12 MESet(_fullPath, _otype, _btype, _kind),
13 logicalDimensions_(_logicalDimensions),
19 throw_(
"Need axis specifications");
48 MESetEcal const* pRhs(dynamic_cast<MESetEcal const*>(&_rhs));
62 if(!_path.empty())
path_ = _path;
77 for(
unsigned iME(0); iME < mePaths.size(); iME++){
78 string&
path(mePaths[iME]);
79 if(path.find(
'%') != string::npos)
80 throw_(
"book() called with incompletely formed path [" + path +
"]");
109 if(isMap && yaxis.
nbins == 0){
123 if(yaxis.
high - yaxis.
low < 1.e-10){
128 if(zaxis.
high - zaxis.
low < 1.e-10){
134 size_t slashPos(path.find_last_of(
'/'));
135 string name(path.substr(slashPos + 1));
158 double* edges(
new double[xaxis.
nbins + 1]);
171 for(
int iSpec(0); iSpec < 2; iSpec++){
172 if(!specs[iSpec]->edges){
173 specs[iSpec]->
edges =
new float[specs[iSpec]->
nbins + 1];
175 double low(specs[iSpec]->low), high(specs[iSpec]->high);
176 for(
int i(0);
i < nbins + 1;
i++)
177 specs[iSpec]->edges[
i] = low + (high - low) / nbins *
i;
193 throw_(
"Variable bin size for 2D profile not implemented");
194 me = _ibooker.
bookProfile2D(
name,
name, xaxis.
nbins, xaxis.
low, xaxis.
high, yaxis.
nbins, yaxis.
low, yaxis.
high, zaxis.
low, zaxis.
high,
"");
203 throw_(
"ME could not be booked");
211 for(
int iBin(1); iBin <= xaxis.
nbins; ++iBin)
215 for(
int iBin(1); iBin <= yaxis.
nbins; ++iBin)
219 for(
int iBin(1); iBin <= zaxis.
nbins; ++iBin)
245 me->
getTH1()->SetUniqueID(uint32_t(2*(actualObject + 1) + (isMap? 1: 0)));
263 if(_failedPath) _failedPath->clear();
267 for(
unsigned iME(0); iME < mePaths.size(); iME++){
269 if(path.find(
'%') != std::string::npos)
270 throw_(
"retrieve() called with incompletely formed path [" + path +
"]");
273 if(me)
mes_.push_back(me);
276 if(_failedPath) *_failedPath =
path;
293 fill_(iME, _x, _wy, _w);
304 fill_(iME, _x, _wy, _w);
315 fill_(iME, _x, _wy, _w);
323 if(
mes_.size() != 1)
return;
325 fill_(0, _x, _wy, _w);
336 mes_[iME]->setBinContent(_bin, _content);
347 mes_[iME]->setBinContent(_bin, _content);
358 mes_[iME]->setBinContent(_bin, _content);
369 mes_[iME]->setBinError(_bin, _error);
380 mes_[iME]->setBinError(_bin, _error);
391 mes_[iME]->setBinError(_bin, _error);
403 mes_[iME]->setBinEntries(_bin, _entries);
415 mes_[iME]->setBinEntries(_bin, _entries);
427 mes_[iME]->setBinEntries(_bin, _entries);
438 return mes_[iME]->getBinContent(_bin);
449 return mes_[iME]->getBinContent(_bin);
460 return mes_[iME]->getBinContent(_bin);
471 return mes_[iME]->getBinError(_bin);
482 return mes_[iME]->getBinError(_bin);
493 return mes_[iME]->getBinError(_bin);
505 return mes_[iME]->getBinEntries(_bin);
517 return mes_[iME]->getBinEntries(_bin);
529 return mes_[iME]->getBinEntries(_bin);
540 return mes_[iME]->getTH1()->FindBin(_x, _y);
551 return mes_[iME]->getTH1()->FindBin(_x, _y);
562 return mes_[iME]->getTH1()->FindBin(_x, _y);
571 std::vector<std::string>
576 vector<string> paths(0);
580 for(
unsigned iME(0); iME < nME; iME++) {
584 map<string, string> replacements;
589 replacements[
"subdet"] =
"EcalBarrel";
590 replacements[
"prefix"] =
"EB";
591 replacements[
"suffix"] =
"";
592 replacements[
"subdetshort"] =
"EB";
593 replacements[
"subdetshortsig"] =
"EB";
594 replacements[
"supercrystal"] =
"trigger tower";
598 replacements[
"subdet"] =
"EcalEndcap";
599 replacements[
"prefix"] =
"EE";
600 replacements[
"subdetshort"] =
"EE";
601 replacements[
"subdetshortsig"] =
"EE";
602 replacements[
"supercrystal"] =
"super crystal";
605 replacements[
"subdet"] =
"EcalEndcap";
606 replacements[
"prefix"] =
"EE";
607 replacements[
"suffix"] =
" EE -";
608 replacements[
"subdetshort"] =
"EE";
609 replacements[
"subdetshortsig"] =
"EEM";
610 replacements[
"supercrystal"] =
"super crystal";
613 replacements[
"subdet"] =
"EcalEndcap";
614 replacements[
"prefix"] =
"EE";
615 replacements[
"suffix"] =
" EE +";
616 replacements[
"subdetshort"] =
"EE";
617 replacements[
"subdetshortsig"] =
"EEP";
618 replacements[
"supercrystal"] =
"super crystal";
621 if(iME <= kEEmHigh || iME >=
kEEpLow){
622 replacements[
"subdet"] =
"EcalEndcap";
623 replacements[
"prefix"] =
"EE";
624 replacements[
"supercrystal"] =
"super crystal";
627 replacements[
"subdet"] =
"EcalBarrel";
628 replacements[
"prefix"] =
"EB";
629 replacements[
"supercrystal"] =
"trigger tower";
634 replacements[
"subdet"] =
"EcalBarrel";
635 replacements[
"prefix"] =
"EB";
637 replacements[
"supercrystal"] =
"trigger tower";
640 replacements[
"subdet"] =
"EcalEndcap";
641 replacements[
"prefix"] =
"EE";
643 replacements[
"supercrystal"] =
"super crystal";
649 if(iDCC <= kEEmHigh || iDCC >=
kEEpLow){
650 replacements[
"subdet"] =
"EcalEndcap";
651 replacements[
"prefix"] =
"EE";
654 replacements[
"subdet"] =
"EcalBarrel";
655 replacements[
"prefix"] =
"EB";
662 unsigned iDCC(
memDCCId(iME + 4) - 1);
663 replacements[
"subdet"] =
"EcalBarrel";
664 replacements[
"prefix"] =
"EB";
670 unsigned iDCC(
memDCCId(iME < 4 ? iME : iME + 36) - 1);
671 replacements[
"subdet"] =
"EcalEndcap";
672 replacements[
"prefix"] =
"EE";
679 paths.push_back(
formPath(replacements));
MonitorElement::Kind kind_
double getBinError(DetId const &, int) const override
double getBinContent(DetId const &, int) const override
MESet & operator=(MESet const &) override
virtual void clear() const
MonitorElement * bookProfile(Args &&...args)
virtual void checkME_(unsigned _iME) const
MonitorElement * get(const std::string &path)
void fill(DetId const &, double=1., double=1., double=1.) override
Ecal readout channel identification [32:20] Unused (so far) [19:13] DCC id [12:6] tower [5:3] strip [...
MESet * clone(std::string const &="") const override
unsigned getNObjects(ObjectType)
void setBinLabel(int bin, const std::string &label, int axis=1)
set bin label for x, y or z axis (axis=1, 2, 3 respectively)
ObjectType getObject(ObjectType, unsigned)
AxisSpecs getBinning(ObjectType, BinningType, bool, int, unsigned)
std::vector< MonitorElement * > mes_
void setBinEntries(DetId const &, int, double) override
void setLumiFlag()
this ME is meant to be stored for each luminosity section
void throw_(std::string const &_message) const
bool isVariableBinning() const override
MonitorElement * bookProfile2D(Args &&...args)
MonitorElement * book1D(Args &&...args)
std::string channelName(uint32_t, BinningType _btype=kDCC)
virtual void fill_(unsigned, int, double)
std::string formPath(PathReplacements const &) const
unsigned memDCCId(unsigned)
double getBinEntries(DetId const &, int) const override
void setCurrentFolder(const std::string &fullpath)
MESetEcal(std::string const &, binning::ObjectType, binning::BinningType, MonitorElement::Kind, unsigned, binning::AxisSpecs const *=0, binning::AxisSpecs const *=0, binning::AxisSpecs const *=0)
MonitorElement * book2D(Args &&...args)
unsigned findPlotIndex(ObjectType, DetId const &)
virtual int findBin(DetId const &, double, double=0.) const
binning::AxisSpecs const * zaxis_
bool retrieve(DQMStore::IGetter &, std::string *=0) const override
void setBinContent(DetId const &, int, double) override
binning::ObjectType otype_
binning::AxisSpecs const * xaxis_
std::vector< std::string > generatePaths() const
MonitorElement * bookFloat(Args &&...args)
virtual MESet & operator=(MESet const &)
void setBinError(DetId const &, int, double) override
binning::AxisSpecs const * yaxis_
binning::BinningType btype_
void setAxisTitle(const std::string &title, int axis=1)
set x-, y- or z-axis title (axis=1, 2, 3 respectively)
void book(DQMStore::IBooker &) override
unsigned logicalDimensions_