CMS 3D CMS Logo

LumiScalers.h
Go to the documentation of this file.
1 /*
2  * File: DataFormats/Scalers/interface/LumiScalers.h (W.Badgett)
3  *
4  * Various Luminosity Scalers from the HF Lumi System
5  *
6  */
7 
8 #ifndef DATAFORMATS_SCALERS_LUMISCALERS_H
9 #define DATAFORMATS_SCALERS_LUMISCALERS_H
10 
12 
13 #include <ctime>
14 #include <iosfwd>
15 #include <vector>
16 #include <string>
17 
26 
30 {
31  public:
32 
33  LumiScalers();
34  LumiScalers(const unsigned char * rawData);
35  virtual ~LumiScalers();
36 
37  enum
38  {
39  nOcc = 2
40  };
41 
43  std::string name() const { return "LumiScalers"; }
44 
46  bool empty() const { return false; }
47 
48  unsigned int trigType() const { return(trigType_);}
49  unsigned int eventID() const { return(eventID_);}
50  unsigned int sourceID() const { return(sourceID_);}
51  unsigned int bunchNumber() const { return(bunchNumber_);}
52 
53  int version() const { return(version_);}
54  timespec collectionTime() const { return(collectionTime_.get_timespec());}
55  float normalization() const { return(normalization_);}
56  float deadTimeNormalization() const
57  { return(deadTimeNormalization_);}
58 
59  float lumiFill() const { return(lumiFill_);}
60  float lumiRun() const { return(lumiRun_);}
61  float liveLumiFill() const { return(liveLumiFill_);}
62  float liveLumiRun() const { return(liveLumiRun_);}
63  float instantLumi() const { return(instantLumi_);}
64  float instantLumiErr() const { return(instantLumiErr_);}
65  unsigned char instantLumiQlty() const { return(instantLumiQlty_);}
66 
67  float lumiETFill() const { return(lumiETFill_);}
68  float lumiETRun() const { return(lumiETRun_);}
69  float liveLumiETFill() const { return(liveLumiETFill_);}
70  float liveLumiETRun() const { return(liveLumiETRun_);}
71  float instantETLumi() const { return(instantETLumi_);}
72  float instantETLumiErr() const { return(instantETLumiErr_);}
73  unsigned char instantETLumiQlty() const { return(instantETLumiQlty_);}
74 
75  std::vector<float> lumiOccFill() const
76  { return(lumiOccFill_);}
77  std::vector<float> lumiOccRun() const
78  { return(lumiOccRun_);}
79  std::vector<float> liveLumiOccFill() const
80  { return(liveLumiOccFill_);}
81  std::vector<float> liveLumiOccRun() const
82  { return(liveLumiOccRun_);}
83  std::vector<float> instantOccLumi() const
84  { return(instantOccLumi_);}
85  std::vector<float> instantOccLumiErr() const
86  { return(instantOccLumiErr_);}
87  std::vector<unsigned char> instantOccLumiQlty() const
88  { return(instantOccLumiQlty_);}
89  std::vector<float> lumiNoise() const { return(lumiNoise_);}
90 
91  unsigned int sectionNumber() const { return(sectionNumber_);}
92  unsigned int startOrbit() const { return(startOrbit_);}
93  unsigned int numOrbits() const { return(numOrbits_);}
94 
95  float pileup() const { return(pileup_);}
96  float pileupRMS() const { return(pileupRMS_);}
97  float bunchLumi() const { return(bunchLumi_);}
98  float spare() const { return(spare_);}
99 
101  int operator==(const LumiScalers& e) const { return false; }
102 
104  int operator!=(const LumiScalers& e) const { return false; }
105 
106 protected:
107 
108  unsigned int trigType_;
109  unsigned int eventID_;
110  unsigned int sourceID_;
111  unsigned int bunchNumber_;
112 
113  int version_;
114 
116 
119 
120  float lumiFill_;
121  float lumiRun_;
126  unsigned char instantLumiQlty_;
127 
128  float lumiETFill_;
129  float lumiETRun_;
134 
135  unsigned char instantETLumiQlty_;
136 
137  std::vector<float> lumiOccFill_;
138  std::vector<float> lumiOccRun_;
139  std::vector<float> liveLumiOccFill_;
140  std::vector<float> liveLumiOccRun_;
141  std::vector<float> instantOccLumi_;
142  std::vector<float> instantOccLumiErr_;
143  std::vector<unsigned char> instantOccLumiQlty_;
144  std::vector<float> lumiNoise_;
145 
146  unsigned int sectionNumber_;
147  unsigned int startOrbit_;
148  unsigned int numOrbits_;
149 
150  float pileup_;
151  float pileupRMS_;
152  float bunchLumi_;
153  float spare_;
154 };
155 
156 
158 std::ostream& operator<<(std::ostream& s, const LumiScalers& c);
159 
160 typedef std::vector<LumiScalers> LumiScalersCollection;
161 
162 #endif
float pileup_
Definition: LumiScalers.h:150
std::vector< unsigned char > instantOccLumiQlty_
Definition: LumiScalers.h:143
std::vector< float > lumiOccFill() const
Definition: LumiScalers.h:75
unsigned int trigType() const
Definition: LumiScalers.h:48
float lumiETFill() const
Definition: LumiScalers.h:67
unsigned char instantETLumiQlty() const
Definition: LumiScalers.h:73
unsigned char instantLumiQlty_
Definition: LumiScalers.h:126
unsigned int sectionNumber() const
Definition: LumiScalers.h:91
unsigned int bunchNumber() const
Definition: LumiScalers.h:51
virtual ~LumiScalers()
Definition: LumiScalers.cc:138
int version() const
Definition: LumiScalers.h:53
std::vector< float > liveLumiOccRun_
Definition: LumiScalers.h:140
std::vector< float > liveLumiOccFill_
Definition: LumiScalers.h:139
float lumiETRun_
Definition: LumiScalers.h:129
unsigned char instantETLumiQlty_
Definition: LumiScalers.h:135
float liveLumiETRun_
Definition: LumiScalers.h:131
std::vector< float > instantOccLumi_
Definition: LumiScalers.h:141
float lumiETRun() const
Definition: LumiScalers.h:68
float liveLumiFill_
Definition: LumiScalers.h:122
std::string name() const
name method
Definition: LumiScalers.h:43
float normalization() const
Definition: LumiScalers.h:55
float pileupRMS() const
Definition: LumiScalers.h:96
float instantETLumi() const
Definition: LumiScalers.h:71
std::vector< float > instantOccLumiErr() const
Definition: LumiScalers.h:85
float spare_
Definition: LumiScalers.h:153
std::vector< float > lumiOccRun_
Definition: LumiScalers.h:138
float bunchLumi() const
Definition: LumiScalers.h:97
float pileup() const
Definition: LumiScalers.h:95
timespec get_timespec() const
Definition: TimeSpec.cc:4
int operator!=(const LumiScalers &e) const
inequality operator
Definition: LumiScalers.h:104
float liveLumiETFill_
Definition: LumiScalers.h:130
float liveLumiRun_
Definition: LumiScalers.h:123
std::vector< float > lumiNoise_
Definition: LumiScalers.h:144
float instantLumi() const
Definition: LumiScalers.h:63
float instantLumiErr_
Definition: LumiScalers.h:125
float deadTimeNormalization_
Definition: LumiScalers.h:118
float lumiETFill_
Definition: LumiScalers.h:128
float pileupRMS_
Definition: LumiScalers.h:151
float lumiFill_
Definition: LumiScalers.h:120
float liveLumiETRun() const
Definition: LumiScalers.h:70
float normalization_
Definition: LumiScalers.h:117
float liveLumiRun() const
Definition: LumiScalers.h:62
float instantETLumiErr_
Definition: LumiScalers.h:133
unsigned int numOrbits() const
Definition: LumiScalers.h:93
float lumiFill() const
Definition: LumiScalers.h:59
timespec collectionTime() const
Definition: LumiScalers.h:54
unsigned int sectionNumber_
Definition: LumiScalers.h:146
float bunchLumi_
Definition: LumiScalers.h:152
float instantETLumiErr() const
Definition: LumiScalers.h:72
float instantETLumi_
Definition: LumiScalers.h:132
std::vector< float > lumiOccRun() const
Definition: LumiScalers.h:77
std::vector< float > lumiNoise() const
Definition: LumiScalers.h:89
std::vector< float > instantOccLumiErr_
Definition: LumiScalers.h:142
std::vector< unsigned char > instantOccLumiQlty() const
Definition: LumiScalers.h:87
float liveLumiETFill() const
Definition: LumiScalers.h:69
std::vector< float > lumiOccFill_
Definition: LumiScalers.h:137
float lumiRun() const
Definition: LumiScalers.h:60
float lumiRun_
Definition: LumiScalers.h:121
unsigned int eventID() const
Definition: LumiScalers.h:49
float spare() const
Definition: LumiScalers.h:98
unsigned char instantLumiQlty() const
Definition: LumiScalers.h:65
float instantLumi_
Definition: LumiScalers.h:124
float liveLumiFill() const
Definition: LumiScalers.h:61
bool empty() const
empty method (= false)
Definition: LumiScalers.h:46
unsigned int startOrbit() const
Definition: LumiScalers.h:92
std::ostream & operator<<(std::ostream &s, const LumiScalers &c)
Pretty-print operator for LumiScalers.
Definition: LumiScalers.cc:142
float instantLumiErr() const
Definition: LumiScalers.h:64
unsigned int sourceID() const
Definition: LumiScalers.h:50
std::vector< float > instantOccLumi() const
Definition: LumiScalers.h:83
int operator==(const LumiScalers &e) const
equality operator
Definition: LumiScalers.h:101
std::vector< LumiScalers > LumiScalersCollection
Definition: LumiScalers.h:160
unsigned int bunchNumber_
Definition: LumiScalers.h:111
TimeSpec collectionTime_
Definition: LumiScalers.h:115
unsigned int startOrbit_
Definition: LumiScalers.h:147
std::vector< float > liveLumiOccRun() const
Definition: LumiScalers.h:81
unsigned int sourceID_
Definition: LumiScalers.h:110
unsigned int eventID_
Definition: LumiScalers.h:109
unsigned int numOrbits_
Definition: LumiScalers.h:148
unsigned int trigType_
Definition: LumiScalers.h:108
float deadTimeNormalization() const
Definition: LumiScalers.h:56
std::vector< float > liveLumiOccFill() const
Definition: LumiScalers.h:79