ATLAS Offline Software
ITruthClassificationTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef ITRUTHCLASSIFICATIONTOOL_H_
6 #define ITRUTHCLASSIFICATIONTOOL_H_
7 
8 #include <iostream>
9 #include <type_traits>
10 
12 #include <xAODBase/IParticle.h>
13 
14 
15 namespace Truth
16 {
17 
19 enum class Type {
20  Unknown,
24  PromptMuon,
27  TauDecay,
33  TauDecayLike = 70,
34  BHadronDecayLike = 80,
35  CHadronDecayLike = 90,
36 };
37 
38 } // namespace Truth
39 
40 inline std::ostream &operator<<(std::ostream &os, const Truth::Type &obj)
41 {
43  return os;
44 }
45 
46 
47 
55 {
57 
58 public:
59  virtual ~ITruthClassificationTool() = default;
60 
64  unsigned int &classification) const = 0;
65 
68  Truth::Type &classification) const = 0;
69 };
70 
71 #endif // ITRUTHCLASSIFICATIONTOOL_H_
Truth::Type::IsoElectron
@ IsoElectron
Trk::ParticleSwitcher::particle
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:76
IParticle.h
Truth::Type::LightFlavorDecay
@ LightFlavorDecay
Truth::Type::TauDecayLike
@ TauDecayLike
operator<<
std::ostream & operator<<(std::ostream &os, const Truth::Type &obj)
Definition: ITruthClassificationTool.h:40
ITruthClassificationTool
a tool interface to classify particles into multiple categories based on their truth information
Definition: ITruthClassificationTool.h:55
xAOD::IParticle
Class providing the definition of the 4-vector interface.
Definition: Event/xAOD/xAODBase/xAODBase/IParticle.h:40
Truth::Type::CHadronDecay
@ CHadronDecay
Truth::Type::BHadronDecayLike
@ BHadronDecayLike
ITruthClassificationTool::~ITruthClassificationTool
virtual ~ITruthClassificationTool()=default
Truth
Definition: ITruthClassificationTool.h:16
Truth::Type::TauDecay
@ TauDecay
Truth::Type::Unknown
@ Unknown
Truth::Type::ChargeFlipIsoElectron
@ ChargeFlipIsoElectron
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ITruthClassificationTool::classify
virtual StatusCode classify(const xAOD::IParticle &particle, unsigned int &classification) const =0
classify and return unsigned int re-declaration needed due to the same name used
ITruthClassificationTool::classify
virtual StatusCode classify(const xAOD::IParticle &particle, Truth::Type &classification) const =0
classify and return Truth::Type
ASG_TOOL_INTERFACE
#define ASG_TOOL_INTERFACE(CLASSNAME)
Definition: AsgToolMacros.h:40
xAODType
Definition: ObjectType.h:13
ReadFromCoolCompare.os
os
Definition: ReadFromCoolCompare.py:231
Truth::Type::PromptPhotonConversion
@ PromptPhotonConversion
Truth::Type::BHadronDecay
@ BHadronDecay
Truth::Type::NonMuonlike
@ NonMuonlike
Truth::Type::KnownUnknown
@ KnownUnknown
Truth::Type::ElectronFromMuon
@ ElectronFromMuon
Truth::Type::CHadronDecayLike
@ CHadronDecayLike
IClassificationTool.h
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
python.PyAthena.obj
obj
Definition: PyAthena.py:135
Truth::Type::ChargeFlipMuon
@ ChargeFlipMuon
CP::IClassificationTool
a tool interface to classify particles into multiple categories by assigning them an unsigned integer
Definition: IClassificationTool.h:20
Truth::Type::PromptMuon
@ PromptMuon
Truth::Type
Type
truth classification type enum
Definition: ITruthClassificationTool.h:19