![]() |
ATLAS Offline Software
|
Standalone module to handle fast segment fitting and momentum estimation starting from global patterns. More...
#include <FastMuonSABuilder.h>
Classes | |
| struct | Config |
| Configuration object. More... | |
Public Types | |
| using | StIndex = Muon::MuonStationIndex::StIndex |
| Type alias for the station index. | |
| using | Parameters = SegmentFit::Parameters |
| Type alias for the segment fitting parameters. | |
| using | LineFitter = MuonR4::SegmentFit::SegmentLineFitter |
| Type alias for the line fitter. | |
| using | MdtSegmentSeeder = MuonR4::SegmentFit::MdtSegmentSeedGenerator |
| Type alias for the L-R segment seeder. | |
| using | MuonCont_t = xAOD::FillContainer<xAOD::MuonContainer, xAOD::MuonAuxContainerR4> |
| Define the muon container type. | |
Public Member Functions | |
| FastMuonSABuilder (const std::string &name, Config &&config) | |
| Standard constructor. | |
| xAOD::Muon * | buildMuonCandidate (const EventContext &ctx, const ActsTrk::GeometryContext &gctx, const AtlasFieldCacheCondObj &magField, const GlobalPattern &pattern, MuonCont_t &outMuons) const |
| Main methods steering the muon candidate building. | |
| bool | msgLvl (const MSG::Level lvl) const |
| Test the output level. | |
| MsgStream & | msg () const |
| The standard message stream. | |
| MsgStream & | msg (const MSG::Level lvl) const |
| The standard message stream. | |
| void | setLevel (MSG::Level lvl) |
| Change the current logging level. | |
Private Types | |
| using | Hit_t = const SpacePoint* |
| Type alias for the hit type & associated vector. | |
| using | HitVec_t = std::vector<Hit_t> |
| using | Bucket_t = const SpacePointBucket* |
| Type alias for the bucket type. | |
| using | Segment_t = std::unique_ptr<Segment> |
| Type alias for the segment type. | |
Private Member Functions | |
| Segment_t | fitSegment (const EventContext &ctx, const Amg::Transform3D &localToGlobal, Bucket_t parentBucket, std::vector< Hit_t > &&hits) const |
| Fit a segment using the provided seed. | |
| HitVec_t | estimateBendingPars (HitVec_t &&hits, Parameters &pars) const |
| Estimate the bending parameters of a segment through a weighted linear regression. | |
| void | initMessaging () const |
| Initialize our message level and MessageSvc. | |
Private Attributes | |
| Config | m_cfg |
| Global Pattern Recognition configuration. | |
| SpacePointPerLayerSorter | m_spSorter {} |
| Spacepoint sorter per logical measurement layer. | |
| std::unique_ptr< LineFitter > | m_fitter {} |
| Pointer to the actual segment fitter. | |
| std::unique_ptr< LineFitter > | m_nswFitter {} |
| Pointer to the NSW segment fitter. | |
| std::unique_ptr< MdtSegmentSeeder > | m_mdtSeeder {} |
| Pointer to the L-R segment seeder. | |
| std::unique_ptr< MsTrackSeeder > | m_trackSeeder {} |
| Pointer to the track seeder for momentum estimate. | |
| std::string | m_nm |
| Message source name. | |
| boost::thread_specific_ptr< MsgStream > | m_msg_tls |
| MsgStream instance (a std::cout like with print-out levels). | |
| std::atomic< IMessageSvc * > | m_imsg { nullptr } |
| MessageSvc pointer. | |
| std::atomic< MSG::Level > | m_lvl { MSG::NIL } |
| Current logging level. | |
| std::atomic_flag m_initialized | ATLAS_THREAD_SAFE = ATOMIC_FLAG_INIT |
| Messaging initialized (initMessaging). | |
Standalone module to handle fast segment fitting and momentum estimation starting from global patterns.
This tool consists of the final stage of the Phase-2 fast reconstruction, processing the global patterns found in previous steps to build muon candidates. It performs a straight line segment fit using the pattern hits in each station and use the fitted segments to estimate the momentum of the muon candidate. The main method consumes the global patterns and produces the output muon candidates as ****to be defined FastReco::MuonSA objects****.
Definition at line 37 of file FastMuonSABuilder.h.
|
private |
Type alias for the bucket type.
Definition at line 110 of file FastMuonSABuilder.h.
|
private |
Type alias for the hit type & associated vector.
Definition at line 107 of file FastMuonSABuilder.h.
|
private |
Definition at line 108 of file FastMuonSABuilder.h.
Type alias for the line fitter.
Definition at line 44 of file FastMuonSABuilder.h.
| using MuonR4::FastReco::FastMuonSABuilder::MdtSegmentSeeder = MuonR4::SegmentFit::MdtSegmentSeedGenerator |
Type alias for the L-R segment seeder.
Definition at line 46 of file FastMuonSABuilder.h.
| using MuonR4::FastReco::FastMuonSABuilder::MuonCont_t = xAOD::FillContainer<xAOD::MuonContainer, xAOD::MuonAuxContainerR4> |
Define the muon container type.
Definition at line 48 of file FastMuonSABuilder.h.
Type alias for the segment fitting parameters.
Definition at line 42 of file FastMuonSABuilder.h.
|
private |
Type alias for the segment type.
Definition at line 112 of file FastMuonSABuilder.h.
Type alias for the station index.
Definition at line 40 of file FastMuonSABuilder.h.
| MuonR4::FastReco::FastMuonSABuilder::FastMuonSABuilder | ( | const std::string & | name, |
| Config && | config ) |
Standard constructor.
| name | Name to be printed in the messaging |
| config | Configuration parameters |
Initialize the segment line fitter
Initialize the NSW segment fitter
Initialize the L-R segment seeder
Initialize the track seeder
Definition at line 59 of file FastMuonSABuilder.cxx.
| xAOD::Muon * MuonR4::FastReco::FastMuonSABuilder::buildMuonCandidate | ( | const EventContext & | ctx, |
| const ActsTrk::GeometryContext & | gctx, | ||
| const AtlasFieldCacheCondObj & | magField, | ||
| const GlobalPattern & | pattern, | ||
| MuonCont_t & | outMuons ) const |
Main methods steering the muon candidate building.
Given the global pattern, it fits segments in each station and use them to estimate the muon momentum.
| ctx | Event context |
| gctx | Geometry context |
| magField | Magnetic field |
| pattern | Global pattern |
| outMuons | Output muon container to be filled |
If we already have 3 segments, we don't try to fit more segments in other stations
Retrieve the pattern hits & parent buckets in the station
Since we can have multiple sectors in a station, we need to group hits by sector
We collect & sort the sectors by the number of hits, so we'll process first the sectors with more hits.
Try to fit a segment using the first sector. If it fails or the segment has poor quality, try other sectors if any
Find the parent bucket, needed for holes recovery in segment fitting. We expect one parent bucket per sector; if we have multiple ones, take the one containing the most hits
Definition at line 101 of file FastMuonSABuilder.cxx.
|
private |
Estimate the bending parameters of a segment through a weighted linear regression.
This method is used to estimate initial parameters when no straw measurements are available and the MDTseeder cannot be used, e.g. NSW.
| hits | Vector of hits |
| pars | Parameters to be estimated |
Definition at line 317 of file FastMuonSABuilder.cxx.
|
private |
Fit a segment using the provided seed.
| ctx | Event context |
| localToGlobal | Transformation from local to global coordinates |
| patternSeed | Seed for the segment fit |
Check that we have at least 2 measurement layers
Initialize initial parameters in the centeral phi plane of the chamber
Handle the case of NSW. In principle it can happen to have mixed hit types, NSW and e.g. EIL hits. In such a case, we check if NSW hits represent the majority
If we have straws, use the MDT segment seeder to estimate initial parameters. Segments are fitted into the chamber center phi plane.
Definition at line 237 of file FastMuonSABuilder.cxx.
|
privateinherited |
Initialize our message level and MessageSvc.
This method should only be called once.
Definition at line 39 of file AthMessaging.cxx.
|
inlineinherited |
The standard message stream.
Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.
Definition at line 167 of file AthMessaging.h.
|
inlineinherited |
The standard message stream.
Returns a reference to the default message stream May not be invoked before sysInitialize() has been invoked.
Definition at line 182 of file AthMessaging.h.
|
inlineinherited |
Test the output level.
| lvl | The message level to test against |
| true | Messages at level "lvl" will be printed |
Definition at line 151 of file AthMessaging.h.
|
inherited |
Change the current logging level.
Use this rather than msg().setLevel() for proper operation with MT.
Definition at line 28 of file AthMessaging.cxx.
|
mutableprivateinherited |
Messaging initialized (initMessaging).
Definition at line 141 of file AthMessaging.h.
|
private |
Global Pattern Recognition configuration.
Definition at line 132 of file FastMuonSABuilder.h.
|
private |
|
mutableprivateinherited |
|
mutableprivateinherited |
|
private |
|
mutableprivateinherited |
MsgStream instance (a std::cout like with print-out levels).
Definition at line 132 of file AthMessaging.h.
|
privateinherited |
Message source name.
Definition at line 129 of file AthMessaging.h.
|
private |
|
private |
Spacepoint sorter per logical measurement layer.
Definition at line 134 of file FastMuonSABuilder.h.
|
private |
Pointer to the track seeder for momentum estimate.
Definition at line 142 of file FastMuonSABuilder.h.