ATLAS Offline Software
TileCondToolIntegrator.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 // Tile includes
8 
9 // Athena includes
12 
13 //
14 //____________________________________________________________________
15 static const InterfaceID IID_TileCondToolIntegrator("TileCondToolIntegrator", 1, 0);
16 
18  return IID_TileCondToolIntegrator;
19 }
20 
21 //
22 //____________________________________________________________________
23 TileCondToolIntegrator::TileCondToolIntegrator(const std::string& type, const std::string& name,
24  const IInterface* parent)
26 {
27  declareInterface<TileCondToolIntegrator>(this);
28 }
29 
30 //
31 //____________________________________________________________________
33 }
34 
35 //
36 //____________________________________________________________________
38  ATH_MSG_DEBUG( "In initialize()" );
39 
40  //=== Initialize integrator conditions data key
41  ATH_CHECK( m_calibIntegratorKey.initialize() );
42 
43  return StatusCode::SUCCESS;
44 }
45 
46 //
47 //____________________________________________________________________
49  ATH_MSG_DEBUG( "finalize called" );
50  return StatusCode::SUCCESS;
51 }
52 
53 //
54 //____________________________________________________________________
55 float TileCondToolIntegrator::getGain(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
56 
58  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 0);
59 
60 }
61 
62 //
63 //____________________________________________________________________
64 float TileCondToolIntegrator::getGainError(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
65 
67  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 1);
68 
69 }
70 
71 //
72 //____________________________________________________________________
73 float TileCondToolIntegrator::getChi2(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
74 
76  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 2);
77 
78 }
79 
80 //
81 //____________________________________________________________________
82 float TileCondToolIntegrator::getPedestal(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
83 
85  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 3);
86 
87 }
88 
89 //
90 //____________________________________________________________________
91 float TileCondToolIntegrator::getDACForPed(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
92 
94  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 4);
95 
96 }
97 
98 //
99 //____________________________________________________________________
100 float TileCondToolIntegrator::getSigmaOfPed(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
101 
103  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 5);
104 
105 }
106 
107 //
108 //____________________________________________________________________
109 float TileCondToolIntegrator::getRMSOfPed(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
110 
112  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 6);
113 
114 }
115 
116 //
117 //____________________________________________________________________
118 float TileCondToolIntegrator::getSigmaOfRMS(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const {
119 
121  return calibIntegrator->getCalibDrawer(drawerIdx)->getData(channel, adc, 7);
122 
123 }
124 
TileCondToolIntegrator.h
TileCalibDrawerFlt.h
plotting.yearwise_efficiency.channel
channel
Definition: yearwise_efficiency.py:28
TileCondToolIntegrator::getSigmaOfRMS
float getSigmaOfRMS(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:118
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
TileCondToolIntegrator::getDACForPed
float getDACForPed(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:91
TileCondToolIntegrator::getGain
float getGain(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:55
TileCondToolIntegrator::initialize
virtual StatusCode initialize() override
Definition: TileCondToolIntegrator.cxx:37
TileCondToolIntegrator::TileCondToolIntegrator
TileCondToolIntegrator(const std::string &type, const std::string &name, const IInterface *parent)
Definition: TileCondToolIntegrator.cxx:23
TileCondToolIntegrator::~TileCondToolIntegrator
virtual ~TileCondToolIntegrator()
Definition: TileCondToolIntegrator.cxx:32
ReadCondHandle.h
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
TileCondToolIntegrator::interfaceID
static const InterfaceID & interfaceID()
Definition: TileCondToolIntegrator.cxx:17
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
TileCondToolIntegrator::getRMSOfPed
float getRMSOfPed(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:109
TileCondToolIntegrator::finalize
virtual StatusCode finalize() override
Definition: TileCondToolIntegrator.cxx:48
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
errorcheck.h
Helpers for checking error return status codes and reporting errors.
TileCondToolIntegrator::getSigmaOfPed
float getSigmaOfPed(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:100
ReadFloatFromCool.adc
adc
Definition: ReadFloatFromCool.py:48
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
TileCondToolIntegrator::getPedestal
float getPedestal(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:82
TileCondToolIntegrator::m_calibIntegratorKey
SG::ReadCondHandleKey< TileCalibDataFlt > m_calibIntegratorKey
Definition: TileCondToolIntegrator.h:41
AthAlgTool
Definition: AthAlgTool.h:26
TileCondToolIntegrator::getGainError
float getGainError(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:64
TileCondToolIntegrator::getChi2
float getChi2(unsigned int drawerIdx, unsigned int channel, unsigned int adc) const
Definition: TileCondToolIntegrator.cxx:73