Public Member Functions | |
void | beginEvent (const edm::Event &, const edm::EventSetup &) |
double | discriminate (const reco::PFTauRef &) |
PFRecoTauDiscriminationByDeltaE (const ParameterSet &iConfig) | |
~PFRecoTauDiscriminationByDeltaE () | |
Private Member Functions | |
double | DeltaE (const PFTauRef &) |
Private Attributes | |
bool | booleanOutput |
double | chargedPionMass |
double | deltaEmax |
double | deltaEmin |
Definition at line 16 of file PFRecoTauDiscriminationByDeltaE.cc.
PFRecoTauDiscriminationByDeltaE::PFRecoTauDiscriminationByDeltaE | ( | const ParameterSet & | iConfig | ) | [inline, explicit] |
Definition at line 18 of file PFRecoTauDiscriminationByDeltaE.cc.
References edm::ParameterSet::getParameter().
:PFTauDiscriminationProducerBase(iConfig){ deltaEmin = iConfig.getParameter<double>("deltaEmin"); deltaEmax = iConfig.getParameter<double>("deltaEmax"); chargedPionMass = 0.139; booleanOutput = iConfig.getParameter<bool>("BooleanOutput"); }
PFRecoTauDiscriminationByDeltaE::~PFRecoTauDiscriminationByDeltaE | ( | ) | [inline] |
Definition at line 25 of file PFRecoTauDiscriminationByDeltaE.cc.
{}
void PFRecoTauDiscriminationByDeltaE::beginEvent | ( | const edm::Event & | iEvent, |
const edm::EventSetup & | iSetup | ||
) | [virtual] |
Reimplemented from TauDiscriminationProducerBase< TauType, TauDiscriminator >.
Definition at line 39 of file PFRecoTauDiscriminationByDeltaE.cc.
{ }
double PFRecoTauDiscriminationByDeltaE::DeltaE | ( | const PFTauRef & | tau | ) | [private] |
Definition at line 49 of file PFRecoTauDiscriminationByDeltaE.cc.
References i, p4, and edm::RefVector< C, T, F >::size().
{ double tracksE = 0; PFCandidateRefVector signalTracks = tau->signalPFChargedHadrCands(); for(size_t i = 0; i < signalTracks.size(); ++i){ TLorentzVector p4; p4.SetXYZM(signalTracks[i]->px(), signalTracks[i]->py(), signalTracks[i]->pz(), chargedPionMass); tracksE += p4.E(); } double hadrTauP = tau->momentum().r() * (1.0 - tau->emFraction()); if (tau->emFraction() >= 1.0) { return -1.0; // electron } else { return tracksE / hadrTauP - 1.0; } }
double PFRecoTauDiscriminationByDeltaE::discriminate | ( | const reco::PFTauRef & | tau | ) |
Definition at line 42 of file PFRecoTauDiscriminationByDeltaE.cc.
{ double dE = DeltaE(tau); if(booleanOutput) return ( dE > deltaEmin && dE < deltaEmax ? 1. : 0. ); return dE; }
bool PFRecoTauDiscriminationByDeltaE::booleanOutput [private] |
Definition at line 36 of file PFRecoTauDiscriminationByDeltaE.cc.
double PFRecoTauDiscriminationByDeltaE::chargedPionMass [private] |
Definition at line 33 of file PFRecoTauDiscriminationByDeltaE.cc.
double PFRecoTauDiscriminationByDeltaE::deltaEmax [private] |
Definition at line 35 of file PFRecoTauDiscriminationByDeltaE.cc.
double PFRecoTauDiscriminationByDeltaE::deltaEmin [private] |
Definition at line 35 of file PFRecoTauDiscriminationByDeltaE.cc.