3 #ifndef PhysicsTools_PatAlgos_PATElectronProducer_h 4 #define PhysicsTools_PatAlgos_PATElectronProducer_h 49 class TrackerIsolationPt;
50 class CaloIsolationEnergy;
84 typedef std::vector<edm::Handle<edm::Association<reco::GenParticleCollection> > >
GenAssociations;
86 std::vector<edm::EDGetTokenT<edm::Association<reco::GenParticleCollection> > >
genMatchTokens_;
117 const ElectronBaseRef& electronRef,
119 const GenAssociations& genMatches,
129 const GenAssociations& genMatches,
139 bool primaryVertexIsValid,
141 bool beamspotIsValid );
149 const char* psetName,
154 typedef std::pair<std::string, edm::InputTag>
NameTag;
194 const char* psetName,
200 if (iConfig.
exists( psetName )) {
207 if (depconf.
exists(
"pfAllParticles")) {
210 if (depconf.
exists(
"pfChargedHadrons")) {
213 if (depconf.
exists(
"pfChargedAll")) {
216 if (depconf.
exists(
"pfPUChargedHadrons")) {
219 if (depconf.
exists(
"pfNeutralHadrons")) {
222 if (depconf.
exists(
"pfPhotons")) {
225 if (depconf.
exists(
"user")) {
226 std::vector<edm::InputTag> userdeps = depconf.
getParameter<std::vector<edm::InputTag> >(
"user");
227 std::vector<edm::InputTag>::const_iterator it = userdeps.begin(), ed = userdeps.end();
229 for ( ; it != ed; ++it, ++
key) {
void readIsolationLabels(const edm::ParameterSet &iConfig, const char *psetName, IsolationLabels &labels, std::vector< edm::EDGetTokenT< edm::ValueMap< T > > > &tokens)
T getParameter(std::string const &) const
Assists in assimilating all pat::UserData into pat objects.
const edm::EDGetTokenT< reco::ConversionCollection > hConversionsToken_
edm::EDGetTokenT< edm::ValueMap< float > > PUPPINoLeptonsIsolation_charged_hadrons_
const GreaterByPt< Electron > pTComparator_
edm::EDGetTokenT< edm::ValueMap< float > > PUPPIIsolation_charged_hadrons_
const bool useParticleFlow_
pflow specific
const edm::EDGetTokenT< reco::PFCandidateCollection > pfElecToken_
edm::EDGetTokenT< edm::ValueMap< float > > PUPPIIsolation_neutral_hadrons_
const edm::EDGetTokenT< edm::ValueMap< float > > ecalPFClusterIsoT_
IsolationLabels isoDepositLabels_
const bool embedPFCandidate_
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
const edm::InputTag reducedBarrelRecHitCollection_
mva input variables
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
const edm::EDGetTokenT< edm::ValueMap< float > > hcalPFClusterIsoT_
IsolationKeys
Enum defining isolation keys.
const bool embedBasicClusters_
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_
const edm::EDGetTokenT< edm::View< reco::GsfElectron > > electronToken_
const bool addEfficiencies_
const edm::EDGetTokenT< std::vector< reco::Vertex > > pvToken_
std::pair< pat::IsolationKeys, edm::InputTag > IsolationLabel
const edm::EDGetTokenT< edm::ValueMap< reco::PFCandidatePtr > > pfCandidateMapToken_
pat::helper::MultiIsolator isolator_
std::vector< edm::Handle< edm::Association< reco::GenParticleCollection > > > GenAssociations
edm::EDGetTokenT< edm::ValueMap< float > > PUPPIIsolation_photons_
Produces pat::Electron's.
const bool addPuppiIsolation_
PATElectronProducer(const edm::ParameterSet &iConfig)
const bool embedHighLevelSelection_
embed high level selection variables?
const bool addResolutions_
std::vector< edm::EDGetTokenT< edm::Association< reco::GenParticleCollection > > > genMatchTokens_
std::vector< edm::EDGetTokenT< edm::ValueMap< IsoDeposit > > > isoDepositTokens_
edm::EDGetTokenT< edm::ValueMap< float > > PUPPINoLeptonsIsolation_neutral_hadrons_
const bool embedSeedCluster_
const edm::EDGetTokenT< EcalRecHitCollection > reducedEndcapRecHitCollectionToken_
const edm::InputTag reducedEndcapRecHitCollection_
const bool addPFClusterIso_
std::vector< edm::Handle< edm::ValueMap< double > > > IsolationValueMaps
std::pair< std::string, edm::InputTag > NameTag
edm::EDGetTokenT< edm::ValueMap< float > > PUPPINoLeptonsIsolation_photons_
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
virtual void produce(edm::Event &iEvent, const edm::EventSetup &iSetup) override
const bool embedGsfTrack_
const edm::EDGetTokenT< reco::BeamSpot > beamLineToken_
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_
pat::helper::EfficiencyLoader efficiencyLoader_
const edm::EDGetTokenT< EcalRecHitCollection > reducedBarrelRecHitCollectionToken_
const bool embedGsfElectronCore_
pat::PATUserDataHelper< pat::Electron > userDataHelper_
Analysis-level electron class.
const CaloTopology * ecalTopology_
IsolationLabels isolationValueLabelsNoPFId_
std::vector< std::pair< pat::IsolationKeys, float > > IsolationValuePairs
std::vector< IsolationLabel > IsolationLabels
IsolationLabels isolationValueLabels_
const bool embedPflowSuperCluster_
const bool embedPflowPreshowerClusters_
pat::helper::KinResolutionsLoader resolutionLoader_
const bool embedPflowBasicClusters_
std::vector< edm::EDGetTokenT< edm::ValueMap< double > > > isolationValueTokens_
pat::helper::MultiIsolator::IsolationValuePairs isolatorTmpStorage_
const bool embedPreshowerClusters_
std::vector< NameTag > elecIDSrcs_
const bool embedSuperCluster_
std::vector< edm::Handle< edm::ValueMap< IsoDeposit > > > IsoDepositMaps