CMS 3D CMS Logo

List of all members | Public Member Functions
ecaldqm::MESetProjection Class Reference

#include <MESetProjection.h>

Inheritance diagram for ecaldqm::MESetProjection:
ecaldqm::MESetEcal ecaldqm::MESet

Public Member Functions

MESetclone (std::string const &="") const override
 
void fill (EcalDQMSetupObjects const, DetId const &, double=1., double=0., double=0.) override
 
void fill (EcalDQMSetupObjects const, double, double=1., double=0.) override
 
void fill (EcalDQMSetupObjects const, int, double=1., double=1., double=0.) override
 
double getBinContent (EcalDQMSetupObjects const, DetId const &, int) const override
 
double getBinContent (EcalDQMSetupObjects const, DetId const &, int=0) const override
 
double getBinContent (EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override
 
double getBinContent (EcalDQMSetupObjects const, int, int) const override
 
double getBinEntries (EcalDQMSetupObjects const, DetId const &, int) const override
 
double getBinEntries (EcalDQMSetupObjects const, DetId const &, int=0) const override
 
double getBinEntries (EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override
 
double getBinEntries (EcalDQMSetupObjects const, int, int) const override
 
double getBinError (EcalDQMSetupObjects const, DetId const &, int) const override
 
double getBinError (EcalDQMSetupObjects const, DetId const &, int=0) const override
 
double getBinError (EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override
 
double getBinError (EcalDQMSetupObjects const, int, int) const override
 
 MESetProjection (MESetProjection const &)
 
 MESetProjection (std::string const &, binning::ObjectType, binning::BinningType, MonitorElement::Kind, binning::AxisSpecs const *=nullptr)
 
void setBinContent (EcalDQMSetupObjects const, DetId const &, double) override
 
void setBinContent (EcalDQMSetupObjects const, DetId const &, int, double) override
 
void setBinContent (EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override
 
void setBinContent (EcalDQMSetupObjects const, int, int, double) override
 
void setBinEntries (EcalDQMSetupObjects const, DetId const &, double) override
 
void setBinEntries (EcalDQMSetupObjects const, DetId const &, int, double) override
 
void setBinEntries (EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override
 
void setBinEntries (EcalDQMSetupObjects const, int, int, double) override
 
void setBinError (EcalDQMSetupObjects const, DetId const &, double) override
 
void setBinError (EcalDQMSetupObjects const, DetId const &, int, double) override
 
void setBinError (EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override
 
void setBinError (EcalDQMSetupObjects const, int, int, double) override
 
 ~MESetProjection () override
 
- Public Member Functions inherited from ecaldqm::MESetEcal
void book (DQMStore::IBooker &, EcalElectronicsMapping const *) override
 
void fill (EcalDQMSetupObjects const, EcalElectronicsId const &, double=1., double=1., double=1.) override
 
virtual int findBin (EcalDQMSetupObjects const, DetId const &, double, double=0.) const
 
virtual int findBin (EcalDQMSetupObjects const, EcalElectronicsId const &, double, double=0.) const
 
virtual int findBin (EcalDQMSetupObjects const, int, double, double=0.) const
 
std::vector< std::string > generatePaths (EcalElectronicsMapping const *) const
 
double getBinContent (EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override
 
double getBinContent (EcalDQMSetupObjects const, int, int) const override
 
double getBinEntries (EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override
 
double getBinEntries (EcalDQMSetupObjects const, int, int) const override
 
double getBinError (EcalDQMSetupObjects const, EcalElectronicsId const &, int) const override
 
double getBinError (EcalDQMSetupObjects const, int, int) const override
 
bool isVariableBinning () const override
 
 MESetEcal (MESetEcal const &)
 
 MESetEcal (std::string const &, binning::ObjectType, binning::BinningType, MonitorElement::Kind, unsigned, binning::AxisSpecs const *=nullptr, binning::AxisSpecs const *=nullptr, binning::AxisSpecs const *=nullptr)
 
MESetoperator= (MESet const &) override
 
bool retrieve (EcalElectronicsMapping const *, DQMStore::IGetter &, std::string *=nullptr) const override
 
void setBinContent (EcalDQMSetupObjects const, DetId const &, int, double) override
 
void setBinContent (EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override
 
void setBinContent (EcalDQMSetupObjects const, int, int, double) override
 
void setBinEntries (EcalDQMSetupObjects const, DetId const &, int, double) override
 
void setBinEntries (EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override
 
void setBinEntries (EcalDQMSetupObjects const, int, int, double) override
 
void setBinError (EcalDQMSetupObjects const, DetId const &, int, double) override
 
void setBinError (EcalDQMSetupObjects const, EcalElectronicsId const &, int, double) override
 
void setBinError (EcalDQMSetupObjects const, int, int, double) override
 
 ~MESetEcal () override
 
- Public Member Functions inherited from ecaldqm::MESet
virtual iterator begin (EcalElectronicsMapping const *electronicsMap)
 
virtual const_iterator begin (EcalElectronicsMapping const *electronicsMap) const
 
virtual iterator beginChannel (EcalElectronicsMapping const *electronicsMap)
 
virtual const_iterator beginChannel (EcalElectronicsMapping const *electronicsMap) const
 
virtual void clear () const
 
virtual iterator end (EcalElectronicsMapping const *electronicsMap)
 
virtual const_iterator end (EcalElectronicsMapping const *electronicsMap) const
 
std::string formPath (PathReplacements const &) const
 
bool getBatchMode () const
 
binning::BinningType getBinType () const
 
MonitorElement::Kind getKind () const
 
bool getLumiFlag () const
 
virtual MonitorElementgetME (unsigned _iME)
 
virtual const MonitorElementgetME (unsigned _iME) const
 
binning::ObjectType getObjType () const
 
virtual const std::string & getPath () const
 
bool isActive () const
 
virtual bool maskMatches (DetId const &, uint32_t, StatusManager const *, EcalTrigTowerConstituentsMap const *) const
 
 MESet ()
 
 MESet (MESet const &)
 
 MESet (std::string const &, binning::ObjectType, binning::BinningType, MonitorElement::Kind)
 
virtual void reset (EcalElectronicsMapping const *, double=0., double=0., double=0.)
 
virtual void resetAll (double=0., double=0., double=0.)
 
virtual void setAxisTitle (std::string const &, int=1)
 
void setBatchMode ()
 
virtual void setBinContent (EcalDQMSetupObjects const, EcalElectronicsId const &, double)
 
virtual void setBinContent (EcalDQMSetupObjects const, int, double)
 
virtual void setBinEntries (EcalDQMSetupObjects const, EcalElectronicsId const &, double)
 
virtual void setBinEntries (EcalDQMSetupObjects const, int, double)
 
virtual void setBinError (EcalDQMSetupObjects const, EcalElectronicsId const &, double)
 
virtual void setBinError (EcalDQMSetupObjects const, int, double)
 
void setLumiFlag ()
 
virtual ~MESet ()
 

Additional Inherited Members

- Public Types inherited from ecaldqm::MESet
typedef dqm::legacy::DQMStore DQMStore
 
typedef dqm::legacy::MonitorElement MonitorElement
 
typedef std::map< std::string, std::string > PathReplacements
 
- Protected Member Functions inherited from ecaldqm::MESet
virtual void checkME_ (unsigned _iME) const
 
virtual void fill_ (unsigned, double, double, double)
 
virtual void fill_ (unsigned, int, double)
 
virtual void fill_ (unsigned, int, double, double)
 
void throw_ (std::string const &_message) const
 
- Protected Attributes inherited from ecaldqm::MESetEcal
unsigned logicalDimensions_
 
const binning::AxisSpecsxaxis_
 
const binning::AxisSpecsyaxis_
 
const binning::AxisSpecszaxis_
 
- Protected Attributes inherited from ecaldqm::MESet
bool active_
 
bool batchMode_
 
binning::BinningType btype_
 
MonitorElement::Kind kind_
 
bool lumiFlag_
 
std::vector< MonitorElement * > mes_
 
binning::ObjectType otype_
 
std::string path_
 

Detailed Description

Definition at line 12 of file MESetProjection.h.

Constructor & Destructor Documentation

◆ MESetProjection() [1/2]

ecaldqm::MESetProjection::MESetProjection ( std::string const &  _fullPath,
binning::ObjectType  _otype,
binning::BinningType  _btype,
MonitorElement::Kind  _kind,
binning::AxisSpecs const *  _yaxis = nullptr 
)

Definition at line 6 of file MESetProjection.cc.

11  : MESetEcal(_fullPath, _otype, _btype, _kind, 1, nullptr, _yaxis) {
12  switch (kind_) {
15  break;
16  default:
17  throw_("Unsupported MonitorElement kind");
18  }
19 
20  switch (btype_) {
21  case binning::kProjEta:
22  case binning::kProjPhi:
23  break;
24  default:
25  throw_("Unsupported binning");
26  }
27  }

References ecaldqm::MESet::btype_, ecaldqm::MESet::kind_, ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, MonitorElementData::TH1F, ecaldqm::MESet::throw_(), and MonitorElementData::TPROFILE.

Referenced by clone().

◆ MESetProjection() [2/2]

ecaldqm::MESetProjection::MESetProjection ( MESetProjection const &  _orig)

Definition at line 29 of file MESetProjection.cc.

29 : MESetEcal(_orig) {}

◆ ~MESetProjection()

ecaldqm::MESetProjection::~MESetProjection ( )
override

Definition at line 31 of file MESetProjection.cc.

31 {}

Member Function Documentation

◆ clone()

MESet * ecaldqm::MESetProjection::clone ( std::string const &  _path = "") const
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 33 of file MESetProjection.cc.

33  {
35  if (!_path.empty())
36  path_ = _path;
37  MESet *copy(new MESetProjection(*this));
38  path_ = path;
39  return copy;
40  }

References filterCSVwithJSON::copy, MESetProjection(), castor_dqm_sourceclient_file_cfg::path, ecaldqm::MESet::path_, and AlCaHLTBitMon_QueryRunRegistry::string.

◆ fill() [1/3]

void ecaldqm::MESetProjection::fill ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
double  _w = 1.,
double  = 0.,
double  = 0. 
)
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 42 of file MESetProjection.cc.

42  {
43  if (!active_)
44  return;
45 
46  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
47  checkME_(iME);
48 
49  int subdet(_id.subdetId());
50 
51  if (subdet == EcalBarrel) {
52  EBDetId ebid(_id);
54  fill_(iME, eta(ebid, edso.geometry), _w, 0.);
55  else if (btype_ == binning::kProjPhi)
56  fill_(iME, phi(ebid), _w, 0.);
57  } else if (subdet == EcalEndcap) {
58  EEDetId eeid(_id);
60  fill_(iME, eta(eeid, edso.geometry), _w, 0.);
61  if (btype_ == binning::kProjPhi) {
62  fill_(iME, phi(eeid), _w, 0.);
63  }
64  } else if (isEndcapTTId(_id)) {
65  EcalTrigTowerDetId ttid(_id);
66  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
67  unsigned nIds(ids.size());
68  if (btype_ == binning::kProjEta) {
69  for (unsigned iId(0); iId < nIds; iId++)
70  fill_(iME, eta(EEDetId(ids[iId]), edso.geometry), _w / nIds, 0.);
71  } else if (btype_ == binning::kProjPhi) {
72  for (unsigned iId(0); iId < nIds; iId++)
73  fill_(iME, phi(EEDetId(ids[iId])), _w / nIds, 0.);
74  }
75  } else if (subdet == EcalTriggerTower) {
76  EcalTrigTowerDetId ttid(_id);
77  if (btype_ == binning::kProjEta) {
78  int ieta(ttid.ieta());
79  if (ieta < 18 && ieta > 0)
80  fill_(iME, (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta, _w, 0.);
81  else if (ieta > -18 && ieta < 0)
82  fill_(iME, (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta, _w, 0.);
83  } else if (btype_ == binning::kProjPhi)
84  fill_(iME, phi(ttid), _w, 0.);
85  }
86  }

References ecaldqm::MESet::active_, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::MESet::fill_(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ fill() [2/3]

void ecaldqm::MESetProjection::fill ( EcalDQMSetupObjects const  edso,
double  _x,
double  _w = 1.,
double  = 0. 
)
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 102 of file MESetProjection.cc.

102  {
103  if (!active_)
104  return;
105  if (btype_ != binning::kProjEta)
106  return;
107 
108  unsigned iME;
109  if (_x < -etaBound)
110  iME = 0;
111  else if (_x < etaBound)
112  iME = 1;
113  else
114  iME = 2;
115 
116  if (otype_ == binning::kEcal2P && iME == 2)
117  iME = 0;
118 
119  checkME_(iME);
120 
121  mes_[iME]->Fill(_x, _w);
122  }

References ecaldqm::MESet::active_, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), ecaldqm::etaBound, ecaldqm::binning::kEcal2P, ecaldqm::binning::kProjEta, ecaldqm::MESet::mes_, and ecaldqm::MESet::otype_.

◆ fill() [3/3]

void ecaldqm::MESetProjection::fill ( EcalDQMSetupObjects const  edso,
int  _subdet,
double  _x = 1.,
double  _w = 1.,
double  = 0. 
)
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 88 of file MESetProjection.cc.

89  {
90  if (!active_)
91  return;
92 
93  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _subdet, btype_));
94  checkME_(iME);
95 
97  _x = phi(_x);
98 
99  mes_[iME]->Fill(_x, _w);
100  }

References ecaldqm::MESet::active_, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::binning::findPlotIndex(), ecaldqm::binning::kProjPhi, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, and ecaldqm::phi().

◆ getBinContent() [1/4]

double ecaldqm::MESetEcal::getBinContent
override

Definition at line 463 of file MESetEcal.cc.

463  {
464  if (!active_)
465  return 0.;
466 
467  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
468  checkME_(iME);
469 
470  return mes_[iME]->getBinContent(_bin);
471  }

◆ getBinContent() [2/4]

double ecaldqm::MESetProjection::getBinContent ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
int  = 0 
) const
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 307 of file MESetProjection.cc.

307  {
308  if (!active_)
309  return 0.;
310 
311  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
312  checkME_(iME);
313 
314  MonitorElement *me(mes_[iME]);
315 
316  if (isEndcapTTId(_id)) {
317  EcalTrigTowerDetId ttid(_id);
318  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
319  if (btype_ == binning::kProjEta) {
320  int bin(me->getTH1()->FindBin(eta(EEDetId(ids[0]), edso.geometry)));
321  return me->getBinContent(bin);
322  } else if (btype_ == binning::kProjPhi) {
323  int bin(me->getTH1()->FindBin(phi(EEDetId(ids[0]))));
324  return me->getBinContent(bin);
325  }
326  return 0.;
327  }
328 
329  double x(0.);
330  int subdet(_id.subdetId());
331  if (subdet == EcalBarrel) {
332  EBDetId ebid(_id);
333  if (btype_ == binning::kProjEta)
334  x = eta(ebid, edso.geometry);
335  else if (btype_ == binning::kProjPhi)
336  x = phi(ebid);
337  } else if (subdet == EcalEndcap) {
338  if (btype_ == binning::kProjEta)
339  x = eta(EEDetId(_id), edso.geometry);
340  else if (btype_ == binning::kProjPhi)
341  x = phi(EEDetId(_id));
342  } else if (subdet == EcalTriggerTower) {
343  EcalTrigTowerDetId ttid(_id);
344  if (btype_ == binning::kProjEta) {
345  int ieta(ttid.ieta());
346  if (ieta < 18 && ieta > 0)
347  x = (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta;
348  else if (ieta > -18 && ieta < 0)
349  x = (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta;
350  } else if (btype_ == binning::kProjPhi)
351  x = phi(ttid);
352  }
353 
354  int bin(me->getTH1()->FindBin(x));
355  return me->getBinContent(bin);
356  }

References ecaldqm::MESet::active_, newFWLiteAna::bin, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, hlt_dqm_clientPB-live_cfg::me, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ getBinContent() [3/4]

double ecaldqm::MESetEcal::getBinContent
override

Definition at line 473 of file MESetEcal.cc.

473  {
474  if (!active_)
475  return 0.;
476 
477  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
478  checkME_(iME);
479 
480  return mes_[iME]->getBinContent(_bin);
481  }

◆ getBinContent() [4/4]

double ecaldqm::MESetEcal::getBinContent
override

Definition at line 483 of file MESetEcal.cc.

483  {
484  if (!active_)
485  return 0.;
486 
487  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _dcctccid, btype_));
488  checkME_(iME);
489 
490  return mes_[iME]->getBinContent(_bin);
491  }

◆ getBinEntries() [1/4]

double ecaldqm::MESetEcal::getBinEntries
override

Definition at line 523 of file MESetEcal.cc.

523  {
524  if (!active_)
525  return 0.;
527  return 0.;
528 
529  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
530  checkME_(iME);
531 
532  return mes_[iME]->getBinEntries(_bin);
533  }

◆ getBinEntries() [2/4]

double ecaldqm::MESetProjection::getBinEntries ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
int  = 0 
) const
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 409 of file MESetProjection.cc.

409  {
410  if (!active_)
411  return 0.;
412 
413  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
414  checkME_(iME);
415 
416  MonitorElement *me(mes_[iME]);
417 
418  if (isEndcapTTId(_id)) {
419  EcalTrigTowerDetId ttid(_id);
420  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
421  if (btype_ == binning::kProjEta) {
422  int bin(me->getTH1()->FindBin(eta(EEDetId(ids[0]), edso.geometry)));
423  return me->getBinEntries(bin);
424  } else if (btype_ == binning::kProjPhi) {
425  int bin(me->getTH1()->FindBin(phi(EEDetId(ids[0]))));
426  return me->getBinEntries(bin);
427  }
428  return 0.;
429  }
430 
431  double x(0.);
432  int subdet(_id.subdetId());
433  if (subdet == EcalBarrel) {
434  EBDetId ebid(_id);
435  if (btype_ == binning::kProjEta)
436  x = eta(ebid, edso.geometry);
437  else if (btype_ == binning::kProjPhi)
438  x = phi(ebid);
439  } else if (subdet == EcalEndcap) {
440  if (btype_ == binning::kProjEta)
441  x = eta(EEDetId(_id), edso.geometry);
442  else if (btype_ == binning::kProjPhi)
443  x = phi(EEDetId(_id));
444  } else if (subdet == EcalTriggerTower) {
445  EcalTrigTowerDetId ttid(_id);
446  if (btype_ == binning::kProjEta) {
447  int ieta(ttid.ieta());
448  if (ieta < 18 && ieta > 0)
449  x = (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta;
450  else if (ieta > -18 && ieta < 0)
451  x = (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta;
452  } else if (btype_ == binning::kProjPhi)
453  x = phi(ttid);
454  }
455 
456  int bin(me->getTH1()->FindBin(x));
457  return me->getBinEntries(bin);
458  }

References ecaldqm::MESet::active_, newFWLiteAna::bin, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, hlt_dqm_clientPB-live_cfg::me, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ getBinEntries() [3/4]

double ecaldqm::MESetEcal::getBinEntries
override

Definition at line 535 of file MESetEcal.cc.

535  {
536  if (!active_)
537  return 0.;
539  return 0.;
540 
541  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
542  checkME_(iME);
543 
544  return mes_[iME]->getBinEntries(_bin);
545  }

◆ getBinEntries() [4/4]

double ecaldqm::MESetEcal::getBinEntries
override

Definition at line 547 of file MESetEcal.cc.

547  {
548  if (!active_)
549  return 0.;
551  return 0.;
552 
553  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _dcctccid, btype_));
554  checkME_(iME);
555 
556  return mes_[iME]->getBinEntries(_bin);
557  }

◆ getBinError() [1/4]

double ecaldqm::MESetEcal::getBinError
override

Definition at line 493 of file MESetEcal.cc.

493  {
494  if (!active_)
495  return 0.;
496 
497  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
498  checkME_(iME);
499 
500  return mes_[iME]->getBinError(_bin);
501  }

◆ getBinError() [2/4]

double ecaldqm::MESetProjection::getBinError ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
int  = 0 
) const
overridevirtual

Reimplemented from ecaldqm::MESetEcal.

Definition at line 358 of file MESetProjection.cc.

358  {
359  if (!active_)
360  return 0.;
361 
362  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
363  checkME_(iME);
364 
365  MonitorElement *me(mes_[iME]);
366 
367  if (isEndcapTTId(_id)) {
368  EcalTrigTowerDetId ttid(_id);
369  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
370  if (btype_ == binning::kProjEta) {
371  int bin(me->getTH1()->FindBin(eta(EEDetId(ids[0]), edso.geometry)));
372  return me->getBinError(bin);
373  } else if (btype_ == binning::kProjPhi) {
374  int bin(me->getTH1()->FindBin(phi(EEDetId(ids[0]))));
375  return me->getBinError(bin);
376  }
377  return 0.;
378  }
379 
380  double x(0.);
381  int subdet(_id.subdetId());
382  if (subdet == EcalBarrel) {
383  EBDetId ebid(_id);
384  if (btype_ == binning::kProjEta)
385  x = eta(ebid, edso.geometry);
386  else if (btype_ == binning::kProjPhi)
387  x = phi(ebid);
388  } else if (subdet == EcalEndcap) {
389  if (btype_ == binning::kProjEta)
390  x = eta(EEDetId(_id), edso.geometry);
391  else if (btype_ == binning::kProjPhi)
392  x = phi(EEDetId(_id));
393  } else if (subdet == EcalTriggerTower) {
394  EcalTrigTowerDetId ttid(_id);
395  if (btype_ == binning::kProjEta) {
396  int ieta(ttid.ieta());
397  if (ieta < 18 && ieta > 0)
398  x = (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta;
399  else if (ieta > -18 && ieta < 0)
400  x = (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta;
401  } else if (btype_ == binning::kProjPhi)
402  x = phi(ttid);
403  }
404 
405  int bin(me->getTH1()->FindBin(x));
406  return me->getBinError(bin);
407  }

References ecaldqm::MESet::active_, newFWLiteAna::bin, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, hlt_dqm_clientPB-live_cfg::me, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ getBinError() [3/4]

double ecaldqm::MESetEcal::getBinError
override

Definition at line 503 of file MESetEcal.cc.

503  {
504  if (!active_)
505  return 0.;
506 
507  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
508  checkME_(iME);
509 
510  return mes_[iME]->getBinError(_bin);
511  }

◆ getBinError() [4/4]

double ecaldqm::MESetEcal::getBinError
override

Definition at line 513 of file MESetEcal.cc.

513  {
514  if (!active_)
515  return 0.;
516 
517  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _dcctccid, btype_));
518  checkME_(iME);
519 
520  return mes_[iME]->getBinError(_bin);
521  }

◆ setBinContent() [1/4]

void ecaldqm::MESetProjection::setBinContent ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
double  _content 
)
overridevirtual

Reimplemented from ecaldqm::MESet.

Definition at line 124 of file MESetProjection.cc.

124  {
125  if (!active_)
126  return;
127 
128  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
129  checkME_(iME);
130 
131  MonitorElement *me(mes_[iME]);
132 
133  if (isEndcapTTId(_id)) {
134  EcalTrigTowerDetId ttid(_id);
135  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
136  unsigned nIds(ids.size());
137  std::set<int> bins;
138  if (btype_ == binning::kProjEta) {
139  for (unsigned iId(0); iId < nIds; iId++) {
140  int bin(me->getTH1()->FindBin(eta(EEDetId(ids[iId]), edso.geometry)));
141  if (bins.find(bin) != bins.end())
142  continue;
143  me->setBinContent(bin, _content);
144  }
145  } else if (btype_ == binning::kProjPhi) {
146  for (unsigned iId(0); iId < nIds; iId++) {
147  int bin(me->getTH1()->FindBin(phi(EEDetId(ids[iId]))));
148  if (bins.find(bin) != bins.end())
149  continue;
150  me->setBinContent(bin, _content);
151  }
152  }
153  return;
154  }
155 
156  double x(0.);
157  int subdet(_id.subdetId());
158  if (subdet == EcalBarrel) {
159  EBDetId ebid(_id);
160  if (btype_ == binning::kProjEta)
161  x = eta(ebid, edso.geometry);
162  else if (btype_ == binning::kProjPhi)
163  x = phi(ebid);
164  } else if (subdet == EcalEndcap) {
165  if (btype_ == binning::kProjEta)
166  x = eta(EEDetId(_id), edso.geometry);
167  else if (btype_ == binning::kProjPhi)
168  x = phi(EEDetId(_id));
169  } else if (subdet == EcalTriggerTower) {
170  EcalTrigTowerDetId ttid(_id);
171  if (btype_ == binning::kProjEta) {
172  int ieta(ttid.ieta());
173  if (ieta < 18 && ieta > 0)
174  x = (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta;
175  else if (ieta > -18 && ieta < 0)
176  x = (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta;
177  } else if (btype_ == binning::kProjPhi)
178  x = phi(ttid);
179  }
180 
181  int bin(me->getTH1()->FindBin(x));
182  me->setBinContent(bin, _content);
183  }

References btvTracks_cfi::_content, ecaldqm::MESet::active_, newFWLiteAna::bin, trigObjTnPSource_cfi::bins, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, hlt_dqm_clientPB-live_cfg::me, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ setBinContent() [2/4]

void ecaldqm::MESetEcal::setBinContent
override

Definition at line 361 of file MESetEcal.cc.

361  {
362  if (!active_)
363  return;
364 
365  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
366  checkME_(iME);
367 
368  mes_[iME]->setBinContent(_bin, _content);
369  }

◆ setBinContent() [3/4]

void ecaldqm::MESetEcal::setBinContent
override

Definition at line 371 of file MESetEcal.cc.

374  {
375  if (!active_)
376  return;
377 
378  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
379  checkME_(iME);
380 
381  mes_[iME]->setBinContent(_bin, _content);
382  }

◆ setBinContent() [4/4]

void ecaldqm::MESetEcal::setBinContent
override

Definition at line 384 of file MESetEcal.cc.

384  {
385  if (!active_)
386  return;
387 
388  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _dcctccid, btype_));
389  checkME_(iME);
390 
391  mes_[iME]->setBinContent(_bin, _content);
392  }

◆ setBinEntries() [1/4]

void ecaldqm::MESetProjection::setBinEntries ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
double  _entries 
)
overridevirtual

Reimplemented from ecaldqm::MESet.

Definition at line 246 of file MESetProjection.cc.

246  {
247  if (!active_)
248  return;
249 
250  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
251  checkME_(iME);
252 
253  MonitorElement *me(mes_[iME]);
254 
255  if (isEndcapTTId(_id)) {
256  EcalTrigTowerDetId ttid(_id);
257  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
258  unsigned nIds(ids.size());
259  std::set<int> bins;
260  if (btype_ == binning::kProjEta) {
261  for (unsigned iId(0); iId < nIds; iId++) {
262  int bin(me->getTH1()->FindBin(eta(EEDetId(ids[iId]), edso.geometry)));
263  if (bins.find(bin) != bins.end())
264  continue;
265  me->setBinEntries(bin, _entries);
266  }
267  } else if (btype_ == binning::kProjPhi) {
268  for (unsigned iId(0); iId < nIds; iId++) {
269  int bin(me->getTH1()->FindBin(phi(EEDetId(ids[iId]))));
270  if (bins.find(bin) != bins.end())
271  continue;
272  me->setBinEntries(bin, _entries);
273  }
274  }
275  return;
276  }
277 
278  double x(0.);
279  int subdet(_id.subdetId());
280  if (subdet == EcalBarrel) {
281  EBDetId ebid(_id);
282  if (btype_ == binning::kProjEta)
283  x = eta(ebid, edso.geometry);
284  else if (btype_ == binning::kProjPhi)
285  x = phi(ebid);
286  } else if (subdet == EcalEndcap) {
287  if (btype_ == binning::kProjEta)
288  x = eta(EEDetId(_id), edso.geometry);
289  else if (btype_ == binning::kProjPhi)
290  x = phi(EEDetId(_id));
291  } else if (subdet == EcalTriggerTower) {
292  EcalTrigTowerDetId ttid(_id);
293  if (btype_ == binning::kProjEta) {
294  int ieta(ttid.ieta());
295  if (ieta < 18 && ieta > 0)
296  x = (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta;
297  else if (ieta > -18 && ieta < 0)
298  x = (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta;
299  } else if (btype_ == binning::kProjPhi)
300  x = phi(ttid);
301  }
302 
303  int bin(me->getTH1()->FindBin(x));
304  me->setBinEntries(bin, _entries);
305  }

References ecaldqm::MESet::active_, newFWLiteAna::bin, trigObjTnPSource_cfi::bins, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, hlt_dqm_clientPB-live_cfg::me, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ setBinEntries() [2/4]

void ecaldqm::MESetEcal::setBinEntries
override

Definition at line 424 of file MESetEcal.cc.

424  {
425  if (!active_)
426  return;
428  return;
429 
430  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
431  checkME_(iME);
432 
433  mes_[iME]->setBinEntries(_bin, _entries);
434  }

◆ setBinEntries() [3/4]

void ecaldqm::MESetEcal::setBinEntries
override

Definition at line 436 of file MESetEcal.cc.

439  {
440  if (!active_)
441  return;
443  return;
444 
445  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
446  checkME_(iME);
447 
448  mes_[iME]->setBinEntries(_bin, _entries);
449  }

◆ setBinEntries() [4/4]

void ecaldqm::MESetEcal::setBinEntries
override

Definition at line 451 of file MESetEcal.cc.

451  {
452  if (!active_)
453  return;
455  return;
456 
457  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _dcctccid, btype_));
458  checkME_(iME);
459 
460  mes_[iME]->setBinEntries(_bin, _entries);
461  }

◆ setBinError() [1/4]

void ecaldqm::MESetProjection::setBinError ( EcalDQMSetupObjects const  edso,
DetId const &  _id,
double  _error 
)
overridevirtual

Reimplemented from ecaldqm::MESet.

Definition at line 185 of file MESetProjection.cc.

185  {
186  if (!active_)
187  return;
188 
189  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
190  checkME_(iME);
191 
192  MonitorElement *me(mes_[iME]);
193 
194  if (isEndcapTTId(_id)) {
195  EcalTrigTowerDetId ttid(_id);
196  std::vector<DetId> ids(edso.trigtowerMap->constituentsOf(ttid));
197  unsigned nIds(ids.size());
198  std::set<int> bins;
199  if (btype_ == binning::kProjEta) {
200  for (unsigned iId(0); iId < nIds; iId++) {
201  int bin(me->getTH1()->FindBin(eta(EEDetId(ids[iId]), edso.geometry)));
202  if (bins.find(bin) != bins.end())
203  continue;
204  me->setBinError(bin, _error);
205  }
206  } else if (btype_ == binning::kProjPhi) {
207  for (unsigned iId(0); iId < nIds; iId++) {
208  int bin(me->getTH1()->FindBin(phi(EEDetId(ids[iId]))));
209  if (bins.find(bin) != bins.end())
210  continue;
211  me->setBinError(bin, _error);
212  }
213  }
214  return;
215  }
216 
217  double x(0.);
218  int subdet(_id.subdetId());
219  if (subdet == EcalBarrel) {
220  EBDetId ebid(_id);
221  if (btype_ == binning::kProjEta)
222  x = eta(ebid, edso.geometry);
223  else if (btype_ == binning::kProjPhi)
224  x = phi(ebid);
225  } else if (subdet == EcalEndcap) {
226  if (btype_ == binning::kProjEta)
227  x = eta(EEDetId(_id), edso.geometry);
228  else if (btype_ == binning::kProjPhi)
229  x = phi(EEDetId(_id));
230  } else if (subdet == EcalTriggerTower) {
231  EcalTrigTowerDetId ttid(_id);
232  if (btype_ == binning::kProjEta) {
233  int ieta(ttid.ieta());
234  if (ieta < 18 && ieta > 0)
235  x = (ieta * 5 - 2.5) * EBDetId::crystalUnitToEta;
236  else if (ieta > -18 && ieta < 0)
237  x = (ieta * 5 + 2.5) * EBDetId::crystalUnitToEta;
238  } else if (btype_ == binning::kProjPhi)
239  x = phi(ttid);
240  }
241 
242  int bin(me->getTH1()->FindBin(x));
243  me->setBinError(bin, _error);
244  }

References ecaldqm::MESet::active_, newFWLiteAna::bin, trigObjTnPSource_cfi::bins, ecaldqm::MESet::btype_, ecaldqm::MESet::checkME_(), EcalTrigTowerConstituentsMap::constituentsOf(), EBDetId::crystalUnitToEta, EcalBarrel, EcalEndcap, EcalTriggerTower, ecaldqm::EcalDQMSetupObjects::electronicsMap, ecaldqm::eta(), ecaldqm::binning::findPlotIndex(), ecaldqm::EcalDQMSetupObjects::geometry, EcalTrigTowerDetId::ieta(), LEDCalibrationChannels::ieta, ecaldqm::isEndcapTTId(), ecaldqm::binning::kProjEta, ecaldqm::binning::kProjPhi, hlt_dqm_clientPB-live_cfg::me, ecaldqm::MESet::mes_, ecaldqm::MESet::otype_, ecaldqm::phi(), DetId::subdetId(), and ecaldqm::EcalDQMSetupObjects::trigtowerMap.

◆ setBinError() [2/4]

void ecaldqm::MESetEcal::setBinError
override

Definition at line 394 of file MESetEcal.cc.

394  {
395  if (!active_)
396  return;
397 
398  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
399  checkME_(iME);
400 
401  mes_[iME]->setBinError(_bin, _error);
402  }

◆ setBinError() [3/4]

void ecaldqm::MESetEcal::setBinError
override

Definition at line 404 of file MESetEcal.cc.

404  {
405  if (!active_)
406  return;
407 
408  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _id));
409  checkME_(iME);
410 
411  mes_[iME]->setBinError(_bin, _error);
412  }

◆ setBinError() [4/4]

void ecaldqm::MESetEcal::setBinError
override

Definition at line 414 of file MESetEcal.cc.

414  {
415  if (!active_)
416  return;
417 
418  unsigned iME(binning::findPlotIndex(edso.electronicsMap, otype_, _dcctccid, btype_));
419  checkME_(iME);
420 
421  mes_[iME]->setBinError(_bin, _error);
422  }
ecaldqm::eta
double eta(EBDetId const &, CaloGeometry const *)
Definition: EcalDQMCommonUtils.cc:209
EBDetId::crystalUnitToEta
static const float crystalUnitToEta
Definition: EBDetId.h:153
ecaldqm::MESet::throw_
void throw_(std::string const &_message) const
Definition: MESet.h:149
ecaldqm::MESetProjection::MESetProjection
MESetProjection(std::string const &, binning::ObjectType, binning::BinningType, MonitorElement::Kind, binning::AxisSpecs const *=nullptr)
Definition: MESetProjection.cc:6
ecaldqm::MESet::fill_
virtual void fill_(unsigned, int, double)
Definition: MESet.cc:252
filterCSVwithJSON.copy
copy
Definition: filterCSVwithJSON.py:36
MonitorElementData::Kind::TH1F
EBDetId
Definition: EBDetId.h:17
ecaldqm::binning::kEcal2P
Definition: MESetBinningUtils.h:33
ecaldqm::isEndcapTTId
bool isEndcapTTId(DetId const &)
Definition: EcalDQMCommonUtils.cc:270
dqm::legacy::MonitorElement
Definition: MonitorElement.h:462
ecaldqm::binning::kProjEta
Definition: MESetBinningUtils.h:48
DDAxes::x
EcalTrigTowerDetId
Definition: EcalTrigTowerDetId.h:14
ecaldqm::etaBound
const double etaBound
EcalBarrel
Definition: EcalSubdetector.h:10
ecaldqm::binning::kProjPhi
Definition: MESetBinningUtils.h:49
ecaldqm::MESet::otype_
binning::ObjectType otype_
Definition: MESet.h:154
ecaldqm::MESet::active_
bool active_
Definition: MESet.h:161
EEDetId
Definition: EEDetId.h:14
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
EcalEndcap
Definition: EcalSubdetector.h:10
LEDCalibrationChannels.ieta
ieta
Definition: LEDCalibrationChannels.py:63
ecaldqm::MESet::btype_
binning::BinningType btype_
Definition: MESet.h:155
ecaldqm::MESet::path_
std::string path_
Definition: MESet.h:153
ecaldqm::MESet::mes_
std::vector< MonitorElement * > mes_
Definition: MESet.h:151
newFWLiteAna.bin
bin
Definition: newFWLiteAna.py:161
EcalTriggerTower
Definition: EcalSubdetector.h:10
MonitorElementData::Kind::TPROFILE2D
ecaldqm::MESet::checkME_
virtual void checkME_(unsigned _iME) const
Definition: MESet.h:141
ecaldqm::MESet::MESet
MESet()
Definition: MESet.cc:14
ecaldqm::binning::findPlotIndex
unsigned findPlotIndex(EcalElectronicsMapping const *, ObjectType, DetId const &)
Definition: MESetBinningUtils.cc:316
castor_dqm_sourceclient_file_cfg.path
path
Definition: castor_dqm_sourceclient_file_cfg.py:37
trigObjTnPSource_cfi.bins
bins
Definition: trigObjTnPSource_cfi.py:20
hlt_dqm_clientPB-live_cfg.me
me
Definition: hlt_dqm_clientPB-live_cfg.py:61
ecaldqm::MESet::kind_
MonitorElement::Kind kind_
Definition: MESet.h:156
btvTracks_cfi._content
_content
Definition: btvTracks_cfi.py:5
MonitorElementData::Kind::TPROFILE
ecaldqm::MESetEcal::MESetEcal
MESetEcal(std::string const &, binning::ObjectType, binning::BinningType, MonitorElement::Kind, unsigned, binning::AxisSpecs const *=nullptr, binning::AxisSpecs const *=nullptr, binning::AxisSpecs const *=nullptr)
Definition: MESetEcal.cc:10
ecaldqm::phi
double phi(EBDetId const &)
Definition: EcalDQMCommonUtils.cc:215