CMS 3D CMS Logo

DTLocalTriggerBaseTest.h
Go to the documentation of this file.
1 #ifndef DTLocalTriggerBaseTest_H
2 #define DTLocalTriggerBaseTest_H
3 
23 
26 
28 
29 #include <string>
30 #include <map>
31 
32 class DTChamberId;
33 class DTGeometry;
34 class TH1F;
35 class TH2F;
36 class TH1D;
37 
39 public:
42 
44  ~DTLocalTriggerBaseTest() override;
45 
46 protected:
48  void beginRun(edm::Run const& run, edm::EventSetup const& context) override;
49 
53  edm::LuminosityBlock const&,
54  edm::EventSetup const&) override;
55 
57  void endRun(edm::Run const& run, edm::EventSetup const& context) override;
58 
60 
63 
65  void bookSectorHistos(DQMStore::IBooker&, int wheel, int sector, std::string hTag, std::string folder = "");
66 
69 
71  void bookCmsHistos(DQMStore::IBooker&, std::string hTag, std::string folder = "", bool isGlb = false);
72 
74  std::pair<float, float> phiRange(const DTChamberId& id);
75 
77  template <class T>
79 
82 
85 
88 
91 
93  inline std::string& topFolder() { return baseFolderTM; };
94 
96  inline std::string category() { return "DTDQM|DTMonitorClient|" + testName + "Test"; };
97 
98  int nevents;
99  unsigned int nLumiSegs;
101  int run;
103  std::vector<std::string> trigSources;
104  std::vector<std::string> hwSources;
105 
108  bool runOnline;
113  std::map<int, std::map<std::string, MonitorElement*> > secME;
114  std::map<int, std::map<std::string, MonitorElement*> > whME;
115  std::map<std::string, MonitorElement*> cmsME;
116 };
117 
118 template <class T>
120  return me ? dynamic_cast<T*>(me->getRootObject()) : nullptr;
121 }
122 
123 #endif
DQMEDHarvester.h
DTGeometry
Definition: DTGeometry.h:28
DTLocalTriggerBaseTest::sourceFolder
std::string sourceFolder
Definition: DTLocalTriggerBaseTest.h:106
Handle.h
DTLocalTriggerBaseTest::dqmEndJob
void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override
Definition: DTLocalTriggerBaseTest.cc:65
DTLocalTriggerBaseTest::cmsME
std::map< std::string, MonitorElement * > cmsME
Definition: DTLocalTriggerBaseTest.h:115
DTLocalTriggerBaseTest::nLumiSegs
unsigned int nLumiSegs
Definition: DTLocalTriggerBaseTest.h:99
DTLocalTriggerBaseTest::beginRun
void beginRun(edm::Run const &run, edm::EventSetup const &context) override
BeginRun.
Definition: DTLocalTriggerBaseTest.cc:37
ESHandle.h
edm::LuminosityBlock
Definition: LuminosityBlock.h:50
edm::Run
Definition: Run.h:45
printsummarytable.folder
folder
Definition: printsummarytable.py:7
LuminosityBlock.h
DTLocalTriggerBaseTest::hwSources
std::vector< std::string > hwSources
Definition: DTLocalTriggerBaseTest.h:104
DQMStore.h
DTLocalTriggerBaseTest::fullName
std::string fullName(std::string htype)
Create fullname from histo partial name.
Definition: DTLocalTriggerBaseTest.cc:99
DTLocalTriggerBaseTest::getMEName
std::string getMEName(std::string histoTag, std::string subfolder, const DTChamberId &chambid)
Get the ME name (by chamber)
dqm::legacy::MonitorElement
Definition: MonitorElement.h:462
EDAnalyzer.h
DTLocalTriggerBaseTest::bookCmsHistos
void bookCmsHistos(DQMStore::IBooker &, std::string hTag, std::string folder="", bool isGlb=false)
Book the new MEs (CMS summary)
Definition: DTLocalTriggerBaseTest.cc:194
DTLocalTriggerBaseTest::phiRange
std::pair< float, float > phiRange(const DTChamberId &id)
Calculate phi range for histograms.
Definition: DTLocalTriggerBaseTest.cc:259
DTLocalTriggerBaseTest::whME
std::map< int, std::map< std::string, MonitorElement * > > whME
Definition: DTLocalTriggerBaseTest.h:114
DTLocalTriggerBaseTest::runOnline
bool runOnline
Definition: DTLocalTriggerBaseTest.h:108
DTLocalTriggerBaseTest::setConfig
void setConfig(const edm::ParameterSet &ps, std::string name)
Set configuration variables.
Definition: DTLocalTriggerBaseTest.cc:78
MakerMacros.h
DTLocalTriggerBaseTest::~DTLocalTriggerBaseTest
~DTLocalTriggerBaseTest() override
Destructor.
Definition: DTLocalTriggerBaseTest.cc:33
Service.h
DTLocalTriggerBaseTest::run
int run
Definition: DTLocalTriggerBaseTest.h:101
edm::ESHandle< DTGeometry >
DTLocalTriggerBaseTest::bookSectorHistos
void bookSectorHistos(DQMStore::IBooker &, int wheel, int sector, std::string hTag, std::string folder="")
Book the new MEs (for each sector)
Definition: DTLocalTriggerBaseTest.cc:134
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
DTLocalTriggerBaseTest
Definition: DTLocalTriggerBaseTest.h:38
edm::ParameterSet
Definition: ParameterSet.h:47
Event.h
dtResolutionTest_cfi.histoTag
histoTag
Definition: dtResolutionTest_cfi.py:21
makeMuonMisalignmentScenario.wheel
wheel
Definition: makeMuonMisalignmentScenario.py:319
DTLocalTriggerBaseTest::secME
std::map< int, std::map< std::string, MonitorElement * > > secME
Definition: DTLocalTriggerBaseTest.h:113
edm::EventSetup
Definition: EventSetup.h:58
DTLocalTriggerBaseTest::hwSource
std::string hwSource
Definition: DTLocalTriggerBaseTest.h:111
DTLocalTriggerBaseTest::muonGeom
edm::ESHandle< DTGeometry > muonGeom
Definition: DTLocalTriggerBaseTest.h:112
DTLocalTriggerBaseTest::nevents
int nevents
Definition: DTLocalTriggerBaseTest.h:96
DTLocalTriggerBaseTest::bookWheelHistos
void bookWheelHistos(DQMStore::IBooker &, int wheel, std::string hTag, std::string folder="")
Book the new MEs (for each wheel)
Definition: DTLocalTriggerBaseTest.cc:211
DTLocalTriggerBaseTest::prescaleFactor
int prescaleFactor
Definition: DTLocalTriggerBaseTest.h:100
DTLocalTriggerBaseTest::trigSource
std::string trigSource
Definition: DTLocalTriggerBaseTest.h:110
DTLocalTriggerBaseTest::topFolder
std::string & topFolder()
Get top folder name.
Definition: DTLocalTriggerBaseTest.h:93
DQMEDHarvester
Definition: DQMEDHarvester.py:1
DTLocalTriggerBaseTest::trigSources
std::vector< std::string > trigSources
Definition: DTLocalTriggerBaseTest.h:103
Frameworkfwd.h
DTLocalTriggerBaseTest::getHisto
T * getHisto(MonitorElement *me)
Convert ME to Histogram fo type T.
Definition: DTLocalTriggerBaseTest.h:119
T
long double T
Definition: Basic3DVectorLD.h:48
dqm::implementation::IGetter
Definition: DQMStore.h:484
DTLocalTriggerBaseTest::parameters
edm::ParameterSet parameters
Definition: DTLocalTriggerBaseTest.h:107
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
dqm::implementation::IBooker
Definition: DQMStore.h:43
DTLocalTriggerBaseTest::category
std::string category()
Get message logger name.
Definition: DTLocalTriggerBaseTest.h:96
DTLocalTriggerBaseTest::baseFolderTM
std::string baseFolderTM
Definition: DTLocalTriggerBaseTest.h:109
DTChamberId
Definition: DTChamberId.h:14
ParameterSet.h
hlt_dqm_clientPB-live_cfg.me
me
Definition: hlt_dqm_clientPB-live_cfg.py:61
DTLocalTriggerBaseTest::testName
std::string testName
Definition: DTLocalTriggerBaseTest.h:102
DTLocalTriggerBaseTest::DTLocalTriggerBaseTest
DTLocalTriggerBaseTest()
Constructor.
Definition: DTLocalTriggerBaseTest.h:41
DTLocalTriggerBaseTest::runClientDiagnostic
virtual void runClientDiagnostic(DQMStore::IBooker &, DQMStore::IGetter &)=0
Perform client analysis.
DTLocalTriggerBaseTest::endRun
void endRun(edm::Run const &run, edm::EventSetup const &context) override
Perform client diagnostic in offline.
Definition: DTLocalTriggerBaseTest.cc:74
DTLocalTriggerBaseTest::dqmEndLuminosityBlock
void dqmEndLuminosityBlock(DQMStore::IBooker &, DQMStore::IGetter &, edm::LuminosityBlock const &, edm::EventSetup const &) override
Perform client diagnostic in online.
Definition: DTLocalTriggerBaseTest.cc:45