CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
MonitorLTC Class Reference

#include <MonitorLTC.h>

Inheritance diagram for MonitorLTC:
DQMEDAnalyzer edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >

Public Member Functions

void analyze (const edm::Event &, const edm::EventSetup &) override
 
void bookHistograms (DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override
 
 MonitorLTC (const edm::ParameterSet &)
 
 ~MonitorLTC () override
 
- Public Member Functions inherited from DQMEDAnalyzer
void accumulate (edm::Event const &event, edm::EventSetup const &setup) final
 
void beginLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void beginRun (edm::Run const &run, edm::EventSetup const &setup) final
 
void beginStream (edm::StreamID id) final
 
virtual void dqmBeginRun (edm::Run const &, edm::EventSetup const &)
 
 DQMEDAnalyzer ()
 
void endLuminosityBlock (edm::LuminosityBlock const &lumi, edm::EventSetup const &setup) final
 
void endRun (edm::Run const &run, edm::EventSetup const &setup) final
 
virtual bool getCanSaveByLumi ()
 
- Public Member Functions inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
 EDProducer ()=default
 
 EDProducer (const EDProducer &)=delete
 
bool hasAbilityToProduceInBeginLumis () const final
 
bool hasAbilityToProduceInBeginProcessBlocks () const final
 
bool hasAbilityToProduceInBeginRuns () const final
 
bool hasAbilityToProduceInEndLumis () const final
 
bool hasAbilityToProduceInEndProcessBlocks () const final
 
bool hasAbilityToProduceInEndRuns () const final
 
const EDProduceroperator= (const EDProducer &)=delete
 

Private Attributes

edm::ParameterSet conf_
 
std::string HLTDirectory
 
edm::EDGetTokenT< LTCDigiCollectionltcDigiCollectionTagToken_
 
MonitorElementLTCTriggerDecision_all
 

Additional Inherited Members

- Public Types inherited from DQMEDAnalyzer
typedef dqm::reco::DQMStore DQMStore
 
typedef dqm::reco::MonitorElement MonitorElement
 
- Public Types inherited from edm::stream::EDProducer< edm::GlobalCache< DQMEDAnalyzerGlobalCache >, edm::EndRunProducer, edm::EndLuminosityBlockProducer, edm::Accumulator >
using CacheTypes = CacheContexts< T... >
 
using GlobalCache = typename CacheTypes::GlobalCache
 
using HasAbility = AbilityChecker< T... >
 
using InputProcessBlockCache = typename CacheTypes::InputProcessBlockCache
 
using LuminosityBlockCache = typename CacheTypes::LuminosityBlockCache
 
using LuminosityBlockContext = LuminosityBlockContextT< LuminosityBlockCache, RunCache, GlobalCache >
 
using LuminosityBlockSummaryCache = typename CacheTypes::LuminosityBlockSummaryCache
 
using RunCache = typename CacheTypes::RunCache
 
using RunContext = RunContextT< RunCache, GlobalCache >
 
using RunSummaryCache = typename CacheTypes::RunSummaryCache
 
- Static Public Member Functions inherited from DQMEDAnalyzer
static void globalEndJob (DQMEDAnalyzerGlobalCache const *)
 
static void globalEndLuminosityBlockProduce (edm::LuminosityBlock &lumi, edm::EventSetup const &setup, LuminosityBlockContext const *context)
 
static void globalEndRunProduce (edm::Run &run, edm::EventSetup const &setup, RunContext const *context)
 
static std::unique_ptr< DQMEDAnalyzerGlobalCacheinitializeGlobalCache (edm::ParameterSet const &)
 
- Protected Member Functions inherited from DQMEDAnalyzer
uint64_t meId () const
 
- Protected Attributes inherited from DQMEDAnalyzer
edm::EDPutTokenT< DQMTokenlumiToken_
 
edm::EDPutTokenT< DQMTokenrunToken_
 
unsigned int streamId_
 

Detailed Description

Definition at line 24 of file MonitorLTC.h.

Constructor & Destructor Documentation

◆ MonitorLTC()

MonitorLTC::MonitorLTC ( const edm::ParameterSet iConfig)
explicit

Definition at line 17 of file MonitorLTC.cc.

19 {
20  HLTDirectory = "HLTResults";
21  conf_ = iConfig;
22 
23  ltcDigiCollectionTagToken_ = consumes<LTCDigiCollection>(conf_.getParameter<edm::InputTag>("ltcDigiCollectionTag"));
24 }

References conf_, edm::ParameterSet::getParameter(), HLTDirectory, and ltcDigiCollectionTagToken_.

◆ ~MonitorLTC()

MonitorLTC::~MonitorLTC ( )
inlineoverride

Definition at line 27 of file MonitorLTC.h.

27 {};

Member Function Documentation

◆ analyze()

void MonitorLTC::analyze ( const edm::Event iEvent,
const edm::EventSetup iSetup 
)
overridevirtual

Reimplemented from DQMEDAnalyzer.

Definition at line 46 of file MonitorLTC.cc.

46  {
48  iEvent.getByToken(ltcDigiCollectionTagToken_, ltcdigis);
49  // unsigned int ltc_run;
50  // unsigned int ltc_event;
51  // unsigned int ltc_triggerNumber;
52  // unsigned int ltc_mask; // eight bits
53  // unsigned long long int ltc_gpstime;
54  // unsigned int ltc_orbit;
55  // unsigned int ltc_bunch;
56  // unsigned int ltc_inhibit;
57  for (LTCDigiCollection::const_iterator ltcdigiItr = ltcdigis->begin(); ltcdigiItr != ltcdigis->end(); ++ltcdigiItr) {
58  // ltc_run = ltcdigiItr->runNumber();
59  // ltc_event = ltcdigiItr->eventNumber();
60  // ltc_triggerNumber = ltcdigiItr->eventID();
61  // ltc_bunch = ltcdigiItr->bunchNumber();
62  // ltc_orbit = ltcdigiItr->orbitNumber();
63  // ltc_inhibit = ltcdigiItr->triggerInhibitNumber();
64  // ltc_mask = (unsigned int)(ltcdigiItr->externTriggerMask());
65  // ltc_gpstime = ltcdigiItr->bstGpsTime();
66  for (int ibit = 0; ibit < 7; ++ibit) {
67  if (ltcdigiItr->HasTriggered(ibit)) {
68  LTCTriggerDecision_all->Fill(ibit, 1.);
69  }
70  }
71  //
72  // std::cout << "XXX: "
73  // << ltcdigiItr->runNumber() << " "
74  // << ltcdigiItr->eventNumber() << " "
75  // << ltcdigiItr->bunchNumber() << " "
76  // << ltcdigiItr->orbitNumber() << " "
77  // << "0x" << std::hex
78  // << int(ltcdigiItr->externTriggerMask()) << " "
79  // << std::dec
80  // << ltcdigiItr->triggerInhibitNumber() << " "
81  // << ltcdigiItr->bstGpsTime() << " "
82  // << std::endl;
83  // std::cout << (*ltcdigiItr) << std::endl;
84  }
85 }

References dqm::impl::MonitorElement::Fill(), iEvent, ltcDigiCollectionTagToken_, and LTCTriggerDecision_all.

◆ bookHistograms()

void MonitorLTC::bookHistograms ( DQMStore::IBooker ibooker,
edm::Run const &  run,
edm::EventSetup const &  es 
)
overridevirtual

Implements DQMEDAnalyzer.

Definition at line 26 of file MonitorLTC.cc.

26  {
28  // 0 DT
29  // 1 CSC
30  // 2 RBC1 (RPC techn. cosmic trigger for wheel +1, sector 10)
31  // 3 RBC2 (RPC techn. cosmic trigger for wheel +2, sector 10)
32  // 4 RPCTB (RPC Trigger Board trigger, covering both sectors 10 of both
33  // wheels, but with different geometrical acceptance ("pointing")) 5 unused
34  // edm::CurrentProcessingContext const* current_processing_context =
35  // currentContext(); std::string const* the_label = moduleLabel();
36  std::string the_label = conf_.getParameter<std::string>("@module_label");
37  std::string ltctitle = the_label + "_LTCTriggerDecision";
38  LTCTriggerDecision_all = ibooker.book1D(ltctitle, ltctitle, 8, -0.5, 7.5);
44 }

References dqm::implementation::IBooker::book1D(), conf_, edm::ParameterSet::getParameter(), HLTDirectory, LTCTriggerDecision_all, dqm::impl::MonitorElement::setBinLabel(), dqm::implementation::NavigatorBase::setCurrentFolder(), and AlCaHLTBitMon_QueryRunRegistry::string.

Member Data Documentation

◆ conf_

edm::ParameterSet MonitorLTC::conf_
private

Definition at line 32 of file MonitorLTC.h.

Referenced by bookHistograms(), and MonitorLTC().

◆ HLTDirectory

std::string MonitorLTC::HLTDirectory
private

Definition at line 36 of file MonitorLTC.h.

Referenced by bookHistograms(), and MonitorLTC().

◆ ltcDigiCollectionTagToken_

edm::EDGetTokenT<LTCDigiCollection> MonitorLTC::ltcDigiCollectionTagToken_
private

Definition at line 38 of file MonitorLTC.h.

Referenced by analyze(), and MonitorLTC().

◆ LTCTriggerDecision_all

MonitorElement* MonitorLTC::LTCTriggerDecision_all
private

Definition at line 34 of file MonitorLTC.h.

Referenced by analyze(), and bookHistograms().

dqm::implementation::NavigatorBase::setCurrentFolder
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
MonitorLTC::conf_
edm::ParameterSet conf_
Definition: MonitorLTC.h:32
MonitorLTC::HLTDirectory
std::string HLTDirectory
Definition: MonitorLTC.h:36
MonitorLTC::ltcDigiCollectionTagToken_
edm::EDGetTokenT< LTCDigiCollection > ltcDigiCollectionTagToken_
Definition: MonitorLTC.h:38
edm::Handle< LTCDigiCollection >
dqm::impl::MonitorElement::Fill
void Fill(long long x)
Definition: MonitorElement.h:290
MonitorLTC::LTCTriggerDecision_all
MonitorElement * LTCTriggerDecision_all
Definition: MonitorLTC.h:34
iEvent
int iEvent
Definition: GenABIO.cc:224
dqm::impl::MonitorElement::setBinLabel
virtual void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
Definition: MonitorElement.cc:762
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
edm::InputTag
Definition: InputTag.h:15
dqm::implementation::IBooker::book1D
MonitorElement * book1D(TString const &name, TString const &title, int const nchX, double const lowX, double const highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:98