ATLAS Offline Software
MuonTrackSummary.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TRK_MUONTRACKSUMMARY_H
6 #define TRK_MUONTRACKSUMMARY_H
7 
8 #include "Identifier/Identifier.h"
9 
10 class MsgStream;
13 class TrackSummaryCnv_p2;
14 
15 namespace Muon {
16 class MuonTrackSummaryHelperTool;
17 }
18 
19 namespace Trk {
20 
26 {
27 public:
29 
32  {
34 
37  struct Projection
38  {
40  int nhits{ 0 }; //<! number of hits on track in the projection
41  int nholes{ 0 }; //<! number of holes in the projection
42  int noutliers{ 0 }; //<! number of outliers in the projection
43  int ndeltas{ 0 }; //<! number of delta electrons in the projection (only filled for MDT chambers)
44  int ncloseHits{ 0 }; //<! number of hits within a road around the track in the projection
45  int ngoodHits{ 0 }; //<! number of hits that matter for the track
46  int noutBounds{ 0 }; //<! number of out-of-bounds hits
47  };
48 
52  ChamberHitSummary(Identifier chID, bool isMdtTube)
53  : m_chId(chID)
54  , m_isMdt(isMdtTube)
55  {}
56 
58  const Identifier& chamberId() const { return m_chId; }
59 
61  bool isMdt() const { return m_isMdt; }
62 
64  int nhits() const { return m_first.nhits + m_second.nhits; }
65 
67  int nholes() const { return m_first.nholes + m_second.nholes; }
68 
70  int noutliers() const { return m_first.noutliers + m_second.noutliers; }
71 
73  int ndeltas() const { return m_first.ndeltas + m_second.ndeltas; }
74 
76  int ncloseHits() const { return m_first.ncloseHits + m_second.ncloseHits; }
77 
79  int ngoodHits() const { return m_first.ngoodHits + m_second.ngoodHits; }
80 
81  // returns the number of out of bounds hits
83 
85  int netaHits() const { return isMdt() ? nhits() : m_first.nhits; }
86 
88  int nphiHits() const { return isMdt() ? 0 : m_second.nhits; }
89 
91  int nMdtHitsMl1() const { return isMdt() ? m_first.nhits : 0; }
92 
94  int nMdtHitsMl2() const { return isMdt() ? m_second.nhits : 0; }
95 
97  const Projection& mdtMl1() const { return m_first; }
98 
100  const Projection& mdtMl2() const { return m_second; }
101 
103  const Projection& etaProjection() const { return m_first; }
104 
106  const Projection& phiProjection() const { return m_second; }
107 
108  private:
109  friend class ::MuonTrackSummaryCnv_p1;
110  friend class ::MuonTrackSummaryCnv_p2;
111  friend class ::TrackSummaryCnv_p2;
112 
113  Identifier m_chId{ 0 }; //<! chamber identifier
114  bool m_isMdt{ false }; //<! is this a MDT chamber
115 
116  Projection m_first; //<! eta projections for cluster chambers, first multi layer for mdt chambers
117  Projection m_second; //<! phi projections for cluster chambers, first multi layer for mdt chambers
118  };
119 
122 
125 
127  unsigned int netaHits() const;
128 
130  unsigned int nphiHits() const;
131 
133  unsigned int noutliers() const;
134 
136  unsigned int nholes() const;
137 
139  unsigned int ncloseHits() const;
140 
142  unsigned int nscatterers() const { return m_nscatterers; }
143 
145  unsigned int npseudoMeasurements() const { return m_npseudoMeasurements; }
146 
148  const std::vector<ChamberHitSummary>& chamberHitSummary() const { return m_chamberHitSummary; }
149 
150 private:
151  friend class ::MuonTrackSummaryCnv_p1;
152  friend class ::MuonTrackSummaryCnv_p2;
153  friend class ::TrackSummaryCnv_p2;
154 
155  unsigned int m_nscatterers; //<! number of scattering centres on the track
156  unsigned int m_npseudoMeasurements; //<! number of pseudomeasurements on the track
157  std::vector<ChamberHitSummary> m_chamberHitSummary; //<! vector with chamber hit summaries
158 };
159 
161 MsgStream&
162 operator<<(MsgStream& out, const MuonTrackSummary& trackSum);
163 
165 std::ostream&
166 operator<<(std::ostream& out, const MuonTrackSummary& trackSum);
167 
168 }
169 #endif
Trk::MuonTrackSummary::ChamberHitSummary::phiProjection
const Projection & phiProjection() const
access to the data of the phi projection, users have to check whether this is NOT a MDT chamber first...
Definition: MuonTrackSummary.h:106
Trk::MuonTrackSummary::ChamberHitSummary::noutBoundsHits
int noutBoundsHits() const
Definition: MuonTrackSummary.h:82
Trk::MuonTrackSummary::ChamberHitSummary::noutliers
int noutliers() const
returns the total number of outliers in the chamber
Definition: MuonTrackSummary.h:70
Trk::MuonTrackSummary::ChamberHitSummary::ncloseHits
int ncloseHits() const
returns the total number of close hits in the chamber
Definition: MuonTrackSummary.h:76
Trk::MuonTrackSummary::ChamberHitSummary::chamberId
const Identifier & chamberId() const
returns the chamber identifier
Definition: MuonTrackSummary.h:58
Trk::MuonTrackSummary::ChamberHitSummary::ndeltas
int ndeltas() const
returns the total number of delta electrons in the chamber
Definition: MuonTrackSummary.h:73
Trk::MuonTrackSummary::ChamberHitSummary::isMdt
bool isMdt() const
returns whether this is a MDT chamber
Definition: MuonTrackSummary.h:61
Trk::MuonTrackSummary::m_npseudoMeasurements
unsigned int m_npseudoMeasurements
Definition: MuonTrackSummary.h:156
python.AthDsoLogger.out
out
Definition: AthDsoLogger.py:71
Trk::MuonTrackSummary::ChamberHitSummary::m_second
Projection m_second
Definition: MuonTrackSummary.h:117
Trk::MuonTrackSummary::nscatterers
unsigned int nscatterers() const
number of scattering centres on the track
Definition: MuonTrackSummary.h:142
Trk::MuonTrackSummary::ChamberHitSummary::Projection::noutBounds
int noutBounds
Definition: MuonTrackSummary.h:46
Trk::MuonTrackSummary::netaHits
unsigned int netaHits() const
number of eta hits on the track
Definition: MuonTrackSummary.cxx:18
Trk::MuonTrackSummary::ChamberHitSummary::ngoodHits
int ngoodHits() const
returns the number of non-deweighted hits in the chamber
Definition: MuonTrackSummary.h:79
Muon
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition: TrackSystemController.h:45
Trk::MuonTrackSummary::ChamberHitSummary::Projection::nhits
int nhits
Definition: MuonTrackSummary.h:40
Trk::MuonTrackSummary::ChamberHitSummary::m_chId
Identifier m_chId
Definition: MuonTrackSummary.h:113
Trk::MuonTrackSummary::ChamberHitSummary::Projection::nholes
int nholes
Definition: MuonTrackSummary.h:41
Trk::MuonTrackSummary::ChamberHitSummary::Projection::ncloseHits
int ncloseHits
Definition: MuonTrackSummary.h:44
Trk::MuonTrackSummary::ChamberHitSummary::nholes
int nholes() const
returns the total number of holes in the chamber
Definition: MuonTrackSummary.h:67
Trk::MuonTrackSummary::ChamberHitSummary
structure to hold information per chamber in the muon system
Definition: MuonTrackSummary.h:32
Trk::MuonTrackSummary::m_chamberHitSummary
std::vector< ChamberHitSummary > m_chamberHitSummary
Definition: MuonTrackSummary.h:157
Trk::MuonTrackSummary::m_nscatterers
unsigned int m_nscatterers
Definition: MuonTrackSummary.h:155
Trk::MuonTrackSummary::chamberHitSummary
const std::vector< ChamberHitSummary > & chamberHitSummary() const
access to the vector of chamber hit summaries on the track
Definition: MuonTrackSummary.h:148
Trk::MuonTrackSummary::ChamberHitSummary::m_first
Projection m_first
Definition: MuonTrackSummary.h:116
Trk::MuonTrackSummary::ChamberHitSummary::nhits
int nhits() const
returns the total number of hits on track in the chamber
Definition: MuonTrackSummary.h:64
Trk::MuonTrackSummary::ChamberHitSummary::netaHits
int netaHits() const
returns the total number of eta hits on track in the chamber
Definition: MuonTrackSummary.h:85
Trk::MuonTrackSummary::ChamberHitSummary::mdtMl2
const Projection & mdtMl2() const
access to the data of the second MDT multi layer, users have to check whether this is a MDT chamber f...
Definition: MuonTrackSummary.h:100
Trk::MuonTrackSummary::ChamberHitSummary::Projection::ndeltas
int ndeltas
Definition: MuonTrackSummary.h:43
Trk::MuonTrackSummary::ChamberHitSummary::Projection::noutliers
int noutliers
Definition: MuonTrackSummary.h:42
Trk::MuonTrackSummary::nholes
unsigned int nholes() const
number of holes on the track
Definition: MuonTrackSummary.cxx:45
MuonTrackSummaryCnv_p1
Definition: MuonTrackSummaryCnv_p1.h:16
Trk::MuonTrackSummary
Detailed track summary for the muon system Give access to hit counts per chamber.
Definition: MuonTrackSummary.h:26
Trk::MuonTrackSummary::ChamberHitSummary::nMdtHitsMl1
int nMdtHitsMl1() const
returns the total number of MDT hits on track in the first multi layer
Definition: MuonTrackSummary.h:91
Trk::MuonTrackSummary::ChamberHitSummary::m_isMdt
bool m_isMdt
Definition: MuonTrackSummary.h:114
Trk::MuonTrackSummary::ChamberHitSummary::Projection::Projection
Projection()
Definition: MuonTrackSummary.h:39
Trk::MuonTrackSummary::ChamberHitSummary::nMdtHitsMl2
int nMdtHitsMl2() const
returns the total number of MDT hits on track in the second multi layer
Definition: MuonTrackSummary.h:94
Trk::MuonTrackSummary::~MuonTrackSummary
~MuonTrackSummary()
destructor
Trk::MuonTrackSummary::ChamberHitSummary::etaProjection
const Projection & etaProjection() const
access to the data of the eta projection, users have to check whether this is NOT a MDT chamber first...
Definition: MuonTrackSummary.h:103
Trk::MuonTrackSummary::ChamberHitSummary::mdtMl1
const Projection & mdtMl1() const
access to the data of the first MDT multi layer, users have to check whether this is a MDT chamber fi...
Definition: MuonTrackSummary.h:97
Trk::MuonTrackSummary::ChamberHitSummary::nphiHits
int nphiHits() const
returns the total number of phi hits on track in the chamber
Definition: MuonTrackSummary.h:88
Trk::MuonTrackSummary::ChamberHitSummary::ChamberHitSummary
ChamberHitSummary(Identifier chID, bool isMdtTube)
constructor taking the Identifier of the chamber and a boolean whether we are dealing with a MDT cham...
Definition: MuonTrackSummary.h:52
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
Muon::MuonTrackSummaryHelperTool
Definition: MuonTrackSummaryHelperTool.h:39
Trk::MuonTrackSummary::MuonTrackSummary
MuonTrackSummary()
default constructor
Definition: MuonTrackSummary.cxx:10
Trk::MuonTrackSummary::nphiHits
unsigned int nphiHits() const
number of phi hits on the track
Definition: MuonTrackSummary.cxx:32
Trk::MuonTrackSummary::noutliers
unsigned int noutliers() const
number of eta trigger hits on the track
Definition: MuonTrackSummary.cxx:58
MuonTrackSummaryCnv_p2
Definition: MuonTrackSummaryCnv_p2.h:16
Trk::MuonTrackSummary::ncloseHits
unsigned int ncloseHits() const
number of holes on the track
Definition: MuonTrackSummary.cxx:71
Trk::MuonTrackSummary::ChamberHitSummary::Projection::ngoodHits
int ngoodHits
Definition: MuonTrackSummary.h:45
Trk::operator<<
MsgStream & operator<<(MsgStream &sl, const AlignModule &alignModule)
overload of << operator for MsgStream for debug output
Definition: AlignModule.cxx:204
TrackSummaryCnv_p2
Definition: TrackSummaryCnv_p2.h:15
Trk::MuonTrackSummary::ChamberHitSummary::Projection
structure to hold the information for the eta/phi projection of RPC, TGC and CSC chambers and per mul...
Definition: MuonTrackSummary.h:38
Trk::MuonTrackSummary::npseudoMeasurements
unsigned int npseudoMeasurements() const
number of pseudo measurements on the track
Definition: MuonTrackSummary.h:145
Identifier
Definition: IdentifierFieldParser.cxx:14