ATLAS Offline Software
Classes | Public Member Functions | Protected Attributes | Private Member Functions | Private Attributes | List of all members
G4UA::iGeant4::TrackProcessorUserActionFullG4 Class Referencefinal

#include <TrackProcessorUserActionFullG4.h>

Inheritance diagram for G4UA::iGeant4::TrackProcessorUserActionFullG4:
Collaboration diagram for G4UA::iGeant4::TrackProcessorUserActionFullG4:

Classes

struct  Config
 

Public Member Functions

 TrackProcessorUserActionFullG4 (const Config &config)
 
virtual ~TrackProcessorUserActionFullG4 ()
 
virtual void PreUserTrackingAction (const G4Track *) override final
 
virtual void BeginOfEventAction (const G4Event *) override final
 
virtual void EndOfEventAction (const G4Event *) override final
 
virtual void PostUserTrackingAction (const G4Track *) override final
 
virtual void UserSteppingAction (const G4Step *) override final
 
ISF::ISFParticleContainer ReturnSecondaries (ISF::ISFParticle const *parent)
 

Protected Attributes

AtlasG4EventUserInfom_atlasG4EvtUserInfo {}
 event-global G4 UserInformation More...
 
ISF::ISFParticleContainer m_storedSecondaries
 

Private Member Functions

void ISFSteppingAction (const G4Step *, ISF::ISFParticle *curISP) override final
 Called by the base class after the G4Track->ISFParticle association has been established. More...
 
ISF::EntryLayer entryLayer (const G4Step *aStep)
 
void setupPrimary (G4Track &)
 Setup the given G4Track as the current primary particle which we'll process. More...
 
void setupSecondary (const G4Track &)
 Setup the given G4Track as the current secondary particle which we'll process. More...
 
void updateCachedParticleInfo (ISF::ISFParticle *baseISFParticle, HepMC::ConstGenParticlePtr primaryGenParticle, HepMC::GenParticlePtr currentGenParticle)
 Set the following information as the currently traced particle. More...
 
VTrackInformation::TrackClassification classify (HepMC::ConstGenParticlePtr primaryGenParticle, HepMC::ConstGenParticlePtr generationZeroGenParticle, HepMC::ConstGenParticlePtr currentGenParticle, int regenerationNumber) const
 Classify the particle represented by the given set of truth links. More...
 

Private Attributes

Config m_config
 
ISF::IEntryLayerToolm_entryLayerToolQuick
 access to the ISF Entry Layer tool which is used to record entry-layer collections More...
 
ISF::IGeoIDSvcm_geoIDSvcQuick
 access to the central ISF GeoID serice More...
 
std::map< std::string, int, std::less< std::string > > m_entryLayerMap
 
AtlasDetDescr::AtlasRegion m_nextGeoID
 
const G4Track * m_currentTrack
 
ISF::ISFParticlem_curBaseISP {}
 The most recent ISFParticle ancestor that triggers the currently processed G4Track. More...
 

Detailed Description

Definition at line 34 of file TrackProcessorUserActionFullG4.h.

Constructor & Destructor Documentation

◆ TrackProcessorUserActionFullG4()

G4UA::iGeant4::TrackProcessorUserActionFullG4::TrackProcessorUserActionFullG4 ( const Config config)

Definition at line 39 of file TrackProcessorUserActionFullG4.cxx.

41  m_entryLayerToolQuick(nullptr),
42  m_geoIDSvcQuick(nullptr),
43  m_currentTrack(nullptr)
44  {
45 
47  {
48  G4cout << "create TrackProcessorUserActionFullG4" << G4endl;
49  }
50 
52 
53  if ( !m_config.entryLayerTool.empty() ) {
54  if ( m_config.entryLayerTool.retrieve().isFailure()) {
55  G4ExceptionDescription description;
56  description << G4String("TrackProcessorUserActionFullG4: ") + "Could not retrieve ISF Entry Layer Tool: " << m_config.entryLayerTool;
57  G4Exception("G4UA::iGeant4::TrackProcessorUserActionFullG4", "NoISFEntryLayerTool", FatalException, description);
58  return; //The G4Exception call above should abort the job, but Coverity does not seem to pick this up.
59  }
61  }
62 
63  if ( !m_config.geoIDSvc.empty() ) {
64  if (m_config.geoIDSvc.retrieve().isFailure()) {
65  G4ExceptionDescription description;
66  description << G4String("TrackProcessorUserActionFullG4: ") + "Could not retrieve ISF GeoID Svc: " << m_config.geoIDSvc;
67  G4Exception("G4UA::iGeant4::TrackProcessorUserActionFullG4", "NoISFGeoIDSvc", FatalException, description);
68  return; //The G4Exception call above should abort the job, but Coverity does not seem to pick this up.
69  }
70 
72  }
73 
74  m_entryLayerMap["CALO::CALO"] = m_config.truthVolLevel+1;
75  m_entryLayerMap["MUONQ02::MUONQ02"] = m_config.truthVolLevel+1;
76  m_entryLayerMap[m_config.isITkGeometry ? "ITK::ITK" : "IDET::IDET"] = m_config.truthVolLevel+1;
77 
78  }

◆ ~TrackProcessorUserActionFullG4()

virtual G4UA::iGeant4::TrackProcessorUserActionFullG4::~TrackProcessorUserActionFullG4 ( )
inlinevirtual

Definition at line 53 of file TrackProcessorUserActionFullG4.h.

53 {}

Member Function Documentation

◆ BeginOfEventAction()

void G4UA::iGeant4::TrackProcessorUserActionBase::BeginOfEventAction ( const G4Event *  )
finaloverridevirtualinherited

Definition at line 48 of file TrackProcessorUserActionBase.cxx.

49 {
50  m_curBaseISP = nullptr;
52  return;
53 }

◆ classify()

VTrackInformation::TrackClassification G4UA::iGeant4::TrackProcessorUserActionBase::classify ( HepMC::ConstGenParticlePtr  primaryGenParticle,
HepMC::ConstGenParticlePtr  generationZeroGenParticle,
HepMC::ConstGenParticlePtr  currentGenParticle,
int  regenerationNumber 
) const
privateinherited

Classify the particle represented by the given set of truth links.

Definition at line 208 of file TrackProcessorUserActionBase.cxx.

212 {
213  // if particle points to a non-zero truth particle it can not just be a 'simple' Secondary
214 
215  if (currentGenParticle) {
216  if (currentGenParticle == primaryGenParticle) {
218  }
219  else if (generationZeroGenParticle == primaryGenParticle && regenerationNumber>0) {
221  }
222  else {
224  }
225  }
226 
228 }

◆ EndOfEventAction()

void G4UA::iGeant4::TrackProcessorUserActionBase::EndOfEventAction ( const G4Event *  )
finaloverridevirtualinherited

Definition at line 55 of file TrackProcessorUserActionBase.cxx.

56 {
57  m_curBaseISP = nullptr;
58  m_atlasG4EvtUserInfo = nullptr;
59  return;
60 }

◆ entryLayer()

ISF::EntryLayer G4UA::iGeant4::TrackProcessorUserActionFullG4::entryLayer ( const G4Step *  aStep)
private

Definition at line 169 of file TrackProcessorUserActionFullG4.cxx.

170  {
171  //
172  // this is the same prescription for getting the entry layer as in
173  // MCTruth/MCTruthSteppingAction
174  //
175 
176  const G4StepPoint *preStep =aStep->GetPreStepPoint();
177  const G4StepPoint *postStep=aStep->GetPostStepPoint();
178 
179  const G4TouchableHistory *preTHist=static_cast<const G4TouchableHistory*>(preStep->GetTouchable());
180  const G4TouchableHistory *postTHist=static_cast<const G4TouchableHistory*>(postStep->GetTouchable());
181  int nLev1 = preTHist->GetHistoryDepth();
182  int nLev2 = postTHist->GetHistoryDepth();
183 
184  std::map<std::string, int, std::less<std::string> >::const_iterator it;
185 
186  std::string vname1;
187  bool pass=false;
188  for (it=m_entryLayerMap.begin(); it!=m_entryLayerMap.end(); ++it) {
189 
190  int il=(*it).second;
191 
192  if (il<=(nLev1+1)) {
193  vname1=preTHist->GetVolume(nLev1-il+1)->GetName();
194 
195  if (vname1!=(*it).first) continue;
196 
197  if (il<=(nLev2+1)) {
198  if (vname1 == static_cast<const std::string&>(postTHist->GetVolume(nLev2-il+1)->GetName()))
199  {
200  continue;
201  }
202  }
203 
204  pass=true;
205  break;
206  }
207  }
208 
209 
211  if (pass) {
212  if (!m_config.isITkGeometry && vname1=="IDET::IDET") layer=ISF::fAtlasCaloEntry;
213  else if ( m_config.isITkGeometry && vname1=="ITK::ITK") layer=ISF::fAtlasCaloEntry;
214  else if (vname1=="CALO::CALO") layer=ISF::fAtlasMuonEntry;
215  else if (vname1=="MUONQ02::MUONQ02") layer=ISF::fAtlasMuonExit;
216  }
217 
218  return layer;
219  }

◆ ISFSteppingAction()

void G4UA::iGeant4::TrackProcessorUserActionFullG4::ISFSteppingAction ( const G4Step *  aStep,
ISF::ISFParticle curISP 
)
finaloverrideprivatevirtual

Called by the base class after the G4Track->ISFParticle association has been established.

Implements G4UA::iGeant4::TrackProcessorUserActionBase.

Definition at line 80 of file TrackProcessorUserActionFullG4.cxx.

81  {
82  G4Track* aTrack = aStep->GetTrack();
83  //int aTrackID = aTrack->GetTrackID(); // Only used in DEBUG messages
84  G4TrackStatus aTrackStatus = aTrack->GetTrackStatus();
85 
86  const G4StepPoint *preStep = aStep->GetPreStepPoint();
87  const G4StepPoint *postStep = aStep->GetPostStepPoint();
88 
89 
91  m_config.
92  truthVolLevel,
94  if ( curISP->nextGeoID()!=nextG4GeoID ) {
95  curISP->setNextGeoID( nextG4GeoID );
96  }
97 
98  // check if dead track
99  if ( aTrackStatus==fStopAndKill ) {
100  // ATH_MSG_DEBUG("Stepping dead G4Track, returning. TrackLength="<<aTrack->GetTrackLength()<<
101  // " TrackEkin="<<aTrack->GetKineticEnergy()<<" TrackID="<<aTrackID);
102  return;
103  }
104 
105  const G4VPhysicalVolume *preVol = preStep->GetPhysicalVolume();
106  const G4VPhysicalVolume *postVol = postStep->GetPhysicalVolume();
107 
108  // check if particle left detector volume
109  if ( postVol==0 ) {
110  // ATH_MSG_DEBUG("G4Step not in physical volume, returning. TrackLength="<<
111  // aTrack->GetTrackLength()<<" TrackEkin="<<aTrack->GetKineticEnergy()<<
112  // " TrackID="<<aTrackID);
113  // left world
114  return;
115  }
116 
117  // check if particle is within same physical volume
118  if ( preVol==postVol ) {
119  // ATH_MSG_DEBUG("G4Track stays inside current volume");
120  return;
121  }
122 
123  //
124  // this point is only reached if particle has crossed
125  // a sub-det boundary in the Geant4-only mode
126  //
127 
128  TrackHelper tHelp(aTrack);
129 
130  // only process particle at entry layer if primary or registered secondary
131 
132  if ( ! tHelp.IsSecondary() ) {
133 
134  // get entry layer
136 
138 
139 
143 
145  *curISP,
146  nullptr // truthBinding
147  );
148  tmpISP->setNextGeoID(nextGeoID);
150 
151  auto generationZeroBarcode = tHelp.GetBarcode(); // FIXME barcode-based
152  tmpISP->setBarcode(generationZeroBarcode); // FIXME barcode-based
153  auto generationZeroID = tHelp.GetUniqueID();
154  tmpISP->setId(generationZeroID);
155 
156  tmpISP->setNextGeoID( nextGeoID );
157 
158  // inform the entry layer tool about this particle
160 
161  delete tmpISP;
162  }
163 
164  }
165 
166  return;
167  }

◆ PostUserTrackingAction()

void G4UA::iGeant4::TrackProcessorUserActionBase::PostUserTrackingAction ( const G4Track *  )
finaloverridevirtualinherited

Definition at line 232 of file TrackProcessorUserActionBase.cxx.

233 {
234  m_curBaseISP = nullptr;
235  return;
236 }

◆ PreUserTrackingAction()

void G4UA::iGeant4::TrackProcessorUserActionFullG4::PreUserTrackingAction ( const G4Track *  aTrack)
finaloverridevirtual

Reimplemented from G4UA::iGeant4::TrackProcessorUserActionBase.

Definition at line 221 of file TrackProcessorUserActionFullG4.cxx.

221  {
222  // reset geoId, call upstream method
224  m_currentTrack = aTrack;
226  return;
227  }

◆ ReturnSecondaries()

ISF::ISFParticleContainer G4UA::iGeant4::TrackProcessorUserActionBase::ReturnSecondaries ( ISF::ISFParticle const parent)
inherited

Definition at line 238 of file TrackProcessorUserActionBase.cxx.

239 {
240  // For now, just return all particles
243  return result;
244 }

◆ setupPrimary()

void G4UA::iGeant4::TrackProcessorUserActionBase::setupPrimary ( G4Track &  aTrack)
privateinherited

Setup the given G4Track as the current primary particle which we'll process.

Definition at line 111 of file TrackProcessorUserActionBase.cxx.

112 {
113  //
114  // Get PrimaryParticleInformation from G4PrimaryParticle (assigned by TransportTool::addPrimaryVertex)
115  //
116 
118  if ( trackInfo ) {
119  G4ExceptionDescription description;
120  description << G4String("PreUserTrackingAction: ")
121  << "Started simulation of primary particle which already has a TrackInformation/TrackBarcodeInfo object attached (trackID: "
122  << aTrack.GetTrackID() << ", track pos: "<<aTrack.GetPosition() << ", mom: "<<aTrack.GetMomentum()
123  << ", parentID " << aTrack.GetParentID() << ")";
124  G4Exception("iGeant4::TrackProcessorUserActionBase", "TrackInformationAlreadyExists", FatalException, description);
125  return; // The G4Exception call above should abort the job, but Coverity does not seem to pick this up.
126  }
127 
128  auto* primaryPartInfo = dynamic_cast <PrimaryParticleInformation*> (aTrack.GetDynamicParticle()->GetPrimaryParticle()->GetUserInformation());
129  if (!primaryPartInfo) {
130  G4ExceptionDescription description;
131  description << G4String("PreUserTrackingAction: ") + "NULL PrimaryParticleInformation pointer for current G4Step (trackID "
132  << aTrack.GetTrackID() << ", track pos: "<<aTrack.GetPosition() << ", mom: "<<aTrack.GetMomentum()
133  << ", parentID " << aTrack.GetParentID() << ")";
134  G4Exception("iGeant4::TrackProcessorUserActionBase", "NoPPInfo", FatalException, description);
135  return; // The G4Exception call above should abort the job, but Coverity does not seem to pick this up.
136  }
137 
138  // get base ISFParticle and link to TrackInformation
139  auto* baseISP = primaryPartInfo->GetISFParticle();
140  if (!baseISP) {
141  G4ExceptionDescription description;
142  description << G4String("PreUserTrackingAction: ") + "No ISFParticle associated with primary particle (trackID: "
143  << aTrack.GetTrackID() << ", track pos: "<<aTrack.GetPosition() << ", mom: "<<aTrack.GetMomentum()
144  << ", parentID " << aTrack.GetParentID() << ")";
145  G4Exception("iGeant4::TrackProcessorUserActionBase", "NoISFParticle", FatalException, description);
146  return; // The G4Exception call above should abort the job, but Coverity does not seem to pick this up.
147  }
148 
149  ISF::TruthBinding* truthBinding = baseISP->getTruthBinding();
150  if (!truthBinding) {
151  G4ExceptionDescription description;
152  description << G4String("PreUserTrackingAction: ") + "No ISF::TruthBinding associated with primary particle (trackID: "
153  << aTrack.GetTrackID() << ", track pos: "<<aTrack.GetPosition() << ", mom: "<<aTrack.GetMomentum()
154  << ", parentID " << aTrack.GetParentID() << ")";
155  G4Exception("iGeant4::TrackProcessorUserActionBase", "NoISFTruthBinding", FatalException, description);
156  return; // The G4Exception call above should abort the job, but Coverity does not seem to pick this up.
157  }
158 
159  int regenerationNr = primaryPartInfo->GetRegenerationNr();
160 
161  HepMC::GenParticlePtr primaryGenParticle = truthBinding->getGenerationZeroGenParticle();
162  HepMC::GenParticlePtr generationZeroGenParticle = truthBinding->getGenerationZeroGenParticle();
163  HepMC::GenParticlePtr currentGenParticle = truthBinding->getCurrentGenParticle();
164 
165  auto classification = classify(primaryGenParticle,
166  generationZeroGenParticle,
167  currentGenParticle,
168  regenerationNr);
169 
170  auto* newTrackInfo = ::iGeant4::ISFG4Helper::attachTrackInfoToNewG4Track(aTrack,
171  *baseISP,
172  classification,
173  generationZeroGenParticle );
174  newTrackInfo->SetRegenerationNr(regenerationNr);
175 
176  updateCachedParticleInfo(baseISP,
177  primaryGenParticle,
178  currentGenParticle);
179 
180  return;
181 }

◆ setupSecondary()

void G4UA::iGeant4::TrackProcessorUserActionBase::setupSecondary ( const G4Track &  aTrack)
privateinherited

Setup the given G4Track as the current secondary particle which we'll process.

Definition at line 183 of file TrackProcessorUserActionBase.cxx.

184 {
186 
187  HepMC::GenParticlePtr currentGenParticle = trackInfo->GetCurrentGenParticle();
188  HepMC::GenParticlePtr primaryGenParticle = trackInfo->GetPrimaryGenParticle();
189  ISF::ISFParticle* baseISFParticle = trackInfo->GetBaseISFParticle();
190 
191  updateCachedParticleInfo(baseISFParticle, primaryGenParticle, currentGenParticle);
192 
193  return;
194 }

◆ updateCachedParticleInfo()

void G4UA::iGeant4::TrackProcessorUserActionBase::updateCachedParticleInfo ( ISF::ISFParticle baseISFParticle,
HepMC::ConstGenParticlePtr  primaryGenParticle,
HepMC::GenParticlePtr  currentGenParticle 
)
privateinherited

Set the following information as the currently traced particle.

Definition at line 196 of file TrackProcessorUserActionBase.cxx.

199 {
200  m_curBaseISP = baseISFParticle;
201  m_atlasG4EvtUserInfo->SetCurrentPrimaryGenParticle( primaryGenParticle );
202  m_atlasG4EvtUserInfo->SetCurrentGenParticle( currentGenParticle );
203  return;
204 }

◆ UserSteppingAction()

void G4UA::iGeant4::TrackProcessorUserActionBase::UserSteppingAction ( const G4Step *  aStep)
finaloverridevirtualinherited

Definition at line 62 of file TrackProcessorUserActionBase.cxx.

63 {
64  // get geoID from parent
65  //TODO ELLI AtlasDetDescr::AtlasRegion curGeoID = m_curBaseISP->nextGeoID();
66  //TODO ELLI ATH_MSG_DEBUG( "Currently simulating TrackID = " << aStep->GetTrack()->GetTrackID() <<
67  //TODO ELLI " inside geoID = " << curGeoID );
68 
69  //
70  // call the ISFSteppingAction method of the implementation
71  //
73 
74  //
75  // propagate the current ISFParticle link to all secondaries
76  //
77  const std::vector<const G4Track*> *secondaryVector = aStep->GetSecondaryInCurrentStep();
78  for ( auto* aConstSecondaryTrack : *secondaryVector ) {
79  // get a non-const G4Track for current secondary (nasty!)
80  G4Track* aSecondaryTrack ATLAS_THREAD_SAFE = const_cast<G4Track*>( aConstSecondaryTrack ); // imposed by Geant4 interface
81 
82  auto *trackInfo = ::iGeant4::ISFG4Helper::getISFTrackInfo(*aSecondaryTrack);
83 
84  // G4Tracks aready returned to ISF will have a TrackInformation attached to them
85  bool particleReturnedToISF = trackInfo && trackInfo->GetReturnedToISF();
86  if (!particleReturnedToISF) {
87  HepMC::GenParticlePtr generationZeroGenParticle{};
89  *m_curBaseISP,
91  generationZeroGenParticle );
92  }
93  } // <- loop over secondaries from this step
94 
95  return;
96 }

Member Data Documentation

◆ m_atlasG4EvtUserInfo

AtlasG4EventUserInfo* G4UA::iGeant4::TrackProcessorUserActionBase::m_atlasG4EvtUserInfo {}
protectedinherited

event-global G4 UserInformation

Definition at line 48 of file TrackProcessorUserActionBase.h.

◆ m_config

Config G4UA::iGeant4::TrackProcessorUserActionFullG4::m_config
private

Definition at line 61 of file TrackProcessorUserActionFullG4.h.

◆ m_curBaseISP

ISF::ISFParticle* G4UA::iGeant4::TrackProcessorUserActionBase::m_curBaseISP {}
privateinherited

The most recent ISFParticle ancestor that triggers the currently processed G4Track.

Definition at line 75 of file TrackProcessorUserActionBase.h.

◆ m_currentTrack

const G4Track* G4UA::iGeant4::TrackProcessorUserActionFullG4::m_currentTrack
private

Definition at line 75 of file TrackProcessorUserActionFullG4.h.

◆ m_entryLayerMap

std::map<std::string, int, std::less<std::string> > G4UA::iGeant4::TrackProcessorUserActionFullG4::m_entryLayerMap
private

Definition at line 72 of file TrackProcessorUserActionFullG4.h.

◆ m_entryLayerToolQuick

ISF::IEntryLayerTool* G4UA::iGeant4::TrackProcessorUserActionFullG4::m_entryLayerToolQuick
private

access to the ISF Entry Layer tool which is used to record entry-layer collections

quickaccess avoiding gaudi ovehead

Definition at line 66 of file TrackProcessorUserActionFullG4.h.

◆ m_geoIDSvcQuick

ISF::IGeoIDSvc* G4UA::iGeant4::TrackProcessorUserActionFullG4::m_geoIDSvcQuick
private

access to the central ISF GeoID serice

quickaccess avoiding gaudi ovehead

Definition at line 69 of file TrackProcessorUserActionFullG4.h.

◆ m_nextGeoID

AtlasDetDescr::AtlasRegion G4UA::iGeant4::TrackProcessorUserActionFullG4::m_nextGeoID
private

Definition at line 74 of file TrackProcessorUserActionFullG4.h.

◆ m_storedSecondaries

ISF::ISFParticleContainer G4UA::iGeant4::TrackProcessorUserActionBase::m_storedSecondaries
protectedinherited

Definition at line 50 of file TrackProcessorUserActionBase.h.


The documentation for this class was generated from the following files:
ISF::ISFParticleContainer
std::list< ISF::ISFParticle * > ISFParticleContainer
generic ISFParticle container (not necessarily a std::list!)
Definition: ISFParticleContainer.h:23
AtlasG4EventUserInfo::SetCurrentPrimaryGenParticle
void SetCurrentPrimaryGenParticle(HepMC::ConstGenParticlePtr p)
set m_currentPrimaryGenParticle, the pointer to the HepMC::GenParticle used to create the current G4P...
Definition: AtlasG4EventUserInfo.h:53
PlotCalibFromCool.il
il
Definition: PlotCalibFromCool.py:381
ISF::fAtlasMuonEntry
@ fAtlasMuonEntry
Definition: EntryLayer.h:38
get_generator_info.result
result
Definition: get_generator_info.py:21
ISF::ISFParticle::setNextGeoID
void setNextGeoID(AtlasDetDescr::AtlasRegion geoID)
register the next AtlasDetDescr::AtlasRegion
G4UA::iGeant4::TrackProcessorUserActionFullG4::Config::truthVolLevel
int truthVolLevel
Definition: TrackProcessorUserActionFullG4.h:47
iGeant4::ISFG4Helper::attachTrackInfoToNewG4Track
static TrackInformation * attachTrackInfoToNewG4Track(G4Track &aTrack, ISF::ISFParticle &baseIsp, VTrackInformation::TrackClassification classification, HepMC::GenParticlePtr generationZeroGenParticle=nullptr)
attach a new TrackInformation object to the given new (!) G4Track (the G4Track must not have a UserIn...
Definition: ISFG4Helper.cxx:78
ISF::fAtlasMuonExit
@ fAtlasMuonExit
Definition: EntryLayer.h:39
ISF::TruthBinding
Definition: TruthBinding.h:18
G4UA::iGeant4::TrackProcessorUserActionBase::TrackProcessorUserActionBase
TrackProcessorUserActionBase()=default
ISF::TruthBinding::getCurrentGenParticle
HepMC::GenParticlePtr getCurrentGenParticle()
pointer to the particle in the simulation truth
AtlasDetDescr::AtlasRegion
AtlasRegion
Definition: AtlasRegion.h:27
G4UA::iGeant4::TrackProcessorUserActionBase::classify
VTrackInformation::TrackClassification classify(HepMC::ConstGenParticlePtr primaryGenParticle, HepMC::ConstGenParticlePtr generationZeroGenParticle, HepMC::ConstGenParticlePtr currentGenParticle, int regenerationNumber) const
Classify the particle represented by the given set of truth links.
Definition: TrackProcessorUserActionBase.cxx:208
HepMC::GenParticlePtr
GenParticle * GenParticlePtr
Definition: GenParticle.h:37
skel.it
it
Definition: skel.GENtoEVGEN.py:423
G4UA::iGeant4::TrackProcessorUserActionFullG4::m_geoIDSvcQuick
ISF::IGeoIDSvc * m_geoIDSvcQuick
access to the central ISF GeoID serice
Definition: TrackProcessorUserActionFullG4.h:69
ISF::ISFParticle
Definition: ISFParticle.h:42
G4UA::iGeant4::TrackProcessorUserActionFullG4::m_entryLayerMap
std::map< std::string, int, std::less< std::string > > m_entryLayerMap
Definition: TrackProcessorUserActionFullG4.h:72
iGeant4::ISFG4GeoHelper::nextGeoId
static AtlasDetDescr::AtlasRegion nextGeoId(const G4Step *aStep, int truthVolLevel, ISF::IGeoIDSvc *geoIDSvc)
Definition: ISFG4GeoHelper.cxx:20
AtlasDetDescr::fUndefinedAtlasRegion
@ fUndefinedAtlasRegion
Definition: AtlasRegion.h:29
G4UA::iGeant4::TrackProcessorUserActionFullG4::m_entryLayerToolQuick
ISF::IEntryLayerTool * m_entryLayerToolQuick
access to the ISF Entry Layer tool which is used to record entry-layer collections
Definition: TrackProcessorUserActionFullG4.h:66
G4UA::iGeant4::TrackProcessorUserActionFullG4::Config::verboseLevel
unsigned int verboseLevel
Definition: TrackProcessorUserActionFullG4.h:48
G4UA::iGeant4::TrackProcessorUserActionBase::ISFSteppingAction
virtual void ISFSteppingAction(const G4Step *, ISF::ISFParticle *)=0
This method is called by TrackProcessorUserActionBase after the G4Track->ISFParticle association has ...
G4UA::iGeant4::TrackProcessorUserActionFullG4::Config::geoIDSvc
ServiceHandle< ISF::IGeoIDSvc > geoIDSvc
access to the central ISF GeoID service
Definition: TrackProcessorUserActionFullG4.h:46
config
Definition: PhysicsAnalysis/AnalysisCommon/AssociationUtils/python/config.py:1
G4UA::iGeant4::TrackProcessorUserActionFullG4::Config::isITkGeometry
bool isITkGeometry
Definition: TrackProcessorUserActionFullG4.h:49
TrackHelper
Definition: TrackHelper.h:14
G4UA::iGeant4::TrackProcessorUserActionFullG4::m_nextGeoID
AtlasDetDescr::AtlasRegion m_nextGeoID
Definition: TrackProcessorUserActionFullG4.h:74
ISF::fUnsetEntryLayer
@ fUnsetEntryLayer
Definition: EntryLayer.h:33
G4UA::iGeant4::TrackProcessorUserActionBase::m_storedSecondaries
ISF::ISFParticleContainer m_storedSecondaries
Definition: TrackProcessorUserActionBase.h:50
ISF::ISFParticle::nextGeoID
AtlasDetDescr::AtlasRegion nextGeoID() const
next geoID the particle will be simulated in
ISF::TruthBinding::getGenerationZeroGenParticle
HepMC::GenParticlePtr getGenerationZeroGenParticle()
pointer to the simulation truth particle before any regeneration happened (eg.
iGeant4::ISFG4Helper::getAtlasG4EventUserInfo
static AtlasG4EventUserInfo * getAtlasG4EventUserInfo()
return pointer to current AtlasG4EventUserInfo
Definition: ISFG4Helper.cxx:114
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
VTrackInformation::Primary
@ Primary
Definition: VTrackInformation.h:32
ISF::IEntryLayerTool::registerParticle
virtual ISF::EntryLayer registerParticle(const ISFParticle &particle, EntryLayer layer=fUnsetEntryLayer)=0
Add the given particle to the corresponding Entry/Exit layer if applicable.
G4UA::iGeant4::TrackProcessorUserActionFullG4::entryLayer
ISF::EntryLayer entryLayer(const G4Step *aStep)
Definition: TrackProcessorUserActionFullG4.cxx:169
ISF::ISFParticle::setId
void setId(int id)
set a new unique ID
WriteCalibToCool.swap
swap
Definition: WriteCalibToCool.py:94
G4UA::iGeant4::TrackProcessorUserActionFullG4::m_config
Config m_config
Definition: TrackProcessorUserActionFullG4.h:61
trackInfo
Definition: TrigInDetUtils.h:13
iGeant4::ISFG4Helper::convertG4TrackToISFParticle
static ISF::ISFParticle * convertG4TrackToISFParticle(const G4Track &aTrack, const ISF::ISFParticle &parent, ISF::TruthBinding *truth=nullptr)
convert the given G4Track into an ISFParticle
Definition: ISFG4Helper.cxx:31
G4UA::iGeant4::TrackProcessorUserActionBase::m_atlasG4EvtUserInfo
AtlasG4EventUserInfo * m_atlasG4EvtUserInfo
event-global G4 UserInformation
Definition: TrackProcessorUserActionBase.h:48
AtlasDetDescr::fAtlasCavern
@ fAtlasCavern
Definition: AtlasRegion.h:37
G4UA::iGeant4::TrackProcessorUserActionFullG4::m_currentTrack
const G4Track * m_currentTrack
Definition: TrackProcessorUserActionFullG4.h:75
G4UA::iGeant4::TrackProcessorUserActionBase::updateCachedParticleInfo
void updateCachedParticleInfo(ISF::ISFParticle *baseISFParticle, HepMC::ConstGenParticlePtr primaryGenParticle, HepMC::GenParticlePtr currentGenParticle)
Set the following information as the currently traced particle.
Definition: TrackProcessorUserActionBase.cxx:196
ISF::ISFParticle::setNextSimID
void setNextSimID(SimSvcID simID)
register the next SimSvcID
ISF::EntryLayer
EntryLayer
Definition: EntryLayer.h:31
PrimaryParticleInformation
This class is attached to G4PrimaryParticle objects as UserInformation. The member variable m_thePart...
Definition: PrimaryParticleInformation.h:39
G4UA::iGeant4::TrackProcessorUserActionFullG4::Config::entryLayerTool
ToolHandle< ISF::IEntryLayerTool > entryLayerTool
access to the ISF Entry Layer tool which is used to record entry-layer collections
Definition: TrackProcessorUserActionFullG4.h:44
ISF::fAtlasCaloEntry
@ fAtlasCaloEntry
Definition: EntryLayer.h:37
ATLAS_THREAD_SAFE
#define ATLAS_THREAD_SAFE
Definition: checker_macros.h:211
G4UA::iGeant4::TrackProcessorUserActionBase::PreUserTrackingAction
virtual void PreUserTrackingAction(const G4Track *) override
Definition: TrackProcessorUserActionBase.cxx:98
G4UA::iGeant4::TrackProcessorUserActionBase::m_curBaseISP
ISF::ISFParticle * m_curBaseISP
The most recent ISFParticle ancestor that triggers the currently processed G4Track.
Definition: TrackProcessorUserActionBase.h:75
ISF::ISFParticle::setBarcode
void setBarcode(int bc)
set a new barcode
VTrackInformation::Secondary
@ Secondary
Definition: VTrackInformation.h:32
iGeant4::ISFG4Helper::getISFTrackInfo
static VTrackInformation * getISFTrackInfo(const G4Track &aTrack)
return a valid UserInformation object of the G4Track for use within the ISF
Definition: ISFG4Helper.cxx:69
AtlasG4EventUserInfo::SetCurrentGenParticle
void SetCurrentGenParticle(HepMC::GenParticlePtr p)
set m_currentGenParticle, the pointer to the GenParticle corresponding to the current G4Track.
Definition: AtlasG4EventUserInfo.h:67
VTrackInformation::RegisteredSecondary
@ RegisteredSecondary
Definition: VTrackInformation.h:32
ISF::fUndefinedSimID
@ fUndefinedSimID
Definition: SimSvcID.h:32
VTrackInformation::RegeneratedPrimary
@ RegeneratedPrimary
Definition: VTrackInformation.h:32
description
std::string description
glabal timer - how long have I taken so far?
Definition: hcg.cxx:88