#include <PFMuonAlgo.h>
Classes | |
class | IndexPtComparator |
class | TrackMETComparator |
class | TrackPtErrorSorter |
Private Types | |
typedef reco::Muon::MuonTrackType | MuonTrackType |
typedef reco::Muon::MuonTrackTypePair | MuonTrackTypePair |
Private Member Functions | |
bool | cleanMismeasured (reco::PFCandidate &, unsigned int) |
bool | cleanPunchThroughAndFakes (reco::PFCandidate &, reco::PFCandidateCollection *, unsigned int) |
void | estimateEventQuantities (const reco::PFCandidateCollection *) |
std::pair< double, double > | getMinMaxMET2 (const reco::PFCandidate &) |
MuonTrackTypePair | getTrackWithSmallestError (const std::vector< MuonTrackTypePair > &) |
std::vector< reco::Muon::MuonTrackTypePair > | goodMuonTracks (const reco::MuonRef &muon, bool includeSA=false) |
std::vector< reco::Muon::MuonTrackTypePair > | muonTracks (const reco::MuonRef &muon, bool includeSA=false, double dpt=1e+9) |
void | removeDeadCandidates (reco::PFCandidateCollection *, const std::vector< unsigned int > &) |
std::vector< MuonTrackTypePair > | tracksPointingAtMET (const std::vector< MuonTrackTypePair > &) |
std::vector< MuonTrackTypePair > | tracksWithBetterMET (const std::vector< MuonTrackTypePair > &, const reco::PFCandidate &) |
Definition at line 13 of file PFMuonAlgo.h.
|
private |
Definition at line 15 of file PFMuonAlgo.h.
|
private |
Definition at line 14 of file PFMuonAlgo.h.
PFMuonAlgo::PFMuonAlgo | ( | edm::ParameterSet const & | iConfig, |
bool | postMuonCleaning | ||
) |
constructor
Definition at line 25 of file PFMuonAlgo.cc.
void PFMuonAlgo::addMissingMuons | ( | edm::Handle< reco::MuonCollection > | muons, |
reco::PFCandidateCollection * | cands | ||
) |
Definition at line 738 of file PFMuonAlgo.cc.
References HLT_2018_cff::cands, changeTrack(), ALCARECOTkAlJpsiMuMu_cff::charge, cosmicRejDistance_, HLT_2018_cff::dEta, HLT_2018_cff::dPhi, HGC3DClusterGenMatchSelector_cfi::dR, goodMuonTracks(), mps_fire::i, edm::Ref< C, T, F >::isNonnull(), METX_, METY_, reco::PFCandidate::mu, reco::PFCandidate::muonRef(), PDWG_BPHSkim_cff::muons, pfAddedMuonCandidates_, pfElectronTranslator_cfi::PFCandidate, postCleaning_, mathSSE::sqrt(), reco::PFCandidate::trackRef(), PDWG_EXOHSCP_cff::tracks, tracksPointingAtMET(), and vertices_.
void PFMuonAlgo::changeTrack | ( | reco::PFCandidate & | candidate, |
const MuonTrackTypePair & | track | ||
) |
Definition at line 601 of file PFMuonAlgo.cc.
References reco::Muon::CombinedTrack, reco::Muon::DYT, HCALHighEnergyHPDFilter_cfi::energy, reco::Muon::InnerTrack, reco::PFCandidate::mu, reco::Muon::Picky, multPhiCorr_741_25nsDY_cfi::px, multPhiCorr_741_25nsDY_cfi::py, reco::LeafCandidate::setCharge(), reco::PFCandidate::setMuonTrackType(), reco::LeafCandidate::setP4(), reco::PFCandidate::setParticleType(), reco::PFCandidate::setVertexSource(), mathSSE::sqrt(), reco::Muon::TPFMS, HLT_2018_cff::track, and PbPb_ZMuSkimMuonDPG_cff::trackType.
Referenced by addMissingMuons(), cleanMismeasured(), and reconstructMuon().
|
private |
Definition at line 839 of file PFMuonAlgo.cc.
References changeTrack(), eventFractionRejection_, goodMuonTracks(), mps_fire::i, maskedIndices_, metFactorRejection_, metSigForRejection_, METX_, METY_, minPostCleaningPt_, reco::PFCandidate::muonRef(), pfCleanedTrackerAndGlobalMuonCandidates_, pfFakeMuonCleanedCandidates_, reco::LeafCandidate::pt(), reco::LeafCandidate::px(), reco::LeafCandidate::py(), mathSSE::sqrt(), sumet_, sumetPU_, PDWG_EXOHSCP_cff::tracks, and tracksWithBetterMET().
Referenced by postClean().
|
private |
Definition at line 937 of file PFMuonAlgo.cc.
References HLT_2018_cff::cands, reco::PFCandidate::elementsInBlocks(), reco::LeafCandidate::eta(), DQMScaleToClient_cfi::factor, getMinMaxMET2(), reco::PFCandidate::h, reco::PFCandidate::h0, mps_fire::i, isIsolatedMuon(), edm::Ref< C, T, F >::isNonnull(), edm::Ref< C, T, F >::key(), maskedIndices_, SiStripPI::max, metFactorFake_, metFactorHighEta_, METX_, METY_, minPostCleaningPt_, minPunchThroughEnergy_, minPunchThroughMomentum_, reco::PFCandidate::muonRef(), reco::LeafCandidate::p(), reco::PFCandidate::particleId(), pfFakeMuonCleanedCandidates_, pfPunchThroughHadronCleanedCandidates_, pfPunchThroughMuonCleanedCandidates_, reco::LeafCandidate::pt(), ptFactorHighEta_, punchThroughFactor_, punchThroughMETFactor_, reco::PFCandidate::rawEcalEnergy(), reco::PFCandidate::rawHcalEnergy(), edm::second(), sumet_, and sumetPU_.
Referenced by postClean().
|
private |
Definition at line 634 of file PFMuonAlgo.cc.
References mps_fire::i, METX_, METY_, sumet_, and sumetPU_.
Referenced by postClean().
|
static |
Definition at line 1037 of file PFMuonAlgo.cc.
References edm::ParameterSetDescription::add(), and AlCaHLTBitMon_QueryRunRegistry::string.
|
private |
Definition at line 820 of file PFMuonAlgo.cc.
References goodMuonTracks(), mps_fire::i, METX_, METY_, reco::PFCandidate::muonRef(), funct::pow(), reco::LeafCandidate::px(), reco::LeafCandidate::py(), and PDWG_EXOHSCP_cff::tracks.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 628 of file PFMuonAlgo.cc.
References MCScenario_CRAFT1_22X::sorter(), and PDWG_EXOHSCP_cff::tracks.
Referenced by reconstructMuon().
|
private |
Definition at line 487 of file PFMuonAlgo.cc.
References maxDPtOPt_, and muonTracks().
Referenced by addMissingMuons(), cleanMismeasured(), getMinMaxMET2(), hasValidTrack(), and reconstructMuon().
bool PFMuonAlgo::hasValidTrack | ( | const reco::MuonRef & | muonRef, |
bool | loose = false |
||
) |
|
static |
Definition at line 205 of file PFMuonAlgo.cc.
References muon::isGoodMuon(), edm::Ref< C, T, F >::isNonnull(), min(), TrackCollections2monitor_cff::normalizedChi2, qcdUeDQM_cfi::quality, mps_fire::result, and muon::TMLastStationAngTight.
|
static |
Definition at line 84 of file PFMuonAlgo.cc.
References cms::cuda::assert(), and reco::PFBlockElementTrack::muonRef().
Referenced by isLooseMuon().
|
static |
Definition at line 119 of file PFMuonAlgo.cc.
References muon::GlobalMuonPromptTight, muon::isGoodMuon(), edm::Ref< C, T, F >::isNonnull(), min(), qcdUeDQM_cfi::quality, mps_fire::result, and muon::TM2DCompatibilityTight.
|
static |
Definition at line 75 of file PFMuonAlgo.cc.
References cms::cuda::assert(), and reco::PFBlockElementTrack::muonRef().
Referenced by isMuon().
|
static |
Definition at line 287 of file PFMuonAlgo.cc.
References edm::Ref< C, T, F >::isNonnull(), and objects.autophobj::relIso.
|
static |
Definition at line 102 of file PFMuonAlgo.cc.
References cms::cuda::assert(), and reco::PFBlockElementTrack::muonRef().
Referenced by cleanPunchThroughAndFakes(), PFAlgo::createCandidatesHCAL(), GreedyMuonPFCandidateFilter::filter(), and isMuon().
|
static |
Definition at line 115 of file PFMuonAlgo.cc.
References isGlobalLooseMuon(), and isTrackerLooseMuon().
|
static |
Definition at line 65 of file PFMuonAlgo.cc.
References cms::cuda::assert(), and reco::PFBlockElementTrack::muonRef().
Referenced by PFAlgo::createCandidatesHCAL(), GeneralTracksImporter::importToBlock(), GeneralTracksImporterWithVeto::importToBlock(), and reconstructMuon().
|
static |
Definition at line 111 of file PFMuonAlgo.cc.
References isGlobalTightMuon(), isIsolatedMuon(), and isTrackerTightMuon().
|
static |
Definition at line 56 of file PFMuonAlgo.cc.
References cms::cuda::assert().
Referenced by PFAlgo::createCandidatesHCAL(), GeneralTracksImporter::importToBlock(), GeneralTracksImporterWithVeto::importToBlock(), PFEGammaAlgo::isMuon(), reconstructMuon(), and PFAlgo::recoTracksNotHCAL().
|
static |
Definition at line 331 of file PFMuonAlgo.cc.
References muon::GlobalMuonPromptTight, and muon::isGoodMuon().
|
static |
Definition at line 264 of file PFMuonAlgo.cc.
References muon::AllArbitrated, muon::isGoodMuon(), edm::Ref< C, T, F >::isNonnull(), qcdUeDQM_cfi::quality, and muon::TMLastStationAngTight.
|
static |
Referenced by isLooseMuon().
|
static |
Definition at line 176 of file PFMuonAlgo.cc.
References muon::AllArbitrated, muon::isGoodMuon(), edm::Ref< C, T, F >::isNonnull(), muon::TM2DCompatibilityTight, and HLT_2018_cff::track.
|
static |
Definition at line 93 of file PFMuonAlgo.cc.
References cms::cuda::assert(), and reco::PFBlockElementTrack::muonRef().
Referenced by isMuon().
|
private |
Definition at line 491 of file PFMuonAlgo.cc.
References reco::Muon::CombinedTrack, reco::Muon::DYT, reco::Muon::InnerTrack, MillePedeFileConverter_cfg::out, reco::Muon::OuterTrack, reco::Muon::Picky, and reco::Muon::TPFMS.
Referenced by goodMuonTracks(), hasValidTrack(), and reconstructMuon().
void PFMuonAlgo::postClean | ( | reco::PFCandidateCollection * | cands | ) |
Definition at line 647 of file PFMuonAlgo.cc.
References HLT_2018_cff::cands, cleanMismeasured(), cleanPunchThroughAndFakes(), cosmicRejDistance_, GlobalTrackerMuonAlignment_cfi::cosmics, estimateEventQuantities(), eventFactorCosmics_, mps_fire::i, maskedIndices_, METX_, METY_, reco::PFCandidate::mu, reco::PFCandidate::muonRef(), PDWG_BPHSkim_cff::muons, pfCleanedTrackerAndGlobalMuonCandidates_, pfCosmicsMuonCleanedCandidates_, pfFakeMuonCleanedCandidates_, pfPunchThroughHadronCleanedCandidates_, pfPunchThroughMuonCleanedCandidates_, postCleaning_, reco::LeafCandidate::pt(), reco::LeafCandidate::px(), reco::LeafCandidate::py(), removeDeadCandidates(), sumet_, sumetPU_, and vertices_.
|
static |
Definition at line 363 of file PFMuonAlgo.cc.
References gather_cfg::cout, dumpMFGeometry_cfg::delta, muon::isGoodMuon(), edm::Ref< C, T, F >::isNonnull(), SiStripPI::max, min(), particleFlowDisplacedVertex_cfi::ratio, mathSSE::sqrt(), egammaDQMOffline_cff::standAlone, muon::TM2DCompatibilityLoose, muon::TM2DCompatibilityTight, muon::TMLastStationAngLoose, muon::TMLastStationAngTight, muon::TMLastStationLoose, muon::TMLastStationOptimizedBarrelLowPtLoose, muon::TMLastStationOptimizedBarrelLowPtTight, muon::TMLastStationOptimizedLowPtLoose, muon::TMLastStationOptimizedLowPtTight, muon::TMLastStationTight, muon::TMOneStationLoose, muon::TMOneStationTight, HLT_2018_cff::track, and PbPb_ZMuSkimMuonDPG_cff::tracker.
bool PFMuonAlgo::reconstructMuon | ( | reco::PFCandidate & | candidate, |
const reco::MuonRef & | muon, | ||
bool | allowLoose = false |
||
) |
Definition at line 542 of file PFMuonAlgo.cc.
References changeTrack(), errorCompScale_, getTrackWithSmallestError(), goodMuonTracks(), reco::Muon::InnerTrack, isLooseMuon(), jets_cff::isMu, isMuon(), muonTracks(), reco::PFCandidate::setMuonRef(), muon::tevOptimized(), trackQuality_, and PbPb_ZMuSkimMuonDPG_cff::trackType.
|
private |
Definition at line 1027 of file PFMuonAlgo.cc.
References mps_fire::i, bTagCombinedSVVariables_cff::indices, N, and getGTfromDQMFile::obj.
Referenced by postClean().
void PFMuonAlgo::setInputsForCleaning | ( | reco::VertexCollection const & | vertices | ) |
Definition at line 935 of file PFMuonAlgo.cc.
References pwdgSkimBPark_cfi::vertices, and vertices_.
|
private |
Definition at line 918 of file PFMuonAlgo.cc.
References mps_fire::i, metFactorCleaning_, METX_, METY_, funct::pow(), and PDWG_EXOHSCP_cff::tracks.
Referenced by addMissingMuons().
|
private |
Definition at line 893 of file PFMuonAlgo.cc.
References eventFractionCleaning_, mps_fire::i, metFactorCleaning_, metSigForCleaning_, METX_, METY_, funct::pow(), reco::LeafCandidate::pt(), reco::LeafCandidate::px(), reco::LeafCandidate::py(), mathSSE::sqrt(), sumet_, sumetPU_, and PDWG_EXOHSCP_cff::tracks.
Referenced by cleanMismeasured().
|
inline |
Definition at line 75 of file PFMuonAlgo.h.
References eostools::move(), and pfAddedMuonCandidates_.
|
inline |
Definition at line 55 of file PFMuonAlgo.h.
References eostools::move(), and pfCosmicsMuonCleanedCandidates_.
|
inline |
Definition at line 63 of file PFMuonAlgo.h.
References eostools::move(), and pfFakeMuonCleanedCandidates_.
|
inline |
Definition at line 59 of file PFMuonAlgo.h.
References eostools::move(), and pfCleanedTrackerAndGlobalMuonCandidates_.
|
inline |
Definition at line 71 of file PFMuonAlgo.h.
References eostools::move(), and pfPunchThroughHadronCleanedCandidates_.
|
inline |
Definition at line 67 of file PFMuonAlgo.h.
References eostools::move(), and pfPunchThroughMuonCleanedCandidates_.
|
private |
Definition at line 146 of file PFMuonAlgo.h.
Referenced by addMissingMuons(), and postClean().
|
private |
Definition at line 128 of file PFMuonAlgo.h.
Referenced by reconstructMuon().
|
private |
Definition at line 133 of file PFMuonAlgo.h.
Referenced by postClean().
|
private |
Definition at line 131 of file PFMuonAlgo.h.
Referenced by tracksWithBetterMET().
|
private |
Definition at line 137 of file PFMuonAlgo.h.
Referenced by cleanMismeasured().
|
private |
Definition at line 118 of file PFMuonAlgo.h.
Referenced by cleanMismeasured(), cleanPunchThroughAndFakes(), and postClean().
|
private |
Definition at line 125 of file PFMuonAlgo.h.
Referenced by goodMuonTracks().
|
private |
Definition at line 136 of file PFMuonAlgo.h.
Referenced by tracksPointingAtMET(), and tracksWithBetterMET().
|
private |
Definition at line 141 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 139 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 138 of file PFMuonAlgo.h.
Referenced by cleanMismeasured().
|
private |
Definition at line 134 of file PFMuonAlgo.h.
Referenced by tracksWithBetterMET().
|
private |
Definition at line 135 of file PFMuonAlgo.h.
Referenced by cleanMismeasured().
|
private |
Definition at line 150 of file PFMuonAlgo.h.
Referenced by addMissingMuons(), cleanMismeasured(), cleanPunchThroughAndFakes(), estimateEventQuantities(), getMinMaxMET2(), postClean(), tracksPointingAtMET(), and tracksWithBetterMET().
|
private |
Definition at line 151 of file PFMuonAlgo.h.
Referenced by addMissingMuons(), cleanMismeasured(), cleanPunchThroughAndFakes(), estimateEventQuantities(), getMinMaxMET2(), postClean(), tracksPointingAtMET(), and tracksWithBetterMET().
|
private |
Definition at line 132 of file PFMuonAlgo.h.
Referenced by cleanMismeasured(), and cleanPunchThroughAndFakes().
|
private |
Definition at line 143 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 142 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
the collection of added muon candidates
Definition at line 116 of file PFMuonAlgo.h.
Referenced by addMissingMuons(), and transferAddedMuonCandidates().
|
private |
the collection of tracker/global cleaned muon candidates
Definition at line 108 of file PFMuonAlgo.h.
Referenced by cleanMismeasured(), postClean(), and transferCleanedTrackerAndGlobalCandidates().
|
private |
the collection of cosmics cleaned muon candidates
Definition at line 106 of file PFMuonAlgo.h.
Referenced by postClean(), and transferCleanedCosmicCandidates().
|
private |
the collection of fake cleaned muon candidates
Definition at line 110 of file PFMuonAlgo.h.
Referenced by cleanMismeasured(), cleanPunchThroughAndFakes(), postClean(), and transferCleanedFakeCandidates().
|
private |
the collection of punch-through cleaned neutral hadron candidates
Definition at line 114 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes(), postClean(), and transferPunchThroughCleanedHadronCandidates().
|
private |
the collection of punch-through cleaned muon candidates
Definition at line 112 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes(), postClean(), and transferPunchThroughCleanedMuonCandidates().
|
private |
Definition at line 130 of file PFMuonAlgo.h.
Referenced by addMissingMuons(), and postClean().
|
private |
Definition at line 140 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 144 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 145 of file PFMuonAlgo.h.
Referenced by cleanPunchThroughAndFakes().
|
private |
Definition at line 149 of file PFMuonAlgo.h.
Referenced by cleanMismeasured(), cleanPunchThroughAndFakes(), estimateEventQuantities(), postClean(), and tracksWithBetterMET().
|
private |
Definition at line 148 of file PFMuonAlgo.h.
Referenced by cleanMismeasured(), cleanPunchThroughAndFakes(), estimateEventQuantities(), postClean(), and tracksWithBetterMET().
|
private |
Definition at line 127 of file PFMuonAlgo.h.
Referenced by reconstructMuon().
|
private |
Definition at line 121 of file PFMuonAlgo.h.
Referenced by addMissingMuons(), postClean(), and setInputsForCleaning().