test
CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Member Functions | Private Member Functions | Private Attributes
HBHEPulseShapeFlagSetter Class Reference

#include <HBHEPulseShapeFlag.h>

Public Member Functions

void Clear ()
 
 HBHEPulseShapeFlagSetter (double MinimumChargeThreshold, double TS4TS5ChargeThreshold, double TS3TS4ChargeThreshold, double TS3TS4UpperChargeThreshold, double TS5TS6ChargeThreshold, double TS5TS6UpperChargeThreshold, double R45PlusOneRange, double R45MinusOneRange, unsigned int TrianglePeakTS, const std::vector< double > &LinearThreshold, const std::vector< double > &LinearCut, const std::vector< double > &RMS8MaxThreshold, const std::vector< double > &RMS8MaxCut, const std::vector< double > &LeftSlopeThreshold, const std::vector< double > &LeftSlopeCut, const std::vector< double > &RightSlopeThreshold, const std::vector< double > &RightSlopeCut, const std::vector< double > &RightSlopeSmallThreshold, const std::vector< double > &RightSlopeSmallCut, const std::vector< double > &TS4TS5UpperThreshold, const std::vector< double > &TS4TS5UpperCut, const std::vector< double > &TS4TS5LowerThreshold, const std::vector< double > &TS4TS5LowerCut, bool UseDualFit, bool TriangleIgnoreSlow, bool setLegacyFlags=true)
 
void Initialize ()
 
template<class Dataframe >
void SetPulseShapeFlags (HBHERecHit &hbhe, const Dataframe &digi, const HcalCoder &coder, const HcalCalibrations &calib)
 
 ~HBHEPulseShapeFlagSetter ()
 

Private Member Functions

double CalculateRMS8Max (const std::vector< double > &Charge)
 
bool CheckPassFilter (double Charge, double Discriminant, std::vector< std::pair< double, double > > &Cuts, int Side)
 
double DualNominalFitSingleTry (const std::vector< double > &Charge, int Offset, int Distance, bool newCharges=true)
 
double PerformDualNominalFit (const std::vector< double > &Charge)
 
double PerformLinearFit (const std::vector< double > &Charge)
 
double PerformNominalFit (const std::vector< double > &Charge)
 
TriangleFitResult PerformTriangleFit (const std::vector< double > &Charge)
 

Private Attributes

std::vector< double > CumulativeIdealPulse
 
std::vector< double > errors_
 
std::vector< double > f1_
 
std::vector< double > f2_
 
std::vector< double > mCharge
 
std::vector< std::pair< double,
double > > 
mLambdaLinearCut
 
std::vector< std::pair< double,
double > > 
mLambdaRMS8MaxCut
 
std::vector< std::pair< double,
double > > 
mLeftSlopeCut
 
double mMinimumChargeThreshold
 
double mR45MinusOneRange
 
double mR45PlusOneRange
 
std::vector< std::pair< double,
double > > 
mRightSlopeCut
 
std::vector< std::pair< double,
double > > 
mRightSlopeSmallCut
 
bool mSetLegacyFlags
 
bool mTriangleIgnoreSlow
 
int mTrianglePeakTS
 
double mTS3TS4ChargeThreshold
 
double mTS3TS4UpperChargeThreshold
 
double mTS4TS5ChargeThreshold
 
std::vector< std::pair< double,
double > > 
mTS4TS5LowerCut
 
std::vector< std::pair< double,
double > > 
mTS4TS5UpperCut
 
double mTS5TS6ChargeThreshold
 
double mTS5TS6UpperChargeThreshold
 
bool mUseDualFit
 

Detailed Description

Definition at line 29 of file HBHEPulseShapeFlag.h.

Constructor & Destructor Documentation

HBHEPulseShapeFlagSetter::HBHEPulseShapeFlagSetter ( double  MinimumChargeThreshold,
double  TS4TS5ChargeThreshold,
double  TS3TS4ChargeThreshold,
double  TS3TS4UpperChargeThreshold,
double  TS5TS6ChargeThreshold,
double  TS5TS6UpperChargeThreshold,
double  R45PlusOneRange,
double  R45MinusOneRange,
unsigned int  TrianglePeakTS,
const std::vector< double > &  LinearThreshold,
const std::vector< double > &  LinearCut,
const std::vector< double > &  RMS8MaxThreshold,
const std::vector< double > &  RMS8MaxCut,
const std::vector< double > &  LeftSlopeThreshold,
const std::vector< double > &  LeftSlopeCut,
const std::vector< double > &  RightSlopeThreshold,
const std::vector< double > &  RightSlopeCut,
const std::vector< double > &  RightSlopeSmallThreshold,
const std::vector< double > &  RightSlopeSmallCut,
const std::vector< double > &  TS4TS5UpperThreshold,
const std::vector< double > &  TS4TS5UpperCut,
const std::vector< double > &  TS4TS5LowerThreshold,
const std::vector< double > &  TS4TS5LowerCut,
bool  UseDualFit,
bool  TriangleIgnoreSlow,
bool  setLegacyFlags = true 
)

Definition at line 17 of file HBHEPulseShapeFlag.cc.

References i, Initialize(), mLambdaLinearCut, mLambdaRMS8MaxCut, mLeftSlopeCut, mMinimumChargeThreshold, mR45MinusOneRange, mR45PlusOneRange, mRightSlopeCut, mRightSlopeSmallCut, mSetLegacyFlags, mTriangleIgnoreSlow, mTrianglePeakTS, mTS3TS4ChargeThreshold, mTS3TS4UpperChargeThreshold, mTS4TS5ChargeThreshold, mTS4TS5LowerCut, mTS4TS5UpperCut, mTS5TS6ChargeThreshold, mTS5TS6UpperChargeThreshold, and mUseDualFit.

44 {
45  //
46  // The constructor that should be used
47  //
48  // Copies various thresholds and limits and parameters to the class for future use.
49  // Also calls the Initialize() function
50  //
51 
52  mMinimumChargeThreshold = MinimumChargeThreshold;
53  mTS4TS5ChargeThreshold = TS4TS5ChargeThreshold;
54  mTS3TS4ChargeThreshold = TS3TS4ChargeThreshold;
55  mTS3TS4UpperChargeThreshold = TS3TS4UpperChargeThreshold;
56  mTS5TS6ChargeThreshold = TS5TS6ChargeThreshold;
57  mTS5TS6UpperChargeThreshold = TS5TS6UpperChargeThreshold;
58  mR45PlusOneRange = R45PlusOneRange;
59  mR45MinusOneRange = R45MinusOneRange;
60  mTrianglePeakTS = TrianglePeakTS;
61  mTriangleIgnoreSlow = TriangleIgnoreSlow;
62  mSetLegacyFlags = setLegacyFlags;
63 
64  for(std::vector<double>::size_type i = 0; i < LinearThreshold.size() && i < LinearCut.size(); i++)
65  mLambdaLinearCut.push_back(std::pair<double, double>(LinearThreshold[i], LinearCut[i]));
66  sort(mLambdaLinearCut.begin(), mLambdaLinearCut.end());
67 
68  for(std::vector<double>::size_type i = 0; i < RMS8MaxThreshold.size() && i < RMS8MaxCut.size(); i++)
69  mLambdaRMS8MaxCut.push_back(std::pair<double, double>(RMS8MaxThreshold[i], RMS8MaxCut[i]));
70  sort(mLambdaRMS8MaxCut.begin(), mLambdaRMS8MaxCut.end());
71 
72  for(std::vector<double>::size_type i = 0; i < LeftSlopeThreshold.size() && i < LeftSlopeCut.size(); i++)
73  mLeftSlopeCut.push_back(std::pair<double, double>(LeftSlopeThreshold[i], LeftSlopeCut[i]));
74  sort(mLeftSlopeCut.begin(), mLeftSlopeCut.end());
75 
76  for(std::vector<double>::size_type i = 0; i < RightSlopeThreshold.size() && i < RightSlopeCut.size(); i++)
77  mRightSlopeCut.push_back(std::pair<double, double>(RightSlopeThreshold[i], RightSlopeCut[i]));
78  sort(mRightSlopeCut.begin(), mRightSlopeCut.end());
79 
80  for(std::vector<double>::size_type i = 0; i < RightSlopeSmallThreshold.size() && i < RightSlopeSmallCut.size(); i++)
81  mRightSlopeSmallCut.push_back(std::pair<double, double>(RightSlopeSmallThreshold[i], RightSlopeSmallCut[i]));
82  sort(mRightSlopeSmallCut.begin(), mRightSlopeSmallCut.end());
83 
84  for(std::vector<double>::size_type i = 0; i < TS4TS5UpperThreshold.size() && i < TS4TS5UpperCut.size(); i++)
85  mTS4TS5UpperCut.push_back(std::pair<double, double>(TS4TS5UpperThreshold[i], TS4TS5UpperCut[i]));
86  sort(mTS4TS5UpperCut.begin(), mTS4TS5UpperCut.end());
87 
88  for(std::vector<double>::size_type i = 0; i < TS4TS5LowerThreshold.size() && i < TS4TS5LowerCut.size(); i++)
89  mTS4TS5LowerCut.push_back(std::pair<double, double>(TS4TS5LowerThreshold[i], TS4TS5LowerCut[i]));
90  sort(mTS4TS5LowerCut.begin(), mTS4TS5LowerCut.end());
91 
92  mUseDualFit = UseDualFit;
93 
94  Initialize();
95 }
int i
Definition: DBlmapReader.cc:9
std::vector< std::pair< double, double > > mLambdaLinearCut
std::vector< std::pair< double, double > > mTS4TS5LowerCut
uint16_t size_type
std::vector< std::pair< double, double > > mLeftSlopeCut
std::vector< std::pair< double, double > > mRightSlopeCut
std::vector< std::pair< double, double > > mRightSlopeSmallCut
std::vector< std::pair< double, double > > mLambdaRMS8MaxCut
std::vector< std::pair< double, double > > mTS4TS5UpperCut
HBHEPulseShapeFlagSetter::~HBHEPulseShapeFlagSetter ( )

Definition at line 97 of file HBHEPulseShapeFlag.cc.

98 {
99  // Dummy destructor - there's nothing to destruct by hand here
100 }

Member Function Documentation

double HBHEPulseShapeFlagSetter::CalculateRMS8Max ( const std::vector< double > &  Charge)
private

Definition at line 480 of file HBHEPulseShapeFlag.cc.

References alignCSCRings::e, i, RMS, and mathSSE::sqrt().

Referenced by SetPulseShapeFlags().

481 {
482  //
483  // CalculateRMS8Max
484  //
485  // returns "RMS" divided by the largest charge in the time slices
486  // "RMS" is calculated using all but the two largest time slices.
487  // The "RMS" is not quite the actual RMS (see note below), but the value is only
488  // used for determining max values, and is not quoted as the actual RMS anywhere.
489  //
490 
491  int DigiSize = Charge.size();
492 
493  if (DigiSize<=2) return 1e-5; // default statement when DigiSize is too small for useful RMS calculation
494  // Copy Charge vector again, since we are passing references around
495  std::vector<double> TempCharge = Charge;
496 
497  // Sort TempCharge vector from smallest to largest charge
498  sort(TempCharge.begin(), TempCharge.end());
499 
500  double Total = 0;
501  double Total2 = 0;
502  for(int i = 0; i < DigiSize - 2; i++)
503  {
504  Total = Total + TempCharge[i];
505  Total2 = Total2 + TempCharge[i] * TempCharge[i];
506  }
507 
508  // This isn't quite the RMS (both Total2 and Total*Total need to be
509  // divided by an extra (DigiSize-2) within the sqrt to get the RMS.)
510  // We're only using this value for relative comparisons, though; we
511  // aren't explicitly interpreting it as the RMS. It might be nice
512  // to either change the calculation or rename the variable in the future, though.
513 
514  double RMS = sqrt(Total2 - Total * Total / (DigiSize - 2));
515 
516  double RMS8Max = RMS / TempCharge[DigiSize-1];
517  if(RMS8Max < 1e-5) // protection against zero
518  RMS8Max = 1e-5;
519 
520  return RMS8Max;
521 }
int i
Definition: DBlmapReader.cc:9
T sqrt(T t)
Definition: SSEVec.h:18
bool HBHEPulseShapeFlagSetter::CheckPassFilter ( double  Charge,
double  Discriminant,
std::vector< std::pair< double, double > > &  Cuts,
int  Side 
)
private

Definition at line 584 of file HBHEPulseShapeFlag.cc.

References plotBeamSpotDB::first, i, and MessageLogger_cff::limit.

Referenced by SetPulseShapeFlags().

588 {
589  //
590  // Checks whether Discriminant value passes Cuts for the specified Charge. True if pulse is good.
591  //
592  // The "Cuts" pairs are assumed to be sorted in terms of size from small to large,
593  // where each "pair" = (Charge, Discriminant)
594  // "Side" is either positive or negative, which determines whether to discard the pulse if discriminant
595  // is greater or smaller than the cut value
596  //
597 
598  if(Cuts.size() == 0) // safety check that there are some cuts defined
599  return true;
600 
601  if(Charge <= Cuts[0].first) // too small to cut on
602  return true;
603 
604  int IndexLargerThanCharge = -1; // find the range it is falling in
605  for(int i = 1; i < (int)Cuts.size(); i++)
606  {
607  if(Cuts[i].first > Charge)
608  {
609  IndexLargerThanCharge = i;
610  break;
611  }
612  }
613 
614  double limit = 1000000;
615 
616  if(IndexLargerThanCharge == -1) // if charge is greater than the last entry, assume flat line
617  limit = Cuts[Cuts.size()-1].second;
618  else // otherwise, do a linear interpolation to find the cut position
619  {
620  double C1 = Cuts[IndexLargerThanCharge].first;
621  double C2 = Cuts[IndexLargerThanCharge-1].first;
622  double L1 = Cuts[IndexLargerThanCharge].second;
623  double L2 = Cuts[IndexLargerThanCharge-1].second;
624 
625  limit = (Charge - C1) / (C2 - C1) * (L2 - L1) + L1;
626  }
627 
628  if(Side > 0 && Discriminant > limit)
629  return false;
630  if(Side < 0 && Discriminant < limit)
631  return false;
632 
633  return true;
634 }
int i
Definition: DBlmapReader.cc:9
void HBHEPulseShapeFlagSetter::Clear ( )

Definition at line 102 of file HBHEPulseShapeFlag.cc.

103 {
104  // Dummy function in case something needs to be cleaned....but none right now
105 }
double HBHEPulseShapeFlagSetter::DualNominalFitSingleTry ( const std::vector< double > &  Charge,
int  Offset,
int  Distance,
bool  newCharges = true 
)
private

Definition at line 386 of file HBHEPulseShapeFlag.cc.

References CumulativeIdealPulse, alignCSCRings::e, errors_, f1_, f2_, and j.

Referenced by PerformDualNominalFit().

387 {
388  //
389  // Does a fit to dual signal pulse hypothesis given offset and distance of the two target pulses
390  //
391  // The only parameters to fit here are the two pulse heights of in-time and out-of-time components
392  // since offset is given
393  // The calculation here is based from writing down the Chi2 formula and minimize against the two parameters,
394  // ie., Chi2 = Sum{((T[i] - a1 * F1[i] - a2 * F2[i]) / (Sigma[i]))^2}, where T[i] is the input pulse shape,
395  // and F1[i], F2[i] are the two ideal pulse components
396  //
397 
398  int DigiSize = Charge.size();
399 
400  if(Offset < 0 || Offset + 250 >= (int)CumulativeIdealPulse.size())
401  return 1000000;
402  if(CumulativeIdealPulse[Offset+250] - CumulativeIdealPulse[Offset] < 1e-5)
403  return 1000000;
404 
405  if ( newCharges) {
406  f1_.resize(DigiSize);
407  f2_.resize(DigiSize);
408  errors_.resize(DigiSize);
409  for(int j = 0; j < DigiSize; j++)
410  {
411  errors_[j] = Charge[j];
412  if(errors_[j] < 1)
413  errors_[j] = 1;
414  errors_[j]=1.0/errors_[j];
415  }
416  }
417 
418  double SumF1F1 = 0;
419  double SumF1F2 = 0;
420  double SumF2F2 = 0;
421  double SumTF1 = 0;
422  double SumTF2 = 0;
423 
424  unsigned int cipSize=CumulativeIdealPulse.size();
425  for(int j = 0; j < DigiSize; j++)
426  {
427  // this is the TS value for in-time component - no problem we can do a subtraction directly
428  f1_[j] = CumulativeIdealPulse[Offset+j*25+25] - CumulativeIdealPulse[Offset+j*25];
429 
430  // However for the out-of-time component the index might go out-of-bound.
431  // Let's protect against this.
432 
433  int OffsetTemp = Offset + j * 25 + Distance;
434 
435  double C1 = 0; // lower-indexed value in the cumulative pulse shape
436  double C2 = 0; // higher-indexed value in the cumulative pulse shape
437 
438 
439  if(OffsetTemp + 25 >= (int)cipSize)
440  C1 = CumulativeIdealPulse[cipSize-1];
441  else
442  if( OffsetTemp >= -25)
443  C1 = CumulativeIdealPulse[OffsetTemp+25];
444  if(OffsetTemp >= (int)cipSize)
445  C2 = CumulativeIdealPulse[cipSize-1];
446  else
447  if( OffsetTemp >= 0)
448  C2 = CumulativeIdealPulse[OffsetTemp];
449  f2_[j] = C1 - C2;
450 
451  SumF1F1 += f1_[j] * f1_[j] * errors_[j];
452  SumF1F2 += f1_[j] * f2_[j] * errors_[j];
453  SumF2F2 += f2_[j] * f2_[j] * errors_[j];
454  SumTF1 += f1_[j] * Charge[j] * errors_[j];
455  SumTF2 += f2_[j] * Charge[j] * errors_[j];
456  }
457 
458  double Height = 0;
459  double Height2 = 0;
460  if (fabs(SumF1F2*SumF1F2-SumF1F1*SumF2F2)>1e-5)
461  {
462  Height = (SumF1F2 * SumTF2 - SumF2F2 * SumTF1) / (SumF1F2 * SumF1F2 - SumF1F1 * SumF2F2);
463  Height2 = (SumF1F2 * SumTF1 - SumF1F1 * SumTF2) / (SumF1F2 * SumF1F2 - SumF1F1 * SumF2F2);
464  }
465 
466  double Chi2 = 0;
467  for(int j = 0; j < DigiSize; j++)
468  {
469  double Residual = Height * f1_[j] + Height2 * f2_[j] - Charge[j];
470  Chi2 += Residual * Residual *errors_[j];
471  }
472 
473  // Safety protection in case of zero
474  if(Chi2 < 1e-5)
475  Chi2 = 1e-5;
476 
477  return Chi2;
478 }
std::vector< double > f1_
std::vector< double > f2_
int j
Definition: DBlmapReader.cc:9
std::vector< double > errors_
std::vector< double > CumulativeIdealPulse
Definition: Chi2.h:17
void HBHEPulseShapeFlagSetter::Initialize ( )

Definition at line 107 of file HBHEPulseShapeFlag.cc.

References HcalPulseShape::at(), CumulativeIdealPulse, HcalPulseShapes::hbShape(), i, and mCharge.

Referenced by HBHEPulseShapeFlagSetter().

108 {
109  //
110  // Initialization: whatever preprocess is needed
111  //
112  // 1. Get the ideal pulse shape from CMSSW
113  //
114  // Since the HcalPulseShapes class stores the ideal pulse shape in terms of 256 numbers,
115  // each representing 1ns integral of the ideal pulse, here I'm taking out the vector
116  // by calling at() function.
117  //
118  // A cumulative distribution is formed and stored to save some time doing integration to TS later on
119  //
120  // 2. Reserve space for vector
121  //
122 
123  std::vector<double> PulseShape;
124 
125  HcalPulseShapes Shapes;
126  HcalPulseShapes::Shape HPDShape = Shapes.hbShape();
127 
128  PulseShape.reserve(350);
129  for(int i = 0; i < 200; i++)
130  PulseShape.push_back(HPDShape.at(i));
131  PulseShape.insert(PulseShape.begin(), 150, 0); // Safety margin of a lot of zeros in the beginning
132 
133  CumulativeIdealPulse.reserve(350);
134  CumulativeIdealPulse.clear();
135  CumulativeIdealPulse.push_back(0);
136  for(unsigned int i = 1; i < PulseShape.size(); i++)
137  CumulativeIdealPulse.push_back(CumulativeIdealPulse[i-1] + PulseShape[i]);
138 
139  // reserve space for vector
140  mCharge.reserve(10);
141 }
int i
Definition: DBlmapReader.cc:9
float at(double time) const
std::vector< double > mCharge
const Shape & hbShape() const
std::vector< double > CumulativeIdealPulse
double HBHEPulseShapeFlagSetter::PerformDualNominalFit ( const std::vector< double > &  Charge)
private

Definition at line 336 of file HBHEPulseShapeFlag.cc.

References CumulativeIdealPulse, DualNominalFitSingleTry(), i, cuy::isFirst, and relval_2017::k.

Referenced by SetPulseShapeFlags().

337 {
338  //
339  // Perform dual nominal fit and returns the chi2
340  //
341  // In this function we do a scan over possible "distance" (number of time slices between two components)
342  // and overall offset for the two components; first coarse, then finer
343  // All the fitting is done in the DualNominalFitSingleTry function
344  //
345 
346  double OverallMinimumChi2 = 1000000;
347 
348  int AvailableDistance[] = {-100, -75, -50, 50, 75, 100};
349 
350  // loop over possible pulse distances between two components
351  bool isFirst=true;
352 
353  for(int k = 0; k < 6; k++)
354  {
355  double SingleMinimumChi2 = 1000000;
356  int MinOffset = 0;
357 
358  // scan coarsely through different offsets and find the minimum
359  for(int i = 0; i + 250 < (int)CumulativeIdealPulse.size(); i += 10)
360  {
361  double Chi2 = DualNominalFitSingleTry(Charge, i, AvailableDistance[k],isFirst);
362  isFirst=false;
363  if(Chi2 < SingleMinimumChi2)
364  {
365  SingleMinimumChi2 = Chi2;
366  MinOffset = i;
367  }
368  }
369 
370  // around the minimum, scan finer for better a better minimum
371  for(int i = MinOffset - 15; i + 250 < (int)CumulativeIdealPulse.size() && i < MinOffset + 15; i++)
372  {
373  double Chi2 = DualNominalFitSingleTry(Charge, i, AvailableDistance[k],false);
374  if(Chi2 < SingleMinimumChi2)
375  SingleMinimumChi2 = Chi2;
376  }
377 
378  // update overall minimum chi2
379  if(SingleMinimumChi2 < OverallMinimumChi2)
380  OverallMinimumChi2 = SingleMinimumChi2;
381  }
382 
383  return OverallMinimumChi2;
384 }
int i
Definition: DBlmapReader.cc:9
isFirst
Definition: cuy.py:417
double DualNominalFitSingleTry(const std::vector< double > &Charge, int Offset, int Distance, bool newCharges=true)
std::vector< double > CumulativeIdealPulse
Definition: Chi2.h:17
double HBHEPulseShapeFlagSetter::PerformLinearFit ( const std::vector< double > &  Charge)
private

Definition at line 523 of file HBHEPulseShapeFlag.cc.

References alignCSCRings::e, and i.

Referenced by SetPulseShapeFlags().

524 {
525  //
526  // Performs a straight-line fit over all time slices, and returns the chi2 value
527  //
528  // The calculation here is based from writing down the formula for chi2 and minimize
529  // with respect to the parameters in the fit, ie., slope and intercept of the straight line
530  // By doing two differentiation, we will get two equations, and the best parameters are determined by these
531  //
532 
533  int DigiSize = Charge.size();
534 
535  double SumTS2OverTi = 0;
536  double SumTSOverTi = 0;
537  double SumOverTi = 0;
538  double SumTiTS = 0;
539  double SumTi = 0;
540 
541  double Error2 = 0;
542  for(int i = 0; i < DigiSize; i++)
543  {
544  Error2 = Charge[i];
545  if(Charge[i] < 1)
546  Error2 = 1;
547 
548  SumTS2OverTi += 1.* i * i / Error2;
549  SumTSOverTi += 1.* i / Error2;
550  SumOverTi += 1. / Error2;
551  SumTiTS += Charge[i] * i / Error2;
552  SumTi += Charge[i] / Error2;
553  }
554 
555  double CM1 = SumTS2OverTi; // Coefficient in front of slope in equation 1
556  double CM2 = SumTSOverTi; // Coefficient in front of slope in equation 2
557  double CD1 = SumTSOverTi; // Coefficient in front of intercept in equation 1
558  double CD2 = SumOverTi; // Coefficient in front of intercept in equation 2
559  double C1 = SumTiTS; // Constant coefficient in equation 1
560  double C2 = SumTi; // Constant coefficient in equation 2
561 
562  // Denominators always non-zero by construction
563  double Slope = (C1 * CD2 - C2 * CD1) / (CM1 * CD2 - CM2 * CD1);
564  double Intercept = (C1 * CM2 - C2 * CM1) / (CD1 * CM2 - CD2 * CM1);
565 
566  // now that the best parameters are found, calculate chi2 from those
567  double Chi2 = 0;
568  for(int i = 0; i < DigiSize; i++)
569  {
570  double Deviation = Slope * i + Intercept - Charge[i];
571  double Error2 = Charge[i];
572  if(Charge[i] < 1)
573  Error2 = 1;
574  Chi2 += Deviation * Deviation / Error2;
575  }
576 
577  // safety protection in case of perfect fit
578  if(Chi2 < 1e-5)
579  Chi2 = 1e-5;
580 
581  return Chi2;
582 }
int i
Definition: DBlmapReader.cc:9
Definition: Chi2.h:17
double HBHEPulseShapeFlagSetter::PerformNominalFit ( const std::vector< double > &  Charge)
private

Definition at line 269 of file HBHEPulseShapeFlag.cc.

References CumulativeIdealPulse, alignCSCRings::e, F(), i, and j.

Referenced by SetPulseShapeFlags().

270 {
271  //
272  // Performs a fit to the ideal pulse shape. Returns best chi2
273  //
274  // A scan over different timing offset (for the ideal pulse) is carried out,
275  // and for each offset setting a one-parameter fit is performed
276  //
277 
278  int DigiSize = Charge.size();
279 
280  double MinimumChi2 = 100000;
281 
282  double F = 0;
283 
284  double SumF2 = 0;
285  double SumTF = 0;
286  double SumT2 = 0;
287 
288  for(int i = 0; i + 250 < (int)CumulativeIdealPulse.size(); i++)
289  {
291  continue;
292 
293  SumF2 = 0;
294  SumTF = 0;
295  SumT2 = 0;
296 
297  double ErrorTemp=0;
298  for(int j = 0; j < DigiSize; j++)
299  {
300  // get ideal pulse component for this time slice....
301  F = CumulativeIdealPulse[i+j*25+25] - CumulativeIdealPulse[i+j*25];
302 
303  ErrorTemp=Charge[j];
304  if (ErrorTemp<1) // protection against small charges
305  ErrorTemp=1;
306  // ...and increment various summations
307  SumF2 += F * F / ErrorTemp;
308  SumTF += F * Charge[j] / ErrorTemp;
309  SumT2 += fabs(Charge[j]);
310  }
311 
312  /*
313  chi2= sum((Charge[j]-aF)^2/|Charge[j]|
314  ( |Charge[j]| = assumed sigma^2 for Charge[j]; a bit wonky for Charge[j]<1 )
315  chi2 = sum(|Charge[j]|) - 2*sum(aF*Charge[j]/|Charge[j]|) +sum( a^2*F^2/|Charge[j]|)
316  chi2 minimimized when d(chi2)/da = 0:
317  a = sum(F*Charge[j])/sum(F^2)
318  ...
319  chi2= sum(|Q[j]|) - sum(Q[j]/|Q[j]|*F)*sum(Q[j]/|Q[j]|*F)/sum(F^2/|Q[j]|), where Q = Charge
320  chi2 = SumT2 - SumTF*SumTF/SumF2
321  */
322 
323  double Chi2 = SumT2 - SumTF * SumTF / SumF2;
324 
325  if(Chi2 < MinimumChi2)
326  MinimumChi2 = Chi2;
327  }
328 
329  // safety protection in case of perfect fit - don't want the log(...) to explode
330  if(MinimumChi2 < 1e-5)
331  MinimumChi2 = 1e-5;
332 
333  return MinimumChi2;
334 }
int i
Definition: DBlmapReader.cc:9
int j
Definition: DBlmapReader.cc:9
std::vector< double > CumulativeIdealPulse
static uInt32 F(BLOWFISH_CTX *ctx, uInt32 x)
Definition: blowfish.cc:281
Definition: Chi2.h:17
TriangleFitResult HBHEPulseShapeFlagSetter::PerformTriangleFit ( const std::vector< double > &  Charge)
private

Definition at line 143 of file HBHEPulseShapeFlag.cc.

References TriangleFitResult::Chi2, i, TriangleFitResult::LeftSlope, mTrianglePeakTS, mps_fire::result, and TriangleFitResult::RightSlope.

Referenced by SetPulseShapeFlags().

144 {
145  //
146  // Perform a "triangle fit", and extract the slopes
147  //
148  // Left-hand side and right-hand side are not correlated to each other - do them separately
149  //
150 
152  result.Chi2 = 0;
153  result.LeftSlope = 0;
154  result.RightSlope = 0;
155 
156  int DigiSize = Charge.size();
157 
158  // right side, starting from TS4
159  double MinimumRightChi2 = 1000000;
160  double Numerator = 0;
161  double Denominator = 0;
162 
163  for(int iTS = mTrianglePeakTS + 2; iTS <= DigiSize; iTS++) // the place where first TS center in flat line
164  {
165  // fit a straight line to the triangle part
166  Numerator = 0;
167  Denominator = 0;
168 
169  for(int i = mTrianglePeakTS + 1; i < iTS; i++)
170  {
171  Numerator += (i - mTrianglePeakTS) * (Charge[i] - Charge[mTrianglePeakTS]);
172  Denominator += (i - mTrianglePeakTS) * (i - mTrianglePeakTS);
173  }
174 
175  double BestSlope = 0;
176  if (Denominator!=0) BestSlope = Numerator / Denominator;
177  if(BestSlope > 0)
178  BestSlope = 0;
179 
180  // check if the slope is reasonable
181  if(iTS != DigiSize)
182  {
183  // iTS starts at mTrianglePeak+2; denominator never zero
184  if(BestSlope > -1 * Charge[mTrianglePeakTS] / (iTS - mTrianglePeakTS))
185  BestSlope = -1 * Charge[mTrianglePeakTS] / (iTS - mTrianglePeakTS);
186  if(BestSlope < -1 * Charge[mTrianglePeakTS] / (iTS - 1 - mTrianglePeakTS))
187  BestSlope = -1 * Charge[mTrianglePeakTS] / (iTS - 1 - mTrianglePeakTS);
188  }
189  else
190  {
191  // iTS starts at mTrianglePeak+2; denominator never zero
192  if(BestSlope < -1 * Charge[mTrianglePeakTS] / (iTS - 1 - mTrianglePeakTS))
193  BestSlope = -1 * Charge[mTrianglePeakTS] / (iTS - 1 - mTrianglePeakTS);
194  }
195 
196  // calculate partial chi2
197 
198  // The shape I'm fitting is more like a tent than a triangle.
199  // After the end of triangle edge assume a flat line
200 
201  double Chi2 = 0;
202  for(int i = mTrianglePeakTS + 1; i < iTS; i++)
203  Chi2 += (Charge[mTrianglePeakTS] - Charge[i] + (i - mTrianglePeakTS) * BestSlope)
204  * (Charge[mTrianglePeakTS] - Charge[i] + (i - mTrianglePeakTS) * BestSlope);
205  for(int i = iTS; i < DigiSize; i++) // Assumes fit line = 0 for iTS > fit
206  Chi2 += Charge[i] * Charge[i];
207 
208  if(Chi2 < MinimumRightChi2)
209  {
210  MinimumRightChi2 = Chi2;
211  result.RightSlope = BestSlope;
212  }
213  } // end of right-hand side loop
214 
215  // left side
216  double MinimumLeftChi2 = 1000000;
217 
218  for(int iTS = 0; iTS < (int)mTrianglePeakTS; iTS++) // the first time after linear fit ends
219  {
220  // fit a straight line to the triangle part
221  Numerator = 0;
222  Denominator = 0;
223  for(int i = iTS; i < (int)mTrianglePeakTS; i++)
224  {
225  Numerator = Numerator + (i - mTrianglePeakTS) * (Charge[i] - Charge[mTrianglePeakTS]);
226  Denominator = Denominator + (i - mTrianglePeakTS) * (i - mTrianglePeakTS);
227  }
228 
229  double BestSlope = 0;
230  if (Denominator!=0) BestSlope = Numerator / Denominator;
231  if (BestSlope < 0)
232  BestSlope = 0;
233 
234  // check slope
235  if(iTS != 0)
236  {
237  // iTS must be >0 and < mTrianglePeakTS; slope never 0
238  if(BestSlope > Charge[mTrianglePeakTS] / (mTrianglePeakTS - iTS))
239  BestSlope = Charge[mTrianglePeakTS] / (mTrianglePeakTS - iTS);
240  if(BestSlope < Charge[mTrianglePeakTS] / (mTrianglePeakTS + 1 - iTS))
241  BestSlope = Charge[mTrianglePeakTS] / (mTrianglePeakTS + 1 - iTS);
242  }
243  else
244  {
245  if(BestSlope > Charge[mTrianglePeakTS] / (mTrianglePeakTS - iTS))
246  BestSlope = Charge[mTrianglePeakTS] / (mTrianglePeakTS - iTS);
247  }
248 
249  // calculate minimum chi2
250  double Chi2 = 0;
251  for(int i = 0; i < iTS; i++)
252  Chi2 += Charge[i] * Charge[i];
253  for(int i = iTS; i < (int)mTrianglePeakTS; i++)
254  Chi2 += (Charge[mTrianglePeakTS] - Charge[i] + (i - mTrianglePeakTS) * BestSlope)
255  * (Charge[mTrianglePeakTS] - Charge[i] + (i - mTrianglePeakTS) * BestSlope);
256 
257  if(MinimumLeftChi2 > Chi2)
258  {
259  MinimumLeftChi2 = Chi2;
260  result.LeftSlope = BestSlope;
261  }
262  } // end of left-hand side loop
263 
264  result.Chi2 = MinimumLeftChi2 + MinimumRightChi2;
265 
266  return result;
267 }
int i
Definition: DBlmapReader.cc:9
tuple result
Definition: mps_fire.py:84
Definition: Chi2.h:17
template<class Dataframe >
void HBHEPulseShapeFlagSetter::SetPulseShapeFlags ( HBHERecHit hbhe,
const Dataframe &  digi,
const HcalCoder coder,
const HcalCalibrations calib 
)

Definition at line 115 of file HBHEPulseShapeFlag.h.

References HcalCoder::adc2fC(), CalculateRMS8Max(), CheckPassFilter(), alignCSCRings::e, HcalCaloFlagLabels::HBHEFlatNoise, HcalCaloFlagLabels::HBHEOOTPU, HcalCaloFlagLabels::HBHESpikeNoise, HcalCaloFlagLabels::HBHETriangleNoise, HcalCaloFlagLabels::HBHETS4TS5Noise, i, HBHERecHit::id(), HcalDetId::ietaAbs(), TriangleFitResult::LeftSlope, dqm-mbProfile::log, mCharge, mLambdaLinearCut, mLambdaRMS8MaxCut, mLeftSlopeCut, mMinimumChargeThreshold, mR45MinusOneRange, mR45PlusOneRange, mRightSlopeCut, mRightSlopeSmallCut, mSetLegacyFlags, mTriangleIgnoreSlow, mTrianglePeakTS, mTS3TS4ChargeThreshold, mTS3TS4UpperChargeThreshold, mTS4TS5ChargeThreshold, mTS4TS5LowerCut, mTS4TS5UpperCut, mTS5TS6ChargeThreshold, mTS5TS6UpperChargeThreshold, mUseDualFit, HcalCalibrations::pedestal(), PerformDualNominalFit(), PerformLinearFit(), PerformNominalFit(), PerformTriangleFit(), TriangleFitResult::RightSlope, and CaloRecHit::setFlagField().

Referenced by HcalHitReconstructor::produce().

118 {
119  //
120  // Decide if a digi/pulse is good or bad using fit-based discriminants
121  //
122  // SetPulseShapeFlags determines the total charge in the digi.
123  // If the charge is above the minimum threshold, the code then
124  // runs the flag-setting algorithms to determine whether the
125  // flags should be set.
126  //
127 
128  // hack to exclude ieta=28/29 for the moment...
129  int abseta = hbhe.id().ietaAbs();
130  if(abseta == 28 || abseta == 29) return;
131 
132  CaloSamples Tool;
133  coder.adc2fC(digi, Tool);
134 
135  // mCharge.clear(); // mCharge is a vector of (pedestal-subtracted) Charge values vs. time slice
136  const unsigned nRead = digi.size();
137  mCharge.resize(nRead);
138 
139  double TotalCharge = 0.0;
140  for (unsigned i = 0; i < nRead; ++i)
141  {
142  mCharge[i] = Tool[i] - calib.pedestal(digi[i].capid());
143  TotalCharge += mCharge[i];
144  }
145 
146  // No flagging if TotalCharge is less than threshold
147  if(TotalCharge < mMinimumChargeThreshold)
148  return;
149 
150  if (mSetLegacyFlags)
151  {
152  double NominalChi2 = 0;
153  if (mUseDualFit == true)
154  NominalChi2=PerformDualNominalFit(mCharge);
155  else
156  NominalChi2=PerformNominalFit(mCharge);
157 
158  double LinearChi2 = PerformLinearFit(mCharge);
159 
160  double RMS8Max = CalculateRMS8Max(mCharge);
161 
162  // Set the HBHEFlatNoise and HBHESpikeNoise flags
163  if(CheckPassFilter(TotalCharge, log(LinearChi2) - log(NominalChi2), mLambdaLinearCut, -1) == false)
165  if(CheckPassFilter(TotalCharge, log(RMS8Max) * 2 - log(NominalChi2), mLambdaRMS8MaxCut, -1) == false)
167 
168  // Set the HBHETriangleNoise flag
169  if ((int)mCharge.size() >= mTrianglePeakTS) // can't compute flag if peak TS isn't present; revise this at some point?
170  {
171  TriangleFitResult TriangleResult = PerformTriangleFit(mCharge);
172 
173  // initial values
174  double TS4Left = 1000;
175  double TS4Right = 1000;
176 
177  // Use 'if' statements to protect against slopes that are either 0 or very small
178  if (TriangleResult.LeftSlope > 1e-5)
179  TS4Left = mCharge[mTrianglePeakTS] / TriangleResult.LeftSlope;
180  if (TriangleResult.RightSlope < -1e-5)
181  TS4Right = mCharge[mTrianglePeakTS] / -TriangleResult.RightSlope;
182 
183  if(TS4Left > 1000 || TS4Left < -1000)
184  TS4Left = 1000;
185  if(TS4Right > 1000 || TS4Right < -1000)
186  TS4Right = 1000;
187 
188  if(mTriangleIgnoreSlow == false) // the slow-rising and slow-dropping edges won't be useful in 50ns/75ns
189  {
190  if(CheckPassFilter(mCharge[mTrianglePeakTS], TS4Left, mLeftSlopeCut, 1) == false)
192  else if(CheckPassFilter(mCharge[mTrianglePeakTS], TS4Right, mRightSlopeCut, 1) == false)
194  }
195 
196  // fast-dropping ones should be checked in any case
197  if(CheckPassFilter(mCharge[mTrianglePeakTS], TS4Right, mRightSlopeSmallCut, -1) == false)
199  }
200  }
201 
202  if(mCharge[4] + mCharge[5] > mTS4TS5ChargeThreshold && mTS4TS5ChargeThreshold>0) // silly protection against negative charge values
203  {
204  double TS4TS5 = (mCharge[4] - mCharge[5]) / (mCharge[4] + mCharge[5]);
205  if(CheckPassFilter(mCharge[4] + mCharge[5], TS4TS5, mTS4TS5UpperCut, 1) == false)
207  if(CheckPassFilter(mCharge[4] + mCharge[5], TS4TS5, mTS4TS5LowerCut, -1) == false)
209 
210  if(CheckPassFilter(mCharge[4] + mCharge[5], TS4TS5, mTS4TS5UpperCut, 1) == false && // TS4TS5 is above envelope
211  mCharge[3] + mCharge[4] > mTS3TS4ChargeThreshold && mTS3TS4ChargeThreshold>0 && // enough charge in 34
212  mCharge[5] + mCharge[6] < mTS5TS6UpperChargeThreshold && mTS5TS6UpperChargeThreshold>0 && // low charge in 56
213  fabs( (mCharge[4] - mCharge[5]) / (mCharge[4] + mCharge[5]) - 1.0 ) < mR45PlusOneRange ) // R45 is around +1
214  {
215  double TS3TS4 = (mCharge[3] - mCharge[4]) / (mCharge[3] + mCharge[4]);
216  if(CheckPassFilter(mCharge[3] + mCharge[4], TS3TS4, mTS4TS5UpperCut, 1) == true && // use the same envelope as TS4TS5
217  CheckPassFilter(mCharge[3] + mCharge[4], TS3TS4, mTS4TS5LowerCut, -1) == true && // use the same envelope as TS4TS5
218  TS3TS4>(mR45MinusOneRange-1) ) // horizontal cut on R34 (R34>-0.8)
219  hbhe.setFlagField(1, HcalCaloFlagLabels::HBHEOOTPU); // set to 1 if there is a pulse-shape-wise good OOTPU in TS3TS4.
220  }
221 
222  if(CheckPassFilter(mCharge[4] + mCharge[5], TS4TS5, mTS4TS5LowerCut, -1) == false && // TS4TS5 is below envelope
223  mCharge[3] + mCharge[4] < mTS3TS4UpperChargeThreshold && mTS3TS4UpperChargeThreshold>0 && // low charge in 34
224  mCharge[5] + mCharge[6] > mTS5TS6ChargeThreshold && mTS5TS6ChargeThreshold>0 && // enough charge in 56
225  fabs( (mCharge[4] - mCharge[5]) / (mCharge[4] + mCharge[5]) + 1.0 ) < mR45MinusOneRange ) // R45 is around -1
226  {
227  double TS5TS6 = (mCharge[5] - mCharge[6]) / (mCharge[5] + mCharge[6]);
228  if(CheckPassFilter(mCharge[5] + mCharge[6], TS5TS6, mTS4TS5UpperCut, 1) == true && // use the same envelope as TS4TS5
229  CheckPassFilter(mCharge[5] + mCharge[6], TS5TS6, mTS4TS5LowerCut, -1) == true && // use the same envelope as TS4TS5
230  TS5TS6<(1-mR45PlusOneRange) ) // horizontal cut on R56 (R56<+0.8)
231  hbhe.setFlagField(1, HcalCaloFlagLabels::HBHEOOTPU); // set to 1 if there is a pulse-shape-wise good OOTPU in TS5TS6.
232  }
233  }
234 }
int i
Definition: DBlmapReader.cc:9
std::vector< std::pair< double, double > > mLambdaLinearCut
HcalDetId id() const
get the id
Definition: HBHERecHit.h:23
void setFlagField(uint32_t value, int base, int width=1)
Definition: CaloRecHit.cc:20
double pedestal(int fCapId) const
get pedestal for capid=0..3
double CalculateRMS8Max(const std::vector< double > &Charge)
std::vector< std::pair< double, double > > mTS4TS5LowerCut
double PerformNominalFit(const std::vector< double > &Charge)
double PerformDualNominalFit(const std::vector< double > &Charge)
double PerformLinearFit(const std::vector< double > &Charge)
std::vector< std::pair< double, double > > mLeftSlopeCut
TriangleFitResult PerformTriangleFit(const std::vector< double > &Charge)
std::vector< std::pair< double, double > > mRightSlopeCut
bool CheckPassFilter(double Charge, double Discriminant, std::vector< std::pair< double, double > > &Cuts, int Side)
int ietaAbs() const
get the absolute value of the cell ieta
Definition: HcalDetId.cc:98
std::vector< double > mCharge
std::vector< std::pair< double, double > > mRightSlopeSmallCut
virtual void adc2fC(const HBHEDataFrame &df, CaloSamples &lf) const =0
std::vector< std::pair< double, double > > mLambdaRMS8MaxCut
std::vector< std::pair< double, double > > mTS4TS5UpperCut

Member Data Documentation

std::vector<double> HBHEPulseShapeFlagSetter::CumulativeIdealPulse
private
std::vector<double> HBHEPulseShapeFlagSetter::errors_
private

Definition at line 102 of file HBHEPulseShapeFlag.h.

Referenced by DualNominalFitSingleTry().

std::vector<double> HBHEPulseShapeFlagSetter::f1_
private

Definition at line 100 of file HBHEPulseShapeFlag.h.

Referenced by DualNominalFitSingleTry().

std::vector<double> HBHEPulseShapeFlagSetter::f2_
private

Definition at line 101 of file HBHEPulseShapeFlag.h.

Referenced by DualNominalFitSingleTry().

std::vector<double> HBHEPulseShapeFlagSetter::mCharge
private

Definition at line 77 of file HBHEPulseShapeFlag.h.

Referenced by Initialize(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mLambdaLinearCut
private

Definition at line 79 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mLambdaRMS8MaxCut
private

Definition at line 80 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mLeftSlopeCut
private

Definition at line 81 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mMinimumChargeThreshold
private

Definition at line 68 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mR45MinusOneRange
private

Definition at line 75 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mR45PlusOneRange
private

Definition at line 74 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mRightSlopeCut
private

Definition at line 82 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mRightSlopeSmallCut
private

Definition at line 83 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

bool HBHEPulseShapeFlagSetter::mSetLegacyFlags
private

Definition at line 88 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

bool HBHEPulseShapeFlagSetter::mTriangleIgnoreSlow
private

Definition at line 87 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

int HBHEPulseShapeFlagSetter::mTrianglePeakTS
private
double HBHEPulseShapeFlagSetter::mTS3TS4ChargeThreshold
private

Definition at line 72 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mTS3TS4UpperChargeThreshold
private

Definition at line 70 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mTS4TS5ChargeThreshold
private

Definition at line 69 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mTS4TS5LowerCut
private

Definition at line 85 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

std::vector<std::pair<double, double> > HBHEPulseShapeFlagSetter::mTS4TS5UpperCut
private

Definition at line 84 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mTS5TS6ChargeThreshold
private

Definition at line 73 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

double HBHEPulseShapeFlagSetter::mTS5TS6UpperChargeThreshold
private

Definition at line 71 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().

bool HBHEPulseShapeFlagSetter::mUseDualFit
private

Definition at line 86 of file HBHEPulseShapeFlag.h.

Referenced by HBHEPulseShapeFlagSetter(), and SetPulseShapeFlags().