ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Public Attributes | Protected Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
Muon::MuonSegmentFittingTool Class Reference

#include <MuonSegmentFittingTool.h>

Inheritance diagram for Muon::MuonSegmentFittingTool:
Collaboration diagram for Muon::MuonSegmentFittingTool:

Public Member Functions

 MuonSegmentFittingTool (const std::string &, const std::string &, const IInterface *)
 
virtual ~MuonSegmentFittingTool ()=default
 
virtual StatusCode initialize ()
 
Trk::Trackfit (const Amg::Vector3D &gpos, const Amg::Vector3D &gdir, const Trk::PlaneSurface &surf, const std::vector< const Trk::MeasurementBase * > &rioVec) const
 fit segment parameters + hits producing a track More...
 
Trk::Trackfit (const MuonSegment &segment) const
 fit segment parameters + hits producing a track More...
 
void updateSegmentParameters (const Trk::Track &track, const Trk::PlaneSurface &surf, Amg::Vector2D &segLocPos, Trk::LocalDirection &segLocDir, Amg::MatrixX &locerr) const
 update the parameters of the segment using the track information More...
 
ServiceHandle< StoreGateSvc > & evtStore ()
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & evtStore () const
 The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc. More...
 
const ServiceHandle< StoreGateSvc > & detStore () const
 The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc. More...
 
virtual StatusCode sysInitialize () override
 Perform system initialization for an algorithm. More...
 
virtual StatusCode sysStart () override
 Handle START transition. More...
 
virtual std::vector< Gaudi::DataHandle * > inputHandles () const override
 Return this algorithm's input handles. More...
 
virtual std::vector< Gaudi::DataHandle * > outputHandles () const override
 Return this algorithm's output handles. More...
 
Gaudi::Details::PropertyBase & declareProperty (Gaudi::Property< T > &t)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKey &hndl, const std::string &doc, const SG::VarHandleKeyType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleBase &hndl, const std::string &doc, const SG::VarHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, SG::VarHandleKeyArray &hndArr, const std::string &doc, const SG::VarHandleKeyArrayType &)
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc, const SG::NotHandleType &)
 Declare a new Gaudi property. More...
 
Gaudi::Details::PropertyBase * declareProperty (const std::string &name, T &property, const std::string &doc="none")
 Declare a new Gaudi property. More...
 
void updateVHKA (Gaudi::Details::PropertyBase &)
 
MsgStream & msg () const
 
MsgStream & msg (const MSG::Level lvl) const
 
bool msgLvl (const MSG::Level lvl) const
 

Static Public Member Functions

static const InterfaceID & interfaceID ()
 access to tool interface More...
 

Public Attributes

Trk::MagneticFieldProperties m_magFieldProperties
 
ToolHandle< Trk::IPropagatorm_slPropagator
 
ToolHandle< Trk::ITrackFitterm_slTrackFitter
 
ToolHandle< Trk::ITrackFitterm_curvedTrackFitter
 
ToolHandle< Muon::IMuonTrackCleanerm_trackCleaner
 
bool m_updatePrecisionCoordinate
 

Protected Member Functions

void renounceArray (SG::VarHandleKeyArray &handlesArray)
 remove all handles from I/O resolution More...
 
std::enable_if_t< std::is_void_v< std::result_of_t< decltype(&T::renounce)(T)> > &&!std::is_base_of_v< SG::VarHandleKeyArray, T > &&std::is_base_of_v< Gaudi::DataHandle, T >, void > renounce (T &h)
 
void extraDeps_update_handler (Gaudi::Details::PropertyBase &ExtraDeps)
 Add StoreName to extra input/output deps as needed. More...
 

Private Types

typedef ServiceHandle< StoreGateSvcStoreGateSvc_t
 

Private Member Functions

Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
 specialization for handling Gaudi::Property<SG::VarHandleKey> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleKeyArrayType &)
 specialization for handling Gaudi::Property<SG::VarHandleKeyArray> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &hndl, const SG::VarHandleType &)
 specialization for handling Gaudi::Property<SG::VarHandleBase> More...
 
Gaudi::Details::PropertyBase & declareGaudiProperty (Gaudi::Property< T > &t, const SG::NotHandleType &)
 specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray> More...
 

Private Attributes

StoreGateSvc_t m_evtStore
 Pointer to StoreGate (event store by default) More...
 
StoreGateSvc_t m_detStore
 Pointer to StoreGate (detector store by default) More...
 
std::vector< SG::VarHandleKeyArray * > m_vhka
 
bool m_varHandleArraysDeclared
 

Detailed Description

Implementation of an IMuonSegmentFittingTool.

Definition at line 38 of file MuonSegmentFittingTool.h.

Member Typedef Documentation

◆ StoreGateSvc_t

typedef ServiceHandle<StoreGateSvc> AthCommonDataStore< AthCommonMsg< AlgTool > >::StoreGateSvc_t
privateinherited

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ MuonSegmentFittingTool()

Muon::MuonSegmentFittingTool::MuonSegmentFittingTool ( const std::string &  t,
const std::string &  n,
const IInterface *  p 
)

Definition at line 26 of file MuonSegmentFittingTool.cxx.

26  :
28  declareInterface<IMuonSegmentFittingTool>(this);
29  declareProperty("UpdatePrecisionCoordinate", m_updatePrecisionCoordinate = false);
30  }

◆ ~MuonSegmentFittingTool()

virtual Muon::MuonSegmentFittingTool::~MuonSegmentFittingTool ( )
virtualdefault

Member Function Documentation

◆ declareGaudiProperty() [1/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyArrayType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKeyArray>

Definition at line 170 of file AthCommonDataStore.h.

172  {
173  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
174  hndl.value(),
175  hndl.documentation());
176 
177  }

◆ declareGaudiProperty() [2/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleKeyType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleKey>

Definition at line 156 of file AthCommonDataStore.h.

158  {
159  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
160  hndl.value(),
161  hndl.documentation());
162 
163  }

◆ declareGaudiProperty() [3/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  hndl,
const SG::VarHandleType  
)
inlineprivateinherited

specialization for handling Gaudi::Property<SG::VarHandleBase>

Definition at line 184 of file AthCommonDataStore.h.

186  {
187  return *AthCommonDataStore<PBASE>::declareProperty(hndl.name(),
188  hndl.value(),
189  hndl.documentation());
190  }

◆ declareGaudiProperty() [4/4]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareGaudiProperty ( Gaudi::Property< T > &  t,
const SG::NotHandleType  
)
inlineprivateinherited

specialization for handling everything that's not a Gaudi::Property<SG::VarHandleKey> or a <SG::VarHandleKeyArray>

Definition at line 199 of file AthCommonDataStore.h.

200  {
201  return PBASE::declareProperty(t);
202  }

◆ declareProperty() [1/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleBase hndl,
const std::string &  doc,
const SG::VarHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleBase. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 245 of file AthCommonDataStore.h.

249  {
250  this->declare(hndl.vhKey());
251  hndl.vhKey().setOwner(this);
252 
253  return PBASE::declareProperty(name,hndl,doc);
254  }

◆ declareProperty() [2/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKey hndl,
const std::string &  doc,
const SG::VarHandleKeyType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
hndlObject holding the property value.
docDocumentation string for the property.

This is the version for types that derive from SG::VarHandleKey. The property value object is put on the input and output lists as appropriate; then we forward to the base class.

Definition at line 221 of file AthCommonDataStore.h.

225  {
226  this->declare(hndl);
227  hndl.setOwner(this);
228 
229  return PBASE::declareProperty(name,hndl,doc);
230  }

◆ declareProperty() [3/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
SG::VarHandleKeyArray hndArr,
const std::string &  doc,
const SG::VarHandleKeyArrayType  
)
inlineinherited

Definition at line 259 of file AthCommonDataStore.h.

263  {
264 
265  // std::ostringstream ost;
266  // ost << Algorithm::name() << " VHKA declareProp: " << name
267  // << " size: " << hndArr.keys().size()
268  // << " mode: " << hndArr.mode()
269  // << " vhka size: " << m_vhka.size()
270  // << "\n";
271  // debug() << ost.str() << endmsg;
272 
273  hndArr.setOwner(this);
274  m_vhka.push_back(&hndArr);
275 
276  Gaudi::Details::PropertyBase* p = PBASE::declareProperty(name, hndArr, doc);
277  if (p != 0) {
278  p->declareUpdateHandler(&AthCommonDataStore<PBASE>::updateVHKA, this);
279  } else {
280  ATH_MSG_ERROR("unable to call declareProperty on VarHandleKeyArray "
281  << name);
282  }
283 
284  return p;
285 
286  }

◆ declareProperty() [4/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc,
const SG::NotHandleType  
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This is the generic version, for types that do not derive from SG::VarHandleKey. It just forwards to the base class version of declareProperty.

Definition at line 333 of file AthCommonDataStore.h.

337  {
338  return PBASE::declareProperty(name, property, doc);
339  }

◆ declareProperty() [5/6]

Gaudi::Details::PropertyBase* AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( const std::string &  name,
T &  property,
const std::string &  doc = "none" 
)
inlineinherited

Declare a new Gaudi property.

Parameters
nameName of the property.
propertyObject holding the property value.
docDocumentation string for the property.

This dispatches to either the generic declareProperty or the one for VarHandle/Key/KeyArray.

Definition at line 352 of file AthCommonDataStore.h.

355  {
356  typedef typename SG::HandleClassifier<T>::type htype;
357  return declareProperty (name, property, doc, htype());
358  }

◆ declareProperty() [6/6]

Gaudi::Details::PropertyBase& AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty ( Gaudi::Property< T > &  t)
inlineinherited

Definition at line 145 of file AthCommonDataStore.h.

145  {
146  typedef typename SG::HandleClassifier<T>::type htype;
148  }

◆ detStore()

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::detStore ( ) const
inlineinherited

The standard StoreGateSvc/DetectorStore Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 95 of file AthCommonDataStore.h.

95 { return m_detStore; }

◆ evtStore() [1/2]

ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( )
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 85 of file AthCommonDataStore.h.

85 { return m_evtStore; }

◆ evtStore() [2/2]

const ServiceHandle<StoreGateSvc>& AthCommonDataStore< AthCommonMsg< AlgTool > >::evtStore ( ) const
inlineinherited

The standard StoreGateSvc (event store) Returns (kind of) a pointer to the StoreGateSvc.

Definition at line 90 of file AthCommonDataStore.h.

90 { return m_evtStore; }

◆ extraDeps_update_handler()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::extraDeps_update_handler ( Gaudi::Details::PropertyBase &  ExtraDeps)
protectedinherited

Add StoreName to extra input/output deps as needed.

use the logic of the VarHandleKey to parse the DataObjID keys supplied via the ExtraInputs and ExtraOuputs Properties to add the StoreName if it's not explicitly given

◆ fit() [1/2]

Trk::Track * Muon::MuonSegmentFittingTool::fit ( const Amg::Vector3D gpos,
const Amg::Vector3D gdir,
const Trk::PlaneSurface surf,
const std::vector< const Trk::MeasurementBase * > &  rioVec 
) const
virtual

fit segment parameters + hits producing a track

Implements Muon::IMuonSegmentFittingTool.

Definition at line 44 of file MuonSegmentFittingTool.cxx.

45  {
46  ATH_MSG_VERBOSE(" trying to fit segment ");
47  const EventContext& ctx = Gaudi::Hive::currentContext();
48  Amg::Vector3D gdir = gDir;
49 
50  double gdirNorm = gdir.mag();
51  bool isCurvedSegment = (gdirNorm > 1.5);
52  if (isCurvedSegment) {
53  // re-normalize the gdir
54  gdir = Amg::Vector3D(gdir.x() / gdirNorm, gdir.y() / gdirNorm, gdir.z() / gdirNorm);
55  }
56 
57  double charge = 0;
58  Trk::AtaPlane segPars(gpos, gdir, charge, surf);
59 
60  // extrapolate segment parameters to first measurements
61  const Trk::MeasurementBase* firstMeas = rioVec.front();
62  std::unique_ptr<Trk::TrackParameters> exPars =
63  m_slPropagator->propagate(ctx, segPars, firstMeas->associatedSurface(), Trk::anyDirection, false, m_magFieldProperties);
64  if (!exPars) {
65  ATH_MSG_DEBUG(" Propagation failed!! ");
66  return nullptr;
67  }
68 
69  // small shift towards the ip
70  double sign = exPars->position().dot(exPars->momentum()) > 0 ? 1. : -1.;
71  Amg::Vector3D perpos = exPars->position() - sign * exPars->momentum().unit();
72 
73  // create start parameter
74  double phi = gdir.phi();
75  double theta = gdir.theta();
76  double qoverp = 0;
77  Trk::PerigeeSurface persurf(perpos);
78  Trk::Perigee startpar(0, 0, phi, theta, qoverp, persurf);
79 
80  // copy measurements into new vector
81  std::vector<const Trk::MeasurementBase*> vec2;
82  vec2.reserve(rioVec.size());
83  std::copy(rioVec.begin(), rioVec.end(), std::back_inserter(vec2));
84 
85  // fit
86  std::unique_ptr<Trk::Track> newtrack;
87  // use the full fitter if the segment is curved
88  if (isCurvedSegment) {
89  newtrack = m_curvedTrackFitter->fit(ctx, vec2, startpar, false, Trk::ParticleSwitcher::particle[0]);
90  }
91  // else use the straight line fitter
92  else {
93  newtrack = m_slTrackFitter->fit(ctx, vec2, startpar, false, Trk::nonInteracting);
94  }
95 
96  if (!newtrack) {
97  ATH_MSG_VERBOSE(" fit failed ");
98  return nullptr;
99  }
100  constexpr double chi2Cut = 10.;
101  std::unique_ptr<Trk::Track> cleanTrack = m_trackCleaner->clean(*newtrack, ctx);
102  if (!cleanTrack && !isCurvedSegment && calcChi2(*newtrack) > chi2Cut) {
103  ATH_MSG_VERBOSE(" lost in cleaner ");
104  return nullptr;
105  }
106 
107  if (cleanTrack && !(*cleanTrack->perigeeParameters() == *newtrack->perigeeParameters()) && !isCurvedSegment) {
108  // using release until the entire code can be migrated to use smart pointers
109  newtrack.swap(cleanTrack);
110  }
111 
112  // reject fit if larger than cut
113  if (calcChi2(*newtrack) > chi2Cut) {
114  ATH_MSG_VERBOSE(" reduced chi2 to large " << calcChi2(*newtrack) << " cut " << chi2Cut);
115  return nullptr;
116  }
117 
118  if (msgLvl(MSG::DEBUG)) {
119  const Trk::Perigee* pp = newtrack->perigeeParameters();
120  if (pp) {
121  ATH_MSG_DEBUG(" pos " << std::setprecision(5) << pp->position() << " phi " << pp->momentum().phi() << " theta "
122  << pp->momentum().theta() << " q*mom " << pp->momentum().mag() * pp->charge() << " pt "
123  << pp->momentum().perp());
124  } else {
125  ATH_MSG_DEBUG(" no perigee ");
126  }
127  }
128  return newtrack.release();
129  }

◆ fit() [2/2]

Trk::Track * Muon::MuonSegmentFittingTool::fit ( const MuonSegment segment) const
virtual

fit segment parameters + hits producing a track

Implements Muon::IMuonSegmentFittingTool.

Definition at line 40 of file MuonSegmentFittingTool.cxx.

40  {
41  return fit(segment.globalPosition(), segment.globalDirection(), segment.associatedSurface(), segment.containedMeasurements());
42  }

◆ initialize()

StatusCode Muon::MuonSegmentFittingTool::initialize ( )
virtual

Definition at line 32 of file MuonSegmentFittingTool.cxx.

32  {
33  ATH_CHECK(m_slPropagator.retrieve());
34  ATH_CHECK(m_slTrackFitter.retrieve());
35  ATH_CHECK(m_curvedTrackFitter.retrieve());
36  ATH_CHECK(m_trackCleaner.retrieve());
37  return StatusCode::SUCCESS;
38  }

◆ inputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::inputHandles ( ) const
overridevirtualinherited

Return this algorithm's input handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ interfaceID()

const InterfaceID & Muon::IMuonSegmentFittingTool::interfaceID ( )
inlinestaticinherited

access to tool interface

Definition at line 47 of file IMuonSegmentFittingTool.h.

47 { return IID_IMuonSegmentFittingTool; }

◆ msg() [1/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( ) const
inlineinherited

Definition at line 24 of file AthCommonMsg.h.

24  {
25  return this->msgStream();
26  }

◆ msg() [2/2]

MsgStream& AthCommonMsg< AlgTool >::msg ( const MSG::Level  lvl) const
inlineinherited

Definition at line 27 of file AthCommonMsg.h.

27  {
28  return this->msgStream(lvl);
29  }

◆ msgLvl()

bool AthCommonMsg< AlgTool >::msgLvl ( const MSG::Level  lvl) const
inlineinherited

Definition at line 30 of file AthCommonMsg.h.

30  {
31  return this->msgLevel(lvl);
32  }

◆ outputHandles()

virtual std::vector<Gaudi::DataHandle*> AthCommonDataStore< AthCommonMsg< AlgTool > >::outputHandles ( ) const
overridevirtualinherited

Return this algorithm's output handles.

We override this to include handle instances from key arrays if they have not yet been declared. See comments on updateVHKA.

◆ renounce()

std::enable_if_t<std::is_void_v<std::result_of_t<decltype(&T::renounce)(T)> > && !std::is_base_of_v<SG::VarHandleKeyArray, T> && std::is_base_of_v<Gaudi::DataHandle, T>, void> AthCommonDataStore< AthCommonMsg< AlgTool > >::renounce ( T &  h)
inlineprotectedinherited

Definition at line 380 of file AthCommonDataStore.h.

381  {
382  h.renounce();
383  PBASE::renounce (h);
384  }

◆ renounceArray()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::renounceArray ( SG::VarHandleKeyArray handlesArray)
inlineprotectedinherited

remove all handles from I/O resolution

Definition at line 364 of file AthCommonDataStore.h.

364  {
365  handlesArray.renounce();
366  }

◆ sysInitialize()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysInitialize ( )
overridevirtualinherited

Perform system initialization for an algorithm.

We override this to declare all the elements of handle key arrays at the end of initialization. See comments on updateVHKA.

Reimplemented in DerivationFramework::CfAthAlgTool, AthCheckedComponent< AthAlgTool >, AthCheckedComponent<::AthAlgTool >, and asg::AsgMetadataTool.

◆ sysStart()

virtual StatusCode AthCommonDataStore< AthCommonMsg< AlgTool > >::sysStart ( )
overridevirtualinherited

Handle START transition.

We override this in order to make sure that conditions handle keys can cache a pointer to the conditions container.

◆ updateSegmentParameters()

void Muon::MuonSegmentFittingTool::updateSegmentParameters ( const Trk::Track track,
const Trk::PlaneSurface surf,
Amg::Vector2D segLocPos,
Trk::LocalDirection segLocDir,
Amg::MatrixX locerr 
) const
virtual

update the parameters of the segment using the track information

Implements Muon::IMuonSegmentFittingTool.

Definition at line 131 of file MuonSegmentFittingTool.cxx.

132  {
133  ATH_MSG_DEBUG(" old segment parameters: pos (" << segLocPos[Trk::locX] << "," << segLocPos[Trk::locY] << ") dir ("
134  << segLocDir.angleXZ() << "," << segLocDir.angleYZ() << ") ");
135 
136  const EventContext& ctx = Gaudi::Hive::currentContext();
137  const Trk::Perigee* pp = track.perigeeParameters();
138  if (!pp) {
139  ATH_MSG_WARNING(" track without perigee ");
140  return;
141  }
142 
143  std::unique_ptr<Trk::TrackParameters> exPars =
144  m_slPropagator->propagate(ctx, *pp, surf, Trk::anyDirection, false, m_magFieldProperties);
145  if (!exPars) {
146  ATH_MSG_WARNING(" extrapolation failed, this should not happen ");
147  return;
148  }
149 
150  Amg::Vector2D lpos{0., 0.};
151  surf.globalToLocal(exPars->position(), exPars->position(), lpos);
152  Trk::LocalDirection ldir;
153  surf.globalToLocalDirection(exPars->momentum().unit(), ldir);
154  ATH_MSG_DEBUG(" new segment parameters: pos (" << lpos[Trk::locX] << "," << lpos[Trk::locY] << ") dir (" << ldir.angleXZ() << ","
155  << ldir.angleYZ() << ") ");
156 
157  segLocPos[Trk::locX] = lpos[Trk::locX];
158  if (m_updatePrecisionCoordinate) segLocPos[Trk::locY] = lpos[Trk::locY];
159  segLocDir = Trk::LocalDirection(ldir.angleXZ(), m_updatePrecisionCoordinate ? ldir.angleYZ() : segLocDir.angleYZ());
160 
161  if (exPars->covariance()) locerr = *exPars->covariance();
162  }

◆ updateVHKA()

void AthCommonDataStore< AthCommonMsg< AlgTool > >::updateVHKA ( Gaudi::Details::PropertyBase &  )
inlineinherited

Definition at line 308 of file AthCommonDataStore.h.

308  {
309  // debug() << "updateVHKA for property " << p.name() << " " << p.toString()
310  // << " size: " << m_vhka.size() << endmsg;
311  for (auto &a : m_vhka) {
312  std::vector<SG::VarHandleKey*> keys = a->keys();
313  for (auto k : keys) {
314  k->setOwner(this);
315  }
316  }
317  }

Member Data Documentation

◆ m_curvedTrackFitter

ToolHandle<Trk::ITrackFitter> Muon::MuonSegmentFittingTool::m_curvedTrackFitter
Initial value:
{
this,
"CurvedFitter",
"Trk::GlobalChi2Fitter/MCTBFitter",
}

Definition at line 69 of file MuonSegmentFittingTool.h.

◆ m_detStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
privateinherited

Pointer to StoreGate (detector store by default)

Definition at line 393 of file AthCommonDataStore.h.

◆ m_evtStore

StoreGateSvc_t AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
privateinherited

Pointer to StoreGate (event store by default)

Definition at line 390 of file AthCommonDataStore.h.

◆ m_magFieldProperties

Trk::MagneticFieldProperties Muon::MuonSegmentFittingTool::m_magFieldProperties

Definition at line 57 of file MuonSegmentFittingTool.h.

◆ m_slPropagator

ToolHandle<Trk::IPropagator> Muon::MuonSegmentFittingTool::m_slPropagator
Initial value:
{
this,
"SLPropagator",
"Trk::RungeKuttaPropagator/AtlasRungeKuttaPropagator",
}

Definition at line 59 of file MuonSegmentFittingTool.h.

◆ m_slTrackFitter

ToolHandle<Trk::ITrackFitter> Muon::MuonSegmentFittingTool::m_slTrackFitter
Initial value:
{
this,
"SLFitter",
"Trk::GlobalChi2Fitter/MCTBSLFitter",
}

Definition at line 64 of file MuonSegmentFittingTool.h.

◆ m_trackCleaner

ToolHandle<Muon::IMuonTrackCleaner> Muon::MuonSegmentFittingTool::m_trackCleaner
Initial value:
{
this,
"TrackCleaner",
"Muon::MuonTrackCleaner/MuonTrackCleaner",
}

Definition at line 74 of file MuonSegmentFittingTool.h.

◆ m_updatePrecisionCoordinate

bool Muon::MuonSegmentFittingTool::m_updatePrecisionCoordinate

Definition at line 80 of file MuonSegmentFittingTool.h.

◆ m_varHandleArraysDeclared

bool AthCommonDataStore< AthCommonMsg< AlgTool > >::m_varHandleArraysDeclared
privateinherited

Definition at line 399 of file AthCommonDataStore.h.

◆ m_vhka

std::vector<SG::VarHandleKeyArray*> AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
privateinherited

Definition at line 398 of file AthCommonDataStore.h.


The documentation for this class was generated from the following files:
Muon::MuonSegmentFittingTool::fit
Trk::Track * fit(const Amg::Vector3D &gpos, const Amg::Vector3D &gdir, const Trk::PlaneSurface &surf, const std::vector< const Trk::MeasurementBase * > &rioVec) const
fit segment parameters + hits producing a track
Definition: MuonSegmentFittingTool.cxx:44
Trk::anyDirection
@ anyDirection
Definition: PropDirection.h:22
Trk::PlaneSurface::globalToLocal
virtual bool globalToLocal(const Amg::Vector3D &glob, const Amg::Vector3D &mom, Amg::Vector2D &loc) const override final
Specified for PlaneSurface: GlobalToLocal method without dynamic memory allocation - boolean checks i...
Definition: PlaneSurface.cxx:213
D3PDMakerTestInstan::vec2
std::vector< D3PDTest::MyVec2 > vec2
Definition: D3PDMakerTestDict.h:14
Trk::ParticleSwitcher::particle
constexpr ParticleHypothesis particle[PARTICLEHYPOTHESES]
the array of masses
Definition: ParticleHypothesis.h:76
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
phi
Scalar phi() const
phi method
Definition: AmgMatrixBasePlugin.h:64
Trk::locX
@ locX
Definition: ParamDefs.h:43
Muon::MuonSegmentFittingTool::m_curvedTrackFitter
ToolHandle< Trk::ITrackFitter > m_curvedTrackFitter
Definition: MuonSegmentFittingTool.h:69
Trk::locY
@ locY
local cartesian
Definition: ParamDefs.h:44
Trk::PerigeeSurface
Definition: PerigeeSurface.h:43
Trk::ParametersBase::position
const Amg::Vector3D & position() const
Access method for the position.
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
AthCommonDataStore< AthCommonMsg< AlgTool > >::declareProperty
Gaudi::Details::PropertyBase & declareProperty(Gaudi::Property< T > &t)
Definition: AthCommonDataStore.h:145
Trk::ParametersT
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
Definition: EMErrorDetail.h:25
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:71
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_evtStore
StoreGateSvc_t m_evtStore
Pointer to StoreGate (event store by default)
Definition: AthCommonDataStore.h:390
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_vhka
std::vector< SG::VarHandleKeyArray * > m_vhka
Definition: AthCommonDataStore.h:398
Muon::MuonSegmentFittingTool::m_magFieldProperties
Trk::MagneticFieldProperties m_magFieldProperties
Definition: MuonSegmentFittingTool.h:57
AthCommonMsg< AlgTool >::msgLvl
bool msgLvl(const MSG::Level lvl) const
Definition: AthCommonMsg.h:30
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
SG::VarHandleKeyArray::setOwner
virtual void setOwner(IDataHandleHolder *o)=0
Trk::LocalDirection::angleYZ
double angleYZ() const
access method for angle of local YZ projection
Definition: LocalDirection.h:106
AthCommonDataStore
Definition: AthCommonDataStore.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
beamspotman.n
n
Definition: beamspotman.py:731
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Muon::MuonSegmentFittingTool::m_trackCleaner
ToolHandle< Muon::IMuonTrackCleaner > m_trackCleaner
Definition: MuonSegmentFittingTool.h:74
sign
int sign(int a)
Definition: TRT_StrawNeighbourSvc.h:127
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
Trk::PlaneSurface::globalToLocalDirection
void globalToLocalDirection(const Amg::Vector3D &glodir, Trk::LocalDirection &locdir) const
This method transforms the global direction to a local direction wrt the plane.
Definition: PlaneSurface.cxx:260
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
Trk::LocalDirection
represents the three-dimensional global direction with respect to a planar surface frame.
Definition: LocalDirection.h:81
AthAlgTool::AthAlgTool
AthAlgTool()
Default constructor:
SG::VarHandleKeyArray::renounce
virtual void renounce()=0
SG::HandleClassifier::type
std::conditional< std::is_base_of< SG::VarHandleKeyArray, T >::value, VarHandleKeyArrayType, type2 >::type type
Definition: HandleClassifier.h:54
Trk::MeasurementBase
Definition: MeasurementBase.h:58
Trk::NoField
@ NoField
Field is set to 0., 0., 0.,.
Definition: MagneticFieldMode.h:18
Trk::Track::perigeeParameters
const Perigee * perigeeParameters() const
return Perigee.
Definition: Tracking/TrkEvent/TrkTrack/src/Track.cxx:163
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
Muon::MuonSegmentFittingTool::m_slTrackFitter
ToolHandle< Trk::ITrackFitter > m_slTrackFitter
Definition: MuonSegmentFittingTool.h:64
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
Trk::MeasurementBase::associatedSurface
virtual const Surface & associatedSurface() const =0
Interface method to get the associated Surface.
Muon::MuonSegmentFittingTool::m_slPropagator
ToolHandle< Trk::IPropagator > m_slPropagator
Definition: MuonSegmentFittingTool.h:59
Trk::nonInteracting
@ nonInteracting
Definition: ParticleHypothesis.h:25
charge
double charge(const T &p)
Definition: AtlasPID.h:494
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
Trk::ParametersBase::momentum
const Amg::Vector3D & momentum() const
Access method for the momentum.
a
TList * a
Definition: liststreamerinfos.cxx:10
h
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
DEBUG
#define DEBUG
Definition: page_access.h:11
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:616
declareProperty
#define declareProperty(n, p, h)
Definition: BaseFakeBkgTool.cxx:15
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:790
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
calibdata.copy
bool copy
Definition: calibdata.py:27
Trk::LocalDirection::angleXZ
double angleXZ() const
access method for angle of local XZ projection
Definition: LocalDirection.h:103
Muon::MuonSegmentFittingTool::m_updatePrecisionCoordinate
bool m_updatePrecisionCoordinate
Definition: MuonSegmentFittingTool.h:80
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
fitman.k
k
Definition: fitman.py:528
NSWL1::PadTriggerAdapter::segment
Muon::NSW_PadTriggerSegment segment(const NSWL1::PadTrigger &data)
Definition: PadTriggerAdapter.cxx:5