ATLAS Offline Software
MuonSegmentSelectionTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MUON_MUONSEGMENTSELECTIONTOOL_H
6 #define MUON_MUONSEGMENTSELECTIONTOOL_H
7 
9 #include "GaudiKernel/ServiceHandle.h"
10 #include "GaudiKernel/ToolHandle.h"
15 
16 namespace Muon {
17 class MuonSegment;
18 }
19 
20 namespace Muon {
21 
22 
34  public:
35  MuonSegmentSelectionTool(const std::string&, const std::string&, const IInterface*);
36 
37  virtual ~MuonSegmentSelectionTool() = default;
38 
40 
42  bool select(const MuonSegment& seg, bool ignoreHoles = false, int qualityLevel = 0, bool useEta = true,
43  bool usePhi = true) const;
44 
46  int quality(const MuonSegment& seg, bool ignoreHoles = false, bool useEta = true, bool usePhi = true) const;
47 
48  private:
50  int mdtSegmentQuality(const MuonSegment& seg, bool ignoreHoles) const;
51 
52 
54  int cscSegmentQuality(const MuonSegment& seg, bool useEta, bool usePhi) const;
55 
57  int nswSegmentQuality(const MuonSegment& seg, const Identifier& chid, bool ignoreHoles) const;
58 
60  "Muon::MuonIdHelperSvc/MuonIdHelperSvc"};
62  this, "edmHelper", "Muon::MuonEDMHelperSvc/MuonEDMHelperSvc",
63  "Handle to the service providing the IMuonEDMHelperSvc interface"};
64 
65  PublicToolHandle<MuonEDMPrinterTool> m_printer{
66  this,
67  "Printer",
68  "Muon::MuonEDMPrinterTool/MuonEDMPrinterTool",
69  };
70 
71  PublicToolHandle<IMuonSegmentHitSummaryTool> m_hitSummaryTool{
72  this,
73  "MuonSegmentHitSummaryTool",
74  "Muon::MuonSegmentHitSummaryTool/MuonSegmentHitSummaryTool",
75  };
76 
77  Gaudi::Property<double> m_cutSegmentQuality{this, "SegmentQualityCut", 10.};
78  Gaudi::Property<double> m_adcFractionCut{this, "GoodADCFractionCut",-1};
79  Gaudi::Property<int> m_minAdcPerSegmentCut{this,"MinADCPerSegmentCut",70 };
80 };
81 
82 } // namespace Muon
83 
84 #endif
Muon::MuonSegmentSelectionTool::m_printer
PublicToolHandle< MuonEDMPrinterTool > m_printer
EDM printer tool.
Definition: MuonSegmentSelectionTool.h:65
Muon::MuonSegmentSelectionTool::m_adcFractionCut
Gaudi::Property< double > m_adcFractionCut
cut on fraction of MDT hits above ADC cut
Definition: MuonSegmentSelectionTool.h:78
Muon::MuonSegmentSelectionTool::m_minAdcPerSegmentCut
Gaudi::Property< int > m_minAdcPerSegmentCut
minimum value for the MDT with the highest ADC value on the segment
Definition: MuonSegmentSelectionTool.h:79
MuonEDMPrinterTool.h
Muon::MuonSegmentSelectionTool::m_edmHelperSvc
ServiceHandle< IMuonEDMHelperSvc > m_edmHelperSvc
EDM Helper tool.
Definition: MuonSegmentSelectionTool.h:61
Muon::MuonSegmentSelectionTool::quality
int quality(const MuonSegment &seg, bool ignoreHoles=false, bool useEta=true, bool usePhi=true) const
segment quality
Definition: MuonSegmentSelectionTool.cxx:32
Muon
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition: TrackSystemController.h:45
xAOD::MuonSegment
MuonSegment_v1 MuonSegment
Reference the current persistent version:
Definition: Event/xAOD/xAODMuon/xAODMuon/MuonSegment.h:13
Muon::MuonSegmentSelectionTool::nswSegmentQuality
int nswSegmentQuality(const MuonSegment &seg, const Identifier &chid, bool ignoreHoles) const
calculate segment quality for NSW segments
Definition: MuonSegmentSelectionTool.cxx:98
IMuonSegmentSelectionTool.h
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
Muon::MuonSegmentSelectionTool::initialize
StatusCode initialize()
Definition: MuonSegmentSelectionTool.cxx:22
Muon::MuonSegmentSelectionTool::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonSegmentSelectionTool.h:59
Muon::MuonSegmentSelectionTool::cscSegmentQuality
int cscSegmentQuality(const MuonSegment &seg, bool useEta, bool usePhi) const
calculate segment quality for CSC segments
Definition: MuonSegmentSelectionTool.cxx:55
Muon::MuonSegmentSelectionTool
tool to select MDT segments, all CSC segments will be kept Quality levels: Level 0 = remove segments ...
Definition: MuonSegmentSelectionTool.h:33
Muon::IMuonSegmentSelectionTool
tool to select segments
Definition: IMuonSegmentSelectionTool.h:18
Muon::MuonSegmentSelectionTool::m_cutSegmentQuality
Gaudi::Property< double > m_cutSegmentQuality
cut on the segment quality
Definition: MuonSegmentSelectionTool.h:77
IMuonEDMHelperSvc.h
Muon::MuonSegmentSelectionTool::select
bool select(const MuonSegment &seg, bool ignoreHoles=false, int qualityLevel=0, bool useEta=true, bool usePhi=true) const
select segment
Definition: MuonSegmentSelectionTool.cxx:260
Muon::MuonSegmentSelectionTool::~MuonSegmentSelectionTool
virtual ~MuonSegmentSelectionTool()=default
Muon::MuonSegmentSelectionTool::MuonSegmentSelectionTool
MuonSegmentSelectionTool(const std::string &, const std::string &, const IInterface *)
Definition: MuonSegmentSelectionTool.cxx:16
Muon::MuonSegment
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:45
AthAlgTool
Definition: AthAlgTool.h:26
IMuonSegmentHitSummaryTool.h
Muon::MuonSegmentSelectionTool::m_hitSummaryTool
PublicToolHandle< IMuonSegmentHitSummaryTool > m_hitSummaryTool
hit summary tool
Definition: MuonSegmentSelectionTool.h:71
Muon::MuonSegmentSelectionTool::mdtSegmentQuality
int mdtSegmentQuality(const MuonSegment &seg, bool ignoreHoles) const
calculate segment quality for MDT segments
Definition: MuonSegmentSelectionTool.cxx:141
ServiceHandle< Muon::IMuonIdHelperSvc >
Identifier
Definition: IdentifierFieldParser.cxx:14