CMS 3D CMS Logo

List of all members | Public Types | Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes
fwlite::MultiChainEvent Class Reference

#include <MultiChainEvent.h>

Inheritance diagram for fwlite::MultiChainEvent:
fwlite::EventBase edm::EventBase

Public Types

typedef std::pair< edm::EventID, edm::EventIDevent_id_range
 
typedef std::map< edm::EventID, Long64_t > sec_file_index_map
 
typedef std::map< event_id_range, Long64_t > sec_file_range_index_map
 

Public Member Functions

bool atEnd () const override
 
edm::EventAuxiliary const & eventAuxiliary () const override
 
Long64_t eventIndex () const
 
Long64_t eventIndexSec () const
 
Long64_t fileIndex () const override
 
std::vector< edm::BranchDescription > const & getBranchDescriptions () const
 
const std::string getBranchNameFor (std::type_info const &, char const *, char const *, char const *) const override
 
bool getByLabel (std::type_info const &, char const *, char const *, char const *, void *) const override
 
edm::WrapperBase const * getByProductID (edm::ProductID const &) const override
 
fwlite::LuminosityBlock const & getLuminosityBlock ()
 
std::vector< std::string > const & getProcessHistory () const
 
fwlite::Run const & getRun ()
 
TFile * getTFile () const
 
TFile * getTFileSec () const
 
edm::WrapperBase const * getThinnedProduct (edm::ProductID const &pid, unsigned int &key) const
 
void getThinnedProducts (edm::ProductID const &pid, std::vector< edm::WrapperBase const * > &foundContainers, std::vector< unsigned int > &keys) const
 
bool isValid () const
 
 MultiChainEvent (std::vector< std::string > const &iFileNames1, std::vector< std::string > const &iFileNames2, bool useSecFileMapSorted=false)
 
 operator bool () const
 
const MultiChainEventoperator++ () override
 
edm::ParameterSet const * parameterSet (edm::ParameterSetID const &psID) const override
 
ChainEvent const * primary () const
 
edm::ProcessHistory const & processHistory () const override
 
ChainEvent const * secondary () const
 
Long64_t secondaryFileIndex () const override
 
Long64_t size () const
 
bool to (edm::EventID id)
 Go to event with event id "id". More...
 
bool to (edm::RunNumber_t run, edm::EventNumber_t event)
 Go to event with given run and event number. More...
 
bool to (edm::RunNumber_t run, edm::LuminosityBlockNumber_t lumi, edm::EventNumber_t event)
 Go to event with given run , lumi (if non-zero), and event number. More...
 
bool to (Long64_t iIndex)
 Go to the event at index iIndex. More...
 
const MultiChainEventtoBegin () override
 
edm::TriggerNames const & triggerNames (edm::TriggerResults const &triggerResults) const override
 
edm::TriggerResultsByName triggerResultsByName (edm::TriggerResults const &triggerResults) const override
 
 ~MultiChainEvent () override
 
- Public Member Functions inherited from fwlite::EventBase
 EventBase ()
 
 ~EventBase () override
 
- Public Member Functions inherited from edm::EventBase
int bunchCrossing () const
 
 EventBase ()
 
edm::EventAuxiliary::ExperimentType experimentType () const
 
template<typename T >
bool get (ProductID const &, Handle< T > &) const
 
template<>
bool getByLabel (edm::InputTag const &tag, Handle< FWGenericObject > &result) const
 Specialize the getByLabel method to work with a Handle<FWGenericObject> More...
 
template<typename T >
bool getByLabel (InputTag const &, Handle< T > &) const
 
edm::EventID id () const
 
bool isRealData () const
 
edm::LuminosityBlockNumber_t luminosityBlock () const
 
int orbitNumber () const
 
edm::Timestamp time () const
 

Static Public Member Functions

static void throwProductNotFoundException (std::type_info const &, char const *, char const *, char const *)
 

Private Member Functions

 MultiChainEvent (Event const &)
 
const MultiChainEventoperator= (Event const &)
 
bool toSec (const edm::EventID &id)
 
bool toSec (edm::RunNumber_t run, edm::EventNumber_t event)
 Go to event with given run and event number. More...
 
bool toSec (edm::RunNumber_t run, edm::LuminosityBlockNumber_t lumi, edm::EventNumber_t event)
 Go to event with given run, lumi, and event number. More...
 
bool toSec (Long64_t iIndex)
 Go to the event from secondary files at index iIndex. More...
 

Private Attributes

std::shared_ptr< ChainEventevent1_
 
std::shared_ptr< ChainEventevent2_
 
std::shared_ptr< internal::MultiProductGetter const > getter_
 
sec_file_range_index_map secFileMapSorted_
 
bool useSecFileMapSorted_
 

Additional Inherited Members

- Static Protected Member Functions inherited from edm::EventBase
static edm::ParameterSet const * parameterSetForID_ (edm::ParameterSetID const &psID)
 
static TriggerNames const * triggerNames_ (edm::TriggerResults const &triggerResults)
 

Detailed Description

Definition at line 50 of file MultiChainEvent.h.

Member Typedef Documentation

◆ event_id_range

Definition at line 53 of file MultiChainEvent.h.

◆ sec_file_index_map

Definition at line 52 of file MultiChainEvent.h.

◆ sec_file_range_index_map

Definition at line 54 of file MultiChainEvent.h.

Constructor & Destructor Documentation

◆ MultiChainEvent() [1/2]

MultiChainEvent::MultiChainEvent ( std::vector< std::string > const &  iFileNames1,
std::vector< std::string > const &  iFileNames2,
bool  useSecFileMapSorted = false 
)

Definition at line 64 of file MultiChainEvent.cc.

66  {
67  event1_ = std::make_shared<ChainEvent>(iFileNames1);
68  event2_ = std::make_shared<ChainEvent>(iFileNames2);
69 
70  getter_ = std::make_shared<internal::MultiProductGetter>(this);
71 
72  if (event1_->size() == 0) {
73  std::cout << "------------------------------------------------------------------------" << std::endl;
74  std::cout << "WARNING! MultiChainEvent: all primary files have zero events." << std::endl;
75  std::cout << "Trying to access the events may lead to a crash. " << std::endl;
76  std::cout << "------------------------------------------------------------------------" << std::endl;
77  } else {
78  event1_->setGetter(getter_);
79  event2_->setGetter(getter_);
80  }
81 
82  useSecFileMapSorted_ = useSecFileMapSorted;
83 
84  if (!useSecFileMapSorted_) {
85  std::cout << "------------------------------------------------------------------------" << std::endl;
86  std::cout << "WARNING! What you are about to do may be very slow." << std::endl;
87  std::cout << "The 2-file solution in FWLite works with very simple assumptions." << std::endl;
88  std::cout << "It will linearly search through the files in the secondary file list for Products." << std::endl;
89  std::cout << "There are speed improvements available to make this run faster." << std::endl;
90  std::cout << "***If your secondary files are sorted with a run-range within a file, (almost always the case) "
91  << std::endl;
92  std::cout << "***please use the option useSecFileMapSorted=true in this constructor. " << std::endl;
93  std::cout << " > usage: MultiChainEvent(primaryFiles, secondaryFiles, true);" << std::endl;
94  std::cout << "------------------------------------------------------------------------" << std::endl;
95  }
96 
98  std::cout << "------------------------------------------------------------------------" << std::endl;
99  std::cout << "This MultiChainEvent is now creating a (run_range)_2 ---> file_index_2 map" << std::endl;
100  std::cout << "for the 2-file solution. " << std::endl;
101  std::cout
102  << "This is assuming the files you are giving me are sorted by run,event pairs within each secondary file."
103  << std::endl;
104  std::cout << "If this is not true (rarely the case), set this option to false." << std::endl;
105  std::cout << " > usage: MultiChainEvent(primaryFiles, secondaryFiles, false);" << std::endl;
106  std::cout << "------------------------------------------------------------------------" << std::endl;
107  // speed up secondary file access with a (run,event)_1 ---> index_2 map
108 
109  // Loop over events, when a new file is encountered, store the first run number from this file,
110  // and the last run number from the last file.
111  TFile* lastFile = nullptr;
112  std::pair<event_id_range, Long64_t> eventRange;
113  bool firstFile = true;
114 
115  bool foundAny = false;
116 
117  for (event2_->toBegin(); !event2_->atEnd(); ++(*event2_)) {
118  // if we have a new file, cache the "first"
119  if (lastFile != event2_->getTFile()) {
120  // if this is not the first file, we have an entry.
121  // Add it to the list.
122  if (!firstFile) {
123  foundAny = true;
126  }
127  // always add the "first" event id to the cached event range
128  eventRange.first.first = event2_->event()->id();
129  lastFile = event2_->getTFile();
130  }
131  // otherwise, cache the "second" event id in the cached event range.
132  // Upon the discovery of a new file, this will be used as the
133  // "last" event id in the cached event range.
134  else {
135  eventRange.first.second = event2_->event()->id();
136  eventRange.second = event2_->eventIndex();
137  }
138  firstFile = false;
139  }
140  // due to the invailability of a "look ahead" operation, we have one additional "put" to make
141  // after the loop (which puts the "last" event, not "this" event.
142  if (foundAny) {
145  }
146  // std::cout << "Dumping run range to event id list:" << std::endl;
147  // for (sec_file_range_index_map::const_iterator mBegin = secFileMapSorted_.begin(),
148  // mEnd = secFileMapSorted_.end(),
149  // mit = mBegin;
150  // mit != mEnd; ++mit) {
151  // char buff[1000];
152  // event2_->to(mit->second);
153  // sprintf(buff, "[%10d,%10d - %10d,%10d] ---> %10d",
154  // mit->first.first.run(),
155  // mit->first.first.event(),
156  // mit->first.second.run(),
157  // mit->first.second.event(),
158  // mit->second);
159  // std::cout << buff << std::endl;
160  // }
161  }
162  }

References gather_cfg::cout, event1_, event2_, unittestinputsource_cfi::eventRange, getter_, secFileMapSorted_, HLT_2018_cff::toAdd, and useSecFileMapSorted_.

◆ ~MultiChainEvent()

MultiChainEvent::~MultiChainEvent ( )
override

Definition at line 169 of file MultiChainEvent.cc.

169 {}

◆ MultiChainEvent() [2/2]

fwlite::MultiChainEvent::MultiChainEvent ( Event const &  )
private

Member Function Documentation

◆ atEnd()

bool MultiChainEvent::atEnd ( ) const
overridevirtual

Implements fwlite::EventBase.

Definition at line 348 of file MultiChainEvent.cc.

348 { return event1_->atEnd(); }

References event1_.

◆ eventAuxiliary()

edm::EventAuxiliary const & MultiChainEvent::eventAuxiliary ( ) const
overridevirtual

Implements edm::EventBase.

Definition at line 294 of file MultiChainEvent.cc.

294 { return event1_->eventAuxiliary(); }

References event1_.

◆ eventIndex()

Long64_t fwlite::MultiChainEvent::eventIndex ( ) const
inline

Definition at line 98 of file MultiChainEvent.h.

98 { return event1_->eventIndex(); }

References event1_.

◆ eventIndexSec()

Long64_t fwlite::MultiChainEvent::eventIndexSec ( ) const
inline

Definition at line 99 of file MultiChainEvent.h.

99 { return event2_->eventIndex(); }

References event2_.

◆ fileIndex()

Long64_t fwlite::MultiChainEvent::fileIndex ( ) const
inlineoverridevirtual

Reimplemented from fwlite::EventBase.

Definition at line 105 of file MultiChainEvent.h.

105 { return event1_->eventIndex(); }

References event1_.

Referenced by python.Events::fileIndicies().

◆ getBranchDescriptions()

std::vector< edm::BranchDescription > const & MultiChainEvent::getBranchDescriptions ( ) const

Definition at line 286 of file MultiChainEvent.cc.

286  {
287  return event1_->getBranchDescriptions();
288  }

References event1_.

◆ getBranchNameFor()

const std::string MultiChainEvent::getBranchNameFor ( std::type_info const &  iType,
char const *  iModule,
char const *  iInstance,
char const *  iProcess 
) const
overridevirtual

Implements fwlite::EventBase.

Definition at line 279 of file MultiChainEvent.cc.

282  {
283  return event1_->getBranchNameFor(iType, iModule, iInstance, iProcess);
284  }

References event1_.

◆ getByLabel()

bool MultiChainEvent::getByLabel ( std::type_info const &  iType,
char const *  iModule,
char const *  iInstance,
char const *  iProcess,
void *  iValue 
) const
overridevirtual

This function should only be called by fwlite::Handle<>

Implements fwlite::EventBase.

Definition at line 296 of file MultiChainEvent.cc.

300  {
301  bool ret1 = event1_->getByLabel(iType, iModule, iInstance, iProcess, iValue);
302  if (!ret1) {
303  (const_cast<MultiChainEvent*>(this))->toSec(event1_->id());
304  bool ret2 = event2_->getByLabel(iType, iModule, iInstance, iProcess, iValue);
305  if (!ret2)
306  return false;
307  }
308  return true;
309  }

References event1_, event2_, and toSec().

◆ getByProductID()

edm::WrapperBase const * MultiChainEvent::getByProductID ( edm::ProductID const &  iID) const
overridevirtual

Implements fwlite::EventBase.

Definition at line 311 of file MultiChainEvent.cc.

311  {
312  // First try the first file
313  edm::WrapperBase const* edp = event1_->getByProductID(iID);
314  // Did not find the product, try secondary file
315  if (edp == nullptr) {
316  (const_cast<MultiChainEvent*>(this))->toSec(event1_->id());
317  edp = event2_->getByProductID(iID);
318  }
319  return edp;
320  }

References event1_, event2_, and toSec().

Referenced by fwlite::internal::MultiProductGetter::getIt().

◆ getLuminosityBlock()

fwlite::LuminosityBlock const& fwlite::MultiChainEvent::getLuminosityBlock ( )
inline

Definition at line 101 of file MultiChainEvent.h.

101 { return event1_->getLuminosityBlock(); }

References event1_.

◆ getProcessHistory()

std::vector< std::string > const & MultiChainEvent::getProcessHistory ( ) const

Definition at line 290 of file MultiChainEvent.cc.

290 { return event1_->getProcessHistory(); }

References event1_.

◆ getRun()

fwlite::Run const& fwlite::MultiChainEvent::getRun ( )
inline

Definition at line 103 of file MultiChainEvent.h.

103 { return event1_->getRun(); }

References event1_.

◆ getTFile()

TFile* fwlite::MultiChainEvent::getTFile ( ) const
inline

Definition at line 95 of file MultiChainEvent.h.

95 { return event1_->getTFile(); }

References event1_.

◆ getTFileSec()

TFile* fwlite::MultiChainEvent::getTFileSec ( ) const
inline

Definition at line 96 of file MultiChainEvent.h.

96 { return event2_->getTFile(); }

References event2_.

◆ getThinnedProduct()

edm::WrapperBase const * MultiChainEvent::getThinnedProduct ( edm::ProductID const &  pid,
unsigned int &  key 
) const

Definition at line 322 of file MultiChainEvent.cc.

322  {
323  // First try the first file
324  edm::WrapperBase const* edp = event1_->getThinnedProduct(pid, key);
325  // Did not find the product, try secondary file
326  if (edp == nullptr) {
327  (const_cast<MultiChainEvent*>(this))->toSec(event1_->id());
328  edp = event2_->getThinnedProduct(pid, key);
329  }
330  return edp;
331  }

References event1_, event2_, crabWrapper::key, and toSec().

Referenced by fwlite::internal::MultiProductGetter::getThinnedProduct().

◆ getThinnedProducts()

void MultiChainEvent::getThinnedProducts ( edm::ProductID const &  pid,
std::vector< edm::WrapperBase const * > &  foundContainers,
std::vector< unsigned int > &  keys 
) const

Definition at line 333 of file MultiChainEvent.cc.

335  {
336  // First try the first file
337  event1_->getThinnedProducts(pid, wrappers, keys);
338  // Did not find all the products, try secondary file
339  if (std::find(wrappers.begin(), wrappers.end(), nullptr) != wrappers.end()) {
340  (const_cast<MultiChainEvent*>(this))->toSec(event1_->id());
341  event2_->getThinnedProducts(pid, wrappers, keys);
342  }
343  }

References event1_, event2_, spr::find(), relativeConstraints::keys, and toSec().

Referenced by fwlite::internal::MultiProductGetter::getThinnedProducts().

◆ isValid()

bool MultiChainEvent::isValid ( void  ) const

Definition at line 345 of file MultiChainEvent.cc.

345 { return event1_->isValid(); }

References event1_.

Referenced by ntupleDataFormat._Object::_checkIsValid(), and core.AutoHandle.AutoHandle::ReallyLoad().

◆ operator bool()

MultiChainEvent::operator bool ( ) const

Definition at line 346 of file MultiChainEvent.cc.

346 { return *event1_; }

◆ operator++()

const MultiChainEvent & MultiChainEvent::operator++ ( )
overridevirtual

Implements fwlite::EventBase.

Definition at line 187 of file MultiChainEvent.cc.

187  {
188  event1_->operator++();
189  return *this;
190  }

References event1_.

◆ operator=()

const MultiChainEvent& fwlite::MultiChainEvent::operator= ( Event const &  )
private

◆ parameterSet()

edm::ParameterSet const * MultiChainEvent::parameterSet ( edm::ParameterSetID const &  psID) const
overridevirtual

Implements edm::EventBase.

Definition at line 391 of file MultiChainEvent.cc.

391  {
392  auto pset = event1_->parameterSet(psID);
393  if (nullptr == pset) {
394  pset = event2_->parameterSet(psID);
395  }
396  return pset;
397  }

References event1_, event2_, and muonDTDigis_cfi::pset.

◆ primary()

ChainEvent const* fwlite::MultiChainEvent::primary ( ) const
inline

Definition at line 117 of file MultiChainEvent.h.

117 { return &*event1_; }

References event1_.

◆ processHistory()

edm::ProcessHistory const & MultiChainEvent::processHistory ( ) const
overridevirtual

Implements edm::EventBase.

Definition at line 292 of file MultiChainEvent.cc.

292 { return event1_->processHistory(); }

References event1_.

◆ secondary()

ChainEvent const* fwlite::MultiChainEvent::secondary ( ) const
inline

Definition at line 118 of file MultiChainEvent.h.

118 { return &*event2_; }

References event2_.

◆ secondaryFileIndex()

Long64_t fwlite::MultiChainEvent::secondaryFileIndex ( ) const
inlineoverridevirtual

Reimplemented from fwlite::EventBase.

Definition at line 106 of file MultiChainEvent.h.

106 { return event2_->eventIndex(); }

References event2_.

Referenced by python.Events::fileIndicies().

◆ size()

Long64_t MultiChainEvent::size ( void  ) const

Definition at line 350 of file MultiChainEvent.cc.

350 { return event1_->size(); }

References event1_.

Referenced by ntupleDataFormat._Collection::__iter__(), and ntupleDataFormat._Collection::__len__().

◆ throwProductNotFoundException()

void MultiChainEvent::throwProductNotFoundException ( std::type_info const &  iType,
char const *  iModule,
char const *  iInstance,
char const *  iProcess 
)
static

Definition at line 401 of file MultiChainEvent.cc.

404  {
405  ChainEvent::throwProductNotFoundException(iType, iModule, iInstance, iProcess);
406  }

References fwlite::ChainEvent::throwProductNotFoundException().

◆ to() [1/4]

bool MultiChainEvent::to ( edm::EventID  id)

Go to event with event id "id".

Definition at line 196 of file MultiChainEvent.cc.

196 { return to(id.run(), id.luminosityBlock(), id.event()); }

References event(), edm::EventBase::luminosityBlock(), writedatasetfile::run, and to().

◆ to() [2/4]

bool MultiChainEvent::to ( edm::RunNumber_t  run,
edm::EventNumber_t  event 
)

Go to event with given run and event number.

Definition at line 204 of file MultiChainEvent.cc.

204 { return to(run, 0U, event); }

References writedatasetfile::run, to(), and mitigatedMETSequence_cff::U.

◆ to() [3/4]

bool MultiChainEvent::to ( edm::RunNumber_t  run,
edm::LuminosityBlockNumber_t  lumi,
edm::EventNumber_t  event 
)

Go to event with given run , lumi (if non-zero), and event number.

Definition at line 199 of file MultiChainEvent.cc.

199  {
200  return event1_->to(run, lumi, event);
201  }

References event1_, and writedatasetfile::run.

◆ to() [4/4]

bool MultiChainEvent::to ( Long64_t  iIndex)

Go to the event at index iIndex.

Definition at line 193 of file MultiChainEvent.cc.

193 { return event1_->to(iIndex); }

References event1_.

Referenced by to().

◆ toBegin()

const MultiChainEvent & MultiChainEvent::toBegin ( )
overridevirtual

Implements fwlite::EventBase.

Definition at line 271 of file MultiChainEvent.cc.

271  {
272  event1_->toBegin();
273  return *this;
274  }

References event1_.

◆ toSec() [1/4]

bool MultiChainEvent::toSec ( const edm::EventID id)
private

Definition at line 210 of file MultiChainEvent.cc.

210  {
211  // First try this file.
212  if (event2_->event_->to(id)) {
213  // Found it, return.
214  return true;
215  }
216  // Second, assume that the secondary files are each in run/event
217  // order. So, let's loop over all files and see if we can figure
218  // out where the event ought to be.
219  for (sec_file_range_index_map::const_iterator mBegin = secFileMapSorted_.begin(),
220  mEnd = secFileMapSorted_.end(),
221  mit = mBegin;
222  mit != mEnd;
223  ++mit) {
224  if (id < mit->first.first || id > mit->first.second) {
225  // We don't expect this event to be in this file, so don't
226  // bother checking it right now.
227  continue;
228  }
229  // If we're here, then we have a reasonable belief that this
230  // event is in this secondary file. This part is
231  // expensive. switchToFile does memory allocations and opens the
232  // files which becomes very time consuming. This should be done
233  // as infrequently as possible.
234  event2_->switchToFile(mit->second);
235  // Is it here?
236  if (event2_->to(id)) {
237  // Yes!
238  return true;
239  }
240  // if we assumed that the secondary files were not each in
241  // order, but were non-overlapping, we could break here. But at
242  // this point, we might as well keep going.
243  } // for loop over files
244 
245  // if we are still here, then we did not find the id in question,
246  // do it the old fashioned way. This will open up each secondary
247  // file and explicitly check to see if the event is there.
248  if (event2_->to(id)) {
249  return true;
250  }
251  // if we're still here, then there really is no matching event in
252  // the secondary files. Throw.
253  throw cms::Exception("ProductNotFound")
254  << "Cannot find id " << id.run() << ", " << id.event() << " in secondary list. Exiting." << std::endl;
255  // to make the compiler happy
256  return false;
257  }

References event2_, Exception, dqmdumpme::first, and secFileMapSorted_.

◆ toSec() [2/4]

bool MultiChainEvent::toSec ( edm::RunNumber_t  run,
edm::EventNumber_t  event 
)
private

Go to event with given run and event number.

Definition at line 266 of file MultiChainEvent.cc.

266  {
267  return toSec(edm::EventID(run, 0U, event));
268  }

References writedatasetfile::run, toSec(), and mitigatedMETSequence_cff::U.

◆ toSec() [3/4]

bool MultiChainEvent::toSec ( edm::RunNumber_t  run,
edm::LuminosityBlockNumber_t  lumi,
edm::EventNumber_t  event 
)
private

Go to event with given run, lumi, and event number.

Definition at line 260 of file MultiChainEvent.cc.

260  {
261  return toSec(edm::EventID(run, lumi, event));
262  }

References writedatasetfile::run, and toSec().

◆ toSec() [4/4]

bool MultiChainEvent::toSec ( Long64_t  iIndex)
private

Go to the event from secondary files at index iIndex.

Go to the event at index iIndex.

Definition at line 207 of file MultiChainEvent.cc.

207 { return event2_->to(iIndex); }

References event2_.

Referenced by getByLabel(), getByProductID(), getThinnedProduct(), getThinnedProducts(), and toSec().

◆ triggerNames()

edm::TriggerNames const & MultiChainEvent::triggerNames ( edm::TriggerResults const &  triggerResults) const
overridevirtual

Implements edm::EventBase.

Definition at line 352 of file MultiChainEvent.cc.

352  {
354  if (names != nullptr)
355  return *names;
356 
357  event1_->fillParameterSetRegistry();
359  if (names != nullptr)
360  return *names;
361 
362  // If we cannot find it in the primary file, this probably will
363  // not help but try anyway
364  event2_->to(event1_->id());
365  event2_->fillParameterSetRegistry();
367  if (names != nullptr)
368  return *names;
369 
370  throw cms::Exception("TriggerNamesNotFound") << "TriggerNames not found in ParameterSet registry";
371  return *names;
372  }

References event1_, event2_, Exception, names, edm::EventBase::triggerNames_(), and triggerResults.

◆ triggerResultsByName()

edm::TriggerResultsByName MultiChainEvent::triggerResultsByName ( edm::TriggerResults const &  triggerResults) const
overridevirtual

Implements edm::EventBase.

Definition at line 374 of file MultiChainEvent.cc.

374  {
376 
377  if (names == nullptr) {
378  event1_->fillParameterSetRegistry();
380  }
381 
382  if (names == nullptr) {
383  event2_->to(event1_->id());
384  event2_->fillParameterSetRegistry();
386  }
387 
389  }

References event1_, event2_, names, edm::EventBase::triggerNames_(), and triggerResults.

Member Data Documentation

◆ event1_

std::shared_ptr<ChainEvent> fwlite::MultiChainEvent::event1_
private

◆ event2_

std::shared_ptr<ChainEvent> fwlite::MultiChainEvent::event2_
private

◆ getter_

std::shared_ptr<internal::MultiProductGetter const> fwlite::MultiChainEvent::getter_
private

Definition at line 147 of file MultiChainEvent.h.

Referenced by MultiChainEvent().

◆ secFileMapSorted_

sec_file_range_index_map fwlite::MultiChainEvent::secFileMapSorted_
private

Definition at line 154 of file MultiChainEvent.h.

Referenced by MultiChainEvent(), and toSec().

◆ useSecFileMapSorted_

bool fwlite::MultiChainEvent::useSecFileMapSorted_
private

Definition at line 153 of file MultiChainEvent.h.

Referenced by MultiChainEvent().

gather_cfg.cout
cout
Definition: gather_cfg.py:144
fwlite::MultiChainEvent::event1_
std::shared_ptr< ChainEvent > event1_
Definition: MultiChainEvent.h:145
triggerResults
static const std::string triggerResults
Definition: EdmProvDump.cc:45
fwlite::ChainEvent::throwProductNotFoundException
static void throwProductNotFoundException(std::type_info const &, char const *, char const *, char const *)
Definition: ChainEvent.cc:262
relativeConstraints.keys
keys
Definition: relativeConstraints.py:89
spr::find
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
Definition: FindCaloHit.cc:19
dqmdumpme.first
first
Definition: dqmdumpme.py:55
fwlite::MultiChainEvent::useSecFileMapSorted_
bool useSecFileMapSorted_
Definition: MultiChainEvent.h:153
names
const std::string names[nVars_]
Definition: PhotonIDValueMapProducer.cc:122
mitigatedMETSequence_cff.U
U
Definition: mitigatedMETSequence_cff.py:36
fwlite::MultiChainEvent::getter_
std::shared_ptr< internal::MultiProductGetter const > getter_
Definition: MultiChainEvent.h:147
edm::EventBase::luminosityBlock
edm::LuminosityBlockNumber_t luminosityBlock() const
Definition: EventBase.h:61
fwlite::MultiChainEvent::to
bool to(Long64_t iIndex)
Go to the event at index iIndex.
Definition: MultiChainEvent.cc:193
edm::TriggerResultsByName
Definition: TriggerResultsByName.h:48
edm::WrapperBase
Definition: WrapperBase.h:23
writedatasetfile.run
run
Definition: writedatasetfile.py:27
fwlite::MultiChainEvent::toSec
bool toSec(Long64_t iIndex)
Go to the event from secondary files at index iIndex.
Definition: MultiChainEvent.cc:207
Exception
Definition: hltDiff.cc:246
edm::TriggerNames
Definition: TriggerNames.h:55
fwlite::MultiChainEvent::event2_
std::shared_ptr< ChainEvent > event2_
Definition: MultiChainEvent.h:146
unittestinputsource_cfi.eventRange
eventRange
Definition: unittestinputsource_cfi.py:108
edm::EventBase::triggerNames_
static TriggerNames const * triggerNames_(edm::TriggerResults const &triggerResults)
Definition: EventBase.cc:45
fwlite::MultiChainEvent::secFileMapSorted_
sec_file_range_index_map secFileMapSorted_
Definition: MultiChainEvent.h:154
HLT_2018_cff.toAdd
toAdd
Definition: HLT_2018_cff.py:50595
fwlite::MultiChainEvent::event_id_range
std::pair< edm::EventID, edm::EventID > event_id_range
Definition: MultiChainEvent.h:53
event
Definition: event.py:1
edm::EventID
Definition: EventID.h:31
crabWrapper.key
key
Definition: crabWrapper.py:19
lumi
Definition: LumiSectionData.h:20
event
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision and the trigger will pass if any such matching triggers are FAIL or EXCEPTION A wildcarded negative criterion that matches more than one trigger in the trigger but the state exists so we define the behavior If all triggers are the negative crieriion will lead to accepting the event(this again matches the behavior of "!*" before the partial wildcard feature was incorporated). The per-event "cost" of each negative criterion with multiple relevant triggers is about the same as ! *was in the past
muonDTDigis_cfi.pset
pset
Definition: muonDTDigis_cfi.py:27