78 auto const& cell = (*input)[kcell];
79 int cell_layer = (
int)cell.layer();
85 double thresholdE = 0.;
86 double thresholdPT2 = 0.;
88 for (
unsigned int j = 0; j < (std::get<1>(
thresholds)).size(); ++
j) {
99 if (cell.energy() < thresholdE || cell.pt2() < thresholdPT2) {
100 LOGDRESSED(
"GenericTopoCluster::buildTopoCluster()")
101 <<
"RecHit " << cell.detId() <<
" with enegy " << cell.energy() <<
" GeV was rejected!." << std::endl;
110 auto const& neighbours = (
_useCornerCells ? cell.neighbours8() : cell.neighbours4());
112 for (
auto nb : neighbours) {
113 if (used[nb] || !rechitMask[nb]) {
114 LOGDRESSED(
"GenericTopoCluster::buildTopoCluster()")
115 <<
" RecHit " << cell.detId() <<
"\'s" 116 <<
" neighbor RecHit " <<
input->at(nb).detId() <<
" with enegy " <<
input->at(nb).energy()
117 <<
" GeV was rejected!" 118 <<
" Reasons : " << used[nb] <<
" (used) " << !rechitMask[nb] <<
" (masked)." << std::endl;
reco::PFRecHitRef makeRefhit(const edm::Handle< reco::PFRecHitCollection > &h, const unsigned i) const
void buildTopoCluster(const edm::Handle< reco::PFRecHitCollection > &, const std::vector< bool > &, unsigned int, std::vector< bool > &, reco::PFCluster &)
Fraction of a PFRecHit (rechits can be shared between several PFCluster's)
static std::string const input
const bool _useCornerCells
Abs< T >::type abs(const T &t)
void addRecHitFraction(const reco::PFRecHitFraction &frac)
add a given fraction of the rechit
std::unordered_map< int, I3tuple > _thresholds