ATLAS Offline Software
Loading...
Searching...
No Matches
MdtCalibrationTool.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef MDTCALIBSVC_MDTCALIBRATIONTOOL_H
6#define MDTCALIBSVC_MDTCALIBRATIONTOOL_H
7
8
10
12
17#include "GaudiKernel/SystemOfUnits.h"
18#include "GaudiKernel/PhysicalConstants.h"
19class MdtCalibHit;
20class MdtCalibToolInput;
21
22namespace MuonCalib {
23 class MdtRtRelation;
24}
25
32
33
34
35class MdtCalibrationTool : public extends<AthAlgTool, IMdtCalibrationTool> {
36public:
37
38
42
43
45 using base_class::base_class;
47 virtual ~MdtCalibrationTool() = default;
48
50 virtual StatusCode initialize() override final;
51
79 virtual MdtCalibOutput calibrate(const EventContext& ctx,
81 bool resolFromRtrack=false) const override final;
82
85 virtual MdtCalibTwinOutput calibrateTwinTubes(const EventContext& ctx,
86 MdtCalibInput&& hit,
87 MdtCalibInput&& twinHit) const override final;
88
89 virtual double getResolutionFromRt(const EventContext& ctx,
90 const Identifier& module,
91 const double time) const override final;
92
93 virtual ToolSettings getSettings() const override final;
94
95 virtual const MuonCalib::MdtFullCalibData*
96 getCalibConstants(const EventContext& ctx,
97 const Identifier& channelId) const override final;
99 Muon::MdtDriftCircleStatus driftTimeStatus(double driftTime,
100 const MuonCalib::MdtRtRelation& rtRelation) const;
101
102 Gaudi::Property<int> m_windowSetting{this, "TimeWindowSetting", timeWindowMode::Default};
103 Gaudi::Property<double> m_timeWindowLowerBound{this, "TimeWindowLowerBound", 0.};
104 Gaudi::Property<double> m_timeWindowUpperBound{this, "TimeWindowUpperBound", 0.};
105 Gaudi::Property<bool> m_doTof{this, "DoTofCorrection", true};
106 Gaudi::Property<bool> m_doProp{this, "DoPropagationCorrection", true};
107 Gaudi::Property<bool> m_doTemp{this, "DoTemperatureCorrection", false};
108 Gaudi::Property<bool> m_doField{this,"DoMagneticFieldCorrection", false};
109 Gaudi::Property<bool> m_doSlew{this, "DoSlewingCorrection", false};
110 Gaudi::Property<bool> m_doBkg{this, "DoBackgroundCorrection", false};
111 Gaudi::Property<bool> m_doPropUncert{this, "DoPropagationTimeUncert", false};
112 /* T0 Shift tool -- Per-tube offsets of t0 value */
113 ToolHandle<MuonCalib::IShiftMapTools> m_t0ShiftTool{this, "T0ShiftTool", ""};
114 /* TMax Shift tool -- Per-tube offsets of Tmax */
115 ToolHandle<MuonCalib::IShiftMapTools> m_tMaxShiftTool{this, "TShiftMaxTool", ""};
116
117 // tools should only be retrieved if they are used
118 Gaudi::Property<bool> m_doT0Shift{this, "DoT0Shift", false};
119 Gaudi::Property<bool> m_doTMaxShift{this, "DoTMaxShift", false};
120
121 Gaudi::Property<double> m_unphysicalHitRadiusLowerBound{this, "LowerBoundHitRadius" , 0.};
122 Gaudi::Property<double> m_resTwin{this, "ResolutionTwinTube" , 1.05, "Twin tube resolution"};
123
124
126 "Conditions object containing the calibrations"};
127
128 // Read handle for conditions object to get the field cache
129 // If one wants to avoid that adding of this read handle here, then client tools/algs calling driftRadiusFromTime
130 // must implement this to get the AtlasFieldCache which can then be passed through the call to driftRadiusFromTime
131 // Note: a readhandle must be in a tool or an alg, and so it cannot be in the class Imp.)
132 SG::ReadCondHandleKey<AtlasFieldCacheCondObj> m_fieldCacheCondObjInputKey {this, "AtlasFieldCacheCondObj", "fieldCondObj",
133 "Name of the Magnetic Field conditions object key"};
134 ServiceHandle<Muon::IMuonIdHelperSvc> m_idHelperSvc {this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"};
135
136};
137
138#endif
MdtCalibOutput::MdtDriftCircleStatus MdtDriftCircleStatus
MdtCalibrationTool::ToolSettings ToolSettings
An MdtCalibHit is an object containing all the intermediate information needed in the conversion of r...
Definition MdtCalibHit.h:50
the Mdt Calib Service provides, on request, the drift radius and its error, computed applying the pro...
ToolHandle< MuonCalib::IShiftMapTools > m_tMaxShiftTool
Gaudi::Property< bool > m_doPropUncert
Gaudi::Property< bool > m_doSlew
Gaudi::Property< double > m_timeWindowLowerBound
Gaudi::Property< bool > m_doTMaxShift
Gaudi::Property< int > m_windowSetting
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Gaudi::Property< bool > m_doProp
SG::ReadCondHandleKey< MuonCalib::MdtCalibDataContainer > m_calibDbKey
Gaudi::Property< double > m_unphysicalHitRadiusLowerBound
Muon::MdtDriftCircleStatus driftTimeStatus(double driftTime, const MuonCalib::MdtRtRelation &rtRelation) const
virtual double getResolutionFromRt(const EventContext &ctx, const Identifier &module, const double time) const override final
Gaudi::Property< double > m_timeWindowUpperBound
ToolHandle< MuonCalib::IShiftMapTools > m_t0ShiftTool
Gaudi::Property< bool > m_doBkg
virtual const MuonCalib::MdtFullCalibData * getCalibConstants(const EventContext &ctx, const Identifier &channelId) const override final
Gaudi::Property< bool > m_doT0Shift
virtual MdtCalibOutput calibrate(const EventContext &ctx, const MdtCalibInput &hit, bool resolFromRtrack=false) const override final
Convert the raw MDT time (+charge) into a drift radius + error.
virtual ToolSettings getSettings() const override final
Gaudi::Property< double > m_resTwin
Gaudi::Property< bool > m_doTemp
MuonCalib::MdtFullCalibData::TubeContainerPtr TubeContainerPtr
MuonCalib::MdtFullCalibData::RtRelationPtr RtRelationPtr
virtual MdtCalibTwinOutput calibrateTwinTubes(const EventContext &ctx, MdtCalibInput &&hit, MdtCalibInput &&twinHit) const override final
Convert the raw MDT times of two twin hits into a Twin position (coordinate along tube) It returns wh...
virtual StatusCode initialize() override final
initialization
Gaudi::Property< bool > m_doField
MuonCalib::MdtFullCalibData::CorrectionPtr CorrectionPtr
virtual ~MdtCalibrationTool()=default
destructor
Gaudi::Property< bool > m_doTof
SG::ReadCondHandleKey< AtlasFieldCacheCondObj > m_fieldCacheCondObjInputKey
class which holds calibration constants per rt-region
Support class for PropertyMgr.
Definition Property.h:23
=============================================================================
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
GeoModel::TransientConstSharedPtr< MdtTubeCalibContainer > TubeContainerPtr
GeoModel::TransientConstSharedPtr< MdtCorFuncSet > CorrectionPtr
GeoModel::TransientConstSharedPtr< MdtRtRelation > RtRelationPtr
#define private