CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
FastTimerService::PlotsPerPath Class Reference

Public Member Functions

void book (DQMStore::IBooker &, ProcessCallGraph const &, ProcessCallGraph::PathType const &, double range, double resolution, unsigned int lumisections, bool byls)
 
void fill (ProcessCallGraph::PathType const &, ResourcesPerJob const &, ResourcesPerPath const &, unsigned int lumisection)
 
 PlotsPerPath ()
 
void reset ()
 

Private Attributes

TH1D * module_counter_
 
TH1D * module_time_real_total_
 
TH1D * module_time_thread_total_
 
PlotsPerElement total_
 

Detailed Description

Definition at line 330 of file FastTimerService.h.

Constructor & Destructor Documentation

FastTimerService::PlotsPerPath::PlotsPerPath ( )

Definition at line 381 of file FastTimerService.cc.

381  :
382  total_(),
383  module_counter_(nullptr),
384  module_time_thread_total_(nullptr),
385  module_time_real_total_(nullptr)
386 {
387 }

Member Function Documentation

void FastTimerService::PlotsPerPath::book ( DQMStore::IBooker booker,
ProcessCallGraph const &  job,
ProcessCallGraph::PathType const &  path,
double  range,
double  resolution,
unsigned int  lumisections,
bool  byls 
)

Definition at line 400 of file FastTimerService.cc.

References stringResolutionProvider_cfi::bin, create_public_pileup_plots::bins, FastTimerService::PlotsPerElement::book(), DQMStore::IBooker::book1DD(), MonitorElement::getTH1D(), diffTwoXMLs::label, module_counter_, module_time_real_total_, module_time_thread_total_, ProcessCallGraph::PathType::modules_and_dependencies_, ProcessCallGraph::PathType::name_, DQMStore::IBooker::pwd(), DQMStore::IBooker::setCurrentFolder(), AlCaHLTBitMon_QueryRunRegistry::string, and total_.

408 {
409  const std::string basedir = booker.pwd();
410  booker.setCurrentFolder(basedir + "/path " + path.name_);
411 
412  total_.book(booker, "path", path.name_, range, resolution, lumisections, byls);
413 
414  unsigned int bins = path.modules_and_dependencies_.size();
415  module_counter_ = booker.book1DD(
416  "module_counter",
417  "module counter",
418  bins + 1, -0.5, bins + 0.5
419  )->getTH1D();
420  module_counter_->SetYTitle("processing time [ms]");
422  "module_time_thread_total",
423  "total module time (cpu)",
424  bins, -0.5, bins - 0.5
425  )->getTH1D();
426  module_time_thread_total_->SetYTitle("processing time [ms]");
428  "module_time_real_total",
429  "total module time (real)",
430  bins, -0.5, bins - 0.5
431  )->getTH1D();
432  module_time_real_total_->SetYTitle("processing time [ms]");
433  for (unsigned int bin: boost::irange(0u, bins)) {
434  auto const& module = job[path.modules_and_dependencies_[bin]];
435  std::string const& label = module.scheduled_ ? module.module_.moduleLabel() : module.module_.moduleLabel() + " (unscheduled)";
436  module_counter_ ->GetXaxis()->SetBinLabel(bin + 1, label.c_str());
437  module_time_thread_total_->GetXaxis()->SetBinLabel(bin + 1, label.c_str());
438  module_time_real_total_ ->GetXaxis()->SetBinLabel(bin + 1, label.c_str());
439  }
440  module_counter_->GetXaxis()->SetBinLabel(bins + 1, "");
441 
442  booker.setCurrentFolder(basedir);
443 }
void book(DQMStore::IBooker &, std::string const &name, std::string const &title, double range, double resolution, unsigned int lumisections, bool byls)
const std::string & pwd(void)
Definition: DQMStore.cc:285
TH1D * getTH1D(void) const
bin
set the eta bin as selection string.
void setCurrentFolder(const std::string &fullpath)
Definition: DQMStore.cc:277
MonitorElement * book1DD(Args &&...args)
Definition: DQMStore.h:127
Definition: vlib.h:208
void FastTimerService::PlotsPerPath::fill ( ProcessCallGraph::PathType const &  description,
ResourcesPerJob const &  data,
ResourcesPerPath const &  path,
unsigned int  lumisection 
)

Definition at line 446 of file FastTimerService.cc.

References FastTimerService::PlotsPerElement::fill(), mps_fire::i, FastTimerService::ResourcesPerPath::last, module_counter_, module_time_real_total_, module_time_thread_total_, FastTimerService::ResourcesPerJob::modules, ProcessCallGraph::PathType::modules_and_dependencies_, AnalysisDataFormats_SUSYBSMObjects::ms, FastTimerService::ResourcesPerPath::status, FastTimerService::ResourcesPerPath::total, and total_.

447 {
448  // fill the total path time
449  total_.fill(path.total, ls);
450 
451  // fill the modules that actually ran and the total time spent in each od them
452  for (unsigned int i = 0; i < path.last; ++i) {
453  auto const& module = data.modules[description.modules_and_dependencies_[i]];
454  module_counter_->Fill(i);
455  module_time_thread_total_->Fill(i, ms(module.total.time_thread));
456  module_time_real_total_->Fill(i, ms(module.total.time_real));
457  }
458  if (path.status)
459  module_counter_->Fill(path.last);
460 }
void fill(Resources const &, unsigned int lumisection)
def ls(path, rec=False)
Definition: eostools.py:348
susybsm::MuonSegment ms
Definition: classes.h:31
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
Definition: vlib.h:208
void FastTimerService::PlotsPerPath::reset ( void  )

Member Data Documentation

TH1D* FastTimerService::PlotsPerPath::module_counter_
private

Definition at line 347 of file FastTimerService.h.

Referenced by book(), fill(), and reset().

TH1D* FastTimerService::PlotsPerPath::module_time_real_total_
private

Definition at line 350 of file FastTimerService.h.

Referenced by book(), fill(), and reset().

TH1D* FastTimerService::PlotsPerPath::module_time_thread_total_
private

Definition at line 349 of file FastTimerService.h.

Referenced by book(), fill(), and reset().

PlotsPerElement FastTimerService::PlotsPerPath::total_
private

Definition at line 339 of file FastTimerService.h.

Referenced by book(), fill(), and reset().