Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:08:22

0001 #ifndef SiPixelMonitorRawData_SiPixelHLTSource_h
0002 #define SiPixelMonitorRawData_SiPixelHLTSource_h
0003 // -*- C++ -*-
0004 //
0005 // Package:     SiPixelMonitorRawData
0006 // Class  :     SiPixelHLTSource
0007 //
0008 /**
0009 
0010  Description:
0011  Produces histograms for error information generated at the raw2digi stage for
0012  the pixel tracker.
0013 
0014  Implementation:
0015  Takes raw data and error data as input, and uses it to populate three
0016  histograms indexed by FED id.
0017 
0018 */
0019 //
0020 // Original Author:  Andrew York
0021 //
0022 
0023 #include <memory>
0024 
0025 // user include files
0026 #include "DQMServices/Core/interface/DQMEDAnalyzer.h"
0027 
0028 #include "DataFormats/Common/interface/DetSetVector.h"
0029 #include "DataFormats/FEDRawData/interface/FEDRawDataCollection.h"
0030 #include "DataFormats/SiPixelRawData/interface/SiPixelRawDataError.h"
0031 
0032 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0033 #include "Geometry/TrackerGeometryBuilder/interface/TrackerGeometry.h"
0034 #include "Geometry/Records/interface/TrackerDigiGeometryRecord.h"
0035 
0036 class SiPixelHLTSource : public DQMEDAnalyzer {
0037 public:
0038   explicit SiPixelHLTSource(const edm::ParameterSet &conf);
0039   ~SiPixelHLTSource() override;
0040 
0041   void analyze(const edm::Event &, const edm::EventSetup &) override;
0042   void bookHistograms(DQMStore::IBooker &, edm::Run const &, edm::EventSetup const &) override;
0043   void dqmBeginRun(const edm::Run &, edm::EventSetup const &) override;
0044   virtual void bookMEs(DQMStore::IBooker &);
0045 
0046 private:
0047   edm::ParameterSet conf_;
0048   edm::EDGetTokenT<FEDRawDataCollection> rawin_;
0049   edm::EDGetTokenT<edm::DetSetVector<SiPixelRawDataError>> errin_;
0050   edm::ESGetToken<TrackerGeometry, TrackerDigiGeometryRecord> trackerGeomToken_;
0051   bool saveFile;
0052   bool slowDown;
0053   std::string dirName_;
0054   int eventNo;
0055   MonitorElement *meRawWords_;
0056   MonitorElement *meNCRCs_;
0057   MonitorElement *meNErrors_;
0058   bool firstRun;
0059 };
0060 
0061 #endif