CMS 3D CMS Logo

CommissioningTask.h
Go to the documentation of this file.
1 #ifndef DQM_SiStripCommissioningSources_CommissioningTask_H
2 #define DQM_SiStripCommissioningSources_CommissioningTask_H
3 
11 #include <vector>
12 #include <string>
13 #include <iomanip>
14 #include <cstdint>
15 
16 class TAxis;
17 namespace edm {
18  class EventSetup;
19 }
20 
25 public:
28  // ---------- Constructors, destructors ----------
29 
31 
32  virtual ~CommissioningTask();
33 
34  // ---------- Classes, structs ----------
35 
38  class HistoSet {
39  public:
40  HistoSet();
41  void histo(MonitorElement*);
43  uint32_t bin(float value);
44  std::vector<float> vNumOfEntries_;
45  std::vector<float> vSumOfContents_;
46  std::vector<double> vSumOfSquares_;
47  bool isProfile_;
49 
50  private:
52  TAxis* axis_;
53  };
54 
56  public:
58  void histo(MonitorElement*);
60  std::vector<short> vNumOfEntries_;
62 
63  private:
65  };
66 
67  // ---------- Public methods ----------
68 
70  void bookHistograms();
71 
74 
79 
84  const std::vector<uint16_t>&);
85 
87  void fillHistograms(const SiStripEventSummary&, const uint16_t& fed_id, const std::map<uint16_t, float>& fed_ch);
88 
90  void updateHistograms();
91 
93  inline const uint32_t& fillCntr() const;
94 
96  inline const uint32_t& updateFreq() const;
97 
99  inline void updateFreq(const uint32_t&);
100 
102  inline const std::string& myName() const;
103 
105  inline void eventSetup(const edm::EventSetup*);
106 
107 protected:
108  // ---------- Protected methods ----------
109 
111  void updateHistoSet(HistoSet&, const uint32_t& bin, const float& value);
112  void updateHistoSet(CompactHistoSet&, const uint32_t& bin, const short& value);
113 
115  void updateHistoSet(HistoSet&, const uint32_t& bin);
116  void updateHistoSet(CompactHistoSet&, const uint32_t& bin);
117 
119  void updateHistoSet(HistoSet&, const float& value);
121 
123  void updateHistoSet(HistoSet&);
124 
126  inline DQMStore* const dqm() const;
127 
129  inline const FedChannelConnection& connection() const;
130 
132  inline const uint32_t& fecKey() const;
133 
135  inline const uint32_t& fedKey() const;
136 
138  inline const edm::EventSetup* const eventSetup() const;
139 
140 private:
141  // ---------- Private methods ----------
142 
144 
145  virtual void book();
146 
147  virtual void fill(const SiStripEventSummary&, const edm::DetSet<SiStripRawDigi>&);
148 
150 
151  virtual void fill(const SiStripEventSummary&,
154  const std::vector<uint16_t>&);
155 
156  virtual void fill(const SiStripEventSummary&, const uint16_t& fed_id, const std::map<uint16_t, float>& fed_ch);
157 
158  virtual void update();
159 
160  // ---------- Private member data ----------
161 
163 
164  uint32_t updateFreq_;
165 
166  uint32_t fillCntr_;
167 
169 
170  uint32_t fedKey_;
171 
172  uint32_t fecKey_;
173 
174  bool booked_;
175 
177 
179 };
180 
181 // ----- inline methods -----
182 
183 const uint32_t& CommissioningTask::fillCntr() const { return fillCntr_; }
184 const uint32_t& CommissioningTask::updateFreq() const { return updateFreq_; }
185 void CommissioningTask::updateFreq(const uint32_t& freq) { updateFreq_ = freq; }
187 
190 
191 const uint32_t& CommissioningTask::fecKey() const { return fecKey_; }
192 const uint32_t& CommissioningTask::fedKey() const { return fedKey_; }
193 
196 
197 #endif // DQM_SiStripCommissioningSources_CommissioningTask_H
CommissioningTask::HistoSet::vSumOfSquares_
std::vector< double > vSumOfSquares_
Definition: CommissioningTask.h:46
CommissioningTask::HistoSet::bin
uint32_t bin(float value)
Definition: CommissioningTask.cc:105
CommissioningTask::HistoSet::vSumOfContents_
std::vector< float > vSumOfContents_
Definition: CommissioningTask.h:45
CommissioningTask::HistoSet::HistoSet
HistoSet()
Definition: CommissioningTask.cc:64
CommissioningTask::HistoSet::histo
MonitorElement * histo()
Definition: CommissioningTask.cc:81
CommissioningTask::fillHistograms
void fillHistograms(const SiStripEventSummary &, const edm::DetSet< SiStripRawDigi > &)
Definition: CommissioningTask.cc:182
edm::DetSet
Definition: DetSet.h:23
CommissioningTask::connection
const FedChannelConnection & connection() const
Definition: CommissioningTask.h:189
edm
HLT enums.
Definition: AlignableModifier.h:19
SiStripRawDigi.h
DQMStore.h
dqm::legacy::MonitorElement
Definition: MonitorElement.h:461
CommissioningTask::CompactHistoSet::vNumOfEntries_
std::vector< short > vNumOfEntries_
Definition: CommissioningTask.h:60
CommissioningTask::CompactHistoSet::histo_
MonitorElement * histo_
Definition: CommissioningTask.h:64
CommissioningTask
Definition: CommissioningTask.h:24
CommissioningTask::bookHistograms
void bookHistograms()
Definition: CommissioningTask.cc:175
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
CommissioningTask::HistoSet
Definition: CommissioningTask.h:38
CommissioningTask::fecKey_
uint32_t fecKey_
Definition: CommissioningTask.h:172
CommissioningTask::HistoSet::vNumOfEntries_
std::vector< float > vNumOfEntries_
Definition: CommissioningTask.h:44
CommissioningTask::fedKey
const uint32_t & fedKey() const
Definition: CommissioningTask.h:192
CommissioningTask::CompactHistoSet::histo
MonitorElement * histo()
Definition: CommissioningTask.cc:85
CommissioningTask::DQMStore
dqm::legacy::DQMStore DQMStore
Definition: CommissioningTask.h:26
CommissioningTask::HistoSet::explicitFill_
bool explicitFill_
Definition: CommissioningTask.h:48
CommissioningTask::fedKey_
uint32_t fedKey_
Definition: CommissioningTask.h:170
dqm::legacy::DQMStore
Definition: DQMStore.h:727
CommissioningTask::CompactHistoSet
Definition: CommissioningTask.h:55
CommissioningTask::~CommissioningTask
virtual ~CommissioningTask()
Definition: CommissioningTask.cc:49
CommissioningTask::myName_
std::string myName_
Definition: CommissioningTask.h:176
CommissioningTask::fill
virtual void fill(const SiStripEventSummary &, const edm::DetSet< SiStripRawDigi > &)
Definition: CommissioningTask.cc:133
CommissioningTask::eventSetup_
const edm::EventSetup * eventSetup_
Definition: CommissioningTask.h:178
CommissioningTask::CommissioningTask
CommissioningTask()
Definition: CommissioningTask.h:143
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
SiStripEventSummary.h
CommissioningTask::HistoSet::isProfile_
bool isProfile_
Definition: CommissioningTask.h:47
FedChannelConnection
Class containning control, module, detector and connection information, at the level of a FED channel...
Definition: FedChannelConnection.h:26
SiStripCluster.h
CommissioningTask::update
virtual void update()
Definition: CommissioningTask.cc:168
CommissioningTask::fillCntr_
uint32_t fillCntr_
Definition: CommissioningTask.h:166
CommissioningTask::eventSetup
const edm::EventSetup *const eventSetup() const
Definition: CommissioningTask.h:195
CommissioningTask::updateFreq
const uint32_t & updateFreq() const
Definition: CommissioningTask.h:184
CommissioningTask::fillCntr
const uint32_t & fillCntr() const
Definition: CommissioningTask.h:183
CommissioningTask::updateHistoSet
void updateHistoSet(HistoSet &, const uint32_t &bin, const float &value)
Definition: CommissioningTask.cc:274
value
Definition: value.py:1
CommissioningTask::book
virtual void book()
Definition: CommissioningTask.cc:126
CommissioningTask::CompactHistoSet::explicitFill_
bool explicitFill_
Definition: CommissioningTask.h:61
CommissioningTask::connection_
FedChannelConnection connection_
Definition: CommissioningTask.h:168
edm::EventSetup
Definition: EventSetup.h:57
newFWLiteAna.bin
bin
Definition: newFWLiteAna.py:161
CommissioningTask::myName
const std::string & myName() const
Definition: CommissioningTask.h:186
CommissioningTask::dqm
DQMStore *const dqm() const
Definition: CommissioningTask.h:188
CommissioningTask::MonitorElement
dqm::legacy::MonitorElement MonitorElement
Definition: CommissioningTask.h:27
FedChannelConnection.h
CommissioningTask::CompactHistoSet::CompactHistoSet
CompactHistoSet()
Definition: CommissioningTask.cc:77
CommissioningTask::HistoSet::histo_
MonitorElement * histo_
Definition: CommissioningTask.h:51
DetSetNew.h
DetSet.h
CommissioningTask::dqm_
DQMStore * dqm_
Definition: CommissioningTask.h:162
EventSetup
SiStripEventSummary
Definition: SiStripEventSummary.h:22
CommissioningTask::updateFreq_
uint32_t updateFreq_
Definition: CommissioningTask.h:164
CommissioningTask::booked_
bool booked_
Definition: CommissioningTask.h:174
CommissioningTask::fecKey
const uint32_t & fecKey() const
Definition: CommissioningTask.h:191
CommissioningTask::HistoSet::axis_
TAxis * axis_
Definition: CommissioningTask.h:52
CommissioningTask::updateHistograms
void updateHistograms()
Definition: CommissioningTask.cc:249