Back to home page

Project CMSSW displayed by LXR

 
 

    


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

0001 #include "DQM/SiPixelMonitorClient/interface/SiPixelDcsInfo.h"
0002 //#include "DataFormats/FEDRawData/interface/FEDNumbering.h"
0003 #include "CondFormats/DataRecord/interface/RunSummaryRcd.h"
0004 #include "CondFormats/RunInfo/interface/RunInfo.h"
0005 #include "CondFormats/RunInfo/interface/RunSummary.h"
0006 
0007 using namespace std;
0008 using namespace edm;
0009 SiPixelDcsInfo::SiPixelDcsInfo(const edm::ParameterSet &ps) { firstRun = true; }
0010 
0011 SiPixelDcsInfo::~SiPixelDcsInfo() {}
0012 
0013 void SiPixelDcsInfo::dqmEndLuminosityBlock(DQMStore::IBooker &iBooker,
0014                                            DQMStore::IGetter &iGetter,
0015                                            const edm::LuminosityBlock &lumiBlock,
0016                                            const edm::EventSetup &iSetup) {
0017   if (firstRun) {
0018     iBooker.setCurrentFolder("Pixel/EventInfo");
0019     Fraction_ = iBooker.bookFloat("DCSSummary");
0020     iBooker.setCurrentFolder("Pixel/EventInfo/DCSContents");
0021     FractionBarrel_ = iBooker.bookFloat("PixelBarrelFraction");
0022     FractionEndcap_ = iBooker.bookFloat("PixelEndcapFraction");
0023   }
0024 
0025   if (iSetup.tryToGet<RunInfoRcd>()) {
0026     // all Pixel:
0027     Fraction_->Fill(1.);
0028     // Barrel:
0029     FractionBarrel_->Fill(1.);
0030     // Endcap:
0031     FractionEndcap_->Fill(1.);
0032     return;
0033   }
0034 }
0035 
0036 void SiPixelDcsInfo::dqmEndJob(DQMStore::IBooker &iBooker, DQMStore::IGetter &iGetter) {
0037   // Nothing actually happened in the old endJob/endRun, so this is left empty.
0038 }