ATLAS Offline Software
Loading...
Searching...
No Matches
TileLaserTimingTool Class Reference

#include <TileLaserTimingTool.h>

Inheritance diagram for TileLaserTimingTool:
Collaboration diagram for TileLaserTimingTool:

Classes

struct  PMTData
struct  DigitizerData
struct  DrawerData

Public Member Functions

 TileLaserTimingTool (const std::string &type, const std::string &name, const IInterface *pParent)
virtual ~TileLaserTimingTool ()
virtual StatusCode initialize () override
virtual StatusCode initNtuple (int runNumber, int runType, TFile *rootfile) override
virtual StatusCode execute () override
 TODO: determine event type, select laser?
virtual StatusCode finalizeCalculations () override
virtual StatusCode writeNtuple (int runNumber, int runType, TFile *rootfile) override
virtual StatusCode finalize () override
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm.
virtual StatusCode sysStart () override
 Handle START transition.
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles.
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles.
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T, V, H > &t)
void updateVHKA (Gaudi::Details::PropertyBase &)
MsgStream & msg () const
bool msgLvl (const MSG::Level lvl) const

Static Public Member Functions

static const InterfaceID & interfaceID ()

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed.

Private Types

typedef float(* TPMTArray)[NDRAWERS][NCHANNELS]
typedef float(* TDrawerArrayF)[NDRAWERS]
typedef int(* TDrawerArrayI)[NDRAWERS]
typedef ServiceHandle< StoreGateSvc > StoreGateSvc_t

Private Member Functions

DrawerData * drawerData (int ros, int drawer)
bool isConnectedChan (int ros, int chan)
int channel2PMT (int ros, int chan)
double fiberCorrection (int ros, int pmt)
HWIdentifier drawerId (int frag)
std::string drawerIdStr (int frag)
HWIdentifier drawerId (int ros, int drawer)
void fitGauss (TH1F &hi, float &p1, float &p2, float &p1_err)
 Fit a Gaussian function (m_gaussf) to the given histogram, store mean, rms and mean error.
void fitGauss2 (TH1F &hi, float &p1, float &p2, float &chi2, float &p1_err, float w1, float w2)
 Fit a Gaussian function with two iterations mean range = hi.mean +- w1|w2 * hi.rms.
void correctEvenOddPMT (int ros, int drawer, TPMTArray &ChannelOffset, TDrawerArrayF &MeanOddPmtTdiff, TDrawerArrayI &OddPmtCounter, TDrawerArrayF &MeanEvenPmtTdiff, TDrawerArrayI &EvenPmtCounter, TDrawerArrayF &EvenOddTimeDiff)
 Correct for differences between even and odd PMTs.
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey>

Static Private Member Functions

static bool isConnectedPMT (int ros, int chan)
static bool isBarrel (int ros)
static bool isExtBarrel (int ros)
static float fiberLength (int ros, int pmt)

Private Attributes

DrawerData *(* m_drawerData )[NDRAWERS]
float(* m_DrawerOffset )[NDRAWERS]
float(* m_DrawerOffsetError )[NDRAWERS]
float(* m_ChannelOffset )[NDRAWERS][NCHANNELS]
float(* m_ChannelOffsetError )[NDRAWERS][NCHANNELS]
float(* m_ADCAmplitude )[NDRAWERS][NCHANNELS]
float(* m_PedestalMean )[NDRAWERS][NCHANNELS]
float(* m_PedestalSigma )[NDRAWERS][NCHANNELS]
float(* m_TimeDiffMean )[NDRAWERS][NCHANNELS]
float(* m_TimeDiffMeanError )[NDRAWERS][NCHANNELS]
float(* m_TimeDiffSigma )[NDRAWERS][NCHANNELS]
float(* m_MeanOddPmtTdiffPMT0 )[NDRAWERS]
int(* m_OddPmtCounterPMT0 )[NDRAWERS]
float(* m_MeanEvenPmtTdiffPMT0 )[NDRAWERS]
int(* m_EvenPmtCounterPMT0 )[NDRAWERS]
float(* m_EvenOddTimeDiffPMT0 )[NDRAWERS]
float(* m_FiberLength )[NDRAWERS][NCHANNELS]
float(* m_TimeDiffPMTDigi0 )[NDRAWERS][NCHANNELS]
float(* m_FiberCorrection )[NDRAWERS][NCHANNELS]
int(* m_IsConnected )[NDRAWERS][NCHANNELS]
float(* m_MeanOddPmtTdiff )[NDRAWERS]
int(* m_OddPmtCounter )[NDRAWERS]
float(* m_MeanEvenPmtTdiff )[NDRAWERS]
int(* m_EvenPmtCounter )[NDRAWERS]
float(* m_EvenOddTimeDiff )[NDRAWERS]
float(* m_DSkewSet )[NDRAWERS][NDIGI]
float(* m_DigiMean )[NDRAWERS][NDIGI]
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
SG::ReadHandleKey< TileRawChannelContainer > m_rawChannelContainerKey
SG::ReadHandleKey< TileDigitsContainer > m_digitsContainerKey
const TileHWID * m_tileHWID {nullptr}
const TileCablingService * m_cabling {nullptr}
ToolHandle< TileCondToolTiming > m_tileToolTiming
std::string m_rawChannelContainerName
std::string m_digitsContainerName
Gaudi::Property< std::string > m_ntupleID {this, "NtupleID", "h3000"}
Gaudi::Property< double > m_fiberLightSpeed {this, "FiberLightSpeed", 0.0}
Gaudi::Property< unsigned > m_nSamples {this, "NSamples", 9}
Gaudi::Property< double > m_eneLowLimitPulseShape {this, "EneLowLimitPulseShape", 0.000001}
Gaudi::Property< unsigned int > m_refDrawer {this, "ReferenceDrawer", 39}
Gaudi::Property< bool > m_useMeanChannelOffset {this, "UseMeanChannelOffset", true}
Gaudi::Property< float > m_maxTimeDiff {this, "MaxTimeDiff", 10000.}
Gaudi::Property< bool > m_usePMT0AsDskewRef {this, "UsePMT0AsDskewRef", true}
std::string m_IOVTag
int m_nevts {0}
 number of laser events
TF1 * m_gaussf {nullptr}
StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default).
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default).
std::vector< SG::VarHandleKeyArray * > m_vhka
bool m_varHandleArraysDeclared

Static Private Attributes

static const int NROS = 5
static const float s_fiberLength [2][48]

Detailed Description

Definition at line 79 of file TileLaserTimingTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 376 of file AthCommonDataStore.h.

◆ TDrawerArrayF

typedef float(* TileLaserTimingTool::TDrawerArrayF)[NDRAWERS]
private

Definition at line 355 of file TileLaserTimingTool.h.

◆ TDrawerArrayI

typedef int(* TileLaserTimingTool::TDrawerArrayI)[NDRAWERS]
private

Definition at line 356 of file TileLaserTimingTool.h.

◆ TPMTArray

typedef float(* TileLaserTimingTool::TPMTArray)[NDRAWERS][NCHANNELS]
private

Definition at line 354 of file TileLaserTimingTool.h.

Constructor & Destructor Documentation

◆ TileLaserTimingTool()

TileLaserTimingTool::TileLaserTimingTool ( const std::string & type,
const std::string & name,
const IInterface * pParent )

Definition at line 122 of file TileLaserTimingTool.cxx.

123 : AthAlgTool(type, name, pParent)
124{
125
126 declareInterface<ITileCalibTool>( this );
127
128#ifdef TileLaserTimingMonPulse
129 // create mon histos
130 m_h1_time_check = new TH1F("h1_time_check", "Time(Tfit based) - Time(cispar based)", 1000, -200., 200.);
131 m_h2_time_check = new TH2F("h2_time_check", "Time(Tfit based) vs Time(cispar based)", 1000, -200., 200., 1000, -200., 200.);
132
133 m_PulseShapeHigh = new TProfile("pulse_shape_HG", "pulse shape HG", 400, -200., 300., 0, 100000.);
134 m_PulseShapeLow = new TProfile("pulse_shape_LG", "pulse shape LG", 400, -200., 300., 0, 100000.);
135#endif
136
137 // creating multi-dim arrays on the heap and initialize all elements to zeros
139
140 m_DrawerOffset = new float[NROS][NDRAWERS]();
141 m_DrawerOffsetError = new float[NROS][NDRAWERS]();
142
143 m_ChannelOffset = new float[NROS][NDRAWERS][NCHANNELS]();
145
146 m_ADCAmplitude = new float[NROS][NDRAWERS][NCHANNELS]();
147
148 m_PedestalMean = new float[NROS][NDRAWERS][NCHANNELS]();
149 m_PedestalSigma = new float[NROS][NDRAWERS][NCHANNELS]();
150
151 m_TimeDiffMean = new float[NROS][NDRAWERS][NCHANNELS]();
153 m_TimeDiffSigma = new float[NROS][NDRAWERS][NCHANNELS]();
154
155 m_MeanOddPmtTdiffPMT0 = new float[NROS][NDRAWERS]();
156 m_OddPmtCounterPMT0 = new int[NROS][NDRAWERS]();
157 m_MeanEvenPmtTdiffPMT0 = new float[NROS][NDRAWERS]();
158 m_EvenPmtCounterPMT0 = new int[NROS][NDRAWERS]();
159 m_EvenOddTimeDiffPMT0 = new float[NROS][NDRAWERS]();
160
161#ifdef TileLaserTimingPMT0Mon
162 m_TimeDiffHighMean = new float[NROS][NDRAWERS][NCHANNELS]();
163 m_TimeDiffHighMeanError = new float[NROS][NDRAWERS][NCHANNELS]();
164 m_TimeDiffHighSigma = new float[NROS][NDRAWERS][NCHANNELS]();
165
166 m_TimeDiffLowMean = new float[NROS][NDRAWERS][NCHANNELS]();
167 m_TimeDiffLowMeanError = new float[NROS][NDRAWERS][NCHANNELS]();
168 m_TimeDiffLowSigma = new float[NROS][NDRAWERS][NCHANNELS]();
169
170 m_TimeDiffNoCFCorrMean = new float[NROS][NDRAWERS][NCHANNELS]();
171 m_TimeDiffNoCFCorrMeanError = new float[NROS][NDRAWERS][NCHANNELS]();
172 m_TimeDiffNoCFCorrSigma = new float[NROS][NDRAWERS][NCHANNELS]();
173#endif
174
175 m_FiberLength = new float[NROS][NDRAWERS][NCHANNELS]();
176
177#ifdef TileLaserTimingMon
178 m_TimeDiffPMTDigi0 = new float[NROS][NDRAWERS][NCHANNELS]();
179 m_FiberCorrection = new float[NROS][NDRAWERS][NCHANNELS]();
180 m_IsConnected = new int[NROS][NDRAWERS][NCHANNELS]();
181
182 m_MeanOddPmtTdiff = new float[NROS][NDRAWERS]();
183 m_OddPmtCounter = new int[NROS][NDRAWERS]();
184 m_MeanEvenPmtTdiff = new float[NROS][NDRAWERS]();
185 m_EvenPmtCounter = new int[NROS][NDRAWERS]();
186
187 m_EvenOddTimeDiff = new float[NROS][NDRAWERS]();
188#endif
189
190 m_DSkewSet = new float[NROS][NDRAWERS][NDIGI]();
191 m_DigiMean = new float[NROS][NDRAWERS][NDIGI]();
192}
#define NDIGI
#define NCHANNELS
#define NPARTITIONS
#define NDRAWERS
AthAlgTool()
Default constructor:
float(* m_FiberCorrection)[NDRAWERS][NCHANNELS]
float(* m_ChannelOffset)[NDRAWERS][NCHANNELS]
float(* m_TimeDiffMean)[NDRAWERS][NCHANNELS]
float(* m_EvenOddTimeDiff)[NDRAWERS]
int(* m_IsConnected)[NDRAWERS][NCHANNELS]
int(* m_OddPmtCounterPMT0)[NDRAWERS]
float(* m_TimeDiffPMTDigi0)[NDRAWERS][NCHANNELS]
int(* m_EvenPmtCounterPMT0)[NDRAWERS]
int(* m_OddPmtCounter)[NDRAWERS]
float(* m_ADCAmplitude)[NDRAWERS][NCHANNELS]
float(* m_DrawerOffset)[NDRAWERS]
float(* m_TimeDiffMeanError)[NDRAWERS][NCHANNELS]
DrawerData *(* m_drawerData)[NDRAWERS]
int(* m_EvenPmtCounter)[NDRAWERS]
float(* m_MeanOddPmtTdiffPMT0)[NDRAWERS]
float(* m_PedestalMean)[NDRAWERS][NCHANNELS]
float(* m_MeanOddPmtTdiff)[NDRAWERS]
float(* m_TimeDiffSigma)[NDRAWERS][NCHANNELS]
float(* m_MeanEvenPmtTdiff)[NDRAWERS]
float(* m_ChannelOffsetError)[NDRAWERS][NCHANNELS]
float(* m_FiberLength)[NDRAWERS][NCHANNELS]
float(* m_DigiMean)[NDRAWERS][NDIGI]
float(* m_PedestalSigma)[NDRAWERS][NCHANNELS]
float(* m_DrawerOffsetError)[NDRAWERS]
float(* m_DSkewSet)[NDRAWERS][NDIGI]
float(* m_MeanEvenPmtTdiffPMT0)[NDRAWERS]
float(* m_EvenOddTimeDiffPMT0)[NDRAWERS]
TH2F(name, title, nxbins, bins_par2, bins_par3, bins_par4, bins_par5=None, bins_par6=None, path='', **kwargs)
TH1F(name, title, nxbins, bins_par2, bins_par3=None, path='', **kwargs)

◆ ~TileLaserTimingTool()

TileLaserTimingTool::~TileLaserTimingTool ( )
virtual

Definition at line 194 of file TileLaserTimingTool.cxx.

194 {
195
196 delete[] m_drawerData;
197 delete[] m_DrawerOffset;
198 delete[] m_DrawerOffsetError;
199 delete[] m_ChannelOffset;
200 delete[] m_ChannelOffsetError;
201 delete[] m_ADCAmplitude;
202 delete[] m_PedestalMean;
203 delete[] m_PedestalSigma;
204 delete[] m_TimeDiffMean;
205 delete[] m_TimeDiffMeanError;
206 delete[] m_TimeDiffSigma;
207 delete[] m_MeanOddPmtTdiffPMT0;
208 delete[] m_OddPmtCounterPMT0;
209 delete[] m_MeanEvenPmtTdiffPMT0;
210 delete[] m_EvenPmtCounterPMT0;
211 delete[] m_EvenOddTimeDiffPMT0;
212#ifdef TileLaserTimingPMT0Mon
213 delete[] m_TimeDiffHighMean;
214 delete[] m_TimeDiffHighMeanError;
215 delete[] m_TimeDiffHighSigma;
216 delete[] m_TimeDiffLowMean;
217 delete[] m_TimeDiffLowMeanError;
218 delete[] m_TimeDiffLowSigma;
219 delete[] m_TimeDiffNoCFCorrMean;
220 delete[] m_TimeDiffNoCFCorrMeanError;
221 delete[] m_TimeDiffNoCFCorrSigma;
222#endif
223
224 delete[] m_FiberLength;
225
226#ifdef TileLaserTimingMon
227 delete[] m_TimeDiffPMTDigi0;
228 delete[] m_FiberCorrection;
229 delete[] m_IsConnected;
230 delete[] m_MeanOddPmtTdiff;
231 delete[] m_OddPmtCounter;
232 delete[] m_MeanEvenPmtTdiff;
233 delete[] m_EvenPmtCounter;
234 delete[] m_EvenOddTimeDiff;
235#endif
236 delete[] m_DSkewSet;
237 delete[] m_DigiMean;
238}

Member Function Documentation

◆ channel2PMT()

int TileLaserTimingTool::channel2PMT ( int ros,
int chan )
inlineprivate
Returns
PMT#-1 for given ros and channel

Definition at line 311 of file TileLaserTimingTool.h.

311 {
312 return (abs(m_cabling->channel2hole(ros, chan)) - 1);
313 }
const TileCablingService * m_cabling

◆ correctEvenOddPMT()

void TileLaserTimingTool::correctEvenOddPMT ( int ros,
int drawer,
TPMTArray & ChannelOffset,
TDrawerArrayF & MeanOddPmtTdiff,
TDrawerArrayI & OddPmtCounter,
TDrawerArrayF & MeanEvenPmtTdiff,
TDrawerArrayI & EvenPmtCounter,
TDrawerArrayF & EvenOddTimeDiff )
private

Correct for differences between even and odd PMTs.

Definition at line 938 of file TileLaserTimingTool.cxx.

941 {
942
943
944 float DeltaParity = 0;
945
946 //=== determine overall shift between odd and even fibers ===
947 //=== for this take only into account channels with connected PMT
948 //=== don't take into the mean the value of tdiff when it is too far from zero
949 for (int ipmt = 0; ipmt < NCHANNELS; ++ipmt) {
950 if (isConnectedPMT(ros, ipmt)) {
951 if (ipmt % 2 == 1) {
952 // odd PMTs
953 if (fabs(ChannelOffset[ros][drawer][ipmt]) < m_maxTimeDiff) {
954 MeanOddPmtTdiff[ros][drawer] += ChannelOffset[ros][drawer][ipmt];
955 ++OddPmtCounter[ros][drawer];
956 } else {
957 ATH_MSG_WARNING( "correctEvenOddPMT()"
958 << " time overflow (" << ChannelOffset[ros][drawer][ipmt]
959 << ") ros:" << ros
960 << " dr:" << drawer
961 << " pmt:" << ipmt );
962
963 }
964 } else if (ipmt % 2 == 0) {
965 // even PMTs
966 if (fabs(ChannelOffset[ros][drawer][ipmt]) < m_maxTimeDiff) {
967 MeanEvenPmtTdiff[ros][drawer] += ChannelOffset[ros][drawer][ipmt];
968 ++EvenPmtCounter[ros][drawer];
969 } else {
970 ATH_MSG_WARNING( "correctEvenOddPMT()"
971 << " time overflow (" << ChannelOffset[ros][drawer][ipmt]
972 << ") ros:" << ros
973 << " dr:" << drawer
974 << " pmt:" << ipmt );
975 }
976 }
977 }
978 }
979
980 // Save Time difference b/w odd/even pmt's
981 MeanOddPmtTdiff[ros][drawer] /= (float) OddPmtCounter[ros][drawer];
982 MeanEvenPmtTdiff[ros][drawer] /= (float) EvenPmtCounter[ros][drawer];
983 DeltaParity = 0.5 * (MeanOddPmtTdiff[ros][drawer] - MeanEvenPmtTdiff[ros][drawer]);
984
985 EvenOddTimeDiff[ros][drawer] = 2 * DeltaParity;
986
987 ATH_MSG_DEBUG( "correctEvenOddPMT()"
988 << " ros: " << ros
989 << " drawer:" << drawer
990 << " EvenOddTimeDiff:" << EvenOddTimeDiff[ros][drawer]
991 << " | MeanOddPmtTdiff:" << MeanOddPmtTdiff[ros][drawer]
992 << " MeanEvenPmtTdiff:" << MeanEvenPmtTdiff[ros][drawer]
993 << " DeltaParity:" << DeltaParity );
994
995 //==================================================================
996 //=== Correct for overall shift b/w odd and even fibers ===
997 //==================================================================
998 for (int ipmt = 0; ipmt < NCHANNELS; ++ipmt) {
999 if (isConnectedPMT(ros, ipmt)) {
1000 if (ipmt % 2 == 1)
1001 ChannelOffset[ros][drawer][ipmt] -= DeltaParity;
1002 else if (ipmt % 2 == 0) ChannelOffset[ros][drawer][ipmt] += DeltaParity;
1003 }
1004 } // end pmt loop
1005}
#define ATH_MSG_DEBUG(x,...)
#define ATH_MSG_WARNING(x,...)
Gaudi::Property< float > m_maxTimeDiff
static bool isConnectedPMT(int ros, int chan)

◆ declareGaudiProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T, V, H > & hndl,
const SG::VarHandleKeyType &  )
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158 {
160 hndl.value(),
161 hndl.documentation());
162
163 }
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T, V, H > &t)

◆ declareProperty()

Gaudi::Details::PropertyBase & AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T, V, H > & t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145 {
146 typedef typename SG::HandleClassifier<T>::type htype;
148 }
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T, V, H > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>

◆ detStore()

const ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

◆ drawerData()

DrawerData * TileLaserTimingTool::drawerData ( int ros,
int drawer )
inlineprivate
Returns
drawer data

Definition at line 239 of file TileLaserTimingTool.h.

239 {
240 if (!m_drawerData[ros - 1][drawer]) {
241 std::ostringstream sout;
242 sout << ros << '_' << drawer;
243 m_drawerData[ros - 1][drawer] = new DrawerData(sout.str());
244 }
245 return m_drawerData[ros - 1][drawer];
246 }

◆ drawerId() [1/2]

HWIdentifier TileLaserTimingTool::drawerId ( int frag)
inlineprivate
Returns
HWIdentifier for fragment

Definition at line 331 of file TileLaserTimingTool.h.

331 {
332 return m_tileHWID->drawer_id(frag);
333 }
const TileHWID * m_tileHWID

◆ drawerId() [2/2]

HWIdentifier TileLaserTimingTool::drawerId ( int ros,
int drawer )
inlineprivate
Returns
HWIdentifier for ros and drawer

Definition at line 339 of file TileLaserTimingTool.h.

339 {
340 return m_tileHWID->drawer_id(ros, drawer);
341 }

◆ drawerIdStr()

std::string TileLaserTimingTool::drawerIdStr ( int frag)
inlineprivate
Returns
string for fragment id

Definition at line 335 of file TileLaserTimingTool.h.

335 {
336 return m_tileHWID->to_string(drawerId(frag));
337 }
HWIdentifier drawerId(int frag)

◆ evtStore()

ServiceHandle< StoreGateSvc > & AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

◆ execute()

StatusCode TileLaserTimingTool::execute ( )
overridevirtual

TODO: determine event type, select laser?

Implements ITileCalibTool.

Definition at line 293 of file TileLaserTimingTool.cxx.

293 {
294
295 ATH_MSG_DEBUG( "execute()" );
296
297 gROOT->cd();
298
299 // Get event's CIS parameters
300 // QQQ: const uint32_t *cispar = m_beamInfo->cispar();
301 // QQQ: const uint32_t dac = cispar[6];
302 // QQQ: const uint32_t phase = cispar[5];
303 // QQQ: const uint32_t cap = cispar[7];
304
305 // Get EventInfo
306 SG::ReadHandle<xAOD::EventInfo> eventInfo(m_eventInfoKey);
307 ATH_CHECK( eventInfo.isValid() );
308
309
310 // QQQ: const unsigned runNumber = eventInfo->runNumber();
311 // QQQ: const unsigned eventNumber = eventInfo->eventNumber();
312
313 // Check if event should be used in calibration
314 bool pass = true;
315
316 // Get TileRawChannelContainer
317 SG::ReadHandle<TileRawChannelContainer> container(m_rawChannelContainerKey);
318 ATH_CHECK( container.isValid() );
319
320 // Get TileDigitsContainer
321 SG::ReadHandle<TileDigitsContainer> digitsCnt(m_digitsContainerKey);
322 ATH_CHECK( digitsCnt.isValid() );
323
324 // Create iterator over RawChannelContainer
325 TileRawChannelContainer::const_iterator itColl = (*container).begin();
326 TileRawChannelContainer::const_iterator itCollEnd = (*container).end();
328
329 // tmp vars
330 const TileDigitsCollection *digiColl = nullptr;
331 const TileDigits* digits;
332 const TileRawChannel *rawch = nullptr;
333 float dtime, dtimeNoCFCorr;
334
335#ifdef TileLaserTimingMonPulse
336 float f_SampleTime, f_phase1, f_phase2, f_time, f_tfittime;
337#endif
338
339 size_t colls;
340 int Nconnected;
341 float ChannelOffset;
342
343 DrawerData *ddata = nullptr;
344
345 unsigned frag;
346 if (pass) {
347 m_nevts++;
348
349 // Go through all TileRawChannelCollections
350 for (; itColl != itCollEnd; ++itColl) {
351 // Get the digits collection for the drawer corresponding to the raw channel
352 frag = (*itColl)->identify();
353 const auto *digiCollIt = digitsCnt->indexFindPtr(digitsCnt->hashFunc()(frag));
354 if (digiCollIt == nullptr) {
355 ATH_MSG_ERROR( " unable to get TileDigitsCollection for drawer:" << drawerIdStr(frag) );
356
357 } else {
358 digiColl = digiCollIt;
359 colls = (*itColl)->size();
360 ATH_MSG_VERBOSE( "execute() colls:" << colls
361 << " digiColl->size:" << digiColl->size()
362 << " drawer:" << drawerIdStr((*itColl)->identify()) );
363
364 if (digiColl->size() != colls) {
365 ATH_MSG_ERROR( " size of TileDigitsCollection and TileRawChannelCollection differ for drawer:" << drawerIdStr((*itColl)->identify()) );
366
367 } else {
368 // ZZZ: Assume the first RawChannel in the collection corresponds to PMT 0
369 // ZZZ: if this is not the case (for some reason) there will be a nasty segflt
370
371 // get drawer HWID
372 HWIdentifier dhwid = drawerId((*itColl)->identify());
373 // LBA=1 LBC=2 EBA=3 EBC=4
374 int ros = m_tileHWID->ros(dhwid);
375 // 0 to 63
376 int drawer = m_tileHWID->drawer(dhwid);
377 // get and create DrawerData if needed, cannot be null
378 ddata = drawerData(ros, drawer);
379 // store ref to first PMT
380 PMTData &pmt0data = *ddata->pmtd[0];
381
382 for (size_t i = 0; i < colls; ++i) {
383 digits = digiColl->at(i);
384 rawch = (*itColl)->at(i);
385
386 // require both digits and raw channels with equal ids
387 if (!digits || !rawch || (digits->identify() != rawch->identify())) {
388 if (!digits) {
389 ATH_MSG_ERROR( " no TileDigits for drawer:" << drawerIdStr((*itColl)->identify()) );
390 }
391
392 if (!rawch) {
393 ATH_MSG_ERROR( " no TileRawChannel for drawer:" << drawerIdStr((*itColl)->identify()) );
394 }
395
396 if (rawch && digits) {
397 ATH_MSG_ERROR( " no id mismatch for drawer:" << drawerIdStr((*itColl)->identify()) );
398 }
399
400 } else {
401 // get hardware id to identify adc
402 HWIdentifier hwid = rawch->adc_HWID();
403 // int ros = m_tileHWID->ros(hwid); // LBA=1 LBC=2 EBA=3 EBC=4
404 // int drawer = m_tileHWID->drawer(hwid); // 0 to 63
405 const int chan = m_tileHWID->channel(hwid); // 0 to 47 channel not PMT
406 const int gain = m_tileHWID->adc(hwid); // low=0 high=1
407 const int ipmt = channel2PMT(ros, chan);
408
409 // store Fit data
410 PMTData &pmtdata = *ddata->pmtd[ipmt];
411 pmtdata.time = rawch->time();
412 pmtdata.energy = rawch->amplitude();
413 pmtdata.pedestal.add(rawch->pedestal());
414
415 // in case of the first PMT (i.e. 0) this will be 0 as per definition
416 dtimeNoCFCorr = pmtdata.time - pmt0data.time;
417 dtime = dtimeNoCFCorr - fiberCorrection(ros, ipmt);
418 pmtdata.TimeDiffHisto.Fill(dtime);
419
420#ifdef TileLaserTimingPMT0
421 pmtdata.TimeDiffNoCFCorrHisto.Fill(dtimeNoCFCorr);
422
423 if(gain == 0) pmtdata.TimeDiffHistoLow.Fill(dtime);
424 else pmtdata.TimeDiffHistoHigh.Fill(dtime);
425#endif
426
427#ifdef TileLaserTimingMon
428 pmtdata.timeHisto.Fill(pmtdata.time);
429 pmtdata.eneHisto.Fill(pmtdata.energy);
430 pmtdata.gainHisto.Fill(gain);
431#endif
432
433 // pulse data-->
434#ifdef TileLaserTimingMonPulse
435 if(isConnectedChan(ros, chan)) {
436 std::vector<float> sample = digits->samples();
437 if(sample.size() != m_nSamples) {
438 ATH_MSG_ERROR( " sample size mismatch for drawer:" << drawerIdStr(frag)
439 <<" in:" << sample.size() << " expected:" << m_nSamples.value() );
440 } else {
441 for (unsigned jsample = 0; jsample < m_nSamples; ++jsample) {
442 f_SampleTime = ((float) jsample) * 25.;
443 f_phase1 = (25. * ((float) phase)) / (30. * 8);
444 f_phase2 = -pmtdata.time;
445 f_time = f_SampleTime + f_phase1 - 100;
446 f_tfittime = f_SampleTime + f_phase2 - 100;
447 if (phase >= 160) {
448 f_time -= 25;
449 f_phase1 -= 25;
450 }
451
452 if (phase < 140 || phase > 160) {
453 // if Low gain convert to the HG scale
454 if (gain == 0) {
455 m_h1_time_check->Fill(f_phase1 - f_phase2);
456 m_h2_time_check->Fill(f_phase1, f_phase2);
457
458 if (fabs(pmtdata.energy) > m_eneLowLimitPulseShape) {
459 pmtdata.pulseShapeLow.Fill(f_tfittime, (LG2HG * (sample[jsample] - rawch->pedestal())));
460 }
461 }
462 //HG
463 else if (fabs(pmtdata.energy) > m_eneLowLimitPulseShape) {
464 pmtdata.pulseShapeHigh.Fill(f_tfittime, (sample[jsample] - rawch->pedestal()));
465 }
466 } // if Cispar not in 140->160 (range with time jitter,
467 //difficult to handle for smooth pulse shape
468 }
469 } // end loop over jsample
470 } // end if PMT is connected
471#endif
472 // <--pulse data
473
474 } // else: ok digits and raw channels
475 } // end collection loop
476
477 //=====================================================================================
478 //=== Compute mean Tfit (corrected for laser fiber length) over the first digitizer ===
479 //=====================================================================================
480 Nconnected = 0;
481 ddata->FarDigitizerMeanTime = 0.;
482 for (int ipmt = 0; ipmt < 6; ++ipmt) {
483 if (isConnectedPMT(ros, ipmt)) {
484 ddata->FarDigitizerMeanTime += (ddata->pmtd[ipmt]->time - fiberCorrection(ros, ipmt));
485 Nconnected++;
486 }
487 }
488 if (Nconnected)
489 ddata->FarDigitizerMeanTime /= (float) Nconnected;
490
491#ifdef TileLaserTimingMon
492 ddata->Digi0Time.Fill(ddata->FarDigitizerMeanTime);
493#endif
494
495 if (msgLvl(MSG::VERBOSE) && (ros == 1) && (drawer == 1)) {
496 ATH_MSG_VERBOSE( " ddata->FarDigitizerMeanTime:" << ddata->FarDigitizerMeanTime );
497 }
498
499 //============================================================================
500 //=== Calculate residuals. Fill histos with time diff b/w PMT i and digi 1 ===
501 //============================================================================
502 for (int ipmt = 0; ipmt < NCHANNELS; ipmt++) {
503 if (isConnectedPMT(ros, ipmt)) {
504 ChannelOffset = -(ddata->pmtd[ipmt]->time - fiberCorrection(ros, ipmt) - ddata->FarDigitizerMeanTime);
505 ddata->pmtd[ipmt]->TimeDiffResHis.Fill(ChannelOffset);
506 if (msgLvl(MSG::VERBOSE) && (ros == 1) && (drawer == 1)) {
507 ATH_MSG_VERBOSE( " ipmt:" << ipmt << " ChannelOffset:" << ChannelOffset );
508 }
509 }
510 }
511
512 } // else: matching digits and raw channel collections
513 }
514 } // end container loop
515
516 //=====================================================================================
517 //=== this histogram contains the difference between first digitizer of drawer 1 and drawer 2: drawer offset
518 //=====================================================================================
519 for (unsigned int ros = 1; ros < TileCalibUtils::MAX_ROS; ++ros) {
520 if (drawerData(ros, m_refDrawer)) {
521 DrawerData &drawer0data = *drawerData(ros, m_refDrawer);
522 for (unsigned int drawer = 0; drawer < TileCalibUtils::MAX_DRAWER; ++drawer) {
523 if ((drawer != m_refDrawer) && drawerData(ros, drawer)) {
524 DrawerData &ddata = *drawerData(ros, drawer);
525 ddata.Digi0TimeDiffHisto.Fill( ddata.FarDigitizerMeanTime - drawer0data.FarDigitizerMeanTime);
526
527 if (msgLvl(MSG::VERBOSE) && (ros == 1) && (drawer == 1)) {
528 ATH_MSG_VERBOSE( " drawerdiff:" << ddata.FarDigitizerMeanTime - drawer0data.FarDigitizerMeanTime );
529 }
530 }
531 }
532 }
533 }
534 }
535
536 return StatusCode::SUCCESS;
537}
#define ATH_CHECK
Evaluate an expression and check for errors.
#define ATH_MSG_ERROR(x,...)
#define ATH_MSG_VERBOSE(x,...)
bool msgLvl(const MSG::Level lvl) const
DataModel_detail::const_iterator< DataVector > const_iterator
Standard const_iterator.
Definition DataVector.h:861
const T * at(size_type n) const
Access an element, as an rvalue.
size_type size() const noexcept
Returns the number of elements in the collection.
static const unsigned int MAX_ROS
Number of ROSs.
static const unsigned int MAX_DRAWER
Number of drawers in ROS 1-4.
const std::vector< float > & samples() const
Definition TileDigits.h:58
Gaudi::Property< unsigned int > m_refDrawer
SG::ReadHandleKey< xAOD::EventInfo > m_eventInfoKey
SG::ReadHandleKey< TileDigitsContainer > m_digitsContainerKey
bool isConnectedChan(int ros, int chan)
int m_nevts
number of laser events
std::string drawerIdStr(int frag)
DrawerData * drawerData(int ros, int drawer)
Gaudi::Property< unsigned > m_nSamples
int channel2PMT(int ros, int chan)
SG::ReadHandleKey< TileRawChannelContainer > m_rawChannelContainerKey
double fiberCorrection(int ros, int pmt)
Gaudi::Property< double > m_eneLowLimitPulseShape
float pedestal(void) const
float time(int ind=0) const
float amplitude(int ind=0) const
Identifier identify(void) const
Definition TileRawData.h:52
HWIdentifier adc_HWID(void) const
Definition TileRawData.h:53
const SG::AuxVectorData * container() const
Return the container holding this element.

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase & ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ fiberCorrection()

double TileLaserTimingTool::fiberCorrection ( int ros,
int pmt )
inlineprivate
Returns
timing correction for fiber length, for given PMT

Definition at line 323 of file TileLaserTimingTool.h.

323 {
324 return (s_fiberLength[isExtBarrel(ros)][pmt] - s_fiberLength[isExtBarrel(ros)][0])
326 }
Gaudi::Property< double > m_fiberLightSpeed
static bool isExtBarrel(int ros)
static const float s_fiberLength[2][48]

◆ fiberLength()

float TileLaserTimingTool::fiberLength ( int ros,
int pmt )
inlinestaticprivate

Definition at line 327 of file TileLaserTimingTool.h.

327 {
328 return s_fiberLength[isExtBarrel(ros)][pmt];
329 }

◆ finalize()

StatusCode TileLaserTimingTool::finalize ( )
overridevirtual

Implements ITileCalibTool.

Definition at line 859 of file TileLaserTimingTool.cxx.

859 {
860
861 ATH_MSG_INFO( "finalize()" );
862
863 return StatusCode::SUCCESS;
864}
#define ATH_MSG_INFO(x,...)

◆ finalizeCalculations()

StatusCode TileLaserTimingTool::finalizeCalculations ( )
overridevirtual

Implements ITileCalibTool.

Definition at line 539 of file TileLaserTimingTool.cxx.

539 {
540
541 ATH_MSG_INFO( "finalizeCalculations()" );
542
543 gROOT->cd();
544
545 float fmean, fdummy, fchi2, fmeanerr;
546
547 for (unsigned int ros = 1; ros < TileCalibUtils::MAX_ROS; ++ros) {
548 for (unsigned int drawer = 0; drawer < TileCalibUtils::MAX_DRAWER; ++drawer) {
549 DrawerData &drawerd = *drawerData(ros, drawer);
550
551 for (int ipmt = 0; ipmt < NCHANNELS; ++ipmt) {
552 PMTData &pmtd = *drawerd.pmtd[ipmt];
553 // to simplify the root analysis, store the fiber length, not really neccessary
554 m_FiberLength[ros][drawer][ipmt] = fiberLength(ros, ipmt);
555#ifdef TileLaserTimingMon
556 m_FiberCorrection[ros][drawer][ipmt] = fiberCorrection(ros, ipmt);
557 m_IsConnected[ros][drawer][ipmt] = isConnectedPMT(ros, ipmt);
558#endif
559 //==========================================================================================
560 //==== Pulse shapes ====
561
562 // use the number of entries in the histos as the number of passed events for high/low
563
564#ifdef TileLaserTimingMonPulse
565 if(pmtd.TimeDiffHistoLow.GetEntries() > 0.99 * m_nevts) {
566 m_PulseShapeLow->Add(&pmtd.pulseShapeLow);
567 }
568
569 if(pmtd.TimeDiffHistoHigh.GetEntries() > 0.99 * m_nevts) {
570 m_PulseShapeHigh->Add(&pmtd.pulseShapeHigh);
571 }
572#endif
573
574 if (ipmt > 0) {
575 //==================================================================
576 // Fit time difference regardless of gain, to derive standard Dskews
577 //==================================================================
578 if (isConnectedPMT(ros, ipmt)) {
579 fitGauss(pmtd.TimeDiffHisto, m_TimeDiffMean[ros][drawer][ipmt], m_TimeDiffSigma[ros][drawer][ipmt], m_TimeDiffMeanError[ros][drawer][ipmt]);
580 }
581
582#ifdef TileLaserTimingPMT0
583 //===========================================================
584 //=== Fit time difference without clear fiber corrections ===
585 //===========================================================
586 if(isConnectedPMT(ros, ipmt)) {
587 fitGauss(pmtd.TimeDiffNoCFCorrHisto, m_TimeDiffNoCFCorrMean[ros][drawer][ipmt], m_TimeDiffNoCFCorrSigma[ros][drawer][ipmt], m_TimeDiffNoCFCorrMeanError[ros][drawer][ipmt]);
588 }
589
590 //================================================================================
591 //==== Fit gauss to time differences in all gains/ low gain/ high gain in all PMTs
592 //================================================================================
593
594 fitGauss(pmtd.TimeDiffHistoLow, m_TimeDiffLowMean[ros][drawer][ipmt], m_TimeDiffLowSigma[ros][drawer][ipmt], m_TimeDiffLowMeanError[ros][drawer][ipmt]);
595
596 //------------------------------------- For high gain --------------------------------------
597
598 fitGauss(pmtd.TimeDiffHistoHigh, m_TimeDiffHighMean[ros][drawer][ipmt], m_TimeDiffHighSigma[ros][drawer][ipmt], m_TimeDiffHighMeanError[ros][drawer][ipmt]);
599#endif
600 }
601
602 //==================================================================================
603 //=== Fit mean value of time difference b/w drawer_i(pmt_j) and drawer_i(digi_1) ===
604 //==================================================================================
605
606 // TODO: previous values on error
607 if (isConnectedPMT(ros, ipmt)) {
609 m_TimeDiffPMTDigi0[ros][drawer][ipmt] = m_ChannelOffset[ros][drawer][ipmt] = pmtd.TimeDiffResHis.GetMean();
610 m_ChannelOffsetError[ros][drawer][ipmt] = pmtd.TimeDiffResHis.GetMeanError();
611 } else {
612 fitGauss2(pmtd.TimeDiffResHis, fmean, fdummy, fchi2, fmeanerr, 1.0, 3.0);
613
614 if (fchi2 > 500) {
615 ATH_MSG_WARNING( "pmt # " << ipmt + 1
616 << " has chi2 value " << fchi2
617 << " force timing residual same as PMT-1 " );
618
619 // FittedMean=PreviousFittedMean;
620 fchi2 = -fchi2; // just to make Coverity happt
621 fmean = -4711;
622 fmeanerr = 0.0;
623 }
624 if (fabs(fmean) > 100) {
625 ATH_MSG_WARNING( " pmt # " << ipmt + 1
626 << " has ChannelOffset " << fmean
627 << " force timing residual same as PMT-1" );
628
629 // FittedMean=PreviousFittedMean;
630 fmean = -4711;
631 fmeanerr = 0.0;
632 }
633 m_ChannelOffset[ros][drawer][ipmt] = fmean;
634 m_ChannelOffsetError[ros][drawer][ipmt] = fmeanerr;
635 }
636 } else {
637 m_ChannelOffset[ros][drawer][ipmt] = 0.0;
638 m_ChannelOffsetError[ros][drawer][ipmt] = 0.0;
639 }
640
641#ifdef TileLaserTimingMonPulse
642 //===========================================================
643 //=== Pedestal and ADC Amplitudes ===
644 //===========================================================
645 pmtd.pedestal.getStat(m_PedestalMean[ros][drawer][ipmt], m_PedestalSigma[ros][drawer][ipmt]);
646 if (isConnectedPMT(ros, ipmt))
647 m_ADCAmplitude[ros][drawer][ipmt] = fmax(pmtd.pulseShapeHigh.GetMaximum(), pmtd.pulseShapeLow.GetMaximum());
648 else
649 m_ADCAmplitude[ros][drawer][ipmt] = 0.;
650
651 if (msgLvl(MSG::VERBOSE) && (ros == 1) && (drawer == 1)) {
652 msg(MSG::VERBOSE) << "ipmt: " << ipmt
653 << " TimeDiffLow: " << m_TimeDiffLowMean[ros][drawer][ipmt] << "(" << m_TimeDiffLowSigma[ros][drawer][ipmt] << ") +-" << m_TimeDiffLowMeanError[ros][drawer][ipmt]
654 << " TimeDiffHigh:" << m_TimeDiffHighMean[ros][drawer][ipmt] << "(" << m_TimeDiffHighSigma[ros][drawer][ipmt] << ") +-" << m_TimeDiffHighMeanError[ros][drawer][ipmt] << endmsg;
655
656 msg(MSG::VERBOSE) << " TimeDiff:" << m_TimeDiffMean[ros][drawer][ipmt] << "(" << m_TimeDiffSigma[ros][drawer][ipmt] << ") +-" << m_TimeDiffMeanError[ros][drawer][ipmt]
657 << " TomeDiffNoCF:" << m_TimeDiffNoCFCorrMean[ros][drawer][ipmt] << "(" << m_TimeDiffNoCFCorrSigma[ros][drawer][ipmt] << ") +-" << m_TimeDiffNoCFCorrMeanError[ros][drawer][ipmt] << endmsg;
658
659 msg(MSG::VERBOSE) << " ped:" << m_PedestalMean[ros][drawer][ipmt] << "(" << m_PedestalSigma[ros][drawer][ipmt]
660 << ") amp:" << m_ADCAmplitude[ros][drawer][ipmt] << endmsg;
661 }
662#endif
663
664 } // end PMT loop
665
666 //============================================
667 //========= Fit mean DrawerOffset ============
668 //============================================
669
670 fitGauss2(drawerd.Digi0TimeDiffHisto, m_DrawerOffset[ros][drawer], fdummy, fdummy, m_DrawerOffsetError[ros][drawer], 0.5, 1.0);
671
672 ATH_MSG_DEBUG( "finalizeCalculations()"
673 << " ros: " << ros
674 << " drawer:" << drawer
675 << " DrawerOffset:" << m_DrawerOffset[ros][drawer] << "("
676 << m_DrawerOffsetError[ros][drawer] << ")" );
677
678 //==============================================================
679 //=== correct for overall offset between odd and even fibers ===
680 //
681 // Better would be to meassure the laser fiber lengths and
682 // implement this as a correction. Meanwhile, use this as
683 // a compromise.
684 //==============================================================
685 // CCC: MeanEvenPmtTdiff= 0;
686 // CCC: MeanOddPmtTdiff = 0;
687 // CCC: DeltaParity = 0;
688 // CCC: OddPmtCounter =0;
689 // CCC: EvenPmtCounter =0;
690
692
694
696
697 //==================================================================
698 //=== Calculate Dskews ===
699 //==================================================================
700 for (int ipmt = 0; ipmt < NCHANNELS; ++ipmt) {
701 // LBA and LBC
702 if (isBarrel(ros)) {
703 if (isConnectedPMT(ros, ipmt) && (timeDiffs[ros][drawer][ipmt] < 300)) {
704 drawerd.digid[ipmt / 6].Add(timeDiffs[ros][drawer][ipmt]);
705 }
706 if (ipmt % 6 == 5) {
707 drawerd.digid[ipmt / 6].Freeze();
708 }
709 } // end isBarrel
710 // EBA and EBC%
711 else if (isExtBarrel(ros)) {
712 if (isConnectedPMT(ros, ipmt) && (timeDiffs[ros][drawer][ipmt] < 300)) {
713 if (ipmt < 6) drawerd.digid[0].Add(timeDiffs[ros][drawer][ipmt]);
714 else if (ipmt > 5 && ipmt < 12) drawerd.digid[1].Add(timeDiffs[ros][drawer][ipmt]);
715 else if (ipmt > 11 && ipmt < 18) drawerd.digid[2].Add(timeDiffs[ros][drawer][ipmt]);
716 else if (ipmt > 17 && ipmt < 24) drawerd.digid[3].Add(timeDiffs[ros][drawer][ipmt]);
717 else if (ipmt > 27 && ipmt < 34) {
718 drawerd.digid[4].Add(timeDiffs[ros][drawer][ipmt]);
719 drawerd.digid[5].Add(timeDiffs[ros][drawer][ipmt]);
720 } else if (ipmt > 35) {
721 drawerd.digid[6].Add(timeDiffs[ros][drawer][ipmt]);
722 drawerd.digid[7].Add(timeDiffs[ros][drawer][ipmt]);
723 }
724 }
725
726 if (ipmt == 5) drawerd.digid[0].Freeze();
727 else if (ipmt == 11) drawerd.digid[1].Freeze();
728 else if (ipmt == 17) drawerd.digid[2].Freeze();
729 else if (ipmt == 23) drawerd.digid[3].Freeze();
730 else if (ipmt == 33) {
731 drawerd.digid[4].Freeze();
732 drawerd.digid[5].Freeze();
733 } else if (ipmt == 47) {
734 drawerd.digid[6].Freeze();
735 drawerd.digid[7].Freeze();
736 }
737 } // end isExtBarrel
738 } // end PMT loop
739
740 for (int digi = 0; digi < NDIGI; ++digi) {
741 m_DigiMean[ros][drawer][digi] = drawerd.digid[digi].GetDigiTime();
742 m_DSkewSet[ros][drawer][digi] = (m_DigiMean[ros][drawer][digi] - m_DigiMean[ros][drawer][0]) * 240. / 25.;
743
744 ATH_MSG_DEBUG( "finalizeCalculations()"
745 << " ros: " << ros
746 << " drawer: " << drawer
747 << " digi: " << digi
748 << " digi_time: " << drawerd.digid[digi].GetDigiTime()
749 << " #active: " << drawerd.digid[digi].GetTotActive()
750 << " DSkewSet: " << m_DSkewSet[ros][drawer][digi] );
751
752 }
753 } // end drawer loop
754 } // end ros loop
755
756 return StatusCode::SUCCESS;
757}
#define endmsg
MsgStream & msg() const
void fitGauss(TH1F &hi, float &p1, float &p2, float &p1_err)
Fit a Gaussian function (m_gaussf) to the given histogram, store mean, rms and mean error.
Gaudi::Property< bool > m_usePMT0AsDskewRef
static bool isBarrel(int ros)
static float fiberLength(int ros, int pmt)
void correctEvenOddPMT(int ros, int drawer, TPMTArray &ChannelOffset, TDrawerArrayF &MeanOddPmtTdiff, TDrawerArrayI &OddPmtCounter, TDrawerArrayF &MeanEvenPmtTdiff, TDrawerArrayI &EvenPmtCounter, TDrawerArrayF &EvenOddTimeDiff)
Correct for differences between even and odd PMTs.
float(* TPMTArray)[NDRAWERS][NCHANNELS]
void fitGauss2(TH1F &hi, float &p1, float &p2, float &chi2, float &p1_err, float w1, float w2)
Fit a Gaussian function with two iterations mean range = hi.mean +- w1|w2 * hi.rms.
Gaudi::Property< bool > m_useMeanChannelOffset

◆ fitGauss()

void TileLaserTimingTool::fitGauss ( TH1F & hi,
float & p1,
float & p2,
float & p1_err )
private

Fit a Gaussian function (m_gaussf) to the given histogram, store mean, rms and mean error.

Definition at line 882 of file TileLaserTimingTool.cxx.

882 {
883
884 if (hi.GetEntries() == 0) {
885 p1 = p2 = p1_err = 0.0;
886 return;
887 }
888 double MaxAmplitude = hi.GetMaximum();
889 double MeanTimeDiff = hi.GetMean();
890 double RMSTimeDiff = hi.GetRMS();
891 m_gaussf->SetParameter(0, MaxAmplitude);
892 m_gaussf->SetParameter(1, MeanTimeDiff);
893 m_gaussf->SetParameter(2, RMSTimeDiff);
894 m_gaussf->SetRange(MeanTimeDiff - 2.0 * RMSTimeDiff, MeanTimeDiff + 2.0 * RMSTimeDiff);
895
896 hi.Fit(m_gaussf, "QR");
897
898 p1 = m_gaussf->GetParameter(1);
899 p1_err = m_gaussf->GetParError(1);
900 p2 = m_gaussf->GetParameter(2);
901}

◆ fitGauss2()

void TileLaserTimingTool::fitGauss2 ( TH1F & hi,
float & p1,
float & p2,
float & chi2,
float & p1_err,
float w1,
float w2 )
private

Fit a Gaussian function with two iterations mean range = hi.mean +- w1|w2 * hi.rms.

Definition at line 903 of file TileLaserTimingTool.cxx.

903 {
904
905 if (hi.GetEntries() == 0) {
906 p1 = p2 = chi2 = p1_err = w1 = w2 = 0.0;
907 return;
908 }
909
910 double MaxAmplitude = hi.GetMaximum();
911 double MeanTimeDiff = hi.GetMean();
912 double RMSTimeDiff = hi.GetRMS();
913
914 m_gaussf->SetParameter(0, MaxAmplitude);
915 m_gaussf->SetParameter(1, MeanTimeDiff);
916 m_gaussf->SetParameter(2, RMSTimeDiff);
917 m_gaussf->SetRange(MeanTimeDiff - w1 * RMSTimeDiff, MeanTimeDiff + w1 * RMSTimeDiff);
918
919 hi.Fit(m_gaussf, "QR");
920 double FittedAmplitude = m_gaussf->GetParameter(0);
921 double FittedMean = m_gaussf->GetParameter(1);
922 double FittedSigma = m_gaussf->GetParameter(2);
923
924 //=== Iterate once ===
925
926 m_gaussf->SetParameter(0, FittedAmplitude);
927 m_gaussf->SetParameter(1, FittedMean);
928 m_gaussf->SetParameter(2, FittedSigma);
929 m_gaussf->SetRange(FittedMean - w2 * FittedSigma, FittedMean + w2 * FittedSigma);
930
931 hi.Fit(m_gaussf, "QR");
932 p1 = m_gaussf->GetParameter(1);
933 p2 = m_gaussf->GetParameter(2);
934 p1_err = m_gaussf->GetParError(1);
935 chi2 = m_gaussf->GetChisquare();
936}
double chi2(TH1 *h0, TH1 *h1)

◆ initialize()

StatusCode TileLaserTimingTool::initialize ( )
overridevirtual

Use timing tool to get cell fiber lengths, when implemented! float athfl, offlfl; const int drawerIdx = TileCalibUtils::getDrawerIdx(1, 0); for (int pmt = 0; pmt < 48; pmt++) { athfl = m_tileToolTiming->getCellFiberLength(drawerIdx, pmt); offlfl = fiberLength(1, pmt); ATH_MSG_INFO( " " << pmt << " : " << athfl << " , " << offlfl ); }

Implements ITileCalibTool.

Definition at line 242 of file TileLaserTimingTool.cxx.

242 {
243
244 ATH_MSG_INFO( "initialize()" );
245
246 // get TileHWID helper
247 CHECK( detStore()->retrieve(m_tileHWID) );
248
249 // get the timing tool
250 CHECK( m_tileToolTiming.retrieve() );
251
252 // get TileCabling Service
254
255 m_nevts = 0;
256
257 ATH_CHECK( m_eventInfoKey.initialize() );
258 ATH_CHECK( m_rawChannelContainerKey.initialize() );
259 ATH_CHECK( m_digitsContainerKey.initialize() );
260
261 // gauss fit function
262 m_gaussf = new TF1("GainGauss", "[0]*exp(- (x-[1])*(x-[1])/(2*[2]*[2]))", -60, 60);
263
264 ATH_MSG_DEBUG( "initialize() ready " );
265
276
277 return StatusCode::SUCCESS;
278}
#define CHECK(...)
Evaluate an expression and check for errors.
const ServiceHandle< StoreGateSvc > & detStore() const
static const TileCablingService * getInstance()
get pointer to service instance
ToolHandle< TileCondToolTiming > m_tileToolTiming

◆ initNtuple()

StatusCode TileLaserTimingTool::initNtuple ( int runNumber,
int runType,
TFile * rootfile )
overridevirtual

Implements ITileCalibTool.

Definition at line 280 of file TileLaserTimingTool.cxx.

280 {
281
282 ATH_MSG_INFO( "initNtuple(" << runNumber << "," << runType << "," << rootFile << ")" );
283
284 return StatusCode::SUCCESS;
285}

◆ inputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

const InterfaceID & ITileCalibTool::interfaceID ( )
inlinestaticinherited

Definition at line 21 of file ITileCalibTool.h.

21{ return IID_ITileCalibTool; }
static const InterfaceID IID_ITileCalibTool("ITileCalibTool", 1, 0)

◆ isBarrel()

bool TileLaserTimingTool::isBarrel ( int ros)
inlinestaticprivate
Returns
if ros is the barrel, LBA or LBC

Definition at line 315 of file TileLaserTimingTool.h.

315 {
316 return ros == 1 || ros == 2;
317 }

◆ isConnectedChan()

bool TileLaserTimingTool::isConnectedChan ( int ros,
int chan )
inlineprivate
Returns
if channel is connected

Definition at line 303 of file TileLaserTimingTool.h.

303 {
304 if (m_cabling->channel2hole(ros, chan) < 0) return false;
305 return true;
306 }

◆ isConnectedPMT()

bool TileLaserTimingTool::isConnectedPMT ( int ros,
int chan )
staticprivate
Returns
if a PMT is connected

Definition at line 868 of file TileLaserTimingTool.cxx.

868 {
869 if (isBarrel(ros)) {
870 return !(ipmt == 31 || ipmt == 32 || ipmt == 43);
871 } else if (isExtBarrel(ros)) {
872 return !( ipmt == 18 || ipmt == 19 || ipmt == 24 || ipmt == 25
873 || ipmt == 26 || ipmt == 27 || ipmt == 30 || ipmt == 31
874 || ipmt == 34 || ipmt == 35 || ipmt == 38 || ipmt == 39
875 || ipmt == 44 || ipmt == 45 || ipmt == 46 || ipmt == 47);
876 }
877
878 return false;
879}

◆ isExtBarrel()

bool TileLaserTimingTool::isExtBarrel ( int ros)
inlinestaticprivate
Returns
if ros is the extended barrel, EBA or EBC

Definition at line 319 of file TileLaserTimingTool.h.

319 {
320 return ros == 3 || ros == 4;
321 }

◆ msg()

MsgStream & AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24 {
25 return this->msgStream();
26 }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30 {
31 return this->msgLevel(lvl);
32 }

◆ outputHandles()

virtual std::vector< Gaudi::DataHandle * > AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ renounce()

std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T & h)
inlineprotectedinherited

Definition at line 368 of file AthCommonDataStore.h.

369 {
370 h.renounce();
372 }
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce(T &h)

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray & handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 352 of file AthCommonDataStore.h.

352 {
354 }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in asg::AsgMetadataTool, AthCheckedComponent< AthAlgTool >, and AthCheckedComponent<::AthAlgTool >.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase & )
inlineinherited

Definition at line 298 of file AthCommonDataStore.h.

298 {
299 for (auto &a : m_vhka) {
301 for (auto k : keys) {
302 k->setOwner(this);
303 }
304 }
305 }
std::vector< SG::VarHandleKeyArray * > m_vhka

◆ writeNtuple()

StatusCode TileLaserTimingTool::writeNtuple ( int runNumber,
int runType,
TFile * rootfile )
overridevirtual

Implements ITileCalibTool.

Definition at line 759 of file TileLaserTimingTool.cxx.

759 {
760
761 ATH_MSG_INFO( "writeNtuple(" << runNumber << "," << runType << "," << rootFile << ")" );
762
763 // Write a tree with all arrays
764 TTree *t = new TTree(m_ntupleID.value().c_str(), "TileLaserTimingNtuple");
765 t->Branch("DrawerOffset", m_DrawerOffset, "DrawerOffset[5][64]/F"); // float m_DrawerOffset[s_NRos][64];
766 t->Branch("DrawerOffsetError", m_DrawerOffsetError, "DrawerOffsetError[5][64]/F"); // float m_DrawerOffsetError[NROS][64];
767
768 t->Branch("ChannelOffset", m_ChannelOffset, "ChannelOffset[5][64][48]/F"); // float m_ChannelOffset[NROS][64][48];
769 t->Branch("ChannelOffsetError", m_ChannelOffsetError, "ChannelOffsetError[5][64][48]/F"); // float m_ChannelOffsetError[NROS][64][48];
770
771 t->Branch("ADCAmplitude", m_ADCAmplitude, "ADCAmplitude[5][64][48]/F"); // float m_ADCAmplitude[NROS][64][48];
772
773 t->Branch("PedestalMean", m_PedestalMean, "PedestalMean[5][64][48]/F"); // float m_PedestalMean[NROS][64][48];
774 t->Branch("PedestalSigma", m_PedestalSigma, "PedestalSigma[5][64][48]/F"); // float m_PedestalSigma[NROS][64][48];
775
776 t->Branch("TimeDiffMean", m_TimeDiffMean, "TimeDiffMean[5][64][48]/F"); // float m_TimeDiffMean[NROS][64][48];
777 t->Branch("TimeDiffMeanError", m_TimeDiffMeanError, "TimeDiffMeanError[5][64][48]/F"); // float m_TimeDiffMeanError[NROS][64][48];
778 t->Branch("TimeDiffSigma", m_TimeDiffSigma, "TimeDiffSigma[5][64][48]/F"); // float m_TimeDiffSigma[NROS][64][48];
779
780#ifdef TileLaserTimingPMT0Mon
781 t->Branch("TimeDiffHighMean", m_TimeDiffHighMean, "TimeDiffHighMean[5][64][48]/F"); // float m_TimeDiffHighMean[NROS][64][48];
782 t->Branch("TimeDiffHighMeanError", m_TimeDiffHighMeanError, "TimeDiffHighMeanError[5][64][48]/F"); // float m_TimeDiffHighMeanError[NROS][64][48];
783 t->Branch("TimeDiffHighSigma", m_TimeDiffHighSigma, "TimeDiffHighSigma[5][64][48]/F"); // float m_TimeDiffHighSigma[NROS][64][48];
784 t->Branch("TimeDiffLowMean", m_TimeDiffLowMean, "TimeDiffLowMean[5][64][48]/F"); // float m_TimeDiffLowMean[NROS][64][48];
785 t->Branch("TimeDiffLowMeanError", m_TimeDiffLowMeanError, "TimeDiffLowMeanError[5][64][48]/F"); // float m_TimeDiffLowMeanError[NROS][64][48];
786 t->Branch("TimeDiffLowSigma", m_TimeDiffLowSigma, "TimeDiffLowSigma[5][64][48]/F"); // float m_TimeDiffLowSigma[NROS][64][48];
787 t->Branch("TimeDiffNoCFCorrMean", m_TimeDiffNoCFCorrMean, "TimeDiffNoCFCorrMean[5][64][48]/F"); // float m_TimeDiffNoCFCorrMean[NROS][64][48];
788 t->Branch("TimeDiffNoCFCorrMeanError", m_TimeDiffNoCFCorrMeanError, "TimeDiffNoCFCorrMeanError[5][64][48]/F"); // float m_TimeDiffNoCFCorrMeanError[NROS][64][48];
789 t->Branch("TimeDiffNoCFCorrSigma", m_TimeDiffNoCFCorrSigma, "TimeDiffNoCFCorrSigma[5][64][48]/F"); // float m_TimeDiffNoCFCorrSigma[NROS][64][48];
790#endif
791 t->Branch("FiberLength", m_FiberLength, "FiberLength[5][64][48]/F"); // float m_FiberLength[NROS][64][48];
792
793#ifdef TileLaserTimingMon
794 t->Branch("EvenOddTimeDiff", m_EvenOddTimeDiff, "EvenOddTimeDiff[5][64]/F"); // float m_EvenOddTimeDiff[NROS][64];
795
796 t->Branch("FiberCorrection", m_FiberCorrection, "FiberCorrection[5][64][48]/F"); // float m_FiberCorrection[NROS][64][48];
797 t->Branch("IsConnected", m_IsConnected, "IsConnected[5][64][48]/F"); // float m_FiberCorrection[NROS][64][48];
798
799 t->Branch("MeanOddPmtTdiff", m_MeanOddPmtTdiff, "MeanOddPmtTdiff[5][64]/F");
800 t->Branch("OddPmtCounter", m_OddPmtCounter, "OddPmtCounter[5][64]/I");
801 t->Branch("MeanEvenPmtTdiff", m_MeanEvenPmtTdiff, "MeanEvenPmtTdiff[5][64]/F");
802 t->Branch("EvenPmtCounter", m_EvenPmtCounter, "EvenPmtCounter[5][64]/I");
803
804 t->Branch("TimeDiffPMTDigi0", m_TimeDiffPMTDigi0, "TimeDiffPMTDigi0[5][64][48]/F");
805#endif
806
807 // mon pmt0-->
808 t->Branch("EvenOddTimeDiffPMT0", m_EvenOddTimeDiffPMT0, "EvenOddTimeDiffPMT0[5][64]/F");
809 t->Branch("MeanOddPmtTdiffPMT0", m_MeanOddPmtTdiffPMT0, "MeanOddPmtTdiffPMT0[5][64]/F");
810 t->Branch("OddPmtCounterPMT0", m_OddPmtCounterPMT0, "OddPmtCounterPMT0[5][64]/I");
811 t->Branch("MeanEvenPmtTdiffPMT0", m_MeanEvenPmtTdiffPMT0, "MeanEvenPmtTdiffPMT0[5][64]/F");
812 t->Branch("EvenPmtCounterPMT0", m_EvenPmtCounterPMT0, "EvenPmtCounterPMT0[5][64]/I");
813 // <-- mon pmt0
814
815 t->Branch("DSkewSet", m_DSkewSet, "DSkewSet[5][64][8]/F"); // float m_DSkewSet[NROS][64][8];
816 t->Branch("DigiMean", m_DigiMean, "DigiMean[5][64][8]/F"); // float m_DigiMean[NROS][64][8];
817 t->Fill();
818 rootFile->cd();
819 t->Write();
820
821 ATH_MSG_INFO( "writeNtuple(" << runNumber << "," << runType << "," << rootFile << ") data written" );
822
823 rootFile->ls();
824
825 // store histos
826 for (unsigned int ros = 1; ros < TileCalibUtils::MAX_ROS; ++ros) {
827 for (unsigned int drawer = 0; drawer < TileCalibUtils::MAX_DRAWER; ++drawer) {
828 ATH_MSG_VERBOSE( "writeNtuple() ros:" << ros << " drawer:" << drawer );
829
830 DrawerData* dd = drawerData(ros, drawer);
831 if (dd) {
832 dd->Digi0TimeDiffHisto.Write();
833#ifdef TileLaserTimingMon
834 dd->Digi0Time.Write();
835#endif
836 for (int ipmt = 0; ipmt < NCHANNELS; ++ipmt) {
837 if (isConnectedPMT(ros, ipmt)) {
838 /*dd->pmtd[ipmt]->TimeDiffHisto.Write();
839 dd->pmtd[ipmt]->TimeDiffNoCFCorrHisto.Write();*/
840#ifdef TileLaserTimingMon
841 dd->pmtd[ipmt]->timeHisto.Write();
842 dd->pmtd[ipmt]->eneHisto.Write();
843 dd->pmtd[ipmt]->gainHisto.Write();
844#endif
845 /*dd->pmtd[ipmt]->TimeDiffHistoHigh.Write();
846 dd->pmtd[ipmt]->pulseShapeHigh.Write();
847 dd->pmtd[ipmt]->TimeDiffHistoLow.Write();
848 dd->pmtd[ipmt]->pulseShapeLow.Write();*/
849 dd->pmtd[ipmt]->TimeDiffResHis.Write();
850 }
851 }
852 }
853 }
854 }
855
856 return StatusCode::SUCCESS;
857}
Gaudi::Property< std::string > m_ntupleID

Member Data Documentation

◆ m_ADCAmplitude

float(* TileLaserTimingTool::m_ADCAmplitude)[NDRAWERS][NCHANNELS]
private

Definition at line 188 of file TileLaserTimingTool.h.

◆ m_cabling

const TileCablingService* TileLaserTimingTool::m_cabling {nullptr}
private

Definition at line 258 of file TileLaserTimingTool.h.

258{nullptr};

◆ m_ChannelOffset

float(* TileLaserTimingTool::m_ChannelOffset)[NDRAWERS][NCHANNELS]
private

Definition at line 185 of file TileLaserTimingTool.h.

◆ m_ChannelOffsetError

float(* TileLaserTimingTool::m_ChannelOffsetError)[NDRAWERS][NCHANNELS]
private

Definition at line 186 of file TileLaserTimingTool.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default).

Definition at line 381 of file AthCommonDataStore.h.

◆ m_DigiMean

float(* TileLaserTimingTool::m_DigiMean)[NDRAWERS][NDIGI]
private

Definition at line 236 of file TileLaserTimingTool.h.

◆ m_digitsContainerKey

SG::ReadHandleKey<TileDigitsContainer> TileLaserTimingTool::m_digitsContainerKey
private
Initial value:
{this,
"TileDigitsContainer", "TileDigitsCnt", "Tile digits container"}

Definition at line 253 of file TileLaserTimingTool.h.

253 {this,
254 "TileDigitsContainer", "TileDigitsCnt", "Tile digits container"};

◆ m_digitsContainerName

std::string TileLaserTimingTool::m_digitsContainerName
private

Definition at line 264 of file TileLaserTimingTool.h.

◆ m_drawerData

DrawerData*(* TileLaserTimingTool::m_drawerData)[NDRAWERS]
private

Definition at line 174 of file TileLaserTimingTool.h.

◆ m_DrawerOffset

float(* TileLaserTimingTool::m_DrawerOffset)[NDRAWERS]
private

Definition at line 181 of file TileLaserTimingTool.h.

◆ m_DrawerOffsetError

float(* TileLaserTimingTool::m_DrawerOffsetError)[NDRAWERS]
private

Definition at line 182 of file TileLaserTimingTool.h.

◆ m_DSkewSet

float(* TileLaserTimingTool::m_DSkewSet)[NDRAWERS][NDIGI]
private

Definition at line 235 of file TileLaserTimingTool.h.

◆ m_eneLowLimitPulseShape

Gaudi::Property<double> TileLaserTimingTool::m_eneLowLimitPulseShape {this, "EneLowLimitPulseShape", 0.000001}
private

Definition at line 269 of file TileLaserTimingTool.h.

269{this, "EneLowLimitPulseShape", 0.000001};

◆ m_EvenOddTimeDiff

float(* TileLaserTimingTool::m_EvenOddTimeDiff)[NDRAWERS]
private

Definition at line 232 of file TileLaserTimingTool.h.

◆ m_EvenOddTimeDiffPMT0

float(* TileLaserTimingTool::m_EvenOddTimeDiffPMT0)[NDRAWERS]
private

Definition at line 203 of file TileLaserTimingTool.h.

◆ m_EvenPmtCounter

int(* TileLaserTimingTool::m_EvenPmtCounter)[NDRAWERS]
private

Definition at line 230 of file TileLaserTimingTool.h.

◆ m_EvenPmtCounterPMT0

int(* TileLaserTimingTool::m_EvenPmtCounterPMT0)[NDRAWERS]
private

Definition at line 202 of file TileLaserTimingTool.h.

◆ m_eventInfoKey

SG::ReadHandleKey<xAOD::EventInfo> TileLaserTimingTool::m_eventInfoKey
private
Initial value:
{this,
"EventInfo", "EventInfo", "EventInfo key"}

Definition at line 249 of file TileLaserTimingTool.h.

249 {this,
250 "EventInfo", "EventInfo", "EventInfo key"};

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default).

Definition at line 378 of file AthCommonDataStore.h.

◆ m_FiberCorrection

float(* TileLaserTimingTool::m_FiberCorrection)[NDRAWERS][NCHANNELS]
private

Definition at line 224 of file TileLaserTimingTool.h.

◆ m_FiberLength

float(* TileLaserTimingTool::m_FiberLength)[NDRAWERS][NCHANNELS]
private

Definition at line 220 of file TileLaserTimingTool.h.

◆ m_fiberLightSpeed

Gaudi::Property<double> TileLaserTimingTool::m_fiberLightSpeed {this, "FiberLightSpeed", 0.0}
private

Definition at line 266 of file TileLaserTimingTool.h.

266{this, "FiberLightSpeed", 0.0};

◆ m_gaussf

TF1* TileLaserTimingTool::m_gaussf {nullptr}
private

Definition at line 286 of file TileLaserTimingTool.h.

286{nullptr};

◆ m_IOVTag

std::string TileLaserTimingTool::m_IOVTag
private

Definition at line 279 of file TileLaserTimingTool.h.

◆ m_IsConnected

int(* TileLaserTimingTool::m_IsConnected)[NDRAWERS][NCHANNELS]
private

Definition at line 225 of file TileLaserTimingTool.h.

◆ m_maxTimeDiff

Gaudi::Property<float> TileLaserTimingTool::m_maxTimeDiff {this, "MaxTimeDiff", 10000.}
private

Definition at line 274 of file TileLaserTimingTool.h.

274{this, "MaxTimeDiff", 10000.};

◆ m_MeanEvenPmtTdiff

float(* TileLaserTimingTool::m_MeanEvenPmtTdiff)[NDRAWERS]
private

Definition at line 229 of file TileLaserTimingTool.h.

◆ m_MeanEvenPmtTdiffPMT0

float(* TileLaserTimingTool::m_MeanEvenPmtTdiffPMT0)[NDRAWERS]
private

Definition at line 201 of file TileLaserTimingTool.h.

◆ m_MeanOddPmtTdiff

float(* TileLaserTimingTool::m_MeanOddPmtTdiff)[NDRAWERS]
private

Definition at line 227 of file TileLaserTimingTool.h.

◆ m_MeanOddPmtTdiffPMT0

float(* TileLaserTimingTool::m_MeanOddPmtTdiffPMT0)[NDRAWERS]
private

Definition at line 199 of file TileLaserTimingTool.h.

◆ m_nevts

int TileLaserTimingTool::m_nevts {0}
private

number of laser events

Definition at line 284 of file TileLaserTimingTool.h.

284{0};

◆ m_nSamples

Gaudi::Property<unsigned> TileLaserTimingTool::m_nSamples {this, "NSamples", 9}
private

Definition at line 267 of file TileLaserTimingTool.h.

267{this, "NSamples", 9};

◆ m_ntupleID

Gaudi::Property<std::string> TileLaserTimingTool::m_ntupleID {this, "NtupleID", "h3000"}
private

Definition at line 265 of file TileLaserTimingTool.h.

265{this, "NtupleID", "h3000"};

◆ m_OddPmtCounter

int(* TileLaserTimingTool::m_OddPmtCounter)[NDRAWERS]
private

Definition at line 228 of file TileLaserTimingTool.h.

◆ m_OddPmtCounterPMT0

int(* TileLaserTimingTool::m_OddPmtCounterPMT0)[NDRAWERS]
private

Definition at line 200 of file TileLaserTimingTool.h.

◆ m_PedestalMean

float(* TileLaserTimingTool::m_PedestalMean)[NDRAWERS][NCHANNELS]
private

Definition at line 190 of file TileLaserTimingTool.h.

◆ m_PedestalSigma

float(* TileLaserTimingTool::m_PedestalSigma)[NDRAWERS][NCHANNELS]
private

Definition at line 191 of file TileLaserTimingTool.h.

◆ m_rawChannelContainerKey

SG::ReadHandleKey<TileRawChannelContainer> TileLaserTimingTool::m_rawChannelContainerKey
private
Initial value:
{this,
"TileRawChannelContainer", "TileRawChannelFit", "Tile raw channel container"}

Definition at line 251 of file TileLaserTimingTool.h.

251 {this,
252 "TileRawChannelContainer", "TileRawChannelFit", "Tile raw channel container"};

◆ m_rawChannelContainerName

std::string TileLaserTimingTool::m_rawChannelContainerName
private

Definition at line 263 of file TileLaserTimingTool.h.

◆ m_refDrawer

Gaudi::Property<unsigned int> TileLaserTimingTool::m_refDrawer {this, "ReferenceDrawer", 39}
private

Definition at line 271 of file TileLaserTimingTool.h.

271{this, "ReferenceDrawer", 39};

◆ m_tileHWID

const TileHWID* TileLaserTimingTool::m_tileHWID {nullptr}
private

Definition at line 257 of file TileLaserTimingTool.h.

257{nullptr};

◆ m_tileToolTiming

ToolHandle<TileCondToolTiming> TileLaserTimingTool::m_tileToolTiming
private
Initial value:
{this,
"TileCondToolTiming", "TileCondToolTiming", "Tile timing tool"}

Definition at line 259 of file TileLaserTimingTool.h.

259 {this,
260 "TileCondToolTiming", "TileCondToolTiming", "Tile timing tool"};

◆ m_TimeDiffMean

float(* TileLaserTimingTool::m_TimeDiffMean)[NDRAWERS][NCHANNELS]
private

Definition at line 194 of file TileLaserTimingTool.h.

◆ m_TimeDiffMeanError

float(* TileLaserTimingTool::m_TimeDiffMeanError)[NDRAWERS][NCHANNELS]
private

Definition at line 195 of file TileLaserTimingTool.h.

◆ m_TimeDiffPMTDigi0

float(* TileLaserTimingTool::m_TimeDiffPMTDigi0)[NDRAWERS][NCHANNELS]
private

Definition at line 223 of file TileLaserTimingTool.h.

◆ m_TimeDiffSigma

float(* TileLaserTimingTool::m_TimeDiffSigma)[NDRAWERS][NCHANNELS]
private

Definition at line 196 of file TileLaserTimingTool.h.

◆ m_useMeanChannelOffset

Gaudi::Property<bool> TileLaserTimingTool::m_useMeanChannelOffset {this, "UseMeanChannelOffset", true}
private

Definition at line 272 of file TileLaserTimingTool.h.

272{this, "UseMeanChannelOffset", true};

◆ m_usePMT0AsDskewRef

Gaudi::Property<bool> TileLaserTimingTool::m_usePMT0AsDskewRef {this, "UsePMT0AsDskewRef", true}
private

Definition at line 276 of file TileLaserTimingTool.h.

276{this, "UsePMT0AsDskewRef", true};

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 387 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 386 of file AthCommonDataStore.h.

◆ NROS

const int TileLaserTimingTool::NROS = 5
staticprivate

Definition at line 176 of file TileLaserTimingTool.h.

◆ s_fiberLength

float const TileLaserTimingTool::s_fiberLength
staticprivate
Initial value:
= {{167.1,167.1,178.7,178.7,190.3,190.3,201.9,201.9,213.5,213.5,
225.1,225.1,236.7,236.7,248.3,248.3,259.9,259.9,271.5,271.5,
283.1,283.1,294.7,294.7,201.9,201.9,213.5,213.5,225.1,225.1,
236.7,236.7,248.3,248.3,259.9,259.9,271.5,271.5,283.1,283.1,
294.7,294.7,306.3,306.3,317.9,317.9,329.6,329.6},
{ 51.1, 51.1, 62.7, 62.7, 74.3, 74.3, 85.9, 85.9, 97.5, 97.5,
109.1,109.1,120.7,120.7,132.3,132.3,143.9,143.9,143.9,143.9,
167.1,167.1,178.1,178.1,178.1,178.1,178.1,178.1,213.5,213.5,
213.5,213.5,236.7,236.7,236.7,236.7,259.9,259.9,259.9,259.9,
283.1,283.1,294.7,294.7,294.7,294.7,294.7,294.7}}

Definition at line 110 of file TileLaserTimingTool.h.


The documentation for this class was generated from the following files: