Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 #ifndef DTDataIntegrity_Test_H
0002 #define DTDataIntegrity_Test_H
0003 
0004 /** \class DTDataIntegrityTest
0005  * *
0006  *  DQM Client to check the data integrity
0007  *
0008  *  \author S. Bolognesi - INFN TO
0009  *
0010  *  threadsafe version (//-) oct/nov 2014 - WATWanAbdullah ncpp-um-my
0011  *
0012  *   
0013  */
0014 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0015 #include "FWCore/Framework/interface/Event.h"
0016 #include "FWCore/Framework/interface/ESHandle.h"
0017 #include "FWCore/Framework/interface/EventSetup.h"
0018 #include "FWCore/Framework/interface/LuminosityBlock.h"
0019 #include "DataFormats/DTDigi/interface/DTuROSControlData.h"
0020 #include "CondFormats/DataRecord/interface/DTReadOutMappingRcd.h"
0021 #include "DQMServices/Core/interface/DQMStore.h"
0022 
0023 #include "DQMServices/Core/interface/DQMEDHarvester.h"
0024 
0025 class DTReadOutMapping;
0026 
0027 class DTDataIntegrityTest : public DQMEDHarvester {
0028 public:
0029   /// Constructor
0030   DTDataIntegrityTest(const edm::ParameterSet &ps);
0031 
0032   /// Destructor
0033   ~DTDataIntegrityTest() override;
0034 
0035 protected:
0036   void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override;
0037 
0038   /// Get the ME name
0039   std::string getMEName(std::string histoType, int FEDId);
0040 
0041   /// DQM Client Diagnostic
0042   void dqmEndLuminosityBlock(DQMStore::IBooker &,
0043                              DQMStore::IGetter &,
0044                              edm::LuminosityBlock const &,
0045                              edm::EventSetup const &) override;
0046 
0047 private:
0048   int readOutToGeometry(int dduId, int rosNumber, int &wheel, int &sector);
0049   int getROS(int uROS, int link);
0050 
0051   //Number of onUpdates
0052   int nupdates;
0053 
0054   // prescale on the # of LS to update the test
0055   int prescaleFactor;
0056 
0057   //Counter between 0 and nTimeBin
0058   int counter;
0059 
0060   int nevents;
0061   unsigned int nLumiSegs;
0062 
0063   int run;
0064 
0065   bool bookingdone;
0066 
0067   edm::ESGetToken<DTReadOutMapping, DTReadOutMappingRcd> mappingToken_;
0068   const DTReadOutMapping *mapping;
0069 
0070   // Monitor Elements
0071   MonitorElement *summaryHisto;
0072   MonitorElement *summaryTDCHisto;
0073   MonitorElement *glbSummaryHisto;
0074 };
0075 
0076 #endif