33 std::vector<CaloTowerDetId> towers;
34 std::vector<reco::CaloClusterPtr> orderedClusters;
47 for ( ; it !=itend; ++it) {
48 orderedClusters.push_back(*it);
51 unsigned nclusters=orderedClusters.size();
52 for (
unsigned iclus =0 ; iclus <nclusters && iclus <
NMaxClusters_; ++iclus) {
55 std::vector<CaloTowerDetId>::const_iterator itcheck=
find(towers.begin(),towers.end(),
id);
56 if( itcheck == towers.end() ) {
81 for( ; trItr != trItrEnd ; ++trItr){
82 std::vector<CaloTowerDetId>::const_iterator itcheck =
find(towers.begin(), towers.end(), trItr->id());
83 if( itcheck != towers.end() ) {
84 esum += trItr->ietaAbs()<18 || trItr->ietaAbs()>29 ? trItr->hadEnergy() : trItr->hadEnergyHeInnerLayer() ;
94 for( ; trItr != trItrEnd ; ++trItr){
95 std::vector<CaloTowerDetId>::const_iterator itcheck =
find(towers.begin(), towers.end(), trItr->id());
96 if( itcheck != towers.end() ) {
97 esum += trItr->hadEnergyHeOuterLayer();
const CaloTowerCollection * towerCollection_
CaloTowerDetId towerOf(const reco::CaloCluster &cluster) const
std::vector< CaloTower >::const_iterator const_iterator
const std::vector< std::pair< DetId, float > > & hitsAndFractions() const
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
void setTowerCollection(const CaloTowerCollection *towercollection)
CaloTowerDetId towerOf(const DetId &id) const
Get the tower id for this det id (or null if not known)
double getDepth1HcalESum(const reco::SuperCluster &sc) const
bool ClusterGreaterThan(const reco::CaloClusterPtr &c1, const reco::CaloClusterPtr &c2)
const_iterator end() const
const CaloTowerConstituentsMap * towerMap_
DetId seed() const
return DetId of seed
std::vector< CaloTowerDetId > towersOf(const reco::SuperCluster &sc) const
double getDepth2HcalESum(const reco::SuperCluster &sc) const
CaloCluster_iterator clustersBegin() const
fist iterator over BasicCluster constituents
unsigned int NMaxClusters_
const CaloClusterPtr & seed() const
seed BasicCluster
Detector det() const
get the detector field from this detid
EgammaHadTower(const edm::EventSetup &es, HoeMode mode=SingleTower)
const_iterator begin() const
CaloCluster_iterator clustersEnd() const
last iterator over BasicCluster constituents