Produces pat::Electron's. More...
#include "PhysicsTools/PatAlgos/interface/PATElectronProducer.h"
Public Member Functions | |
PATElectronProducer (const edm::ParameterSet &iConfig) | |
virtual void | produce (edm::Event &iEvent, const edm::EventSetup &iSetup) override |
~PATElectronProducer () | |
Public Member Functions inherited from edm::stream::EDProducer<> | |
EDProducer ()=default | |
Public Member Functions inherited from edm::stream::EDProducerBase | |
EDProducerBase () | |
ModuleDescription const & | moduleDescription () const |
virtual | ~EDProducerBase () |
Public Member Functions inherited from edm::ProducerBase | |
void | callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func) |
ProducerBase () | |
void | registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &) |
std::function< void(BranchDescription const &)> | registrationCallback () const |
used by the fwk to register list of products More... | |
virtual | ~ProducerBase () |
Public Member Functions inherited from edm::EDConsumerBase | |
std::vector< ConsumesInfo > | consumesInfo () const |
EDConsumerBase () | |
ProductHolderIndexAndSkipBit | indexFrom (EDGetToken, BranchType, TypeID const &) const |
void | itemsMayGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const |
void | itemsToGet (BranchType, std::vector< ProductHolderIndexAndSkipBit > &) const |
std::vector < ProductHolderIndexAndSkipBit > const & | itemsToGetFromEvent () const |
void | labelsForToken (EDGetToken iToken, Labels &oLabels) const |
void | modulesDependentUpon (const std::string &iProcessName, std::vector< const char * > &oModuleLabels) const |
void | modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const |
bool | registeredToConsume (ProductHolderIndex, bool, BranchType) const |
bool | registeredToConsumeMany (TypeID const &, BranchType) const |
void | updateLookup (BranchType iBranchType, ProductHolderIndexHelper const &) |
virtual | ~EDConsumerBase () |
Static Public Member Functions | |
static void | fillDescriptions (edm::ConfigurationDescriptions &descriptions) |
Static Public Member Functions inherited from edm::stream::EDProducerBase | |
static const std::string & | baseType () |
static void | fillDescriptions (ConfigurationDescriptions &descriptions) |
static void | prevalidate (ConfigurationDescriptions &descriptions) |
Private Types | |
typedef edm::RefToBase < reco::GsfElectron > | ElectronBaseRef |
typedef std::vector < edm::Handle < edm::Association < reco::GenParticleCollection > > > | GenAssociations |
typedef std::vector < edm::Handle< edm::ValueMap < IsoDeposit > > > | IsoDepositMaps |
typedef std::pair < pat::IsolationKeys, edm::InputTag > | IsolationLabel |
typedef std::vector < IsolationLabel > | IsolationLabels |
typedef std::vector < edm::Handle< edm::ValueMap < double > > > | IsolationValueMaps |
typedef std::pair< std::string, edm::InputTag > | NameTag |
Private Member Functions | |
void | embedHighLevel (pat::Electron &anElectron, reco::GsfTrackRef track, reco::TransientTrack &tt, reco::Vertex &primaryVertex, bool primaryVertexIsValid, reco::BeamSpot &beamspot, bool beamspotIsValid) |
void | fillElectron (Electron &aElectron, const ElectronBaseRef &electronRef, const reco::CandidateBaseRef &baseRef, const GenAssociations &genMatches, const IsoDepositMaps &deposits, const bool pfId, const IsolationValueMaps &isolationValues, const IsolationValueMaps &isolationValuesNoPFId) const |
common electron filling, for both the standard and PF2PAT case More... | |
void | fillElectron2 (Electron &anElectron, const reco::CandidatePtr &candPtrForIsolation, const reco::CandidatePtr &candPtrForGenMatch, const reco::CandidatePtr &candPtrForLoader, const GenAssociations &genMatches, const IsoDepositMaps &deposits, const IsolationValueMaps &isolationValues) const |
template<typename T > | |
void | readIsolationLabels (const edm::ParameterSet &iConfig, const char *psetName, IsolationLabels &labels, std::vector< edm::EDGetTokenT< edm::ValueMap< T > > > &tokens) |
Additional Inherited Members | |
Public Types inherited from edm::stream::EDProducer<> | |
typedef CacheContexts< T...> | CacheTypes |
typedef CacheTypes::GlobalCache | GlobalCache |
typedef AbilityChecker< T...> | HasAbility |
typedef CacheTypes::LuminosityBlockCache | LuminosityBlockCache |
typedef LuminosityBlockContextT < LuminosityBlockCache, RunCache, GlobalCache > | LuminosityBlockContext |
typedef CacheTypes::LuminosityBlockSummaryCache | LuminosityBlockSummaryCache |
typedef CacheTypes::RunCache | RunCache |
typedef RunContextT< RunCache, GlobalCache > | RunContext |
typedef CacheTypes::RunSummaryCache | RunSummaryCache |
Public Types inherited from edm::stream::EDProducerBase | |
typedef EDProducerAdaptorBase | ModuleType |
Public Types inherited from edm::ProducerBase | |
typedef ProductRegistryHelper::TypeLabelList | TypeLabelList |
Public Types inherited from edm::EDConsumerBase | |
typedef ProductLabels | Labels |
Protected Member Functions inherited from edm::EDConsumerBase | |
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 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) |
Produces pat::Electron's.
The PATElectronProducer produces analysis-level pat::Electron's starting from a collection of objects of reco::GsfElectron.
Definition at line 54 of file PATElectronProducer.h.
|
private |
Definition at line 109 of file PATElectronProducer.h.
|
private |
Definition at line 84 of file PATElectronProducer.h.
|
private |
Definition at line 110 of file PATElectronProducer.h.
|
private |
Definition at line 142 of file PATElectronProducer.h.
|
private |
Definition at line 143 of file PATElectronProducer.h.
|
private |
Definition at line 111 of file PATElectronProducer.h.
|
private |
Definition at line 153 of file PATElectronProducer.h.
|
explicit |
Definition at line 50 of file PATElectronProducer.cc.
References addGenMatch_, edm::EDConsumerBase::consumes(), edm::ParameterSet::existsAs(), genMatchTokens_, edm::ParameterSet::getParameter(), GlobalPosition_Frontier_DevDB_cff::tag, and edm::vector_transform().
PATElectronProducer::~PATElectronProducer | ( | ) |
Definition at line 178 of file PATElectronProducer.cc.
|
private |
Definition at line 1010 of file PATElectronProducer.cc.
References pat::Electron::BS2D, pat::Electron::BS3D, reco::BeamSpot::covariance3D(), reco::BeamSpot::position(), pat::Electron::PV2D, pat::Electron::PV3D, query::result, pat::Electron::setDB(), IPTools::signedImpactParameter3D(), and IPTools::signedTransverseImpactParameter().
Referenced by produce().
|
static |
Definition at line 880 of file PATElectronProducer.cc.
References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::add(), edm::ParameterSetDescription::addNode(), edm::ParameterSetDescription::addOptional(), pat::helper::KinResolutionsLoader::fillDescription(), pat::PATUserDataHelper< ObjectType >::fillDescription(), edm::ParameterSetDescription::ifValue(), HLT_25ns14e33_v1_cff::InputTag, or, edm::ParameterSetDescription::setAllowAnything(), edm::ParameterSetDescription::setComment(), and edm::ParameterDescriptionNode::setComment().
|
private |
common electron filling, for both the standard and PF2PAT case
Definition at line 699 of file PATElectronProducer.cc.
References addGenMatch_, pat::PATObject< ObjectType >::addGenParticleRef(), assert(), efficiencyLoader_, pat::Electron::embedBasicClusters(), embedBasicClusters_, embedGenMatch_, pat::PATObject< ObjectType >::embedGenParticle(), pat::Electron::embedGsfElectronCore(), embedGsfElectronCore_, pat::Electron::embedGsfTrack(), embedGsfTrack_, pat::Electron::embedPflowBasicClusters(), embedPflowBasicClusters_, pat::Electron::embedPflowPreshowerClusters(), embedPflowPreshowerClusters_, pat::Electron::embedPflowSuperCluster(), embedPflowSuperCluster_, pat::Electron::embedPreshowerClusters(), embedPreshowerClusters_, pat::Electron::embedSeedCluster(), embedSeedCluster_, pat::Electron::embedSuperCluster(), embedSuperCluster_, pat::Electron::embedTrack(), embedTrack_, pat::helper::EfficiencyLoader::enabled(), pat::helper::KinResolutionsLoader::enabled(), plotBeamSpotDB::first, i, edm::Ref< C, T, F >::isNull(), isoDepositLabels_, isolationValueLabels_, isolationValueLabelsNoPFId_, j, gen::n, pat::Electron::pfCandidateRef(), resolutionLoader_, pat::helper::EfficiencyLoader::setEfficiencies(), pat::Lepton< LeptonType >::setIsoDeposit(), pat::Lepton< LeptonType >::setIsolation(), pat::helper::KinResolutionsLoader::setResolutions(), source, and useParticleFlow_.
Referenced by produce().
|
private |
Definition at line 795 of file PATElectronProducer.cc.
References addGenMatch_, pat::PATObject< ObjectType >::addGenParticleRef(), edm::contains(), pat::EcalIso, efficiencyLoader_, pat::Electron::embedBasicClusters(), embedBasicClusters_, embedGenMatch_, pat::PATObject< ObjectType >::embedGenParticle(), pat::Electron::embedGsfElectronCore(), embedGsfElectronCore_, pat::Electron::embedGsfTrack(), embedGsfTrack_, pat::Electron::embedPflowBasicClusters(), embedPflowBasicClusters_, pat::Electron::embedPflowPreshowerClusters(), embedPflowPreshowerClusters_, pat::Electron::embedPflowSuperCluster(), embedPflowSuperCluster_, pat::Electron::embedPreshowerClusters(), embedPreshowerClusters_, pat::Electron::embedSeedCluster(), embedSeedCluster_, pat::Electron::embedSuperCluster(), embedSuperCluster_, pat::Electron::embedTrack(), embedTrack_, pat::helper::EfficiencyLoader::enabled(), pat::helper::KinResolutionsLoader::enabled(), plotBeamSpotDB::first, pat::HcalIso, i, edm::Ptr< T >::id(), isoDepositLabels_, isolationValueLabels_, j, gen::n, reco::GsfElectron::p4(), pat::Electron::pfCandidateRef(), resolutionLoader_, pat::Electron::setEcalDrivenMomentum(), pat::helper::EfficiencyLoader::setEfficiencies(), pat::Lepton< LeptonType >::setIsoDeposit(), pat::Lepton< LeptonType >::setIsolation(), reco::GsfElectron::setP4(), pat::helper::KinResolutionsLoader::setResolutions(), and pat::TrackIso.
Referenced by produce().
|
overridevirtual |
Implements edm::stream::EDProducerBase.
Definition at line 183 of file PATElectronProducer.cc.
References IPTools::absoluteImpactParameter3D(), addElecID_, addGenMatch_, addPFClusterIso_, Reference_intrackfit_cff::barrel, beamLineToken_, SiPixelRawToDigiRegional_cfi::beamSpot, pat::helper::MultiIsolator::beginEvent(), reco::PFCandidate::e, DetId::Ecal, EcalBarrel, EcalEndcap, ecalPFClusterIsoT_, ecalTopology_, efficiencyLoader_, elecIDSrcs_, elecIDTokens_, electronToken_, embedBasicClusters_, embedGenMatch_, embedHighLevel(), embedHighLevelSelection_, pat::Electron::embedPFCandidate(), embedPFCandidate_, embedPflowBasicClusters_, pat::Electron::embedRecHits(), embedRecHits_, pat::helper::EfficiencyLoader::enabled(), pat::helper::KinResolutionsLoader::enabled(), pat::helper::MultiIsolator::enabled(), edm::SortedCollection< T, SORT >::end(), pat::helper::MultiIsolator::endEvent(), pat::helper::MultiIsolator::fill(), fillElectron(), fillElectron2(), edm::SortedCollection< T, SORT >::find(), plotBeamSpotDB::first, genMatchTokens_, edm::EventSetup::get(), edm::Event::getByToken(), CaloTopology::getSubdetectorTopology(), CaloSubdetectorTopology::getWindow(), ConversionTools::hasMatchedConversion(), hcalPFClusterIsoT_, hConversionsToken_, i, customizeTrackingMonitorSeedNumber::idx, cmsHarvester::index, edm::Ref< C, T, F >::isAvailable(), edm::Ptr< T >::isNonnull(), edm::Ref< C, T, F >::isNonnull(), isoDepositLabels_, isoDepositTokens_, isolationValueNoPFIdTokens_, isolationValueTokens_, isolator_, isolatorTmpStorage_, edm::EventBase::isRealData(), edm::HandleBase::isValid(), j, reco::Matched, reco::HitPattern::MISSING_INNER_HITS, pat::helper::EfficiencyLoader::newEvent(), pat::helper::KinResolutionsLoader::newEvent(), electronProducer_cfi::patElectrons, pfCandidateMapToken_, pfElecToken_, pfElectrons_cff::pfElectrons, HLT_25ns14e33_v1_cff::primaryVertex, pTComparator_, edm::SortedCollection< T, SORT >::push_back(), edm::Event::put(), pvToken_, HLT_25ns14e33_v3_cff::recHits, reducedBarrelRecHitCollectionToken_, reducedEndcapRecHitCollectionToken_, resolutionLoader_, fileCollector::seed, pat::Electron::setEcalPFClusterIso(), pat::Electron::setElectronIDs(), pat::Electron::setHcalPFClusterIso(), pat::Lepton< LeptonType >::setIsoDeposit(), pat::Lepton< LeptonType >::setIsolation(), pat::Electron::setIsPF(), pat::Electron::setMvaVariables(), pat::Electron::setPassConversionVeto(), pat::Electron::setPFCandidateRef(), edm::SortedCollection< T, SORT >::sort(), python.multivaluedict::sort(), groupFilesInBlocks::tt, useParticleFlow_, userDataHelper_, and useUserData_.
|
private |
fill the labels vector from the contents of the parameter set, for the isodeposit or isolation values embedding
Definition at line 183 of file PATElectronProducer.h.
References pat::EcalIso, edm::ParameterSet::exists(), edm::ParameterSet::getParameter(), pat::HcalIso, relval_steps::key, diffTwoXMLs::label, pat::PfAllParticleIso, pat::PfChargedAllIso, pat::PfChargedHadronIso, pat::PfGammaIso, pat::PfNeutralHadronIso, pat::PfPUChargedHadronIso, pat::TrackIso, pat::UserBaseIso, and edm::vector_transform().
|
private |
Definition at line 169 of file PATElectronProducer.h.
|
private |
Definition at line 152 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 80 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), PATElectronProducer(), and produce().
|
private |
Definition at line 100 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 172 of file PATElectronProducer.h.
|
private |
Definition at line 106 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 101 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 178 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 170 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), and produce().
|
private |
Definition at line 154 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 155 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 68 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 75 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), and produce().
|
private |
Definition at line 81 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), and produce().
|
private |
Definition at line 70 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 71 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
embed high level selection variables?
Definition at line 105 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 92 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 77 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), and produce().
|
private |
Definition at line 78 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 73 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 76 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 82 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 74 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 72 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 79 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 86 of file PATElectronProducer.h.
Referenced by PATElectronProducer(), and produce().
|
private |
Definition at line 102 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 69 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 162 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), and produce().
|
private |
Definition at line 163 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 164 of file PATElectronProducer.h.
Referenced by fillElectron(), and fillElectron2().
|
private |
Definition at line 166 of file PATElectronProducer.h.
Referenced by fillElectron().
|
private |
Definition at line 167 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 165 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 160 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 161 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 91 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 90 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 158 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 107 of file PATElectronProducer.h.
Referenced by produce().
|
private |
mva input variables
Definition at line 95 of file PATElectronProducer.h.
|
private |
Definition at line 96 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 97 of file PATElectronProducer.h.
|
private |
Definition at line 98 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 173 of file PATElectronProducer.h.
Referenced by fillElectron(), fillElectron2(), and produce().
|
private |
pflow specific
Definition at line 89 of file PATElectronProducer.h.
Referenced by fillElectron(), and produce().
|
private |
Definition at line 176 of file PATElectronProducer.h.
Referenced by produce().
|
private |
Definition at line 175 of file PATElectronProducer.h.
Referenced by produce().