#include <ElectronIDSelectorLikelihood.h>
Public Member Functions | |
ElectronIDSelectorLikelihood (const edm::ParameterSet &conf) | |
void | newEvent (const edm::Event &, const edm::EventSetup &) |
double | operator() (const reco::GsfElectron &, const edm::Event &, const edm::EventSetup &) |
virtual | ~ElectronIDSelectorLikelihood () |
Private Attributes | |
edm::ParameterSet | conf_ |
bool | doLikelihood_ |
edm::ESHandle< ElectronLikelihood > | likelihoodAlgo_ |
edm::InputTag | reducedBarrelRecHitCollection_ |
edm::InputTag | reducedEndcapRecHitCollection_ |
Definition at line 19 of file ElectronIDSelectorLikelihood.h.
ElectronIDSelectorLikelihood::ElectronIDSelectorLikelihood | ( | const edm::ParameterSet & | conf | ) | [explicit] |
Definition at line 3 of file ElectronIDSelectorLikelihood.cc.
References conf_, doLikelihood_, edm::ParameterSet::getParameter(), reducedBarrelRecHitCollection_, and reducedEndcapRecHitCollection_.
: conf_ (conf) { doLikelihood_ = conf_.getParameter<bool> ("doLikelihood"); reducedBarrelRecHitCollection_ = conf.getParameter<edm::InputTag>("reducedBarrelRecHitCollection"); reducedEndcapRecHitCollection_ = conf.getParameter<edm::InputTag>("reducedEndcapRecHitCollection"); }
ElectronIDSelectorLikelihood::~ElectronIDSelectorLikelihood | ( | ) | [virtual] |
Definition at line 11 of file ElectronIDSelectorLikelihood.cc.
{ }
void ElectronIDSelectorLikelihood::newEvent | ( | const edm::Event & | e, |
const edm::EventSetup & | es | ||
) |
Definition at line 15 of file ElectronIDSelectorLikelihood.cc.
References edm::EventSetup::getData(), and likelihoodAlgo_.
{ es.getData(likelihoodAlgo_) ; }
double ElectronIDSelectorLikelihood::operator() | ( | const reco::GsfElectron & | ele, |
const edm::Event & | e, | ||
const edm::EventSetup & | es | ||
) |
Definition at line 22 of file ElectronIDSelectorLikelihood.cc.
References doLikelihood_, edm::Event::getByLabel(), likelihoodAlgo_, reducedBarrelRecHitCollection_, and reducedEndcapRecHitCollection_.
{ if (doLikelihood_) { edm::Handle< EcalRecHitCollection > pEBRecHits; e.getByLabel( reducedBarrelRecHitCollection_, pEBRecHits ); edm::Handle< EcalRecHitCollection > pEERecHits; e.getByLabel( reducedEndcapRecHitCollection_, pEERecHits ); EcalClusterLazyTools lazyTools( e, es, reducedBarrelRecHitCollection_, reducedEndcapRecHitCollection_ ) ; return static_cast<double>(likelihoodAlgo_->resultLog (ele,lazyTools)) ; } return 0; }
Definition at line 33 of file ElectronIDSelectorLikelihood.h.
Referenced by ElectronIDSelectorLikelihood().
bool ElectronIDSelectorLikelihood::doLikelihood_ [private] |
Definition at line 38 of file ElectronIDSelectorLikelihood.h.
Referenced by ElectronIDSelectorLikelihood(), and operator()().
Definition at line 31 of file ElectronIDSelectorLikelihood.h.
Referenced by newEvent(), and operator()().
Definition at line 35 of file ElectronIDSelectorLikelihood.h.
Referenced by ElectronIDSelectorLikelihood(), and operator()().
Definition at line 36 of file ElectronIDSelectorLikelihood.h.
Referenced by ElectronIDSelectorLikelihood(), and operator()().