CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Private Attributes
FastTimerService::PlotsPerPath Class Reference

Public Member Functions

void book (dqm::reco::DQMStore::IBooker &, std::string const &, ProcessCallGraph const &, ProcessCallGraph::PathType const &, PlotRanges const &ranges, unsigned int lumisections, bool byls)
 
void fill (ProcessCallGraph::PathType const &, ResourcesPerJob const &, ResourcesPerPath const &, unsigned int lumisection)
 
 PlotsPerPath ()=default
 

Private Attributes

dqm::reco::MonitorElementmodule_allocated_total_
 
dqm::reco::MonitorElementmodule_counter_
 
dqm::reco::MonitorElementmodule_deallocated_total_
 
dqm::reco::MonitorElementmodule_time_real_total_
 
dqm::reco::MonitorElementmodule_time_thread_total_
 
PlotsPerElement total_
 

Detailed Description

Definition at line 352 of file FastTimerService.h.

Constructor & Destructor Documentation

FastTimerService::PlotsPerPath::PlotsPerPath ( )
default

Member Function Documentation

void FastTimerService::PlotsPerPath::book ( dqm::reco::DQMStore::IBooker booker,
std::string const &  prefixDir,
ProcessCallGraph const &  job,
ProcessCallGraph::PathType const &  path,
PlotRanges const &  ranges,
unsigned int  lumisections,
bool  byls 
)

Definition at line 560 of file FastTimerService.cc.

References makeHippyCampaign::basedir, newFWLiteAna::bin, dqm::implementation::IBooker::book1DD(), memory_usage::is_available(), label, callgraph::module, ProcessCallGraph::PathType::modules_and_dependencies_, ProcessCallGraph::PathType::name_, dqm::implementation::NavigatorBase::pwd(), dqm::implementation::NavigatorBase::setCurrentFolder(), dqm::impl::MonitorElement::setYTitle(), and AlCaHLTBitMon_QueryRunRegistry::string.

566  {
567  const std::string basedir = booker.pwd();
568  booker.setCurrentFolder(basedir + "/" + prefixDir + path.name_);
569 
570  total_.book(booker, "path", path.name_, ranges, lumisections, byls);
571 
572  // MonitorElement::setStatOverflows(kTRUE) includes underflows and overflows in the computation of mean and RMS
573  unsigned int bins = path.modules_and_dependencies_.size();
574  module_counter_ = booker.book1DD("module_counter", "module counter", bins + 1, -0.5, bins + 0.5);
575  module_counter_->setYTitle("events");
578  booker.book1DD("module_time_thread_total", "total module time (cpu)", bins, -0.5, bins - 0.5);
579  module_time_thread_total_->setYTitle("processing time [ms]");
582  booker.book1DD("module_time_real_total", "total module time (real)", bins, -0.5, bins - 0.5);
583  module_time_real_total_->setYTitle("processing time [ms]");
587  booker.book1DD("module_allocated_total", "total allocated memory", bins, -0.5, bins - 0.5);
588  module_allocated_total_->setYTitle("memory [kB]");
591  booker.book1DD("module_deallocated_total", "total deallocated memory", bins, -0.5, bins - 0.5);
592  module_deallocated_total_->setYTitle("memory [kB]");
594  }
595  for (unsigned int bin : boost::irange(0u, bins)) {
596  auto const& module = job[path.modules_and_dependencies_[bin]];
597  std::string const& label =
598  module.scheduled_ ? module.module_.moduleLabel() : module.module_.moduleLabel() + " (unscheduled)";
599  module_counter_->setBinLabel(bin + 1, label);
605  }
606  }
607  module_counter_->setBinLabel(bins + 1, "");
608 
609  booker.setCurrentFolder(basedir);
610 }
virtual void setCurrentFolder(std::string const &fullpath)
Definition: DQMStore.cc:32
dqm::reco::MonitorElement * module_deallocated_total_
virtual std::string pwd()
Definition: DQMStore.cc:16
char const * label
MonitorElement * book1DD(TString const &name, TString const &title, int nchX, double lowX, double highX, FUNC onbooking=NOOP())
Definition: DQMStore.h:155
dqm::reco::MonitorElement * module_time_thread_total_
dqm::reco::MonitorElement * module_time_real_total_
virtual 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)
string ranges
Definition: diffTwoXMLs.py:79
void book(dqm::reco::DQMStore::IBooker &, std::string const &name, std::string const &title, PlotRanges const &ranges, unsigned int lumisections, bool byls)
static bool is_available()
Definition: memory_usage.cc:84
virtual void setYTitle(std::string const &title)
virtual DQM_DEPRECATED void setStatOverflows(bool value)
dqm::reco::MonitorElement * module_allocated_total_
dqm::reco::MonitorElement * module_counter_
tuple module
Definition: callgraph.py:69
void FastTimerService::PlotsPerPath::fill ( ProcessCallGraph::PathType const &  description,
ResourcesPerJob const &  data,
ResourcesPerPath const &  path,
unsigned int  lumisection 
)

Definition at line 612 of file FastTimerService.cc.

References mps_fire::i, FastTimerService::ResourcesPerPath::last, callgraph::module, FastTimerService::ResourcesPerJob::modules, ProcessCallGraph::PathType::modules_and_dependencies_, FastTimerService::ResourcesPerPath::status, and FastTimerService::ResourcesPerPath::total.

615  {
616  // fill the total path time
617  total_.fill(path.total, ls);
618 
619  // fill the modules that actually ran and the total time spent in each od them
620  for (unsigned int i = 0; i < path.last; ++i) {
621  auto const& module = data.modules[description.modules_and_dependencies_[i]];
622  if (module_counter_)
624 
626  module_time_thread_total_->Fill(i, ms(module.total.time_thread));
627 
629  module_time_real_total_->Fill(i, ms(module.total.time_real));
630 
632  module_allocated_total_->Fill(i, kB(module.total.allocated));
633 
635  module_deallocated_total_->Fill(i, kB(module.total.deallocated));
636  }
637  if (module_counter_ and path.status)
638  module_counter_->Fill(path.last);
639 }
void fill(Resources const &, unsigned int lumisection)
dqm::reco::MonitorElement * module_deallocated_total_
def ls
Definition: eostools.py:349
void Fill(long long x)
dqm::reco::MonitorElement * module_time_thread_total_
dqm::reco::MonitorElement * module_time_real_total_
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
dqm::reco::MonitorElement * module_allocated_total_
dqm::reco::MonitorElement * module_counter_
tuple module
Definition: callgraph.py:69

Member Data Documentation

dqm::reco::MonitorElement* FastTimerService::PlotsPerPath::module_allocated_total_
private

Definition at line 381 of file FastTimerService.h.

dqm::reco::MonitorElement* FastTimerService::PlotsPerPath::module_counter_
private

Definition at line 377 of file FastTimerService.h.

dqm::reco::MonitorElement* FastTimerService::PlotsPerPath::module_deallocated_total_
private

Definition at line 382 of file FastTimerService.h.

dqm::reco::MonitorElement* FastTimerService::PlotsPerPath::module_time_real_total_
private

Definition at line 380 of file FastTimerService.h.

dqm::reco::MonitorElement* FastTimerService::PlotsPerPath::module_time_thread_total_
private

Definition at line 379 of file FastTimerService.h.

PlotsPerElement FastTimerService::PlotsPerPath::total_
private

Definition at line 369 of file FastTimerService.h.