CMS 3D CMS Logo

List of all members | Public Member Functions | Private Member Functions | Private Attributes
GenericHistoryDQMService Class Reference

#include <GenericHistoryDQMService.h>

Inheritance diagram for GenericHistoryDQMService:
DQMHistoryServiceBase

Public Member Functions

 GenericHistoryDQMService (const edm::ParameterSet &, const edm::ActivityRegistry &)
 
 ~GenericHistoryDQMService ()
 
- Public Member Functions inherited from DQMHistoryServiceBase
virtual bool checkForCompatibility (std::string ss)
 
 DQMHistoryServiceBase (const edm::ParameterSet &, const edm::ActivityRegistry &)
 
virtual void getMetaDataString (std::stringstream &ss)
 
virtual void getObj (HDQMSummary *&obj)
 
virtual void initialize ()
 
virtual void setSeparator (std::string const &)
 
virtual ~DQMHistoryServiceBase ()
 

Private Member Functions

uint32_t returnDetComponent (const MonitorElement *ME)
 
bool setDBLabelsForUser (std::string &keyName, std::vector< std::string > &userDBContent, std::string &quantity)
 Example on how to define an user function for the statistic extraction. More...
 
bool setDBValuesForUser (std::vector< MonitorElement * >::const_iterator iterMes, HDQMSummary::InputVector &values, std::string &quantity)
 

Private Attributes

edm::ParameterSet iConfig_
 

Additional Inherited Members

- Protected Member Functions inherited from DQMHistoryServiceBase
virtual void createSummary ()
 
virtual uint32_t getRunNumber () const
 
virtual void openRequestedFile ()
 
virtual void scanTreeAndFillSummary (const std::vector< MonitorElement * > &MEs, HDQMSummary *summary, std::string &histoName, std::vector< std::string > &Quantities)
 
virtual bool setDBLabelsForGauss (std::string &keyName, std::vector< std::string > &userDBContent)
 
virtual bool setDBLabelsForLandau (std::string &keyName, std::vector< std::string > &userDBContent)
 
virtual bool setDBLabelsForStat (std::string &keyName, std::vector< std::string > &userDBContent)
 
virtual bool setDBLabelsForUser (std::string &keyName, std::vector< std::string > &userDBContent)
 
virtual bool setDBValuesForGauss (std::vector< MonitorElement * >::const_iterator iterMes, HDQMSummary::InputVector &values)
 
virtual bool setDBValuesForLandau (std::vector< MonitorElement * >::const_iterator iterMes, HDQMSummary::InputVector &values)
 
virtual bool setDBValuesForStat (std::vector< MonitorElement * >::const_iterator iterMes, HDQMSummary::InputVector &values)
 
virtual bool setDBValuesForUser (std::vector< MonitorElement * >::const_iterator iterMes, HDQMSummary::InputVector &values)
 
- Protected Attributes inherited from DQMHistoryServiceBase
DQMStoredqmStore_
 
HDQMfitUtilitiesfitME
 
std::string fSep
 
edm::ParameterSet iConfig_
 
HDQMSummaryobj_
 

Detailed Description

Author
D. Giordano to read DQM root file & insert summary informations to DB

Definition at line 11 of file GenericHistoryDQMService.h.

Constructor & Destructor Documentation

GenericHistoryDQMService::GenericHistoryDQMService ( const edm::ParameterSet iConfig,
const edm::ActivityRegistry aReg 
)
explicit

Definition at line 6 of file GenericHistoryDQMService.cc.

8 {
9  edm::LogInfo("GenericHistoryDQMService") << "[GenericHistoryDQMService::GenericHistoryDQMService]";
10 }
DQMHistoryServiceBase(const edm::ParameterSet &, const edm::ActivityRegistry &)
GenericHistoryDQMService::~GenericHistoryDQMService ( )

Definition at line 12 of file GenericHistoryDQMService.cc.

13 {
14  edm::LogInfo("GenericHistoryDQMService") << "[GenericHistoryDQMService::~GenericHistoryDQMService]";
15 }

Member Function Documentation

uint32_t GenericHistoryDQMService::returnDetComponent ( const MonitorElement ME)
privatevirtual

Reimplemented from DQMHistoryServiceBase.

Definition at line 17 of file GenericHistoryDQMService.cc.

References edm::ParameterSet::getParameter(), iConfig_, and LogTrace.

18 {
19  LogTrace("GenericHistoryDQMService") << "[GenericHistoryDQMService::returnDetComponent] returning value defined in the configuration Pset \"DetectorId\"";
20  return iConfig_.getParameter<uint32_t>("DetectorId");
21 }
T getParameter(std::string const &) const
#define LogTrace(id)
bool GenericHistoryDQMService::setDBLabelsForUser ( std::string &  keyName,
std::vector< std::string > &  userDBContent,
std::string &  quantity 
)
privatevirtual

Example on how to define an user function for the statistic extraction.

Reimplemented from DQMHistoryServiceBase.

Definition at line 24 of file GenericHistoryDQMService.cc.

References AlCaHLTBitMon_QueryRunRegistry::string.

25 {
26  if(quantity=="userExample_XMax"){
27  userDBContent.push_back(keyName+std::string("@")+std::string("userExample_XMax"));
28  }
29  else if(quantity=="userExample_mean"){
30  userDBContent.push_back(keyName+std::string("@")+std::string("userExample_mean"));
31  }
32  else{
33  edm::LogError("DQMHistoryServiceBase")
34  << "Quantity " << quantity
35  << " cannot be handled\nAllowed quantities are"
36  << "\n 'stat' that includes: entries, mean, rms"
37  << "\n 'landau' that includes: landauPeak, landauPeakErr, landauSFWHM, landauChi2NDF"
38  << "\n 'gauss' that includes: gaussMean, gaussSigma, gaussChi2NDF"
39  << "\n or a specific user quantity that should be implemented in the user functions GenericHistoryDQMService::setDBLabelsForUser"
40  << std::endl;
41  return false;
42  }
43  return true;
44 }
bool GenericHistoryDQMService::setDBValuesForUser ( std::vector< MonitorElement * >::const_iterator  iterMes,
HDQMSummary::InputVector values,
std::string &  quantity 
)
privatevirtual

Reimplemented from DQMHistoryServiceBase.

Definition at line 46 of file GenericHistoryDQMService.cc.

47 {
48  if(quantity=="userExample_XMax"){
49  values.push_back( (*iterMes)->getTH1F()->GetXaxis()->GetBinCenter((*iterMes)->getTH1F()->GetMaximumBin()));
50  }
51  else if(quantity=="userExample_mean"){
52  values.push_back( (*iterMes)->getMean() );
53  }
54  else{
55  return false;
56  }
57  return true;
58 }

Member Data Documentation

edm::ParameterSet GenericHistoryDQMService::iConfig_
private

Definition at line 23 of file GenericHistoryDQMService.h.

Referenced by returnDetComponent().