ATLAS Offline Software
MuGirlLowBetaTag.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef MUONCOMBINEDEVENT_MUGIRLLOWBETATAG_H
6 #define MUONCOMBINEDEVENT_MUGIRLLOWBETATAG_H
7 
8 #include <vector>
9 #include <memory>
10 
15 
16 namespace Trk {
17  class Track;
18 }
19 
20 namespace Muon {
21  class MuonSegment;
22 }
23 
24 namespace MuonCombined {
25 
27  class MuGirlLowBetaTag : public TagBase {
28  public:
32  const std::vector<ElementLink<Trk::SegmentCollection> >& segments);
33 
37 
39  ~MuGirlLowBetaTag() = default;
40 
42  const Trk::Track* combinedTrack() const;
43 
44  /*ElementLink to the combined track*/
46 
48  const Trk::Track* updatedExtrapolatedTrack() const;
49 
52 
54  const std::vector<ElementLink<Trk::SegmentCollection> >& segments() const;
55  std::vector<const Muon::MuonSegment*> associatedSegments() const override;
56 
57  /* stau Dressing */
58  void setMuBeta(float muBeta);
59  float getMuBeta() const;
60 
61 
62 
63  void setStauExtras(std::unique_ptr<MuGirlNS::StauExtras> stauExtras);
65  const MuGirlNS::StauExtras* getStauExtras() const;
66 
67 
69  std::string name() const override { return "MuGirlLowBetaTag"; }
70 
72  std::string toString() const override { return name(); }
73 
75  const Trk::Track* primaryTrack() const override;
76 
77  private:
81 
85  std::vector<ElementLink<Trk::SegmentCollection> > m_segments{};
86 
87  // dressing
88  float m_muBeta{-9999.};
89  std::unique_ptr<MuGirlNS::StauExtras> m_stauExtras{};
90  };
91  inline bool operator<(const MuGirlLowBetaTag& t1, const MuGirlLowBetaTag& t2) {
92  const Trk::FitQuality* t1FQ = t1.combinedTrack() ? t1.combinedTrack()->fitQuality() : nullptr;
93  const Trk::FitQuality* t2FQ = t2.combinedTrack() ? t2.combinedTrack()->fitQuality() : nullptr;
94  if (t1FQ && t2FQ) { return t1FQ->chiSquared() < t2FQ->chiSquared(); }
95  return t1.segments().size() < t2.segments().size();
96  }
97 
98 } // namespace MuonCombined
99 
100 #endif
MuonCombined::MuGirlLowBetaTag::setUpdatedExtrapolatedTrack
void setUpdatedExtrapolatedTrack(const ElementLink< TrackCollection > &meLink)
set update extrapolated track
Definition: MuGirlLowBetaTag.cxx:22
MuonCombined::MuGirlLowBetaTag::operator=
MuGirlLowBetaTag & operator=(const MuGirlLowBetaTag &)=delete
MuonCombined::MuGirlLowBetaTag::segments
const std::vector< ElementLink< Trk::SegmentCollection > > & segments() const
access segments
Definition: MuGirlLowBetaTag.cxx:24
MuonCombined::MuGirlLowBetaTag::toString
std::string toString() const override
print content to string
Definition: MuGirlLowBetaTag.h:72
Trk::Track
The ATLAS Track class.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
MuonCombined::MuGirlLowBetaTag::MuGirlLowBetaTag
MuGirlLowBetaTag(const MuGirlLowBetaTag &)=delete
block copy and assignment
ALFA_EventTPCnv_Dict::t1
std::vector< ALFA_RawDataCollection_p1 > t1
Definition: ALFA_EventTPCnvDict.h:43
MuonCombined::MuGirlLowBetaTag::m_stauExtras
std::unique_ptr< MuGirlNS::StauExtras > m_stauExtras
Definition: MuGirlLowBetaTag.h:89
Muon
This class provides conversion from CSC RDO data to CSC Digits.
Definition: TrackSystemController.h:49
xAOD::MuonSegment
MuonSegment_v1 MuonSegment
Reference the current persistent version:
Definition: Event/xAOD/xAODMuon/xAODMuon/MuonSegment.h:13
MuonCombined::MuGirlLowBetaTag
TagBase implementation for a combined fit.
Definition: MuGirlLowBetaTag.h:27
MuonCombined::MuGirlLowBetaTag::name
std::string name() const override
name string
Definition: MuGirlLowBetaTag.h:69
MuonCombined::MuGirlLowBetaTag::associatedSegments
std::vector< const Muon::MuonSegment * > associatedSegments() const override
access to associated segments, empty vector if non available
Definition: MuGirlLowBetaTag.cxx:27
TrackCollection.h
Trk::FitQuality
Class to represent and store fit qualities from track reconstruction in terms of and number of degre...
Definition: FitQuality.h:97
MuonCombined::MuGirlLowBetaTag::m_combLink
ElementLink< TrackCollection > m_combLink
data content
Definition: MuGirlLowBetaTag.h:83
MuonCombined::MuGirlLowBetaTag::getStauExtras
MuGirlNS::StauExtras * getStauExtras()
Definition: MuGirlLowBetaTag.cxx:42
Trk
Ensure that the ATLAS eigen extensions are properly loaded.
Definition: FakeTrackBuilder.h:9
MuonCombined::MuGirlLowBetaTag::combinedTrack
const Trk::Track * combinedTrack() const
access combined track
Definition: MuGirlLowBetaTag.cxx:19
MuonCombined::MuGirlLowBetaTag::m_segments
std::vector< ElementLink< Trk::SegmentCollection > > m_segments
Definition: MuGirlLowBetaTag.h:85
MuonCombined::MuGirlLowBetaTag::getMuBeta
float getMuBeta() const
Definition: MuGirlLowBetaTag.cxx:37
MuonCombined::MuGirlLowBetaTag::m_muBeta
float m_muBeta
list of segments
Definition: MuGirlLowBetaTag.h:88
MuonCombined::operator<
bool operator<(const CombinedFitTag &t1, const CombinedFitTag &t2)
Definition: CombinedFitTag.h:117
ALFA_EventTPCnv_Dict::t2
std::vector< ALFA_RawDataContainer_p1 > t2
Definition: ALFA_EventTPCnvDict.h:44
MuonCombined::MuGirlLowBetaTag::setMuBeta
void setMuBeta(float muBeta)
Definition: MuGirlLowBetaTag.cxx:36
TagBase.h
MuonCombined
The MuonTagToSegMap is an auxillary construct that links the MuonSegments associated with a combined ...
Definition: IMuonSystemExtensionTool.h:23
MuonCombined::MuGirlLowBetaTag::setStauExtras
void setStauExtras(std::unique_ptr< MuGirlNS::StauExtras > stauExtras)
Definition: MuGirlLowBetaTag.cxx:39
Trk::FitQuality::chiSquared
double chiSquared() const
returns the of the overall track fit
Definition: FitQuality.h:56
CandidateSummary.h
Track
Definition: TriggerChamberClusterOnTrackCreator.h:21
MuonCombined::MuGirlLowBetaTag::MuGirlLowBetaTag
MuGirlLowBetaTag(const ElementLink< TrackCollection > &combLink, const std::vector< ElementLink< Trk::SegmentCollection > > &segments)
Constructor a combined track and a list of segments as input.
Definition: MuGirlLowBetaTag.cxx:12
MuGirlNS::StauExtras
Definition: CandidateSummary.h:69
MuonCombined::MuGirlLowBetaTag::combinedTrackLink
ElementLink< TrackCollection > combinedTrackLink() const
Definition: MuGirlLowBetaTag.h:45
MuonCombined::MuGirlLowBetaTag::updatedExtrapolatedTrack
const Trk::Track * updatedExtrapolatedTrack() const
access update extrapolated track, returns zero if none are available
Definition: MuGirlLowBetaTag.cxx:20
MuonCombined::MuGirlLowBetaTag::m_meLink
ElementLink< TrackCollection > m_meLink
Definition: MuGirlLowBetaTag.h:84
SegmentCollection.h
MuonCombined::TagBase
base-class for combined reconstruction output Provides access to MuonType and Author
Definition: TagBase.h:48
MuonCombined::MuGirlLowBetaTag::primaryTrack
const Trk::Track * primaryTrack() const override
access to primary muon system track, zero if non available
Definition: MuGirlLowBetaTag.cxx:26
MuonCombined::MuGirlLowBetaTag::~MuGirlLowBetaTag
~MuGirlLowBetaTag()=default
destructor