|
| L1TkFastVertexProducer (const edm::ParameterSet &) |
|
| ~L1TkFastVertexProducer () override |
|
| EDProducer ()=default |
|
| EDProducer (const EDProducer &)=delete |
|
bool | hasAbilityToProduceInBeginLumis () const final |
|
bool | hasAbilityToProduceInBeginProcessBlocks () const final |
|
bool | hasAbilityToProduceInBeginRuns () const final |
|
bool | hasAbilityToProduceInEndLumis () const final |
|
bool | hasAbilityToProduceInEndProcessBlocks () const final |
|
bool | hasAbilityToProduceInEndRuns () const final |
|
EDProducer & | operator= (const EDProducer &)=delete |
|
bool | wantsGlobalLuminosityBlocks () const final |
|
bool | wantsGlobalRuns () const final |
|
bool | wantsInputProcessBlocks () const final |
|
bool | wantsProcessBlocks () const final |
|
bool | wantsStreamLuminosityBlocks () const final |
|
bool | wantsStreamRuns () const final |
|
| EDProducerBase () |
|
ModuleDescription const & | moduleDescription () const |
|
| ~EDProducerBase () 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 |
|
std::vector< bool > const & | recordProvenanceList () 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) |
|
TypeLabelList const & | typeLabelList () const |
| used by the fwk to register the list of products of this module More...
|
|
| ~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 |
|
std::vector< ESProxyIndex > const & | esGetTokenIndicesVector (edm::Transition iTrans) const |
|
std::vector< ESRecordIndex > const & | esGetTokenRecordIndicesVector (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::array< std::vector< ModuleDescription const *> *, NumBranchTypes > &modulesAll, std::vector< ModuleProcessName > &modulesInPreviousProcesses, 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 |
|
void | selectInputProcessBlocks (ProductRegistry const &productRegistry, ProcessBlockHelperBase const &processBlockHelperBase) |
|
ProductResolverIndexAndSkipBit | uncheckedIndexFrom (EDGetToken) const |
|
void | updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet) |
|
void | updateLookup (eventsetup::ESRecordsToProxyIndices const &) |
|
virtual | ~EDConsumerBase () noexcept(false) |
|
|
template<Transition Tr = Transition::Event> |
auto | produces (std::string instanceName) noexcept |
| declare what type of product will make and with which optional label More...
|
|
template<Transition B> |
BranchAliasSetter | produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true) |
|
template<BranchType B> |
BranchAliasSetter | produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true) |
|
BranchAliasSetter | produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true) |
|
template<typename ProductType , Transition B> |
BranchAliasSetterT< ProductType > | produces (std::string instanceName) |
|
template<class ProductType > |
BranchAliasSetterT< ProductType > | produces () |
|
template<typename ProductType , BranchType B> |
BranchAliasSetterT< ProductType > | produces (std::string instanceName) |
|
template<typename ProductType , BranchType B> |
BranchAliasSetterT< ProductType > | produces () |
|
template<class ProductType > |
BranchAliasSetterT< ProductType > | produces (std::string instanceName) |
|
template<typename ProductType , Transition B> |
BranchAliasSetterT< ProductType > | produces () |
|
template<Transition Tr = Transition::Event> |
auto | produces () noexcept |
|
ProducesCollector | producesCollector () |
|
template<typename ProductType , BranchType B = InEvent> |
EDGetTokenT< ProductType > | consumes (edm::InputTag const &tag) |
|
template<BranchType B = InEvent> |
EDConsumerBaseAdaptor< B > | consumes (edm::InputTag tag) noexcept |
|
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<Transition Tr = Transition::Event> |
constexpr auto | esConsumes () |
|
template<Transition Tr = Transition::Event> |
auto | esConsumes (ESInputTag tag) |
|
template<Transition Tr = Transition::Event> |
ESGetTokenGeneric | esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey) |
| Used with EventSetupRecord::doGet. More...
|
|
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) |
|
void | resetItemsToGetFrom (BranchType iType) |
|
Definition at line 48 of file L1TkFastVertexProducer.cc.
Implements edm::global::EDProducerBase.
Definition at line 137 of file L1TkFastVertexProducer.cc.
References a0, testProducerWithPsetDescEmpty_cfi::a2, funct::abs(), hltPixelTracks_cff::chi2, chi2Max_, doPtComp_, doTightChi2_, PVValHelper::eta, Exception, spr::find(), newFWLiteAna::found, genparticleToken_, edm::EventSetup::getData(), edm::HepMCProduct::GetEvent(), hepmcToken_, highPtTracks_, mps_fire::i, iEvent, createfilelist::int, edm::HandleBase::isValid(), LogTrace, monteCarloVertex_, eostools::move(), nBinning_, nStubsmin_, nStubsPSmin_, nVtx_, parents, funct::pow(), DiDispStaMuonMonitor_cfi::pt, pTMax_, pTMinTra_, mps_fire::result, mps_update::status, StripSubdetector::TID, StripSubdetector::TOB, topoToken_, HLT_2022v12_cff::track, align::Tracker, trackToken_, trkChi2dofTightChi2_, trkPtTightChi2_, weight_, xmax_, xmin_, z, HLTMuonOfflineAnalyzer_cfi::z0, testProducerWithPsetDescEmpty_cfi::z2, and zMax_.
140 auto result = std::make_unique<TkPrimaryVertexCollection>();
158 const double mm = 0.1;
159 float zvtx_gen = -999;
165 for (HepMC::GenEvent::vertex_const_iterator ivertex = MCEvt->vertices_begin(); ivertex != MCEvt->vertices_end();
167 bool hasParentVertex =
false;
170 for (HepMC::GenVertex::particle_iterator iparent = (*ivertex)->particles_begin(
HepMC::parents);
173 if ((*iparent)->production_vertex()) {
174 hasParentVertex =
true;
182 HepMC::FourVector
pos = (*ivertex)->position();
183 zvtx_gen =
pos.z() * mm;
187 }
else if (GenParticleHandle.
isValid()) {
188 for (
const auto& genpart : *GenParticleHandle) {
189 int status = genpart.status();
192 if (genpart.numberOfMothers() == 0)
194 float part_zvertex = genpart.vz();
195 zvtx_gen = part_zvertex;
200 <<
"\nerror: try to retrieve the MC vertex (monteCarloVertex_ = True) " 201 <<
"\nbut the input file contains neither edm::HepMCProduct> nor vector<reco::GenParticle>. Exit" 207 result->push_back(genvtx);
215 if (!L1TTTrackHandle.
isValid()) {
217 <<
"\nWarning: L1TkTrackCollection with not found in the event. Exit" << std::endl;
221 for (
const auto&
track : *L1TTTrackHandle) {
222 float z =
track.POCA().z();
224 float pt =
track.momentum().perp();
251 theStubs =
track.getStubRefs();
253 int tmp_trk_nstub = (
int)theStubs.size();
254 if (tmp_trk_nstub < 0) {
256 <<
" ... could not retrieve the vector of stubs in L1TkFastVertexProducer::SumPtVertex " << std::endl;
261 for (
const auto& stub : theStubs) {
264 DetId detId(stub->getDetId());
280 int trk_nstub = (
int)
track.getStubRefs().size();
281 float chi2dof =
chi2 / (2 * trk_nstub - 4);
284 float trk_consistency =
track.stubPtConsistency();
285 if (trk_nstub == 4) {
298 htmp_weight.Fill(
z, wt);
307 int nb = htmp.GetNbinsX();
308 std::vector<int>
found;
310 for (
int ivtx = 0; ivtx <
nVtx_; ivtx++) {
314 for (
int i = 2;
i <= nb - 1;
i++) {
315 float a0 = htmp_weight.GetBinContent(
i - 1);
316 float a1 = htmp_weight.GetBinContent(
i);
317 float a2 = htmp_weight.GetBinContent(
i + 1);
318 float sigma =
a0 + a1 +
a2;
322 float z0 = htmp_weight.GetBinCenter(
i - 1);
323 float z1 = htmp_weight.GetBinCenter(
i);
324 float z2 = htmp_weight.GetBinCenter(
i + 1);
325 zvtx_sliding = (
a0 *
z0 + a1 * z1 +
a2 *
z2) / sigma;
328 found.push_back(imax);
const edm::ESGetToken< TrackerTopology, TrackerTopologyRcd > topoToken_
static constexpr float xmin_
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
float trkChi2dofTightChi2_
Abs< T >::type abs(const T &t)
bool getData(T &iHolder) const
static constexpr auto TOB
Class to store the L1 Track Trigger stubs.
const edm::EDGetTokenT< std::vector< TTTrack< Ref_Phase2TrackerDigi_ > > > trackToken_
const HepMC::GenEvent * GetEvent() const
static constexpr float xmax_
const edm::EDGetTokenT< std::vector< reco::GenParticle > > genparticleToken_
static constexpr float a0
const edm::EDGetTokenT< edm::HepMCProduct > hepmcToken_
static constexpr auto TID
Power< A, B >::type pow(const A &a, const B &b)