16 std::vector<double> blank;
19 std::vector<double> EnergyDefault;
20 EnergyDefault.clear();
21 EnergyDefault.push_back(50);
26 for (
int i=29;
i<=41;++
i)
35 for (
int i=29;
i<=41;++
i)
48 const std::vector<double>& short_Energy,
49 const std::vector<double>& short_ET,
50 const std::vector<double>& long_optimumSlope,
51 const std::vector<double>& long_Energy,
52 const std::vector<double>& long_ET,
96 double eta1 = etas.first;
97 double eta2 = etas.second;
98 double fEta = 0.5*(eta1 + eta2);
100 double ET = energy/fabs(cosh(fEta));
103 double ETthresh=0, Energythresh=0;
114 if (energy<Energythresh || ET < ETthresh)
125 if (neigh!=rec.
end())
137 for (
int d=1;
d<=2;++
d)
139 for (
int i=ieta-1;
i<=ieta+1;++
i)
144 if (
abs(ieta)==39 &&
abs(
i)>39 && testphi%4==1)
146 while (testphi<0) testphi+=72;
148 if (
d==depth ||
isS8S1_==
true)
continue;
154 if (neigh!=rec.
end())
160 S9S1+=neigh->energy();
168 if (
abs(ieta)>39) phiseg=4;
169 for (
int d=1;
d<=2;++
d)
171 for (
int i=iphi-phiseg;
i<=iphi+phiseg;
i+=phiseg)
173 if (
i==iphi)
continue;
176 while (testphi<0) testphi+=72;
177 while (testphi>72) testphi-=72;
181 if (neigh!=rec.
end())
187 S9S1+=neigh->energy();
194 for (
int d=1;
d<=2;++
d)
198 if (neigh!=rec.
end())
204 S9S1+=neigh->energy();
217 double intercept = 0;
224 if (intercept>0 && energy>0)
225 S9S1cut=-1.*slope*
log(intercept) + slope*
log(energy);
250 threshold+=params[
i]*
pow(static_cast<double>(abs_ieta), (
int)
i);
268 threshold+=params[
i]*
pow(abs_energy, (
int)
i);
tuple HcalAcceptSeverityLevel
std::vector< double > LongSlopes
void HFSetFlagFromS9S1(HFRecHit &hf, HFRecHitCollection &rec, const HcalChannelQuality *myqual, const HcalSeverityLevelComputer *mySeverity)
static const double slope[3]
void setFlagField(uint32_t value, int base, int width=1)
int HcalAcceptSeverityLevel_
std::vector< HFRecHit >::const_iterator const_iterator
std::vector< double > LongEnergyThreshold
const Item * getValues(DetId fId, bool throwOnFail=true) const
std::vector< double > LongETThreshold
bool neighbor(int endcap, int sector, int SectIndex, int id, int sub, int station)
int depth() const
get the tower depth
std::vector< double > ShortSlopes
double CalcSlope(int abs_ieta, const std::vector< double > ¶ms)
int ieta() const
get the cell ieta
Abs< T >::type abs(const T &t)
const_iterator end() const
int iphi() const
get the cell iphi
int getSeverityLevel(const DetId &myid, const uint32_t &myflag, const uint32_t &mystatus) const
std::pair< double, double > etaRange(HcalSubdetector subdet, int ieta) const
iterator find(key_type k)
std::vector< double > ShortETThreshold
std::vector< double > ShortEnergyThreshold
uint32_t getValue() const
Power< A, B >::type pow(const A &a, const B &b)
const HcalTopology * topo() const
double CalcEnergyThreshold(double abs_energy, const std::vector< double > ¶ms)