CMS 3D CMS Logo

List of all members | Classes | Public Types | Public Member Functions | Static Public Member Functions
TriggerDQMBase Class Reference

#include <TriggerDQMBase.h>

Inheritance diagram for TriggerDQMBase:
BTVHLTOfflineSource::PathInfo DiJetMonitor HMesonGammaDQM HTDQM JetDQM METDQM METplusTrackMonitor TopMonitor

Classes

struct  MEbinning
 
class  ObjME
 

Public Types

typedef dqm::legacy::DQMStore DQMStore
 
typedef dqm::legacy::MonitorElement MonitorElement
 

Public Member Functions

void bookME (DQMStore::IBooker &, ObjME &me, const std::string &histname, const std::string &histtitle, unsigned nbins, double xmin, double xmax)
 
void bookME (DQMStore::IBooker &, ObjME &me, const std::string &histname, const std::string &histtitle, const std::vector< double > &binningX)
 
void bookME (DQMStore::IBooker &, ObjME &me, const std::string &histname, const std::string &histtitle, unsigned nbinsX, double xmin, double xmax, double ymin, double ymax)
 
void bookME (DQMStore::IBooker &, ObjME &me, const std::string &histname, const std::string &histtitle, unsigned nbinsX, double xmin, double xmax, unsigned nbinsY, double ymin, double ymax)
 
void bookME (DQMStore::IBooker &, ObjME &me, const std::string &histname, const std::string &histtitle, const std::vector< double > &binningX, const std::vector< double > &binningY)
 
void setMETitle (ObjME &me, const std::string &titleX, const std::string &titleY)
 
 TriggerDQMBase ()=default
 
virtual ~TriggerDQMBase ()=default
 

Static Public Member Functions

static void fillHistoLSPSetDescription (edm::ParameterSetDescription &pset)
 
static void fillHistoPSetDescription (edm::ParameterSetDescription &pset)
 
static MEbinning getHistoLSPSet (const edm::ParameterSet &pset)
 
static MEbinning getHistoPSet (const edm::ParameterSet &pset)
 

Detailed Description

Definition at line 7 of file TriggerDQMBase.h.

Member Typedef Documentation

Definition at line 10 of file TriggerDQMBase.h.

Definition at line 9 of file TriggerDQMBase.h.

Constructor & Destructor Documentation

TriggerDQMBase::TriggerDQMBase ( )
default
virtual TriggerDQMBase::~TriggerDQMBase ( )
virtualdefault

Member Function Documentation

void TriggerDQMBase::bookME ( DQMStore::IBooker ibooker,
ObjME me,
const std::string &  histname,
const std::string &  histtitle,
unsigned  nbins,
double  xmin,
double  xmax 
)

Definition at line 10 of file TriggerDQMBase.cc.

References dqm::dqmstoreimpl::DQMStore::IBooker::book1D(), TriggerDQMBase::ObjME::denominator, and TriggerDQMBase::ObjME::numerator.

Referenced by METDQM::bookHistograms(), HTDQM::bookHistograms(), JetDQM::bookHistograms(), HMesonGammaDQM::bookHistograms(), TopMonitor::bookHistograms(), METplusTrackMonitor::bookHistograms(), and DiJetMonitor::bookHistograms().

16  {
17  me.numerator = ibooker.book1D(histname + "_numerator", histtitle + " (numerator)", nbins, min, max);
18  me.denominator = ibooker.book1D(histname + "_denominator", histtitle + " (denominator)", nbins, min, max);
19 }
T min(T a, T b)
Definition: MathUtil.h:58
void TriggerDQMBase::bookME ( DQMStore::IBooker ibooker,
ObjME me,
const std::string &  histname,
const std::string &  histtitle,
const std::vector< double > &  binningX 
)

Definition at line 20 of file TriggerDQMBase.cc.

References dqm::dqmstoreimpl::DQMStore::IBooker::book1D(), TriggerDQMBase::ObjME::denominator, LaserClient_cfi::nbins, and TriggerDQMBase::ObjME::numerator.

24  {
25  unsigned nbins = binning.size() - 1;
26  std::vector<float> fbinning(binning.begin(), binning.end());
27  float* arr = &fbinning[0];
28  me.numerator = ibooker.book1D(histname + "_numerator", histtitle + " (numerator)", nbins, arr);
29  me.denominator = ibooker.book1D(histname + "_denominator", histtitle + " (denominator)", nbins, arr);
30 }
void TriggerDQMBase::bookME ( DQMStore::IBooker ibooker,
ObjME me,
const std::string &  histname,
const std::string &  histtitle,
unsigned  nbinsX,
double  xmin,
double  xmax,
double  ymin,
double  ymax 
)

Definition at line 31 of file TriggerDQMBase.cc.

References dqm::dqmstoreimpl::DQMStore::IBooker::bookProfile(), TriggerDQMBase::ObjME::denominator, and TriggerDQMBase::ObjME::numerator.

39  {
40  me.numerator =
41  ibooker.bookProfile(histname + "_numerator", histtitle + " (numerator)", nbinsX, xmin, xmax, ymin, ymax);
42  me.denominator =
43  ibooker.bookProfile(histname + "_denominator", histtitle + " (denominator)", nbinsX, xmin, xmax, ymin, ymax);
44 }
void TriggerDQMBase::bookME ( DQMStore::IBooker ibooker,
ObjME me,
const std::string &  histname,
const std::string &  histtitle,
unsigned  nbinsX,
double  xmin,
double  xmax,
unsigned  nbinsY,
double  ymin,
double  ymax 
)
void TriggerDQMBase::bookME ( DQMStore::IBooker ibooker,
ObjME me,
const std::string &  histname,
const std::string &  histtitle,
const std::vector< double > &  binningX,
const std::vector< double > &  binningY 
)

Definition at line 60 of file TriggerDQMBase.cc.

References dqm::dqmstoreimpl::DQMStore::IBooker::book2D(), TriggerDQMBase::ObjME::denominator, hlt_dqm_clientPB-live_cfg::nbinsX, hlt_dqm_clientPB-live_cfg::nbinsY, and TriggerDQMBase::ObjME::numerator.

65  {
66  unsigned nbinsX = binningX.size() - 1;
67  std::vector<float> fbinningX(binningX.begin(), binningX.end());
68  float* arrX = &fbinningX[0];
69  unsigned nbinsY = binningY.size() - 1;
70  std::vector<float> fbinningY(binningY.begin(), binningY.end());
71  float* arrY = &fbinningY[0];
72 
73  me.numerator = ibooker.book2D(histname + "_numerator", histtitle + " (numerator)", nbinsX, arrX, nbinsY, arrY);
74  me.denominator = ibooker.book2D(histname + "_denominator", histtitle + " (denominator)", nbinsX, arrX, nbinsY, arrY);
75 }
void TriggerDQMBase::fillHistoLSPSetDescription ( edm::ParameterSetDescription pset)
static

Definition at line 83 of file TriggerDQMBase.cc.

References edm::ParameterSetDescription::add().

Referenced by TopMonitor::fillDescriptions(), METplusTrackMonitor::fillDescriptions(), DiJetMonitor::fillDescriptions(), HMesonGammaDQM::fillHmgDescription(), HTDQM::fillHtDescription(), JetDQM::fillJetDescription(), and METDQM::fillMetDescription().

83  {
84  pset.add<unsigned int>("nbins", 2500);
85  pset.add<double>("xmin", 0.);
86  pset.add<double>("xmax", 2500.);
87 }
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void TriggerDQMBase::fillHistoPSetDescription ( edm::ParameterSetDescription pset)
static

Definition at line 77 of file TriggerDQMBase.cc.

References edm::ParameterSetDescription::add().

Referenced by TopMonitor::fillDescriptions(), METplusTrackMonitor::fillDescriptions(), DiJetMonitor::fillDescriptions(), HMesonGammaDQM::fillHmgDescription(), HTDQM::fillHtDescription(), JetDQM::fillJetDescription(), and METDQM::fillMetDescription().

77  {
78  pset.add<unsigned>("nbins");
79  pset.add<double>("xmin");
80  pset.add<double>("xmax");
81 }
ParameterDescriptionBase * add(U const &iLabel, T const &value)
TriggerDQMBase::MEbinning TriggerDQMBase::getHistoLSPSet ( const edm::ParameterSet pset)
static

Definition at line 97 of file TriggerDQMBase.cc.

References edm::ParameterSet::getParameter().

97  {
99  pset.getParameter<uint32_t>("nbins"), 0., double(pset.getParameter<uint32_t>("nbins"))};
100 }
T getParameter(std::string const &) const
TriggerDQMBase::MEbinning TriggerDQMBase::getHistoPSet ( const edm::ParameterSet pset)
static

Definition at line 89 of file TriggerDQMBase.cc.

References edm::ParameterSet::getParameter().

Referenced by DiJetMonitor::DiJetMonitor(), METDQM::initialise(), HTDQM::initialise(), JetDQM::initialise(), HMesonGammaDQM::initialise(), and TopMonitor::TopMonitor().

89  {
91  pset.getParameter<uint32_t>("nbins"),
92  pset.getParameter<double>("xmin"),
93  pset.getParameter<double>("xmax"),
94  };
95 }
T getParameter(std::string const &) const
void TriggerDQMBase::setMETitle ( ObjME me,
const std::string &  titleX,
const std::string &  titleY 
)

Definition at line 3 of file TriggerDQMBase.cc.

References TriggerDQMBase::ObjME::denominator, TriggerDQMBase::ObjME::numerator, and dqm::impl::MonitorElement::setAxisTitle().

Referenced by METDQM::bookHistograms(), HTDQM::bookHistograms(), JetDQM::bookHistograms(), HMesonGammaDQM::bookHistograms(), TopMonitor::bookHistograms(), METplusTrackMonitor::bookHistograms(), and DiJetMonitor::bookHistograms().

3  {
4  me.numerator->setAxisTitle(titleX, 1);
5  me.numerator->setAxisTitle(titleY, 2);
6  me.denominator->setAxisTitle(titleX, 1);
7  me.denominator->setAxisTitle(titleY, 2);
8 }