template<typename DET, PFLayer::Layer Layer, unsigned subdet>
class PFHGCalRecHitCreator< DET, Layer, subdet >
Definition at line 27 of file PFHGCalRecHitCreator.h.
template<typename DET , PFLayer::Layer Layer, unsigned subdet>
Implements PFRecHitCreatorBase.
Definition at line 37 of file PFHGCalRecHitCreator.h.
References EnergyCorrector::c, PFHGCalRecHitCreator< DET, Layer, subdet >::caloCells_, Exception, relativeConstraints::geom, edm::EventSetup::get(), edm::Event::getByToken(), hgcal::RecHitTools::getEventSetup(), ecaldqm::getGeometry(), hgcal::RecHitTools::getPosition(), CaloGeometry::getSubdetectorGeometry(), DetId::Hcal, mps_fire::i, keep, LogDebug, edm::ESHandle< T >::product(), PFRecHitCreatorBase::qualityTests_, TrackInfoProducer_cfi::rechits, PFHGCalRecHitCreator< DET, Layer, subdet >::recHitToken_, PFHGCalRecHitCreator< DET, Layer, subdet >::recHitTools_, edm::SortedCollection< T, SORT >::size(), and ntuplemaker::time.
59 caloCells_.reserve(rechits.
size());
61 unsigned skipped_rechits = 0;
62 for (
const auto & hgrh : rechits) {
63 const DET detid(hgrh.detid());
65 if( subdet != detid.subdetId() ) {
67 <<
"subdet expected: " << subdet
68 <<
" subdet gotten: " << detid.subdetId() << std::endl;
71 double energy = hgrh.energy();
72 double time = hgrh.time();
81 thisCell = caloCells_.back();
87 <<
"warning detid "<<detid.rawId()
88 <<
" not found in geometry"<<std::endl;
99 bool rcleaned =
false;
114 cleaned->push_back(rh);
117 <<
"Skipped " << skipped_rechits
118 <<
" out of " << rechits.size() <<
" rechits!" << std::endl;
120 <<
"Created " <<
out->size() <<
" PFRecHits!" << std::endl;
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly
std::vector< std::unique_ptr< PFRecHitQTestBase > > qualityTests_
bool getByToken(EDGetToken token, Handle< PROD > &result) const
CaloGeometry const * getGeometry()
SeedingLayerSetsHits::SeedingLayer Layer
hgcal::RecHitTools recHitTools_
Particle flow rechit (rechit + geometry and topology information). See clustering algorithm in PFClus...
edm::EDGetTokenT< HGCRecHitCollection > recHitToken_
std::vector< const CaloCellGeometryHGCALAdapter * > caloCells_
T const * product() const