Go to the documentation of this file. 1 #ifndef RecoParticleFlow_PFClusterProducer_PFPSRecHitCreator_h
2 #define RecoParticleFlow_PFClusterProducer_PFPSRecHitCreator_h
34 std::unique_ptr<reco::PFRecHitCollection>& cleaned,
46 for (
const auto& erh : *recHitHandle) {
48 auto energy = erh.energy();
52 switch (detid.plane()) {
61 <<
"incorrect preshower plane !! plane number " << detid.plane() << std::endl;
69 <<
"warning detid " << detid.rawId() <<
" not found in geometry" << std::endl;
74 auto& rh =
out->back();
75 rh.setDepth(detid.plane());
76 rh.setTime(erh.time());
78 bool rcleaned =
false;
84 if (!qtest->test(rh, erh, rcleaned,
hi)) {
void beginEvent(const edm::Event &event, const edm::EventSetup &setup)
PFPSRecHitCreator(const edm::ParameterSet &iConfig, edm::ConsumesCollector &cc)
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly
std::vector< std::unique_ptr< PFRecHitQTestBase > > qualityTests_
edm::ESGetToken< CaloGeometry, CaloGeometryRecord > geomToken_
constexpr std::array< uint8_t, layerIndexSize > layer
ESHandle< T > getHandle(const ESGetToken< T, R > &iToken) const
edm::EDGetTokenT< EcalRecHitCollection > recHitToken_
virtual std::shared_ptr< const CaloCellGeometry > getGeometry(const DetId &id) const
Get the cell geometry of a given detector id. Should return false if not found.
Log< level::Error, false > LogError
void importRecHits(std::unique_ptr< reco::PFRecHitCollection > &out, std::unique_ptr< reco::PFRecHitCollection > &cleaned, const edm::Event &iEvent, const edm::EventSetup &iSetup) override