35 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule Constructor (start)" << std::endl;
76 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: Digi monitor flag is on...." << std::endl;
84 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: RecHit monitor flag is on...." << std::endl;
92 if(fVerbosity>0)
std::cout <<
"CastorChannelQualityMonitor: CQ monitor flag is on...." << std::endl;
100 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: HI monitor flag is on...." << std::endl;
108 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: PS monitor flag is on...." << std::endl;
117 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: Tower Jet monitor flag is on...." << std::endl;
125 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: Data Integrity Monitor flag is on...." << std::endl;
134 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule: LED monitor flag is on...." << std::endl;
146 if(fVerbosity>1)
std::cout <<
"===>CastorMonitor event prescale = " <<
prescaleEvt_ <<
" event(s)"<< std::endl;
149 if(fVerbosity>1)
std::cout <<
"===>CastorMonitor lumi section prescale = " <<
prescaleLS_ <<
" lumi section(s)"<< std::endl;
153 if(fVerbosity>1)
std::cout <<
"===>CastorMonitor update prescale = " <<
prescaleUpdate_ <<
" update(s)"<< std::endl;
156 if(fVerbosity>1)
std::cout <<
"===>CastorMonitor time prescale = " <<
prescaleTime_ <<
" minute(s)"<< std::endl;
160 if(fVerbosity>1)
std::cout <<
"===>CastorMonitor name = " << subsystemname << std::endl;
175 if(fVerbosity>0)
std::cout <<
"CastorMonitorModule Constructor (end)" << std::endl;
240 hCastorEventProduct->GetXaxis()->SetBinLabel(1,
"RawData");
241 hCastorEventProduct->GetXaxis()->SetBinLabel(2,
"CastorDigi");
242 hCastorEventProduct->GetXaxis()->SetBinLabel(3,
"CastorRecHits");
243 hCastorEventProduct->GetYaxis()->SetBinLabel(1,
"Status");
244 hCastorEventProduct->SetBinContent(1,1,-1);
245 hCastorEventProduct->SetBinContent(2,1,-1);
246 hCastorEventProduct->SetBinContent(3,1,-1);
247 hCastorEventProduct->SetOption(
"textcolz");
265 if(
fVerbosity>0)
std::cout <<
"CastorMonitorModule::beginRun - NO DQMStore service" << std::endl;
288 float sigma_averaged;
289 unsigned int iChannel = 0;
290 std::vector<DetId> channels =
dbPedestals->getAllChannels();
293 for (std::vector<DetId>::iterator ch=channels.begin(); ch!=channels.end(); ch++) {
298 for (
short unsigned int iCapId = 0; iCapId < 4; iCapId++){
299 sigma_averaged +=
sqrt(pedestals_mean->
getWidth(iCapId));
307 if(iChannel<224 && fVerbosity>0)
std::cout <<
"There are less that 224 channels in CastorPedestalsRcd record !!!" << std::endl;
465 if (!RawData.isValid()) {
480 const std::vector<int> feds = (*report).getFedsUnpacked();
481 for(
unsigned int f=0;
f<feds.size();
f++){
494 if (!CastorDigi.isValid()) {
512 if (!CastorHits.isValid()) {
522 hCastorEventProduct->SetBinContent(1,1,
int(
rawOK_));
523 hCastorEventProduct->SetBinContent(2,1,
int(
digiOK_));
524 hCastorEventProduct->SetBinContent(3,1,
int(
rechitOK_));
575 listEMap = myRefEMap->allPrecisionId();
634 std::cout <<
"CastorMonitorModule: processed " <<
ievt_ <<
" events" << std::endl;
669 if(!evtPS && !lsPS && !timePS && !updatePS)
671 if (
fVerbosity>0)
std::cout <<
"CastorMonitorModule::prescale (end - permature but fine!)"<<std::endl;
691 std::cout<<
"CastorMonitorModule::prescale evt: "<<
ievent_<<
"/"<<evtPS<<
", ";
699 if(evtPS || lsPS || timePS)
return false;
T getParameter(std::string const &) const
EventNumber_t event() const
T getUntrackedParameter(std::string const &, T const &) const
MonitorElement * meCASTOR_
MonitorElement * meQuality_
void processEvent(const CastorRecHitCollection &castorHits, const CastorDigiCollection &cast, const CastorDbService &cond)
void endRun(const edm::Run &run, const edm::EventSetup &eventSetup)
int sector() const
get the sector (1-16)
MonitorElement * book1D(const char *name, const char *title, int nchX, double lowX, double highX)
Book 1D histogram.
void beginRun(const edm::Run &iRun, const edm::EventSetup &iSetup)
void analyze(const edm::Event &iEvent, const edm::EventSetup &eventSetup)
void beginRun(const edm::EventSetup &iSetup)
edm::InputTag inputLabelCastorTowers_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
void beginLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &eventSetup)
#define DEFINE_FWK_MODULE(type)
void processEvent(const CastorDigiCollection &castorDigis, const CastorDbService &conditions, const std::vector< HcalGenericDetId > &listEMap, int iBunch, float PedSigmaInChannel[14][16])
edm::EDGetTokenT< CastorRecHitCollection > inputLabelRecHitCASTORToken_
edm::ESHandle< CastorDbService > conditions_
int bunchCrossing() const
void beginRun(const edm::Run &iRun, const edm::EventSetup &iSetup)
edm::LuminosityBlockNumber_t luminosityBlock() const
CastorLEDMonitor * LedMon_
void beginRun(const edm::Run &iRun, const edm::EventSetup &eventSetup)
MonitorElement * meRunType_
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
int module() const
get the module (1-2 for EM, 1-12 for HAD)
edm::ESHandle< CastorPedestals > dbPedestals
float getWidth(int fCapId) const
get width for capId = 0..3
void beginRun(const edm::EventSetup &iSetup)
void beginRun(const edm::Run &iRun, const edm::EventSetup &iSetup)
edm::InputTag inputLabelRaw_
static const int DO_CASTOR_RECHITMON
edm::InputTag inputLabelDigi_
CastorTowerJetMonitor * TowerJetMon_
std::vector< HcalGenericDetId > listEMap
CastorMonitorModule(const edm::ParameterSet &ps)
edm::InputTag inputLabelRecHitCASTOR_
void processEvent(const CastorDigiCollection &cast, const CastorDbService &cond)
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
edm::InputTag inputLabelReport_
CastorMonitorSelector * evtSel_
CastorDigiMonitor * DigiMon_
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
edm::EDGetTokenT< CastorDigiCollection > inputLabelDigiToken_
MonitorElement * meEvtMask_
struct CastorMonitorModule::@255 psTime_
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
void CheckCastorStatus(const FEDRawDataCollection &rawraw, const HcalUnpackerReport &report, const CastorElectronicsMap &emap, const CastorDigiCollection &castordigi)
void beginRun(const edm::EventSetup &iSetup)
MonitorElement * meStatus_
CastorDataIntegrityMonitor * DataIntMon_
void processEvent(const CastorRecHitCollection &castorHits)
edm::EDGetTokenT< FEDRawDataCollection > inputLabelRawToken_
void beginRun(const edm::EventSetup &iSetup)
void processEvent(const FEDRawDataCollection &RawData, const HcalUnpackerReport &report, const CastorElectronicsMap &emap)
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
static const int DO_CASTOR_PED_CALIBMON
MonitorElement * CastorEventProduct
CastorChannelQualityMonitor * CQMon_
void beginRun(const edm::EventSetup &iSetup)
void processEvent(const CastorDigiCollection &cast, const CastorDbService &cond)
float fPedestalNSigmaAverage[14][16]
void setup(const edm::ParameterSet &ps, DQMStore *dbe)
CastorRecHitMonitor * RecHitMon_
void processEvent(const CastorRecHitCollection &castorHits)
TH2F * getTH2F(void) const
void endLuminosityBlock(const edm::LuminosityBlock &lumiSeg, const edm::EventSetup &eventSetup)
MonitorElement * bookInt(const char *name)
Book int.
MonitorElement * book2D(const char *name, const char *title, int nchX, double lowX, double highX, int nchY, double lowY, double highY)
Book 2D histogram.
TimeValue_t value() const
edm::Timestamp time() const
void setCurrentFolder(const std::string &fullpath)
edm::EDGetTokenT< HcalUnpackerReport > inputLabelReportToken_