|
std::unique_ptr< gen::GenStreamCache< HAD, DEC > > | beginStream (StreamID) const override |
|
| ConcurrentGeneratorFilter (ParameterSet const &ps) |
|
bool | filter (StreamID id, Event &e, EventSetup const &es) const override |
|
void | globalBeginLuminosityBlockProduce (LuminosityBlock &, EventSetup const &) const override |
|
std::shared_ptr< gen::GenLumiSummary > | globalBeginLuminosityBlockSummary (LuminosityBlock const &, EventSetup const &) const override |
|
std::shared_ptr< gen::GenRunCache > | globalBeginRun (Run const &, EventSetup const &) const override |
|
void | globalEndLuminosityBlockProduce (LuminosityBlock &, EventSetup const &, gen::GenLumiSummary const *) const override |
|
void | globalEndLuminosityBlockSummary (LuminosityBlock const &, EventSetup const &, gen::GenLumiSummary *) const override |
|
void | globalEndRun (Run const &, EventSetup const &) const override |
|
void | globalEndRunProduce (Run &, EventSetup const &) const override |
|
void | streamBeginLuminosityBlock (StreamID, LuminosityBlock const &, EventSetup const &) const override |
|
void | streamEndLuminosityBlock (StreamID, LuminosityBlock const &, EventSetup const &) const override |
|
void | streamEndLuminosityBlockSummary (StreamID, LuminosityBlock const &, EventSetup const &, gen::GenLumiSummary *) const override |
|
void | streamEndRun (StreamID, Run const &, EventSetup const &) const override |
|
| EDFilter ()=default |
|
bool | hasAbilityToProduceInLumis () const final |
|
bool | hasAbilityToProduceInRuns () const final |
|
bool | wantsGlobalLuminosityBlocks () const final |
|
bool | wantsGlobalRuns () const final |
|
bool | wantsStreamLuminosityBlocks () const final |
|
bool | wantsStreamRuns () const final |
|
| EDFilterBase () |
|
ModuleDescription const & | moduleDescription () const |
|
| ~EDFilterBase () override |
|
void | callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func) |
|
std::vector< edm::ProductResolverIndex > const & | indiciesForPutProducts (BranchType iBranchType) const |
|
| ProducerBase () |
|
std::vector< edm::ProductResolverIndex > const & | putTokenIndexToProductResolverIndex () const |
|
void | registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &) |
|
std::function< void(BranchDescription const &)> | registrationCallback () const |
| used by the fwk to register list of products More...
|
|
void | resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel) |
|
| ~ProducerBase () noexcept(false) override |
|
std::vector< ConsumesInfo > | consumesInfo () const |
|
void | convertCurrentProcessAlias (std::string const &processName) |
| Convert "@currentProcess" in InputTag process names to the actual current process name. More...
|
|
| EDConsumerBase () |
|
| EDConsumerBase (EDConsumerBase const &)=delete |
|
| EDConsumerBase (EDConsumerBase &&)=default |
|
ESProxyIndex const * | esGetTokenIndices (edm::Transition iTrans) const |
|
ProductResolverIndexAndSkipBit | indexFrom (EDGetToken, BranchType, TypeID const &) const |
|
void | itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const |
|
void | itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const |
|
std::vector< ProductResolverIndexAndSkipBit > const & | itemsToGetFrom (BranchType iType) const |
|
void | labelsForToken (EDGetToken iToken, Labels &oLabels) const |
|
void | modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const |
|
EDConsumerBase const & | operator= (EDConsumerBase const &)=delete |
|
EDConsumerBase & | operator= (EDConsumerBase &&)=default |
|
bool | registeredToConsume (ProductResolverIndex, bool, BranchType) const |
|
bool | registeredToConsumeMany (TypeID const &, BranchType) const |
|
ProductResolverIndexAndSkipBit | uncheckedIndexFrom (EDGetToken) const |
|
void | updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet) |
|
void | updateLookup (eventsetup::ESRecordsToProxyIndices const &) |
|
virtual | ~EDConsumerBase () noexcept(false) |
|
|
static const std::string & | baseType () |
|
static void | fillDescriptions (ConfigurationDescriptions &descriptions) |
|
static void | prevalidate (ConfigurationDescriptions &descriptions) |
|
template<typename ProductType , BranchType B = InEvent> |
EDGetTokenT< ProductType > | consumes (edm::InputTag const &tag) |
|
EDGetToken | consumes (const TypeToGet &id, edm::InputTag const &tag) |
|
template<BranchType B> |
EDGetToken | consumes (TypeToGet const &id, edm::InputTag const &tag) |
|
ConsumesCollector | consumesCollector () |
| Use a ConsumesCollector to gather consumes information from helper functions. More...
|
|
template<typename ProductType , BranchType B = InEvent> |
void | consumesMany () |
|
void | consumesMany (const TypeToGet &id) |
|
template<BranchType B> |
void | consumesMany (const TypeToGet &id) |
|
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event> |
auto | esConsumes () |
|
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event> |
auto | esConsumes (ESInputTag const &tag) |
|
template<typename ProductType , BranchType B = InEvent> |
EDGetTokenT< ProductType > | mayConsume (edm::InputTag const &tag) |
|
EDGetToken | mayConsume (const TypeToGet &id, edm::InputTag const &tag) |
|
template<BranchType B> |
EDGetToken | mayConsume (const TypeToGet &id, edm::InputTag const &tag) |
|
template<class HAD, class DEC>
class edm::ConcurrentGeneratorFilter< HAD, DEC >
Definition at line 76 of file ConcurrentGeneratorFilter.h.
template<class HAD , class DEC >
Implements edm::global::EDFilterBase.
Definition at line 211 of file ConcurrentGeneratorFilter.h.
References utilities::cache(), edm::EventID::event(), event(), particlelevel_cff::genEventInfo, edm::EventBase::id(), eostools::move(), edm::Event::put(), edm::Event::streamID(), and protons_cff::t.
212 auto cache = this->streamCache(
id);
213 RandomEngineSentry<HAD> randomEngineSentry(&
cache->hadronizer_,
ev.streamID());
214 RandomEngineSentry<DEC> randomEngineSentryDecay(
cache->decayer_.get(),
ev.streamID());
216 cache->hadronizer_.setEDMEvent(
ev);
218 bool passEvtGenSelector =
false;
219 std::unique_ptr<HepMC::GenEvent>
event(
nullptr);
221 while (!passEvtGenSelector) {
223 cache->hadronizer_.setEDMEvent(
ev);
225 if (!
cache->hadronizer_.generatePartonsAndHadronize())
234 if (!
cache->hadronizer_.decay())
237 event =
cache->hadronizer_.getGenEvent();
244 if (
cache->decayer_) {
253 passEvtGenSelector =
cache->hadronizer_.select(
event.get());
266 if (!
cache->hadronizer_.residualDecay())
269 cache->hadronizer_.finalizeEvent();
271 event =
cache->hadronizer_.getGenEvent();
275 event->set_event_number(
ev.id().event());
280 std::unique_ptr<GenEventInfoProduct>
genEventInfo(
cache->hadronizer_.getGenEventInfo());
283 genEventInfo = std::make_unique<GenEventInfoProduct>(
event.get());
288 std::unique_ptr<HepMCProduct> bare_product(
new HepMCProduct());
289 bare_product->addHepMCData(
event.release());
291 cache->nEventsInLumiBlock_++;
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
template<class HAD , class DEC >
Definition at line 168 of file ConcurrentGeneratorFilter.h.
References edm::errors::Configuration, edmIntegrityCheck::d, edm::gen::GenStreamCache< HAD, DEC >::decayer_, Exception, edm::LuminosityBlock::get(), h, edm::gen::GenStreamCache< HAD, DEC >::hadronizer_, edm::LuminosityBlock::index(), edm::gen::GenStreamCache< HAD, DEC >::initialized_, and edm::gen::GenStreamCache< HAD, DEC >::nEventsInLumiBlock_.
Referenced by edm::ConcurrentGeneratorFilter< HAD, DEC >::globalBeginLuminosityBlockProduce(), and edm::ConcurrentGeneratorFilter< HAD, DEC >::streamBeginLuminosityBlock().
171 cache->nEventsInLumiBlock_ = 0;
175 auto enginePtr = rng->cloneEngine(
lumi.index());
176 cache->hadronizer_.setRandomEngine(enginePtr.get());
177 cache->decayer_->setRandomEngine(enginePtr.get());
179 auto unsetH = [](HAD*
h) {
h->setRandomEngine(
nullptr); };
180 auto unsetD = [](DEC*
d) {
d->setRandomEngine(
nullptr); };
182 std::unique_ptr<HAD, decltype(unsetH)> randomEngineSentry(&
cache->hadronizer_, unsetH);
183 std::unique_ptr<DEC, decltype(unsetD)> randomEngineSentryDecay(
cache->decayer_.get(), unsetD);
185 cache->hadronizer_.randomizeIndex(
lumi, enginePtr.get());
187 if (!
cache->hadronizer_.readSettings(0))
189 <<
"Failed to read settings for the hadronizer " <<
cache->hadronizer_.classname() <<
" \n";
191 if (
cache->decayer_) {
192 cache->decayer_->init(es);
193 if (!
cache->hadronizer_.declareStableParticles(
cache->decayer_->operatesOnParticles()))
195 <<
"Failed to declare stable particles in hadronizer " <<
cache->hadronizer_.classname()
196 <<
" for internal parton generation\n";
197 if (!
cache->hadronizer_.declareSpecialSettings(
cache->decayer_->specialSettings()))
199 <<
"Failed to declare special settings in hadronizer " <<
cache->hadronizer_.classname() <<
"\n";
202 if (!
cache->hadronizer_.initializeForInternalPartons())
204 <<
"Failed to initialize hadronizer " <<
cache->hadronizer_.classname()
205 <<
" for internal parton generation\n";
207 cache->initialized_ =
true;
FWCore Framework interface EventSetupRecordImplementation h
Helper function to determine trigger accepts.
template<class HAD , class DEC >
Definition at line 325 of file ConcurrentGeneratorFilter.h.
References utilities::cache(), GenRunInfoProduct::XSec::error(), GenRunInfoProduct::internalXSec(), edm::gen::GenLumiSummary::lumiInfo_, eostools::move(), GenLumiInfoProduct::ProcessInfo::setAccepted(), GenLumiInfoProduct::ProcessInfo::setAcceptedBr(), GenLumiInfoProduct::setHEPIDWTUP(), GenLumiInfoProduct::ProcessInfo::setKilled(), GenLumiInfoProduct::ProcessInfo::setLheXSec(), GenLumiInfoProduct::ProcessInfo::setNPassNeg(), GenLumiInfoProduct::ProcessInfo::setNPassPos(), GenLumiInfoProduct::ProcessInfo::setNTotalNeg(), GenLumiInfoProduct::ProcessInfo::setNTotalPos(), GenLumiInfoProduct::ProcessInfo::setProcess(), GenLumiInfoProduct::setProcessInfo(), GenLumiInfoProduct::ProcessInfo::setSelected(), GenLumiInfoProduct::ProcessInfo::setTried(), groupFilesInBlocks::temp, edm::ConcurrentGeneratorFilter< HAD, DEC >::useInLumi_, and GenRunInfoProduct::XSec::value().
329 auto cache = this->streamCache(
id);
330 cache->hadronizer_.statistics();
332 cache->decayer_->statistics();
335 std::vector<GenLumiInfoProduct::ProcessInfo> GenLumiProcess;
338 unsigned int nEvtInLumiBlock_ =
cache->nEventsInLumiBlock_;
345 temp.
setTried(nEvtInLumiBlock_, nEvtInLumiBlock_, nEvtInLumiBlock_);
346 temp.
setSelected(nEvtInLumiBlock_, nEvtInLumiBlock_, nEvtInLumiBlock_);
347 temp.
setKilled(nEvtInLumiBlock_, nEvtInLumiBlock_, nEvtInLumiBlock_);
350 GenLumiProcess.push_back(temp);
356 if (iSummary->lumiInfo_) {
357 iSummary->lumiInfo_->mergeProduct(genLumiInfo);
359 iSummary->lumiInfo_ = std::make_unique<GenLumiInfoProduct>(
std::move(genLumiInfo));
362 cache->nEventsInLumiBlock_ = 0;
364 gen::GenStreamCache<HAD, DEC>* expected =
nullptr;
366 useInLumi_.compare_exchange_strong(expected, this->streamCache(
id));
void setNPassNeg(unsigned int n)
void setTried(unsigned int n, double sum, double sum2)
void setNTotalNeg(unsigned int n)
void setSelected(unsigned int n, double sum, double sum2)
void setKilled(unsigned int n, double sum, double sum2)
std::atomic< gen::GenStreamCache< HAD, DEC > * > useInLumi_
void setAccepted(unsigned int n, double sum, double sum2)
void setAcceptedBr(unsigned int n, double sum, double sum2)
void setNTotalPos(unsigned int n)
void setLheXSec(double value, double err)
void setHEPIDWTUP(const int id)
const XSec & internalXSec() const
void setNPassPos(unsigned int n)
void setProcessInfo(const std::vector< ProcessInfo > &processes)