#include <PFTauQualityCutWrapper.h>
Classes | |
struct | QualityCutSet |
Public Member Functions | |
void | isolationChargedObjects (const reco::PFTau &, const reco::Vertex &, std::vector< reco::LeafCandidate > &) |
retrieve filtered isolation charged objects from the pfTau | |
void | isolationGammaObjects (const reco::PFTau &, std::vector< reco::LeafCandidate > &) |
retrieve filtered isolation gamma objects from the pfTau | |
void | isolationPUObjects (const reco::PFTau &, const reco::Vertex &, std::vector< reco::LeafCandidate > &) |
PFTauQualityCutWrapper (const edm::ParameterSet &pset) | |
void | signalChargedObjects (const reco::PFTau &, const reco::Vertex &, std::vector< reco::LeafCandidate > &) |
retrieve filtered signal charged objects from the pfTau | |
void | signalGammaObjects (const reco::PFTau &, std::vector< reco::LeafCandidate > &) |
retrieve filtered signal gamma objects from the pfTau | |
Private Attributes | |
QualityCutSet | isoQCuts |
QualityCutSet | signalQCuts |
Definition at line 13 of file PFTauQualityCutWrapper.h.
PFTauQualityCutWrapper::PFTauQualityCutWrapper | ( | const edm::ParameterSet & | pset | ) | [inline] |
Definition at line 15 of file PFTauQualityCutWrapper.h.
References PFTauQualityCutWrapper::QualityCutSet::fill(), edm::ParameterSet::getParameter(), isoQCuts, and signalQCuts.
{ isoQCuts.fill(pset.getParameter<edm::ParameterSet>("isolationQualityCuts")); signalQCuts.fill(pset.getParameter<edm::ParameterSet>("signalQualityCuts")); }
void PFTauQualityCutWrapper::isolationChargedObjects | ( | const reco::PFTau & | , |
const reco::Vertex & | , | ||
std::vector< reco::LeafCandidate > & | |||
) |
retrieve filtered isolation charged objects from the pfTau
Definition at line 10 of file PFTauQualityCutWrapper.cc.
References edm::RefVector< C, T, F >::at(), DeDxDiscriminatorTools::charge(), TauTagTools::filteredPFChargedHadrCands(), TauTagTools::filteredTracks(), i, reco::PFTau::isolationPFChargedHadrCands(), reco::BaseTau::isolationTracks(), p3, p4, reco::Vertex::position(), query::result, edm::RefVector< C, T, F >::size(), reco::Vertex::trackWeight(), and w().
{ if( isoQCuts.useTracksInsteadOfPF ) { TrackRefVector result = TauTagTools::filteredTracks(pfTau.isolationTracks(), isoQCuts.minTrackPt, isoQCuts.minTrackPixelHits, isoQCuts.minTrackHits, isoQCuts.maxTransverseImpactParameter, isoQCuts.maxTrackChi2, isoQCuts.maxDeltaZ, pv, pv.position().z() ); //???? size_t nTracks = result.size(); for(size_t iTrack = 0; iTrack < nTracks; ++iTrack) { // this sucks int charge = result[iTrack]->charge(); math::XYZVector p3 = result[iTrack]->momentum(); reco::Particle::LorentzVector p4(p3.R(), p3.x(), p3.y(), p3.z()); output.push_back(reco::LeafCandidate(charge, p4)); } } else { PFCandidateRefVector preresult = TauTagTools::filteredPFChargedHadrCands(pfTau.isolationPFChargedHadrCands(), isoQCuts.minTrackPt, isoQCuts.minTrackPixelHits, isoQCuts.minTrackHits, isoQCuts.maxTransverseImpactParameter, isoQCuts.maxTrackChi2, 10000., // isoQCuts.maxDeltaZ, pv, pv.position().z() ); //???? for(unsigned int i=0;i<preresult.size();++i) if(preresult.at(i)->trackRef().isNonnull()) { //get the vertex weight and require to be >50% float w = pv.trackWeight(preresult.at(i)->trackRef()); if(w>0.0) output.push_back(reco::LeafCandidate(preresult.at(i)->charge(), preresult[i]->p4())); } } }
void PFTauQualityCutWrapper::isolationGammaObjects | ( | const reco::PFTau & | , |
std::vector< reco::LeafCandidate > & | |||
) |
retrieve filtered isolation gamma objects from the pfTau
Definition at line 86 of file PFTauQualityCutWrapper.cc.
References DeDxDiscriminatorTools::charge(), TauTagTools::filteredPFGammaCands(), reco::PFTau::isolationPFGammaCands(), reco::tau::helpers::nGammas(), p4, query::result, and edm::RefVector< C, T, F >::size().
{ PFCandidateRefVector result = TauTagTools::filteredPFGammaCands(pfTau.isolationPFGammaCands(), isoQCuts.minGammaEt); size_t nGammas = result.size(); for(size_t iGamma = 0; iGamma < nGammas; ++iGamma) { output.push_back(reco::LeafCandidate(result[iGamma]->charge(), result[iGamma]->p4())); } }
void PFTauQualityCutWrapper::isolationPUObjects | ( | const reco::PFTau & | , |
const reco::Vertex & | , | ||
std::vector< reco::LeafCandidate > & | |||
) |
Definition at line 62 of file PFTauQualityCutWrapper.cc.
References edm::RefVector< C, T, F >::at(), TauTagTools::filteredPFChargedHadrCands(), i, reco::PFTau::isolationPFChargedHadrCands(), reco::Vertex::position(), edm::RefVector< C, T, F >::size(), reco::Vertex::trackWeight(), and w().
{ PFCandidateRefVector preresult = TauTagTools::filteredPFChargedHadrCands(pfTau.isolationPFChargedHadrCands(), isoQCuts.minGammaEt,0,0,1000.,100000, 10000., // isoQCuts.maxDeltaZ, pv, pv.position().z() ); //???? for(unsigned int i=0;i<preresult.size();++i) if(preresult.at(i)->trackRef().isNonnull()) { //get the vertex weight and require to be >50% float w = pv.trackWeight(preresult.at(i)->trackRef()); if(w==0.0) output.push_back(reco::LeafCandidate(preresult.at(i)->charge(), preresult[i]->p4())); } }
void PFTauQualityCutWrapper::signalChargedObjects | ( | const reco::PFTau & | , |
const reco::Vertex & | , | ||
std::vector< reco::LeafCandidate > & | |||
) |
retrieve filtered signal charged objects from the pfTau
Definition at line 103 of file PFTauQualityCutWrapper.cc.
References edm::RefVector< C, T, F >::at(), DeDxDiscriminatorTools::charge(), TauTagTools::filteredPFChargedHadrCands(), TauTagTools::filteredTracks(), i, p3, p4, reco::Vertex::position(), query::result, reco::PFTau::signalPFChargedHadrCands(), reco::BaseTau::signalTracks(), edm::RefVector< C, T, F >::size(), reco::Vertex::trackWeight(), and w().
{ if( signalQCuts.useTracksInsteadOfPF ) { TrackRefVector result = TauTagTools::filteredTracks(pfTau.signalTracks(), signalQCuts.minTrackPt, signalQCuts.minTrackPixelHits, signalQCuts.minTrackHits, signalQCuts.maxTransverseImpactParameter, signalQCuts.maxTrackChi2, signalQCuts.maxDeltaZ, pv, pv.position().z() ); //???? size_t nTracks = result.size(); for(size_t iTrack = 0; iTrack < nTracks; ++iTrack) { // this sucks int charge = result[iTrack]->charge(); math::XYZVector p3 = result[iTrack]->momentum(); reco::Particle::LorentzVector p4(p3.R(), p3.x(), p3.y(), p3.z()); output.push_back(reco::LeafCandidate(charge, p4)); } } else { //First perform basic filtering without vertex dz PFCandidateRefVector preresult = TauTagTools::filteredPFChargedHadrCands(pfTau.signalPFChargedHadrCands(), signalQCuts.minTrackPt, signalQCuts.minTrackPixelHits, signalQCuts.minTrackHits, signalQCuts.maxTransverseImpactParameter, signalQCuts.maxTrackChi2, 10000., // signalQCuts.maxDeltaZ, pv, pv.position().z() ); //???? //Now check the vertex association for(unsigned int i=0;i<preresult.size();++i) if(preresult.at(i)->trackRef().isNonnull()) { //get the vertex weight and require to be >50% float w = pv.trackWeight(preresult.at(i)->trackRef()); if(w>0.0) output.push_back(reco::LeafCandidate(preresult.at(i)->charge(), preresult[i]->p4())); } } }
void PFTauQualityCutWrapper::signalGammaObjects | ( | const reco::PFTau & | , |
std::vector< reco::LeafCandidate > & | |||
) |
retrieve filtered signal gamma objects from the pfTau
Definition at line 157 of file PFTauQualityCutWrapper.cc.
References DeDxDiscriminatorTools::charge(), TauTagTools::filteredPFGammaCands(), reco::tau::helpers::nGammas(), p4, query::result, reco::PFTau::signalPFGammaCands(), and edm::RefVector< C, T, F >::size().
{ PFCandidateRefVector result = TauTagTools::filteredPFGammaCands(pfTau.signalPFGammaCands(), signalQCuts.minGammaEt); size_t nGammas = result.size(); for(size_t iGamma = 0; iGamma < nGammas; ++iGamma) { output.push_back(reco::LeafCandidate(result[iGamma]->charge(), result[iGamma]->p4())); } }
Definition at line 56 of file PFTauQualityCutWrapper.h.
Referenced by PFTauQualityCutWrapper().
Definition at line 57 of file PFTauQualityCutWrapper.h.
Referenced by PFTauQualityCutWrapper().