produce HGCAL rechits from uncalibrated rechits
simplified version of Ecal code
- Author
- Valeri Andreev (ported to 76X by L. Gray, add HFNose by Sunanda)
Definition at line 26 of file HGCalRecHitProducer.cc.
Definition at line 67 of file HGCalRecHitProducer.cc.
References edm::SortedCollection< T, SORT >::begin(), eeRechitCollection_, eeUncalibRecHitCollection_, edm::SortedCollection< T, SORT >::end(), edm::Event::getByToken(), hebRechitCollection_, hebUncalibRecHitCollection_, hefRechitCollection_, hefUncalibRecHitCollection_, hfnoseRechitCollection_, hfnoseUncalibRecHitCollection_, edm::HandleBase::isValid(), ALPAKA_ACCELERATOR_NAMESPACE::vertexFinder::it, eostools::move(), edm::Handle< T >::product(), edm::Event::put(), and worker_.
82 eeUncalibRecHits = pHGCeeUncalibRecHits.
product();
85 hefUncalibRecHits = pHGChefUncalibRecHits.
product();
88 hebUncalibRecHits = pHGChebUncalibRecHits.
product();
91 if (pHGChfnoseUncalibRecHits.
isValid())
92 hfnoseUncalibRecHits = pHGChfnoseUncalibRecHits.
product();
95 auto eeRecHits = std::make_unique<HGCeeRecHitCollection>();
96 auto hefRecHits = std::make_unique<HGChefRecHitCollection>();
97 auto hebRecHits = std::make_unique<HGChebRecHitCollection>();
102 for (
auto it = eeUncalibRecHits->
begin();
it != eeUncalibRecHits->
end(); ++
it) {
107 for (
auto it = hefUncalibRecHits->
begin();
it != hefUncalibRecHits->
end(); ++
it) {
112 for (
auto it = hebUncalibRecHits->
begin();
it != hebUncalibRecHits->
end(); ++
it) {
122 LogInfo(
"HGCalRecHitInfo") <<
"total # HGCee calibrated rechits: " << eeRecHits->size();
123 LogInfo(
"HGCalRecHitInfo") <<
"total # HGChef calibrated rechits: " << hefRecHits->size();
124 LogInfo(
"HGCalRecHitInfo") <<
"total # HGCheb calibrated rechits: " << hebRecHits->size();
131 if (pHGChfnoseUncalibRecHits.
isValid()) {
132 auto hfnoseRecHits = std::make_unique<HGChfnoseRecHitCollection>();
133 for (
auto it = hfnoseUncalibRecHits->
begin();
it != hfnoseUncalibRecHits->
end(); ++
it) {
136 hfnoseRecHits->sort();
137 LogInfo(
"HGCalRecHitInfo") <<
"total # HGChfnose calibrated rechits: " << hfnoseRecHits->size();
OrphanHandle< PROD > put(std::unique_ptr< PROD > product)
Put a new product.
const std::string hfnoseRechitCollection_
T const * product() const
bool getByToken(EDGetToken token, Handle< PROD > &result) const
const edm::EDGetTokenT< HGChefUncalibratedRecHitCollection > hefUncalibRecHitCollection_
const edm::EDGetTokenT< HGCeeUncalibratedRecHitCollection > eeUncalibRecHitCollection_
const std::string hefRechitCollection_
const_iterator begin() const
const_iterator end() const
Log< level::Info, false > LogInfo
const std::string eeRechitCollection_
const std::string hebRechitCollection_
std::unique_ptr< HGCalRecHitWorkerBaseClass > worker_
const edm::EDGetTokenT< HGChebUncalibratedRecHitCollection > hebUncalibRecHitCollection_
const edm::EDGetTokenT< HGChfnoseUncalibratedRecHitCollection > hfnoseUncalibRecHitCollection_