ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
Trigger
TrigMonitoring
TrigIDR4Monitoring
src
SiHitPlots.h
Go to the documentation of this file.
1
/* emacs: this is -*- c++ -*- */
22
23
24
#ifndef IDTPM2_SIHITPLOTS_H
25
#define IDTPM2_SIHITPLOTS_H
26
27
#include "
IPlotBase.h
"
28
35
36
#define HIT_PARAMS(X) \
37
X(NInnerMostPixelHits) \
38
X(NInnerMostPixelEndcapHits) \
39
X(NNextToInnerMostPixelHits) \
40
X(NNextToInnerMostPixelEndcapHits) \
41
X(NInnerMostPixelSharedHits) \
42
X(NInnerMostPixelSharedEndcapHits) \
43
X(NPixelHits) \
44
X(NPixelHoles) \
45
X(NPixelSharedHits) \
46
X(NPixeldEdx) \
47
X(NSCTHits) \
48
X(NSCTHoles) \
49
X(NSCTSharedHits) \
50
\
51
X(NInnerMostPixelOutliers) \
52
X(NInnerMostPixelEndcapOutliers) \
53
X(NInnerMostPixelSplitHits) \
54
X(NInnerMostPixelSplitEndcapHits) \
55
X(NExpectedInnerMostPixelHits) \
56
X(NExpectedNextToInnerMostPixelHits) \
57
X(NPixelOutliers) \
58
X(NPixelContribLayers) \
59
X(NPixelSplitHits) \
60
X(NPixelGangedHits) \
61
X(NPixelGangedHitsFlaggedFakes) \
62
X(NPixelDeadSensors) \
63
X(NSCTOutliers) \
64
X(NSCTDoubleHoles) \
65
X(NSCTDeadSensors)
66
67
68
namespace
IDTPM2
{
69
70
class
SiHitPlots
:
public
IPlotBase
{
71
72
public
:
73
74
SiHitPlots
(
const
std::string&
name
, ToolHandle<GenericMonitoringTool>* m );
75
76
virtual
~SiHitPlots
() { }
77
78
void
initialize
();
79
80
void
execute
(
const
TrackAnalysisStore
& collections )
const
;
81
83
void
finalize
();
84
85
private
:
86
90
92
93
struct
Histograms
{
94
97
100
101
enum
HitPar
{
102
# define X(x) x,
103
HIT_PARAMS
(
X
)
104
# undef X
105
NHitPars
106
};
107
109
std::vector<std::string>
m_hitParNames
= {
110
# define X(x) #x,
111
HIT_PARAMS
(
X
)
112
# undef X
113
};
114
115
size_t
nHitParNames
()
const
{
return
m_hitParNames
.size(); }
116
117
const
std::string&
hitParName
(
int
i)
const
{
return
m_hitParNames
.at(i); }
118
119
void
initialize
(
SiHitPlots
* p,
const
std::string& s=
""
);
120
121
void
fill
(
const
TrackView
* t )
const
;
122
123
#if 1
125
126
TIDA::Histogram<float>
m_hits
[
NHitPars
];
127
132
133
TIDA::Histogram<float>
m_hits_vs_pt
[
NHitPars
];
134
TIDA::Histogram<float>
m_hits_vs_eta
[
NHitPars
];
135
TIDA::Histogram<float>
m_hits_vs_phi
[
NHitPars
];
136
TIDA::Histogram<float>
m_hits_vs_d0
[
NHitPars
];
137
138
#else
139
144
145
# define X(x) TIDA::Histogram<float> m_##x;
146
HIT_PARAMS
(
X
)
147
# undef X
148
149
# define X(x) TIDA::Histogram2D<float> m_##x##_vs_pt;
150
HIT_PARAMS
(
X
)
151
# undef X
152
153
# define X(x) TIDA::Histogram2D<float> m_##x##_vs_eta;
154
HIT_PARAMS
(
X
)
155
# undef X
156
157
# define X(x) TIDA::Histogram2D<float> m_##x##_vs_phi;
158
HIT_PARAMS
(
X
)
159
# undef X
160
161
# define X(x) TIDA::Histogram2D<float> m_##x##_vs_d0;
162
HIT_PARAMS
(
X
)
163
# undef X
164
165
#endif
166
167
};
168
169
private
:
170
174
175
Histograms
m_reference
;
176
Histograms
m_test
;
177
178
};
179
180
}
// namespace IDTPM2
181
182
183
inline
std::ostream&
operator<<
( std::ostream& s,
const
IDTPM2::SiHitPlots
& ) {
184
return
s;
185
}
186
187
188
#endif
// IDTPM2_SIHITPLOTS_H
189
190
191
192
193
194
195
196
197
198
IPlotBase.h
operator<<
std::ostream & operator<<(std::ostream &s, const IDTPM2::SiHitPlots &)
Definition
SiHitPlots.h:183
X
#define X(x)
Definition
SiHitPlots.h:102
HIT_PARAMS
#define HIT_PARAMS(X)
all these enums for all the histograms are really nasty and the names for them, and making sure they ...
Definition
SiHitPlots.h:36
IDTPM2::IPlotBase::name
const std::string & name() const
generic utilities, just in case
Definition
IPlotBase.h:68
IDTPM2::IPlotBase::IPlotBase
IPlotBase(const std::string &name, ToolHandle< GenericMonitoringTool > *m=0)
built from dirName and anaTag
Definition
IPlotBase.h:41
IDTPM2::SiHitPlots
Definition
SiHitPlots.h:70
IDTPM2::SiHitPlots::finalize
void finalize()
Print out final stats on histograms.
Definition
SiHitPlots.cxx:207
IDTPM2::SiHitPlots::initialize
void initialize()
Definition
SiHitPlots.cxx:26
IDTPM2::SiHitPlots::~SiHitPlots
virtual ~SiHitPlots()
Definition
SiHitPlots.h:76
IDTPM2::SiHitPlots::m_test
Histograms m_test
Definition
SiHitPlots.h:176
IDTPM2::SiHitPlots::m_reference
Histograms m_reference
actual class histogram sets - this avoid needlessly duplicating all the histograms with _ref,...
Definition
SiHitPlots.h:175
IDTPM2::SiHitPlots::SiHitPlots
SiHitPlots(const std::string &name, ToolHandle< GenericMonitoringTool > *m)
Definition
SiHitPlots.cxx:15
IDTPM2::SiHitPlots::execute
void execute(const TrackAnalysisStore &collections) const
this can be over ridden if need be
Definition
SiHitPlots.cxx:180
IDTPM2::TrackAnalysisStore
Definition
TrackAnalysisStore.h:78
TIDA::Histogram
Definition
TIDAHistogram.h:56
TrackView
forward declaration required for function prototype
Definition
TrackView.h:43
IDTPM2
Search the ancestor history, looking for an ancestor that satifies the predicate ....
Definition
AnalysisR4.h:31
IDTPM2::SiHitPlots::Histograms
oh dear, just the (too many!) histogram variables (we will need these for the test and reference,...
Definition
SiHitPlots.h:93
IDTPM2::SiHitPlots::Histograms::nHitParNames
size_t nHitParNames() const
Definition
SiHitPlots.h:115
IDTPM2::SiHitPlots::Histograms::m_hits_vs_d0
TIDA::Histogram< float > m_hits_vs_d0[NHitPars]
Definition
SiHitPlots.h:136
IDTPM2::SiHitPlots::Histograms::m_hits_vs_phi
TIDA::Histogram< float > m_hits_vs_phi[NHitPars]
Definition
SiHitPlots.h:135
IDTPM2::SiHitPlots::Histograms::hitParName
const std::string & hitParName(int i) const
Definition
SiHitPlots.h:117
IDTPM2::SiHitPlots::Histograms::m_hits_vs_pt
TIDA::Histogram< float > m_hits_vs_pt[NHitPars]
for theis "2D" histograms, could use yet another enum, and some parname vector, but prefer to keep it...
Definition
SiHitPlots.h:133
IDTPM2::SiHitPlots::Histograms::HitPar
HitPar
ugly, but it gets the jobs done - this is the price you pay for have SO MANY STUPIDLY LONG NAMED PARA...
Definition
SiHitPlots.h:101
IDTPM2::SiHitPlots::Histograms::NHitPars
@ NHitPars
Definition
SiHitPlots.h:105
IDTPM2::SiHitPlots::Histograms::m_hitParNames
std::vector< std::string > m_hitParNames
probably should use an std::array<string,NparNames>
Definition
SiHitPlots.h:109
IDTPM2::SiHitPlots::Histograms::fill
void fill(const TrackView *t) const
Definition
SiHitPlots.cxx:57
IDTPM2::SiHitPlots::Histograms::m_hits
TIDA::Histogram< float > m_hits[NHitPars]
actual stored histograms
Definition
SiHitPlots.h:126
IDTPM2::SiHitPlots::Histograms::m_hits_vs_eta
TIDA::Histogram< float > m_hits_vs_eta[NHitPars]
Definition
SiHitPlots.h:134
Generated on
for ATLAS Offline Software by
1.17.0