CMS 3D CMS Logo

L1TriggerRates.h
Go to the documentation of this file.
1 /*
2  * File: DataFormats/Scalers/interface/L1TriggerRates.h (W.Badgett)
3  *
4  * Various Level 1 Trigger Rates from the GT/TS
5  *
6  */
7 
8 #ifndef DATAFORMATS_SCALERS_L1TRIGGERRATES_H
9 #define DATAFORMATS_SCALERS_L1TRIGGERRATES_H
10 
12 
13 #include <ctime>
14 #include <iosfwd>
15 #include <string>
16 #include <vector>
17 
25 
28 class L1TriggerScalers;
29 
31 public:
32  enum { N_BX = 3654, N_BX_ACTIVE = 2808 };
33 
34 #define BX_SPACING (double)25E-9
35 
39  virtual ~L1TriggerRates();
40 
41  void computeRunRates(L1TriggerScalers const& t);
42  void computeRates(L1TriggerScalers const& t1, L1TriggerScalers const& t2);
43 
45  std::string name() const { return "L1TriggerRates"; }
46 
48  bool empty() const { return false; }
49 
51 
52  int version() const { return (version_); }
54 
55  double deltaT() const { return (deltaT_); }
56  double deltaTActive() const { return (deltaTActive_); }
57  double deltaTRun() const { return (deltaTRun_); }
58  double deltaTRunActive() const { return (deltaTRunActive_); }
59 
60  // Instantaneous Rate accessors
61  double triggerNumberRate() const { return (triggerNumberRate_); }
62 
63  double eventNumberRate() const { return (eventNumberRate_); }
64 
67 
68  double randomTriggersRate() const { return (randomTriggersRate_); }
69 
71 
72  double totalTestTriggersRate() const { return (totalTestTriggersRate_); }
73 
74  double orbitNumberRate() const { return (orbitNumberRate_); }
75 
76  double numberResetsRate() const { return (numberResetsRate_); }
77 
78  double deadTimePercent() const { return (deadTimePercent_); }
79 
80  double deadTimeActivePercent() const { return (deadTimeActivePercent_); }
81 
83 
85 
87 
89 
91 
93 
95 
97 
99 
100  std::vector<double> triggersRate() const { return (triggersRate_); }
101  std::vector<double> testTriggersRate() const { return (testTriggersRate_); }
102 
103  // Run Rate Accessors
104  double triggerNumberRunRate() const { return (triggerNumberRunRate_); }
105 
106  double eventNumberRunRate() const { return (eventNumberRunRate_); }
107 
109 
111 
112  double randomTriggersRunRate() const { return (randomTriggersRunRate_); }
113 
115 
117 
118  double orbitNumberRunRate() const { return (orbitNumberRunRate_); }
119 
120  double numberResetsRunRate() const { return (numberResetsRunRate_); }
121 
122  double deadTimeRunPercent() const { return (deadTimeRunPercent_); }
123 
125 
127 
129 
131 
133 
135 
137 
139 
141 
142  std::vector<double> triggersRunRate() const { return (triggersRunRate_); }
143 
144  std::vector<double> testTriggersRunRate() const { return (testTriggersRunRate_); }
145 
147  int operator==(const L1TriggerRates& e) const { return false; }
148 
150  int operator!=(const L1TriggerRates& e) const { return false; }
151 
152 protected:
153  int version_;
155 
156  double deltaT_;
158 
178 
179  std::vector<double> triggersRate_;
180  std::vector<double> testTriggersRate_;
181 
182  double deltaTRun_;
184 
204 
206  std::vector<double> triggersRunRate_;
207  std::vector<double> testTriggersRunRate_;
208 };
209 
211 std::ostream& operator<<(std::ostream& s, const L1TriggerRates& c);
212 
213 typedef std::vector<L1TriggerRates> L1TriggerRatesCollection;
214 
215 #endif
L1TriggerRates::finalTriggersDistributedRate_
double finalTriggersDistributedRate_
Definition: L1TriggerRates.h:161
L1TriggerRates::deadTimeActivePartitionPercent
double deadTimeActivePartitionPercent() const
Definition: L1TriggerRates.h:86
L1TriggerRates::deadTimeActiveRunPercent
double deadTimeActiveRunPercent() const
Definition: L1TriggerRates.h:124
RandomServiceHelper.t2
t2
Definition: RandomServiceHelper.py:257
L1TriggerRates::collectionTimeDetails
timespec collectionTimeDetails() const
Definition: L1TriggerRates.h:98
L1TriggerRates::randomTriggersRunRate_
double randomTriggersRunRate_
Definition: L1TriggerRates.h:189
L1TriggerRates::deltaTRunActive_
double deltaTRunActive_
Definition: L1TriggerRates.h:183
L1TriggerRates::triggersRate
std::vector< double > triggersRate() const
Definition: L1TriggerRates.h:100
L1TriggerRates::lostFinalTriggersActiveRunPercent_
double lostFinalTriggersActiveRunPercent_
Definition: L1TriggerRates.h:203
L1TriggerRates::totalTestTriggersRate_
double totalTestTriggersRate_
Definition: L1TriggerRates.h:165
L1TriggerRates::numberResetsRunRate_
double numberResetsRunRate_
Definition: L1TriggerRates.h:193
L1TriggerRates::finalTriggersDistributedRunRate_
double finalTriggersDistributedRunRate_
Definition: L1TriggerRates.h:187
L1TriggerRates::eventNumberRunRate_
double eventNumberRunRate_
Definition: L1TriggerRates.h:186
L1TriggerRates::version
int version() const
get the data
Definition: L1TriggerRates.h:52
L1TriggerRates
Definition: L1TriggerRates.h:30
L1TriggerRates::numberResetsRate_
double numberResetsRate_
Definition: L1TriggerRates.h:167
L1TriggerRates::deadTimeActivePrivateRunPercent_
double deadTimeActivePrivateRunPercent_
Definition: L1TriggerRates.h:197
L1TriggerRates::deadTimeRunPercent
double deadTimeRunPercent() const
Definition: L1TriggerRates.h:122
L1TriggerRates::deltaTActive_
double deltaTActive_
Definition: L1TriggerRates.h:157
L1TriggerRates::finalTriggersInvalidBCPercent_
double finalTriggersInvalidBCPercent_
Definition: L1TriggerRates.h:175
L1TriggerRates::deltaTRun_
double deltaTRun_
Definition: L1TriggerRates.h:182
L1TriggerRates::orbitNumberRunRate_
double orbitNumberRunRate_
Definition: L1TriggerRates.h:192
L1TriggerRates::testTriggersRunRate
std::vector< double > testTriggersRunRate() const
Definition: L1TriggerRates.h:144
L1TriggerRates::randomTriggersRunRate
double randomTriggersRunRate() const
Definition: L1TriggerRates.h:112
operator<<
std::ostream & operator<<(std::ostream &s, const L1TriggerRates &c)
Pretty-print operator for L1TriggerRates.
Definition: L1TriggerRates.cc:191
L1TriggerRates::name
std::string name() const
name method
Definition: L1TriggerRates.h:45
L1TriggerRates::finalTriggersGeneratedRate_
double finalTriggersGeneratedRate_
Definition: L1TriggerRates.h:162
L1TriggerRates::testTriggersRunRate_
std::vector< double > testTriggersRunRate_
Definition: L1TriggerRates.h:207
L1TriggerRates::calibrationTriggersRunRate
double calibrationTriggersRunRate() const
Definition: L1TriggerRates.h:114
TimeSpec::get_timespec
timespec get_timespec() const
Definition: TimeSpec.cc:4
indexGen.s2
s2
Definition: indexGen.py:107
L1TriggerRates::deadTimeActiveThrottlePercent
double deadTimeActiveThrottlePercent() const
Definition: L1TriggerRates.h:88
L1TriggerRates::finalTriggersDistributedRate
double finalTriggersDistributedRate() const
Definition: L1TriggerRates.h:66
L1TriggerRates::deadTimeActiveCalibrationRunPercent
double deadTimeActiveCalibrationRunPercent() const
Definition: L1TriggerRates.h:126
L1TriggerRates::totalTestTriggersRate
double totalTestTriggersRate() const
Definition: L1TriggerRates.h:72
L1TriggerRates::deadTimeActiveRunPercent_
double deadTimeActiveRunPercent_
Definition: L1TriggerRates.h:195
L1TriggerRates::deltaTActive
double deltaTActive() const
Definition: L1TriggerRates.h:56
L1TriggerRates::eventNumberRate
double eventNumberRate() const
Definition: L1TriggerRates.h:63
L1TriggerRates::deadTimeActivePercent_
double deadTimeActivePercent_
Definition: L1TriggerRates.h:169
L1TriggerRates::deadTimeActiveThrottleRunPercent_
double deadTimeActiveThrottleRunPercent_
Definition: L1TriggerRates.h:199
L1TriggerRates::collectionTimeSummary_
TimeSpec collectionTimeSummary_
Definition: L1TriggerRates.h:154
L1TriggerRates::N_BX
Definition: L1TriggerRates.h:32
L1TriggerRates::randomTriggersRate_
double randomTriggersRate_
Definition: L1TriggerRates.h:163
alignCSCRings.s
s
Definition: alignCSCRings.py:92
RandomServiceHelper.t1
t1
Definition: RandomServiceHelper.py:256
L1TriggerRates::deadTimeActiveThrottleRunPercent
double deadTimeActiveThrottleRunPercent() const
Definition: L1TriggerRates.h:132
L1TriggerRates::deadTimeActivePrivatePercent
double deadTimeActivePrivatePercent() const
Definition: L1TriggerRates.h:84
L1TriggerRates::triggerNumberRate_
double triggerNumberRate_
Definition: L1TriggerRates.h:159
L1TriggerRates::deadTimeRunPercent_
double deadTimeRunPercent_
Definition: L1TriggerRates.h:194
L1TriggerRates::deadTimePercent
double deadTimePercent() const
Definition: L1TriggerRates.h:78
L1TriggerRates::version_
int version_
Definition: L1TriggerRates.h:153
L1TriggerRates::lostFinalTriggersActivePercent
double lostFinalTriggersActivePercent() const
Definition: L1TriggerRates.h:96
L1TriggerRates::finalTriggersInvalidBCRunPercent
double finalTriggersInvalidBCRunPercent() const
Definition: L1TriggerRates.h:136
L1TriggerRates::deadTimePercent_
double deadTimePercent_
Definition: L1TriggerRates.h:168
L1TriggerRates::deadTimeActiveTimeSlotRunPercent
double deadTimeActiveTimeSlotRunPercent() const
Definition: L1TriggerRates.h:134
L1TriggerRates::triggerNumberRunRate_
double triggerNumberRunRate_
Definition: L1TriggerRates.h:185
L1TriggerRates::operator!=
int operator!=(const L1TriggerRates &e) const
inequality operator
Definition: L1TriggerRates.h:150
L1TriggerRates::deadTimeActiveThrottlePercent_
double deadTimeActiveThrottlePercent_
Definition: L1TriggerRates.h:173
L1TriggerRates::deltaT
double deltaT() const
Definition: L1TriggerRates.h:55
L1TriggerRates::lostFinalTriggersActiveRunPercent
double lostFinalTriggersActiveRunPercent() const
Definition: L1TriggerRates.h:140
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
L1TriggerRates::deadTimeActivePartitionPercent_
double deadTimeActivePartitionPercent_
Definition: L1TriggerRates.h:172
L1TriggerRates::eventNumberRate_
double eventNumberRate_
Definition: L1TriggerRates.h:160
L1TriggerRatesCollection
std::vector< L1TriggerRates > L1TriggerRatesCollection
Definition: L1TriggerRates.h:213
L1TriggerRates::deadTimeActiveCalibrationRunPercent_
double deadTimeActiveCalibrationRunPercent_
Definition: L1TriggerRates.h:196
L1TriggerRates::lostFinalTriggersPercent
double lostFinalTriggersPercent() const
Definition: L1TriggerRates.h:94
L1TriggerRates::triggerNumberRunRate
double triggerNumberRunRate() const
Definition: L1TriggerRates.h:104
L1TriggerRates::computeRunRates
void computeRunRates(L1TriggerScalers const &t)
Definition: L1TriggerRates.cc:144
L1TriggerRates::deadTimeActivePartitionRunPercent_
double deadTimeActivePartitionRunPercent_
Definition: L1TriggerRates.h:198
L1TriggerRates::lostFinalTriggersPercent_
double lostFinalTriggersPercent_
Definition: L1TriggerRates.h:176
L1TriggerRates::deltaTRun
double deltaTRun() const
Definition: L1TriggerRates.h:57
L1TriggerRates::lostFinalTriggersActivePercent_
double lostFinalTriggersActivePercent_
Definition: L1TriggerRates.h:177
L1TriggerRates::finalTriggersInvalidBCRunPercent_
double finalTriggersInvalidBCRunPercent_
Definition: L1TriggerRates.h:201
L1TriggerRates::testTriggersRate_
std::vector< double > testTriggersRate_
Definition: L1TriggerRates.h:180
L1TriggerRates::deltaTRunActive
double deltaTRunActive() const
Definition: L1TriggerRates.h:58
L1TriggerRates::deadTimeActiveTimeSlotPercent_
double deadTimeActiveTimeSlotPercent_
Definition: L1TriggerRates.h:174
L1TriggerRates::finalTriggersGeneratedRunRate_
double finalTriggersGeneratedRunRate_
Definition: L1TriggerRates.h:188
L1TriggerRates::numberResetsRate
double numberResetsRate() const
Definition: L1TriggerRates.h:76
L1TriggerRates::calibrationTriggersRate
double calibrationTriggersRate() const
Definition: L1TriggerRates.h:70
L1TriggerRates::totalTestTriggersRunRate_
double totalTestTriggersRunRate_
Definition: L1TriggerRates.h:191
L1TriggerRates::L1TriggerRates
L1TriggerRates()
Definition: L1TriggerRates.cc:11
L1TriggerRates::operator==
int operator==(const L1TriggerRates &e) const
equality operator
Definition: L1TriggerRates.h:147
L1TriggerRates::lostFinalTriggersRunPercent
double lostFinalTriggersRunPercent() const
Definition: L1TriggerRates.h:138
L1TriggerRates::orbitNumberRate_
double orbitNumberRate_
Definition: L1TriggerRates.h:166
L1TriggerRates::finalTriggersDistributedRunRate
double finalTriggersDistributedRunRate() const
Definition: L1TriggerRates.h:108
L1TriggerRates::numberResetsRunRate
double numberResetsRunRate() const
Definition: L1TriggerRates.h:120
L1TriggerRates::calibrationTriggersRate_
double calibrationTriggersRate_
Definition: L1TriggerRates.h:164
L1TriggerRates::calibrationTriggersRunRate_
double calibrationTriggersRunRate_
Definition: L1TriggerRates.h:190
L1TriggerRates::deadTimeActiveTimeSlotPercent
double deadTimeActiveTimeSlotPercent() const
Definition: L1TriggerRates.h:90
TimeSpec.h
L1TriggerRates::computeRates
void computeRates(L1TriggerScalers const &t1, L1TriggerScalers const &t2)
Definition: L1TriggerRates.cc:83
L1TriggerRates::deltaT_
double deltaT_
Definition: L1TriggerRates.h:156
L1TriggerRates::collectionTimeDetails_
TimeSpec collectionTimeDetails_
Definition: L1TriggerRates.h:205
L1TriggerRates::triggersRunRate_
std::vector< double > triggersRunRate_
Definition: L1TriggerRates.h:206
L1TriggerRates::N_BX_ACTIVE
Definition: L1TriggerRates.h:32
L1TriggerRates::orbitNumberRunRate
double orbitNumberRunRate() const
Definition: L1TriggerRates.h:118
L1TriggerRates::orbitNumberRate
double orbitNumberRate() const
Definition: L1TriggerRates.h:74
L1TriggerRates::totalTestTriggersRunRate
double totalTestTriggersRunRate() const
Definition: L1TriggerRates.h:116
L1TriggerRates::triggerNumberRate
double triggerNumberRate() const
Definition: L1TriggerRates.h:61
L1TriggerRates::testTriggersRate
std::vector< double > testTriggersRate() const
Definition: L1TriggerRates.h:101
L1TriggerRates::deadTimeActivePrivateRunPercent
double deadTimeActivePrivateRunPercent() const
Definition: L1TriggerRates.h:128
L1TriggerRates::deadTimeActiveTimeSlotRunPercent_
double deadTimeActiveTimeSlotRunPercent_
Definition: L1TriggerRates.h:200
TimeSpec
Definition: TimeSpec.h:7
L1TriggerRates::~L1TriggerRates
virtual ~L1TriggerRates()
Definition: L1TriggerRates.cc:81
L1TriggerRates::deadTimeActiveCalibrationPercent
double deadTimeActiveCalibrationPercent() const
Definition: L1TriggerRates.h:82
L1TriggerRates::randomTriggersRate
double randomTriggersRate() const
Definition: L1TriggerRates.h:68
L1TriggerRates::deadTimeActivePartitionRunPercent
double deadTimeActivePartitionRunPercent() const
Definition: L1TriggerRates.h:130
L1TriggerRates::collectionTimeSummary
timespec collectionTimeSummary()
Definition: L1TriggerRates.h:53
L1TriggerRates::deadTimeActivePrivatePercent_
double deadTimeActivePrivatePercent_
Definition: L1TriggerRates.h:171
L1TriggerRates::triggersRate_
std::vector< double > triggersRate_
Definition: L1TriggerRates.h:179
L1TriggerRates::triggersRunRate
std::vector< double > triggersRunRate() const
Definition: L1TriggerRates.h:142
c
auto & c
Definition: CAHitNtupletGeneratorKernelsImpl.h:46
submitPVValidationJobs.t
string t
Definition: submitPVValidationJobs.py:644
L1TriggerRates::deadTimeActiveCalibrationPercent_
double deadTimeActiveCalibrationPercent_
Definition: L1TriggerRates.h:170
L1TriggerRates::eventNumberRunRate
double eventNumberRunRate() const
Definition: L1TriggerRates.h:106
L1TriggerRates::lostFinalTriggersRunPercent_
double lostFinalTriggersRunPercent_
Definition: L1TriggerRates.h:202
L1TriggerRates::empty
bool empty() const
empty method (= false)
Definition: L1TriggerRates.h:48
L1TriggerScalers
Definition: L1TriggerScalers.h:28
L1TriggerRates::deadTimeActivePercent
double deadTimeActivePercent() const
Definition: L1TriggerRates.h:80
L1TriggerRates::finalTriggersInvalidBCPercent
double finalTriggersInvalidBCPercent() const
Definition: L1TriggerRates.h:92
L1TriggerRates::finalTriggersGeneratedRunRate
double finalTriggersGeneratedRunRate() const
Definition: L1TriggerRates.h:110
MillePedeFileConverter_cfg.e
e
Definition: MillePedeFileConverter_cfg.py:37
L1TriggerRates::finalTriggersGeneratedRate
double finalTriggersGeneratedRate() const
Definition: L1TriggerRates.h:65