ATLAS Offline Software
TruthParticleDecoratorAlg.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TRUTH_PARTICLE_DECORATOR_ALG_HH
6 #define TRUTH_PARTICLE_DECORATOR_ALG_HH
7 
9 #include "GaudiKernel/ToolHandle.h"
13 
17 
18 
19 namespace FlavorTagDiscriminants {
20 
22  public:
23  TruthParticleDecoratorAlg(const std::string& name,
24  ISvcLocator* pSvcLocator );
25 
26  virtual StatusCode initialize() override;
27  virtual StatusCode execute(const EventContext& ) const override;
28 
29  private:
30 
31  // Input Containers
33  this, "truthContainer", "TruthParticles",
34  "Key for the input truth particle collection"};
36  this, "TruthPrimaryVertices", "TruthPrimaryVertices",
37  "Key for the input truth PV collection"};
38 
39  // Decorators for truth particles
41  this, "ftagTruthOriginLabel", "ftagTruthOriginLabel",
42  "Exclusive origin label of the truth particle"};
44  this, "ftagTruthTypeLabel", "ftagTruthTypeLabel",
45  "Exclusive truth type label of the truth particle"};
47  this, "ftagTruthSourceLabel", "ftagTruthSourceLabel",
48  "Exclusive truth label for the source of secondary particles"};
50  this, "ftagTruthVertexIndex", "ftagTruthVertexIndex",
51  "ftagTruth vertex index of the truth particle"};
53  this, "ftagTruthParentBarcode", "ftagTruthParentBarcode",
54  "Barcode of parent of linked truth particle"};
55 
56  // truth origin tool
57  ToolHandle<InDet::InDetTrackTruthOriginTool> m_truthOriginTool {
58  this, "trackTruthOriginTool", "InDet::InDetTrackTruthOriginTool",
59  "track truth origin tool"};
60 
61  Gaudi::Property<float> m_truthVertexMergeDistance {
62  this, "truthVertexMergeDistance", 0.1,
63  "Merge any truth vertices within this distance [mm]"};
64  };
65 }
66 
67 #endif
TruthParticleContainerFwd.h
SG::WriteDecorHandleKey
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
Definition: StoreGate/StoreGate/WriteDecorHandleKey.h:89
TruthVertexContainerFwd.h
ReadDecorHandleKey.h
Property holding a SG store/key/clid/attr name from which a ReadDecorHandle is made.
FlavorTagDiscriminants
This file contains "getter" functions used for accessing tagger inputs from the EDM.
Definition: AssociationEnums.h:11
FlavorTagDiscriminants::TruthParticleDecoratorAlg::execute
virtual StatusCode execute(const EventContext &) const override
Definition: TruthParticleDecoratorAlg.cxx:57
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_truthOriginTool
ToolHandle< InDet::InDetTrackTruthOriginTool > m_truthOriginTool
Definition: TruthParticleDecoratorAlg.h:57
SG::ReadHandleKey< xAOD::TruthParticleContainer >
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_TruthPVsKey
SG::ReadHandleKey< xAOD::TruthVertexContainer > m_TruthPVsKey
Definition: TruthParticleDecoratorAlg.h:35
AthReentrantAlgorithm
An algorithm that can be simultaneously executed in multiple threads.
Definition: AthReentrantAlgorithm.h:83
WriteDecorHandleKey.h
Property holding a SG store/key/clid/attr name from which a WriteDecorHandle is made.
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
FlavorTagDiscriminants::TruthParticleDecoratorAlg
Definition: TruthParticleDecoratorAlg.h:21
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_truthVertexMergeDistance
Gaudi::Property< float > m_truthVertexMergeDistance
Definition: TruthParticleDecoratorAlg.h:61
AthReentrantAlgorithm.h
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
FlavorTagDiscriminants::TruthParticleDecoratorAlg::TruthParticleDecoratorAlg
TruthParticleDecoratorAlg(const std::string &name, ISvcLocator *pSvcLocator)
Definition: TruthParticleDecoratorAlg.cxx:23
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_dec_source_label
SG::WriteDecorHandleKey< xAOD::TruthParticleContainer > m_dec_source_label
Definition: TruthParticleDecoratorAlg.h:46
InDetTrackTruthOriginTool.h
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_TruthContainerKey
SG::ReadHandleKey< xAOD::TruthParticleContainer > m_TruthContainerKey
Definition: TruthParticleDecoratorAlg.h:32
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_dec_type_label
SG::WriteDecorHandleKey< xAOD::TruthParticleContainer > m_dec_type_label
Definition: TruthParticleDecoratorAlg.h:43
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_dec_vertex_index
SG::WriteDecorHandleKey< xAOD::TruthParticleContainer > m_dec_vertex_index
Definition: TruthParticleDecoratorAlg.h:49
FlavorTagDiscriminants::TruthParticleDecoratorAlg::initialize
virtual StatusCode initialize() override
Definition: TruthParticleDecoratorAlg.cxx:27
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_dec_origin_label
SG::WriteDecorHandleKey< xAOD::TruthParticleContainer > m_dec_origin_label
Definition: TruthParticleDecoratorAlg.h:40
AuxElement.h
Base class for elements of a container that can have aux data.
FlavorTagDiscriminants::TruthParticleDecoratorAlg::m_dec_parent_barcode
SG::WriteDecorHandleKey< xAOD::TruthParticleContainer > m_dec_parent_barcode
Definition: TruthParticleDecoratorAlg.h:52