Skip to content

Enable Gamma Russian Roulette as ATLAS SteppingAction#545

Merged
SeverinDiederichs merged 5 commits intoapt-sim:masterfrom
SeverinDiederichs:add_GammaRussianRoulette
Apr 20, 2026
Merged

Enable Gamma Russian Roulette as ATLAS SteppingAction#545
SeverinDiederichs merged 5 commits intoapt-sim:masterfrom
SeverinDiederichs:add_GammaRussianRoulette

Conversation

@SeverinDiederichs
Copy link
Copy Markdown
Collaborator

@SeverinDiederichs SeverinDiederichs commented Apr 13, 2026

This PR adds the gamma Russian Roulette for ATLAS and resolves #532.

The Russian Roulette is implemented as a SteppingAction: if active (-DADEPT_STEPPINGACTION=ATLAS), before a gamma is created, it will undergo RR. The settings for the energy threshold and probability are hardcoded for now, as the default parameters in Athena. One important difference: Athena checks for the placed volume prefix "LAr" while AdePT does this at the logical volume level. A safety check is added, and it does not trigger in Athena, in case a placed volume would be created without the LAr prefix, while the logical volume had one.

Notes:

  • example1 was not using the weight in the energy deposition (integrationBenchmark was), this is fixed
  • A new constructor for the track is needed, to assign the weight not directly from the parent pass it as a parameter

Performance results:

Run on the RTX4090

Config Mean Real [s] Std [s] Mean wall [min]
Mono_Master 891.0 11.5 14.850
Mono_NoRR 909.9 3.0 15.165
Mono_GammaRR 860.3 11.6 14.338
Split_Master 898.0 8.6 14.967
Split_NoRR 904.6 2.0 15.077
Split_GammaRR 855.1 4.9 14.252
G4HepEm 1149.9 2.2 19.165

Validation:
The results in Athena with both monolithic and split kernels look good with the Russian Roulette turned on.
Screenshot from 2026-04-20 08-54-38

To do:

  • update Readme and documentation to describe the new option
  • do performance tests with Athena
  • do physics validation in Athena

For an upcoming PR:

  • Add CI test. The reason to not do it in this PR, is that it requires changing the drift test to use a different compilation flag. Doing in a separate PR will allow to show that the current test passes cleanly and then a separate PR will be made to change the CI test to include a case with Russian Roulette.

@phsft-bot
Copy link
Copy Markdown

Can one of the admins verify this patch?

@SeverinDiederichs SeverinDiederichs force-pushed the add_GammaRussianRoulette branch from 436b4cc to 8e09ce1 Compare April 17, 2026 08:43
@SeverinDiederichs
Copy link
Copy Markdown
Collaborator Author

/run-test

Copy link
Copy Markdown
Contributor

@agheata agheata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for this important addition. As discussed offline, the new photon roulette only preserves expectation for unit-weight parents, but this is how it is done in ATLAS so it has to match, propose a fix in Athena and only after update in AdePT. LGTM

@SeverinDiederichs SeverinDiederichs merged commit 0abfff5 into apt-sim:master Apr 20, 2026
6 checks passed
@SeverinDiederichs SeverinDiederichs deleted the add_GammaRussianRoulette branch April 20, 2026 08:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add Photon Russian Roulette for ATLAS

3 participants