45 std::vector<int>
const& flagsEB,
46 std::vector<int>
const& flagsEE,
47 std::vector<int>
const& severitiesEB,
48 std::vector<int>
const& severitiesEE,
57 if (not hcRHC.label().empty())
187 bool isEBPho =
false;
188 bool isEEPho =
false;
189 bool isEBEtaGap =
false;
190 bool isEBPhiGap =
false;
191 bool isEERingGap =
false;
192 bool isEEDeeGap =
false;
193 bool isEBEEGap =
false;
194 classify(pho, isEBPho, isEEPho, isEBEtaGap, isEBPhiGap, isEERingGap, isEEDeeGap, isEBEEGap);
195 phofid.
isEB = isEBPho;
196 phofid.
isEE = isEEPho;
208 DetId seedXtalId = seedCluster.hitsAndFractions()[0].first;
212 double photonEcalRecHitConeInnerRadiusA_;
213 double photonEcalRecHitConeOuterRadiusA_;
214 double photonEcalRecHitEtaSliceA_;
215 double photonEcalRecHitThreshEA_;
216 double photonEcalRecHitThreshEtA_;
217 double photonHcalTowerConeInnerRadiusA_;
218 double photonHcalTowerConeOuterRadiusA_;
219 double photonHcalTowerThreshEA_;
220 double photonHcalDepth1TowerConeInnerRadiusA_;
221 double photonHcalDepth1TowerConeOuterRadiusA_;
222 double photonHcalDepth1TowerThreshEA_;
223 double photonHcalDepth2TowerConeInnerRadiusA_;
224 double photonHcalDepth2TowerConeOuterRadiusA_;
225 double photonHcalDepth2TowerThreshEA_;
226 double trackConeOuterRadiusA_;
227 double trackConeInnerRadiusA_;
228 double isolationtrackThresholdA_;
229 double isolationtrackEtaSliceA_;
230 double trackLipRadiusA_;
231 double trackD0RadiusA_;
232 double photonEcalRecHitConeInnerRadiusB_;
233 double photonEcalRecHitConeOuterRadiusB_;
234 double photonEcalRecHitEtaSliceB_;
235 double photonEcalRecHitThreshEB_;
236 double photonEcalRecHitThreshEtB_;
237 double photonHcalTowerConeInnerRadiusB_;
238 double photonHcalTowerConeOuterRadiusB_;
239 double photonHcalTowerThreshEB_;
240 double photonHcalDepth1TowerConeInnerRadiusB_;
241 double photonHcalDepth1TowerConeOuterRadiusB_;
242 double photonHcalDepth1TowerThreshEB_;
243 double photonHcalDepth2TowerConeInnerRadiusB_;
244 double photonHcalDepth2TowerConeOuterRadiusB_;
245 double photonHcalDepth2TowerThreshEB_;
246 double trackConeOuterRadiusB_;
247 double trackConeInnerRadiusB_;
248 double isolationtrackThresholdB_;
249 double isolationtrackEtaSliceB_;
250 double trackLipRadiusB_;
251 double trackD0RadiusB_;
357 isolationtrackThresholdA_,
358 trackConeOuterRadiusA_,
359 trackConeInnerRadiusA_,
360 isolationtrackEtaSliceA_,
371 isolationtrackThresholdA_,
372 trackConeOuterRadiusA_,
374 isolationtrackEtaSliceA_,
390 isolationtrackThresholdB_,
391 trackConeOuterRadiusB_,
392 trackConeInnerRadiusB_,
393 isolationtrackEtaSliceB_,
404 isolationtrackThresholdB_,
405 trackConeOuterRadiusB_,
407 isolationtrackEtaSliceB_,
422 photonEcalRecHitConeOuterRadiusA_,
423 photonEcalRecHitConeInnerRadiusA_,
424 photonEcalRecHitEtaSliceA_,
425 photonEcalRecHitThreshEA_,
426 photonEcalRecHitThreshEtA_,
434 photonEcalRecHitConeOuterRadiusB_,
435 photonEcalRecHitConeInnerRadiusB_,
436 photonEcalRecHitEtaSliceB_,
437 photonEcalRecHitThreshEB_,
438 photonEcalRecHitThreshEtB_,
444 pho, e, es, photonHcalTowerConeOuterRadiusA_, photonHcalTowerConeInnerRadiusA_, photonHcalTowerThreshEA_, -1);
448 pho, e, es, photonHcalTowerConeOuterRadiusB_, photonHcalTowerConeInnerRadiusB_, photonHcalTowerThreshEB_, -1);
456 photonHcalDepth1TowerConeOuterRadiusA_,
457 photonHcalDepth1TowerConeInnerRadiusA_,
458 photonHcalDepth1TowerThreshEA_,
465 photonHcalDepth1TowerConeOuterRadiusB_,
466 photonHcalDepth1TowerConeInnerRadiusB_,
467 photonHcalDepth1TowerThreshEB_,
476 photonHcalDepth2TowerConeOuterRadiusA_,
477 photonHcalDepth2TowerConeInnerRadiusA_,
478 photonHcalDepth2TowerThreshEA_,
485 photonHcalDepth2TowerConeOuterRadiusB_,
486 photonHcalDepth2TowerConeInnerRadiusB_,
487 photonHcalDepth2TowerThreshEB_,
492 double HcalTowerBcIsoA =
496 double HcalTowerBcIsoB =
502 double HcalDepth1TowerBcIsoA =
503 calculateHcalTowerIso(pho, e, es, photonHcalDepth1TowerConeOuterRadiusA_, photonHcalDepth1TowerThreshEA_, 1);
506 double HcalDepth1TowerBcIsoB =
507 calculateHcalTowerIso(pho, e, es, photonHcalDepth1TowerConeOuterRadiusB_, photonHcalDepth1TowerThreshEB_, 1);
512 double HcalDepth2TowerBcIsoA =
513 calculateHcalTowerIso(pho, e, es, photonHcalDepth2TowerConeOuterRadiusA_, photonHcalDepth2TowerThreshEA_, 2);
516 double HcalDepth2TowerBcIsoB =
517 calculateHcalTowerIso(pho, e, es, photonHcalDepth2TowerConeOuterRadiusB_, photonHcalDepth2TowerThreshEB_, 2);
538 double feta = fabs(eta);
543 if (fabs(feta - 1.479) < .1)
555 if (fabs(feta - 1.479) < .1)
589 vertexBeamSpot = *recoBeamSpotHandle;
600 std::pair<int, double>
res = phoIso.
getIso(photon);
601 ntrkCone = res.first;
602 trkCone = res.second;
614 bool useNumXtals)
const {
632 RCone, RConeInner, etaSlice, etMin, eMin, geoHandle, *rechitsCollectionEB_, sevLevel,
DetId::Ecal);
638 double ecalIsolEB = phoIsoEB.
getEtSum(photon);
641 RCone, RConeInner, etaSlice, etMin, eMin, geoHandle, *rechitsCollectionEE_, sevLevel,
DetId::Ecal);
648 double ecalIsolEE = phoIsoEE.
getEtSum(photon);
650 double ecalIsol = ecalIsolEB + ecalIsolEE;
661 signed int depth)
const {
662 double hcalIsol = 0.;
685 signed int depth)
const {
686 double hcalIsol = 0.;
T getParameter(std::string const &) const
double z0() const
z coordinate
float hcalDepth1TowerSumEtBc
double ecalIsoBarrelRadiusA_[5]
float hcalDepth1TowerSumEt
std::vector< int > flagsEE_
static bool isNextToEtaBoundary(EBDetId id)
void calculate(const reco::Photon *, const edm::Event &, const edm::EventSetup &es, reco::Photon::FiducialFlags &phofid, reco::Photon::IsolationVariables &phoisolR03, reco::Photon::IsolationVariables &phoisolR04) const
double modulePhiBoundary_
double hcalIsoBarrelRadiusB_[9]
bool getByToken(EDGetToken token, Handle< PROD > &result) const
double getEtSum(const reco::Candidate *emObject) const
edm::EDGetToken barrelecalCollection_
edm::EDGetToken endcapecalCollection_
std::vector< Track > TrackCollection
collection of Tracks
double trkIsoEndcapRadiusB_[6]
std::vector< int > severityExclEE_
double trkIsoBarrelRadiusB_[6]
float hcalDepth2TowerSumEt
reco::SuperClusterRef superCluster() const override
Ref to SuperCluster.
edm::EDGetToken hcalCollection_
double hcalIsoBarrelRadiusA_[9]
void doFlagChecks(const std::vector< int > &v)
double calculateHcalTowerIso(const reco::Photon *photon, const edm::Event &iEvent, const edm::EventSetup &iSetup, double RCone, double RConeInner, double eMin, signed int depth) const
void setUseNumCrystals(bool b=true)
double hcalIsoEndcapRadiusA_[9]
std::vector< int > flagsEB_
const std::vector< std::pair< DetId, float > > & hitsAndFractions() const
std::vector< int > severityExclEB_
double trkIsoBarrelRadiusA_[6]
void setup(const edm::ParameterSet &conf, std::vector< int > const &flagsEB_, std::vector< int > const &flagsEE_, std::vector< int > const &severitiesEB_, std::vector< int > const &severitiesEE_, edm::ConsumesCollector &&iC)
static bool isNextToPhiBoundary(EBDetId id)
constexpr int subdetId() const
get the contents of the subdetector field (not cast into any detector's numbering enum) ...
static bool isNextToRingBoundary(EEDetId id)
bool isUninitialized() const
double ecalIsoBarrelRadiusB_[5]
double ecalIsoEndcapRadiusB_[5]
static bool isNextToDBoundary(EEDetId id)
edm::EDGetToken trackInputTag_
std::pair< int, float > getIso(const reco::Candidate *) const
void doSeverityChecks(const EcalRecHitCollection *const recHits, const std::vector< int > &v)
float hcalDepth2TowerSumEtBc
T const * product() const
XYZPointD XYZPoint
point in space with cartesian internal representation
double trkIsoEndcapRadiusA_[6]
double calculateEcalRecHitIso(const reco::Photon *photon, const edm::Event &iEvent, const edm::EventSetup &iSetup, double RCone, double RConeInner, double etaSlice, double eMin, double etMin, bool vetoClusteredHits, bool useNumCrystals) const
void calculateTrackIso(const reco::Photon *photon, const edm::Event &e, double &trkCone, int &ntrkCone, double pTThresh=0, double RCone=.4, double RinnerCone=.1, double etaSlice=0.015, double lip=0.2, double d0=0.1) const
std::vector< double > moduleEtaBoundary_
void setVetoClustered(bool b=true)
edm::EDGetToken beamSpotProducerTag_
double getTowerEtSum(const reco::Candidate *cand, const std::vector< CaloTowerDetId > *detIdToExclude=0) const
double y0() const
y coordinate
const std::vector< CaloTowerDetId > & hcalTowersBehindClusters() const
static void classify(const reco::Photon *photon, bool &isEBPho, bool &isEEPho, bool &isEBEtaGap, bool &isEBPhiGap, bool &isEERingGap, bool &isEEDeeGap, bool &isEBEEGap)
double ecalIsoEndcapRadiusA_[5]
T const * product() const
double x0() const
x coordinate
double hcalIsoEndcapRadiusB_[9]
bool vetoClusteredEcalHits_