ATLAS Offline Software
egammaRec.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef EGAMMARECEVENT_EGAMMA_H
6 #define EGAMMARECEVENT_EGAMMA_H
7 
12 // INCLUDE HEADER FILES:
13 
14 #include "AthLinks/ElementLink.h"
15 
16 // CaloCluster include
19 
20 // TrackParticle Includes
23 
24 // Vertex Includes
25 #include "xAODTracking/Vertex.h"
27 
28 #include <array>
29 #include <vector>
30 class egammaRec
31 {
33  // Public typedefs:
35 public:
37  egammaRec() = default;
38 
40  egammaRec(const std::vector<ElementLink<xAOD::CaloClusterContainer>> &caloClusterLinks);
41 
45  egammaRec(const egammaRec&) = default;
46  egammaRec(egammaRec&&) = default;
47  egammaRec& operator=(const egammaRec&) = default;
48  egammaRec& operator=(egammaRec&&) = default;
49  ~egammaRec() = default;
50 
52  size_t getNumberOfClusters() const;
53 
55  const xAOD::CaloCluster* caloCluster(size_t index = 0) const;
56 
59 
62 
64  const std::vector<ElementLink<xAOD::CaloClusterContainer>> & caloClusterElementLinks() const;
65 
67  size_t getNumberOfTrackParticles() const;
68 
70  const xAOD::TrackParticle* trackParticle(size_t index = 0) const;
71 
74 
77 
79  const std::vector<ElementLink<xAOD::TrackParticleContainer>> & trackParticleElementLinks() const;
80 
82  size_t getNumberOfVertices() const;
83 
85  const xAOD::Vertex* vertex(size_t index = 0) const;
86 
89 
92 
94  const std::vector<ElementLink<xAOD::VertexContainer>> & vertexElementLinks() const;
95 
98 
101 
104 
105  std::array<double,4> deltaEta () const;
106 
108  std::array<double,4> deltaPhi () const;
109 
111  std::array<double,4> deltaPhiRescaled () const;
112 
114  double deltaPhiLast () const ;
115 
117  void setDeltaEta(const std::array<double, 4>& deltaEtas);
118 
120  void setDeltaPhi(const std::array<double, 4>& deltaPhis);
121 
124  void setDeltaPhiRescaled(std::array<double, 4>& deltaPhis);
125 
127  void setDeltaPhiLast(double value);
129 
132 
133  float deltaEtaVtx() const;
134 
136  float deltaPhiVtx() const;
137 
139  void setDeltaEtaVtx(float value);
140 
142  void setDeltaPhiVtx(float value);
144 
145 private:
146  std::vector<ElementLink<xAOD::CaloClusterContainer>> m_caloClusters;
147  std::vector<ElementLink<xAOD::TrackParticleContainer>> m_trackParticles;
148  std::vector<ElementLink<xAOD::VertexContainer>> m_vertices;
149 
150  std::array<double, 4> m_deltaEta {-999, -999, -999, -999};
151  std::array<double, 4> m_deltaPhi {-999, -999, -999, -999};
152  std::array<double, 4> m_deltaPhiRescaled {-999, -999, -999, -999};
153 
154  double m_deltaPhiLast = -999;
155  float m_deltaEtaVtx = -999;
156  float m_deltaPhiVtx = -999;
157 };
158 #include"egammaRec.icc"
159 #endif
160 
egammaRec::egammaRec
egammaRec(const std::vector< ElementLink< xAOD::CaloClusterContainer >> &caloClusterLinks)
Constructor which adds cluster links.
egammaRec::setCaloClusters
void setCaloClusters(const std::vector< ElementLink< xAOD::CaloClusterContainer >> &links)
set Pointer to the xAOD::CaloCluster
egammaRec::pushFrontVertex
void pushFrontVertex(const ElementLink< xAOD::VertexContainer > &vertexElementLink)
Push front another vertex.
Definition: egammaRec.cxx:82
egammaRec::setDeltaPhiLast
void setDeltaPhiLast(double value)
set deltaPhi at sampling 2 from Last track Measurement
egammaRec::vertexElementLink
ElementLink< xAOD::VertexContainer > vertexElementLink(size_t index=0) const
ElementLink to the xAOD::vertex/es that match the electron candidate.
Definition: egammaRec.cxx:63
egammaRec::getNumberOfVertices
size_t getNumberOfVertices() const
Return the number xAOD::Vertex/vertices that match the photon candidate.
egammaRec::setDeltaPhi
void setDeltaPhi(const std::array< double, 4 > &deltaPhis)
set Phi of track extrapolated at pre sampler(0) -> 3rd sampling(3)
egammaRec::caloClusterElementLink
ElementLink< xAOD::CaloClusterContainer > caloClusterElementLink(size_t index=0) const
ElementLink to the xAOD::CaloCluster/s that match the electron candidate.
Definition: egammaRec.cxx:17
egammaRec::setDeltaEta
void setDeltaEta(const std::array< double, 4 > &deltaEtas)
set deltaEta at pre sampler(0) -> 3rd sampling(3)
index
Definition: index.py:1
egammaRec::operator=
egammaRec & operator=(egammaRec &&)=default
egammaRec::caloCluster
const xAOD::CaloCluster * caloCluster(size_t index=0) const
Pointer to the xAOD::CaloCluster/s that define the electron candidate.
Definition: egammaRec.cxx:8
egammaRec.icc
athena.value
value
Definition: athena.py:122
egammaRec::deltaEta
std::array< double, 4 > deltaEta() const
deltaEta at pre sampler(0) -> 3rd sampling(3)
egammaRec::deltaPhiRescaled
std::array< double, 4 > deltaPhiRescaled() const
deltaPhi for rescaled momentum extrapolation from the perigee.
egammaRec::trackParticleElementLinks
const std::vector< ElementLink< xAOD::TrackParticleContainer > > & trackParticleElementLinks() const
Get a reference to the track particle links.
Definition: egammaRec.cxx:49
egammaRec::m_vertices
std::vector< ElementLink< xAOD::VertexContainer > > m_vertices
Definition: egammaRec.h:148
egammaRec::m_caloClusters
std::vector< ElementLink< xAOD::CaloClusterContainer > > m_caloClusters
Definition: egammaRec.h:146
egammaRec::getNumberOfClusters
size_t getNumberOfClusters() const
Return the number of xAOD::CaloClusters that define the electron candidate.
xAOD::CaloCluster_v1
Description of a calorimeter cluster.
Definition: CaloCluster_v1.h:59
egammaRec::setDeltaPhiVtx
void setDeltaPhiVtx(float value)
set deltaPhiVtx
egammaRec::deltaPhiLast
double deltaPhiLast() const
deltaPhi from Last measurement
egammaRec::caloClusterElementLinks
const std::vector< ElementLink< xAOD::CaloClusterContainer > > & caloClusterElementLinks() const
Get a reference to the calo cluster links.
Definition: egammaRec.cxx:26
CaloCluster.h
egammaRec::~egammaRec
~egammaRec()=default
DMTest::links
links
Definition: CLinks_v1.cxx:22
egammaRec::m_deltaPhiVtx
float m_deltaPhiVtx
Definition: egammaRec.h:156
egammaRec::m_deltaEta
std::array< double, 4 > m_deltaEta
Definition: egammaRec.h:150
egammaRec::pushBackVertex
void pushBackVertex(const ElementLink< xAOD::VertexContainer > &vertexElementLink)
Push back another vertex.
Definition: egammaRec.cxx:76
egammaRec::setTrackParticles
void setTrackParticles(const std::vector< ElementLink< xAOD::TrackParticleContainer >> &links)
Set the ElementLinks to the xAOD::TrackParticle/s that match the electron candidate.
egammaRec::trackParticleElementLink
ElementLink< xAOD::TrackParticleContainer > trackParticleElementLink(size_t index=0) const
ElementLink to the xAOD::TrackParticle/s that match the electron candidate.
Definition: egammaRec.cxx:40
egammaRec::deltaPhiVtx
float deltaPhiVtx() const
deltaPhiVtx
egammaRec::setVertices
void setVertices(const std::vector< ElementLink< xAOD::VertexContainer >> &links)
set Pointer to the xAOD::vertex/vertices that match the photon candidate
egammaRec::getNumberOfTrackParticles
size_t getNumberOfTrackParticles() const
Return the number xAOD::TrackParticles that match the electron candidate.
egammaRec::trackParticle
const xAOD::TrackParticle * trackParticle(size_t index=0) const
Pointer to the xAOD::TrackParticle/s that match the electron candidate.
Definition: egammaRec.cxx:31
egammaRec::deltaPhi
std::array< double, 4 > deltaPhi() const
deltaPhi at pre sampler(0) -> 3rd sampling(3)
Vertex.h
egammaRec::setDeltaEtaVtx
void setDeltaEtaVtx(float value)
set deltaEtaVtx
egammaRec::m_deltaPhiLast
double m_deltaPhiLast
Definition: egammaRec.h:154
egammaRec::m_trackParticles
std::vector< ElementLink< xAOD::TrackParticleContainer > > m_trackParticles
Definition: egammaRec.h:147
egammaRec::vertexElementLinks
const std::vector< ElementLink< xAOD::VertexContainer > > & vertexElementLinks() const
Get a reference to the vertix links.
Definition: egammaRec.cxx:71
TrackParticle.h
egammaRec::egammaRec
egammaRec(const egammaRec &)=default
Default copy/move ctor/assignment dtor.
egammaRec::egammaRec
egammaRec()=default
Default constructor implemented.
VertexContainer.h
xAOD::Vertex_v1
Class describing a Vertex.
Definition: Vertex_v1.h:42
egammaRec::vertex
const xAOD::Vertex * vertex(size_t index=0) const
Pointer to the xAOD::Vertex/es that match the photon candidate.
Definition: egammaRec.cxx:54
egammaRec::setDeltaPhiRescaled
void setDeltaPhiRescaled(std::array< double, 4 > &deltaPhis)
set deltaPhi at sampling for rescaled momentum extrapolation from the perigee.
egammaRec::egammaRec
egammaRec(egammaRec &&)=default
CaloClusterContainer.h
egammaRec::operator=
egammaRec & operator=(const egammaRec &)=default
egammaRec
Definition: egammaRec.h:31
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
egammaRec::m_deltaPhi
std::array< double, 4 > m_deltaPhi
Definition: egammaRec.h:151
egammaRec::m_deltaEtaVtx
float m_deltaEtaVtx
Definition: egammaRec.h:155
egammaRec::m_deltaPhiRescaled
std::array< double, 4 > m_deltaPhiRescaled
Definition: egammaRec.h:152
TrackParticleContainer.h
egammaRec::deltaEtaVtx
float deltaEtaVtx() const
deltaEtaVtx