Analysis Software
Documentation for
sPHENIX
simulation software
Home page
Related Pages
Modules
Namespaces
Classes
Files
Examples
External Links
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
Pages
QAG4SimulationJet.h
Go to the documentation of this file.
Or view
the newest version in sPHENIX GitHub for file QAG4SimulationJet.h
1
#ifndef QA_QAG4SIMULATIONJET_H
2
#define QA_QAG4SIMULATIONJET_H
3
4
#include <
fun4all/SubsysReco.h
>
5
6
#include <TString.h>
7
8
#include <cstdint>
9
#include <map>
10
#include <memory>
11
#include <set>
12
#include <string>
13
#include <utility>
// std::pair, std::make_pair
14
15
class
JetEvalStack
;
16
class
JetTruthEval
;
17
class
Jet
;
18
class
PHCompositeNode
;
19
21
class
QAG4SimulationJet
:
public
SubsysReco
22
{
23
public
:
24
enum
enu_flags
25
{
27
kProcessTruthSpectrum
= 1 << 1,
28
30
kProcessRecoSpectrum
= 1 << 2,
31
33
kProcessTruthMatching
= 1 << 3,
34
36
kDefaultFlag
=
kProcessTruthSpectrum
|
kProcessRecoSpectrum
|
kProcessTruthMatching
37
};
38
39
QAG4SimulationJet
(
const
std::string
&truth_jet,
enu_flags
flags =
40
kDefaultFlag
);
41
virtual
~QAG4SimulationJet
() {}
42
45
int
add_reco_jet
(
const
std::string
&reco_jet)
46
{
47
_reco_jets
.insert(reco_jet);
48
return
_reco_jets
.size();
49
}
50
51
uint32_t
52
get_flags
()
const
53
{
54
return
_flags
;
55
}
56
57
void
58
set_flags
(
enu_flags
flags)
59
{
60
_flags
= (uint32_t) flags;
61
}
62
63
void
64
set_flag
(
enu_flags
flag
)
65
{
66
_flags
|= (uint32_t) flag;
67
}
68
69
bool
70
flag
(
enu_flags
flag
)
71
{
72
return
_flags
&
flag
;
73
}
74
75
void
76
reset_flag
(
enu_flags
flag
)
77
{
78
_flags
&= ~(uint32_t) flag;
79
}
80
82
double
83
get_jet_match_dE_Ratio
()
const
84
{
85
return
_jet_match_dE_Ratio
;
86
}
87
89
void
90
set_jet_match_dE_Ratio
(
double
jetMatchDERatio)
91
{
92
_jet_match_dE_Ratio
= jetMatchDERatio;
93
}
94
96
double
97
get_jet_match_dEta
()
const
98
{
99
return
_jet_match_dEta
;
100
}
101
103
void
104
set_jet_match_dEta
(
double
jetMatchDEta)
105
{
106
_jet_match_dEta
= jetMatchDEta;
107
}
108
110
double
111
get_jet_match_dPhi
()
const
112
{
113
return
_jet_match_dPhi
;
114
}
115
117
void
118
set_jet_match_dPhi
(
double
jetMatchDPhi)
119
{
120
_jet_match_dPhi
= jetMatchDPhi;
121
}
122
124
void
125
set_eta_range
(
double
low,
double
high);
126
127
int
Init
(
PHCompositeNode
*topNode);
128
int
InitRun
(
PHCompositeNode
*topNode);
129
int
process_event
(
PHCompositeNode
*topNode);
130
131
private
:
132
int
Init_Spectrum
(
PHCompositeNode
*topNode,
const
std::string
&jet_name);
133
int
process_Spectrum
(
PHCompositeNode
*topNode,
const
std::string
&jet_name,
const
bool
is_reco_jet);
134
135
int
Init_TruthMatching
(
PHCompositeNode
*topNode,
const
std::string
&reco_jet_name);
136
int
process_TruthMatching
(
PHCompositeNode
*topNode,
137
const
std::string
&reco_jet_name);
138
140
std::string
141
get_histo_prefix
(
const
std::string
&src_jet_name =
""
,
142
const
std::string
&reco_jet_name =
""
);
143
145
typedef
std::map<std::string, std::shared_ptr<JetEvalStack>>
jetevalstacks_map
;
146
jetevalstacks_map
_jetevalstacks
;
147
std::shared_ptr<JetTruthEval>
_jettrutheval
;
148
150
std::string
_truth_jet
;
151
153
std::set<std::string>
_reco_jets
;
154
155
uint32_t
_flags
;
156
158
std::pair<double, double>
eta_range
;
159
162
TString
163
get_eta_range_str
(
const
char
*eta_name =
"#eta_{Jet}"
)
const
;
164
166
bool
167
jet_acceptance_cut
(
const
Jet
*jet)
const
;
168
170
double
_jet_match_dEta
;
171
173
double
_jet_match_dPhi
;
174
176
double
_jet_match_dE_Ratio
;
177
};
178
179
#endif // QA_QAG4SIMULATIONJET_H
coresoftware
blob
master
offline
QA
modules
QAG4SimulationJet.h
Built by
Jin Huang
. updated:
Sat Feb 17 2024 22:18:11
using
1.8.2 with
sPHENIX GitHub integration