CMS 3D CMS Logo

EcalMEFormatter.cc
Go to the documentation of this file.
2 
4 
7 
9 
10 #include <limits>
11 
13  initialize("EcalMEFormatter", _ps);
14  setME(_ps.getUntrackedParameterSet("MEs"));
15  verbosity_ = _ps.getUntrackedParameter<int>("verbosity", 0);
16 }
17 
18 /*static*/
22  desc.addUntracked<int>("verbosity", 0);
23 
24  _descs.addDefault(desc);
25 }
26 
28  DQMStore::IGetter &_igetter,
29  edm::LuminosityBlock const &,
30  edm::EventSetup const &_es) {
31  setSetupObjects(_es);
32  format_(_igetter, true);
33 }
34 
36 
37 void EcalMEFormatter::format_(DQMStore::IGetter &_igetter, bool _checkLumi) {
38  std::string failedPath;
39 
40  for (auto &mItr : MEs_) {
41  if (_checkLumi && !mItr.second->getLumiFlag())
42  continue;
43  mItr.second->clear();
44  if (!mItr.second->retrieve(GetElectronicsMap(), _igetter, &failedPath)) {
45  if (verbosity_ > 0)
46  edm::LogWarning("EcalDQM") << "Could not find ME " << mItr.first << "@" << failedPath;
47  continue;
48  }
49  if (verbosity_ > 1)
50  edm::LogInfo("EcalDQM") << "Retrieved " << mItr.first << " from DQMStore";
51 
52  if (dynamic_cast<ecaldqm::MESetDet2D *>(mItr.second.get()))
53  formatDet2D_(*mItr.second);
54  }
55 }
56 
58 
EcalMEFormatter::dqmEndJob
void dqmEndJob(DQMStore::IBooker &, DQMStore::IGetter &) override
Definition: EcalMEFormatter.cc:35
ecaldqm
Definition: DQWorker.h:29
EcalMEFormatter::dqmEndLuminosityBlock
void dqmEndLuminosityBlock(DQMStore::IBooker &, DQMStore::IGetter &, edm::LuminosityBlock const &, edm::EventSetup const &) override
Definition: EcalMEFormatter.cc:27
edm::ParameterSet::getUntrackedParameterSet
ParameterSet getUntrackedParameterSet(std::string const &name, ParameterSet const &defaultValue) const
Definition: ParameterSet.cc:2136
edm::LuminosityBlock
Definition: LuminosityBlock.h:50
edm::ParameterSetDescription
Definition: ParameterSetDescription.h:52
DQMStore.h
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
ecaldqm::DQWorker::GetElectronicsMap
const EcalElectronicsMapping * GetElectronicsMap()
Definition: DQWorker.cc:104
EcalMEFormatter.h
ecaldqm::DQWorker::setSetupObjects
void setSetupObjects(edm::EventSetup const &)
Definition: DQWorker.cc:86
MakerMacros.h
DEFINE_FWK_MODULE
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:16
Service.h
EcalMEFormatter
Definition: EcalMEFormatter.h:9
ecaldqm::DQWorker::fillDescriptions
static void fillDescriptions(edm::ParameterSetDescription &_desc)
Definition: DQWorker.cc:31
ecaldqm::DQWorker::MEs_
MESetCollection MEs_
Definition: DQWorker.h:104
edm::ConfigurationDescriptions
Definition: ConfigurationDescriptions.h:28
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
edm::ParameterSet
Definition: ParameterSet.h:47
EcalMEFormatter::format_
void format_(DQMStore::IGetter &, bool)
Definition: EcalMEFormatter.cc:37
ecaldqm::DQWorker::initialize
void initialize(std::string const &_name, edm::ParameterSet const &)
Definition: DQWorker.cc:47
MESetDet2D.h
edm::EventSetup
Definition: EventSetup.h:58
ecaldqm::DQWorker::setME
virtual void setME(edm::ParameterSet const &)
Definition: DQWorker.cc:53
DQMEDHarvester
Definition: DQMEDHarvester.py:1
submitPVResolutionJobs.desc
string desc
Definition: submitPVResolutionJobs.py:251
dqm::implementation::IGetter
Definition: DQMStore.h:484
ecaldqm::DQWorker::verbosity_
int verbosity_
Definition: DQWorker.h:108
dqm::implementation::IBooker
Definition: DQMStore.h:43
EcalMEFormatter::formatDet2D_
void formatDet2D_(ecaldqm::MESet &)
Definition: EcalMEFormatter.cc:57
EcalMEFormatter::EcalMEFormatter
EcalMEFormatter(edm::ParameterSet const &)
Definition: EcalMEFormatter.cc:12
EcalMEFormatter::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &)
Definition: EcalMEFormatter.cc:19
edm::ConfigurationDescriptions::addDefault
void addDefault(ParameterSetDescription const &psetDescription)
Definition: ConfigurationDescriptions.cc:99
ecaldqm::MESet
Definition: MESet.h:42