Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hcal DQM Migration - II.2 #6337

Merged
merged 7 commits into from Nov 17, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 4 additions & 6 deletions DQM/HcalMonitorClient/interface/HcalBaseDQClient.h
Expand Up @@ -28,14 +28,13 @@ class HcalBaseDQClient
virtual ~HcalBaseDQClient(void);

// Overload these functions with client-specific instructions
virtual void beginJob(void);
virtual void beginRun(void) {}
virtual void setup(void) {}

virtual void analyze(void) {enoughevents_=true;} // fill new histograms
virtual void analyze(DQMStore::IBooker &, DQMStore::IGetter &) {enoughevents_=true;} // fill new histograms
virtual void calculateProblems(void) {} // update/fill ProblemCell histograms

virtual void endRun(void) {}
//virtual void endRun(void) {}
virtual void endJob(void) {}
virtual void cleanup(void) {}

Expand All @@ -44,11 +43,11 @@ class HcalBaseDQClient
virtual bool hasOther_Temp(void) {return false;};
virtual bool test_enabled(void) {return false;};

virtual void htmlOutput(std::string htmlDir);
virtual void htmlOutput(DQMStore::IBooker &, DQMStore::IGetter &, std::string htmlDir);
virtual void setStatusMap(std::map<HcalDetId, unsigned int>& map);
virtual void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual){};

virtual bool validHtmlOutput();
virtual bool validHtmlOutput(DQMStore::IBooker &, DQMStore::IGetter &);

void getLogicalMap(const edm::EventSetup& es);

Expand Down Expand Up @@ -78,7 +77,6 @@ class HcalBaseDQClient
std::vector<std::string> problemnames_;

std::map<HcalDetId, unsigned int> badstatusmap;
DQMStore* dqmStore_;
bool enoughevents_;

bool needLogicalMap_;
Expand Down
15 changes: 11 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalBeamClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalBeamClient : public HcalBaseDQClient {
HcalBeamClient(std::string myname);//{ name_=myname;};
HcalBeamClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);

Expand All @@ -34,6 +33,14 @@ class HcalBeamClient : public HcalBaseDQClient {

private:
int nevts_;

// -- setup the problem cells monitor
bool setupProblemCells_; // defaults to true in constructor

// perform the setup of the problem cells monitor elements and EtaPhiHists
// This function sets the above setupProblemCells_ to false.
void doProblemCellSetup(DQMStore::IBooker &, DQMStore::IGetter &);

};

#endif
15 changes: 11 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalCoarsePedestalClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalCoarsePedestalClient : public HcalBaseDQClient {
HcalCoarsePedestalClient(std::string myname);//{ name_=myname;};
HcalCoarsePedestalClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);

Expand All @@ -39,6 +38,14 @@ class HcalCoarsePedestalClient : public HcalBaseDQClient {
TH2F* DatabasePedestalsADCByDepth[4];
EtaPhiHists* CoarsePedestalsByDepth;
MonitorElement* CoarsePedDiff;

// -- setup problem cells monitors
bool doCoarseSetup_; // defaults to true in constructor

// performs the setup of the coarse cell
// sets the doCoarseSetup_ to false
void setupCoarsePedestal(DQMStore::IBooker &, DQMStore::IGetter &);

};

#endif
14 changes: 10 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalDeadCellClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalDeadCellClient : public HcalBaseDQClient {
HcalDeadCellClient(std::string myname);//{ name_=myname;};
HcalDeadCellClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);

Expand All @@ -38,6 +37,13 @@ class HcalDeadCellClient : public HcalBaseDQClient {
int HBpresent_, HEpresent_, HOpresent_, HFpresent_;
bool excludeHOring2_backup_; // this value is used for excludeHOring2 if it can't be read directly from the DQM file

// -- setup the problem cells monitors
bool doProblemCellSetup_; // defaults to true in the constructor

// setup the problem cell monitors
// Sets the doProblemCellSetup_ to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);

};

#endif
18 changes: 12 additions & 6 deletions DQM/HcalMonitorClient/interface/HcalDetDiagLEDClient.h
Expand Up @@ -14,22 +14,21 @@ class HcalDetDiagLEDClient : public HcalBaseDQClient {
HcalDetDiagLEDClient(std::string myname);//{ name_=myname;};
HcalDetDiagLEDClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);
bool hasErrors_Temp(void);
bool hasWarnings_Temp(void);
bool hasOther_Temp(void);
bool test_enabled(void);

void htmlOutput(std::string);
bool validHtmlOutput();
void htmlOutput(DQMStore::IBooker &, DQMStore::IGetter &, std::string);
bool validHtmlOutput(DQMStore::IBooker &, DQMStore::IGetter &);

/// Destructor
~HcalDetDiagLEDClient();
Expand All @@ -48,6 +47,13 @@ class HcalDetDiagLEDClient : public HcalBaseDQClient {
TH2F *ChannelStatusTimeRMS[4];
double get_channel_status(std::string subdet,int eta,int phi,int depth,int type);
double get_energy(std::string subdet,int eta,int phi,int depth,int type);

// -- setup for problem cells
bool doProblemCellSetup_; // default to true in the constructor

// setup the problem cells
// this sets the doProblemCellSetup_ to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);
};

#endif
17 changes: 11 additions & 6 deletions DQM/HcalMonitorClient/interface/HcalDetDiagLaserClient.h
Expand Up @@ -14,28 +14,33 @@ class HcalDetDiagLaserClient : public HcalBaseDQClient {
HcalDetDiagLaserClient(std::string myname);//{ name_=myname;};
HcalDetDiagLaserClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);
bool hasErrors_Temp(void);
bool hasWarnings_Temp(void);
bool hasOther_Temp(void);
bool test_enabled(void);

void htmlOutput(std::string);
bool validHtmlOutput();
void htmlOutput(DQMStore::IBooker &, DQMStore::IGetter &, std::string);
bool validHtmlOutput(DQMStore::IBooker &, DQMStore::IGetter &);
/// Destructor
~HcalDetDiagLaserClient();

private:
int nevts_;
int status;

// -- problem cell setup flag
bool doProblemCellSetup_; // defaults to true in constructor
// setup the problem cell monitors and set the doProblemCellSetup_
// flag to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);
};

#endif
12 changes: 8 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalDetDiagNoiseMonitorClient.h
Expand Up @@ -14,11 +14,10 @@ class HcalDetDiagNoiseMonitorClient : public HcalBaseDQClient {
HcalDetDiagNoiseMonitorClient(std::string myname);//{ name_=myname;};
HcalDetDiagNoiseMonitorClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
//void endJob(void);
void beginRun(void);
void endRun(void);
void setup(void);
Expand All @@ -34,6 +33,11 @@ class HcalDetDiagNoiseMonitorClient : public HcalBaseDQClient {

private:
int nevts_;

// -- problem cell setup flag
bool doProblemCellSetup_; // defaults to true in the constructor
// setup the problem cell monitors and set the doProblemCellSetup_ flag to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);
};

#endif
17 changes: 11 additions & 6 deletions DQM/HcalMonitorClient/interface/HcalDetDiagPedestalClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalDetDiagPedestalClient : public HcalBaseDQClient {
HcalDetDiagPedestalClient(std::string myname);//{ name_=myname;};
HcalDetDiagPedestalClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker & , DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);
bool hasErrors_Temp(void);
Expand All @@ -29,15 +28,21 @@ class HcalDetDiagPedestalClient : public HcalBaseDQClient {
bool test_enabled(void);


void htmlOutput(std::string);
bool validHtmlOutput();
void htmlOutput(DQMStore::IBooker &, DQMStore::IGetter &, std::string);
bool validHtmlOutput(DQMStore::IBooker &, DQMStore::IGetter &);

/// Destructor
~HcalDetDiagPedestalClient();

private:
int nevts_;
int status;

// - setup problem cell flags
bool doProblemCellSetup_; // defaults to true in the constructor
// setup the problem cell monitor elements
// This method sets the doProblemCellSetup_ flag to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);
};

#endif
14 changes: 10 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalDetDiagTimingClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalDetDiagTimingClient : public HcalBaseDQClient {
HcalDetDiagTimingClient(std::string myname);//{ name_=myname;};
HcalDetDiagTimingClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);

Expand All @@ -34,6 +33,13 @@ class HcalDetDiagTimingClient : public HcalBaseDQClient {

private:
int nevts_;

// - setup problem cell flags
bool doProblemCellSetup_; // defaults to true in the constructor
// setup the problem cell monitor elements
// This method sets the doProblemCellSetup_ flag to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);

};

#endif
14 changes: 10 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalDigiClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalDigiClient : public HcalBaseDQClient {
HcalDigiClient(std::string myname);//{ name_=myname;};
HcalDigiClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);

Expand All @@ -35,6 +34,13 @@ class HcalDigiClient : public HcalBaseDQClient {
private:
int nevts_;
MonitorElement* HFTiming_averageTime;

// - setup problem cell flags
bool doProblemCellSetup_; // defaults to true in the constructor
// setup the problem cell monitor elements
// This method sets the doProblemCellSetup_ flag to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);

};

#endif
14 changes: 10 additions & 4 deletions DQM/HcalMonitorClient/interface/HcalHotCellClient.h
Expand Up @@ -14,13 +14,12 @@ class HcalHotCellClient : public HcalBaseDQClient {
HcalHotCellClient(std::string myname);//{ name_=myname;};
HcalHotCellClient(std::string myname, const edm::ParameterSet& ps);

void analyze(void);
void calculateProblems(void); // calculates problem histogram contents
void analyze(DQMStore::IBooker &, DQMStore::IGetter &);
void calculateProblems(DQMStore::IBooker &, DQMStore::IGetter &); // calculates problem histogram contents
void updateChannelStatus(std::map<HcalDetId, unsigned int>& myqual);
void beginJob(void);
void endJob(void);
void beginRun(void);
void endRun(void);
//void endRun(void);
void setup(void);
void cleanup(void);

Expand All @@ -34,6 +33,13 @@ class HcalHotCellClient : public HcalBaseDQClient {

private:
int nevts_;

// - setup problem cell flags
bool doProblemCellSetup_; // defaults to true in the constructor
// setup the problem cell monitor elements
// This method sets the doProblemCellSetup_ flag to false
void setupProblemCells(DQMStore::IBooker &, DQMStore::IGetter &);

};

#endif