celeritas-project / celeritas

Celeritas is a new Monte Carlo transport code designed to accelerate scientific discovery in high energy physics by improving detector simulation throughput and energy efficiency using GPUs.
https://celeritas-project.github.io/celeritas/
Other
65 stars 35 forks source link

Properly clear state counters and data for reuse #1367

Closed amandalund closed 3 months ago

amandalund commented 3 months ago

This fixes an unsual case for celer-sim when multiple events are run one at a time on a single stream and max_steps is specified (unlikely to be done in practice, but how we run our CPU app test). Because the core state counters, track status, and vacancies are not reset between events, stale state data is reused in the next event. This adds a helper method to reset the state data, as well as: