#include <MonitorLTC.h>
Public Member Functions | |
virtual void | analyze (const edm::Event &, const edm::EventSetup &) |
virtual void | beginJob () |
virtual void | endJob () |
MonitorLTC (const edm::ParameterSet &) | |
~MonitorLTC () | |
Private Attributes | |
edm::ParameterSet | conf_ |
DQMStore * | dqmStore_ |
std::string | HLTDirectory |
edm::InputTag | ltcDigiCollectionTag_ |
MonitorElement * | LTCTriggerDecision_all |
Definition at line 26 of file MonitorLTC.h.
MonitorLTC::MonitorLTC | ( | const edm::ParameterSet & | iConfig | ) | [explicit] |
Definition at line 21 of file MonitorLTC.cc.
References conf_, dqmStore_, HLTDirectory, and cppFunctionSkipper::operator.
: ltcDigiCollectionTag_(iConfig.getParameter<edm::InputTag>("ltcDigiCollectionTag")) { HLTDirectory="HLTResults"; dqmStore_ = edm::Service<DQMStore>().operator->(); conf_ = iConfig; }
MonitorLTC::~MonitorLTC | ( | ) | [inline] |
Definition at line 29 of file MonitorLTC.h.
{};
void MonitorLTC::analyze | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup | ||
) | [virtual] |
Implements edm::EDAnalyzer.
Definition at line 50 of file MonitorLTC.cc.
References MonitorElement::Fill(), edm::Event::getByLabel(), ltcDigiCollectionTag_, and LTCTriggerDecision_all.
{ edm::Handle<LTCDigiCollection> ltcdigis; iEvent.getByLabel(ltcDigiCollectionTag_, ltcdigis); // unsigned int ltc_run; // unsigned int ltc_event; // unsigned int ltc_triggerNumber; // unsigned int ltc_mask; // eight bits // unsigned long long int ltc_gpstime; // unsigned int ltc_orbit; // unsigned int ltc_bunch; // unsigned int ltc_inhibit; for( LTCDigiCollection::const_iterator ltcdigiItr = ltcdigis->begin() ; ltcdigiItr != ltcdigis->end() ; ++ltcdigiItr ) { // ltc_run = ltcdigiItr->runNumber(); // ltc_event = ltcdigiItr->eventNumber(); // ltc_triggerNumber = ltcdigiItr->eventID(); // ltc_bunch = ltcdigiItr->bunchNumber(); // ltc_orbit = ltcdigiItr->orbitNumber(); // ltc_inhibit = ltcdigiItr->triggerInhibitNumber(); // ltc_mask = (unsigned int)(ltcdigiItr->externTriggerMask()); // ltc_gpstime = ltcdigiItr->bstGpsTime(); for ( int ibit = 0; ibit < 7; ++ibit ) { if ( ltcdigiItr->HasTriggered(ibit) ) { LTCTriggerDecision_all->Fill(ibit,1.); } } // // std::cout << "XXX: " // << ltcdigiItr->runNumber() << " " // << ltcdigiItr->eventNumber() << " " // << ltcdigiItr->bunchNumber() << " " // << ltcdigiItr->orbitNumber() << " " // << "0x" << std::hex // << int(ltcdigiItr->externTriggerMask()) << " " // << std::dec // << ltcdigiItr->triggerInhibitNumber() << " " // << ltcdigiItr->bstGpsTime() << " " // << std::endl; // std::cout << (*ltcdigiItr) << std::endl; } }
void MonitorLTC::beginJob | ( | void | ) | [virtual] |
Reimplemented from edm::EDAnalyzer.
Definition at line 30 of file MonitorLTC.cc.
References DQMStore::book1D(), conf_, dqmStore_, edm::ParameterSet::getParameter(), HLTDirectory, LTCTriggerDecision_all, MonitorElement::setBinLabel(), DQMStore::setCurrentFolder(), and AlCaHLTBitMon_QueryRunRegistry::string.
{ dqmStore_->setCurrentFolder(HLTDirectory); // 0 DT // 1 CSC // 2 RBC1 (RPC techn. cosmic trigger for wheel +1, sector 10) // 3 RBC2 (RPC techn. cosmic trigger for wheel +2, sector 10) // 4 RPCTB (RPC Trigger Board trigger, covering both sectors 10 of both wheels, but with different geometrical acceptance ("pointing")) // 5 unused // edm::CurrentProcessingContext const* current_processing_context = currentContext(); // std::string const* the_label = moduleLabel(); std::string the_label = conf_.getParameter<std::string>("@module_label"); std::string ltctitle = the_label + "_LTCTriggerDecision"; LTCTriggerDecision_all = dqmStore_->book1D(ltctitle, ltctitle, 8, -0.5, 7.5); LTCTriggerDecision_all->setBinLabel(1, "DT"); LTCTriggerDecision_all->setBinLabel(2, "CSC"); LTCTriggerDecision_all->setBinLabel(3, "RBC1"); LTCTriggerDecision_all->setBinLabel(4, "RBC2"); LTCTriggerDecision_all->setBinLabel(5, "RPCTB"); }
void MonitorLTC::endJob | ( | void | ) | [virtual] |
Reimplemented from edm::EDAnalyzer.
Definition at line 92 of file MonitorLTC.cc.
References conf_, dqmStore_, edm::ParameterSet::getParameter(), dumpDBToFile_GT_ttrig_cfg::outputFileName, DQMStore::save(), and AlCaHLTBitMon_QueryRunRegistry::string.
{ bool outputMEsInRootFile = conf_.getParameter<bool>("OutputMEsInRootFile"); std::string outputFileName = conf_.getParameter<std::string>("OutputFileName"); if(outputMEsInRootFile){ dqmStore_->save(outputFileName); } }
edm::ParameterSet MonitorLTC::conf_ [private] |
Definition at line 35 of file MonitorLTC.h.
Referenced by beginJob(), endJob(), and MonitorLTC().
DQMStore* MonitorLTC::dqmStore_ [private] |
Definition at line 34 of file MonitorLTC.h.
Referenced by beginJob(), endJob(), and MonitorLTC().
std::string MonitorLTC::HLTDirectory [private] |
Definition at line 39 of file MonitorLTC.h.
Referenced by beginJob(), and MonitorLTC().
Definition at line 40 of file MonitorLTC.h.
Referenced by analyze().
MonitorElement* MonitorLTC::LTCTriggerDecision_all [private] |
Definition at line 37 of file MonitorLTC.h.
Referenced by analyze(), and beginJob().