ATLAS Offline Software
Loading...
Searching...
No Matches
TruthIsolationTool Class Reference

#include <TruthIsolationTool.h>

Inheritance diagram for TruthIsolationTool:
Collaboration diagram for TruthIsolationTool:

Public Types

enum  ParticleSelect { UseChargedOnly = 0 , UseAll }
 enumerator to decide which strategy to apply in the selection of particles during the Et-isolation computation More...

Public Member Functions

 TruthIsolationTool (const std::string &type, const std::string &name, const IInterface *parent)
virtual ~TruthIsolationTool ()
StatusCode initialize ()
const std::string & etIsolationsName (const std::string &mcEvtName) const
 Return the name of the TruthEtIsolations container (ie: its StoreGate location) given the StoreGate location of a McEventCollection.
StatusCode buildEtIsolations (const std::string &mcEvtName, ITruthIsolationTool::ParticleSelect sel)
 Computes the isolation energies for each of the HepMC::GenEvent contained into the McEventCollection.
StatusCode registerAlias (const std::string &originalMcEvtColl, const std::string &aliasMcEvtColl)
 Make an alias in the map of isolation energies.
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm.
virtual StatusCode sysStart () override
 Handle START transition.
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles.
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles.
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
void updateVHKA (Gaudi::Details::PropertyBase &)
MsgStream & msg () const
bool msgLvl (const MSG::Level lvl) const

Static Public Member Functions

static const InterfaceID & interfaceID ()
 Inline methods:

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed.

Private Types

typedef std::unordered_map< std::string, std::string > EtIsolMap_t
typedef ServiceHandle< StoreGateSvcStoreGateSvc_t

Private Member Functions

StatusCode buildEtIsolations (const std::string &mcEvtName, const HepMC::GenEvent *genEvt, const std::size_t genIdx, TruthEtIsolations &etIsols, ITruthIsolationTool::ParticleSelect sel)
 Computes the isolation energies for a given HepMC::GenEvent contained into the McEventCollection.
void computeIso (const std::list< HepMC::ConstGenParticlePtr > &parts, const HepMC::ConstGenParticlePtr &p, TruthEtIsolations &etIsolations, ITruthIsolationTool::ParticleSelect sel)
 Computes and stores the list of transverse isolation energies for various cone sizes into the TruthEtIsolations container.
void setupTruthEtIsolationsPrefix (Gaudi::Details::PropertyBase &truthEtIsolationsPrefix)
 Callback method to ensure consistency of the TruthEtIsolations prefix key.
void setupMcEventsOutput (Gaudi::Details::PropertyBase &mcEventsOutputName)
 Callback method to ensure consistency of output McEventCollection key.
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Private Attributes

const HepPDT::ParticleDataTable * m_pdt
 Particle Property service.
StringProperty m_prefix
 Prefix for the TruthEtIsolations container.
StringProperty m_mcEventsOutputName
 Name of the McEventCollection we should attach isolations to.
DoubleProperty m_ptGamMin
 Minimum transverse energy of gammas to be taken into account into the isolation computation.
EtIsolMap_t m_etIsolMap
 A map of McEventCollection StoreGate locations to the according StoreGate location of TruthEtIsolations.
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default)
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default)
std::vector< SG::VarHandleKeyArray * > m_vhka
bool m_varHandleArraysDeclared

Detailed Description

Member Typedef Documentation

◆ EtIsolMap_t

typedef std::unordered_map<std::string, std::string> TruthIsolationTool::EtIsolMap_t
private

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Member Enumeration Documentation

◆ ParticleSelect

enumerator to decide which strategy to apply in the selection of particles during the Et-isolation computation

Enumerator
UseChargedOnly 
UseAll 

Definition at line 43 of file ITruthIsolationTool.h.

Constructor & Destructor Documentation

◆ TruthIsolationTool()

TruthIsolationTool::TruthIsolationTool ( const std::string & type,
const std::string & name,
const IInterface * parent )

Definition at line 41 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

43 :
44 AthAlgTool ( type, name, parent ),
45 m_pdt ( nullptr )
46{
47 //
48 // Property declaration
49 //
50
51 declareProperty( "ptGammaMin",
52 m_ptGamMin = 0.5*GeV,
53 "Minimum transverse energy of gammas to be taken into "
54 "account into the isolation computation." );
55
56 declareProperty( "TruthEtIsolationsPrefix",
57 m_prefix = "TruthEtIsol",
58 "Prefix for the TruthEtIsolations container. This is the "
59 "string which will be prepended to the key of the "
60 "McEventCollection to build the (StoreGate) output "
61 "location for the TruthEtIsolations.\nie: \"GEN_EVENT\" "
62 "--> \"<prefix>_GEN_EVENT\"" );
63 m_prefix.declareUpdateHandler
65 this );
66
67 declareProperty( "McEventsOutput",
68 m_mcEventsOutputName = "GEN_AOD",
69 "Name of the McEventCollection we should attach "
70 "isolations to" );
71 m_mcEventsOutputName.declareUpdateHandler
73 this );
74
75 declareInterface<ITruthIsolationTool>(this);
76}
AthAlgTool()
Default constructor:
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)
const HepPDT::ParticleDataTable * m_pdt
Particle Property service.
void setupMcEventsOutput(Gaudi::Details::PropertyBase &mcEventsOutputName)
Callback method to ensure consistency of output McEventCollection key.
StringProperty m_mcEventsOutputName
Name of the McEventCollection we should attach isolations to.
void setupTruthEtIsolationsPrefix(Gaudi::Details::PropertyBase &truthEtIsolationsPrefix)
Callback method to ensure consistency of the TruthEtIsolations prefix key.
StringProperty m_prefix
Prefix for the TruthEtIsolations container.
DoubleProperty m_ptGamMin
Minimum transverse energy of gammas to be taken into account into the isolation computation.

◆ ~TruthIsolationTool()

TruthIsolationTool::~TruthIsolationTool ( )
virtualdefault

Member Function Documentation

◆ buildEtIsolations() [1/2]

StatusCode TruthIsolationTool::buildEtIsolations ( const std::string & mcEvtName,
const HepMC::GenEvent * genEvt,
const std::size_t genIdx,
TruthEtIsolations & etIsols,
ITruthIsolationTool::ParticleSelect sel )
private

Computes the isolation energies for a given HepMC::GenEvent contained into the McEventCollection.

Definition at line 179 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

184{
185 if ( nullptr == genEvt ) {
186 msg(MSG::WARNING)
187 << "Null pointer to GenEvent (idx = [" << genIdx << "] from "
188 << "McEventCollection [" << mcEvtName << "]) !!"
189 << endmsg;
190 return StatusCode::RECOVERABLE;
191 }
192
193 // create a reduced list of particles
195 for ( const auto& i: *genEvt) {
196 if ( MC::isGenStable(i) && MC::isSimInteracting(i) ) {
197 particles.push_back( i );
198 }
199 }
200
201 for ( const auto& i: *genEvt) {
202 const HepMC::FourVector hlv = i->momentum();
203 const int ida = std::abs(i->pdg_id());
204 const double pt = hlv.perp();
205
206 // Compute isolation only for photon, electron, muon or tau.
207 // Not for documentation particle
208 const bool doComputeIso = ( ( ida == 22 && pt > m_ptGamMin ) ||
209 ida == 11 || ida == 13 || ida == 15 ) &&
211 if ( doComputeIso ) {
212 computeIso( particles, i, etIsols, partSel );
213 }
214 }
215
216 return StatusCode::SUCCESS;
217}
#define endmsg
std::list< HepMC::ConstGenParticlePtr > GenParticles_t
MsgStream & msg() const
void computeIso(const std::list< HepMC::ConstGenParticlePtr > &parts, const HepMC::ConstGenParticlePtr &p, TruthEtIsolations &etIsolations, ITruthIsolationTool::ParticleSelect sel)
Computes and stores the list of transverse isolation energies for various cone sizes into the TruthEt...
bool isSimInteracting(const T &p)
Identify if the particle could interact with the detector during the simulation, e....
bool isGenStable(const T &p)
Determine if the particle is stable at the generator (not det-sim) level,.
bool isPhysical(const T &p)
Identify if the particle is physical, i.e. is stable or decayed.

◆ buildEtIsolations() [2/2]

StatusCode TruthIsolationTool::buildEtIsolations ( const std::string & mcEvtName,
ITruthIsolationTool::ParticleSelect sel )
virtual

Computes the isolation energies for each of the HepMC::GenEvent contained into the McEventCollection.

One can switch b/w using all particles or only the charged ones. Default (from interface) is to use all.

Implements ITruthIsolationTool.

Definition at line 121 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

123{
124 // retrieve collection
125 const McEventCollection* mcEvts = nullptr;
126 if ( !evtStore()->retrieve( mcEvts, mcEvtName ).isSuccess() ) {
127 ATH_MSG_WARNING("Could not retrieve a McEventCollection at ["
128 << mcEvtName << "] !!" << endmsg
129 << "No Et-isolations will be computed !");
130 return StatusCode::RECOVERABLE;
131 }
132
133 // the name of the output (filtered) McEventCollection we want to attach
134 // the Et-isolations to
135 const std::string& outMcEvtName = m_mcEventsOutputName.value();
136
137 // create the container of TruthEtIsolations
138 std::ostringstream truthEtIsolName;
139 truthEtIsolName << m_prefix.value()
141 ? "Charged"
142 : "")
143 << "_" << outMcEvtName;
144
146 if ( !evtStore()->record( etIsolations,
147 truthEtIsolName.str() ).isSuccess() ) {
148 delete etIsolations;
149 etIsolations = nullptr;
150 ATH_MSG_WARNING("Could not record a TruthEtIsolations container at ["
151 << truthEtIsolName.str() << "] !!");
152 return StatusCode::RECOVERABLE;
153 }
154 if ( !evtStore()->setConst( etIsolations ).isSuccess() ) {
155 ATH_MSG_WARNING("Could not setConst the TruthEtIsolations container at ["
156 << truthEtIsolName.str() << "] !!");
157 }
158
159 // update our registry of EtIsol StoreGate locations
160 m_etIsolMap[outMcEvtName] = truthEtIsolName.str();
161
162 bool allGood = true;
163 for ( std::size_t iMc = 0, iMax = mcEvts->size(); iMc != iMax; ++iMc ) {
164 TruthEtIsolations * etIsols = new TruthEtIsolations( outMcEvtName, iMc );
165 etIsolations->push_back( etIsols );
166 if ( !buildEtIsolations( mcEvtName, (*mcEvts)[iMc], iMc,
167 *etIsols, partSel ).isSuccess() ) {
168 msg(MSG::WARNING)
169 << "Problem encountered while computing Et-isolations for idx=["
170 << iMc << "] of McEventCollection [" << mcEvtName << "] !!"
171 << endmsg;
172 allGood = false;
173 }
174 }
175 return allGood ? StatusCode::SUCCESS : StatusCode::RECOVERABLE;
176}
#define ATH_MSG_WARNING(x)
TruthEtIsolationsContainer
ServiceHandle< StoreGateSvc > & evtStore()
value_type push_back(value_type pElem)
Add an element to the end of the collection.
size_type size() const noexcept
Returns the number of elements in the collection.
EtIsolMap_t m_etIsolMap
A map of McEventCollection StoreGate locations to the according StoreGate location of TruthEtIsolatio...
StatusCode buildEtIsolations(const std::string &mcEvtName, ITruthIsolationTool::ParticleSelect sel)
Computes the isolation energies for each of the HepMC::GenEvent contained into the McEventCollection.
bool allGood
Loop over the SDOs & Digits.
retrieve(aClass, aKey=None)
Definition PyKernel.py:110

◆ computeIso()

void TruthIsolationTool::computeIso ( const std::list< HepMC::ConstGenParticlePtr > & parts,
const HepMC::ConstGenParticlePtr & p,
TruthEtIsolations & etIsolations,
ITruthIsolationTool::ParticleSelect sel )
private

Computes and stores the list of transverse isolation energies for various cone sizes into the TruthEtIsolations container.

Definition at line 220 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

224{
225 const HepLorentzVector hlv = ::svToLv(part->momentum());
226 const int ida = std::abs(part->pdg_id());
227
228 McAod::EtIsolations etIsol = { {0.*GeV, 0.*GeV, 0.*GeV, 0.*GeV,
229 0.*GeV, 0.*GeV, 0.*GeV, 0.*GeV} };
230 McAod::EtIsolations pxi = etIsol;
231 McAod::EtIsolations pyi = etIsol;
232
233 int barcodepart = HepMC::barcode(part);
234 for (const auto & particle : particles) {
235 if ( HepMC::barcode(particle) == barcodepart ) {
236 continue;
237 }
238 if( partSel == ITruthIsolationTool::UseChargedOnly ) {
239 double particleCharge = MC::charge(particle->pdg_id());
240 if( std::abs(particleCharge)<1.e-2 )
241 continue;
242 }
243 const HepLorentzVector itrHlv = ::svToLv(particle->momentum());
244 const double r = hlv.deltaR(itrHlv);
245 for ( std::size_t iCone = 0;
247 ++iCone ) {
249 pxi[iCone] += itrHlv.px();
250 pyi[iCone] += itrHlv.py();
251 }
252 }
253 }
254
255 //
256 // Correction for tau (as was done in the old tool for the time being)
257 double pxv = 0.*GeV;
258 double pyv = 0.*GeV;
259 auto decVtx = part->end_vertex();
260 if (ida == 15 && decVtx) {
261 for (const auto& child: *decVtx) {
262 if ( MC::isSimInteracting(child) ) {
263 if( partSel == ITruthIsolationTool::UseChargedOnly ) {
264 double particleCharge = MC::charge(child->pdg_id());
265 if( std::abs(particleCharge)<1.e-2 )
266 continue;
267 }
268 const HepMC::FourVector childHlv = child->momentum();
269 pxv += childHlv.px();
270 pyv += childHlv.py();
271 }
272 }
273 }
274
275 for ( std::size_t i = 0;
276 i != static_cast<std::size_t>(TruthParticleParameters::NbrOfCones);
277 ++i ) {
278 pxi[i] -= pxv;
279 pyi[i] -= pyv;
280 etIsol[i] = std::sqrt(pxi[i]*pxi[i]+pyi[i]*pyi[i]);
281 }
282
283 etIsolations.setEtIsol( part, etIsol );
284}
void setEtIsol(const HepMC::ConstGenParticlePtr &genParticle, const TruthParticleParameters::ConeSize coneIdx, const double etIsol)
Set the transverse energy isolation of a HepMC::GenParticle for a given Cone size.
int r
Definition globals.cxx:22
int barcode(const T *p)
Definition Barcode.h:16
double charge(const T &p)
std::array< double, TruthParticleParameters::NbrOfCones > EtIsolations
An array of doubles of fixed size to modelize the Et isolations for different values of isolation rad...
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
double coneCut(const TruthParticleParameters::ConeSize idx)
The actual definition of delta R cuts for each cone.
ConeSize
Enum for Cone size indexes (for isolation)

◆ declareGaudiProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T, V, H > & hndl,
const SG::VarHandleKeyType &  )
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158 {
160 hndl.value(),
161 hndl.documentation());
162
163 }

◆ declareProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T, V, H > & t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145 {
146 typedef typename SG::HandleClassifier<T>::type htype;
148 }
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>

◆ detStore()

const ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

◆ etIsolationsName()

const std::string & TruthIsolationTool::etIsolationsName ( const std::string & mcEvtName) const
virtual

Return the name of the TruthEtIsolations container (ie: its StoreGate location) given the StoreGate location of a McEventCollection.

It returns an empty string if no TruthEtIsolations container has been processed by the isolation tool.

Implements ITruthIsolationTool.

Definition at line 109 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

110{
111 static const std::string s_emptyString = "";
112 const EtIsolMap_t::const_iterator i = m_etIsolMap.find(mcEvtName);
113 if ( i != m_etIsolMap.end() ) {
114 return i->second;
115 }
116
117 return s_emptyString;
118}

◆ evtStore()

ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase & ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ initialize()

StatusCode TruthIsolationTool::initialize ( )
virtual

Implements ITruthIsolationTool.

Definition at line 81 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

82{
83 // retrieve StoreGate
84 if ( !evtStore().retrieve().isSuccess() ) {
85 ATH_MSG_ERROR("Could not get a handle on StoreGateSvc !!");
86 return StatusCode::FAILURE;
87 }
88
89 ATH_MSG_INFO(" McEventsOutput: [" << m_mcEventsOutputName.value() << "]");
90
91 // Get the Particle Properties Service
92 ServiceHandle<IPartPropSvc> partPropSvc("PartPropSvc", name());
93 if ( !partPropSvc.retrieve().isSuccess() ) {
94 ATH_MSG_ERROR(" Could not initialize Particle Properties Service");
95 return StatusCode::FAILURE;
96 }
97
98 m_pdt = partPropSvc->PDT();
99 if ( nullptr == m_pdt ) {
100 ATH_MSG_ERROR("Could not retrieve HepPDT::ParticleDataTable from "\
101 "ParticleProperties Service !!");
102 return StatusCode::FAILURE;
103 }
104
105 return StatusCode::SUCCESS;
106}
#define ATH_MSG_ERROR(x)
#define ATH_MSG_INFO(x)

◆ inputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

const InterfaceID & ITruthIsolationTool::interfaceID ( )
inlinestaticinherited

Inline methods:

Definition at line 100 of file ITruthIsolationTool.h.

101{
103}
static const InterfaceID IID_ITruthIsolationTool("ITruthIsolationTool", 1, 0)

◆ msg()

MsgStream & AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24 {
25 return this->msgStream();
26 }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30 {
31 return this->msgLevel(lvl);
32 }

◆ outputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ registerAlias()

StatusCode TruthIsolationTool::registerAlias ( const std::string & originalMcEvtColl,
const std::string & aliasMcEvtColl )
virtual

Make an alias in the map of isolation energies.

Implements ITruthIsolationTool.

Definition at line 299 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

301{
302 m_etIsolMap[aliasMcEvtColl] = m_etIsolMap[originalMcEvtColl];
303 return StatusCode::SUCCESS;
304}

◆ renounce()

std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T & h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381 {
382 h.renounce();
384 }
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364 {
366 }

◆ setupMcEventsOutput()

void TruthIsolationTool::setupMcEventsOutput ( Gaudi::Details::PropertyBase & mcEventsOutputName)
private

Callback method to ensure consistency of output McEventCollection key.

Definition at line 293 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

294{
295 // no-op for now
296}

◆ setupTruthEtIsolationsPrefix()

void TruthIsolationTool::setupTruthEtIsolationsPrefix ( Gaudi::Details::PropertyBase & truthEtIsolationsPrefix)
private

Callback method to ensure consistency of the TruthEtIsolations prefix key.

Definition at line 287 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.cxx.

288{
289 // no-op for now
290}

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in asg::AsgMetadataTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and DerivationFramework::CfAthAlgTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase & )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308 {
309 // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310 // << " size: " << m_vhka.size() << endmsg;
311 for (auto &a : m_vhka) {
313 for (auto k : keys) {
314 k->setOwner(this);
315 }
316 }
317 }
std::vector< SG::VarHandleKeyArray * > m_vhka

Member Data Documentation

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_etIsolMap

EtIsolMap_t TruthIsolationTool::m_etIsolMap
private

A map of McEventCollection StoreGate locations to the according StoreGate location of TruthEtIsolations.

Definition at line 139 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_mcEventsOutputName

StringProperty TruthIsolationTool::m_mcEventsOutputName
private

Name of the McEventCollection we should attach isolations to.

Definition at line 128 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.h.

◆ m_pdt

const HepPDT::ParticleDataTable* TruthIsolationTool::m_pdt
private

Particle Property service.

Definition at line 118 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.h.

◆ m_prefix

StringProperty TruthIsolationTool::m_prefix
private

Prefix for the TruthEtIsolations container.

This is the string which will be prepended to the key of the McEventCollection to build the (StoreGate) output location for the TruthEtIsolations. ie: "GEN_EVENT" --> "<prefix>_GEN_EVENT"

Definition at line 124 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.h.

◆ m_ptGamMin

DoubleProperty TruthIsolationTool::m_ptGamMin
private

Minimum transverse energy of gammas to be taken into account into the isolation computation.

Default is ptMin = 0.5*GeV

Definition at line 134 of file TruthParticleID/McParticleTools/src/TruthIsolationTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files: