|
|
Producer for particle flow reconstructed particles (PFCandidates)
More...
Producer for particle flow reconstructed particles (PFCandidates)
This producer makes use of PFAlgo, the particle flow algorithm.
- Author
- Colin Bernet
- Date
- July 2006
Definition at line 37 of file PFProducer.cc.
◆ PFProducer()
Definition at line 107 of file PFProducer.cc.
112 iConfig.
getParameter<std::vector<double>>(
"calibHF_eta_step"),
113 iConfig.
getParameter<std::vector<double>>(
"calibHF_a_EMonly"),
114 iConfig.
getParameter<std::vector<double>>(
"calibHF_b_HADonly"),
115 iConfig.
getParameter<std::vector<double>>(
"calibHF_a_EMHAD"),
116 iConfig.
getParameter<std::vector<double>>(
"calibHF_b_EMHAD")),
121 iConfig.
getParameter<std::vector<double>>(
"resolHF_square"),
132 if (iConfig.
existsAs<
bool>(
"useEGammaFilters")) {
146 produces<reco::PFCandidateCollection>(
"CleanedCosmicsMuons");
147 produces<reco::PFCandidateCollection>(
"CleanedTrackerAndGlobalMuons");
148 produces<reco::PFCandidateCollection>(
"CleanedFakeMuons");
149 produces<reco::PFCandidateCollection>(
"CleanedPunchThroughMuons");
150 produces<reco::PFCandidateCollection>(
"CleanedPunchThroughNeutralHadrons");
151 produces<reco::PFCandidateCollection>(
"AddedMuonsAndHadrons");
168 pfegamma_ = std::make_unique<PFEGammaFilters>(pfEGammaFiltersParams);
209 std::vector<edm::InputTag>
tags = iConfig.
getParameter<std::vector<edm::InputTag>>(
"cleanedHF");
210 for (
unsigned int i = 0;
i <
tags.size(); ++
i)
◆ beginRun()
◆ fillDescriptions()
Definition at line 319 of file PFProducer.cc.
323 desc.addUntracked<
bool>(
"verbose",
false);
324 desc.addUntracked<
bool>(
"debug",
false);
331 desc.add<
bool>(
"postMuonCleaning",
true);
341 desc.add<
bool>(
"useVerticesForNeutral",
true);
344 desc.add<
bool>(
"useHO",
true);
351 desc.add<
bool>(
"useEGammaElectrons",
true);
354 desc.add<
bool>(
"useEGammaFilters",
true);
355 desc.add<
bool>(
"useProtectionsForJetMET",
true);
364 desc.add<std::vector<double>>(
"muon_HCAL", {3.0, 3.0});
365 desc.add<std::vector<double>>(
"muon_ECAL", {0.5, 0.5});
366 desc.add<std::vector<double>>(
"muon_HO", {0.9, 0.9});
375 desc.add<
bool>(
"rejectTracks_Bad",
true);
376 desc.add<
bool>(
"rejectTracks_Step45",
true);
378 desc.add<
bool>(
"usePFNuclearInteractions",
true);
379 desc.add<
bool>(
"usePFConversions",
true);
380 desc.add<
bool>(
"usePFDecays",
false);
382 desc.add<
double>(
"dptRel_DispVtx", 10.0);
390 desc.add<
double>(
"nsigma_TRACK", 1.0)->setComment(
"Number of sigmas for fake track detection");
392 desc.add<
double>(
"pt_Error", 1.0)
393 ->setComment(
"Absolute pt error to detect fake tracks in the first three iterations");
394 desc.add<std::vector<double>>(
"factors_45", {10.0, 100.0})
395 ->setComment(
"Factors to be applied in the four and fifth steps to the pt error");
398 desc.add<
double>(
"goodTrackDeadHcal_ptErrRel", 0.2)->setComment(
"trackRef->ptError()/trackRef->pt() < X");
399 desc.add<
double>(
"goodTrackDeadHcal_chi2n", 5)->setComment(
"trackRef->normalizedChi2() < X");
400 desc.add<
unsigned int>(
"goodTrackDeadHcal_layers", 4)
401 ->setComment(
"trackRef->hitPattern().trackerLayersWithMeasurement() >= X");
402 desc.add<
double>(
"goodTrackDeadHcal_validFr", 0.5)->setComment(
"trackRef->validFraction() > X");
403 desc.add<
double>(
"goodTrackDeadHcal_dxy", 0.5)->setComment(
"abs(trackRef->dxy(primaryVertex_.position())) < X [cm]");
405 desc.add<
double>(
"goodPixelTrackDeadHcal_minEta", 2.3)->setComment(
"abs(trackRef->eta()) > X");
406 desc.add<
double>(
"goodPixelTrackDeadHcal_maxPt", 50.0)->setComment(
"trackRef->ptError()/trackRef->pt() < X");
407 desc.add<
double>(
"goodPixelTrackDeadHcal_ptErrRel", 1.0)->setComment(
"trackRef->ptError()/trackRef->pt() < X");
408 desc.add<
double>(
"goodPixelTrackDeadHcal_chi2n", 2)->setComment(
"trackRef->normalizedChi2() < X");
409 desc.add<
int>(
"goodPixelTrackDeadHcal_maxLost3Hit", 0)
411 "max missing outer hits for a track with 3 valid pixel layers (can set to -1 to reject all these tracks)");
412 desc.add<
int>(
"goodPixelTrackDeadHcal_maxLost4Hit", 1)
413 ->setComment(
"max missing outer hits for a track with >= 4 valid pixel layers");
414 desc.add<
double>(
"goodPixelTrackDeadHcal_dxy", 0.02)
415 ->setComment(
"abs(trackRef->dxy(primaryVertex_.position())) < X [cm] ");
416 desc.add<
double>(
"goodPixelTrackDeadHcal_dz", 0.05)
417 ->setComment(
"abs(trackRef->dz(primaryVertex_.position())) < X [cm]");
420 desc.add<
double>(
"pf_nsigma_ECAL", 0.0);
421 desc.add<
double>(
"pf_nsigma_HCAL", 1.0);
422 desc.add<
double>(
"pf_nsigma_HFEM", 1.0);
423 desc.add<
double>(
"pf_nsigma_HFHAD", 1.0);
426 desc.add<
bool>(
"useCalibrationsFromDB",
true);
430 desc.add<
bool>(
"postHFCleaning",
false);
433 psd_PFHFCleaning.
add<
double>(
"minHFCleaningPt", 5.0)
434 ->
setComment(
"Clean only objects with pt larger than this value");
435 psd_PFHFCleaning.add<
double>(
"maxSignificance", 2.5)
436 ->setComment(
"Clean only if the initial MET/sqrt(sumet) is larger than this value");
437 psd_PFHFCleaning.add<
double>(
"minSignificance", 2.5)
438 ->setComment(
"Clean only if the final MET/sqrt(sumet) is smaller than this value");
439 psd_PFHFCleaning.add<
double>(
"minSignificanceReduction", 1.4)
440 ->setComment(
"Clean only if the significance reduction is larger than this value");
441 psd_PFHFCleaning.add<
double>(
"maxDeltaPhiPt", 7.0)
442 ->setComment(
"Clean only if the MET and the to-be-cleaned object satisfy this DeltaPhi * Pt cut");
444 psd_PFHFCleaning.add<
double>(
"minDeltaMet", 0.4)
446 "Clean only if the MET relative reduction from the to-be-cleaned object is larger than this value");
451 desc.add<std::vector<edm::InputTag>>(
"cleanedHF",
458 desc.add<
bool>(
"calibHF_use",
false);
459 desc.add<std::vector<double>>(
"calibHF_eta_step", {0.0, 2.9, 3.0, 3.2, 4.2, 4.4, 4.6, 4.8, 5.2, 5.4});
460 desc.add<std::vector<double>>(
"calibHF_a_EMonly", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
461 desc.add<std::vector<double>>(
"calibHF_a_EMHAD", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
462 desc.add<std::vector<double>>(
"calibHF_b_HADonly", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
463 desc.add<std::vector<double>>(
"calibHF_b_EMHAD", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
466 desc.add<std::vector<double>>(
"resolHF_square", {2.799 * 2.799, 0.114 * 0.114, 0.0 * 0.0})
467 ->setComment(
"HF resolution - stochastic, constant, noise term squares");
469 descriptions.
add(
"particleFlow",
desc);
References edm::ConfigurationDescriptions::add(), edm::ParameterSetDescription::add(), submitPVResolutionJobs::desc, PFMuonAlgo::fillPSetDescription(), PFEGammaFilters::fillPSetDescription(), PFCandConnector::fillPSetDescription(), HLT_FULL_cff::InputTag, or, edm::ParameterDescriptionNode::setComment(), and AlCaHLTBitMon_QueryRunRegistry::string.
◆ produce()
Definition at line 235 of file PFProducer.cc.
236 LogDebug(
"PFProducer") <<
"START event: " <<
iEvent.id().event() <<
" in run " <<
iEvent.id().run() << endl;
259 LogDebug(
"PFProducer") <<
"particle flow is starting" << endl;
277 for (
unsigned jhf = 0; jhf < (*hfCleaned).size(); ++jhf) {
278 hfCopy.push_back((*hfCleaned)[jhf]);
287 LogDebug(
"PFProducer") <<
"particle flow: putting products in the event";
291 for (
auto const&
cand : pOutputCandidateCollection) {
293 ss <<
" " << nC <<
") pid=" <<
cand.particleId() <<
" pt=" <<
cand.pt() << endl;
295 LogDebug(
"PFProducer") <<
"Here the full list:" << endl <<
ss.str();
305 iEvent.put(muAlgo.transferCleanedCosmicCandidates(),
"CleanedCosmicsMuons");
307 iEvent.put(muAlgo.transferCleanedTrackerAndGlobalCandidates(),
"CleanedTrackerAndGlobalMuons");
309 iEvent.put(muAlgo.transferCleanedFakeCandidates(),
"CleanedFakeMuons");
311 iEvent.put(muAlgo.transferPunchThroughCleanedMuonCandidates(),
"CleanedPunchThroughMuons");
313 iEvent.put(muAlgo.transferPunchThroughCleanedHadronCandidates(),
"CleanedPunchThroughNeutralHadrons");
315 iEvent.put(muAlgo.transferAddedMuonCandidates(),
"AddedMuonsAndHadrons");
References cms::cuda::assert(), gather_cfg::blocks, PFAlgo::checkCleaning(), PFAlgo::getCleanedCandidates(), PFAlgo::getPFMuonAlgo(), iEvent, ihf, inputTagBlocks_, inputTagCleanedHF_, inputTagMuons_, inputTagPFEGammaCandidates_, inputTagValueMapGedElectrons_, inputTagValueMapGedPhotons_, inputTagVetoes_, LogDebug, PFAlgo::makeConnectedCandidates(), pfAlgo_, pfCandidatesToken_, pfCleanedCandidatesToken_, pfegamma_, postHFCleaning_, postMuonCleaning_, PFAlgo::reconstructParticles(), PFAlgo::setEGammaCollections(), PFAlgo::setMuonHandle(), PFAlgo::setPFVertexParameters(), PFMuonAlgo::setVetoes(), contentValuesCheck::ss, str, use_EGammaFilters_, useVerticesForNeutral_, verbose_, vertices_, and vetoEndcap_.
◆ calibrationsLabel_
std::string PFProducer::calibrationsLabel_ |
|
private |
◆ electronExtraOutputCol_
std::string PFProducer::electronExtraOutputCol_ |
|
private |
◆ inputTagBlocks_
◆ inputTagCleanedHF_
◆ inputTagEgammaElectrons_
◆ inputTagMuons_
◆ inputTagPFEGammaCandidates_
◆ inputTagValueMapGedElectrons_
◆ inputTagValueMapGedPhotons_
◆ inputTagVetoes_
◆ perfToken_
◆ pfAlgo_
◆ pfCandidatesToken_
◆ pfCleanedCandidatesToken_
◆ pfegamma_
◆ pfEnergyCalibration_
◆ pfEnergyCalibrationHF_
◆ photonExtraOutputCol_
std::string PFProducer::photonExtraOutputCol_ |
|
private |
◆ postHFCleaning_
bool PFProducer::postHFCleaning_ |
|
private |
◆ postMuonCleaning_
bool PFProducer::postMuonCleaning_ |
|
private |
◆ use_EGammaFilters_
bool PFProducer::use_EGammaFilters_ |
|
private |
◆ useCalibrationsFromDB_
bool PFProducer::useCalibrationsFromDB_ |
|
private |
◆ useEGammaElectrons_
bool PFProducer::useEGammaElectrons_ |
|
private |
◆ useHO_
◆ useVerticesForNeutral_
bool PFProducer::useVerticesForNeutral_ |
|
private |
◆ verbose_
bool PFProducer::verbose_ |
|
private |
◆ vertices_
◆ vetoEndcap_
bool PFProducer::vetoEndcap_ |
|
private |
const edm::EDPutTokenT< reco::PFCandidateCollection > pfCandidatesToken_
bool useVerticesForNeutral_
edm::EDGetTokenT< edm::ValueMap< reco::PhotonRef > > inputTagValueMapGedPhotons_
ParameterDescriptionBase * add(U const &iLabel, T const &value)
void reconstructParticles(const reco::PFBlockHandle &blockHandle, PFEGammaFilters const *pfegamma)
reconstruct particles
void setDisplacedVerticesParameters(bool rejectTracks_Bad, bool rejectTracks_Step45, bool usePFNuclearInteractions, bool usePFConversions, bool usePFDecays, double dptRel_DispVtx)
void setMuonHandle(const edm::Handle< reco::MuonCollection > &muons)
T getUntrackedParameter(std::string const &, T const &) const
bool existsAs(std::string const ¶meterName, bool trackiness=true) const
checks if a parameter exists as a given type
Log< level::Info, false > LogInfo
reco::PFCandidateCollection makeConnectedCandidates()
reco::PFCandidateCollection & getCleanedCandidates()
void setCandConnectorParameters(const edm::ParameterSet &iCfgCandConnector)
std::vector< PFRecHit > PFRecHitCollection
collection of PFRecHit objects
void add(std::string const &label, ParameterSetDescription const &psetDescription)
void setEGammaParameters(bool use_EGammaFilters, bool useProtectionsForJetMET)
edm::EDGetTokenT< reco::PFCandidateCollection > inputTagVetoes_
void checkCleaning(const reco::PFRecHitCollection &cleanedHF)
Check HF Cleaning.
edm::EDGetTokenT< reco::GsfElectronCollection > inputTagEgammaElectrons_
const edm::EDPutTokenT< reco::PFCandidateCollection > pfCleanedCandidatesToken_
std::string calibrationsLabel_
void setPFVertexParameters(bool useVertex, reco::VertexCollection const &primaryVertices)
edm::EDGetTokenT< edm::ValueMap< reco::GsfElectronRef > > inputTagValueMapGedElectrons_
void setVetoes(const reco::PFCandidateCollection &vetoes)
edm::ESGetToken< PerformancePayload, PFCalibrationRcd > perfToken_
void setEGammaCollections(const edm::View< reco::PFCandidate > &pfEgammaCandidates, const edm::ValueMap< reco::GsfElectronRef > &valueMapGedElectrons, const edm::ValueMap< reco::PhotonRef > &valueMapGedPhotons)
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
void setCalibrationFunctions(const PerformancePayloadFromTFormula *thePFCal)
bool useCalibrationsFromDB_
PFEnergyCalibration pfEnergyCalibration_
edm::EDGetTokenT< edm::View< reco::PFCandidate > > inputTagPFEGammaCandidates_
std::vector< edm::EDGetTokenT< reco::PFRecHitCollection > > inputTagCleanedHF_
void setPostHFCleaningParameters(bool postHFCleaning, const edm::ParameterSet &pfHFCleaningParams)
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
T getParameter(std::string const &) const
void setComment(std::string const &value)
edm::EDGetTokenT< reco::MuonCollection > inputTagMuons_
PFAlgo pfAlgo_
particle flow algorithm
static void fillPSetDescription(edm::ParameterSetDescription &iDesc)
PFEnergyCalibrationHF pfEnergyCalibrationHF_
edm::EDGetTokenT< reco::VertexCollection > vertices_
static void fillPSetDescription(edm::ParameterSetDescription &iDesc)
std::unique_ptr< PFEGammaFilters > pfegamma_
const edm::EDGetTokenT< reco::PFBlockCollection > inputTagBlocks_
static void fillPSetDescription(edm::ParameterSetDescription &iDesc)
PFMuonAlgo * getPFMuonAlgo()