3 #ifndef PhysicsTools_PatAlgos_PATElectronProducer_h
4 #define PhysicsTools_PatAlgos_PATElectronProducer_h
84 typedef std::vector<edm::Handle<edm::Association<reco::GenParticleCollection> > >
GenAssociations;
86 std::vector<edm::EDGetTokenT<edm::Association<reco::GenParticleCollection> > >
genMatchTokens_;
135 bool primaryVertexIsValid,
137 bool beamspotIsValid );
145 const char* psetName,
150 typedef std::pair<std::string, edm::InputTag>
NameTag;
188 const char* psetName,
194 if (iConfig.
exists( psetName )) {
201 if (depconf.
exists(
"pfAllParticles")) {
204 if (depconf.
exists(
"pfChargedHadrons")) {
207 if (depconf.
exists(
"pfChargedAll")) {
210 if (depconf.
exists(
"pfPUChargedHadrons")) {
213 if (depconf.
exists(
"pfNeutralHadrons")) {
216 if (depconf.
exists(
"pfPhotons")) {
219 if (depconf.
exists(
"user")) {
220 std::vector<edm::InputTag> userdeps = depconf.
getParameter<std::vector<edm::InputTag> >(
"user");
221 std::vector<edm::InputTag>::const_iterator it = userdeps.begin(), ed = userdeps.end();
223 for ( ; it != ed; ++it, ++
key) {
T getParameter(std::string const &) const
bool embedGsfElectronCore_
Assists in assimilating all pat::UserData into pat objects.
IsolationLabels isoDepositLabels_
edm::EDGetTokenT< edm::View< reco::GsfElectron > > electronToken_
void embedHighLevel(pat::Electron &anElectron, reco::GsfTrackRef track, reco::TransientTrack &tt, reco::Vertex &primaryVertex, bool primaryVertexIsValid, reco::BeamSpot &beamspot, bool beamspotIsValid)
bool exists(std::string const ¶meterName) const
checks if a parameter exists
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
edm::RefToBase< reco::GsfElectron > ElectronBaseRef
IsolationKeys
Enum defining isolation keys.
auto vector_transform(std::vector< InputType > const &input, Function predicate) -> std::vector< typename std::remove_cv< typename std::remove_reference< decltype(predicate(input.front()))>::type >::type >
std::vector< edm::EDGetTokenT< edm::ValueMap< float > > > elecIDTokens_
std::pair< pat::IsolationKeys, edm::InputTag > IsolationLabel
GreaterByPt< Electron > pTComparator_
pat::helper::MultiIsolator isolator_
std::vector< edm::Handle< edm::Association< reco::GenParticleCollection > > > GenAssociations
Produces pat::Electron's.
PATElectronProducer(const edm::ParameterSet &iConfig)
edm::EDGetTokenT< EcalRecHitCollection > reducedEndcapRecHitCollectionToken_
std::vector< edm::EDGetTokenT< edm::Association< reco::GenParticleCollection > > > genMatchTokens_
edm::InputTag reducedEndcapRecHitCollection_
std::vector< edm::EDGetTokenT< edm::ValueMap< IsoDeposit > > > isoDepositTokens_
edm::InputTag reducedBarrelRecHitCollection_
mva input variables
edm::EDGetTokenT< reco::ConversionCollection > hConversionsToken_
std::vector< edm::Handle< edm::ValueMap< double > > > IsolationValueMaps
bool embedHighLevelSelection_
embed high level selection variables?
std::pair< std::string, edm::InputTag > NameTag
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
virtual void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
edm::EDGetTokenT< EcalRecHitCollection > reducedBarrelRecHitCollectionToken_
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
std::vector< edm::EDGetTokenT< edm::ValueMap< double > > > isolationValueNoPFIdTokens_
bool embedPflowSuperCluster_
pat::helper::EfficiencyLoader efficiencyLoader_
bool embedPreshowerClusters_
pat::PATUserDataHelper< pat::Electron > userDataHelper_
bool useParticleFlow_
pflow specific
Analysis-level electron class.
const CaloTopology * ecalTopology_
IsolationLabels isolationValueLabelsNoPFId_
edm::EDGetTokenT< edm::ValueMap< reco::PFCandidatePtr > > pfCandidateMapToken_
std::vector< std::pair< pat::IsolationKeys, float > > IsolationValuePairs
std::vector< IsolationLabel > IsolationLabels
IsolationLabels isolationValueLabels_
Calculates a lepton's calorimetric isolation energy.
pat::helper::KinResolutionsLoader resolutionLoader_
void readIsolationLabels(const edm::ParameterSet &iConfig, const char *psetName, IsolationLabels &labels, std::vector< edm::EDGetTokenT< edm::ValueMap< T > > > &tokens)
bool embedPflowBasicClusters_
std::vector< edm::EDGetTokenT< edm::ValueMap< double > > > isolationValueTokens_
edm::EDGetTokenT< reco::BeamSpot > beamLineToken_
pat::helper::MultiIsolator::IsolationValuePairs isolatorTmpStorage_
edm::EDGetTokenT< reco::PFCandidateCollection > pfElecToken_
bool embedPflowPreshowerClusters_
edm::EDGetTokenT< std::vector< reco::Vertex > > pvToken_
Calculates a lepton's tracker isolation pt.
std::vector< NameTag > elecIDSrcs_
std::vector< edm::Handle< edm::ValueMap< IsoDeposit > > > IsoDepositMaps