ATLAS Offline Software
Loading...
Searching...
No Matches
IMdtCalibrationTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef MDTCALIBSVC_IMDTCALIBRATIONTOOL_H
6#define MDTCALIBSVC_IMDTCALIBRATIONTOOL_H
7
8#include <bitset>
9#include <GaudiKernel/IAlgTool.h>
10#include <GaudiKernel/EventContext.h>
14
15
16namespace MuonCalib{
17 struct MdtFullCalibData;
18}
19
26
27class IMdtCalibrationTool : virtual public IAlgTool {
28public:
29
37
38 static constexpr double tdcBinSize = 0.78125; //25/32; exact number: (1000.0/40.079)/32.0
39
41 virtual ~IMdtCalibrationTool() = default;
42
45
73 virtual MdtCalibOutput calibrate(const EventContext& ctx,
74 const MdtCalibInput& hit,
75 bool resolFromRtrack=false) const = 0;
76
79 virtual MdtCalibTwinOutput calibrateTwinTubes(const EventContext& ctx,
80 MdtCalibInput&& primHit,
81 MdtCalibInput&& twinHit) const = 0;
82
83
84 virtual const MuonCalib::MdtFullCalibData* getCalibConstants(const EventContext& ctx,
85 const Identifier& channelId) const = 0;
86 virtual double getResolutionFromRt(const EventContext& ctx,
87 const Identifier& module,
88 const double time) const = 0;
89
90 struct ToolSettings {
100
101 void setBit(const Property prop, const bool value){
102 m_mask.set(static_cast<unsigned int>(prop), value);
103 }
104 bool isActive(const Property prop) const {
105 return m_mask.test(static_cast<unsigned int>(prop));
106 }
108 private:
109 using bitmask = std::bitset<static_cast<unsigned>(Property::NumSettings)>;
111
112 };
113 virtual ToolSettings getSettings() const = 0;
114
115};
116
117#endif
the Mdt Calib Service provides, on request, the drift radius and its error, computed applying the pro...
virtual ~IMdtCalibrationTool()=default
destructor
virtual ToolSettings getSettings() const =0
static constexpr double tdcBinSize
Conversion to go from tdc counts -> drift Time.
virtual MdtCalibTwinOutput calibrateTwinTubes(const EventContext &ctx, MdtCalibInput &&primHit, MdtCalibInput &&twinHit) const =0
Convert the raw MDT times of two twin hits into a Twin position (coordinate along tube) It returns wh...
virtual double getResolutionFromRt(const EventContext &ctx, const Identifier &module, const double time) const =0
@ Default
User can configure the window.
virtual const MuonCalib::MdtFullCalibData * getCalibConstants(const EventContext &ctx, const Identifier &channelId) const =0
virtual MdtCalibOutput calibrate(const EventContext &ctx, const MdtCalibInput &hit, bool resolFromRtrack=false) const =0
Convert the raw MDT time (+charge) into a drift radius + error.
DeclareInterfaceID(IMdtCalibrationTool, 1, 0)
implements IInterface
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.
bool isActive(const Property prop) const
void setBit(const Property prop, const bool value)
std::bitset< static_cast< unsigned >(Property::NumSettings)> bitmask
class which holds the full set of calibration constants for a given tube