CMS 3D CMS Logo

L1TGT.h
Go to the documentation of this file.
1 #ifndef L1TGT_H
2 #define L1TGT_H
3 
16 // system include files
17 #include <memory>
18 #include <unistd.h>
19 #include <vector>
20 #include <utility>
21 
22 // user include files
25 
28 
30 
36 
37 //L1 trigger includes
42 
44 
45 //
46 // class declaration
47 //
48 
49 class L1TGT : public DQMOneEDAnalyzer<edm::one::WatchLuminosityBlocks> {
50 public:
51  // constructor
52  L1TGT(const edm::ParameterSet& ps);
53 
54  // destructor
55  ~L1TGT() override;
56 
57 protected:
58  //virtual void beginJob();
59  void dqmBeginRun(const edm::Run&, const edm::EventSetup&) override;
60  void bookHistograms(DQMStore::IBooker& ibooker, edm::Run const&, edm::EventSetup const&) override;
61  void analyze(const edm::Event&, const edm::EventSetup&) override;
62 
65  void endLuminosityBlock(const edm::LuminosityBlock&, const edm::EventSetup&) override;
66 
67 private:
69 
70  bool isActive(int word, int bit);
71  // Active boards DAQ record bit number:
72  // 0 FDL
73  // 1 PSB_0 9 Techn.Triggers for FDL
74  // 2 PSB_1 13 Calo data for GTL
75  // 3 PSB_2 14 Calo data for GTL
76  // 4 PSB_3 15 Calo data for GTL
77  // 5 PSB_4 19 M/Q bits for GMT
78  // 6 PSB_5 20 M/Q bits for GMT
79  // 7 PSB_6 21 M/Q bits for GMT
80  // 8 GMT
82  // Active boards EVM record bit number:
83  // 0 TCS
84  // 1 FDL
85  enum activeEVM { TCS, FDLEVM };
86 
87  // count the number of indices per Ls for prescale factor sets
88  // if no errors, it must be 1
89  void countPfsIndicesPerLs();
90 
91 private:
93 
97 
100 
104 
106  bool verbose_;
107 
108 private:
117 
125 
128 
139 
142 
145  // maximum difference in orbit number, luminosity number
146  // histogram range: -(MaxOrbitNrDiffTcsFdlEvm+1), (MaxOrbitNrDiffTcsFdlEvm+1)
147  // if value is greater than the maximum difference, fill an entry in the last but one bin
148  // if value is smaller than the negative value of maximum difference, fill an entry
149  // in the second bin
150  // if no value can be retrieved for TCS, fill an entry in the first bin
151  // if no value can be retrieved for FDL, fill an entry in the last bin
152  static const int MaxOrbitNrDiffTcsFdlEvm;
153  static const int MaxLsNrDiffTcsFdlEvm;
154 
157 
163 
164  //MonitorElement* m_monDiffEvmDaqFdl;
165 
166 private:
170 
173 
176 
179  std::map<std::string, bool> l1TriggerDecision, l1TechTriggerDecision;
180  std::map<std::string, bool>::iterator trig_iter;
181 
182  std::vector<std::pair<int, int> > m_pairLsNumberPfIndex;
183  typedef std::vector<std::pair<int, int> >::const_iterator CItVecPair;
184 };
185 
186 #endif
MonitorElement * m_monL1PrescaleFactorSet
Definition: L1TGT.h:140
void bookHistograms(DQMStore::IBooker &ibooker, edm::Run const &, edm::EventSetup const &) override
Definition: L1TGT.cc:36
MonitorElement * h_L1AlgoBX1
Definition: L1TGT.h:158
MonitorElement * gpsfreqwide
Definition: L1TGT.h:137
int m_nrEvRun
Definition: L1TGT.h:169
Definition: L1TGT.h:49
void endLuminosityBlock(const edm::LuminosityBlock &, const edm::EventSetup &) override
Definition: L1TGT.cc:714
std::map< std::string, bool > l1TriggerDecision
Definition: L1TGT.h:179
MonitorElement * m_monLsNrDiffTcsFdlEvmLs
Definition: L1TGT.h:156
std::vector< std::pair< int, int > >::const_iterator CItVecPair
Definition: L1TGT.h:183
activeEVM
Definition: L1TGT.h:85
void analyze(const edm::Event &, const edm::EventSetup &) override
Definition: L1TGT.cc:330
MonitorElement * BST_intensityBeam1
Definition: L1TGT.h:134
static const int MaxOrbitNrDiffTcsFdlEvm
Definition: L1TGT.h:152
MonitorElement * algo_bits_corr
Definition: L1TGT.h:110
MonitorElement * tt_bits
Definition: L1TGT.h:111
bool verbose_
verbosity switch
Definition: L1TGT.h:106
MonitorElement * gtfe_bx
Definition: L1TGT.h:126
MonitorElement * BST_beamMode
Definition: L1TGT.h:132
bool m_runInEventLoop
switches to choose the running of various methods
Definition: L1TGT.h:102
MonitorElement * BST_MasterStatus
Definition: L1TGT.h:129
MonitorElement * BST_intensityBeam2
Definition: L1TGT.h:135
~L1TGT() override
Definition: L1TGT.cc:32
uint64_t word
MonitorElement * h_L1TechBX
Definition: L1TGT.h:162
MonitorElement * event_number
Definition: L1TGT.h:118
MonitorElement * h_L1AlgoBX3
Definition: L1TGT.h:160
activeDAQ
Definition: L1TGT.h:81
uint64_t preGps_
Definition: L1TGT.h:174
static const int MaxLsNrDiffTcsFdlEvm
Definition: L1TGT.h:153
edm::EDGetTokenT< L1GlobalTriggerEvmReadoutRecord > gtEvmSource_
input tag for L1 GT EVM readout record
Definition: L1TGT.h:99
MonitorElement * orbit_lumi
Definition: L1TGT.h:123
MonitorElement * h_L1AlgoBX4
Definition: L1TGT.h:161
std::string m_histFolder
histogram folder for L1 GT plots
Definition: L1TGT.h:172
MonitorElement * algo_bits_lumi
Definition: L1TGT.h:114
MonitorElement * m_monLsNrDiffTcsFdlEvm
Definition: L1TGT.h:144
MonitorElement * gpsfreq
Definition: L1TGT.h:136
std::string algoBitToName[128]
Definition: L1TGT.h:177
MonitorElement * algo_bits
Definition: L1TGT.h:109
void dqmBeginRun(const edm::Run &, const edm::EventSetup &) override
Definition: L1TGT.cc:327
MonitorElement * event_type
Definition: L1TGT.h:116
MonitorElement * m_monOrbitNrDiffTcsFdlEvmLs
Definition: L1TGT.h:155
MonitorElement * dbx_module
Definition: L1TGT.h:127
bool m_runInEndLumi
Definition: L1TGT.h:103
unsigned long long uint64_t
Definition: Time.h:13
MonitorElement * tt_bits_corr
Definition: L1TGT.h:112
bool isActive(int word, int bit)
book all histograms for the module
Definition: L1TGT.cc:721
uint64_t preOrb_
Definition: L1TGT.h:175
MonitorElement * gpsfreqlum
Definition: L1TGT.h:138
int m_nrEvJob
number of events processed
Definition: L1TGT.h:168
edm::EDGetTokenT< L1GlobalTriggerReadoutRecord > gtSource_L1GT_
input parameters
Definition: L1TGT.h:95
MonitorElement * h_L1AlgoBX2
Definition: L1TGT.h:159
void countPfsIndicesPerLs()
Definition: L1TGT.cc:727
MonitorElement * m_monL1PfIndicesPerLs
Definition: L1TGT.h:141
std::map< std::string, bool >::iterator trig_iter
Definition: L1TGT.h:180
MonitorElement * trigger_number
Definition: L1TGT.h:120
std::vector< std::pair< int, int > > m_pairLsNumberPfIndex
Definition: L1TGT.h:182
void beginLuminosityBlock(const edm::LuminosityBlock &, const edm::EventSetup &) final
end section
Definition: L1TGT.h:64
MonitorElement * BST_beamMomentum
Definition: L1TGT.h:133
MonitorElement * BST_lhcFillNumber
Definition: L1TGT.h:131
MonitorElement * setupversion_lumi
Definition: L1TGT.h:124
MonitorElement * BST_turnCountNumber
Definition: L1TGT.h:130
std::map< std::string, bool > l1TechTriggerDecision
Definition: L1TGT.h:179
MonitorElement * event_lumi
Definition: L1TGT.h:119
MonitorElement * tt_bits_lumi
Definition: L1TGT.h:115
MonitorElement * trigger_lumi
Definition: L1TGT.h:121
MonitorElement * evnum_trignum_lumi
Definition: L1TGT.h:122
MonitorElement * algo_tt_bits_corr
Definition: L1TGT.h:113
std::string techBitToName[64]
Definition: L1TGT.h:178
Definition: Run.h:45
MonitorElement * m_monOrbitNrDiffTcsFdlEvm
Definition: L1TGT.h:143
L1TGT(const edm::ParameterSet &ps)
Definition: L1TGT.cc:18
edm::EDGetTokenT< L1MuGMTReadoutCollection > gtSource_L1MuGMT_
Definition: L1TGT.h:96