88 const uint32_t recHitFlag = hit.
flags();
93 if (severityLevel == 0)
114 int severityLevel = 999;
154 const edm::Handle<std::vector<reco::TrackExtrapolation> >& trackextrapcoll_h,
167 if (!objectvalidator.
validHit(*hit))
179 if (!objectvalidator.
validHit(*hit))
189 if (!objectvalidator.
validHit(*hit))
196 for (std::vector<reco::TrackExtrapolation>::const_iterator it = trackextrapcoll_h->begin();
197 it != trackextrapcoll_h->end();
212 if (std::fabs(
point.eta()) < 1.479) {
231 if (
id.ietaAbs() == 29)
237 std::set<PhysicsTower, towercmp>::iterator it =
towers_.find(dummy);
252 if (
id.ietaAbs() == 29)
258 std::set<PhysicsTower, towercmp>::iterator it =
towers_.find(dummy);
276 std::set<const PhysicsTower*>& neighbors)
const {
282 std::vector<CaloTowerDetId> ids;
284 if (
id.ietaAbs() <= 20) {
297 if (
id.ietaAbs() <= 20) {
310 if (
id.ietaAbs() == 20 && (
id.iphi() % 2) == 0)
316 if (
id.ietaAbs() == 21) {
319 }
else if (
id.ietaAbs() == 1) {
326 if (
id.ietaAbs() <= 19 || (
id.ietaAbs() == 20 && (
id.iphi() % 2) == 0)) {
331 }
else if (
id.ietaAbs() >= 21) {
339 if (
id.ietaAbs() <= 19) {
344 }
else if (
id.ietaAbs() >= 21 || (
id.ietaAbs() == 20 && (
id.iphi() % 2) == 1)) {
352 if (
id.ietaAbs() == 1) {
357 }
else if (
id.ietaAbs() <= 20) {
362 }
else if (
id.ietaAbs() >= 21) {
370 if (
id.ietaAbs() == 1) {
375 }
else if (
id.ietaAbs() <= 20) {
380 }
else if (
id.ietaAbs() >= 22) {
385 }
else if (
id.ietaAbs() == 21) {
396 for (std::vector<CaloTowerDetId>::const_iterator it = ids.begin(); it != ids.end(); ++it) {
399 neighbors.insert(twr);
417 if (twr ==
nullptr) {
419 if (
id.ietaAbs() == 29)
433 if (twr ==
nullptr) {
435 if (
id.ietaAbs() == 29)
449 if (twr ==
nullptr) {
451 if (
id.ietaAbs() == 29)
455 dummy.
tracks.insert(track);
458 twr->
tracks.insert(track);
535 for (std::set<const HBHERecHit*>::const_iterator it2 = it1->second->hcalhits.begin();
536 it2 != it1->second->hcalhits.end();
550 v.insert(it1->second->ecalhits.begin(), it1->second->ecalhits.end());
558 v.insert(it1->second->tracks.begin(), it1->second->tracks.end());
631 neighbors_.insert(neighbors.begin(), neighbors.end());
662 std::set<const HBHERecHit*>
v;
664 for (std::set<const HBHERecHit*>::const_iterator it = v.begin(); it != v.end(); ++it) {
675 std::set<const EcalRecHit*>
v;
677 for (std::set<const EcalRecHit*>::const_iterator it = v.begin(); it != v.end(); ++it) {
688 std::set<const reco::Track*>
v;
690 for (std::set<const reco::Track*>::const_iterator it = v.begin(); it != v.end(); ++it) {
701 std::set<const HBHERecHit*>
v;
703 for (std::set<const HBHERecHit*>::const_iterator it = v.begin(); it != v.end(); ++it) {
714 std::set<const EcalRecHit*>
v;
716 for (std::set<const EcalRecHit*>::const_iterator it = v.begin(); it != v.end(); ++it) {
727 std::set<const reco::Track*>
v;
729 for (std::set<const reco::Track*>::const_iterator it = v.begin(); it != v.end(); ++it) {
757 std::set<const PhysicsTower*> neighbors;
762 rbxs_[rbxidnum].insert(hit, tower, neighbors);
766 hpds_[hpdidnum].insert(hit, tower, neighbors);
769 std::vector<const HBHERecHit*> hpdneighbors;
772 if (hpdneighbors.size() == 1) {
773 std::vector<const HBHERecHit*> hpdneighborsneighbors;
776 if (hpdneighborsneighbors.size() == 1 && hpdneighborsneighbors[0] == hit &&
777 hit->
energy() > hpdneighbors[0]->energy()) {
782 const PhysicsTower* tower2 = pto.
findTower(hpdneighbors[0]->
id().ieta(), hpdneighbors[0]->
id().iphi());
783 std::set<const PhysicsTower*> neighbors2;
784 pto.
findNeighbors(hpdneighbors[0]->
id().ieta(), hpdneighbors[0]->
id().iphi(), neighbors2);
787 dihit.
insert(hit, tower, neighbors);
788 dihit.
insert(hpdneighbors[0], tower2, neighbors2);
791 }
else if (hpdneighbors.empty()) {
794 monohit.
insert(hit, tower, neighbors);
803 for (std::map<int, HBHEHitMap>::const_iterator it =
rbxs_.begin(); it !=
rbxs_.end(); ++it) {
812 for (std::map<int, HBHEHitMap>::const_iterator it =
hpds_.begin(); it !=
hpds_.end(); ++it) {
821 for (std::vector<HBHEHitMap>::const_iterator it =
dihits_.begin(); it !=
dihits_.end(); ++it) {
822 if (it->hitEnergy() >
energy)
829 for (std::vector<HBHEHitMap>::const_iterator it =
monohits_.begin(); it !=
monohits_.end(); ++it) {
830 if (it->hitEnergy() >
energy)
837 std::vector<const HBHERecHit*>& neighbors,
839 std::set<const PhysicsTower*>
temp;
846 for (std::set<const PhysicsTower*>::const_iterator it1 = temp.begin(); it1 != temp.end(); ++it1) {
847 for (std::set<const HBHERecHit*>::const_iterator it2 = (*it1)->hcalhits.begin(); it2 != (*it1)->hcalhits.end();
851 neighbors.push_back(hit2);
constexpr float energy() const
void getHPDNeighbors(const HBHERecHit *hit, std::vector< const HBHERecHit * > &neighbors, const PhysicsTowerOrganizer &pto)
double p() const
momentum vector magnitude
double hcalEnergySameTowers(void) const
std::set< const HBHERecHit * > hcalhits
const CaloSubdetectorGeometry * getSubdetectorGeometry(const DetId &id) const
access the subdetector geometry for the given subdetector directly
void tracksNeighborTowers(std::set< const reco::Track * > &v) const
double ecalEnergySameTowers_
int nHcalHitsSameTowers(void) const
constexpr int ietaAbs() const
get the absolute value of the cell ieta
uint16_t *__restrict__ id
EcalSeverityLevel::SeverityLevel severityLevel(const DetId &id) const
Evaluate status from id use channelStatus from DB.
constexpr uint32_t auxPhase1() const
double MinValidTrackPtBarrel_
std::map< const HBHERecHit *, const PhysicsTower * >::const_iterator hitmap_const_iterator
int ietaAbs() const
get the absolute value of the tower ieta
std::vector< HBHEHitMap > dihits_
hitmap_const_iterator findHit(const HBHERecHit *hit) const
constexpr const DetId & detid() const
PhysicsTowerOrganizer(const edm::Handle< HBHERecHitCollection > &hbhehitcoll_h, const edm::Handle< EcalRecHitCollection > &ebhitcoll_h, const edm::Handle< EcalRecHitCollection > &eehitcoll_h, const edm::Handle< std::vector< reco::TrackExtrapolation > > &trackextrapcoll_h, const ObjectValidatorAbs &objectvalidator, const CaloTowerConstituentsMap &ctcm, const CaloGeometry &geo)
void getHPDs(std::vector< HBHEHitMap > &v, double energy) const
HBHEHitMapOrganizer(const edm::Handle< HBHERecHitCollection > &hbhehitcoll_h, const ObjectValidatorAbs &objvalidator, const PhysicsTowerOrganizer &pto, const HcalFrontEndMap *hfemap)
neighbor_const_iterator findNeighbor(const PhysicsTower *twr) const
const int lookupRMIndex(DetId fId) const
const DetId & detid() const
std::vector< T >::const_iterator const_iterator
virtual bool validTrack(const reco::Track &) const =0
int nEcalHitsNeighborTowers(void) const
const Item * getValues(DetId fId, bool throwOnFail=true) const
neighbor_const_iterator beginNeighbors(void) const
double hcalEnergyNeighborTowers_
void getRBXs(std::vector< HBHEHitMap > &v, double energy) const
const Vector & momentum() const
track momentum vector
ObjectValidator(const edm::ParameterSet &)
void ecalHitsNeighborTowers(std::set< const EcalRecHit * > &v) const
void find(edm::Handle< EcalRecHitCollection > &hits, DetId thisDet, std::vector< EcalRecHitCollection::const_iterator > &hit, bool debug=false)
hitmap_const_iterator endHits(void) const
bool validHit(const HBHERecHit &) const override
std::map< const HBHERecHit *, const PhysicsTower * > hits_
bool UseAllCombinedRechits_
void getMonoHits(std::vector< HBHEHitMap > &v, double energy) const
void ecalHitsSameTowers(std::set< const EcalRecHit * > &v) const
double trackEnergyNeighborTowers_
void calcTracksSameTowers_(void) const
double trackEnergySameTowers_
uint32_t HcalAcceptSeverityLevel_
constexpr HcalSubdetector subdet() const
get the subdetector
double ecalEnergyNeighborTowers(void) const
std::set< const PhysicsTower * > neighbors_
void insert(const HBHERecHit *hit, const PhysicsTower *twr, std::set< const PhysicsTower * > &neighbors)
const PhysicsTower * findTower(const CaloTowerDetId &id) const
void tracksSameTowers(std::set< const reco::Track * > &v) const
const int lookupRBXIndex(DetId fId) const
int nHcalHitsNeighborTowers(void) const
CaloTowerDetId towerOf(const DetId &id) const
Get the tower id for this det id (or null if not known)
void calcHcalSameTowers_(void) const
std::map< int, HBHEHitMap > rbxs_
constexpr int iphi() const
get the cell iphi
bool UseHcalRecoveredHits_
int nEcalHitsNeighborTowers_
constexpr HcalDetId id() const
get the id
double pt() const
track transverse momentum
const EcalChannelStatus * theEcalChStatus_
bool recoveredRecHit(const DetId &myid, const uint32_t &myflag) const
const EcalRecHitCollection * theEERecHitCollection_
double hcalEnergyNeighborTowers(void) const
int iphi() const
get the tower iphi
double trackEnergySameTowers(void) const
void insert_(CaloTowerDetId &id, const HBHERecHit *hit)
constexpr int ieta() const
get the cell ieta
double hcalEnergySameTowers_
int nHcalHitsNeighborTowers_
unsigned short numberOfValidHits() const
number of valid hits found
const EcalRecHitCollection * theEBRecHitCollection_
std::set< const PhysicsTower * >::const_iterator neighbor_const_iterator
constexpr bool getBit(const uint32_t u, const unsigned bitnum)
std::map< int, HBHEHitMap > hpds_
~ObjectValidator() override
virtual DetId getClosestCell(const GlobalPoint &r) const
std::set< PhysicsTower, towercmp > towers_
double hitEnergy(void) const
void calcEcalSameTowers_(void) const
DetId id() const
get the id
virtual bool validHit(const HBHERecHit &) const =0
double ecalEnergyNeighborTowers_
void calcTracksNeighborTowers_(void) const
void calcHcalNeighborTowers_(void) const
T getParameter(std::string const &) const
int zside() const
get the z-side of the tower (1/-1)
const EcalSeverityLevelAlgo * theEcalSevLvlAlgo_
int getSeverityLevel(const DetId &myid, const uint32_t &myflag, const uint32_t &mystatus) const
std::set< const EcalRecHit * > ecalhits
uint32_t EcalAcceptSeverityLevel_
double trackEnergyNeighborTowers(void) const
bool validTrack(const reco::Track &) const override
double hitEnergyTrackFiducial(void) const
void calcHits_(void) const
std::set< const reco::Track * > tracks
void calcEcalNeighborTowers_(void) const
static const unsigned OFF_COMBINED
std::vector< HBHEHitMap > monohits_
int nTracksSameTowers(void) const
void getDiHits(std::vector< HBHEHitMap > &v, double energy) const
int nTracksNeighborTowers_
double ecalEnergySameTowers(void) const
const HcalChannelQuality * theHcalChStatus_
int nEcalHitsSameTowers(void) const
int nTracksNeighborTowers(void) const
uint32_t getValue() const
const HcalFrontEndMap * hfemap_
void hcalHitsSameTowers(std::set< const HBHERecHit * > &v) const
const HcalSeverityLevelComputer * theHcalSevLvlComputer_
constexpr uint32_t flags() const
void byTowers(std::vector< twrinfo > &v) const
neighbor_const_iterator endNeighbors(void) const
void findNeighbors(const CaloTowerDetId &id, std::set< const PhysicsTower * > &neighbors) const
*vegas h *****************************************************used in the default bin number in original ***version of VEGAS is ***a higher bin number might help to derive a more precise ***grade subtle point
hitmap_const_iterator beginHits(void) const
bool UseEcalRecoveredHits_
void hcalHitsNeighborTowers(std::set< const HBHERecHit * > &v) const