28 barrelC0_(c.getParameter<double>(
"barrelC0")),
29 endcapC0_(c.getParameter<double>(
"endcapC0")),
30 barrelCpt_(c.getParameter<double>(
"barrelCpt")),
31 endcapCpt_(c.getParameter<double>(
"endcapCpt")),
32 barrelCutOff_(c.getParameter<double>(
"barrelCutOff")),
33 effectiveAreas_((c.getParameter<edm::FileInPath>(
"effAreasConfigFile")).
fullPath()) {
49 double absEta =
std::abs(cand->superCluster()->eta());
53 const float isoCut = C0 + Cpt / cand->pt();
55 return value(cand) < isoCut;
61 double absEta =
std::abs(ele->superCluster()->eta());
64 auto pfIso = ele->pfIsolationVariables();
65 const float chad = pfIso.sumChargedHadronPt;
66 const float nhad = pfIso.sumNeutralHadronEt;
67 const float pho = pfIso.sumPhotonEt;
70 const float iso = chad +
std::max(0.0
f, nhad + pho - rho * eA);
71 return iso / cand->pt();
EDGetTokenT< ProductType > consumes(edm::InputTag const &tag)
const edm::EventSetup & c
const float barrelCutOff_
std::unordered_map< std::string, edm::InputTag > contentTags_
EffectiveAreas effectiveAreas_
const float getEffectiveArea(float eta) const
GsfEleRelPFIsoScaledCut(const edm::ParameterSet &c)
CandidateType candidateType() const final
Abs< T >::type abs(const T &t)
edm::Handle< double > rhoHandle_
std::unordered_map< std::string, edm::EDGetToken > contentTokens_
result_type operator()(const reco::GsfElectronPtr &) const final
void setConsumes(edm::ConsumesCollector &) final
T getParameter(std::string const &) const
bool getByLabel(InputTag const &, Handle< T > &) const
void getEventContent(const edm::EventBase &) final
#define DEFINE_EDM_PLUGIN(factory, type, name)
double value(const reco::CandidatePtr &cand) const final