Analyze.
452 LogTrace(
"DTDQM|DTMonitorModule|DTDigiTask") <<
"[DTDigiTask] Analyze #Run: " <<
event.id().run()
453 <<
" #Event: " <<
event.id().event() << endl;
475 if(dtdigis->begin() == dtdigis->end()) {
476 LogTrace(
"DTDQM|DTMonitorModule|DTDigiTask") <<
"Event " <<
nevents <<
" empty." << endl;
482 for (dtLayerId_It=dtdigis->begin(); dtLayerId_It!=dtdigis->end(); dtLayerId_It++) {
483 DTChamberId chId = ((*dtLayerId_It).first).chamberId();
487 hitMap[chId] += (((*dtLayerId_It).second).
second - ((*dtLayerId_It).second).first);
493 map<DTChamberId,int>::const_iterator hitMapIt =
hitMap.begin();
494 map<DTChamberId,int>::const_iterator hitMapEnd =
hitMap.end();
498 for (; hitMapIt != hitMapEnd; ++hitMapIt) {
502 int wh = chId.
wheel();
504 LogTrace(
"DTDQM|DTMonitorModule|DTDigiTask") <<
"[DTDigiTask] Synch noise in chamber: " << chId
505 <<
" with # digis: " << hitMapIt->second << endl;
507 if(chMap.find(wh) == chMap.end()) { chMap[wh] = 0; }
518 map<int,int>::const_iterator chMapIt = chMap.begin();
519 map<int,int>::const_iterator chMapEnd = chMap.end();
520 for (; chMapIt != chMapEnd; ++chMapIt) {
521 wheelHistos[
"SyncNoiseChambs"][(*chMapIt).first]->Fill((*chMapIt).second);
528 LogVerbatim(
"DTDQM|DTMonitorModule|DTDigiTask") <<
"[DTDigiTask] Synch Noise in event: " <<
nevents;
529 if(
filterSyncNoise)
LogVerbatim(
"DTDQM|DTMonitorModule|DTDigiTask") <<
"\tnoisy time-boxes and occupancy will not be filled!" << endl;
536 time_t eventTime = time_t(
event.time().value()>>32);
538 LogVerbatim(
"DTDQM|DTMonitorModule|DTDigiTask|DTSynchNoise")
539 <<
"[DTDigiTask] At least 4 Synch Noisy chambers in Run : " <<
event.id().run()
540 <<
" Lumi : " <<
event.id().luminosityBlock()
541 <<
" Event : " <<
event.id().event()
542 <<
" at time : " << ctime(&eventTime) << endl;
547 stringstream synchNoisyCh;
548 for (;chIt!=chEnd;++chIt) { synchNoisyCh <<
" " << (*chIt); }
549 LogVerbatim(
"DTDQM|DTMonitorModule|DTDigiTask|DTSynchNoise") <<
550 "[DTDigiTask] Chamber List :" << synchNoisyCh.str() << endl;
555 << (
syncNum*0.1) <<
"% sync noise events in the last 1000 events " << endl;
560 bool isSyncNoisy =
false;
563 for (dtLayerId_It=dtdigis->begin(); dtLayerId_It!=dtdigis->end(); ++dtLayerId_It) {
567 DTChamberId chId = ((*dtLayerId_It).first).chamberId();
574 digiIt!=((*dtLayerId_It).second).
second; ++digiIt) {
576 bool isNoisy =
false;
577 bool isFEMasked =
false;
578 bool isTDCMasked =
false;
579 bool isTrigMask =
false;
583 const DTWireId wireId(((*dtLayerId_It).first), (*digiIt).wire());
584 statusMap->cellStatus(wireId, isNoisy, isFEMasked, isTDCMasked, isTrigMask, isDead, isNohv);
588 const DTSuperLayerId dtSLId = ((*dtLayerId_It).first).superlayerId();
589 uint32_t indexSL = dtSLId.
rawId();
591 uint32_t indexCh = dtChId.
rawId();
592 int layer_number=((*dtLayerId_It).first).layer();
598 tTrigMap->get( ((*dtLayerId_It).first).superlayerId(),
605 float t0;
float t0RMS;
606 int tdcTime = (*digiIt).countsTDC();
609 const DTWireId dtWireId(((*dtLayerId_It).first), (*digiIt).wire());
612 tdcTime += int(round(t0));
619 if (( !isNoisy ) && (!isSyncNoisy)) {
623 (
digiHistos.find(histoTag)->second).
find(indexSL)->second->Fill(tdcTime);
633 histoTag =
"OccupancyAllHits_perCh";
634 map<uint32_t, MonitorElement*>::const_iterator mappedHisto =
644 mappedHisto->second->Fill((*digiIt).wire(),(layer_number+(superlayer_number-1)*4)-1);
648 histoTag =
"OccupancyAllHits";
649 map<int, MonitorElement*>::const_iterator histoPerWheel =
652 histoPerWheel->second->Fill(dtChId.
sector(),dtChId.
station());
656 if (tdcTime < inTimeHitsLowerBoundCorr ) {
661 histoTag =
"OccupancyNoise_perCh";
662 map<uint32_t, MonitorElement*>::const_iterator mappedHisto =
665 mappedHisto->second->Fill((*digiIt).wire(),
666 (layer_number+(superlayer_number-1)*4)-1);
669 histoTag =
"OccupancyNoise";
670 map<int, MonitorElement*>::const_iterator histoPerWheel =
673 histoPerWheel->second->Fill(dtChId.
sector(),dtChId.
station());
679 if (tdcTime > inTimeHitsLowerBoundCorr && tdcTime < inTimeHitsUpperBoundCorr) {
683 histoTag =
"OccupancyInTimeHits_perCh";
684 map<uint32_t, MonitorElement*>::const_iterator mappedHisto =
687 mappedHisto->second->Fill((*digiIt).wire(),
688 (layer_number+(superlayer_number-1)*4)-1);
691 histoTag =
"OccupancyInTimeHits";
692 map<int, MonitorElement*>::const_iterator histoPerWheel =
695 histoPerWheel->second->Fill(dtChId.
sector(),dtChId.
station());
DTChamberId chamberId() const
Return the corresponding ChamberId.
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
edm::ESHandle< DTTtrig > tTrigMap
uint32_t rawId() const
get the raw id
U second(std::pair< T, U > const &p)
edm::EDGetTokenT< DTDigiCollection > dtDigiToken_
edm::ESHandle< DTT0 > t0Map
std::map< std::string, std::map< int, MonitorElement * > > wheelHistos
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of"!*"before the partial wildcard feature was incorporated).The per-event"cost"of each negative criterion with multiple relevant triggers is about the same as!*was in the past
float tTrig
tTrig from the DB
int tMax
no needs to be precise. Value from PSets will always be used
int superlayer() const
Return the superlayer number (deprecated method name)
bool doAllHitsOccupancies
std::vector< DTDigi >::const_iterator const_iterator
std::set< DTChamberId > syncNoisyChambers
MonitorElement * nEventMonitor
std::map< DTChamberId, int > hitMap
int station() const
Return the station number.
std::map< std::string, std::map< uint32_t, MonitorElement * > > digiHistos
int wheel() const
Return the wheel number.
std::string triggerSource()
get the L1A source
edm::Handle< LTCDigiCollection > ltcdigis
edm::EDGetTokenT< LTCDigiCollection > ltcDigiCollectionToken_