ATLAS Offline Software
MsTrackSeeder.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 #ifndef MUONTRACKFINDINGTOOLS_MSTRACKSEEDER_H
5 #define MUONTRACKFINDINGTOOLS_MSTRACKSEEDER_H
6 
8 
9 #include "GaudiKernel/SystemOfUnits.h"
10 #include "Acts/Utilities/KDTree.hpp"
14 
15 
16 namespace MuonR4{
25  class MsTrackSeeder: public AthMessaging {
26  public:
27 
28  struct Config{
44  };
46  using SearchTree_t = Acts::KDTree<3, const xAOD::MuonSegment*, double, std::array, 6>;
50  enum SeedCoords{
57  };
58 
62  MsTrackSeeder(const std::string& msgName, Config&& cfg);
70  const Location loc) const;
71 
75  bool withinBounds(const Amg::Vector2D& projPos,
76  const Location loc) const;
80  std::unique_ptr<MsTrackSeedContainer> findTrackSeeds(const EventContext& ctx,
81  const xAOD::MuonSegmentContainer& segments) const;
82  private:
84  using TreeRawVec_t = SearchTree_t::vector_t;
92  const Location loc,
93  TreeRawVec_t& outContainer) const;
96  std::unique_ptr<MsTrackSeedContainer> resolveOverlaps(MsTrackSeedContainer&& unresolved) const;
97 
99  };
100 }
101 
102 
103 #endif
MuonR4::MsTrackSeeder::findTrackSeeds
std::unique_ptr< MsTrackSeedContainer > findTrackSeeds(const EventContext &ctx, const xAOD::MuonSegmentContainer &segments) const
Constructs the MS track seeds from the segment container.
Definition: MsTrackSeeder.cxx:81
MuonR4::MsTrackSeeder::Config::barrelRadius
double barrelRadius
The radius of the barrel cylinder to seed.
Definition: MsTrackSeeder.h:30
MuonR4::MsTrackSeeder::withinBounds
bool withinBounds(const Amg::Vector2D &projPos, const Location loc) const
Returns whether the expression on the cylinder is within the surface bounds.
Definition: MsTrackSeeder.cxx:33
MuonR4::MsTrackSeeder::Config::barrelLength
double barrelLength
The maximum length of the barrel cylinder, if not capped by the placement of the endcap discs.
Definition: MsTrackSeeder.h:33
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
MuonR4::MsTrackSeeder::SearchTree_t
Acts::KDTree< 3, const xAOD::MuonSegment *, double, std::array, 6 > SearchTree_t
Definition of the search tree class.
Definition: MsTrackSeeder.h:46
xAOD::MuonSegment_v1
Class describing a MuonSegment.
Definition: MuonSegment_v1.h:33
MuonR4::MsTrackSeeder::appendSegment
void appendSegment(const xAOD::MuonSegment *segment, const Location loc, TreeRawVec_t &outContainer) const
Append the to the raw data container.
Definition: MsTrackSeeder.cxx:48
MuonR4::MsTrackSeeder::eSector
@ eSector
Sector of the associated spectrometer sector.
Definition: MsTrackSeeder.h:54
MuonR4::MsTrackSeeder::Config::endcapDiscZ
double endcapDiscZ
Position of the endcap discs.
Definition: MsTrackSeeder.h:35
MuonR4::MsTrackSeeder::SeedCoords
SeedCoords
Abrivation of the seed coordinates.
Definition: MsTrackSeeder.h:50
MuonR4::MsTrackSeed::Location
Location
Enum defining whether the seed is made in the endcap / barrel.
Definition: MsTrackSeed.h:21
MuonSegmentContainer.h
MuonR4::MsTrackSeeder::m_cfg
Config m_cfg
Definition: MsTrackSeeder.h:98
cm
const double cm
Definition: Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/tools/FCAL_ChannelMap.cxx:25
MuonR4::MsTrackSeeder::constructTree
SearchTree_t constructTree(const xAOD::MuonSegmentContainer &segments) const
Construct a complete search tree from a MuonSegment container.
Definition: MsTrackSeeder.cxx:71
MuonR4::ISegmentSelectionTool
Definition: ISegmentSelectionTool.h:14
MuonR4::MsTrackSeeder::TreeRawVec_t
SearchTree_t::vector_t TreeRawVec_t
Abbrivation of the KDTree raw data vector.
Definition: MsTrackSeeder.h:84
ISegmentSelectionTool.h
MsTrackSeed.h
AthMessaging
Class to provide easy MsgStream access and capabilities.
Definition: AthMessaging.h:55
MuonR4::MsTrackSeeder::Location
MsTrackSeed::Location Location
Enum toggling whether the segment is in the endcap or barrel.
Definition: MsTrackSeeder.h:48
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
Config
Definition: dumpNPs.cxx:47
MuonR4::MsTrackSeeder::ePosOnCylinder
@ ePosOnCylinder
Extrapolation position along the cylinder surface.
Definition: MsTrackSeeder.h:56
MuonR4::MsTrackSeeder::Config::endcapDiscRadius
double endcapDiscRadius
Radius of the endcap discs.
Definition: MsTrackSeeder.h:37
MuonR4::SearchTree_t
MsTrackSeeder::SearchTree_t SearchTree_t
Definition: MsTrackSeeder.cxx:9
MuonR4::MsTrackSeeder::Config::seedHalfLength
double seedHalfLength
Maximum separation of point on the cylinder to be picked up onto a seed.
Definition: MsTrackSeeder.h:40
MuonR4::MsTrackSeeder
Helper class to group muon sgements that may belong to a muon trajectory.
Definition: MsTrackSeeder.h:25
WriteCaloSwCorrections.cfg
cfg
Definition: WriteCaloSwCorrections.py:23
MuonR4
This header ties the generic definitions in this package.
Definition: HoughEventData.h:16
MuonR4::MsTrackSeeder::Config::selector
const ISegmentSelectionTool * selector
Pointer to the segement selection tool which compares two segments for their compatibilitiy.
Definition: MsTrackSeeder.h:43
MuonR4::MsTrackSeedContainer
std::vector< MsTrackSeed > MsTrackSeedContainer
Definition: MsTrackSeed.h:61
AthMessaging.h
MuonR4::MsTrackSeeder::resolveOverlaps
std::unique_ptr< MsTrackSeedContainer > resolveOverlaps(MsTrackSeedContainer &&unresolved) const
Removes exact duplciates or partial subsets of the MsTrackSeeds.
Definition: MsTrackSeeder.cxx:135
MuonR4::MsTrackSeeder::Config
Definition: MsTrackSeeder.h:28
MuonR4::MsTrackSeeder::expressOnCylinder
Amg::Vector2D expressOnCylinder(const xAOD::MuonSegment &segment, const Location loc) const
Expresses the segment on the cylinder surface.
Definition: MsTrackSeeder.cxx:15
MuonR4::MsTrackSeeder::eDetSection
@ eDetSection
Encode the seed location (-1,1 -> endcaps, 0 -> barrel
Definition: MsTrackSeeder.h:52
python.SystemOfUnits.m
float m
Definition: SystemOfUnits.py:106
NSWL1::PadTriggerAdapter::segment
Muon::NSW_PadTriggerSegment segment(const NSWL1::PadTrigger &data)
Definition: PadTriggerAdapter.cxx:5
MuonR4::MsTrackSeeder::MsTrackSeeder
MsTrackSeeder(const std::string &msgName, Config &&cfg)
Standard constructor.
Definition: MsTrackSeeder.cxx:11