ATLAS Offline Software
MuonSeededSegmentFinder.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MUON_MUONSEEDEDSEGMENTFINDER_H
6 #define MUON_MUONSEEDEDSEGMENTFINDER_H
7 
8 #include <set>
9 
23 
24 namespace Muon {
25 
30  class MuonSeededSegmentFinder : public extends<AthAlgTool, IMuonSeededSegmentFinder> {
31  public:
33  MuonSeededSegmentFinder(const std::string&, const std::string&, const IInterface*);
34 
37 
40 
42  std::unique_ptr<Trk::SegmentCollection> find(const EventContext& ctx, const Trk::TrackParameters& pars,
43  const std::set<Identifier>& chIds) const;
44 
46  std::unique_ptr<Trk::SegmentCollection> find(const EventContext& ctx, const Trk::TrackParameters& pars,
47  const std::set<IdentifierHash>& chIdHs) const;
48 
50  std::unique_ptr<Trk::SegmentCollection> find(const EventContext& ctx, const Trk::TrackParameters& pars,
51  const std::vector<const MdtPrepData*>& mdtPrds) const;
52 
54  void extractMdtPrdCols(const EventContext& ctx, const std::set<IdentifierHash>& chIdHs,
55  std::vector<const MdtPrepDataCollection*>& target) const;
56 
58  void extractRpcPrdCols(const EventContext& ctx, const std::set<IdentifierHash>& chIdHs,
59  std::vector<const RpcPrepDataCollection*>& target) const;
60 
62  void extractTgcPrdCols(const EventContext& ctx, const std::set<IdentifierHash>& chIdHs,
63  std::vector<const TgcPrepDataCollection*>& target) const;
64 
66  void extractCscPrdCols(const std::set<IdentifierHash>& chIdHs, std::vector<const CscPrepDataCollection*>& target) const;
67 
68  // New Small Wheel
69 
71  void extractsTgcPrdCols(const EventContext& ctx, const std::set<IdentifierHash>& chIdHs,
72  std::vector<const sTgcPrepDataCollection*>& target) const;
73 
75  void extractMMPrdCols(const std::set<IdentifierHash>& chIdHs, std::vector<const MMPrepDataCollection*>& target) const;
76 
77  private:
79  std::vector<const MdtPrepData*> extractPrds(const EventContext& ctx, const std::set<Identifier>& chIds) const;
80 
82  std::vector<const MdtPrepData*> extractPrds(const EventContext& ctx, const std::set<IdentifierHash>& chIdHs) const;
83 
85  void selectAndCalibrate(const EventContext& ctx, const Trk::TrackParameters& pars,
86  const std::vector<const MdtPrepData*>& mdtPrdCols, std::vector<const MdtDriftCircleOnTrack*>& mdtROTs,
87  bool& doHoleSearch) const;
88 
90  const MdtDriftCircleOnTrack* handleMdtPrd(const EventContext& ctx, const Trk::TrackParameters& pars, const MdtPrepData& mdtPrd,
91  bool& doHoleSearch) const;
92 
93  SG::ReadCondHandleKey<MuonGM::MuonDetectorManager> m_DetectorManagerKey{this, "DetectorManagerKey", "MuonDetectorManager",
94  "Key of input MuonDetectorManager condition data"};
95 
96  ToolHandle<Muon::IMuonSegmentMaker> m_segMaker{
97  this, "SegmentMaker", "Muon::DCMathSegmentMaker/DCMathSegmentMaker"};
98  ToolHandle<Muon::IMuonSegmentMaker> m_segMakerNoHoles{
99  this, "SegmentMakerNoHoles", "Muon::DCMathSegmentMaker/DCMathSegmentMaker"};
100  ToolHandle<Trk::IPropagator> m_propagator{this, "Propagator",
101  "Trk::RungeKuttaPropagator/AtlasRungeKuttaPropagator"};
102  ToolHandle<Muon::IMdtDriftCircleOnTrackCreator> m_mdtRotCreator{
103  this, "MdtRotCreator", "Muon::MdtDriftCircleOnTrackCreator/MdtDriftCircleOnTrackCreator"};
105  ServiceHandle<Muon::IMuonIdHelperSvc> m_idHelperSvc{this, "MuonIdHelperSvc", "Muon::MuonIdHelperSvc/MuonIdHelperSvc"};
106  PublicToolHandle<Muon::MuonEDMPrinterTool> m_printer{this, "Printer",
107  "Muon::MuonEDMPrinterTool/MuonEDMPrinterTool"};
108 
109  SG::ReadHandleKey<Muon::MdtPrepDataContainer> m_key_mdt{this, "MdtPrepDataContainer", "MDT_DriftCircles", "MDT PRDs"};
110  SG::ReadHandleKey<Muon::CscPrepDataContainer> m_key_csc{this, "CscPrepDataContainer", "CSC_Clusters", "CSC PRDS"};
111  SG::ReadHandleKey<Muon::TgcPrepDataContainer> m_key_tgc{this, "TgcPrepDataContainer", "TGC_Measurements", "TGC PRDs"};
112  SG::ReadHandleKey<Muon::RpcPrepDataContainer> m_key_rpc{this, "RpcPrepDataContainer", "RPC_Measurements", "RPC PRDs"};
113  SG::ReadHandleKey<Muon::sTgcPrepDataContainer> m_key_stgc{this, "sTgcPrepDataContainer", "STGC_Measurements", "sTGC PRDs"};
114  SG::ReadHandleKey<Muon::MMPrepDataContainer> m_key_mm{this, "MMPrepDataContainer", "MM_Measurements", "MM PRDs"};
115 
116  Gaudi::Property<double> m_adcCut{this, "AdcCut", 50};
117  Gaudi::Property<double> m_maxSigma{this, "MdtSigmaFromTrack", 3};
118  };
119 
120 } // namespace Muon
121 
122 #endif
Muon::MuonSeededSegmentFinder::find
std::unique_ptr< Trk::SegmentCollection > find(const EventContext &ctx, const Trk::TrackParameters &pars, const std::set< Identifier > &chIds) const
find segments in a set of chambers starting from seeding TrackParameters
Definition: MuonSeededSegmentFinder.cxx:49
make_hlt_rep.pars
pars
Definition: make_hlt_rep.py:90
Muon::MuonSeededSegmentFinder::m_key_csc
SG::ReadHandleKey< Muon::CscPrepDataContainer > m_key_csc
Definition: MuonSeededSegmentFinder.h:110
Muon::MuonSeededSegmentFinder::m_propagator
ToolHandle< Trk::IPropagator > m_propagator
propagator
Definition: MuonSeededSegmentFinder.h:100
Muon::MuonSeededSegmentFinder::m_key_stgc
SG::ReadHandleKey< Muon::sTgcPrepDataContainer > m_key_stgc
Definition: MuonSeededSegmentFinder.h:113
Muon::MuonSeededSegmentFinder::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonSeededSegmentFinder.h:105
TrackParameters.h
Trk::MagneticFieldProperties
Definition: MagneticFieldProperties.h:31
Muon::MuonSeededSegmentFinder::extractsTgcPrdCols
void extractsTgcPrdCols(const EventContext &ctx, const std::set< IdentifierHash > &chIdHs, std::vector< const sTgcPrepDataCollection * > &target) const
retrieve STGC PRD collections for the given hashes
Definition: MuonSeededSegmentFinder.cxx:274
Muon::MuonSeededSegmentFinder::m_printer
PublicToolHandle< Muon::MuonEDMPrinterTool > m_printer
EDM printer tool.
Definition: MuonSeededSegmentFinder.h:106
Muon::MuonSeededSegmentFinder
seeded segment finder that gets its data directly from storegate for a give set of Identifiers or Ide...
Definition: MuonSeededSegmentFinder.h:30
MuonEDMPrinterTool.h
Muon::MuonSeededSegmentFinder::m_mdtRotCreator
ToolHandle< Muon::IMdtDriftCircleOnTrackCreator > m_mdtRotCreator
IMdtDriftCircleOnTrackCreator.
Definition: MuonSeededSegmentFinder.h:102
Muon::MuonSeededSegmentFinder::extractPrds
std::vector< const MdtPrepData * > extractPrds(const EventContext &ctx, const std::set< Identifier > &chIds) const
retrieve the MdtPrepDataCollections for the give Identifiers
Definition: MuonSeededSegmentFinder.cxx:124
Muon::MuonSeededSegmentFinder::handleMdtPrd
const MdtDriftCircleOnTrack * handleMdtPrd(const EventContext &ctx, const Trk::TrackParameters &pars, const MdtPrepData &mdtPrd, bool &doHoleSearch) const
select and calibrate a single MdtPrepData
Definition: MuonSeededSegmentFinder.cxx:357
IPropagator.h
Muon::MuonSeededSegmentFinder::m_DetectorManagerKey
SG::ReadCondHandleKey< MuonGM::MuonDetectorManager > m_DetectorManagerKey
Definition: MuonSeededSegmentFinder.h:93
MuonPrepDataContainer.h
SG::ReadHandleKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Definition: StoreGate/StoreGate/ReadHandleKey.h:39
Muon
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition: TrackSystemController.h:45
MagneticFieldProperties.h
IMuonSeededSegmentFinder.h
Muon::MuonSeededSegmentFinder::initialize
StatusCode initialize()
AlgTool initilize.
Definition: MuonSeededSegmentFinder.cxx:26
MdtPrepDataCollection.h
Muon::MuonSeededSegmentFinder::m_key_tgc
SG::ReadHandleKey< Muon::TgcPrepDataContainer > m_key_tgc
Definition: MuonSeededSegmentFinder.h:111
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
Muon::MuonSeededSegmentFinder::extractMdtPrdCols
void extractMdtPrdCols(const EventContext &ctx, const std::set< IdentifierHash > &chIdHs, std::vector< const MdtPrepDataCollection * > &target) const
retrieve MDT PRD collections for the given hashes
Definition: MuonSeededSegmentFinder.cxx:186
AthAlgTool.h
Muon::MuonSeededSegmentFinder::m_maxSigma
Gaudi::Property< double > m_maxSigma
Definition: MuonSeededSegmentFinder.h:117
Muon::MuonSeededSegmentFinder::MuonSeededSegmentFinder
MuonSeededSegmentFinder(const std::string &, const std::string &, const IInterface *)
constructor
Definition: MuonSeededSegmentFinder.cxx:23
Muon::MuonSeededSegmentFinder::m_adcCut
Gaudi::Property< double > m_adcCut
Definition: MuonSeededSegmentFinder.h:116
Muon::MuonSeededSegmentFinder::extractRpcPrdCols
void extractRpcPrdCols(const EventContext &ctx, const std::set< IdentifierHash > &chIdHs, std::vector< const RpcPrepDataCollection * > &target) const
retrieve RPC PRD collections for the given hashes
Definition: MuonSeededSegmentFinder.cxx:207
Trk::ParametersBase
Definition: ParametersBase.h:55
Muon::MuonSeededSegmentFinder::m_key_mdt
SG::ReadHandleKey< Muon::MdtPrepDataContainer > m_key_mdt
Definition: MuonSeededSegmentFinder.h:109
Muon::MuonSeededSegmentFinder::m_segMaker
ToolHandle< Muon::IMuonSegmentMaker > m_segMaker
actual segment maker with hole search
Definition: MuonSeededSegmentFinder.h:96
IMdtDriftCircleOnTrackCreator.h
Muon::MdtDriftCircleOnTrack
This class represents the corrected MDT measurements, where the corrections include the effects of wi...
Definition: MdtDriftCircleOnTrack.h:37
Muon::MuonSeededSegmentFinder::extractMMPrdCols
void extractMMPrdCols(const std::set< IdentifierHash > &chIdHs, std::vector< const MMPrepDataCollection * > &target) const
retrieve MM PRD collections for the given hashes
Definition: MuonSeededSegmentFinder.cxx:306
Muon::MdtPrepData
Class to represent measurements from the Monitored Drift Tubes.
Definition: MdtPrepData.h:33
MuonDetectorManager.h
Muon::MuonSeededSegmentFinder::~MuonSeededSegmentFinder
~MuonSeededSegmentFinder()=default
destructor
Muon::MuonSeededSegmentFinder::m_key_mm
SG::ReadHandleKey< Muon::MMPrepDataContainer > m_key_mm
Definition: MuonSeededSegmentFinder.h:114
SG::ReadCondHandleKey< MuonGM::MuonDetectorManager >
Muon::MuonSeededSegmentFinder::selectAndCalibrate
void selectAndCalibrate(const EventContext &ctx, const Trk::TrackParameters &pars, const std::vector< const MdtPrepData * > &mdtPrdCols, std::vector< const MdtDriftCircleOnTrack * > &mdtROTs, bool &doHoleSearch) const
select a set of Mdt hits and calibrate them
Definition: MuonSeededSegmentFinder.cxx:336
copySelective.target
string target
Definition: copySelective.py:37
MagneticFieldMode.h
Muon::MuonSeededSegmentFinder::m_key_rpc
SG::ReadHandleKey< Muon::RpcPrepDataContainer > m_key_rpc
Definition: MuonSeededSegmentFinder.h:112
Muon::MuonSeededSegmentFinder::extractCscPrdCols
void extractCscPrdCols(const std::set< IdentifierHash > &chIdHs, std::vector< const CscPrepDataCollection * > &target) const
retrieve CSC PRD collections for the given hashes
Definition: MuonSeededSegmentFinder.cxx:247
Muon::MuonSeededSegmentFinder::extractTgcPrdCols
void extractTgcPrdCols(const EventContext &ctx, const std::set< IdentifierHash > &chIdHs, std::vector< const TgcPrepDataCollection * > &target) const
retrieve TGC PRD collections for the given hashes
Definition: MuonSeededSegmentFinder.cxx:227
IMuonIdHelperSvc.h
IMuonSegmentMaker.h
Muon::MuonSeededSegmentFinder::m_magFieldProperties
Trk::MagneticFieldProperties m_magFieldProperties
magnetic field properties
Definition: MuonSeededSegmentFinder.h:104
Muon::MuonSeededSegmentFinder::m_segMakerNoHoles
ToolHandle< Muon::IMuonSegmentMaker > m_segMakerNoHoles
actual segment maker no hole search
Definition: MuonSeededSegmentFinder.h:98
ServiceHandle< Muon::IMuonIdHelperSvc >