|
|
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 106 of file PFProducer.cc.
111 iConfig.
getParameter<std::vector<double>>(
"calibHF_eta_step"),
112 iConfig.
getParameter<std::vector<double>>(
"calibHF_a_EMonly"),
113 iConfig.
getParameter<std::vector<double>>(
"calibHF_b_HADonly"),
114 iConfig.
getParameter<std::vector<double>>(
"calibHF_a_EMHAD"),
115 iConfig.
getParameter<std::vector<double>>(
"calibHF_b_EMHAD")),
120 iConfig.
getParameter<std::vector<double>>(
"resolHF_square"),
131 if (iConfig.
existsAs<
bool>(
"useEGammaFilters")) {
145 produces<reco::PFCandidateCollection>(
"CleanedCosmicsMuons");
146 produces<reco::PFCandidateCollection>(
"CleanedTrackerAndGlobalMuons");
147 produces<reco::PFCandidateCollection>(
"CleanedFakeMuons");
148 produces<reco::PFCandidateCollection>(
"CleanedPunchThroughMuons");
149 produces<reco::PFCandidateCollection>(
"CleanedPunchThroughNeutralHadrons");
150 produces<reco::PFCandidateCollection>(
"AddedMuonsAndHadrons");
167 pfegamma_ = std::make_unique<PFEGammaFilters>(pfEGammaFiltersParams);
207 std::vector<edm::InputTag>
tags = iConfig.
getParameter<std::vector<edm::InputTag>>(
"cleanedHF");
208 for (
unsigned int i = 0;
i <
tags.size(); ++
i)
◆ beginRun()
◆ fillDescriptions()
Definition at line 318 of file PFProducer.cc.
322 desc.addUntracked<
bool>(
"verbose",
false);
323 desc.addUntracked<
bool>(
"debug",
false);
330 desc.add<
bool>(
"postMuonCleaning",
true);
340 desc.add<
bool>(
"useVerticesForNeutral",
true);
343 desc.add<
bool>(
"useHO",
true);
350 desc.add<
bool>(
"useEGammaElectrons",
true);
353 desc.add<
bool>(
"useEGammaFilters",
true);
354 desc.add<
bool>(
"useProtectionsForJetMET",
true);
363 desc.add<std::vector<double>>(
"muon_HCAL", {3.0, 3.0});
364 desc.add<std::vector<double>>(
"muon_ECAL", {0.5, 0.5});
365 desc.add<std::vector<double>>(
"muon_HO", {0.9, 0.9});
374 desc.add<
bool>(
"rejectTracks_Bad",
true);
375 desc.add<
bool>(
"rejectTracks_Step45",
true);
377 desc.add<
bool>(
"usePFNuclearInteractions",
true);
378 desc.add<
bool>(
"usePFConversions",
true);
379 desc.add<
bool>(
"usePFDecays",
false);
381 desc.add<
double>(
"dptRel_DispVtx", 10.0);
389 desc.add<
double>(
"nsigma_TRACK", 1.0)->setComment(
"Number of sigmas for fake track detection");
391 desc.add<
double>(
"pt_Error", 1.0)
392 ->setComment(
"Absolute pt error to detect fake tracks in the first three iterations");
393 desc.add<std::vector<double>>(
"factors_45", {10.0, 100.0})
394 ->setComment(
"Factors to be applied in the four and fifth steps to the pt error");
397 desc.add<
double>(
"goodTrackDeadHcal_ptErrRel", 0.2)->setComment(
"trackRef->ptError()/trackRef->pt() < X");
398 desc.add<
double>(
"goodTrackDeadHcal_chi2n", 5)->setComment(
"trackRef->normalizedChi2() < X");
399 desc.add<
unsigned int>(
"goodTrackDeadHcal_layers", 4)
400 ->setComment(
"trackRef->hitPattern().trackerLayersWithMeasurement() >= X");
401 desc.add<
double>(
"goodTrackDeadHcal_validFr", 0.5)->setComment(
"trackRef->validFraction() > X");
402 desc.add<
double>(
"goodTrackDeadHcal_dxy", 0.5)->setComment(
"abs(trackRef->dxy(primaryVertex_.position())) < X [cm]");
404 desc.add<
double>(
"goodPixelTrackDeadHcal_minEta", 2.3)->setComment(
"abs(trackRef->eta()) > X");
405 desc.add<
double>(
"goodPixelTrackDeadHcal_maxPt", 50.0)->setComment(
"trackRef->ptError()/trackRef->pt() < X");
406 desc.add<
double>(
"goodPixelTrackDeadHcal_ptErrRel", 1.0)->setComment(
"trackRef->ptError()/trackRef->pt() < X");
407 desc.add<
double>(
"goodPixelTrackDeadHcal_chi2n", 2)->setComment(
"trackRef->normalizedChi2() < X");
408 desc.add<
int>(
"goodPixelTrackDeadHcal_maxLost3Hit", 0)
410 "max missing outer hits for a track with 3 valid pixel layers (can set to -1 to reject all these tracks)");
411 desc.add<
int>(
"goodPixelTrackDeadHcal_maxLost4Hit", 1)
412 ->setComment(
"max missing outer hits for a track with >= 4 valid pixel layers");
413 desc.add<
double>(
"goodPixelTrackDeadHcal_dxy", 0.02)
414 ->setComment(
"abs(trackRef->dxy(primaryVertex_.position())) < X [cm] ");
415 desc.add<
double>(
"goodPixelTrackDeadHcal_dz", 0.05)
416 ->setComment(
"abs(trackRef->dz(primaryVertex_.position())) < X [cm]");
419 desc.add<
double>(
"pf_nsigma_ECAL", 0.0);
420 desc.add<
double>(
"pf_nsigma_HCAL", 1.0);
421 desc.add<
double>(
"pf_nsigma_HFEM", 1.0);
422 desc.add<
double>(
"pf_nsigma_HFHAD", 1.0);
425 desc.add<
bool>(
"useCalibrationsFromDB",
true);
429 desc.add<
bool>(
"postHFCleaning",
false);
432 psd_PFHFCleaning.
add<
double>(
"minHFCleaningPt", 5.0)
433 ->
setComment(
"Clean only objects with pt larger than this value");
434 psd_PFHFCleaning.add<
double>(
"maxSignificance", 2.5)
435 ->setComment(
"Clean only if the initial MET/sqrt(sumet) is larger than this value");
436 psd_PFHFCleaning.add<
double>(
"minSignificance", 2.5)
437 ->setComment(
"Clean only if the final MET/sqrt(sumet) is smaller than this value");
438 psd_PFHFCleaning.add<
double>(
"minSignificanceReduction", 1.4)
439 ->setComment(
"Clean only if the significance reduction is larger than this value");
440 psd_PFHFCleaning.add<
double>(
"maxDeltaPhiPt", 7.0)
441 ->setComment(
"Clean only if the MET and the to-be-cleaned object satisfy this DeltaPhi * Pt cut");
443 psd_PFHFCleaning.add<
double>(
"minDeltaMet", 0.4)
445 "Clean only if the MET relative reduction from the to-be-cleaned object is larger than this value");
450 desc.add<std::vector<edm::InputTag>>(
"cleanedHF",
457 desc.add<
bool>(
"calibHF_use",
false);
458 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});
459 desc.add<std::vector<double>>(
"calibHF_a_EMonly", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
460 desc.add<std::vector<double>>(
"calibHF_a_EMHAD", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
461 desc.add<std::vector<double>>(
"calibHF_b_HADonly", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
462 desc.add<std::vector<double>>(
"calibHF_b_EMHAD", {1., 1., 1., 1., 1., 1., 1., 1., 1., 1.});
465 desc.add<std::vector<double>>(
"resolHF_square", {2.799 * 2.799, 0.114 * 0.114, 0.0 * 0.0})
466 ->setComment(
"HF resolution - stochastic, constant, noise term squares");
468 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 234 of file PFProducer.cc.
235 LogDebug(
"PFProducer") <<
"START event: " <<
iEvent.id().event() <<
" in run " <<
iEvent.id().run() << endl;
258 LogDebug(
"PFProducer") <<
"particle flow is starting" << endl;
276 for (
unsigned jhf = 0; jhf < (*hfCleaned).size(); ++jhf) {
277 hfCopy.push_back((*hfCleaned)[jhf]);
286 LogDebug(
"PFProducer") <<
"particle flow: putting products in the event";
290 for (
auto const&
cand : pOutputCandidateCollection) {
292 ss <<
" " << nC <<
") pid=" <<
cand.particleId() <<
" pt=" <<
cand.pt() << endl;
294 LogDebug(
"PFProducer") <<
"Here the full list:" << endl <<
ss.str();
304 iEvent.put(muAlgo.transferCleanedCosmicCandidates(),
"CleanedCosmicsMuons");
306 iEvent.put(muAlgo.transferCleanedTrackerAndGlobalCandidates(),
"CleanedTrackerAndGlobalMuons");
308 iEvent.put(muAlgo.transferCleanedFakeCandidates(),
"CleanedFakeMuons");
310 iEvent.put(muAlgo.transferPunchThroughCleanedMuonCandidates(),
"CleanedPunchThroughMuons");
312 iEvent.put(muAlgo.transferPunchThroughCleanedHadronCandidates(),
"CleanedPunchThroughNeutralHadrons");
314 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_
◆ 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 |
T const * product() const
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)
void setEGammaCollections(const edm::View< reco::PFCandidate > &pfEgammaCandidates, const edm::ValueMap< reco::GsfElectronRef > &valueMapGedElectrons, const edm::ValueMap< reco::PhotonRef > &valueMapGedPhotons)
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()