33 moduleLabel_(pset.getParameter<
std::
string>(
"@module_label")),
37 "ApplyDiscriminationByTrackerIsolation");
39 "ApplyDiscriminationByECALIsolation");
41 calculateWeights_ = pset.
getParameter<
bool>(
"ApplyDiscriminationByWeightedECALIsolation");
46 weightGammas_ = pset.
getParameter<
double>(
"WeightECALIsolation");
49 minPtForNoIso_ = pset.
getParameter<
double>(
"minTauPtForNoIso");
51 applyOccupancyCut_ = pset.
getParameter<
bool>(
"applyOccupancyCut");
52 maximumOccupancy_ = pset.
getParameter<uint32_t>(
"maximumOccupancy");
54 applySumPtCut_ = pset.
getParameter<
bool>(
"applySumPtCut");
55 maximumSumPt_ = pset.
getParameter<
double>(
"maximumSumPtCut");
57 applyRelativeSumPtCut_ = pset.
getParameter<
bool>(
"applyRelativeSumPtCut");
58 maximumRelativeSumPt_ = pset.
getParameter<
double>(
"relativeSumPtCut");
59 offsetRelativeSumPt_ = pset.
getParameter<
double>(
"relativeSumPtOffset");
61 storeRawOccupancy_ = pset.
getParameter<
bool>(
"storeRawOccupancy");
62 storeRawSumPt_ = pset.
getParameter<
bool>(
"storeRawSumPt");
63 storeRawPUsumPt_ = pset.
getParameter<
bool>(
"storeRawPUsumPt");
64 storeRawFootprintCorrection_ = pset.
getParameter<
bool>(
"storeRawFootprintCorrection");
65 storeRawPhotonSumPt_outsideSignalCone_ = pset.
getParameter<
bool>(
"storeRawPhotonSumPt_outsideSignalCone");
69 if ( applySumPtCut_ || applyOccupancyCut_ || applyRelativeSumPtCut_ ) {
70 if ( storeRawSumPt_ || storeRawOccupancy_ || storeRawPUsumPt_ ) {
72 <<
"A 'store raw' and a 'apply cut' option have been set to true " 73 <<
"simultaneously. These options are mutually exclusive.";
78 if ( includeGammas_ && calculateWeights_ ) {
80 <<
"Both 'ApplyDiscriminationByECALIsolation' and 'ApplyDiscriminationByWeightedECALIsolation' " 81 <<
"have been set to true. These options are mutually exclusive.";
85 int numStoreOptions = 0;
86 if ( storeRawSumPt_ ) ++numStoreOptions;
87 if ( storeRawOccupancy_ ) ++numStoreOptions;
88 if ( storeRawPUsumPt_ ) ++numStoreOptions;
89 if ( storeRawFootprintCorrection_ ) ++numStoreOptions;
90 if ( storeRawPhotonSumPt_outsideSignalCone_ ) ++numStoreOptions;
91 if ( numStoreOptions > 1 ) {
93 <<
"Multiple 'store sum pt' and/or 'store occupancy' options are set." 94 <<
" These options are mutually exclusive.";
97 customIsoCone_ = pset.
getParameter<
double>(
"customOuterCone");
99 applyPhotonPtSumOutsideSignalConeCut_ = pset.
getParameter<
bool>(
"applyPhotonPtSumOutsideSignalConeCut");
100 if ( applyPhotonPtSumOutsideSignalConeCut_ ) {
101 maxAbsPhotonSumPt_outsideSignalCone_ = pset.
getParameter<
double>(
"maxAbsPhotonSumPt_outsideSignalCone");
102 maxRelPhotonSumPt_outsideSignalCone_ = pset.
getParameter<
double>(
"maxRelPhotonSumPt_outsideSignalCone");
105 applyFootprintCorrection_ = pset.
getParameter<
bool>(
"applyFootprintCorrection");
106 if ( applyFootprintCorrection_ || storeRawFootprintCorrection_ ) {
108 for ( edm::VParameterSet::const_iterator cfgFootprintCorrection = cfgFootprintCorrections.begin();
109 cfgFootprintCorrection != cfgFootprintCorrections.end(); ++cfgFootprintCorrection ) {
113 footprintCorrections_.push_back(
std::move(footprintCorrection));
119 "isolationQualityCuts");
123 vertexAssociator_.reset(
126 applyDeltaBeta_ = pset.
getParameter<
bool>(
"applyDeltaBetaCorrection");
128 if ( applyDeltaBeta_ || calculateWeights_ ) {
131 std::pair<edm::ParameterSet, edm::ParameterSet> puFactorizedIsoQCuts =
138 if ( deltaBetaPUTrackPtCutOverride ) {
140 puFactorizedIsoQCuts.second.addParameter<
double>(
145 puFactorizedIsoQCuts.second.addParameter<
double>(
151 puFactorizedIsoQCuts.first));
154 puFactorizedIsoQCuts.second));
157 pfCand_token = consumes<edm::View<reco::Candidate> >(pfCandSrc_);
159 vertex_token = consumes<reco::VertexCollection>(vertexSrc_);
161 "isoConeSizeForDeltaBeta");
164 deltaBetaFormula_.reset(
165 new TFormula(
"DB_corr", deltaBetaFactorFormula.c_str()));
168 applyRhoCorrection_ = pset.
getParameter<
bool>(
"applyRhoCorrection");
169 if ( applyRhoCorrection_ ) {
171 rho_token=consumes<double>(rhoProducer_);
172 rhoConeSize_ = pset.
getParameter<
double>(
"rhoConeSize");
173 rhoUEOffsetCorrection_ =
176 useAllPFCands_ = pset.
getParameter<
bool>(
"UseAllPFCandsForWeights");
186 double discriminate(
const PFTauRef& pfTau)
const override;
188 inline double weightedSum(
const std::vector<CandidatePtr>& inColl_,
double eta,
double phi)
const {
190 for (
auto const & inObj_ : inColl_){
191 double sum = (inObj_->pt()*inObj_->pt())/(
deltaR2(eta,phi,inObj_->eta(),inObj_->phi()));
192 if(sum > 1.0) out *= sum;
203 std::auto_ptr<tau::RecoTauQualityCuts>
qcuts_;
234 : selection_(selection),
287 vertexAssociator_->setEvent(event);
291 if ( applyDeltaBeta_ || calculateWeights_ ) {
294 event.getByToken(pfCand_token, pfCandidates);
295 chargedPFCandidatesInEvent_.clear();
296 chargedPFCandidatesInEvent_.reserve(pfCandidates->size());
297 size_t numPFCandidates = pfCandidates->size();
298 for (
size_t i = 0;
i < numPFCandidates; ++
i ) {
300 if ( pfCandidate->
charge() != 0 ) {
301 chargedPFCandidatesInEvent_.push_back(pfCandidate);
307 event.getByToken(vertex_token, vertices);
308 size_t nVtxThisEvent = vertices->size();
309 deltaBetaFactorThisEvent_ = deltaBetaFormula_->Eval(nVtxThisEvent);
312 if ( applyRhoCorrection_ ) {
314 event.getByToken(rho_token, rhoHandle_);
315 rhoThisEvent_ = (*rhoHandle_ - rhoUEOffsetCorrection_)*
316 (3.14159)*rhoConeSize_*rhoConeSize_;
323 LogDebug(
"discriminate") <<
" tau: Pt = " << pfTau->pt() <<
", eta = " << pfTau->eta() <<
", phi = " << pfTau->phi();
324 LogDebug(
"discriminate") << *pfTau ;
327 std::vector<CandidatePtr> isoCharged_;
328 std::vector<CandidatePtr> isoNeutral_;
329 std::vector<CandidatePtr> isoPU_;
331 std::vector<CandidatePtr> chPV_;
332 isoCharged_.
reserve(pfTau->isolationChargedHadrCands().size());
333 isoNeutral_.reserve(pfTau->isolationGammaCands().size());
334 isoPU_.reserve(
std::min(100UL, chargedPFCandidatesInEvent_.size()));
335 isoNeutralWeight_.
reserve(pfTau->isolationGammaCands().size());
337 chPV_.reserve(
std::min(50UL, chargedPFCandidatesInEvent_.size()));
345 LogTrace(
"discriminate") <<
"pv: x = " << pv->position().x() <<
", y = " << pv->position().y() <<
", z = " << pv->position().z() ;
347 LogTrace(
"discriminate") <<
"pv: N/A" ;
349 if ( pfTau->leadChargedHadrCand().
isNonnull() ) {
350 LogTrace(
"discriminate") <<
"leadPFChargedHadron:" 351 <<
" Pt = " << pfTau->leadChargedHadrCand()->pt() <<
"," 352 <<
" eta = " << pfTau->leadChargedHadrCand()->eta() <<
"," 353 <<
" phi = " << pfTau->leadChargedHadrCand()->phi() ;
355 LogTrace(
"discriminate") <<
"leadPFChargedHadron: N/A" ;
363 qcuts_->setLeadTrack(*pfTau->leadChargedHadrCand());
365 if ( applyDeltaBeta_ || calculateWeights_) {
366 pileupQcutsGeneralQCuts_->setPV(pv);
367 pileupQcutsGeneralQCuts_->setLeadTrack(*pfTau->leadChargedHadrCand());
368 pileupQcutsPUTrackSelection_->setPV(pv);
369 pileupQcutsPUTrackSelection_->setLeadTrack(*pfTau->leadChargedHadrCand());
373 if ( includeTracks_ ) {
374 for(
auto const &
cand : pfTau->isolationChargedHadrCands() ) {
375 if ( qcuts_->filterCandRef(
cand) ) {
376 LogTrace(
"discriminate") <<
"adding charged iso cand with pt " <<
cand->pt() ;
377 isoCharged_.push_back(
cand);
381 if ( includeGammas_ || calculateWeights_ ) {
382 for(
auto const &
cand : pfTau->isolationGammaCands() ) {
383 if ( qcuts_->filterCandRef(
cand) ) {
384 LogTrace(
"discriminate") <<
"adding neutral iso cand with pt " <<
cand->pt() ;
385 isoNeutral_.push_back(
cand);
394 if ( applyDeltaBeta_ || calculateWeights_) {
397 std::cout <<
"Initial PFCands: " << chargedPFCandidatesInEvent_.size() << std::endl;
400 std::vector<CandidatePtr> allPU =
401 pileupQcutsPUTrackSelection_->filterCandRefs(
402 chargedPFCandidatesInEvent_,
true);
404 std::vector<CandidatePtr> allNPU =
405 pileupQcutsPUTrackSelection_->filterCandRefs(
406 chargedPFCandidatesInEvent_);
407 LogTrace(
"discriminate") <<
"After track cuts: " << allPU.size() ;
410 if ( !useAllPFCands_ ) {
411 std::vector<CandidatePtr> cleanPU =
412 pileupQcutsGeneralQCuts_->filterCandRefs(allPU);
414 std::vector<CandidatePtr> cleanNPU =
415 pileupQcutsGeneralQCuts_->filterCandRefs(allNPU);
417 LogTrace(
"discriminate") <<
"After cleaning cuts: " << cleanPU.size() ;
420 DRFilter deltaBetaFilter(pfTau->p4(), 0, deltaBetaCollectionCone_);
421 for (
auto const &
cand : cleanPU ) {
422 if ( deltaBetaFilter(
cand) ) isoPU_.push_back(
cand);
425 for (
auto const &
cand : cleanNPU ) {
426 if ( deltaBetaFilter(
cand) ) chPV_.push_back(
cand);
428 LogTrace(
"discriminate") <<
"After cone cuts: " << isoPU_.size() <<
" " << chPV_.size() ;
435 if ( calculateWeights_ ) {
436 for (
auto const & isoObject : isoNeutral_ ) {
437 if ( isoObject->charge() != 0 ) {
443 double eta = isoObject->eta();
444 double phi = isoObject->phi();
445 double sumNPU = 0.5*
log(weightedSum(chPV_, eta, phi));
447 double sumPU = 0.5*
log(weightedSum(isoPU_, eta, phi));
449 if ( (sumNPU + sumPU) > 0 ) neutral.
setP4(((sumNPU)/(sumNPU + sumPU))*neutral.
p4());
456 if ( customIsoCone_ >= 0. ) {
457 DRFilter
filter(pfTau->p4(), 0, customIsoCone_);
458 DRFilter2 filter2(pfTau->p4(), 0, customIsoCone_);
459 std::vector<CandidatePtr> isoCharged_filter;
460 std::vector<CandidatePtr> isoNeutral_filter;
463 for(
auto const & isoObject : isoCharged_ ) {
466 if(!calculateWeights_){
467 for(
auto const & isoObject : isoNeutral_ ) {
468 if (
filter(isoObject) ) isoNeutral_filter.push_back(isoObject);
470 isoNeutral_ = isoNeutral_filter;
472 for(
auto const & isoObject : isoNeutralWeight_){
473 if ( filter2(isoObject) ) isoNeutralWeight_filter.
push_back(isoObject);
475 isoNeutralWeight_ = isoNeutralWeight_filter;
477 isoCharged_ = isoCharged_filter;
480 bool failsOccupancyCut =
false;
481 bool failsSumPtCut =
false;
482 bool failsRelativeSumPtCut =
false;
485 int neutrals = isoNeutral_.
size();
487 if ( applyDeltaBeta_ ) {
488 neutrals -= TMath::Nint(deltaBetaFactorThisEvent_*isoPU_.size());
490 if ( neutrals < 0 ) {
494 size_t nOccupants = isoCharged_.size() + neutrals;
496 failsOccupancyCut = ( nOccupants > maximumOccupancy_ );
498 double footprintCorrection_value = 0.;
499 if ( applyFootprintCorrection_ || storeRawFootprintCorrection_ ) {
500 for ( std::vector<std::unique_ptr<FootprintCorrection> >::const_iterator
footprintCorrection = footprintCorrections_.begin();
502 if ( (*footprintCorrection)->selection_(*pfTau) ) {
503 footprintCorrection_value = (*footprintCorrection)->offset_(*pfTau);
511 if ( applySumPtCut_ || applyRelativeSumPtCut_ || storeRawSumPt_ || storeRawPUsumPt_ ) {
512 double chargedPt = 0.;
513 double neutralPt = 0.;
514 double weightedNeutralPt = 0.;
515 for (
auto const & isoObject : isoCharged_ ) {
516 chargedPt += isoObject->pt();
518 if ( !calculateWeights_ ) {
519 for (
auto const & isoObject : isoNeutral_ ) {
520 neutralPt += isoObject->pt();
523 for (
auto const & isoObject : isoNeutralWeight_ ) {
524 weightedNeutralPt += isoObject.pt();
527 for (
auto const & isoObject : isoPU_ ) {
528 puPt += isoObject->pt();
530 LogTrace(
"discriminate") <<
"chargedPt = " << chargedPt ;
531 LogTrace(
"discriminate") <<
"neutralPt = " << neutralPt ;
532 LogTrace(
"discriminate") <<
"weighted neutral Pt = " << weightedNeutralPt ;
533 LogTrace(
"discriminate") <<
"puPt = " << puPt <<
" (delta-beta corr. = " << (deltaBetaFactorThisEvent_*puPt) <<
")" ;
535 if ( calculateWeights_ ) {
536 neutralPt = weightedNeutralPt;
539 if ( applyDeltaBeta_ ) {
540 neutralPt -= (deltaBetaFactorThisEvent_*puPt);
543 if ( applyFootprintCorrection_ ) {
544 neutralPt -= footprintCorrection_value;
547 if ( applyRhoCorrection_ ) {
548 neutralPt -= rhoThisEvent_;
551 if ( neutralPt < 0. ) {
555 totalPt = chargedPt + weightGammas_ * neutralPt;
556 LogTrace(
"discriminate") <<
"totalPt = " << totalPt <<
" (cut = " << maximumSumPt_ <<
")" ;
558 failsSumPtCut = (totalPt > maximumSumPt_);
561 failsRelativeSumPtCut = (totalPt > ((pfTau->pt() - offsetRelativeSumPt_)*maximumRelativeSumPt_));
564 bool failsPhotonPtSumOutsideSignalConeCut =
false;
565 double photonSumPt_outsideSignalCone = 0.;
566 if ( applyPhotonPtSumOutsideSignalConeCut_ || storeRawPhotonSumPt_outsideSignalCone_ ) {
567 const std::vector<reco::CandidatePtr>& signalGammas = pfTau->signalGammaCands();
568 for ( std::vector<reco::CandidatePtr>::const_iterator signalGamma = signalGammas.begin();
569 signalGamma != signalGammas.end(); ++signalGamma ) {
570 double dR =
deltaR(pfTau->eta(), pfTau->phi(), (*signalGamma)->eta(), (*signalGamma)->phi());
571 if ( dR > pfTau->signalConeSize() ) photonSumPt_outsideSignalCone += (*signalGamma)->pt();
573 if ( photonSumPt_outsideSignalCone > maxAbsPhotonSumPt_outsideSignalCone_ || photonSumPt_outsideSignalCone > (maxRelPhotonSumPt_outsideSignalCone_*pfTau->pt()) ) {
574 failsPhotonPtSumOutsideSignalConeCut =
true;
578 bool fails = (applyOccupancyCut_ && failsOccupancyCut) ||
579 (applySumPtCut_ && failsSumPtCut) ||
580 (applyRelativeSumPtCut_ && failsRelativeSumPtCut) ||
581 (applyPhotonPtSumOutsideSignalConeCut_ && failsPhotonPtSumOutsideSignalConeCut);
584 if (pfTau->pt() > minPtForNoIso_ && minPtForNoIso_ > 0.){
586 LogDebug(
"discriminate") <<
"tau pt = " << pfTau->pt() <<
"\t min cutoff pt = " << minPtForNoIso_ ;
590 if ( storeRawSumPt_ ) {
592 }
else if ( storeRawPUsumPt_ ) {
593 if ( applyDeltaBeta_ )
return puPt;
594 else if ( applyRhoCorrection_ )
return rhoThisEvent_;
596 }
else if ( storeRawOccupancy_ ) {
598 }
else if ( storeRawFootprintCorrection_ ) {
599 return footprintCorrection_value;
600 }
else if ( storeRawPhotonSumPt_outsideSignalCone_ ) {
601 return photonSumPt_outsideSignalCone;
603 return (fails ? 0. : 1.);
611 desc.
add<
bool>(
"storeRawFootprintCorrection",
false);
613 desc.
add<
bool>(
"storeRawOccupancy",
false);
614 desc.
add<
double>(
"maximumSumPtCut", 6.0);
618 pset_signalQualityCuts.
add<
double>(
"maxDeltaZ", 0.4);
619 pset_signalQualityCuts.
add<
double>(
"minTrackPt", 0.5);
620 pset_signalQualityCuts.
add<
double>(
"minTrackVertexWeight", -1.0);
621 pset_signalQualityCuts.
add<
double>(
"maxTrackChi2", 100.0);
622 pset_signalQualityCuts.
add<
unsigned int>(
"minTrackPixelHits", 0);
623 pset_signalQualityCuts.
add<
double>(
"minGammaEt", 1.0);
624 pset_signalQualityCuts.
add<
unsigned int>(
"minTrackHits", 3);
625 pset_signalQualityCuts.
add<
double>(
"minNeutralHadronEt", 30.0);
626 pset_signalQualityCuts.
add<
double>(
"maxTransverseImpactParameter", 0.1);
627 pset_signalQualityCuts.
addOptional<
bool>(
"useTracksInsteadOfPFHadrons");
630 pset_vxAssocQualityCuts.
add<
double>(
"minTrackPt", 0.5);
631 pset_vxAssocQualityCuts.add<
double>(
"minTrackVertexWeight", -1.0);
632 pset_vxAssocQualityCuts.add<
double>(
"maxTrackChi2", 100.0);
633 pset_vxAssocQualityCuts.add<
unsigned int>(
"minTrackPixelHits", 0);
634 pset_vxAssocQualityCuts.add<
double>(
"minGammaEt", 1.0);
635 pset_vxAssocQualityCuts.add<
unsigned int>(
"minTrackHits", 3);
636 pset_vxAssocQualityCuts.add<
double>(
"maxTransverseImpactParameter", 0.1);
637 pset_vxAssocQualityCuts.addOptional<
bool>(
"useTracksInsteadOfPFHadrons");
640 pset_isolationQualityCuts.
add<
double>(
"maxDeltaZ", 0.2);
641 pset_isolationQualityCuts.add<
double>(
"minTrackPt", 1.0);
642 pset_isolationQualityCuts.add<
double>(
"minTrackVertexWeight", -1.0);
643 pset_isolationQualityCuts.add<
double>(
"maxTrackChi2", 100.0);
644 pset_isolationQualityCuts.add<
unsigned int>(
"minTrackPixelHits", 0);
645 pset_isolationQualityCuts.add<
double>(
"minGammaEt", 1.5);
646 pset_isolationQualityCuts.add<
unsigned int>(
"minTrackHits", 8);
647 pset_isolationQualityCuts.add<
double>(
"maxTransverseImpactParameter", 0.03);
648 pset_isolationQualityCuts.addOptional<
bool>(
"useTracksInsteadOfPFHadrons");
654 pset_qualityCuts.
add<
std::string>(
"leadingTrkOrPFCandOption",
"leadPFCand");
655 pset_qualityCuts.add<
std::string>(
"pvFindingAlgo",
"closestInDeltaZ");
657 pset_qualityCuts.add<
bool>(
"vertexTrackFiltering",
false);
658 pset_qualityCuts.add<
bool>(
"recoverLeadingTrk",
false);
663 desc.
add<
double>(
"minTauPtForNoIso", -99.0);
664 desc.
add<
double>(
"maxAbsPhotonSumPt_outsideSignalCone", 1000000000.0);
666 desc.
add<
bool>(
"applySumPtCut",
false);
667 desc.
add<
double>(
"rhoConeSize", 0.5);
668 desc.
add<
bool>(
"ApplyDiscriminationByTrackerIsolation",
true);
669 desc.
add<
bool>(
"storeRawPhotonSumPt_outsideSignalCone",
false);
676 desc.
addVPSet(
"footprintCorrections", vpsd1);
680 desc.
add<
bool>(
"applyFootprintCorrection",
false);
681 desc.
add<
bool>(
"UseAllPFCandsForWeights",
false);
682 desc.
add<
double>(
"relativeSumPtCut", 0.0);
688 psd1.
add<
double>(
"cut");
704 psd1.
add<
double>(
"cut");
717 psd1.
add<
double>(
"cut");
724 desc.
add<
unsigned int>(
"maximumOccupancy", 0);
725 desc.
add<
int>(
"verbosity", 0);
727 desc.
add<
bool>(
"applyOccupancyCut",
true);
728 desc.
add<
bool>(
"applyDeltaBetaCorrection",
false);
729 desc.
add<
bool>(
"applyRelativeSumPtCut",
false);
730 desc.
add<
bool>(
"storeRawPUsumPt",
false);
731 desc.
add<
bool>(
"applyPhotonPtSumOutsideSignalConeCut",
false);
732 desc.
add<
bool>(
"deltaBetaPUTrackPtCutOverride",
false);
733 desc.
add<
bool>(
"ApplyDiscriminationByWeightedECALIsolation",
false);
734 desc.
add<
bool>(
"storeRawSumPt",
false);
735 desc.
add<
bool>(
"ApplyDiscriminationByECALIsolation",
true);
736 desc.
add<
bool>(
"applyRhoCorrection",
false);
738 desc.
add<
double>(
"WeightECALIsolation", 1.0);
739 desc.
add<
double>(
"rhoUEOffsetCorrection", 1.0);
740 desc.
add<
double>(
"maxRelPhotonSumPt_outsideSignalCone", 0.1);
741 desc.
add<
double>(
"deltaBetaPUTrackPtCutOverride_val", -1.5);
742 desc.
add<
double>(
"isoConeSizeForDeltaBeta", 0.5);
743 desc.
add<
double>(
"relativeSumPtOffset", 0.0);
744 desc.
add<
double>(
"customOuterCone", -1.0);
747 descriptions.
add(
"pfRecoTauDiscriminationByIsolation", desc);
deltaBetaPUTrackPtCutOverride
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
PFRecoTauDiscriminationByIsolation(const edm::ParameterSet &pset)
T getParameter(std::string const &) const
ParameterDescriptionBase * addOptional(U const &iLabel, T const &value)
edm::EDGetTokenT< double > rho_token
bool isNonnull() const
Checks for non-null.
ParameterDescriptionBase * addVPSet(U const &iLabel, ParameterSetDescription const &validator, std::vector< ParameterSet > const &defaults)
std::auto_ptr< tau::RecoTauQualityCuts > pileupQcutsGeneralQCuts_
deltaBetaPUTrackPtCutOverride_val
bool applyPhotonPtSumOutsideSignalConeCut_
std::vector< ParameterSet > VParameterSet
edm::EDGetTokenT< edm::View< reco::Candidate > > pfCand_token
void beginEvent(const edm::Event &evt, const edm::EventSetup &evtSetup) override
double rhoUEOffsetCorrection_
double maximumRelativeSumPt_
bool applyRelativeSumPtCut_
~PFRecoTauDiscriminationByIsolation() override
double rhoCorrectionThisEvent_
double deltaBetaFactorThisEvent_
bool applyFootprintCorrection_
double offsetRelativeSumPt_
std::vector< std::unique_ptr< FootprintCorrection > > footprintCorrections_
#define DEFINE_FWK_MODULE(type)
const LorentzVector & p4() const final
four-momentum Lorentz vector
bool storeRawFootprintCorrection_
std::pair< edm::ParameterSet, edm::ParameterSet > factorizePUQCuts(const edm::ParameterSet &inputSet)
ParameterDescriptionBase * add(U const &iLabel, T const &value)
double weightedSum(const std::vector< CandidatePtr > &inColl_, double eta, double phi) const
std::auto_ptr< tau::RecoTauQualityCuts > qcuts_
std::auto_ptr< tau::RecoTauQualityCuts > pileupQcutsPUTrackSelection_
constexpr auto deltaR(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
double deltaBetaCollectionCone_
std::vector< reco::CandidatePtr > chargedPFCandidatesInEvent_
constexpr auto deltaR2(const T1 &t1, const T2 &t2) -> decltype(t1.eta())
double discriminate(const PFTauRef &pfTau) const override
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
ParameterSet const & getParameterSet(std::string const &) const
void add(std::string const &label, ParameterSetDescription const &psetDescription)
uint32_t maximumOccupancy_
virtual int charge() const =0
electric charge
double maxRelPhotonSumPt_outsideSignalCone_
std::auto_ptr< tau::RecoTauVertexAssociator > vertexAssociator_
edm::InputTag rhoProducer_
std::auto_ptr< TFormula > deltaBetaFormula_
double maxAbsPhotonSumPt_outsideSignalCone_
bool storeRawPhotonSumPt_outsideSignalCone_
edm::ParameterSet qualityCutsPSet_
void setP4(const LorentzVector &p4) final
set 4-momentum
edm::EDGetTokenT< reco::VertexCollection > vertex_token