ATLAS Offline Software
Loading...
Searching...
No Matches
LArNoisyROMonAlg.cxx
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3*/
4
5#include "LArNoisyROMonAlg.h"
6
8
9#include <sstream>
10#include <stdexcept>
11#include <cmath>
12
13LArNoisyROMonAlg::LArNoisyROMonAlg(const std::string& name, ISvcLocator* pSvcLocator):
14 AthMonitorAlgorithm(name, pSvcLocator),
15 m_LArOnlineIDHelper(nullptr) {
16
17}
18
19
21{
22 ATH_CHECK(detStore()->retrieve(m_LArOnlineIDHelper, "LArOnlineID" ));
23 ATH_CHECK(m_inputKey.initialize());
24 ATH_CHECK(m_badFebKey.initialize());
25 ATH_CHECK(m_MNBFebKey.initialize());
26 ATH_CHECK(m_hvMapKey.initialize(!m_hvMapKey.empty()));
27 ATH_CHECK( m_eventInfoDecorKey.initialize() );
28
29 m_histoGroups.reserve(m_SubDetNames.size());
30 for (unsigned i=0; i<m_SubDetNames.size(); ++i) {
31 std::vector<std::string> part;
32 part.push_back(m_partitions[2*i]);
33 part.push_back(m_partitions[2*i+1]);
34 ATH_MSG_INFO(i<<" "<<m_SubDetNames[i]<<" "<<part[0] <<" " <<part[1]);
36 }
37
39}
40
41
42void LArNoisyROMonAlg::fillHistogramsOnce(const EventContext& ctx, const bool isMC) const {
43
45 const LArBadFebCont *badCont{*badHdl};
46 if(badCont) {
47 if( !isMC && badCont->size()==0) {
48 ATH_MSG_DEBUG("List of known Bad FEBs empty !? ");
49 } else {
50 auto sl=Monitored::Scalar<unsigned>("slotBad",0);
51 auto FT=Monitored::Scalar<unsigned>("FTBad",0);
52 for(LArBadFebCont::BadChanVec::const_iterator i = badCont->begin(); i!=badCont->end(); ++i) {
53 HWIdentifier chid(i->first);
54 sl = m_LArOnlineIDHelper->slot(chid);
55 FT = m_LArOnlineIDHelper->feedthrough(chid);
56 unsigned sd = partitionNumber(chid)/2;
57 unsigned part = partitionNumber(chid);
58 ATH_MSG_DEBUG("Filled known Bad FEBs for " << sd << " and " << part<<": "<<sl<<" "<<FT);
59 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[part])],sl,FT);
60 }
61 }
62 } else {
63 ATH_MSG_WARNING("Known Bad FEBs container not existing !? ");
64 }
65
67 const LArBadFebCont* mnbCont{*mnbHdl};
68 if(mnbCont) {
69 if( !isMC && mnbCont->size()==0) {
70 ATH_MSG_WARNING("List of known MNB FEBs empty !? ");
71 } else {
72 auto sl=Monitored::Scalar<unsigned>("slotMNB",0);
73 auto FT=Monitored::Scalar<unsigned>("FTMNB",0);
74 for(LArBadFebCont::BadChanVec::const_iterator i = mnbCont->begin(); i!=mnbCont->end(); ++i) {
75 HWIdentifier chid(i->first);
76 sl = m_LArOnlineIDHelper->slot(chid);
77 FT = m_LArOnlineIDHelper->feedthrough(chid);
78 unsigned sd = partitionNumber(chid)/2;
79 unsigned part = partitionNumber(chid);
80 ATH_MSG_DEBUG("Filled known MNB FEBs for " << sd << " and " << m_partitions[part]<<": "<<sl<<" "<<FT);
81 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[part])],sl,FT);
82 }
83 }
84 } else {
85 ATH_MSG_WARNING("Known MNB FEBs container not existing !? ");
86 }
87 return;
88}
89
90
91StatusCode LArNoisyROMonAlg::fillHistograms(const EventContext& ctx) const {
92
94 ATH_CHECK(eventInfo.isValid());
95 const bool isMC=eventInfo->eventType( xAOD::EventInfo::IS_SIMULATION);
96 std::call_once(m_onceFlag, &LArNoisyROMonAlg::fillHistogramsOnce, this, ctx, isMC);
97
98
99 // retrieve
101 if (!noisyRO.isValid())
102 {
103 ATH_MSG_WARNING( "Can't retrieve LArNoisyROSummary " );
104 return StatusCode::SUCCESS;
105 }
106 const LArHVIdMapping* hvid=nullptr;
107 if(!m_hvMapKey.empty()){
109 hvid = *hvidHdl;
110 if(!hvid) {
111 ATH_MSG_WARNING( "Can't retrieve LArHVIdMapping, no per partition HVlines histograms ! " );
112 }
113 }
114
115 unsigned int LBN = eventInfo->lumiBlock();
116 bool burstveto = eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::NOISEBURSTVETO);
117
118 const std::vector<HWIdentifier>& mnbtightFEB = noisyRO->get_MNBTight_febs();
119 const std::vector<HWIdentifier>& mnbtight_PsVetoFEB = noisyRO->get_MNBTight_PsVeto_febs();
120 const std::vector<HWIdentifier>& mnblooseFEB = noisyRO->get_MNBLoose_febs();
121
122 // Filling Candidate MNB Tree
123 std::vector<int> v_candidate_MNBTightFEB;
124 std::vector<int> v_candidate_MNBTight_PsVetoFEB;
125 std::vector<int> v_candidate_MNBLooseFEB;
126
127 for(unsigned int iFeb=0; iFeb<mnbtightFEB.size(); iFeb++)
128 v_candidate_MNBTightFEB.push_back(mnbtightFEB.at(iFeb).get_identifier32().get_compact());
129
130 for(unsigned int iFeb=0; iFeb<mnbtight_PsVetoFEB.size(); iFeb++)
131 v_candidate_MNBTight_PsVetoFEB.push_back(mnbtight_PsVetoFEB.at(iFeb).get_identifier32().get_compact());
132
133 if (m_storeLooseMNBFEBs){ // joboption - By default the FEB flagged as MNB-Loose are not stored in the TTree
134 for(unsigned int iFeb=0; iFeb<mnblooseFEB.size(); iFeb++)
135 v_candidate_MNBLooseFEB.push_back(mnblooseFEB.at(iFeb).get_identifier32().get_compact());
136 }
137
138 if(v_candidate_MNBLooseFEB.size() > 0 || v_candidate_MNBTightFEB.size() > 0) {
139 auto candidate_MNB_time = Monitored::Scalar<unsigned int>("candidate_MNB_time", eventInfo->timeStamp());
140 auto candidate_MNB_time_ns = Monitored::Scalar<unsigned int>("candidate_MNB_time_ns", eventInfo->timeStampNSOffset());
141 auto n_candidate_MNBTight_FEB = Monitored::Scalar<unsigned int>("n_candidate_MNBTight_FEB", mnbtightFEB.size());
142 auto n_candidate_MNBTight_PsVeto_FEB = Monitored::Scalar<unsigned int>("n_candidate_MNBTight_PsVeto_FEB", mnbtightFEB.size());
143 auto n_candidate_MNBLoose_FEB = Monitored::Scalar<unsigned int>("n_candidate_MNBLoose_FEB", mnblooseFEB.size());
144
145 auto mon_candidate_MNBTightFEB = Monitored::Collection("v_candidate_MNBTightFEB", v_candidate_MNBTightFEB);
146 auto mon_candidate_MNBTight_PsVetoFEB = Monitored::Collection("v_candidate_MNBTight_PsVetoFEB", v_candidate_MNBTight_PsVetoFEB);
147 auto mon_candidate_MNBLooseFEB = Monitored::Collection("v_candidate_MNBLooseFEB", v_candidate_MNBLooseFEB);
148
149 ATH_MSG_DEBUG("Filling CandidateMNB tree");
150
151 fill(m_MonGroupName,candidate_MNB_time,candidate_MNB_time_ns,n_candidate_MNBTight_FEB,n_candidate_MNBTight_PsVeto_FEB,n_candidate_MNBLoose_FEB,mon_candidate_MNBTightFEB,mon_candidate_MNBTight_PsVetoFEB,mon_candidate_MNBLooseFEB);
152 }
153
154 // Fill the noise bursts timestamp ttree
155 auto time = Monitored::Scalar<int>("time",eventInfo->timeStamp());
156 auto time_ns = Monitored::Scalar<int>("time_ns",eventInfo->timeStampNSOffset());
157 auto algo = Monitored::Scalar<unsigned char>("algo",0);
158 if ( eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::BADFEBS) )
159 {
160 algo |= 0x1;
161 }
162 if ( eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::TIGHTSATURATEDQ) )
163 {
164 algo |= 0x2;
165 }
166 if ( eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::BADFEBS_W) )
167 {
168 algo |= 0x8;
169 }
170 if (eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::MININOISEBURSTLOOSE))
171 {
172 algo |= 0x10;
173 }
174 if (eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::MININOISEBURSTTIGHT))
175 {
176 algo |= 0x20;
177 }
179 {
180 algo |= 0x40;
181 }
182 if (eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::BADHVLINES))
183 {
184 algo |= 0x80;
185 }
186
187 if ( algo != 0 ) {
188 if ( burstveto ) algo |= 0x4;
189 ATH_MSG_DEBUG("Filling LArNoise tree with algo: " << algo);
190 fill(m_MonGroupName,time,time_ns,algo);
191 } else {
192 ATH_MSG_DEBUG("Not a noisy event");
193 }
194
195 // Triggers
196 unsigned long trigbits = 0;
197 unsigned long L1trigbits = 0;
198 if ( m_doTrigger ) {
199 for ( size_t i = 0; i < m_EF_NoiseBurst_Triggers.size(); i++) {
200 if ( m_trigDecTool->isPassed(m_EF_NoiseBurst_Triggers[i])) trigbits |= (0x1 << i);
201 }
202 for ( size_t i = 0; i < m_L1_NoiseBurst_Triggers.size(); i++) {
203 if ( m_trigDecTool->isPassed(m_L1_NoiseBurst_Triggers[i])) L1trigbits |= (0x1 << i);
204 }
205 ATH_MSG_DEBUG("Trigger words: " << std::hex << trigbits << " " << L1trigbits << std::dec);
206 }
207 if(!m_doHisto) return StatusCode::SUCCESS;
208
209 // Fill the 2D map of noisy and mini-noisy FEBs
210 const std::vector<HWIdentifier>& noisyFEB = noisyRO->get_noisy_febs();
211
212 // Loop on all FEBs noisy in Std definition (i.e >30 channels with q factor > 4000)
213 // And fill the 2D maps of fraction of fraction of noisy events
214 unsigned int NbNoisyFEB = 0;
216
217 ATH_MSG_DEBUG("NoisyFEB vector size " << noisyFEB.size());
218
219 auto slotN=Monitored::Scalar<unsigned>("slotNoisy",0);
220 auto FTN=Monitored::Scalar<unsigned>("FTNoisy",0);
221 for (size_t i = 0; i<noisyFEB.size(); i++) {
222 NbNoisyFEB++;
223 const HWIdentifier& febid = noisyFEB[i];
224 HWIdentifier id = m_LArOnlineIDHelper->channel_Id(febid,0);
225 unsigned partition = partitionNumber(febid);
226 unsigned sd = partitionNumber(id)/2;
227
228 if (partition<4){
229 FTN = m_LArOnlineIDHelper->feedthrough(id);
230 slotN = m_LArOnlineIDHelper->slot(id);
231 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slotN,FTN);
232 }
233 } // End of loop on all RNB - noisy FEB
234
235 auto n_noisyFEB = Monitored::Scalar<int>("n_noisyFEBs",NbNoisyFEB);
236 auto lb = Monitored::Scalar<int>("LBN",LBN);
237
238 const std::vector<HWIdentifier>& noisyHVlines = noisyRO->get_noisy_hvlines();
239 unsigned int NbNoisyHVlines = noisyHVlines.size();
240 auto n_noisyHVlines = Monitored::Scalar<int>("n_noisyHVlines",NbNoisyHVlines);
241
242 fill(m_MonGroupName,n_noisyFEB,n_noisyHVlines,lb);
243;
244 // Loop on all FEBs noisy in MNB-tight definition
245 // And fill the 2D maps of fraction of fraction of noisy events
246 // Fill two histograms with veto cut and all events
247 ATH_MSG_DEBUG("MNBTight FEB vector size " << mnbtightFEB.size());
248 auto slotTightCan=Monitored::Scalar<unsigned>("slotTightCan",0);
249 auto FTTightCan=Monitored::Scalar<unsigned>("FTTightCan",0);
250 auto slotTight=Monitored::Scalar<unsigned>("slotTight",0);
251 auto FTTight=Monitored::Scalar<unsigned>("FTTight",0);
252 for (size_t i = 0; i<mnbtightFEB.size(); i++) {
253 const HWIdentifier& febid = mnbtightFEB[i];
254 HWIdentifier id = m_LArOnlineIDHelper->channel_Id(febid,0);
255 unsigned partition = partitionNumber(febid);
256
257 if (partition<4){
258 unsigned sd = partitionNumber(id)/2;
259 FTTightCan = m_LArOnlineIDHelper->feedthrough(id);
260 slotTightCan = m_LArOnlineIDHelper->slot(id);
261 // FIXME: could not this be done with cutmask ?
262 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slotTightCan,FTTightCan);
263 if((noisyRO->MNBTightFlaggedPartitions() & partMask[partition]) != 0){
264 slotTight = unsigned(slotTightCan);
265 FTTight = unsigned(FTTightCan);
266 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slotTight,FTTight);
267 }
268 }
269 }// End of loop on all MNB-Tight - noisy FEB
270
271 // Loop on all FEBs noisy in MNB-tight-PsVeto definition
272 // And fill the 2D maps of fraction of fraction of noisy events
273 // Fill two histograms with veto cut and all events
274 auto slot_PsVetoTightCan=Monitored::Scalar<unsigned>("slot_PsVetoTightCan",0);
275 auto FT_PsVetoTightCan=Monitored::Scalar<unsigned>("FT_PsVetoTightCan",0);
276 auto slot_PsVetoTight=Monitored::Scalar<unsigned>("slot_PsVetoTight",0);
277 auto FT_PsVetoTight=Monitored::Scalar<unsigned>("FT_PsVetoTight",0);
278 ATH_MSG_DEBUG("MNBTight_PsVeto FEB vector size " << mnbtight_PsVetoFEB.size());
279 for (size_t i = 0; i<mnbtight_PsVetoFEB.size(); i++) {
280 const HWIdentifier& febid = mnbtight_PsVetoFEB[i];
281 HWIdentifier id = m_LArOnlineIDHelper->channel_Id(febid,0);
282 int partition = partitionNumber(febid);
283
284 if (partition<4){
285 unsigned sd = partitionNumber(id)/2;
286 FT_PsVetoTightCan = m_LArOnlineIDHelper->feedthrough(id);
287 slot_PsVetoTightCan = m_LArOnlineIDHelper->slot(id);
288 // FIXME: could not this be done with cutmask ?
289 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slot_PsVetoTightCan,FT_PsVetoTightCan);
290 if((noisyRO->MNBTight_PsVetoFlaggedPartitions() & partMask[partition]) != 0){
291 slot_PsVetoTight = unsigned(slot_PsVetoTightCan);
292 FT_PsVetoTight = unsigned(FT_PsVetoTightCan);
293 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slot_PsVetoTight,FT_PsVetoTight);
294 }
295 }
296 }// End of loop on all MNB-Tight-PsVeto - noisy FEB
297
298 // Loop on all FEBs noisy in MNB-loose definition
299 // And fill the 2D maps of fraction of fraction of noisy events
300 // Fill two histograms with veto cut and all events
301 auto slotLooseCan=Monitored::Scalar<unsigned>("slotLooseCan",0);
302 auto FTLooseCan=Monitored::Scalar<unsigned>("FTLooseCan",0);
303 auto slotLoose=Monitored::Scalar<unsigned>("slotLoose",0);
304 auto FTLoose=Monitored::Scalar<unsigned>("FTLoose",0);
305 ATH_MSG_DEBUG("MNBLoose FEB vector size " << mnblooseFEB.size());
306 for (size_t i = 0; i<mnblooseFEB.size(); i++) {
307 const HWIdentifier& febid = mnblooseFEB[i];
308 // Will be used in next iteration:
309 HWIdentifier id = m_LArOnlineIDHelper->channel_Id(febid,0);
310 int partition = partitionNumber(febid);
311
312 if (partition<4){
313 unsigned sd = partitionNumber(id)/2;
314 FTLooseCan = m_LArOnlineIDHelper->feedthrough(id);
315 slotLooseCan = m_LArOnlineIDHelper->slot(id);
316 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slotLooseCan,FTLooseCan);
317 if((noisyRO->MNBLooseFlaggedPartitions() & partMask[partition]) != 0){
318 slotLoose = unsigned(slotLoose);
319 FTLoose = unsigned(FTLoose);
320 fill(m_tools[m_histoGroups.at(sd).at(m_partitions[partition])],slotLoose,FTLoose);
321 }
322 }
323 }// End of loop on all MNB-Loose - noisy FEB
324 // End of 2D map of FEB found as noisy (in any definition : Std, MNB-Tight, MNB-Tight-PsVeto or MNB-Loose)
325
326 // Now fill 1D histograms of events found as noisy vetoed or not
327 // Event found noisy by Std method
328 uint8_t BadFEBPartitions = noisyRO->BadFEBFlaggedPartitions();
329 if ( BadFEBPartitions != 0) {
330 auto LBStd = Monitored::Scalar<unsigned>("LBStd",LBN);
331 auto LBStdV = Monitored::Scalar<unsigned>("LBStd_Veto",LBN);
332 for (size_t i= 0;i<m_partitions.size();i++){
333 if ( (BadFEBPartitions & partMask[i]) != 0 ) {
334 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBStd);
335 if ( m_doTrigger ) {
336 fillTriggerHisto(i,trigbits,L1trigbits);
337 }
338 if ( ! burstveto ) {
339 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBStdV);
340 }
341 }
342 }
343 } // End of test on RNB
344
345 uint8_t BadHVPartitions = noisyRO->HVlineFlaggedPartitions();
346 if ( BadHVPartitions != 0) {
347 auto LBHV = Monitored::Scalar<unsigned>("LBHV",LBN);
348 auto LBHV_Veto = Monitored::Scalar<unsigned>("LBHV_Veto",LBN);
349 for (size_t i= 0;i<m_partitions.size();i++){
350 if ( (BadHVPartitions & partMask[i]) != 0 ) {
351 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBHV);
352 if ( ! burstveto ) {
353 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBHV_Veto);
354 }
355 }
356 }
357 } // End of test on HVlines
358
359 // event flagged by # of saturated quality cells
360 uint8_t SatTightPartitions = noisyRO->SatTightFlaggedPartitions();
361 if ( eventInfo->isEventFlagBitSet(xAOD::EventInfo::LAr,LArEventBitInfo::TIGHTSATURATEDQ) ) {
362 auto LBSat = Monitored::Scalar<unsigned>("LBSat",LBN);
363 auto LBSatV = Monitored::Scalar<unsigned>("LBSat_Veto",LBN);
364 for (size_t i= 0;i<m_partitions.size();i++){
365 if ( (SatTightPartitions & partMask[i]) != 0 ) {
366 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBSat);
367 if ( ! burstveto ) {
368 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBSatV);
369 }
370 }
371 }
372 } // end of test on RNB-Saturated
373
374
375 // event flagged by tight-MNB
376 uint8_t MNBTightPartitions = noisyRO->MNBTightFlaggedPartitions();
377 if ( MNBTightPartitions != 0) {
378 auto LBMTight = Monitored::Scalar<unsigned>("LBMNBTight",LBN);
379 auto LBMTightV = Monitored::Scalar<unsigned>("LBMNBTight_Veto",LBN);
380 for (size_t i= 0;i<m_partitions.size();i++){
381 if ( (MNBTightPartitions & partMask[i]) != 0 ) {
382 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBMTight);
383 if ( ! burstveto ) {
384 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBMTightV);
385 }
386 }
387 }
388 } // End of test on MNB-Tight
389
390 // event flagged by tight-MNB-PsVeto
391 uint8_t MNBTight_PsVetoPartitions = noisyRO->MNBTight_PsVetoFlaggedPartitions();
392 if ( MNBTight_PsVetoPartitions != 0) {
393 auto LBMTight_PsVeto = Monitored::Scalar<unsigned>("LBMNBTight_PsVeto",LBN);
394 auto LBMTight_PsVetoV = Monitored::Scalar<unsigned>("LBMNBTight_PsVeto_Veto",LBN);
395 for (size_t i= 0;i<m_partitions.size();i++){
396 if ( (MNBTight_PsVetoPartitions & partMask[i]) != 0 ) {
397 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBMTight_PsVeto);
398 if ( ! burstveto ) {
399 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBMTight_PsVetoV);
400 }
401 }
402 }
403 } // End of test on MNB-Tight-PsVeto
404
405 // event flagged by loose-MNB
406 uint8_t MNBLoosePartitions = noisyRO->MNBLooseFlaggedPartitions();
407 if ( MNBLoosePartitions != 0) {
408 auto LBMLoose = Monitored::Scalar<unsigned>("LBMNBLoose",LBN);
409 auto LBMLooseV = Monitored::Scalar<unsigned>("LBMNBLoose_Veto",LBN);
410 for (size_t i= 0;i<m_partitions.size();i++){
411 if ( (MNBLoosePartitions & partMask[i]) != 0 ) {
412 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBMLoose);
413 if ( ! burstveto ) {
414 fill(m_tools[m_histoGroups.at(i/2).at(m_partitions[i])],LBMLooseV);
415 }
416 }
417 }
418 } // end fo test on MNB-Loose
419
420 return StatusCode::SUCCESS;
421}
422
424 unsigned long triggerbits, unsigned long L1triggerbits) const{
425
426 auto trig = Monitored::Scalar<unsigned>("Triggers",0);
427 if ( triggerbits ==0 ) {
428 trig = m_EF_NoiseBurst_Triggers.size()+1;
429 fill(m_tools[m_histoGroups.at(partition/2).at(m_partitions[partition])],trig);
430 } else {
431 for ( size_t i = 0; i < m_EF_NoiseBurst_Triggers.size(); i++) {
432 if ( triggerbits & (0x1 << i) ) {
433 trig = i+1;
434 fill(m_tools[m_histoGroups.at(partition/2).at(m_partitions[partition])],trig);
435 }
436 }
437 }
438
439 auto l1trig = Monitored::Scalar<unsigned>("L1Triggers",0);
440 if ( L1triggerbits ==0 ) {
441 l1trig = m_L1_NoiseBurst_Triggers.size()+1;
442 fill(m_tools[m_histoGroups.at(partition/2).at(m_partitions[partition])],l1trig);
443 } else {
444 for ( size_t i = 0; i < m_L1_NoiseBurst_Triggers.size(); i++) {
445 if ( L1triggerbits & (0x1 << i) ) {
446 l1trig = i+1;
447 fill(m_tools[m_histoGroups.at(partition/2).at(m_partitions[partition])],l1trig);
448 }
449 }
450 }
451}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_INFO(x)
#define ATH_MSG_WARNING(x)
#define ATH_MSG_DEBUG(x)
LArBadXCont< LArBadFeb > LArBadFebCont
const ServiceHandle< StoreGateSvc > & detStore() const
virtual StatusCode initialize() override
initialize
SG::ReadHandle< xAOD::EventInfo > GetEventInfo(const EventContext &) const
Return a ReadHandle for an EventInfo object (get run/event numbers, etc.)
PublicToolHandle< Trig::TrigDecisionTool > m_trigDecTool
Tool to tell whether a specific trigger is passed.
AthMonitorAlgorithm(const std::string &name, ISvcLocator *pSvcLocator)
Constructor.
ToolHandleArray< GenericMonitoringTool > m_tools
Array of Generic Monitoring Tools.
const_iterator end() const
Access to the end iterator of the underlying vector.
size_type size() const
Number of known bad channels.
const_iterator begin() const
Access to the begin iterator of the underlying vector.
BadChanVec::const_iterator const_iterator
LArNoisyROMonAlg(const std::string &name, ISvcLocator *pSvcLocator)
Gaudi::Property< std::vector< std::string > > m_EF_NoiseBurst_Triggers
Gaudi::Property< std::vector< std::string > > m_L1_NoiseBurst_Triggers
virtual StatusCode fillHistograms(const EventContext &ctx) const override final
adds event to the monitoring histograms
void fillTriggerHisto(size_t partition, unsigned long triggerbits, unsigned long L1triggerbits) const
std::vector< std::map< std::string, int > > m_histoGroups
SG::ReadHandleKey< LArNoisyROSummary > m_inputKey
Gaudi::Property< bool > m_doTrigger
size_t partitionNumber(const HWIdentifier) const
Gaudi::Property< std::string > m_MonGroupName
const LArOnlineID * m_LArOnlineIDHelper
Gaudi::Property< bool > m_storeLooseMNBFEBs
Gaudi::Property< std::vector< std::string > > m_partitions
SG::ReadCondHandleKey< LArBadFebCont > m_badFebKey
virtual StatusCode initialize() override final
initialize
SG::ReadDecorHandleKey< xAOD::EventInfo > m_eventInfoDecorKey
SG::ReadCondHandleKey< LArHVIdMapping > m_hvMapKey
SG::ReadCondHandleKey< LArBadFebCont > m_MNBFebKey
Gaudi::Property< bool > m_doHisto
Gaudi::Property< std::vector< std::string > > m_SubDetNames
void fillHistogramsOnce(const EventContext &ctx, const bool isMC) const
Declare a monitored scalar variable.
virtual bool isValid() override final
Can the handle be successfully dereferenced?
@ LAr
The LAr calorimeter.
@ IS_SIMULATION
true: simulation, false: data
int lb
Definition globals.cxx:23
std::vector< V > buildToolMap(const ToolHandleArray< GenericMonitoringTool > &tools, const std::string &baseName, int nHist)
Builds an array of indices (base case)
ValuesCollection< T > Collection(std::string name, const T &collection)
Declare a monitored (double-convertible) collection.
void fill(H5::Group &out_file, size_t iterations)