test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
CaloParams.h
Go to the documentation of this file.
1 
12 #ifndef CaloParams_h
13 #define CaloParams_h
14 
15 #include <memory>
16 #include <iostream>
17 #include <vector>
18 #include <cmath>
19 
22 
23 namespace l1t {
24 
25 
26  class CaloParams {
27 
28  public:
29 
30  enum { Version = 1 };
31 
32  class Node {
33  public:
35  unsigned version_;
37  std::vector<double> dparams_;
38  std::vector<unsigned> uparams_;
39  std::vector<int> iparams_;
40  std::vector<std::string> sparams_;
41  Node(){ type_="unspecified"; version_=1; }
43  };
44 
45  class TowerParams{
46  public:
47  /* Towers */
48 
49  // LSB of HCAL scale
50  double lsbH_;
51 
52  // LSB of ECAL scale
53  double lsbE_;
54 
55  // LSB of ECAL+HCAL sum scale
56  double lsbSum_;
57 
58  // number of bits for HCAL encoding
59  int nBitsH_;
60 
61  // number of bits for ECAL encoding
62  int nBitsE_;
63 
64  // number of bits for ECAL+HCAL sum encoding
65  int nBitsSum_;
66 
67  // number of bits for ECAL/HCAL ratio encoding
69 
70  // bitmask for storing HCAL Et in object
71  int maskH_;
72 
73  // bitmask for storing ECAL ET in object
74  int maskE_;
75 
76  // bitmask for storing ECAL+HCAL sum in object
77  int maskSum_;
78 
79  // bitmask for storing ECAL/HCAL ratio in object
81 
82  // turn encoding on/off
84 
85  TowerParams() : lsbH_(0), lsbE_(0), lsbSum_(0),
86  nBitsH_(0), nBitsE_(0), nBitsSum_(0), nBitsRatio_(0),
87  maskH_(0), maskE_(0), maskSum_(0), maskRatio_(0),
89  { /* no-op */}
90 
92  };
93 
94  class EgParams {
95  public:
96  // EG LSB
97  double lsb_;
98 
99  // Et threshold on EG seed tower
101 
102  // Et threshold on EG neighbour tower(s)
104 
105  // Et threshold on HCAL for H/E computation
107 
108  // EG maximum value of HCAL Et
109  double maxHcalEt_;
110 
111  // Et threshold to remove the H/E cut from the EGammas
112  double maxPtHOverE_;
113 
114  // Range of jet isolation for EG (in rank!) (Stage1Layer2)
117 
118  // Range of 3x3 HoE isolation for EG (in rank!) (Stage1Layer2)
121 
122  // isolation area in eta is seed tower +/- <=egIsoAreaNrTowersPhi
124 
125  // isolation area in phi is seed tower +/- <=egIsoAreaNrTowersPhi
127 
128  // veto region is seed tower +/- <=egIsoVetoNrTowersPhi
130 
134  { /* no-op */ }
135 
137  };
138 
139 
140  class TauParams {
141  public:
142  // Tau LSB
143  double lsb_;
144 
145  // Et threshold on tau seed tower
147 
148  // Et threshold on tau neighbour towers
150 
151  // Et limit when to switch off tau veto requirement
153 
154  // Et limit when to switch off tau isolation requirement
156 
157  // Et jet isolation limit for Taus (Stage1Layer2)
159 
160  // Relative jet isolation cut for Taus (Stage1Layer2)
162 
163  // Eta min and max for Iso-Tau collections (Stage1Layer2)
166 
167  // isolation area in eta is seed tower +/- <=tauIsoAreaNrTowersEta
169 
170  // isolation area in phi is seed tower +/- <=tauIsoAreaNrTowersPhi
172 
173  // veto region is seed tower +/- <=tauIsoVetoNrTowersPhi
175 
178  isoEtaMin_(0), isoEtaMax_(0),
180  { /* no-op */ }
181 
183  };
184 
185  class JetParams {
186  public:
187  // Jet LSB
188  double lsb_;
189 
190  // Et threshold on jet seed tower/region
192 
193  // Et threshold on neighbouring towers/regions
195 
196  JetParams() : lsb_(0), seedThreshold_(0), neighbourThreshold_(0) { /* no-op */ }
197 
199  };
200 
201 
202  // DO NOT ADD ENTRIES ANYWHERE BUT DIRECTLY BEFORE "NUM_CALOPARAMNODES"
203  enum { regionPUS=0,
210  };
211 
214 
215  // print parameters to stream:
216  void print(std::ostream&) const;
217  friend std::ostream& operator<<(std::ostream& o, const CaloParams & p) { p.print(o); return o; }
218 
219  protected:
220  unsigned version_;
221 
222  std::vector<Node> pnode_;
223 
225 
226  // Region LSB
227  double regionLsb_;
228 
232 
233  /* Sums */
234 
235  // EtSum LSB
236  double etSumLsb_;
237 
238  // minimum eta for EtSums (index is particular EtSum. ETT=1, HTT=2, MET=3, MHT=4, other values reserved).
239  std::vector<int> etSumEtaMin_;
240 
241  // maximum eta for EtSums (index is particular EtSum. ETT=1, HTT=2, MET=3, MHT=4, other values reserved).
242  std::vector<int> etSumEtaMax_;
243 
244  // minimum eta for EtSums (index is particular EtSum. ETT=1, HTT=2, MET=3, MHT=4, other values reserved).
245  std::vector<double> etSumEtThreshold_;
246 
247 
249  };
250 
251 }// namespace
252 #endif
std::string type_
Definition: CaloParams.h:34
EgParams egp_
Definition: CaloParams.h:229
void print(std::ostream &) const
std::vector< double > etSumEtThreshold_
Definition: CaloParams.h:245
std::vector< Node > pnode_
Definition: CaloParams.h:222
TowerParams towerp_
Definition: CaloParams.h:224
double regionLsb_
Definition: CaloParams.h:227
std::vector< double > dparams_
Definition: CaloParams.h:37
std::vector< int > etSumEtaMin_
Definition: CaloParams.h:239
std::vector< std::string > sparams_
Definition: CaloParams.h:40
JetParams jetp_
Definition: CaloParams.h:231
std::vector< int > etSumEtaMax_
Definition: CaloParams.h:242
unsigned version_
Definition: CaloParams.h:220
std::vector< unsigned > uparams_
Definition: CaloParams.h:38
Definition: LUT.h:29
TauParams taup_
Definition: CaloParams.h:230
double etSumLsb_
Definition: CaloParams.h:236
#define COND_SERIALIZABLE
Definition: Serializable.h:37
std::vector< int > iparams_
Definition: CaloParams.h:39
volatile std::atomic< bool > shutdown_flag false
friend std::ostream & operator<<(std::ostream &o, const CaloParams &p)
Definition: CaloParams.h:217