#include <SimpleCutsIsolator.h>
Public Member Functions | |
virtual Result | result (const DepositContainer &deposits, const edm::Event *=0) const |
Compute and return the isolation variable. | |
virtual Result | result (const DepositContainer &deposits, const reco::Track &tk, const edm::Event *=0) const |
Compute and return the isolation variable, with vetoes and the muon. | |
virtual ResultType | resultType () const |
SimpleCutsIsolator (const edm::ParameterSet &par) | |
Private Attributes | |
muonisolation::Cuts | theCuts |
Definition at line 8 of file SimpleCutsIsolator.h.
SimpleCutsIsolator::SimpleCutsIsolator | ( | const edm::ParameterSet & | par | ) | [inline] |
Definition at line 10 of file SimpleCutsIsolator.h.
: theCuts(par.getParameter<std::vector<double> > ("EtaBounds"), par.getParameter<std::vector<double> > ("ConeSizes"), par.getParameter<std::vector<double> > ("Thresholds")) { }
virtual Result SimpleCutsIsolator::result | ( | const DepositContainer & | deposits, |
const edm::Event * | = 0 |
||
) | const [inline, virtual] |
Compute and return the isolation variable.
Implements muonisolation::MuIsoBaseIsolator.
Definition at line 19 of file SimpleCutsIsolator.h.
References submit::answer, muonisolation::MuIsoBaseIsolator::ISOL_BOOL_TYPE, and muonisolation::MuIsoBaseIsolator::Result::valBool.
{ Result answer(ISOL_BOOL_TYPE); answer.valBool = false; // fail miserably... return answer; }
virtual Result SimpleCutsIsolator::result | ( | const DepositContainer & | deposits, |
const reco::Track & | muon, | ||
const edm::Event * | = 0 |
||
) | const [inline, virtual] |
Compute and return the isolation variable, with vetoes and the muon.
Reimplemented from muonisolation::MuIsoBaseIsolator.
Definition at line 26 of file SimpleCutsIsolator.h.
References submit::answer, muonisolation::Cuts::CutSpec::conesize, reco::TrackBase::eta(), muonisolation::MuIsoBaseIsolator::ISOL_BOOL_TYPE, theCuts, muonisolation::Cuts::CutSpec::threshold, muonisolation::MuIsoBaseIsolator::Result::valBool, and muonisolation::MuIsoBaseIsolator::Result::valFloat.
{ Result answer(ISOL_BOOL_TYPE); muonisolation::Cuts::CutSpec cuts_here = theCuts(tk.eta()); double conesize = cuts_here.conesize; double dephlt = 0; unsigned int nDeps = deposits.size(); for(unsigned int iDep = 0; iDep < nDeps; ++iDep ){ dephlt += deposits[iDep].dep->depositWithin(conesize); } answer.valFloat = dephlt; if (dephlt<cuts_here.threshold) { answer.valBool = true; } else { answer.valBool = false; } return answer; }
virtual ResultType SimpleCutsIsolator::resultType | ( | ) | const [inline, virtual] |
Implements muonisolation::MuIsoBaseIsolator.
Definition at line 17 of file SimpleCutsIsolator.h.
References muonisolation::MuIsoBaseIsolator::ISOL_BOOL_TYPE.
{return ISOL_BOOL_TYPE;}
Definition at line 49 of file SimpleCutsIsolator.h.
Referenced by result().