Particle Flow Algorithm. More...
#include <PFBlockAlgo.h>
Public Types | |
typedef std::vector< std::unique_ptr< reco::PFBlockElement > > | ElementList |
typedef std::array< std::pair< unsigned int, unsigned int >, reco::PFBlockElement::kNBETypes > | ElementRanges |
typedef reco::PFBlockCollection::const_iterator | IBC |
typedef ElementList::iterator | IE |
define these in *Fwd files in DataFormats/ParticleFlowReco? More... | |
typedef ElementList::const_iterator | IEC |
typedef std::unique_ptr< BlockElementImporterBase > | ImporterPtr |
typedef std::unique_ptr< KDTreeLinkerBase > | KDTreePtr |
typedef std::unique_ptr< BlockElementLinkerBase > | LinkTestPtr |
Public Member Functions | |
const std::unique_ptr< reco::PFBlockCollection > & | blocks () const |
void | buildElements (const edm::Event &) |
void | findBlocks () |
build blocks More... | |
PFBlockAlgo () | |
void | setDebug (bool debug) |
sets debug printout flag More... | |
void | setImporters (const std::vector< edm::ParameterSet > &, edm::ConsumesCollector &) |
void | setLinkers (const std::vector< edm::ParameterSet > &) |
std::unique_ptr< reco::PFBlockCollection > | transferBlocks () |
void | updateEventSetup (const edm::EventSetup &) |
~PFBlockAlgo () | |
Private Member Functions | |
void | link (const reco::PFBlockElement *el1, const reco::PFBlockElement *el2, PFBlockLink::Type &linktype, reco::PFBlock::LinkTest &linktest, double &dist) const |
check whether 2 elements are linked. Returns distance and linktype More... | |
bool | linkPrefilter (const reco::PFBlockElement *last, const reco::PFBlockElement *next) const |
Avoid to check links when not useful. More... | |
void | packLinks (reco::PFBlock &block, const std::unordered_map< std::pair< unsigned int, unsigned int >, PFBlockLink > &links) const |
Private Attributes | |
std::vector< ElementList::value_type::pointer > | bare_elements_ |
std::unique_ptr< reco::PFBlockCollection > | blocks_ |
bool | debug_ |
if true, debug printouts activated More... | |
ElementList | elements_ |
const std::unordered_map< std::string, reco::PFBlockElement::Type > | elementTypes_ |
std::vector< ImporterPtr > | importers_ |
std::vector< KDTreePtr > | kdtrees_ |
std::vector< LinkTestPtr > | linkTests_ |
unsigned int | linkTestSquare_ [reco::PFBlockElement::kNBETypes][reco::PFBlockElement::kNBETypes] |
ElementRanges | ranges_ |
bool | useHO_ |
Friends | |
std::ostream & | operator<< (std::ostream &, const PFBlockAlgo &) |
typedef std::vector<std::unique_ptr<reco::PFBlockElement> > PFBlockAlgo::ElementList |
Definition at line 95 of file PFBlockAlgo.h.
typedef std::array<std::pair<unsigned int,unsigned int>,reco::PFBlockElement::kNBETypes> PFBlockAlgo::ElementRanges |
Definition at line 104 of file PFBlockAlgo.h.
typedef reco::PFBlockCollection::const_iterator PFBlockAlgo::IBC |
Definition at line 102 of file PFBlockAlgo.h.
typedef ElementList::iterator PFBlockAlgo::IE |
define these in *Fwd files in DataFormats/ParticleFlowReco?
Definition at line 100 of file PFBlockAlgo.h.
typedef ElementList::const_iterator PFBlockAlgo::IEC |
Definition at line 101 of file PFBlockAlgo.h.
typedef std::unique_ptr<BlockElementImporterBase> PFBlockAlgo::ImporterPtr |
Definition at line 96 of file PFBlockAlgo.h.
typedef std::unique_ptr<KDTreeLinkerBase> PFBlockAlgo::KDTreePtr |
Definition at line 98 of file PFBlockAlgo.h.
typedef std::unique_ptr<BlockElementLinkerBase> PFBlockAlgo::LinkTestPtr |
Definition at line 97 of file PFBlockAlgo.h.
PFBlockAlgo::PFBlockAlgo | ( | ) |
Definition at line 67 of file PFBlockAlgo.cc.
References ECAL, HCAL, hcaldqm::constants::HO, and INIT_ENTRY.
PFBlockAlgo::~PFBlockAlgo | ( | ) |
|
inline |
Definition at line 129 of file PFBlockAlgo.h.
Referenced by operator<<().
void PFBlockAlgo::buildElements | ( | const edm::Event & | evt | ) |
Definition at line 335 of file PFBlockAlgo.cc.
References a, b, bare_elements_, elements_, mps_fire::i, importers_, kdtrees_, and ranges_.
void PFBlockAlgo::findBlocks | ( | ) |
build blocks
Definition at line 154 of file PFBlockAlgo.cc.
References bare_elements_, blocks_, elements_, mps_fire::i, diffTreeTool::index, kdtrees_, crabWrapper::key, relativeConstraints::keys, linkPrefilter(), linkTests_, linkTestSquare_, min(), PFBlockLink::NONE, p1, p2, packLinks(), and ranges_.
|
inlineprivate |
check whether 2 elements are linked. Returns distance and linktype
Definition at line 305 of file PFBlockAlgo.cc.
References constexpr, gather_cfg::cout, debug_, diffTreeTool::index, reco::PFBlockElement::kNBETypes, linkTests_, SiStripPI::max, min(), and reco::PFBlockElement::type().
Referenced by packLinks().
|
inlineprivate |
Avoid to check links when not useful.
Definition at line 294 of file PFBlockAlgo.cc.
References constexpr, diffTreeTool::index, reco::PFBlockElement::kNBETypes, plotBeamSpotDB::last, linkTests_, SiStripPI::max, min(), GetRecoTauVFromDQM_MC_cff::next, and mps_fire::result.
Referenced by findBlocks().
|
private |
compute missing links in the blocks (the recursive procedure does not build all links)
Definition at line 237 of file PFBlockAlgo.cc.
References reco::PFBlock::bookLinkData(), constexpr, gather_cfg::cout, debug_, reco::PFBlock::elements(), diffTreeTool::index, reco::PFBlockElement::kNBETypes, link(), reco::PFBlock::linkData(), linkTests_, PFBlockLink::NONE, reco::PFBlock::setLink(), and edm::OwnVector< T, P >::size().
Referenced by findBlocks().
|
inline |
void PFBlockAlgo::setImporters | ( | const std::vector< edm::ParameterSet > & | confs, |
edm::ConsumesCollector & | sumes | ||
) |
Definition at line 133 of file PFBlockAlgo.cc.
References reco::get(), Reconstruction_hiPF_cff::importerName, importers_, and AlCaHLTBitMon_QueryRunRegistry::string.
void PFBlockAlgo::setLinkers | ( | const std::vector< edm::ParameterSet > & | confs | ) |
Definition at line 85 of file PFBlockAlgo.cc.
References constexpr, beamerCreator::create(), elementTypes_, Exception, reco::get(), mps_fire::i, diffTreeTool::index, kdtrees_, reco::PFBlockElement::kNBETypes, hltParticleFlowForJets_cfi::linkerName, linkTests_, linkTestSquare_, SiStripPI::max, min(), tablePrinter::prefix, split, AlCaHLTBitMon_QueryRunRegistry::string, and hltParticleFlowForJets_cfi::useKDTree.
|
inline |
Definition at line 133 of file PFBlockAlgo.h.
References groupFilesInBlocks::block, plotBeamSpotDB::last, eostools::move(), and GetRecoTauVFromDQM_MC_cff::next.
void PFBlockAlgo::updateEventSetup | ( | const edm::EventSetup & | es | ) |
|
friend |
Definition at line 383 of file PFBlockAlgo.cc.
|
private |
Definition at line 159 of file PFBlockAlgo.h.
Referenced by buildElements(), and findBlocks().
|
private |
Definition at line 155 of file PFBlockAlgo.h.
Referenced by findBlocks().
|
private |
if true, debug printouts activated
Definition at line 163 of file PFBlockAlgo.h.
Referenced by link(), packLinks(), and ~PFBlockAlgo().
|
private |
Definition at line 158 of file PFBlockAlgo.h.
Referenced by buildElements(), findBlocks(), operator<<(), and ~PFBlockAlgo().
|
private |
Definition at line 171 of file PFBlockAlgo.h.
Referenced by setLinkers().
|
private |
Definition at line 168 of file PFBlockAlgo.h.
Referenced by buildElements(), setImporters(), and updateEventSetup().
|
private |
Definition at line 175 of file PFBlockAlgo.h.
Referenced by buildElements(), findBlocks(), and setLinkers().
|
private |
Definition at line 172 of file PFBlockAlgo.h.
Referenced by findBlocks(), link(), linkPrefilter(), packLinks(), and setLinkers().
|
private |
Definition at line 173 of file PFBlockAlgo.h.
Referenced by findBlocks(), and setLinkers().
|
private |
Definition at line 160 of file PFBlockAlgo.h.
Referenced by buildElements(), and findBlocks().
|
private |
Definition at line 166 of file PFBlockAlgo.h.