CMS 3D CMS Logo

SiPixelStatusHarvester.h
Go to the documentation of this file.
1 #ifndef SiPixelStatusHarvester_H
2 #define SiPixelStatusHarvester_H
3 
11 
21 
22 // Pixel quality harvester
24 // PixelDQM Framework
26 // PixelPhase1 HelperClass
28 
29 // Threshold testing
30 #include "TH1.h"
31 #include "TFile.h"
32 
33 class SiPixelStatusHarvester : public DQMOneEDAnalyzer<edm::one::WatchLuminosityBlocks>,
34  private HistogramManagerHolder {
36 
37 public:
38  // Constructor
40 
41  // Destructor
42  ~SiPixelStatusHarvester() override;
43 
44  // Operations
45  void beginJob() override;
46  void endJob() override;
47  void bookHistograms(DQMStore::IBooker& iBooker, edm::Run const&, const edm::EventSetup&) final;
48  void dqmEndRun(const edm::Run&, const edm::EventSetup&) final;
49  void analyze(const edm::Event& iEvent, const edm::EventSetup&) final;
50 
52  void endLuminosityBlock(const edm::LuminosityBlock&, const edm::EventSetup&) final;
53 
54 private:
55  // Parameters
59  int nLumi_;
62  // harvest helper classs that setup the IOV structure
64  // debug mode
65  bool debug_;
66  // for DB output naming
68 
69  // permanent known bad components
71 
72  // totoal number of lumi blocks with non-zero pixel DIGIs
73  int countLumi_ = 0;
74  // last lumi section of the SiPixeDetectorStatus data
76 
78  const SiPixelFedCabling* cablingMap_ = nullptr;
79  std::map<int, unsigned int> sensorSize_;
80 
82 
83  // pixel online to offline pixel row/column
84  std::map<int, std::map<int, std::pair<int, int> > > pixelO2O_;
85 
90 
91  //Helper functions
92  std::vector<std::string> substructures;
93  double perLayerRingAverage(int detid, SiPixelDetectorStatus tmpSiPixelStatus);
94  std::string substructure(int detid);
95 
96  // "step function" for IOV
98  std::map<edm::LuminosityBlockNumber_t, edm::LuminosityBlockNumber_t> IOV);
99 
100  // boolean function to check whether two SiPixelQualitys (pyloads) are identical
102 
103  // Tag constructor
104  void constructTag(std::map<int, SiPixelQuality*> siPixelQualityTag,
107  edm::Run const& iRun);
108 };
109 
110 #endif
SiPixelStatusHarvester
Definition: SiPixelStatusHarvester.h:33
SiPixelStatusHarvester::beginJob
void beginJob() override
Definition: SiPixelStatusHarvester.cc:98
TrackerGeometry.h
SiPixelStatusHarvester::trackerGeometryToken_
edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord > trackerGeometryToken_
Definition: SiPixelStatusHarvester.h:86
SiPixelStatusHarvester::FEDERRORROC
Definition: SiPixelStatusHarvester.h:35
edm::LuminosityBlock
Definition: LuminosityBlock.h:50
SiPixelStatusHarvester::trackerGeometry_
const TrackerGeometry * trackerGeometry_
Definition: SiPixelStatusHarvester.h:77
edm::Run
Definition: Run.h:45
SiPixelStatusHarvester::STUCKTBMROC
Definition: SiPixelStatusHarvester.h:35
DQMOneEDAnalyzer
Definition: DQMOneEDAnalyzer.h:20
SiPixelStatusHarvester::cablingMap_
const SiPixelFedCabling * cablingMap_
Definition: SiPixelStatusHarvester.h:78
SiPixelFedCablingMap.h
SiPixelQualityFromDbRcd.h
SiPixelStatusHarvester::endJob
void endJob() override
Definition: SiPixelStatusHarvester.cc:101
SiPixelFedCabling
Definition: SiPixelFedCabling.h:10
edm::LuminosityBlockNumber_t
unsigned int LuminosityBlockNumber_t
Definition: RunLumiEventNumber.h:13
SiPixelStatusHarvester::recordName_
std::string recordName_
Definition: SiPixelStatusHarvester.h:67
SiPixelStatusHarvester::perLayerRingAverage
double perLayerRingAverage(int detid, SiPixelDetectorStatus tmpSiPixelStatus)
Definition: SiPixelStatusHarvester.cc:674
ESGetToken.h
DQMOneEDAnalyzer.h
SiPixelDetectorStatus
Definition: SiPixelDetectorStatus.h:11
SiPixelStatusHarvester::substructures
std::vector< std::string > substructures
Definition: SiPixelStatusHarvester.h:92
dqm::legacy::DQMStore::IBooker
dqm::implementation::IBooker IBooker
Definition: DQMStore.h:729
SiPixelStatusHarvester::SiPixelStatusHarvester
SiPixelStatusHarvester(const edm::ParameterSet &)
Definition: SiPixelStatusHarvester.cc:53
TrackerTopology.h
SiPixelStatusHarvester::debug_
bool debug_
Definition: SiPixelStatusHarvester.h:65
TrackerTopologyRcd.h
SiPixelStatusHarvester::thresholdL4_
double thresholdL4_
Definition: SiPixelStatusHarvester.h:56
SiPixelStatusHarvester::OTHERBADROC
Definition: SiPixelStatusHarvester.h:35
SiPixelStatusHarvester::beginLuminosityBlock
void beginLuminosityBlock(const edm::LuminosityBlock &, const edm::EventSetup &) final
Definition: SiPixelStatusHarvester.cc:578
SiPixelStatusHarvester::thresholdRNG1_
double thresholdRNG1_
Definition: SiPixelStatusHarvester.h:56
SiPixelStatusHarvester::thresholdL2_
double thresholdL2_
Definition: SiPixelStatusHarvester.h:56
SiPixelStatusHarvester::sensorSize_
std::map< int, unsigned int > sensorSize_
Definition: SiPixelStatusHarvester.h:79
SiPixelStatusHarvester::endLuminosityBlock
void endLuminosityBlock(const edm::LuminosityBlock &, const edm::EventSetup &) final
Definition: SiPixelStatusHarvester.cc:583
b
double b
Definition: hdecay.h:118
SiPixelStatusHarvester::coord_
SiPixelCoordinates coord_
Definition: SiPixelStatusHarvester.h:81
SiPixelStatusHarvester::thresholdL3_
double thresholdL3_
Definition: SiPixelStatusHarvester.h:56
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
SiPixelStatusHarvester::outputBase_
std::string outputBase_
Definition: SiPixelStatusHarvester.h:57
SiPixelStatusHarvester::BADROC
Definition: SiPixelStatusHarvester.h:35
TrackerDigiGeometryRecord.h
SiPixelStatusManager.h
edm::ParameterSet
Definition: ParameterSet.h:36
SiPixelStatusManager
Definition: SiPixelStatusManager.h:24
SiPixelQuality
Definition: SiPixelQuality.h:27
SiPixelStatusHarvester::bookHistograms
void bookHistograms(DQMStore::IBooker &iBooker, edm::Run const &, const edm::EventSetup &) final
Definition: SiPixelStatusHarvester.cc:104
a
double a
Definition: hdecay.h:119
SiPixelFedCablingMapRcd.h
SiPixelStatusHarvester::constructTag
void constructTag(std::map< int, SiPixelQuality * > siPixelQualityTag, edm::Service< cond::service::PoolDBOutputService > &poolDbService, std::string tagName, edm::Run const &iRun)
Definition: SiPixelStatusHarvester.cc:652
HistogramManagerHolder
Definition: SiPixelPhase1Base.h:27
SiPixelStatusHarvester::PERMANENTBADROC
Definition: SiPixelStatusHarvester.h:35
edm::Service< cond::service::PoolDBOutputService >
iEvent
int iEvent
Definition: GenABIO.cc:224
SiPixelStatusHarvester::thresholdL1_
double thresholdL1_
Definition: SiPixelStatusHarvester.h:56
SiPixelStatusHarvester::thresholdRNG2_
double thresholdRNG2_
Definition: SiPixelStatusHarvester.h:56
edm::EventSetup
Definition: EventSetup.h:57
SiPixelStatusHarvester::moduleName_
std::string moduleName_
Definition: SiPixelStatusHarvester.h:60
SiPixelStatusHarvester::trackerTopologyToken_
edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > trackerTopologyToken_
Definition: SiPixelStatusHarvester.h:87
SiPixelStatusHarvester::aveDigiOcc_
int aveDigiOcc_
Definition: SiPixelStatusHarvester.h:58
edm::ESGetToken< TrackerGeometry, TrackerDigiGeometryRecord >
SiPixelStatusHarvester::endLumiBlock_
edm::LuminosityBlockNumber_t endLumiBlock_
Definition: SiPixelStatusHarvester.h:75
SiPixelStatusHarvester::equal
bool equal(SiPixelQuality *a, SiPixelQuality *b)
Definition: SiPixelStatusHarvester.cc:615
SiPixelStatusHarvester::siPixelQualityToken_
edm::ESGetToken< SiPixelQuality, SiPixelQualityFromDbRcd > siPixelQualityToken_
Definition: SiPixelStatusHarvester.h:89
SiPixelPhase1Base.h
SiPixelStatusHarvester::PROMPTBADROC
Definition: SiPixelStatusHarvester.h:35
SiPixelStatusHarvester::pixelO2O_
std::map< int, std::map< int, std::pair< int, int > > > pixelO2O_
Definition: SiPixelStatusHarvester.h:84
SiPixelStatusHarvester::~SiPixelStatusHarvester
~SiPixelStatusHarvester() override
Definition: SiPixelStatusHarvester.cc:95
Frameworkfwd.h
SiPixelStatusHarvester::siPixelFedCablingMapToken_
edm::ESGetToken< SiPixelFedCablingMap, SiPixelFedCablingMapRcd > siPixelFedCablingMapToken_
Definition: SiPixelStatusHarvester.h:88
SiPixelStatusHarvester::stepIOV
edm::LuminosityBlockNumber_t stepIOV(edm::LuminosityBlockNumber_t pin, std::map< edm::LuminosityBlockNumber_t, edm::LuminosityBlockNumber_t > IOV)
Definition: SiPixelStatusHarvester.cc:591
SiPixelStatusHarvester::nLumi_
int nLumi_
Definition: SiPixelStatusHarvester.h:59
SiPixelQuality.h
SiPixelStatusHarvester::siPixelStatusManager_
SiPixelStatusManager siPixelStatusManager_
Definition: SiPixelStatusHarvester.h:63
ParameterSet.h
SiPixelStatusHarvester::badPixelInfo_
const SiPixelQuality * badPixelInfo_
Definition: SiPixelStatusHarvester.h:70
SiPixelStatusHarvester::analyze
void analyze(const edm::Event &iEvent, const edm::EventSetup &) final
Definition: SiPixelStatusHarvester.cc:113
edm::Event
Definition: Event.h:73
SiPixelCoordinates
Definition: SiPixelCoordinates.h:35
JetPartonCorrections_cff.tagName
tagName
Definition: JetPartonCorrections_cff.py:12
SiPixelStatusHarvester::dqmEndRun
void dqmEndRun(const edm::Run &, const edm::EventSetup &) final
Definition: SiPixelStatusHarvester.cc:116
SiPixelStatusHarvester::substructure
std::string substructure(int detid)
Definition: SiPixelStatusHarvester.cc:699
SiPixelStatusHarvester::countLumi_
int countLumi_
Definition: SiPixelStatusHarvester.h:73
SiPixelCoordinates.h
SiPixelStatusHarvester::label_
std::string label_
Definition: SiPixelStatusHarvester.h:61
TrackerGeometry
Definition: TrackerGeometry.h:14