Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:07:04

0001 #ifndef DTLocalTriggerSynchTest_H
0002 #define DTLocalTriggerSynchTest_H
0003 
0004 /** \class DTLocalTriggerSynchTest
0005  * *
0006  *  DQM Test Client
0007  *
0008  *  \author  C. Battilana - CIEMAT
0009  *
0010  *  threadsafe version (//-) oct/nov 2014 - WATWanAbdullah -ncpp-um-my
0011  *
0012  *   
0013  */
0014 
0015 #include "DQM/DTMonitorClient/src/DTLocalTriggerBaseTest.h"
0016 #include "CondFormats/DTObjects/interface/DTTPGParameters.h"
0017 #include "CondFormats/DataRecord/interface/DTTPGParametersRcd.h"
0018 
0019 class DTTrigGeomUtils;
0020 
0021 class DTLocalTriggerSynchTest : public DTLocalTriggerBaseTest {
0022 public:
0023   /// Constructor
0024   DTLocalTriggerSynchTest(const edm::ParameterSet &ps);
0025 
0026   /// Destructor
0027   ~DTLocalTriggerSynchTest() override;
0028 
0029 protected:
0030   /// Book the new MEs (for each chamber)
0031 
0032   void bookChambHistos(DQMStore::IBooker &, DTChamberId chambId, std::string htype, std::string subfolder = "");
0033 
0034   /// Compute efficiency plots
0035   void makeRatioME(TH1F *numerator, TH1F *denominator, MonitorElement *result);
0036 
0037   /// Get float MEs
0038 
0039   float getFloatFromME(DQMStore::IGetter &, DTChamberId chId, std::string meType);
0040 
0041   /// begin Run
0042   void beginRun(const edm::Run &run, const edm::EventSetup &c) override;
0043 
0044   void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override;
0045 
0046   /// DQM Client Diagnostic
0047 
0048   void runClientDiagnostic(DQMStore::IBooker &, DQMStore::IGetter &) override;
0049 
0050   void dqmEndLuminosityBlock(DQMStore::IBooker &,
0051                              DQMStore::IGetter &,
0052                              edm::LuminosityBlock const &,
0053                              edm::EventSetup const &) override;
0054 
0055 private:
0056   std::map<uint32_t, std::map<std::string, MonitorElement *> > chambME;
0057   std::string numHistoTag;
0058   std::string denHistoTag;
0059   std::string ratioHistoTag;
0060   double bxTime;
0061   bool rangeInBX;
0062   int nBXLow;
0063   int nBXHigh;
0064   int minEntries;
0065   bool writeDB;
0066   edm::ESGetToken<DTTPGParameters, DTTPGParametersRcd> wPhaseMapToken_;
0067   const DTTPGParameters *wPhaseMap;
0068 
0069   bool bookingdone;
0070 };
0071 
0072 #endif