CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
HcalSimpleRecAlgo.h
Go to the documentation of this file.
1 #ifndef HCALSIMPLERECALGO_H
2 #define HCALSIMPLERECALGO_H 1
3 
4 #include <memory>
5 #include "boost/shared_ptr.hpp"
6 
22 
25 
27 
41 public:
44  bool correctForContainment, float fixedPhaseNs);
45 
48 
49  void beginRun(edm::EventSetup const & es);
50  void endRun();
51 
52  void initPulseCorr(int toadd);
53 
54  // set RecoParams channel-by-channel.
55  void setRecoParams(bool correctForTimeslew, bool correctForPulse, bool setLeakCorrection, int pileupCleaningID, float phaseNS);
56 
57  // ugly hack related to HB- e-dependent corrections
58  void setForData (int runnum);
59 
60  // usage of leak correction
61  void setLeakCorrection();
62 
63  // set OOT pileup corrections
64  void setHBHEPileupCorrection(boost::shared_ptr<AbsOOTPileupCorrection> corr);
65  void setHFPileupCorrection(boost::shared_ptr<AbsOOTPileupCorrection> corr);
66  void setHOPileupCorrection(boost::shared_ptr<AbsOOTPileupCorrection> corr);
67 
68  // Set bunch crossing information.
69  // This object will not manage the pointer.
70  void setBXInfo(const BunchXParameter* info, unsigned lenInfo);
71 
72 
73  HBHERecHit reconstruct(const HBHEDataFrame& digi, int first, int toadd, const HcalCoder& coder, const HcalCalibrations& calibs) const;
74  HBHERecHit reconstructHBHEUpgrade(const HcalUpgradeDataFrame& digi, int first, int toadd, const HcalCoder& coder, const HcalCalibrations& calibs) const;
75 
76  HFRecHit reconstruct(const HFDataFrame& digi, int first, int toadd, const HcalCoder& coder, const HcalCalibrations& calibs) const;
77  HFRecHit reconstructHFUpgrade(const HcalUpgradeDataFrame& digi, int first, int toadd, const HcalCoder& coder, const HcalCalibrations& calibs) const;
78 
79  HORecHit reconstruct(const HODataFrame& digi, int first, int toadd, const HcalCoder& coder, const HcalCalibrations& calibs) const;
80  HcalCalibRecHit reconstruct(const HcalCalibDataFrame& digi, int first, int toadd, const HcalCoder& coder, const HcalCalibrations& calibs) const;
81 
82  void setpuCorrMethod(int method){
83  puCorrMethod_ = method; if( puCorrMethod_ == 2 ) psFitOOTpuCorr_ = std::auto_ptr<PulseShapeFitOOTPileupCorrection>(new PulseShapeFitOOTPileupCorrection());
84  if( puCorrMethod_ == 3) hltOOTpuCorr_ = std::auto_ptr<HcalDeterministicFit>(new HcalDeterministicFit());
85  }
86  void setpuCorrParams(bool iPedestalConstraint, bool iTimeConstraint,bool iAddPulseJitter,bool iUnConstrainedFit,bool iApplyTimeSlew,
87  double iTS4Min, double iTS4Max, double iPulseJitter,double iTimeMean,double iTimeSig,double iPedMean,double iPedSig,
88  double iNoise,double iTMin,double iTMax,
89  double its3Chi2,double its4Chi2,double its345Chi2,double iChargeThreshold, int iFitTimes);
90 
91  std::auto_ptr<PedestalSub> pedSubFxn_= std::auto_ptr<PedestalSub>(new PedestalSub());
92 
93 private:
96  float phaseNS_;
97  std::auto_ptr<HcalPulseContainmentManager> pulseCorr_;
98  int runnum_; // data run numer
101  const BunchXParameter* bunchCrossingInfo_;
103  boost::shared_ptr<AbsOOTPileupCorrection> hbhePileupCorr_;
104  boost::shared_ptr<AbsOOTPileupCorrection> hfPileupCorr_;
105  boost::shared_ptr<AbsOOTPileupCorrection> hoPileupCorr_;
106 
108 
110 
111  std::auto_ptr<PulseShapeFitOOTPileupCorrection> psFitOOTpuCorr_;
112 
113  // S.Brandt Feb19 : Add a pointer to the HLT algo
114  std::auto_ptr<HcalDeterministicFit> hltOOTpuCorr_;
115 };
116 
117 #endif
static const TGPicture * info(bool iBackgroundIsBlack)
HBHERecHit reconstruct(const HBHEDataFrame &digi, int first, int toadd, const HcalCoder &coder, const HcalCalibrations &calibs) const
void beginRun(edm::EventSetup const &es)
void setHOPileupCorrection(boost::shared_ptr< AbsOOTPileupCorrection > corr)
HcalPulseShapes theHcalPulseShapes_
const BunchXParameter * bunchCrossingInfo_
boost::shared_ptr< AbsOOTPileupCorrection > hoPileupCorr_
void setBXInfo(const BunchXParameter *info, unsigned lenInfo)
boost::shared_ptr< AbsOOTPileupCorrection > hbhePileupCorr_
unsigned lenBunchCrossingInfo_
HFRecHit reconstructHFUpgrade(const HcalUpgradeDataFrame &digi, int first, int toadd, const HcalCoder &coder, const HcalCalibrations &calibs) const
void initPulseCorr(int toadd)
std::auto_ptr< HcalPulseContainmentManager > pulseCorr_
std::auto_ptr< PulseShapeFitOOTPileupCorrection > psFitOOTpuCorr_
JetCorrectorParameters corr
Definition: classes.h:5
void setRecoParams(bool correctForTimeslew, bool correctForPulse, bool setLeakCorrection, int pileupCleaningID, float phaseNS)
std::auto_ptr< PedestalSub > pedSubFxn_
void setHBHEPileupCorrection(boost::shared_ptr< AbsOOTPileupCorrection > corr)
void setForData(int runnum)
HBHERecHit reconstructHBHEUpgrade(const HcalUpgradeDataFrame &digi, int first, int toadd, const HcalCoder &coder, const HcalCalibrations &calibs) const
boost::shared_ptr< AbsOOTPileupCorrection > hfPileupCorr_
void setpuCorrMethod(int method)
tuple runnum
Definition: summaryLumi.py:210
std::auto_ptr< HcalDeterministicFit > hltOOTpuCorr_
void setHFPileupCorrection(boost::shared_ptr< AbsOOTPileupCorrection > corr)
void setpuCorrParams(bool iPedestalConstraint, bool iTimeConstraint, bool iAddPulseJitter, bool iUnConstrainedFit, bool iApplyTimeSlew, double iTS4Min, double iTS4Max, double iPulseJitter, double iTimeMean, double iTimeSig, double iPedMean, double iPedSig, double iNoise, double iTMin, double iTMax, double its3Chi2, double its4Chi2, double its345Chi2, double iChargeThreshold, int iFitTimes)