CMS 3D CMS Logo

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

#include <Schedule.h>

Public Types

typedef std::vector
< edm::propagate_const
< std::shared_ptr
< OutputModuleCommunicator > > > 
AllOutputModuleCommunicators
 
typedef std::vector< Worker * > AllWorkers
 
typedef std::vector< std::string > vstring
 
typedef std::vector< Worker * > Workers
 

Public Member Functions

AllWorkers const & allWorkers () const
 returns the collection of pointers to workers More...
 
void availablePaths (std::vector< std::string > &oLabelsToFill) const
 adds to oLabelsToFill the labels for all paths in the process More...
 
void beginJob (ProductRegistry const &)
 
void beginStream (unsigned int)
 
bool changeModule (std::string const &iLabel, ParameterSet const &iPSet, const ProductRegistry &iRegistry)
 
void clearCounters ()
 Clear all the counters in the trigger report. More...
 
void closeOutputFiles ()
 
void enableEndPaths (bool active)
 
void endJob (ExceptionCollector &collector)
 
void endPaths (std::vector< std::string > &oLabelsToFill) const
 adds to oLabelsToFill the labels for all end paths in the process More...
 
bool endPathsEnabled () const
 
void endStream (unsigned int)
 
void fillModuleAndConsumesInfo (std::vector< ModuleDescription const * > &allModuleDescriptions, std::vector< std::pair< unsigned int, unsigned int > > &moduleIDToIndex, std::vector< std::vector< ModuleDescription const * > > &modulesWhoseProductsAreConsumedBy, ProductRegistry const &preg) const
 
std::vector< ModuleDescription
const * > 
getAllModuleDescriptions () const
 
void getTriggerReport (TriggerReport &rep) const
 
void getTriggerTimingReport (TriggerTimingReport &rep) const
 
void moduleDescriptionsInEndPath (std::string const &iEndPathLabel, std::vector< ModuleDescription const * > &descriptions, unsigned int hint) const
 
void moduleDescriptionsInPath (std::string const &iPathLabel, std::vector< ModuleDescription const * > &descriptions, unsigned int hint) const
 
void modulesInPath (std::string const &iPathLabel, std::vector< std::string > &oLabelsToFill) const
 adds to oLabelsToFill in execution order the labels of all modules in path iPathLabel More...
 
void openNewOutputFilesIfNeeded ()
 
void openOutputFiles (FileBlock &fb)
 
void postForkReacquireResources (unsigned int iChildIndex, unsigned int iNumberOfChildren)
 
void preForkReleaseResources ()
 
void processOneEventAsync (WaitingTaskHolder iTask, unsigned int iStreamID, EventPrincipal &principal, EventSetup const &eventSetup)
 
template<typename T >
void processOneGlobal (typename T::MyPrincipal &principal, EventSetup const &eventSetup, bool cleaningUpAfterException=false)
 
template<typename T >
void processOneStream (unsigned int iStreamID, typename T::MyPrincipal &principal, EventSetup const &eventSetup, bool cleaningUpAfterException=false)
 
void respondToCloseInputFile (FileBlock const &fb)
 
void respondToOpenInputFile (FileBlock const &fb)
 
 Schedule (ParameterSet &proc_pset, service::TriggerNamesService &tns, ProductRegistry &pregistry, BranchIDListHelper &branchIDListHelper, ThinnedAssociationsHelper &thinnedAssociationsHelper, ExceptionToActionTable const &actions, std::shared_ptr< ActivityRegistry > areg, std::shared_ptr< ProcessConfiguration > processConfiguration, bool hasSubprocesses, PreallocationConfiguration const &config, ProcessContext const *processContext)
 
bool shouldWeCloseOutput () const
 
bool terminate () const
 Return whether each output module has reached its maximum count. More...
 
int totalEvents () const
 
int totalEventsFailed () const
 
int totalEventsPassed () const
 
void triggerPaths (std::vector< std::string > &oLabelsToFill) const
 
void writeLumi (LuminosityBlockPrincipal const &lbp, ProcessContext const *)
 
void writeRun (RunPrincipal const &rp, ProcessContext const *)
 

Private Member Functions

void limitOutput (ParameterSet const &proc_pset, BranchIDLists const &branchIDLists)
 
std::shared_ptr
< ModuleRegistry const > 
moduleRegistry () const
 
std::shared_ptr< ModuleRegistry > & moduleRegistry ()
 
std::shared_ptr
< TriggerResultInserter const > 
resultsInserter () const
 
std::shared_ptr
< TriggerResultInserter > & 
resultsInserter ()
 

Private Attributes

AllOutputModuleCommunicators all_output_communicators_
 
volatile bool endpathsAreActive_
 
edm::propagate_const
< std::unique_ptr
< GlobalSchedule > > 
globalSchedule_
 
edm::propagate_const
< std::shared_ptr
< ModuleRegistry > > 
moduleRegistry_
 
PreallocationConfiguration preallocConfig_
 
edm::propagate_const
< std::shared_ptr
< TriggerResultInserter > > 
resultsInserter_
 
std::vector
< edm::propagate_const
< std::shared_ptr
< StreamSchedule > > > 
streamSchedules_
 
edm::propagate_const
< std::unique_ptr
< SystemTimeKeeper > > 
summaryTimeKeeper_
 
bool wantSummary_
 

Detailed Description

Definition at line 114 of file Schedule.h.

Member Typedef Documentation

Definition at line 118 of file Schedule.h.

typedef std::vector<Worker*> edm::Schedule::AllWorkers

Definition at line 117 of file Schedule.h.

typedef std::vector<std::string> edm::Schedule::vstring

Definition at line 116 of file Schedule.h.

typedef std::vector<Worker*> edm::Schedule::Workers

Definition at line 120 of file Schedule.h.

Constructor & Destructor Documentation

edm::Schedule::Schedule ( ParameterSet proc_pset,
service::TriggerNamesService tns,
ProductRegistry pregistry,
BranchIDListHelper branchIDListHelper,
ThinnedAssociationsHelper thinnedAssociationsHelper,
ExceptionToActionTable const &  actions,
std::shared_ptr< ActivityRegistry areg,
std::shared_ptr< ProcessConfiguration processConfiguration,
bool  hasSubprocesses,
PreallocationConfiguration const &  config,
ProcessContext const *  processContext 
)

Definition at line 372 of file Schedule.cc.

382  :
383  //Only create a resultsInserter if there is a trigger path
384  resultsInserter_{tns.getTrigPaths().empty()? std::shared_ptr<TriggerResultInserter>{} :makeInserter(proc_pset,prealloc,preg,actions,areg,processConfiguration)},
processConfiguration
Definition: Schedule.cc:384
actions
Definition: Schedule.cc:384
edm::propagate_const< std::shared_ptr< TriggerResultInserter > > resultsInserter_
Definition: Schedule.h:274
areg
Definition: Schedule.cc:384
preg
Definition: Schedule.cc:384
prealloc
Definition: Schedule.cc:384

Member Function Documentation

Schedule::AllWorkers const & edm::Schedule::allWorkers ( ) const

returns the collection of pointers to workers

Definition at line 1017 of file Schedule.cc.

References globalSchedule_.

Referenced by changeModule(), edm::PathsAndConsumesOfModules::doConsumesInfo(), fillModuleAndConsumesInfo(), getAllModuleDescriptions(), postForkReacquireResources(), preForkReleaseResources(), respondToCloseInputFile(), and respondToOpenInputFile().

1017  {
1018  return globalSchedule_->allWorkers();
1019  }
edm::propagate_const< std::unique_ptr< GlobalSchedule > > globalSchedule_
Definition: Schedule.h:278
void edm::Schedule::availablePaths ( std::vector< std::string > &  oLabelsToFill) const

adds to oLabelsToFill the labels for all paths in the process

Definition at line 1022 of file Schedule.cc.

References streamSchedules_.

Referenced by edm::ScheduleInfo::availablePaths().

1022  {
1023  streamSchedules_[0]->availablePaths(oLabelsToFill);
1024  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::beginJob ( ProductRegistry const &  iRegistry)

Definition at line 938 of file Schedule.cc.

References globalSchedule_.

938  {
939  globalSchedule_->beginJob(iRegistry);
940  }
edm::propagate_const< std::unique_ptr< GlobalSchedule > > globalSchedule_
Definition: Schedule.h:278
void edm::Schedule::beginStream ( unsigned int  iStreamID)

Definition at line 942 of file Schedule.cc.

References assert(), and streamSchedules_.

942  {
943  assert(iStreamID<streamSchedules_.size());
944  streamSchedules_[iStreamID]->beginStream();
945  }
assert(m_qm.get())
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
bool edm::Schedule::changeModule ( std::string const &  iLabel,
ParameterSet const &  iPSet,
const ProductRegistry iRegistry 
)

clone the type of module with label iLabel but configure with iPSet. Returns true if successful.

Definition at line 969 of file Schedule.cc.

References allWorkers(), newFWLiteAna::found, globalSchedule_, edm::InEvent, edm::InLumi, edm::InRun, moduleRegistry_, preallocConfig_, edm::ProductRegistry::productLookup(), streamSchedules_, and edm::Worker::updateLookup().

971  {
972  Worker* found = nullptr;
973  for (auto const& worker : allWorkers()) {
974  if (worker->description().moduleLabel() == iLabel) {
975  found = worker;
976  break;
977  }
978  }
979  if (nullptr == found) {
980  return false;
981  }
982 
983  auto newMod = moduleRegistry_->replaceModule(iLabel,iPSet,preallocConfig_);
984 
985  globalSchedule_->replaceModule(newMod,iLabel);
986 
987  for(auto& s: streamSchedules_) {
988  s->replaceModule(newMod,iLabel);
989  }
990 
991  {
992  //Need to updateLookup in order to make getByToken work
993  auto const runLookup = iRegistry.productLookup(InRun);
994  auto const lumiLookup = iRegistry.productLookup(InLumi);
995  auto const eventLookup = iRegistry.productLookup(InEvent);
996  found->updateLookup(InRun,*runLookup);
997  found->updateLookup(InLumi,*lumiLookup);
998  found->updateLookup(InEvent,*eventLookup);
999  }
1000 
1001  return true;
1002  }
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
edm::propagate_const< std::unique_ptr< GlobalSchedule > > globalSchedule_
Definition: Schedule.h:278
edm::propagate_const< std::shared_ptr< ModuleRegistry > > moduleRegistry_
Definition: Schedule.h:275
PreallocationConfiguration preallocConfig_
Definition: Schedule.h:281
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::clearCounters ( )

Clear all the counters in the trigger report.

Definition at line 1148 of file Schedule.cc.

References streamSchedules_.

1148  {
1149  for(auto& s: streamSchedules_) {
1150  s->clearCounters();
1151  }
1152  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::closeOutputFiles ( )

Definition at line 895 of file Schedule.cc.

References all_output_communicators_, edm::OutputModuleCommunicator::closeFile(), and edm::for_all().

895  {
896  using std::placeholders::_1;
898  }
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
void edm::Schedule::enableEndPaths ( bool  active)

Turn end_paths "off" if "active" is false; turn end_paths "on" if "active" is true.

Definition at line 1089 of file Schedule.cc.

References endpathsAreActive_, and streamSchedules_.

1089  {
1090  endpathsAreActive_ = active;
1091  for(auto& s : streamSchedules_) {
1092  s->enableEndPaths(active);
1093  }
1094  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
volatile bool endpathsAreActive_
Definition: Schedule.h:287
void edm::Schedule::endJob ( ExceptionCollector collector)

Definition at line 607 of file Schedule.cc.

References constexpr, edm::EventTimingSummary::cpuTime, edm::TriggerTimingReport::endPathSummaries, edm::TriggerReport::endPathSummaries, edm::TriggerTimingReport::eventSummary, edm::TriggerReport::eventSummary, getTriggerReport(), getTriggerTimingReport(), globalSchedule_, edm::ExceptionCollector::hasThrown(), bookConverter::max, mod(), edm::PreallocationConfiguration::numberOfThreads(), AlCaHLTBitMon_ParallelJobs::p, preallocConfig_, edm::EventTimingSummary::realTime, streamSchedules_, edm::EventTimingSummary::sumStreamRealTime, edm::EventTimingSummary::totalEvents, edm::EventSummary::totalEvents, totalEvents(), edm::EventSummary::totalEventsFailed, edm::EventSummary::totalEventsPassed, edm::TriggerTimingReport::trigPathSummaries, edm::TriggerReport::trigPathSummaries, wantSummary_, edm::TriggerTimingReport::workerSummaries, and edm::TriggerReport::workerSummaries.

607  {
608  globalSchedule_->endJob(collector);
609  if (collector.hasThrown()) {
610  return;
611  }
612 
613  if (wantSummary_ == false) return;
614  {
615  TriggerReport tr;
616  getTriggerReport(tr);
617 
618  // The trigger report (pass/fail etc.):
619 
620  LogVerbatim("FwkSummary") << "";
621  if(streamSchedules_[0]->context().processContext()->isSubProcess()) {
622  LogVerbatim("FwkSummary") << "TrigReport Process: "<<streamSchedules_[0]->context().processContext()->processName();
623  }
624  LogVerbatim("FwkSummary") << "TrigReport " << "---------- Event Summary ------------";
625  if(!tr.trigPathSummaries.empty()) {
626  LogVerbatim("FwkSummary") << "TrigReport"
627  << " Events total = " << tr.eventSummary.totalEvents
628  << " passed = " << tr.eventSummary.totalEventsPassed
629  << " failed = " << tr.eventSummary.totalEventsFailed
630  << "";
631  } else {
632  LogVerbatim("FwkSummary") << "TrigReport"
633  << " Events total = " << tr.eventSummary.totalEvents
634  << " passed = " << tr.eventSummary.totalEvents
635  << " failed = 0";
636  }
637 
638  LogVerbatim("FwkSummary") << "";
639  LogVerbatim("FwkSummary") << "TrigReport " << "---------- Path Summary ------------";
640  LogVerbatim("FwkSummary") << "TrigReport "
641  << std::right << std::setw(10) << "Trig Bit#" << " "
642  << std::right << std::setw(10) << "Executed" << " "
643  << std::right << std::setw(10) << "Passed" << " "
644  << std::right << std::setw(10) << "Failed" << " "
645  << std::right << std::setw(10) << "Error" << " "
646  << "Name" << "";
647  for (auto const& p: tr.trigPathSummaries) {
648  LogVerbatim("FwkSummary") << "TrigReport "
649  << std::right << std::setw(5) << 1
650  << std::right << std::setw(5) << p.bitPosition << " "
651  << std::right << std::setw(10) << p.timesRun << " "
652  << std::right << std::setw(10) << p.timesPassed << " "
653  << std::right << std::setw(10) << p.timesFailed << " "
654  << std::right << std::setw(10) << p.timesExcept << " "
655  << p.name << "";
656  }
657 
658  /*
659  std::vector<int>::const_iterator epi = empty_trig_paths_.begin();
660  std::vector<int>::const_iterator epe = empty_trig_paths_.end();
661  std::vector<std::string>::const_iterator epn = empty_trig_path_names_.begin();
662  for (; epi != epe; ++epi, ++epn) {
663 
664  LogVerbatim("FwkSummary") << "TrigReport "
665  << std::right << std::setw(5) << 1
666  << std::right << std::setw(5) << *epi << " "
667  << std::right << std::setw(10) << totalEvents() << " "
668  << std::right << std::setw(10) << totalEvents() << " "
669  << std::right << std::setw(10) << 0 << " "
670  << std::right << std::setw(10) << 0 << " "
671  << *epn << "";
672  }
673  */
674 
675  LogVerbatim("FwkSummary") << "";
676  LogVerbatim("FwkSummary") << "TrigReport " << "-------End-Path Summary ------------";
677  LogVerbatim("FwkSummary") << "TrigReport "
678  << std::right << std::setw(10) << "Trig Bit#" << " "
679  << std::right << std::setw(10) << "Executed" << " "
680  << std::right << std::setw(10) << "Passed" << " "
681  << std::right << std::setw(10) << "Failed" << " "
682  << std::right << std::setw(10) << "Error" << " "
683  << "Name" << "";
684  for (auto const& p: tr.endPathSummaries) {
685  LogVerbatim("FwkSummary") << "TrigReport "
686  << std::right << std::setw(5) << 0
687  << std::right << std::setw(5) << p.bitPosition << " "
688  << std::right << std::setw(10) << p.timesRun << " "
689  << std::right << std::setw(10) << p.timesPassed << " "
690  << std::right << std::setw(10) << p.timesFailed << " "
691  << std::right << std::setw(10) << p.timesExcept << " "
692  << p.name << "";
693  }
694 
695  for (auto const& p: tr.trigPathSummaries) {
696  LogVerbatim("FwkSummary") << "";
697  LogVerbatim("FwkSummary") << "TrigReport " << "---------- Modules in Path: " << p.name << " ------------";
698  LogVerbatim("FwkSummary") << "TrigReport "
699  << std::right << std::setw(10) << "Trig Bit#" << " "
700  << std::right << std::setw(10) << "Visited" << " "
701  << std::right << std::setw(10) << "Passed" << " "
702  << std::right << std::setw(10) << "Failed" << " "
703  << std::right << std::setw(10) << "Error" << " "
704  << "Name" << "";
705 
706  unsigned int bitpos = 0;
707  for (auto const& mod: p.moduleInPathSummaries) {
708  LogVerbatim("FwkSummary") << "TrigReport "
709  << std::right << std::setw(5) << 1
710  << std::right << std::setw(5) << bitpos << " "
711  << std::right << std::setw(10) << mod.timesVisited << " "
712  << std::right << std::setw(10) << mod.timesPassed << " "
713  << std::right << std::setw(10) << mod.timesFailed << " "
714  << std::right << std::setw(10) << mod.timesExcept << " "
715  << mod.moduleLabel << "";
716  ++bitpos;
717  }
718  }
719 
720  for (auto const& p: tr.endPathSummaries) {
721  LogVerbatim("FwkSummary") << "";
722  LogVerbatim("FwkSummary") << "TrigReport " << "------ Modules in End-Path: " << p.name << " ------------";
723  LogVerbatim("FwkSummary") << "TrigReport "
724  << std::right << std::setw(10) << "Trig Bit#" << " "
725  << std::right << std::setw(10) << "Visited" << " "
726  << std::right << std::setw(10) << "Passed" << " "
727  << std::right << std::setw(10) << "Failed" << " "
728  << std::right << std::setw(10) << "Error" << " "
729  << "Name" << "";
730 
731  unsigned int bitpos=0;
732  for (auto const& mod: p.moduleInPathSummaries) {
733  LogVerbatim("FwkSummary") << "TrigReport "
734  << std::right << std::setw(5) << 0
735  << std::right << std::setw(5) << bitpos << " "
736  << std::right << std::setw(10) << mod.timesVisited << " "
737  << std::right << std::setw(10) << mod.timesPassed << " "
738  << std::right << std::setw(10) << mod.timesFailed << " "
739  << std::right << std::setw(10) << mod.timesExcept << " "
740  << mod.moduleLabel << "";
741  ++bitpos;
742  }
743  }
744 
745  LogVerbatim("FwkSummary") << "";
746  LogVerbatim("FwkSummary") << "TrigReport " << "---------- Module Summary ------------";
747  LogVerbatim("FwkSummary") << "TrigReport "
748  << std::right << std::setw(10) << "Visited" << " "
749  << std::right << std::setw(10) << "Executed" << " "
750  << std::right << std::setw(10) << "Passed" << " "
751  << std::right << std::setw(10) << "Failed" << " "
752  << std::right << std::setw(10) << "Error" << " "
753  << "Name" << "";
754  for (auto const& worker : tr.workerSummaries) {
755  LogVerbatim("FwkSummary") << "TrigReport "
756  << std::right << std::setw(10) << worker.timesVisited << " "
757  << std::right << std::setw(10) << worker.timesRun << " "
758  << std::right << std::setw(10) << worker.timesPassed << " "
759  << std::right << std::setw(10) << worker.timesFailed << " "
760  << std::right << std::setw(10) << worker.timesExcept << " "
761  << worker.moduleLabel << "";
762  }
763  LogVerbatim("FwkSummary") << "";
764  }
765  // The timing report (CPU and Real Time):
766  TriggerTimingReport tr;
768 
769  const int totalEvents = std::max(1, tr.eventSummary.totalEvents);
770 
771  LogVerbatim("FwkSummary") << "TimeReport " << "---------- Event Summary ---[sec]----";
772  LogVerbatim("FwkSummary") << "TimeReport"
773  << std::setprecision(6) << std::fixed
774  << " event loop CPU/event = " << tr.eventSummary.cpuTime/totalEvents;
775  LogVerbatim("FwkSummary") << "TimeReport"
776  << std::setprecision(6) << std::fixed
777  << " event loop Real/event = " << tr.eventSummary.realTime/totalEvents;
778  LogVerbatim("FwkSummary") << "TimeReport"
779  << std::setprecision(6) << std::fixed
780  << " sum Streams Real/event = " << tr.eventSummary.sumStreamRealTime/totalEvents;
781  LogVerbatim("FwkSummary") << "TimeReport"
782  << std::setprecision(6) << std::fixed
783  << " efficiency CPU/Real/thread = " << tr.eventSummary.cpuTime/tr.eventSummary.realTime/preallocConfig_.numberOfThreads();
784 
785  constexpr int kColumn1Size = 10;
786  constexpr int kColumn2Size = 12;
787  constexpr int kColumn3Size = 12;
788  LogVerbatim("FwkSummary") << "";
789  LogVerbatim("FwkSummary") << "TimeReport " << "---------- Path Summary ---[Real sec]----";
790  LogVerbatim("FwkSummary") << "TimeReport "
791  << std::right << std::setw(kColumn1Size) << "per event"<<" "
792  << std::right << std::setw(kColumn2Size) << "per exec"
793  << " Name";
794  for (auto const& p: tr.trigPathSummaries) {
795  const int timesRun = std::max(1, p.timesRun);
796  LogVerbatim("FwkSummary") << "TimeReport "
797  << std::setprecision(6) << std::fixed
798  << std::right << std::setw(kColumn1Size) << p.realTime/totalEvents << " "
799  << std::right << std::setw(kColumn2Size) << p.realTime/timesRun << " "
800  << p.name << "";
801  }
802  LogVerbatim("FwkSummary") << "TimeReport "
803  << std::right << std::setw(kColumn1Size) << "per event"<<" "
804  << std::right << std::setw(kColumn2Size) << "per exec"
805  << " Name" << "";
806 
807  LogVerbatim("FwkSummary") << "";
808  LogVerbatim("FwkSummary") << "TimeReport " << "-------End-Path Summary ---[Real sec]----";
809  LogVerbatim("FwkSummary") << "TimeReport "
810  << std::right << std::setw(kColumn1Size) << "per event" <<" "
811  << std::right << std::setw(kColumn2Size) << "per exec"
812  << " Name" << "";
813  for (auto const& p: tr.endPathSummaries) {
814  const int timesRun = std::max(1, p.timesRun);
815 
816  LogVerbatim("FwkSummary") << "TimeReport "
817  << std::setprecision(6) << std::fixed
818  << std::right << std::setw(kColumn1Size) << p.realTime/totalEvents << " "
819  << std::right << std::setw(kColumn2Size) << p.realTime/timesRun << " "
820  << p.name << "";
821  }
822  LogVerbatim("FwkSummary") << "TimeReport "
823  << std::right << std::setw(kColumn1Size) << "per event" <<" "
824  << std::right << std::setw(kColumn2Size) << "per exec"
825  << " Name" << "";
826 
827  for (auto const& p: tr.trigPathSummaries) {
828  LogVerbatim("FwkSummary") << "";
829  LogVerbatim("FwkSummary") << "TimeReport " << "---------- Modules in Path: " << p.name << " ---[Real sec]----";
830  LogVerbatim("FwkSummary") << "TimeReport "
831  << std::right << std::setw(kColumn1Size) << "per event" <<" "
832  << std::right << std::setw(kColumn2Size) << "per visit"
833  << " Name" << "";
834  for (auto const& mod: p.moduleInPathSummaries) {
835  LogVerbatim("FwkSummary") << "TimeReport "
836  << std::setprecision(6) << std::fixed
837  << std::right << std::setw(kColumn1Size) << mod.realTime/totalEvents << " "
838  << std::right << std::setw(kColumn2Size) << mod.realTime/std::max(1, mod.timesVisited) << " "
839  << mod.moduleLabel << "";
840  }
841  }
842  if(not tr.trigPathSummaries.empty()) {
843  LogVerbatim("FwkSummary") << "TimeReport "
844  << std::right << std::setw(kColumn1Size) << "per event" <<" "
845  << std::right << std::setw(kColumn2Size) << "per visit"
846  << " Name" << "";
847  }
848  for (auto const& p: tr.endPathSummaries) {
849  LogVerbatim("FwkSummary") << "";
850  LogVerbatim("FwkSummary") << "TimeReport " << "------ Modules in End-Path: " << p.name << " ---[Real sec]----";
851  LogVerbatim("FwkSummary") << "TimeReport "
852  << std::right << std::setw(kColumn1Size) << "per event" <<" "
853  << std::right << std::setw(kColumn2Size) << "per visit"
854  << " Name" << "";
855  for (auto const& mod: p.moduleInPathSummaries) {
856  LogVerbatim("FwkSummary") << "TimeReport "
857  << std::setprecision(6) << std::fixed
858  << std::right << std::setw(kColumn1Size) << mod.realTime/totalEvents << " "
859  << std::right << std::setw(kColumn2Size) << mod.realTime/std::max(1, mod.timesVisited) << " "
860  << mod.moduleLabel << "";
861  }
862  }
863  if(not tr.endPathSummaries.empty()) {
864  LogVerbatim("FwkSummary") << "TimeReport "
865  << std::right << std::setw(kColumn1Size) << "per event" <<" "
866  << std::right << std::setw(kColumn2Size) << "per visit"
867  << " Name" << "";
868  }
869  LogVerbatim("FwkSummary") << "";
870  LogVerbatim("FwkSummary") << "TimeReport " << "---------- Module Summary ---[Real sec]----";
871  LogVerbatim("FwkSummary") << "TimeReport "
872  << std::right << std::setw(kColumn1Size) << "per event" <<" "
873  << std::right << std::setw(kColumn2Size) << "per exec" <<" "
874  << std::right << std::setw(kColumn3Size) << "per visit"
875  << " Name" << "";
876  for (auto const& worker : tr.workerSummaries) {
877  LogVerbatim("FwkSummary") << "TimeReport "
878  << std::setprecision(6) << std::fixed
879  << std::right << std::setw(kColumn1Size) << worker.realTime/totalEvents << " "
880  << std::right << std::setw(kColumn2Size) << worker.realTime/std::max(1, worker.timesRun) << " "
881  << std::right << std::setw(kColumn3Size) << worker.realTime/std::max(1, worker.timesVisited) << " "
882  << worker.moduleLabel << "";
883  }
884  LogVerbatim("FwkSummary") << "TimeReport "
885  << std::right << std::setw(kColumn1Size) << "per event" <<" "
886  << std::right << std::setw(kColumn2Size) << "per exec" <<" "
887  << std::right << std::setw(kColumn3Size) << "per visit"
888  << " Name" << "";
889 
890  LogVerbatim("FwkSummary") << "";
891  LogVerbatim("FwkSummary") << "T---Report end!" << "";
892  LogVerbatim("FwkSummary") << "";
893  }
#define constexpr
edm::propagate_const< std::unique_ptr< GlobalSchedule > > globalSchedule_
Definition: Schedule.h:278
int totalEvents() const
Definition: Schedule.cc:1120
void getTriggerReport(TriggerReport &rep) const
Definition: Schedule.cc:1102
PreallocationConfiguration preallocConfig_
Definition: Schedule.h:281
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
bool wantSummary_
Definition: Schedule.h:285
T mod(const T &a, const T &b)
Definition: ecalDccMap.h:4
void getTriggerTimingReport(TriggerTimingReport &rep) const
Definition: Schedule.cc:1112
void edm::Schedule::endPaths ( std::vector< std::string > &  oLabelsToFill) const

adds to oLabelsToFill the labels for all end paths in the process

Definition at line 1032 of file Schedule.cc.

References streamSchedules_.

Referenced by edm::PathsAndConsumesOfModules::initialize().

1032  {
1033  streamSchedules_[0]->endPaths(oLabelsToFill);
1034  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
bool edm::Schedule::endPathsEnabled ( ) const

Return true if end_paths are active, and false if they are inactive.

Definition at line 1097 of file Schedule.cc.

References endpathsAreActive_.

1097  {
1098  return endpathsAreActive_;
1099  }
volatile bool endpathsAreActive_
Definition: Schedule.h:287
void edm::Schedule::endStream ( unsigned int  iStreamID)

Definition at line 947 of file Schedule.cc.

References assert(), and streamSchedules_.

947  {
948  assert(iStreamID<streamSchedules_.size());
949  streamSchedules_[iStreamID]->endStream();
950  }
assert(m_qm.get())
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::fillModuleAndConsumesInfo ( std::vector< ModuleDescription const * > &  allModuleDescriptions,
std::vector< std::pair< unsigned int, unsigned int > > &  moduleIDToIndex,
std::vector< std::vector< ModuleDescription const * > > &  modulesWhoseProductsAreConsumedBy,
ProductRegistry const &  preg 
) const

Definition at line 1057 of file Schedule.cc.

References allWorkers(), i, edm::ModuleDescription::id(), edm::ModuleDescription::moduleLabel(), edmConvertToStreamModule::modules, AlCaHLTBitMon_ParallelJobs::p, findQualityFiles::size, and edm::sort_all().

Referenced by edm::PathsAndConsumesOfModules::initialize().

1060  {
1061  allModuleDescriptions.clear();
1062  moduleIDToIndex.clear();
1063  modulesWhoseProductsAreConsumedBy.clear();
1064 
1065  allModuleDescriptions.reserve(allWorkers().size());
1066  moduleIDToIndex.reserve(allWorkers().size());
1067  modulesWhoseProductsAreConsumedBy.resize(allWorkers().size());
1068 
1069  std::map<std::string, ModuleDescription const*> labelToDesc;
1070  unsigned int i = 0;
1071  for (auto const& worker : allWorkers()) {
1072  ModuleDescription const* p = worker->descPtr();
1073  allModuleDescriptions.push_back(p);
1074  moduleIDToIndex.push_back(std::pair<unsigned int, unsigned int>(p->id(), i));
1075  labelToDesc[p->moduleLabel()] = p;
1076  ++i;
1077  }
1078  sort_all(moduleIDToIndex);
1079 
1080  i = 0;
1081  for (auto const& worker : allWorkers()) {
1082  std::vector<ModuleDescription const*>& modules = modulesWhoseProductsAreConsumedBy.at(i);
1083  worker->modulesWhoseProductsAreConsumed(modules, preg, labelToDesc);
1084  ++i;
1085  }
1086  }
int i
Definition: DBlmapReader.cc:9
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
void sort_all(RandomAccessSequence &s)
wrappers for std::sort
Definition: Algorithms.h:120
preg
Definition: Schedule.cc:384
tuple size
Write out results.
std::vector< ModuleDescription const * > edm::Schedule::getAllModuleDescriptions ( ) const

Return a vector allowing const access to all the ModuleDescriptions for this Schedule. *** N.B. *** Ownership of the ModuleDescriptions is not *** passed to the caller. Do not call delete on these *** pointers!

Definition at line 1005 of file Schedule.cc.

References allWorkers(), AlCaHLTBitMon_ParallelJobs::p, mps_fire::result, and findQualityFiles::size.

Referenced by edm::ScheduleInfo::availableModuleLabels(), and edm::ScheduleInfo::parametersForModule().

1005  {
1006  std::vector<ModuleDescription const*> result;
1007  result.reserve(allWorkers().size());
1008 
1009  for (auto const& worker : allWorkers()) {
1010  ModuleDescription const* p = worker->descPtr();
1011  result.push_back(p);
1012  }
1013  return result;
1014  }
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
tuple result
Definition: mps_fire.py:84
tuple size
Write out results.
void edm::Schedule::getTriggerReport ( TriggerReport rep) const

Return the trigger report information on paths, modules-in-path, modules-in-endpath, and modules.

Definition at line 1102 of file Schedule.cc.

References edm::TriggerReport::eventSummary, streamSchedules_, edm::EventSummary::totalEvents, edm::EventSummary::totalEventsFailed, and edm::EventSummary::totalEventsPassed.

Referenced by endJob().

1102  {
1103  rep.eventSummary.totalEvents = 0;
1104  rep.eventSummary.totalEventsPassed = 0;
1105  rep.eventSummary.totalEventsFailed = 0;
1106  for(auto& s: streamSchedules_) {
1107  s->getTriggerReport(rep);
1108  }
1109  }
string rep
Definition: cuy.py:1188
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::getTriggerTimingReport ( TriggerTimingReport rep) const

Return the trigger timing report information on paths, modules-in-path, modules-in-endpath, and modules.

Definition at line 1112 of file Schedule.cc.

References edm::EventTimingSummary::cpuTime, edm::TriggerTimingReport::eventSummary, edm::EventTimingSummary::realTime, summaryTimeKeeper_, and edm::EventTimingSummary::totalEvents.

Referenced by endJob().

1112  {
1113  rep.eventSummary.totalEvents = 0;
1114  rep.eventSummary.cpuTime = 0.;
1115  rep.eventSummary.realTime = 0.;
1116  summaryTimeKeeper_->fillTriggerTimingReport(rep);
1117  }
string rep
Definition: cuy.py:1188
edm::propagate_const< std::unique_ptr< SystemTimeKeeper > > summaryTimeKeeper_
Definition: Schedule.h:283
void edm::Schedule::limitOutput ( ParameterSet const &  proc_pset,
BranchIDLists const &  branchIDLists 
)
private

Definition at line 552 of file Schedule.cc.

References all_output_communicators_, EnergyCorrector::c, edm::errors::Configuration, edm::ParameterSet::empty(), Exception, edm::ParameterSet::getParameterNamesForType(), edm::ParameterSet::getParameterSetNames(), edm::ParameterSet::getUntrackedParameter(), edm::ParameterSet::getUntrackedParameterSet(), edm::OutputModuleDescription::maxEvents_, convertSQLitetoXML_cfg::output, edm::search_all(), and AlCaHLTBitMon_QueryRunRegistry::string.

552  {
553  std::string const output("output");
554 
555  ParameterSet const& maxEventsPSet = proc_pset.getUntrackedParameterSet("maxEvents", ParameterSet());
556  int maxEventSpecs = 0;
557  int maxEventsOut = -1;
558  ParameterSet const* vMaxEventsOut = 0;
559  std::vector<std::string> intNamesE = maxEventsPSet.getParameterNamesForType<int>(false);
560  if (search_all(intNamesE, output)) {
561  maxEventsOut = maxEventsPSet.getUntrackedParameter<int>(output);
562  ++maxEventSpecs;
563  }
564  std::vector<std::string> psetNamesE;
565  maxEventsPSet.getParameterSetNames(psetNamesE, false);
566  if (search_all(psetNamesE, output)) {
567  vMaxEventsOut = &maxEventsPSet.getUntrackedParameterSet(output);
568  ++maxEventSpecs;
569  }
570 
571  if (maxEventSpecs > 1) {
573  "\nAt most, one form of 'output' may appear in the 'maxEvents' parameter set";
574  }
575 
576  for (auto& c : all_output_communicators_) {
577  OutputModuleDescription desc(branchIDLists, maxEventsOut);
578  if (vMaxEventsOut != 0 && !vMaxEventsOut->empty()) {
579  std::string const& moduleLabel = c->description().moduleLabel();
580  try {
581  desc.maxEvents_ = vMaxEventsOut->getUntrackedParameter<int>(moduleLabel);
582  } catch (Exception const&) {
584  "\nNo entry in 'maxEvents' for output module label '" << moduleLabel << "'.\n";
585  }
586  }
587  c->configure(desc);
588  }
589  }
bool search_all(ForwardSequence const &s, Datum const &d)
Definition: Algorithms.h:46
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
void edm::Schedule::moduleDescriptionsInEndPath ( std::string const &  iEndPathLabel,
std::vector< ModuleDescription const * > &  descriptions,
unsigned int  hint 
) const

adds the ModuleDescriptions into the vector for the modules scheduled in path iEndPathLabel hint is a performance optimization if you might know the position of the module in the path

Definition at line 1050 of file Schedule.cc.

References streamSchedules_.

Referenced by edm::PathsAndConsumesOfModules::initialize().

1052  {
1053  streamSchedules_[0]->moduleDescriptionsInEndPath(iEndPathLabel, descriptions, hint);
1054  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::moduleDescriptionsInPath ( std::string const &  iPathLabel,
std::vector< ModuleDescription const * > &  descriptions,
unsigned int  hint 
) const

adds the ModuleDescriptions into the vector for the modules scheduled in path iPathLabel hint is a performance optimization if you might know the position of the module in the path

Definition at line 1043 of file Schedule.cc.

References streamSchedules_.

Referenced by edm::PathsAndConsumesOfModules::initialize().

1045  {
1046  streamSchedules_[0]->moduleDescriptionsInPath(iPathLabel, descriptions, hint);
1047  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
std::shared_ptr<ModuleRegistry const> edm::Schedule::moduleRegistry ( ) const
inlineprivate

Definition at line 271 of file Schedule.h.

References edm::get_underlying_safe(), and moduleRegistry_.

std::shared_ptr< T > & get_underlying_safe(propagate_const< std::shared_ptr< T >> &iP)
edm::propagate_const< std::shared_ptr< ModuleRegistry > > moduleRegistry_
Definition: Schedule.h:275
std::shared_ptr<ModuleRegistry>& edm::Schedule::moduleRegistry ( )
inlineprivate

Definition at line 272 of file Schedule.h.

References edm::get_underlying_safe(), and moduleRegistry_.

std::shared_ptr< T > & get_underlying_safe(propagate_const< std::shared_ptr< T >> &iP)
edm::propagate_const< std::shared_ptr< ModuleRegistry > > moduleRegistry_
Definition: Schedule.h:275
void edm::Schedule::modulesInPath ( std::string const &  iPathLabel,
std::vector< std::string > &  oLabelsToFill 
) const

adds to oLabelsToFill in execution order the labels of all modules in path iPathLabel

Definition at line 1037 of file Schedule.cc.

References streamSchedules_.

Referenced by edm::ScheduleInfo::modulesInPath().

1038  {
1039  streamSchedules_[0]->modulesInPath(iPathLabel,oLabelsToFill);
1040  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::openNewOutputFilesIfNeeded ( )

Definition at line 900 of file Schedule.cc.

References all_output_communicators_, edm::for_all(), and edm::OutputModuleCommunicator::openNewFileIfNeeded().

900  {
901  using std::placeholders::_1;
903  }
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
virtual void openNewFileIfNeeded()=0
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
void edm::Schedule::openOutputFiles ( FileBlock fb)

Definition at line 905 of file Schedule.cc.

References all_output_communicators_, edm::for_all(), and edm::OutputModuleCommunicator::openFile().

905  {
906  using std::placeholders::_1;
908  }
virtual void openFile(FileBlock const &fb)=0
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
void edm::Schedule::postForkReacquireResources ( unsigned int  iChildIndex,
unsigned int  iNumberOfChildren 
)

Definition at line 964 of file Schedule.cc.

References allWorkers(), edm::for_all(), and edm::Worker::postForkReacquireResources().

964  {
965  using std::placeholders::_1;
966  for_all(allWorkers(), std::bind(&Worker::postForkReacquireResources, _1, iChildIndex, iNumberOfChildren));
967  }
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
void postForkReacquireResources(unsigned int iChildIndex, unsigned int iNumberOfChildren)
Definition: Worker.h:110
void edm::Schedule::preForkReleaseResources ( )

Definition at line 960 of file Schedule.cc.

References allWorkers(), edm::for_all(), and edm::Worker::preForkReleaseResources().

960  {
961  using std::placeholders::_1;
963  }
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
void preForkReleaseResources()
Definition: Worker.h:109
void edm::Schedule::processOneEventAsync ( WaitingTaskHolder  iTask,
unsigned int  iStreamID,
EventPrincipal principal,
EventSetup const &  eventSetup 
)

Definition at line 952 of file Schedule.cc.

References assert(), eostools::move(), and streamSchedules_.

955  {
956  assert(iStreamID<streamSchedules_.size());
957  streamSchedules_[iStreamID]->processOneEventAsync(std::move(iTask),ep,es);
958  }
assert(m_qm.get())
def move
Definition: eostools.py:510
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
template<typename T >
void edm::Schedule::processOneGlobal ( typename T::MyPrincipal &  principal,
EventSetup const &  eventSetup,
bool  cleaningUpAfterException = false 
)

Definition at line 301 of file Schedule.h.

References globalSchedule_.

303  {
304  globalSchedule_->processOneGlobal<T>(ep,es,cleaningUpAfterException);
305  }
edm::propagate_const< std::unique_ptr< GlobalSchedule > > globalSchedule_
Definition: Schedule.h:278
long double T
template<typename T >
void edm::Schedule::processOneStream ( unsigned int  iStreamID,
typename T::MyPrincipal &  principal,
EventSetup const &  eventSetup,
bool  cleaningUpAfterException = false 
)

Definition at line 292 of file Schedule.h.

References assert(), and streamSchedules_.

295  {
296  assert(iStreamID<streamSchedules_.size());
297  streamSchedules_[iStreamID]->processOneStream<T>(ep,es,cleaningUpAfterException);
298  }
assert(m_qm.get())
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
long double T
void edm::Schedule::respondToCloseInputFile ( FileBlock const &  fb)

Definition at line 933 of file Schedule.cc.

References allWorkers(), edm::for_all(), and edm::Worker::respondToCloseInputFile().

933  {
934  using std::placeholders::_1;
935  for_all(allWorkers(), std::bind(&Worker::respondToCloseInputFile, _1, std::cref(fb)));
936  }
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
void respondToCloseInputFile(FileBlock const &fb)
Definition: Worker.h:107
void edm::Schedule::respondToOpenInputFile ( FileBlock const &  fb)

Definition at line 928 of file Schedule.cc.

References allWorkers(), edm::for_all(), and edm::Worker::respondToOpenInputFile().

928  {
929  using std::placeholders::_1;
930  for_all(allWorkers(), std::bind(&Worker::respondToOpenInputFile, _1, std::cref(fb)));
931  }
AllWorkers const & allWorkers() const
returns the collection of pointers to workers
Definition: Schedule.cc:1017
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
void respondToOpenInputFile(FileBlock const &fb)
Definition: Worker.h:106
std::shared_ptr<TriggerResultInserter const> edm::Schedule::resultsInserter ( ) const
inlineprivate

Definition at line 269 of file Schedule.h.

References edm::get_underlying_safe(), and resultsInserter_.

edm::propagate_const< std::shared_ptr< TriggerResultInserter > > resultsInserter_
Definition: Schedule.h:274
std::shared_ptr< T > & get_underlying_safe(propagate_const< std::shared_ptr< T >> &iP)
std::shared_ptr<TriggerResultInserter>& edm::Schedule::resultsInserter ( )
inlineprivate

Definition at line 270 of file Schedule.h.

References edm::get_underlying_safe(), and resultsInserter_.

edm::propagate_const< std::shared_ptr< TriggerResultInserter > > resultsInserter_
Definition: Schedule.h:274
std::shared_ptr< T > & get_underlying_safe(propagate_const< std::shared_ptr< T >> &iP)
bool edm::Schedule::shouldWeCloseOutput ( ) const

Definition at line 920 of file Schedule.cc.

References all_output_communicators_, and edm::OutputModuleCommunicator::shouldWeCloseFile().

920  {
921  using std::placeholders::_1;
922  // Return true iff at least one output module returns true.
923  return (std::find_if (all_output_communicators_.begin(), all_output_communicators_.end(),
925  != all_output_communicators_.end());
926  }
virtual bool shouldWeCloseFile() const =0
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
bool edm::Schedule::terminate ( void  ) const

Return whether each output module has reached its maximum count.

Definition at line 591 of file Schedule.cc.

References all_output_communicators_, and EnergyCorrector::c.

591  {
592  if (all_output_communicators_.empty()) {
593  return false;
594  }
595  for (auto& c : all_output_communicators_) {
596  if (!c->limitReached()) {
597  // Found an output module that has not reached output event count.
598  return false;
599  }
600  }
601  LogInfo("SuccessfulTermination")
602  << "The job is terminating successfully because each output module\n"
603  << "has reached its configured limit.\n";
604  return true;
605  }
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
int edm::Schedule::totalEvents ( ) const

Return the number of events this Schedule has tried to process (inclues both successes and failures, including failures due to exceptions during processing).

Definition at line 1120 of file Schedule.cc.

References streamSchedules_.

Referenced by endJob().

1120  {
1121  int returnValue = 0;
1122  for(auto& s: streamSchedules_) {
1123  returnValue += s->totalEvents();
1124  }
1125  return returnValue;
1126  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
int edm::Schedule::totalEventsFailed ( ) const

Return the number of events that have not passed any trigger. (N.B. totalEventsFailed() + totalEventsPassed() == totalEvents()

Definition at line 1138 of file Schedule.cc.

References streamSchedules_.

1138  {
1139  int returnValue = 0;
1140  for(auto& s: streamSchedules_) {
1141  returnValue += s->totalEventsFailed();
1142  }
1143  return returnValue;
1144  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
int edm::Schedule::totalEventsPassed ( ) const

Return the number of events which have been passed by one or more trigger paths.

Definition at line 1129 of file Schedule.cc.

References streamSchedules_.

1129  {
1130  int returnValue = 0;
1131  for(auto& s: streamSchedules_) {
1132  returnValue += s->totalEventsPassed();
1133  }
1134  return returnValue;
1135  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::triggerPaths ( std::vector< std::string > &  oLabelsToFill) const

Adds to oLabelsToFill the labels for all trigger paths in the process. This is different from availablePaths because it includes the empty paths to match the entries in TriggerResults exactly.

Definition at line 1027 of file Schedule.cc.

References streamSchedules_.

Referenced by edm::PathsAndConsumesOfModules::initialize().

1027  {
1028  streamSchedules_[0]->triggerPaths(oLabelsToFill);
1029  }
std::vector< edm::propagate_const< std::shared_ptr< StreamSchedule > > > streamSchedules_
Definition: Schedule.h:276
void edm::Schedule::writeLumi ( LuminosityBlockPrincipal const &  lbp,
ProcessContext const *  processContext 
)

Definition at line 915 of file Schedule.cc.

References all_output_communicators_, edm::for_all(), and edm::OutputModuleCommunicator::writeLumi().

915  {
916  using std::placeholders::_1;
917  for_all(all_output_communicators_, std::bind(&OutputModuleCommunicator::writeLumi, _1, std::cref(lbp), processContext));
918  }
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
virtual void writeLumi(LuminosityBlockPrincipal const &lbp, ProcessContext const *)=0
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280
void edm::Schedule::writeRun ( RunPrincipal const &  rp,
ProcessContext const *  processContext 
)

Definition at line 910 of file Schedule.cc.

References all_output_communicators_, edm::for_all(), and edm::OutputModuleCommunicator::writeRun().

910  {
911  using std::placeholders::_1;
912  for_all(all_output_communicators_, std::bind(&OutputModuleCommunicator::writeRun, _1, std::cref(rp), processContext));
913  }
virtual void writeRun(RunPrincipal const &rp, ProcessContext const *)=0
Func for_all(ForwardSequence &s, Func f)
wrapper for std::for_each
Definition: Algorithms.h:16
AllOutputModuleCommunicators all_output_communicators_
Definition: Schedule.h:280

Member Data Documentation

AllOutputModuleCommunicators edm::Schedule::all_output_communicators_
private
volatile bool edm::Schedule::endpathsAreActive_
private

Definition at line 287 of file Schedule.h.

Referenced by enableEndPaths(), and endPathsEnabled().

edm::propagate_const<std::unique_ptr<GlobalSchedule> > edm::Schedule::globalSchedule_
private

Definition at line 278 of file Schedule.h.

Referenced by allWorkers(), beginJob(), changeModule(), endJob(), and processOneGlobal().

edm::propagate_const<std::shared_ptr<ModuleRegistry> > edm::Schedule::moduleRegistry_
private

Definition at line 275 of file Schedule.h.

Referenced by changeModule(), and moduleRegistry().

PreallocationConfiguration edm::Schedule::preallocConfig_
private

Definition at line 281 of file Schedule.h.

Referenced by changeModule(), and endJob().

edm::propagate_const<std::shared_ptr<TriggerResultInserter> > edm::Schedule::resultsInserter_
private

Definition at line 274 of file Schedule.h.

Referenced by resultsInserter().

std::vector<edm::propagate_const<std::shared_ptr<StreamSchedule> > > edm::Schedule::streamSchedules_
private
edm::propagate_const<std::unique_ptr<SystemTimeKeeper> > edm::Schedule::summaryTimeKeeper_
private

Definition at line 283 of file Schedule.h.

Referenced by getTriggerTimingReport().

bool edm::Schedule::wantSummary_
private

Definition at line 285 of file Schedule.h.

Referenced by endJob().