ATLAS Offline Software
GlobalTimeFitter.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 MUONCALIB_GLOBALTIMEFITTER_H
6 #define MUONCALIB_GLOBALTIMEFITTER_H
7 
8 #include <iostream>
9 #include <memory>
10 
15 
16 namespace MuonCalib {
17 
24  public:
27  ~GlobalTimeFitter() = default;
28 
29  double GTFit(MuonCalibSegment *seg);
30  double GTFit2(MuonCalibSegment *seg);
31 
32  static std::unique_ptr<IRtRelation> getDefaultRtRelation();
33 
34  void setRtRelation(const IRtRelation *rtRel) { m_rtRel = rtRel; };
35 
36  double getDefaultResolution(double r) {
37  double resolH8 = 0.164 * std::exp(-r / 4.43) + 0.043; // resolution from H8 TestBeam
38  return 2. * resolH8; // resolution from Cosmics in the pit
39  // return 2.0 ; // FLAT 2 mm resolution
40  };
41  bool fit(MuonCalibSegment &seg) const { return m_fitter->fit(seg); }
43  return m_fitter->fit(seg, selection);
44  }
45 
46  private:
47  const IMdtSegmentFitter *m_fitter{nullptr};
48  const IRtRelation *m_rtRel{nullptr};
49  };
50 
51 } // namespace MuonCalib
52 
53 #endif
MuonCalib::IMdtSegmentFitter::fit
virtual bool fit(MuonCalibSegment &seg) const =0
fit using all hits
beamspotman.r
def r
Definition: beamspotman.py:676
LArSamples::FitterData::fitter
const ShapeFitter * fitter
Definition: ShapeFitter.cxx:23
MuonCalib::GlobalTimeFitter::fit
bool fit(MuonCalibSegment &seg) const
Definition: GlobalTimeFitter.h:41
MuonCalib::GlobalTimeFitter::GTFit2
double GTFit2(MuonCalibSegment *seg)
Definition: GlobalTimeFitter.cxx:119
MuonCalibSegment.h
IMdtSegmentFitter.h
MuonCalib::MuonCalibSegment
Definition: MuonCalibSegment.h:39
MuonCalib::IMdtSegmentFitter
Definition: IMdtSegmentFitter.h:30
drawFromPickle.exp
exp
Definition: drawFromPickle.py:36
MuonCalib::GlobalTimeFitter::GlobalTimeFitter
GlobalTimeFitter(const IMdtSegmentFitter *fitter, const IRtRelation *rtRel)
Definition: GlobalTimeFitter.h:26
MuonCalib::GlobalTimeFitter::~GlobalTimeFitter
~GlobalTimeFitter()=default
MuonCalib::GlobalTimeFitter::getDefaultResolution
double getDefaultResolution(double r)
Definition: GlobalTimeFitter.h:36
MuonCalib::GlobalTimeFitter::m_fitter
const IMdtSegmentFitter * m_fitter
Definition: GlobalTimeFitter.h:47
MuonCalib
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.
Definition: CscCalcPed.cxx:22
MuonCalib::GlobalTimeFitter::GTFit
double GTFit(MuonCalibSegment *seg)
Definition: GlobalTimeFitter.cxx:18
MuonCalib::GlobalTimeFitter::setRtRelation
void setRtRelation(const IRtRelation *rtRel)
Definition: GlobalTimeFitter.h:34
selection
std::string selection
Definition: fbtTestBasics.cxx:75
MuonCalib::GlobalTimeFitter::fit
bool fit(MuonCalibSegment &seg, const MuonCalib::IMdtSegmentFitter::HitSelection &selection) const
Definition: GlobalTimeFitter.h:42
MdtCalibHit.h
MuonCalib::GlobalTimeFitter::m_rtRel
const IRtRelation * m_rtRel
Definition: GlobalTimeFitter.h:48
IRtRelation.h
MuonCalib::GlobalTimeFitter::getDefaultRtRelation
static std::unique_ptr< IRtRelation > getDefaultRtRelation()
Definition: GlobalTimeFitter.cxx:134
MuonCalib::GlobalTimeFitter::GlobalTimeFitter
GlobalTimeFitter(const IMdtSegmentFitter *fitter)
Definition: GlobalTimeFitter.h:25
MuonCalib::IRtRelation
generic interface for a rt-relation
Definition: IRtRelation.h:15
MuonCalib::GlobalTimeFitter
Definition: GlobalTimeFitter.h:23
MuonCalib::IMdtSegmentFitter::HitSelection
std::vector< unsigned int > HitSelection
Definition: IMdtSegmentFitter.h:32