Repository navigation
Conversation
This adds the switch G4.useG4HepEm, off by default. - It appends _HEP to the hadronic physics list, eg. FTFP_BERT_EMV_HEP+optical, which selects G4HepEm in geant4_vmc. - It needs a geant4_vmc built with G4HepEm. https://its.cern.ch/jira/browse/O2-5901 https://its.cern.ch/jira/browse/O2-7316 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This lets FindGeant4 return early when its targets already exist. - A geant4_vmc built with G4HepEm finds G4HepEm, which finds Geant4 again. - FindGeant4 then failed because the geant4 target already existed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This makes the Geant4 sampling factor for FTFP_BERT_EMV_HEP+optical explicit. - The value 0.808 gives the same EMCAL energy per primary as FTFP_BERT_EMV+optical with 0.821. - It was determined with e- of 1 to 20 GeV and gamma of 1 to 5 GeV; the agreement is within 1 % at all energies. - Before, the list fell back to the default 0.81 by name. https://its.cern.ch/jira/browse/O2-7210 https://its.cern.ch/jira/browse/O2-7316 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This makes the TRD ionisation model follow the G4HepEm physics. - The new default TRDSimParams.ionisationModel=-1 selects the collision tables (1) when G4HepEm transports e-, e+ and gamma, and the energy deposit with PAI (0) otherwise. - G4HepEm counts as active when the physics list in use has the suffix _HEP, so a list given by name behaves like G4.useG4HepEm=1. - An explicit 0 or 1 still wins; 0 together with G4HepEm gives a warning, since G4HepEm has no PAI model. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
sawenzel
requested review from
a team,
bazinski,
f3sch,
jokonig,
nstrangm and
wille10
as code owners
November 18, 2026 18:37
This was referenced Nov 18, 2026
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This adds the switch
G4.useG4HepEm, off by default. With it, e-, e+ and gamma are transported with G4HepEm instead of the Geant4 standard EM physics:The switch appends
_HEPto the hadronic physics list, eg.FTFP_BERT_EMV_HEP+optical, which selects G4HepEm in geant4_vmc. It needs a geant4_vmc built with G4HepEm, which comes with vmc-project/geant4_vmc#93 and alisw/alidist#6428. By default, nothing changes for the user.In addition:
FTFP_BERT_EMV+opticalwith 0.821 (O2-7210).TRDSimParams.ionisationModel=-1does this, and an explicit value still wins.FindGeant4.cmakereturns early when its targets already exist, because a geant4_vmc built with G4HepEm makes CMake look for Geant4 a second time.The validation (GRID productions of pp events, K0S and photon candles, EMCAL and PHOS response) is summarised in https://its.cern.ch/jira/browse/O2-7316: tracking, vertexing, K0S and photon conversions agree within 0.1-0.5 %, and transport is about 5 % faster for pp. The TPC fix found during this work is #16131.
Relates to https://its.cern.ch/jira/browse/O2-5901
and https://its.cern.ch/jira/browse/O2-7316
Assisted by Claude Code.