ATLAS Offline Software
Loading...
Searching...
No Matches
MuonR4::SegmentFit::SeederStateBase Struct Reference

Helper struct to delegate the EDM interactions with the space point container during the seeding. More...

#include <MdtSegmentSeedGenerator.h>

Inheritance diagram for MuonR4::SegmentFit::SeederStateBase:
Collaboration diagram for MuonR4::SegmentFit::SeederStateBase:

Public Types

using CalibCont_t = std::vector<std::unique_ptr<CalibratedSpacePoint>>
 Abrivation of the collection of calibrated space points.
using HitVec = std::vector<const SpacePoint*>
using HitLayVec = std::vector<HitVec>

Public Member Functions

const SegmentSeedparent () const
 Returns the parent seed from which the state is constructed.
bool goodCandidate (const SpacePoint &testMdt) const
 Returns whether the hit is a good candidate for seeding.
double candidateChi2 (const Acts::CalibrationContext &cctx, const Amg::Vector3D &seedPos, const Amg::Vector3D &seedDir, const double t0, const SpacePoint &candidate) const
 Returns the pull of the candidate w.r.t.
double strawRadius (const SpacePoint &testMdt) const
 Returns the outer tube radius of the space point.
CalibCont_t newContainer (const Acts::CalibrationContext &cctx) const
 Creates a new candidate seed container.
void append (const Acts::CalibrationContext &cctx, const Amg::Vector3D &pos, const Amg::Vector3D &dir, const double t0, const SpacePoint &appendMe, CalibCont_t &appendTo) const
 Appends the space point measurement to the candidate seed container Optionally, the hit may be calibrated.
bool stopSeeding (const std::size_t lowerLayer, const std::size_t upperLayer) const
 Requests whether the seed line generation shall be stopped based on the pair of.
const HitLayVecmdtHits () const
 Returns the sorted Mdt hits.
const HitLayVecstrawHits () const
 Returns the sorted Mdt hits.
std::size_t nMdtHits () const
 Returns the number of all Mdt hits in the seed.
const HitLayVecstripHits () const
 Returns the sorted strip hits.
std::size_t nStripHits () const
 Returns the number of all strip hits in the seed.
std::size_t firstLayerFrom2ndMl () const
 Returns the layer index with hits from the second multilayer.

Protected Member Functions

 SeederStateBase (const SegmentSeed *parentSeed, const ISpacePointCalibrator *calibrator, const bool calibratedPull)
 Protected constructor to instantiate the.

Private Attributes

const SegmentSeedm_parent {}
const ISpacePointCalibratorm_calibrator {nullptr}
bool m_calibratePull {false}
HitLayVec m_mdtLayers {}
 Sorted Mdt hits per tube layer.
HitLayVec m_stripLayers {}
 Sorted Strip hits per gasGap strip.
std::size_t m_nMdtHits {0}
 Number of all Mdt tube hits.
std::size_t m_nStripHits {0}
 Number of all strip hits.
std::size_t m_tubeLaySwitch {std::numeric_limits<std::size_t>::max()}
 Index of the first tube-layer from the second multilayer.

Detailed Description

Helper struct to delegate the EDM interactions with the space point container during the seeding.

Definition at line 21 of file MdtSegmentSeedGenerator.h.

Member Typedef Documentation

◆ CalibCont_t

Abrivation of the collection of calibrated space points.

Definition at line 29 of file MdtSegmentSeedGenerator.h.

◆ HitLayVec

using MuonR4::SpacePointPerLayerSplitter::HitLayVec = std::vector<HitVec>
inherited

Definition at line 21 of file SpacePointPerLayerSplitter.h.

◆ HitVec

using MuonR4::SpacePointPerLayerSplitter::HitVec = std::vector<const SpacePoint*>
inherited

Definition at line 20 of file SpacePointPerLayerSplitter.h.

Constructor & Destructor Documentation

◆ SeederStateBase()

MuonR4::SegmentFit::SeederStateBase::SeederStateBase ( const SegmentSeed * parentSeed,
const ISpacePointCalibrator * calibrator,
const bool calibratedPull )
explicitprotected

Protected constructor to instantiate the.

Definition at line 23 of file MdtSegmentSeedGenerator.cxx.

25 :
26 SpacePointPerLayerSplitter{parentSeed->getHitsInMax()},
27 m_parent{parentSeed},
28 m_calibrator{calibrator},
29 m_calibratePull{calibratePull} {}
SpacePointPerLayerSplitter(const SpacePointBucket &bucket)
Constructor taking a complete bucket.
const ISpacePointCalibrator * m_calibrator

Member Function Documentation

◆ append()

void MuonR4::SegmentFit::SeederStateBase::append ( const Acts::CalibrationContext & cctx,
const Amg::Vector3D & pos,
const Amg::Vector3D & dir,
const double t0,
const SpacePoint & appendMe,
CalibCont_t & appendTo ) const

Appends the space point measurement to the candidate seed container Optionally, the hit may be calibrated.

Parameters
cctxCalibration context to access the conditions data
posReference position of the seed line
dirReference direction of the seed line
t0Offset in the time of arrival (Acts units)
appendMeSpace point candidate to append to the container
appendToOutput container to which the space point is appended

Definition at line 69 of file MdtSegmentSeedGenerator.cxx.

74 {
75 const EventContext& ctx{*cctx.get<const EventContext*>()};
76 appendTo.push_back(m_calibrator->calibrate(ctx, &appendMe, pos, dir, t0));
77 }
static Double_t t0

◆ candidateChi2()

double MuonR4::SegmentFit::SeederStateBase::candidateChi2 ( const Acts::CalibrationContext & cctx,
const Amg::Vector3D & seedPos,
const Amg::Vector3D & seedDir,
const double t0,
const SpacePoint & candidate ) const

Returns the pull of the candidate w.r.t.

the line & the time offset

Parameters
cctxCalibration context to access the conditions data
seedPosReference position of the seed line
seedDirReference direction of the seed line
t0Offset in the time of arrival (Acts units)
candidateSpace point which chi2 is to be evaluated

Definition at line 52 of file MdtSegmentSeedGenerator.cxx.

56 {
57 if (m_calibratePull) {
58 const EventContext& ctx{*cctx.get<const EventContext*>()};
59 auto calibSp = m_calibrator->calibrate(ctx, &candidate, seedPos, seedDir, t0);
60 assert(calibSp != nullptr);
61 return SeedingAux::chi2Term(seedPos, seedDir, *calibSp);
62 }
63 return SeedingAux::chi2Term(seedPos, seedDir, candidate);
64 }

◆ firstLayerFrom2ndMl()

std::size_t MuonR4::SpacePointPerLayerSplitter::firstLayerFrom2ndMl ( ) const
inlineinherited

Returns the layer index with hits from the second multilayer.

Definition at line 47 of file SpacePointPerLayerSplitter.h.

47 {
48 return m_tubeLaySwitch;
49 }
std::size_t m_tubeLaySwitch
Index of the first tube-layer from the second multilayer.

◆ goodCandidate()

bool MuonR4::SegmentFit::SeederStateBase::goodCandidate ( const SpacePoint & testMdt) const

Returns whether the hit is a good candidate for seeding.

Parameters
testMdtReference to the space point considered for seeding

Definition at line 38 of file MdtSegmentSeedGenerator.cxx.

38 {
39 switch (testMdt.type()) {
40 using enum xAOD::UncalibMeasType;
42 return static_cast<const xAOD::MdtDriftCircle*>(testMdt.primaryMeasurement())->status() ==
43 Muon::MdtDriftCircleStatus::MdtStatusDriftTime;
44 case RpcStripType:
45 case TgcStripType:
46 return true;
47 default:
48 return false;
49 }
50 return false;
51 }
MdtDriftCircleStatus status() const
Returns the status of the measurement.
MdtDriftCircle_v1 MdtDriftCircle
UncalibMeasType
Define the type of the uncalibrated measurement.

◆ mdtHits()

const HitLayVec & MuonR4::SpacePointPerLayerSplitter::mdtHits ( ) const
inlineinherited

Returns the sorted Mdt hits.

Definition at line 27 of file SpacePointPerLayerSplitter.h.

27 {
28 return m_mdtLayers;
29 }
HitLayVec m_mdtLayers
Sorted Mdt hits per tube layer.

◆ newContainer()

SeederStateBase::CalibCont_t MuonR4::SegmentFit::SeederStateBase::newContainer ( const Acts::CalibrationContext & cctx) const

Creates a new candidate seed container.

Parameters
cctxCalibration context (defined by the interface)

Definition at line 66 of file MdtSegmentSeedGenerator.cxx.

66 {
67 return CalibCont_t{};
68 }
std::vector< std::unique_ptr< CalibratedSpacePoint > > CalibCont_t
Abrivation of the collection of calibrated space points.

◆ nMdtHits()

std::size_t MuonR4::SpacePointPerLayerSplitter::nMdtHits ( ) const
inlineinherited

Returns the number of all Mdt hits in the seed.

Definition at line 35 of file SpacePointPerLayerSplitter.h.

35 {
36 return m_nMdtHits;
37 }
std::size_t m_nMdtHits
Number of all Mdt tube hits.

◆ nStripHits()

std::size_t MuonR4::SpacePointPerLayerSplitter::nStripHits ( ) const
inlineinherited

Returns the number of all strip hits in the seed.

Definition at line 43 of file SpacePointPerLayerSplitter.h.

43 {
44 return m_nStripHits;
45 }
std::size_t m_nStripHits
Number of all strip hits.

◆ parent()

const SegmentSeed * MuonR4::SegmentFit::SeederStateBase::parent ( ) const

Returns the parent seed from which the state is constructed.

Definition at line 31 of file MdtSegmentSeedGenerator.cxx.

31{ return m_parent; }

◆ stopSeeding()

bool MuonR4::SegmentFit::SeederStateBase::stopSeeding ( const std::size_t lowerLayer,
const std::size_t upperLayer ) const

Requests whether the seed line generation shall be stopped based on the pair of.

Parameters
lowerLayerIndex of the lower hit layer from which the seed circles are picked
upperLayerIndex of the upper hit layer from which the seed circles are picked

Definition at line 78 of file MdtSegmentSeedGenerator.cxx.

79 {
80 return lowerLayer >= firstLayerFrom2ndMl() || lowerLayer >= upperLayer;
81 }
std::size_t firstLayerFrom2ndMl() const
Returns the layer index with hits from the second multilayer.

◆ strawHits()

const HitLayVec & MuonR4::SpacePointPerLayerSplitter::strawHits ( ) const
inlineinherited

Returns the sorted Mdt hits.

Definition at line 31 of file SpacePointPerLayerSplitter.h.

31 {
32 return m_mdtLayers;
33 }

◆ strawRadius()

double MuonR4::SegmentFit::SeederStateBase::strawRadius ( const SpacePoint & testMdt) const

Returns the outer tube radius of the space point.

Parameters
testMdtReference to the Mdt space point of interest

Definition at line 33 of file MdtSegmentSeedGenerator.cxx.

33 {
34 assert(testMdt.type() == xAOD::UncalibMeasType::MdtDriftCircleType);
35 return static_cast<const xAOD::MdtDriftCircle*>(testMdt.primaryMeasurement())
37 }
double tubeRadius() const
Adds the thickness of the tube wall onto the radius.
const MuonGMR4::MdtReadoutElement * readoutElement() const
Retrieve the associated MdtReadoutElement.

◆ stripHits()

const HitLayVec & MuonR4::SpacePointPerLayerSplitter::stripHits ( ) const
inlineinherited

Returns the sorted strip hits.

Definition at line 39 of file SpacePointPerLayerSplitter.h.

39 {
40 return m_stripLayers;
41 }
HitLayVec m_stripLayers
Sorted Strip hits per gasGap strip.

Member Data Documentation

◆ m_calibratePull

bool MuonR4::SegmentFit::SeederStateBase::m_calibratePull {false}
private

Definition at line 75 of file MdtSegmentSeedGenerator.h.

75{false};

◆ m_calibrator

const ISpacePointCalibrator* MuonR4::SegmentFit::SeederStateBase::m_calibrator {nullptr}
private

Definition at line 74 of file MdtSegmentSeedGenerator.h.

74{nullptr};

◆ m_mdtLayers

HitLayVec MuonR4::SpacePointPerLayerSplitter::m_mdtLayers {}
privateinherited

Sorted Mdt hits per tube layer.

Definition at line 52 of file SpacePointPerLayerSplitter.h.

52{};

◆ m_nMdtHits

std::size_t MuonR4::SpacePointPerLayerSplitter::m_nMdtHits {0}
privateinherited

Number of all Mdt tube hits.

Definition at line 56 of file SpacePointPerLayerSplitter.h.

56{0};

◆ m_nStripHits

std::size_t MuonR4::SpacePointPerLayerSplitter::m_nStripHits {0}
privateinherited

Number of all strip hits.

Definition at line 58 of file SpacePointPerLayerSplitter.h.

58{0};

◆ m_parent

const SegmentSeed* MuonR4::SegmentFit::SeederStateBase::m_parent {}
private

Definition at line 73 of file MdtSegmentSeedGenerator.h.

73{};

◆ m_stripLayers

HitLayVec MuonR4::SpacePointPerLayerSplitter::m_stripLayers {}
privateinherited

Sorted Strip hits per gasGap strip.

Definition at line 54 of file SpacePointPerLayerSplitter.h.

54{};

◆ m_tubeLaySwitch

std::size_t MuonR4::SpacePointPerLayerSplitter::m_tubeLaySwitch {std::numeric_limits<std::size_t>::max()}
privateinherited

Index of the first tube-layer from the second multilayer.

Definition at line 60 of file SpacePointPerLayerSplitter.h.

60{std::numeric_limits<std::size_t>::max()};

The documentation for this struct was generated from the following files: