CMS 3D CMS Logo

EventPrincipal.cc
Go to the documentation of this file.
2 
23 
24 #include <algorithm>
25 #include <cassert>
26 #include <limits>
27 #include <memory>
28 
29 namespace edm {
30  EventPrincipal::EventPrincipal(std::shared_ptr<ProductRegistry const> reg,
31  std::shared_ptr<BranchIDListHelper const> branchIDListHelper,
32  std::shared_ptr<ThinnedAssociationsHelper const> thinnedAssociationsHelper,
33  ProcessConfiguration const& pc,
34  HistoryAppender* historyAppender,
35  unsigned int streamIndex,
36  bool isForPrimaryProcess)
37  : Base(reg, reg->productLookup(InEvent), pc, InEvent, historyAppender, isForPrimaryProcess),
38  aux_(),
39  luminosityBlockPrincipal_(nullptr),
40  provRetrieverPtr_(new ProductProvenanceRetriever(streamIndex, *reg)),
41  eventSelectionIDs_(),
42  branchIDListHelper_(branchIDListHelper),
43  thinnedAssociationsHelper_(thinnedAssociationsHelper),
44  branchListIndexes_(),
45  branchListIndexToProcessIndex_(),
46  streamID_(streamIndex) {
48 
49  for (auto& prod : *this) {
50  if (prod->singleProduct()) {
51  prod->setProductProvenanceRetriever(productProvenanceRetrieverPtr());
52  }
53  }
54  }
55 
58  aux_ = EventAuxiliary();
59  //do not clear luminosityBlockPrincipal_ since
60  // it is only connected at beginLumi transition
61  provRetrieverPtr_->reset();
62  }
63 
65  ProcessHistory const* processHistory,
66  EventSelectionIDVector eventSelectionIDs,
67  BranchListIndexes branchListIndexes,
68  ProductProvenanceRetriever const& provRetriever,
70  bool deepCopyRetriever) {
72  if (deepCopyRetriever) {
73  provRetrieverPtr_->deepCopy(provRetriever);
74  } else {
75  provRetrieverPtr_->mergeParentProcessRetriever(provRetriever);
76  }
78  if (branchIDListHelper_->hasProducedProducts()) {
79  // Add index into BranchIDListRegistry for products produced this process
80  branchListIndexes.push_back(branchIDListHelper_->producedBranchListIndex());
81  }
83  }
85  }
86 
88  ProcessHistory const* processHistory,
89  EventSelectionIDVector eventSelectionIDs,
90  BranchListIndexes branchListIndexes) {
92 
94  if (branchIDListHelper_->hasProducedProducts()) {
95  // Add index into BranchIDListRegistry for products produced this process
96  branchListIndexes.push_back(branchIDListHelper_->producedBranchListIndex());
97  }
99  }
101  }
102 
104  ProcessHistory const* processHistory,
106  if (branchListIndexes_.empty() and branchIDListHelper_->hasProducedProducts()) {
107  // Add index into BranchIDListRegistry for products produced this process
108  // if it hasn't already been filled in by the other fillEventPrincipal or by an earlier call to this function
109  BranchListIndexes indexes;
110  indexes.push_back(branchIDListHelper_->producedBranchListIndex());
112  }
114  }
115 
117  ProcessHistory const* processHistory,
119  if (aux.event() == invalidEventNumber) {
120  throw Exception(errors::LogicError) << "EventPrincipal::fillEventPrincipal, Invalid event number provided in "
121  "EventAuxiliary, It is illegal for the event number to be 0\n";
122  }
123 
125  aux_ = aux;
127  }
128 
130  //fromInput does not contain entries for what is being produced in this job.
131  auto end = branchListIndexes_.end();
132  if (end != branchListIndexes_.begin() and branchIDListHelper_->hasProducedProducts()) {
133  --end;
134  }
135 
136  return not std::equal(fromInput.begin(), fromInput.end(), branchListIndexes_.begin(), end);
137  }
138 
142  // Fill in helper map for Branch to ProductID mapping
143  if (not branchListIndexes_.empty()) {
144  ProcessIndex pix = 0;
145  branchListIndexToProcessIndex_.resize(1 + *std::max_element(branchListIndexes_.begin(), branchListIndexes_.end()),
147  for (auto const& blindex : branchListIndexes_) {
148  branchListIndexToProcessIndex_[blindex] = pix;
149  ++pix;
150  }
151  }
152 
153  // Fill in the product ID's in the product holders.
154  for (auto& prod : *this) {
155  if (prod->singleProduct()) {
156  // If an alias is in the same process as the original then isAlias will be true.
157  // Under that condition, we want the ProductID to be the same as the original.
158  // If not, then we've internally changed the original BranchID to the alias BranchID
159  // in the ProductID lookup so we need the alias BranchID.
160 
161  auto const& bd = prod->branchDescription();
162  prod->setProductID(branchIDToProductID(bd.isAlias() ? bd.originalBranchID() : bd.branchID()));
163  }
164  }
165  }
166 
168 
171  assert(lumi == luminosityBlockPrincipal_->luminosityBlock());
172  EventNumber_t event = aux_.id().event();
173  aux_.id() = EventID(run, lumi, event);
174  }
175 
177 
179  std::unique_ptr<WrapperBase> edp,
180  ProductProvenance const& productProvenance) const {
181  // assert commented out for DaqSource. When DaqSource no longer uses put(), the assert can be restored.
182  //assert(produced());
183  if (edp.get() == nullptr) {
184  throw Exception(errors::InsertFailure, "Null Pointer") << "put: Cannot put because ptr to product is null."
185  << "\n";
186  }
187  productProvenanceRetrieverPtr()->insertIntoSet(productProvenance);
188  auto phb = getExistingProduct(bd.branchID());
189  assert(phb);
190  // ProductResolver assumes ownership
191  phb->putProduct(std::move(edp));
192  }
193 
194  void EventPrincipal::put(ProductResolverIndex index, std::unique_ptr<WrapperBase> edp, ParentageID parentage) const {
195  if (edp.get() == nullptr) {
196  throw Exception(errors::InsertFailure, "Null Pointer") << "put: Cannot put because ptr to product is null."
197  << "\n";
198  }
199  auto phb = getProductResolverByIndex(index);
200 
202  ProductProvenance(phb->branchDescription().branchID(), std::move(parentage)));
203 
204  assert(phb);
205  // ProductResolver assumes ownership
206  phb->putProduct(std::move(edp));
207  }
208 
210  std::unique_ptr<WrapperBase> edp,
211  std::optional<ProductProvenance> productProvenance) const {
212  assert(!bd.produced());
213  if (productProvenance) {
214  productProvenanceRetrieverPtr()->insertIntoSet(std::move(*productProvenance));
215  }
216  auto phb = getExistingProduct(bd.branchID());
217  assert(phb);
218  // ProductResolver assumes ownership
219  phb->putProduct(std::move(edp));
220  }
221 
223  if (!pid.isValid()) {
224  throw Exception(errors::ProductNotFound, "InvalidID") << "get by product ID: invalid ProductID supplied\n";
225  }
226  return productIDToBranchID(pid, branchIDListHelper_->branchIDLists(), branchListIndexes_);
227  }
228 
230  if (!bid.isValid()) {
231  throw Exception(errors::NotFound, "InvalidID") << "branchIDToProductID: invalid BranchID supplied\n";
232  }
233  typedef BranchIDListHelper::BranchIDToIndexMap BIDToIndexMap;
234  typedef BIDToIndexMap::const_iterator Iter;
235  typedef std::pair<Iter, Iter> IndexRange;
236 
237  IndexRange range = branchIDListHelper_->branchIDToIndexMap().equal_range(bid);
238  for (Iter it = range.first; it != range.second; ++it) {
239  BranchListIndex blix = it->second.first;
240  if (blix < branchListIndexToProcessIndex_.size()) {
241  auto v = branchListIndexToProcessIndex_[blix];
243  ProductIndex productIndex = it->second.second;
244  ProcessIndex processIndex = v;
245  return ProductID(processIndex + 1, productIndex + 1);
246  }
247  }
248  }
249  // cannot throw, because some products may legitimately not have product ID's (e.g. pile-up).
250  return ProductID();
251  }
252 
253  unsigned int EventPrincipal::transitionIndex_() const { return streamID_.value(); }
254 
256 
257  static void throwProductDeletedException(ProductID const& pid,
260  exception << "get by product ID: The product with given id: " << pid << "\ntype: " << phb->productType()
261  << "\nproduct instance name: " << phb->productInstanceName() << "\nprocess name: " << phb->processName()
262  << "\nwas already deleted. This is a configuration error. Please change the configuration of the module "
263  "which caused this exception to state it reads this data.";
264  throw exception;
265  }
266 
268  BranchID bid = pidToBid(pid);
270  if (phb == nullptr) {
271  return BasicHandle(makeHandleExceptionFactory([pid]() -> std::shared_ptr<cms::Exception> {
272  std::shared_ptr<cms::Exception> whyFailed(std::make_shared<Exception>(errors::ProductNotFound, "InvalidID"));
273  *whyFailed << "get by product ID: no product with given id: " << pid << "\n";
274  return whyFailed;
275  }));
276  }
277 
278  // Was this already deleted?
279  if (phb->productWasDeleted()) {
281  }
282  // Check for case where we tried on demand production and
283  // it failed to produce the object
284  if (phb->unscheduledWasNotRun()) {
285  return BasicHandle(makeHandleExceptionFactory([pid]() -> std::shared_ptr<cms::Exception> {
286  std::shared_ptr<cms::Exception> whyFailed(std::make_shared<Exception>(errors::ProductNotFound, "InvalidID"));
287  *whyFailed << "get by ProductID: could not get product with id: " << pid << "\n"
288  << "Unscheduled execution not allowed to get via ProductID.\n";
289  return whyFailed;
290  }));
291  }
292  auto resolution = phb->resolveProduct(*this, false, nullptr, nullptr);
293 
294  auto data = resolution.data();
295  if (data) {
296  return BasicHandle(data->wrapper(), &(data->provenance()));
297  }
298  return BasicHandle(nullptr, nullptr);
299  }
300 
301  WrapperBase const* EventPrincipal::getIt(ProductID const& pid) const { return getByProductID(pid).wrapper(); }
302 
303  WrapperBase const* EventPrincipal::getThinnedProduct(ProductID const& pid, unsigned int& key) const {
304  BranchID parent = pidToBid(pid);
305 
306  // Loop over thinned containers which were made by selecting elements from the parent container
307  for (auto associatedBranches = thinnedAssociationsHelper_->parentBegin(parent),
308  iEnd = thinnedAssociationsHelper_->parentEnd(parent);
309  associatedBranches != iEnd;
310  ++associatedBranches) {
311  ThinnedAssociation const* thinnedAssociation = getThinnedAssociation(associatedBranches->association());
312  if (thinnedAssociation == nullptr)
313  continue;
314 
315  if (associatedBranches->parent() != pidToBid(thinnedAssociation->parentCollectionID())) {
316  continue;
317  }
318 
319  unsigned int thinnedIndex = 0;
320  // Does this thinned container have the element referenced by key?
321  // If yes, thinnedIndex is set to point to it in the thinned container
322  if (!thinnedAssociation->hasParentIndex(key, thinnedIndex)) {
323  continue;
324  }
325  // Get the thinned container and return a pointer if we can find it
326  ProductID const& thinnedCollectionPID = thinnedAssociation->thinnedCollectionID();
327  BasicHandle bhThinned = getByProductID(thinnedCollectionPID);
328  if (!bhThinned.isValid()) {
329  // Thinned container is not found, try looking recursively in thinned containers
330  // which were made by selecting elements from this thinned container.
331  WrapperBase const* wrapperBase = getThinnedProduct(thinnedCollectionPID, thinnedIndex);
332  if (wrapperBase != nullptr) {
333  key = thinnedIndex;
334  return wrapperBase;
335  } else {
336  continue;
337  }
338  }
339  key = thinnedIndex;
340  return bhThinned.wrapper();
341  }
342  return nullptr;
343  }
344 
346  std::vector<WrapperBase const*>& foundContainers,
347  std::vector<unsigned int>& keys) const {
348  BranchID parent = pidToBid(pid);
349 
350  // Loop over thinned containers which were made by selecting elements from the parent container
351  for (auto associatedBranches = thinnedAssociationsHelper_->parentBegin(parent),
352  iEnd = thinnedAssociationsHelper_->parentEnd(parent);
353  associatedBranches != iEnd;
354  ++associatedBranches) {
355  ThinnedAssociation const* thinnedAssociation = getThinnedAssociation(associatedBranches->association());
356  if (thinnedAssociation == nullptr)
357  continue;
358 
359  if (associatedBranches->parent() != pidToBid(thinnedAssociation->parentCollectionID())) {
360  continue;
361  }
362 
363  unsigned nKeys = keys.size();
364  unsigned int doNotLookForThisIndex = std::numeric_limits<unsigned int>::max();
365  std::vector<unsigned int> thinnedIndexes(nKeys, doNotLookForThisIndex);
366  bool hasAny = false;
367  for (unsigned k = 0; k < nKeys; ++k) {
368  // Already found this one
369  if (foundContainers[k] != nullptr)
370  continue;
371  // Already know this one is not in this thinned container
372  if (keys[k] == doNotLookForThisIndex)
373  continue;
374  // Does the thinned container hold the entry of interest?
375  // Modifies thinnedIndexes[k] only if it returns true and
376  // sets it to the index in the thinned collection.
377  if (thinnedAssociation->hasParentIndex(keys[k], thinnedIndexes[k])) {
378  hasAny = true;
379  }
380  }
381  if (!hasAny) {
382  continue;
383  }
384  // Get the thinned container and set the pointers and indexes into
385  // it (if we can find it)
386  ProductID thinnedCollectionPID = thinnedAssociation->thinnedCollectionID();
387  BasicHandle bhThinned = getByProductID(thinnedCollectionPID);
388  if (!bhThinned.isValid()) {
389  // Thinned container is not found, try looking recursively in thinned containers
390  // which were made by selecting elements from this thinned container.
391  getThinnedProducts(thinnedCollectionPID, foundContainers, thinnedIndexes);
392  for (unsigned k = 0; k < nKeys; ++k) {
393  if (foundContainers[k] == nullptr)
394  continue;
395  if (thinnedIndexes[k] == doNotLookForThisIndex)
396  continue;
397  keys[k] = thinnedIndexes[k];
398  }
399  } else {
400  for (unsigned k = 0; k < nKeys; ++k) {
401  if (thinnedIndexes[k] == doNotLookForThisIndex)
402  continue;
403  keys[k] = thinnedIndexes[k];
404  foundContainers[k] = bhThinned.wrapper();
405  }
406  }
407  }
408  }
409 
411  BranchID bid = pidToBid(pid);
412  return getProvenance(bid, mcc);
413  }
414 
416 
418 
420  ConstProductResolverPtr const phb = getProductResolver(branchID);
421 
422  if (phb == nullptr) {
424  << "EventPrincipal::getThinnedAssociation, ThinnedAssociation ProductResolver cannot be found\n"
425  << "This should never happen. Contact a Framework developer";
426  }
427  ProductData const* productData = (phb->resolveProduct(*this, false, nullptr, nullptr)).data();
428  if (productData == nullptr) {
429  return nullptr;
430  }
431  WrapperBase const* product = productData->wrapper();
432  if (!(typeid(edm::ThinnedAssociation) == product->dynamicTypeInfo())) {
434  << "EventPrincipal::getThinnedProduct, product has wrong type, not a ThinnedAssociation.\n";
435  }
437  return wrapper->product();
438  }
439 
440 } // namespace edm
edm::ProductDeletedException
Definition: ProductDeletedException.h:28
ThinnedAssociationsHelper.h
edm::RunNumber_t
unsigned int RunNumber_t
Definition: RunLumiEventNumber.h:14
FastTimerService_cff.range
range
Definition: FastTimerService_cff.py:34
edm::EventAuxiliary::event
EventNumber_t event() const
Definition: EventAuxiliary.h:72
edm::EventPrincipal::branchIDListHelper_
std::shared_ptr< BranchIDListHelper const > branchIDListHelper_
Definition: EventPrincipal.h:177
edm::EventPrincipal::luminosityBlockPrincipal_
edm::propagate_const< LuminosityBlockPrincipal * > luminosityBlockPrincipal_
Definition: EventPrincipal.h:170
edm::LuminosityBlockPrincipal::runPrincipal
RunPrincipal const & runPrincipal() const
Definition: LuminosityBlockPrincipal.h:45
edm::EventPrincipal::aux
EventAuxiliary const & aux() const
Definition: EventPrincipal.h:104
ModuleCallingContext.h
ProductResolverBase.h
edm::ProductResolverIndex
unsigned int ProductResolverIndex
Definition: ProductResolverIndex.h:8
edm::EventPrincipal::luminosityBlockPrincipal
LuminosityBlockPrincipal const & luminosityBlockPrincipal() const
Definition: EventPrincipal.h:81
FunctorHandleExceptionFactory.h
edm::BasicHandle
Definition: BasicHandle.h:43
edm::EventPrincipal::aux_
EventAuxiliary aux_
Definition: EventPrincipal.h:168
edm::errors::LogicError
Definition: EDMException.h:37
BranchIDListHelper.h
edm
HLT enums.
Definition: AlignableModifier.h:19
edm::ProductData::wrapper
WrapperBase const * wrapper() const
Definition: ProductData.h:35
edm::EventPrincipal::getIt
WrapperBase const * getIt(ProductID const &pid) const override
Definition: EventPrincipal.cc:301
RunLumiEventNumber.h
edm::EventPrincipal::thinnedAssociationsHelper_
std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper_
Definition: EventPrincipal.h:178
edm::EventPrincipal::getThinnedProduct
WrapperBase const * getThinnedProduct(ProductID const &pid, unsigned int &key) const override
Definition: EventPrincipal.cc:303
edm::LuminosityBlockPrincipal
Definition: LuminosityBlockPrincipal.h:31
edm::BranchListIndexes
std::vector< BranchListIndex > BranchListIndexes
Definition: BranchListIndex.h:18
edm::ThinnedAssociation
Definition: ThinnedAssociation.h:14
Algorithms.h
cms::cuda::assert
assert(be >=bs)
edm::ProcessIndex
unsigned short ProcessIndex
Definition: ProductID.h:25
edm::Principal
Definition: Principal.h:57
DelayedReader.h
edm::StreamID::value
unsigned int value() const
Definition: StreamID.h:42
relativeConstraints.keys
keys
Definition: relativeConstraints.py:89
ProductRegistry.h
wrapper
static HepMC::HEPEVT_Wrapper wrapper
Definition: BeamHaloProducer.cc:47
edm::Principal::processHistory
ProcessHistory const & processHistory() const
Definition: Principal.h:139
findQualityFiles.v
v
Definition: findQualityFiles.py:179
edm::errors::NotFound
Definition: EDMException.h:57
watchdog.const
const
Definition: watchdog.py:83
edm::LuminosityBlockNumber_t
unsigned int LuminosityBlockNumber_t
Definition: RunLumiEventNumber.h:13
edm::ProductIndex
unsigned short ProductIndex
Definition: ProductID.h:26
edm::EventPrincipal::getProvenance
Provenance getProvenance(ProductID const &pid, ModuleCallingContext const *mcc) const
Definition: EventPrincipal.cc:410
edm::Principal::getProductResolverByIndex
ConstProductResolverPtr getProductResolverByIndex(ProductResolverIndex const &oid) const
Definition: Principal.cc:535
edm::Wrapper
Definition: Product.h:10
edm::EventPrincipal::setRunAndLumiNumber
void setRunAndLumiNumber(RunNumber_t run, LuminosityBlockNumber_t lumi)
Definition: EventPrincipal.cc:169
edm::EventPrincipal::productProvenanceRetrieverPtr
ProductProvenanceRetriever const * productProvenanceRetrieverPtr() const
Definition: EventPrincipal.h:114
edm::Principal::fillPrincipal
void fillPrincipal(ProcessHistoryID const &hist, ProcessHistory const *phr, DelayedReader *reader)
Definition: Principal.cc:394
edm::makeHandleExceptionFactory
std::shared_ptr< HandleExceptionFactory > makeHandleExceptionFactory(T &&iFunctor)
Definition: FunctorHandleExceptionFactory.h:45
edm::EventPrincipal::branchListIndexes
BranchListIndexes const & branchListIndexes() const
Definition: EventPrincipal.cc:417
EDMException.h
SharedResourcesAcquirer.h
edm::errors::ProductNotFound
Definition: EDMException.h:33
edm::EventPrincipal::provRetrieverPtr_
edm::propagate_const< std::shared_ptr< ProductProvenanceRetriever > > provRetrieverPtr_
Definition: EventPrincipal.h:173
edm::ProductProvenanceRetriever::insertIntoSet
void insertIntoSet(ProductProvenance provenanceProduct) const
Definition: ProductProvenanceRetriever.cc:121
edm::EventPrincipal::changedIndexes_
void changedIndexes_() final
Definition: EventPrincipal.cc:255
edm::EventPrincipal::ConstProductResolverPtr
Base::ConstProductResolverPtr ConstProductResolverPtr
Definition: EventPrincipal.h:51
edm::ProductProvenance
Definition: ProductProvenance.h:24
edm::BasicHandle::isValid
bool isValid() const noexcept(true)
Definition: BasicHandle.h:69
edm::EventPrincipal::getThinnedAssociation
edm::ThinnedAssociation const * getThinnedAssociation(edm::BranchID const &branchID) const
Definition: EventPrincipal.cc:419
edm::Principal::processHistoryID
ProcessHistoryID const & processHistoryID() const
Definition: Principal.h:141
DQM.reader
reader
Definition: DQM.py:105
EventPrincipal.h
BranchListIndex.h
edm::invalidEventNumber
const EventNumber_t invalidEventNumber
Definition: RunLumiEventNumber.h:16
edm::BranchID
Definition: BranchID.h:14
edm::Principal::reader
DelayedReader * reader() const
Definition: Principal.h:185
Provenance.h
dumpMFGeometry_cfg.prod
prod
Definition: dumpMFGeometry_cfg.py:24
edm::EventAuxiliary::id
EventID const & id() const
Definition: EventAuxiliary.h:63
L1TObjectsTimingClient_cff.resolution
resolution
Definition: L1TObjectsTimingClient_cff.py:52
edm::errors::InsertFailure
Definition: EDMException.h:35
edm::Principal::getProductResolver
ConstProductResolverPtr getProductResolver(BranchID const &oid) const
Definition: Principal.cc:527
edm::BranchIDListHelper::BranchIDToIndexMap
std::multimap< BranchID, IndexPair > BranchIDToIndexMap
Definition: BranchIDListHelper.h:18
edm::Hash< ParentageType >
edm::BranchListIndex
unsigned short BranchListIndex
Definition: BranchListIndex.h:17
edm::EventNumber_t
unsigned long long EventNumber_t
Definition: RunLumiEventNumber.h:12
edm::InEvent
Definition: BranchType.h:11
dqmdumpme.k
k
Definition: dqmdumpme.py:60
edm::Principal::end
const_iterator end() const
Definition: Principal.h:162
edm::EventPrincipal::put
void put(BranchDescription const &bd, std::unique_ptr< WrapperBase > edp, ProductProvenance const &productProvenance) const
Definition: EventPrincipal.cc:178
edm::BasicHandle::wrapper
WrapperBase const * wrapper() const noexcept(true)
Definition: BasicHandle.h:73
edm::Principal::productRegistry
ProductRegistry const & productRegistry() const
Definition: Principal.h:145
edm::ThinnedAssociation::thinnedCollectionID
ProductID const & thinnedCollectionID() const
Definition: ThinnedAssociation.h:19
edm::EventAuxiliary
Definition: EventAuxiliary.h:14
edm::WrapperBase::dynamicTypeInfo
std::type_info const & dynamicTypeInfo() const
Definition: WrapperBase.h:42
cppFunctionSkipper.exception
exception
Definition: cppFunctionSkipper.py:10
SiStripPI::max
Definition: SiStripPayloadInspectorHelper.h:169
edm::EventPrincipal::branchListIndexToProcessIndex_
std::vector< ProcessIndex > branchListIndexToProcessIndex_
Definition: EventPrincipal.h:182
edm::EventPrincipal::setLuminosityBlockPrincipal
void setLuminosityBlockPrincipal(LuminosityBlockPrincipal *lbp)
Definition: EventPrincipal.cc:167
printConversionInfo.aux
aux
Definition: printConversionInfo.py:19
edm::EventID::event
EventNumber_t event() const
Definition: EventID.h:40
edm::EventPrincipal::commonFillEventPrincipal
void commonFillEventPrincipal(EventAuxiliary const &aux, ProcessHistory const *processHistory, DelayedReader *reader)
Definition: EventPrincipal.cc:116
edm::EventPrincipal::putOnRead
void putOnRead(BranchDescription const &bd, std::unique_ptr< WrapperBase > edp, std::optional< ProductProvenance > productProvenance) const
Definition: EventPrincipal.cc:209
edm::EventPrincipal::eventSelectionIDs
EventSelectionIDVector const & eventSelectionIDs() const
Definition: EventPrincipal.cc:415
edm::WrapperBase
Definition: WrapperBase.h:23
ProductIDToBranchID.h
edm::Principal::getExistingProduct
ProductResolverBase * getExistingProduct(BranchID const &branchID)
Definition: Principal.cc:474
edm::HistoryAppender
Definition: HistoryAppender.h:13
edm::EventPrincipal::updateBranchListIndexes
void updateBranchListIndexes(BranchListIndexes &&)
Definition: EventPrincipal.cc:139
BranchIDList.h
edm::ThinnedAssociation::hasParentIndex
bool hasParentIndex(unsigned int parentIndex, unsigned int &thinnedIndex) const
Definition: ThinnedAssociation.cc:9
edm::Principal::clearPrincipal
void clearPrincipal()
Definition: Principal.cc:373
edm::ThinnedAssociation::parentCollectionID
ProductID const & parentCollectionID() const
Definition: ThinnedAssociation.h:18
edm::BranchDescription::produced
bool produced() const
Definition: BranchDescription.h:82
LuminosityBlockPrincipal.h
edm::ProductID::isValid
bool isValid() const
Definition: ProductID.h:32
edm::EventPrincipal::eventSelectionIDs_
EventSelectionIDVector eventSelectionIDs_
Definition: EventPrincipal.h:175
edm::EventPrincipal::getByProductID
BasicHandle getByProductID(ProductID const &oid) const
Definition: EventPrincipal.cc:267
edm::EventPrincipal::fillEventPrincipal
void fillEventPrincipal(EventAuxiliary const &aux, ProcessHistory const *processHistory, DelayedReader *reader=nullptr)
Definition: EventPrincipal.cc:103
edm::EventPrincipal::getThinnedProducts
void getThinnedProducts(ProductID const &pid, std::vector< WrapperBase const * > &foundContainers, std::vector< unsigned int > &keys) const override
Definition: EventPrincipal.cc:345
edm::ProductProvenanceRetriever
Definition: ProductProvenanceRetriever.h:56
edm::throwProductDeletedException
static void throwProductDeletedException(ProductID const &pid, edm::EventPrincipal::ConstProductResolverPtr const phb)
Definition: EventPrincipal.cc:257
edm::EventPrincipal::run
RunNumber_t run() const
Definition: EventPrincipal.h:110
Wrapper.h
eostools.move
def move(src, dest)
Definition: eostools.py:511
writedatasetfile.run
run
Definition: writedatasetfile.py:27
edm::EventPrincipal::clearEventPrincipal
void clearEventPrincipal()
Definition: EventPrincipal.cc:56
edm::EventAuxiliary::processHistoryID
ProcessHistoryID const & processHistoryID() const
Definition: EventAuxiliary.h:61
edm::EventPrincipal::branchIDToProductID
ProductID branchIDToProductID(BranchID const &bid) const
Definition: EventPrincipal.cc:229
Exception
Definition: hltDiff.cc:246
edm::ProductData
Definition: ProductData.h:20
BasicHandle.h
edm::EventPrincipal::streamID_
StreamID streamID_
Definition: EventPrincipal.h:184
ProductDeletedException.h
edm::BranchID::isValid
bool isValid() const
Definition: BranchID.h:22
ThinnedAssociation.h
edm::DelayedReader
Definition: DelayedReader.h:29
data
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
AlignmentPI::index
index
Definition: AlignmentPayloadInspectorHelper.h:46
edm::productIDToBranchID
BranchID productIDToBranchID(ProductID const &pid, BranchIDLists const &lists, BranchListIndexes const &indexes)
Definition: ProductIDToBranchID.cc:11
edm::EventPrincipal::transitionIndex_
unsigned int transitionIndex_() const override
Definition: EventPrincipal.cc:253
edm::BranchDescription
Definition: BranchDescription.h:32
edm::EventPrincipal::pidToBid
BranchID pidToBid(ProductID const &pid) const
Definition: EventPrincipal.cc:222
edm::ProcessHistory
Definition: ProcessHistory.h:13
edm::RunPrincipal
Definition: RunPrincipal.h:34
edm::Provenance
Definition: Provenance.h:34
event
Definition: event.py:1
edm::EventID
Definition: EventID.h:31
edm::EventSelectionIDVector
std::vector< EventSelectionID > EventSelectionIDVector
Definition: EventSelectionID.h:16
crabWrapper.key
key
Definition: crabWrapper.py:19
cond::serialization::equal
bool equal(const T &first, const T &second)
Definition: Equal.h:32
lumi
Definition: LumiSectionData.h:20
edm::BranchDescription::branchID
BranchID const & branchID() const
Definition: BranchDescription.h:74
edm::EventPrincipal::runPrincipal
RunPrincipal const & runPrincipal() const
Definition: EventPrincipal.cc:176
class-composition.parent
parent
Definition: class-composition.py:88
edm::EventAuxiliary::setProcessHistoryID
void setProcessHistoryID(ProcessHistoryID const &phid)
Definition: EventAuxiliary.h:62
edm::ProductID
Definition: ProductID.h:27
edm::ProcessConfiguration
Definition: ProcessConfiguration.h:14
edm::EventPrincipal::branchListIndexes_
BranchListIndexes branchListIndexes_
Definition: EventPrincipal.h:180
edm::EventPrincipal::EventPrincipal
EventPrincipal(std::shared_ptr< ProductRegistry const > reg, std::shared_ptr< BranchIDListHelper const > branchIDListHelper, std::shared_ptr< ThinnedAssociationsHelper const > thinnedAssociationsHelper, ProcessConfiguration const &pc, HistoryAppender *historyAppender, unsigned int streamIndex=0, bool isForPrimaryProcess=true)
Definition: EventPrincipal.cc:30
edm::EventPrincipal::wasBranchListIndexesChangedFromInput
bool wasBranchListIndexesChangedFromInput(BranchListIndexes const &) const
Definition: EventPrincipal.cc:129
edm::ModuleCallingContext
Definition: ModuleCallingContext.h:29