ATLAS Offline Software
LArParabolaPeakRecoTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2021 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef LARCALIBUTILS_LARPARABOLAPEAKRECOTOOL_H
6 #define LARCALIBUTILS_LARPARABOLAPEAKRECOTOOL_H
7 
9 
15 static const InterfaceID IID_LArParabolaPeakRecoTool("LArParabolaPeakRecoTool", 1 , 0);
16 
18 
19 {
20  public:
21 
22  // constructor
23  LArParabolaPeakRecoTool(const std::string& type,
24  const std::string& name,
25  const IInterface* parent);
26 
27  // destructor
29 
30  static const InterfaceID& interfaceID() { return IID_LArParabolaPeakRecoTool;}
31 
32  // returns a vector: vector[0]=ADCReco, vector[1]=TimeReco
33  std::vector<float> peak (const std::vector<float>& samples) const;
34  // short needed for backward compatability
35  std::vector<float> peak (const std::vector<short>& samples) const;
36  // second method in case one want to apply bias correction
37  std::vector<float> peak (const std::vector<float>& samples, int layer, float pedestal) const;
38  std::vector<float> peak (const std::vector<short>& samples, int layer, float pedestal) const;
39 
40 
41 
42  // initialize and finalize methods
43  virtual StatusCode initialize();
44  virtual StatusCode finalize();
45 
46  float ParabolaRawToTrueTime(float& QT_fittime, int& layer) const ;
47  float ParabolaRawToTrueADC(float& QT_true_time, double& ADCref, float& PEDref, int& layer) const ;
48 
49  // Avoid ambiguity.
50  //static const InterfaceID& interfaceID() { return IAlgTool::interfaceID(); }
51 
52  private:
53 
54  // jobOptions for bias correction
57 
58  // file and tables for corrections
59  FILE* m_fileShape = nullptr, *m_fileADCcor = nullptr;
60  float m_QT_Shape[4][26]{};
61  float m_QT_ADCcor[4][25]{};
62 };
63 
64 
65 #endif
LArParabolaPeakRecoTool::initialize
virtual StatusCode initialize()
Definition: LArParabolaPeakRecoTool.cxx:33
LArParabolaPeakRecoTool::peak
std::vector< float > peak(const std::vector< float > &samples) const
Definition: LArParabolaPeakRecoTool.cxx:80
LArParabolaPeakRecoTool::LArParabolaPeakRecoTool
LArParabolaPeakRecoTool(const std::string &type, const std::string &name, const IInterface *parent)
Definition: LArParabolaPeakRecoTool.cxx:19
LArParabolaPeakRecoTool::~LArParabolaPeakRecoTool
virtual ~LArParabolaPeakRecoTool()
Definition: LArParabolaPeakRecoTool.h:28
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
AthAlgTool.h
LArParabolaPeakRecoTool::finalize
virtual StatusCode finalize()
Definition: LArParabolaPeakRecoTool.cxx:77
test_pyathena.parent
parent
Definition: test_pyathena.py:15
LArParabolaPeakRecoTool::m_fileShape
FILE * m_fileShape
Definition: LArParabolaPeakRecoTool.h:59
LArParabolaPeakRecoTool::m_fileShapeName
std::string m_fileShapeName
Definition: LArParabolaPeakRecoTool.h:56
LArParabolaPeakRecoTool
Definition: LArParabolaPeakRecoTool.h:19
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
LArParabolaPeakRecoTool::ParabolaRawToTrueTime
float ParabolaRawToTrueTime(float &QT_fittime, int &layer) const
Definition: LArParabolaPeakRecoTool.cxx:173
LArParabolaPeakRecoTool::m_QT_Shape
float m_QT_Shape[4][26]
Definition: LArParabolaPeakRecoTool.h:60
LArParabolaPeakRecoTool::m_QT_ADCcor
float m_QT_ADCcor[4][25]
Definition: LArParabolaPeakRecoTool.h:61
LArParabolaPeakRecoTool::m_fileADCcorName
std::string m_fileADCcorName
Definition: LArParabolaPeakRecoTool.h:56
LArParabolaPeakRecoTool::interfaceID
static const InterfaceID & interfaceID()
Definition: LArParabolaPeakRecoTool.h:30
LArParabolaPeakRecoTool::m_correctBias
bool m_correctBias
Definition: LArParabolaPeakRecoTool.h:55
LArParabolaPeakRecoTool::ParabolaRawToTrueADC
float ParabolaRawToTrueADC(float &QT_true_time, double &ADCref, float &PEDref, int &layer) const
Definition: LArParabolaPeakRecoTool.cxx:249
LArParabolaPeakRecoTool::m_fileADCcor
FILE * m_fileADCcor
Definition: LArParabolaPeakRecoTool.h:59
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
AthAlgTool
Definition: AthAlgTool.h:26