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

tool to match segments More...

#include <MuonSegmentInOverlapResolvingTool.h>

Inheritance diagram for Muon::MuonSegmentInOverlapResolvingTool:
Collaboration diagram for Muon::MuonSegmentInOverlapResolvingTool:

Public Types

typedef std::vector< const Trk::MeasurementBase * > MeasVec
 
typedef MeasVec::iterator MeasIt
 
typedef MeasVec::const_iterator MeasCit
 

Public Member Functions

 MuonSegmentInOverlapResolvingTool (const std::string &, const std::string &, const IInterface *)
 constructor More...
 
virtual ~MuonSegmentInOverlapResolvingTool ()
 destructor More...
 
StatusCode initialize ()
 AlgTool initilize. More...
 
SegmentMatchResult matchResult (const EventContext &ctx, const MuonSegment &seg1, const MuonSegment &seg2) const
 performance match and return result More...
 
SegmentPositionMatchResult bestPositionAlongTubeMatch (const MuonSegment &seg1, const MuonSegment &seg2, const Amg::Vector3D &segDir1Min) const
 calculate the position along a tube direction of the first segment that results in the smallest position residual in the precision plane of the second segment given the segment direction for segment 1 in global coordinates More...
 
SegmentPhiMatchResult bestPhiMatch (const MuonSegment &seg1, const MuonSegment &seg2) const
 calculate the angle phi for which the angular residual in the precision plane of the second segment is zero More...
 
SegmentPhiMatchResult bestPhiMatchAnalytic (const MuonSegment &seg1, const MuonSegment &seg2) const
 calculate the angle phi for which the angular residual in the precision plane of the second segment is zero More...
 
Amg::Vector3D updateSegmentDirection (const MuonSegment &seg, double phi) const
 recalculate the segment direction give a new angle phi, keeps the angle in the precision plane fixed More...
 
SegmentGeometrySummary segmentGeometrySummary (const MuonSegment &seg) const
 calculate geometrical information for a segment 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...
 

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

double checkPhiHitConsistency (const EventContext &ctx, const Muon::MuonSegment &segment, SegmentPhiMatchResult &phiMatchResult, SegmentPositionMatchResult &matchResult) const
 compare phi hits with segment parameters, return average pull of the phi hits More...
 
Amg::Vector3D estimateSegmentDirection (const MuonSegment &seg1, const MuonSegment &seg2, double &phi, double &stereoangle) const
 
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

ServiceHandle< Muon::IMuonIdHelperSvcm_idHelperSvc
 
ServiceHandle< IMuonEDMHelperSvcm_edmHelperSvc
 EDM Helper tool. More...
 
PublicToolHandle< MuonEDMPrinterToolm_printer
 EDM printer tool. More...
 
ToolHandle< Trk::IPropagatorm_propagator
 
ToolHandle< Trk::IResidualPullCalculatorm_pullCalculator
 
Trk::MagneticFieldProperties m_magFieldProperties
 magnetic field properties More...
 
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

tool to match segments

Definition at line 41 of file MuonSegmentInOverlapResolvingTool.h.

Member Typedef Documentation

◆ MeasCit

typedef MeasVec::const_iterator Muon::IMuonSegmentInOverlapResolvingTool::MeasCit
inherited

Definition at line 34 of file IMuonSegmentInOverlapResolvingTool.h.

◆ MeasIt

typedef MeasVec::iterator Muon::IMuonSegmentInOverlapResolvingTool::MeasIt
inherited

Definition at line 33 of file IMuonSegmentInOverlapResolvingTool.h.

◆ MeasVec

Definition at line 32 of file IMuonSegmentInOverlapResolvingTool.h.

◆ StoreGateSvc_t

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

Definition at line 388 of file AthCommonDataStore.h.

Constructor & Destructor Documentation

◆ MuonSegmentInOverlapResolvingTool()

Muon::MuonSegmentInOverlapResolvingTool::MuonSegmentInOverlapResolvingTool ( const std::string &  ty,
const std::string &  na,
const IInterface *  pa 
)

constructor

Definition at line 20 of file MuonSegmentInOverlapResolvingTool.cxx.

23 {
24  declareInterface<IMuonSegmentInOverlapResolvingTool>(this);
25 }

◆ ~MuonSegmentInOverlapResolvingTool()

virtual Muon::MuonSegmentInOverlapResolvingTool::~MuonSegmentInOverlapResolvingTool ( )
inlinevirtual

destructor

Definition at line 47 of file MuonSegmentInOverlapResolvingTool.h.

47 {};

Member Function Documentation

◆ bestPhiMatch()

MuonSegmentInOverlapResolvingTool::SegmentPhiMatchResult Muon::MuonSegmentInOverlapResolvingTool::bestPhiMatch ( const MuonSegment seg1,
const MuonSegment seg2 
) const
virtual

calculate the angle phi for which the angular residual in the precision plane of the second segment is zero

Implements Muon::IMuonSegmentInOverlapResolvingTool.

Definition at line 275 of file MuonSegmentInOverlapResolvingTool.cxx.

276 {
277 
278  unsigned int nbins = 11;
279  // unsigned int bestBin = 0;
280  double scanRange = 1.;
281  double scanStep = scanRange / (nbins - 1);
282  double phiStart = seg1.globalDirection().phi() - 0.5 * scanRange;
283 
284  double dthetaMin = 1e9;
285  Amg::Vector3D segDir1Min = seg1.globalDirection();
286  Trk::LocalDirection segLocDir2;
287  seg2.associatedSurface().globalToLocalDirection(seg2.globalDirection(), segLocDir2);
288  for (unsigned int i = 0; i < nbins; ++i) {
289  double phi = phiStart + scanStep * i;
290  Amg::Vector3D segDir1 = updateSegmentDirection(seg1, phi);
291  Trk::LocalDirection segLocDir12;
292  seg2.associatedSurface().globalToLocalDirection(segDir1, segLocDir12);
293  double dyz = std::abs(segLocDir12.angleYZ() - segLocDir2.angleYZ());
294  if (dyz < dthetaMin) {
295  dthetaMin = dyz;
296  segDir1Min = segDir1;
297  // bestBin = i;
298  }
299  }
300  return {segDir1Min, updateSegmentDirection(seg2, segDir1Min.phi()), dthetaMin};
301 }

◆ bestPhiMatchAnalytic()

MuonSegmentInOverlapResolvingTool::SegmentPhiMatchResult Muon::MuonSegmentInOverlapResolvingTool::bestPhiMatchAnalytic ( const MuonSegment seg1,
const MuonSegment seg2 
) const

calculate the angle phi for which the angular residual in the precision plane of the second segment is zero

Definition at line 194 of file MuonSegmentInOverlapResolvingTool.cxx.

195 {
196 
197  //
198  // From two segments the direction and position of the segments are determined
199  // assuming a straight line
200  //
201  // if a stereoangle is present one can determine: phi and x local for both segments
202  //
203 
204  // bool check = false;
205 
206  // Confusing use of objects:
207  // Trk::GlobalDirection can and will hold a 3D LOCAL direction
208  // Trk::GlobalPositionn can and will hold a 3D LOCAL position
209  // This is needed because otherwise the Amg::Transform3D DOES NOT know
210  // whether it transforms a position or a direction
211  //
212  const Amg::Transform3D& gToGlobal1 = seg1.associatedSurface().transform();
213  const Amg::Transform3D& gToGlobal2 = seg2.associatedSurface().transform();
214  Amg::Transform3D gToLocal1 = seg1.associatedSurface().transform().inverse();
215  // Amg::Transform3D gToLocal2 = seg2.associatedSurface().transform().inverse();
216  //
217  const Amg::Vector3D& gDir1 = seg1.globalDirection();
218  const Amg::Vector3D& gDir2 = seg2.globalDirection();
219  // Confusing but Amg::Vector3D can hold a 3D local direction
220  Amg::Vector3D lDir1 = gToLocal1.linear() * gDir1;
221  // Amg::Vector3D lDir2 = gToLocal2.linear()*gDir2;
222  // segment 2 local direction in frame of segment 1
223  Amg::Vector3D lDir12 = gToLocal1.linear() * gDir2;
224  // Amg::Vector3D lDir21 = gToLocal2.linear()*gDir1;
225 
226  Amg::Vector3D segLocDiro(1., 0., 0.);
227  // orthogonal vector to segment 2 in local frame of segment 1
228  Amg::Vector3D lDiro12 = gToLocal1.linear() * (gToGlobal2.linear() * segLocDiro);
229  // orthogonal vector to segment 1in local frame of segment 2
230  // Amg::Vector3D lDiro21 = gToLocal2.linear()*(gToGlobal1.linear()*segLocDiro);
231 
232  // stereoangle = acos(lDiro12.x());
233 
234  // We have the following equations for segment 2 in local frame of segment 1
235  // dx1 = free
236  // dy1 = lDir1.y() = a * lDir12.y() + b * lDiro12.y()
237  // dz1 = lDir1.z() = a * lDir12.z() + b * lDiro12.z()
238 
239  double b = lDir1.y() * lDir12.z() - lDir1.z() * lDir12.y();
240  double a = lDir1.y() * lDiro12.z() - lDir1.z() * lDiro12.y();
241  double dxn = lDir12.x();
242  double dyn = lDir12.y();
243  double dzn = lDir12.z();
244  if (std::abs(a) > 1e-2) {
245  dxn = lDir12.x() - b * lDiro12.x() / a;
246  dyn = lDir12.y() - b * lDiro12.y() / a;
247  dzn = lDir12.z() - b * lDiro12.z() / a;
248  }
249  double norm = std::hypot(dxn, dyn, dzn);
250  if (norm < 1e-6) {
251  ATH_MSG_DEBUG(" Unexpected normalisation " << norm);
252  norm = 1e-6;
253  }
254  if (dxn * lDir1.x() + dyn * lDir1.y() + dzn * lDir1.z() < 0) norm = -norm;
255  dxn = dxn / norm;
256  dyn = dyn / norm;
257  dzn = dzn / norm;
258 
259  // The final result for the direction of the two segments
260 
261  // New Local direction of segment 1
262  Amg::Vector3D lDirn1(dxn, dyn, dzn);
263  // Global direction of both segments
264  Amg::Vector3D segDir1Min = gToGlobal1.linear() * lDirn1;
265  const Amg::Vector3D& segDir2Min = segDir1Min; // updateSegmentDirection(seg2,segDir1Min.phi());
266  Trk::LocalDirection segLocDir1;
267  seg2.associatedSurface().globalToLocalDirection(segDir1Min, segLocDir1);
268  Trk::LocalDirection segLocDir2;
269  seg2.associatedSurface().globalToLocalDirection(segDir2Min, segLocDir2);
270  double dyz = std::abs(segLocDir1.angleYZ() - segLocDir2.angleYZ());
271  return {segDir1Min, segDir2Min, dyz};
272 }

◆ bestPositionAlongTubeMatch()

MuonSegmentInOverlapResolvingTool::SegmentPositionMatchResult Muon::MuonSegmentInOverlapResolvingTool::bestPositionAlongTubeMatch ( const MuonSegment seg1,
const MuonSegment seg2,
const Amg::Vector3D segDir1Min 
) const
virtual

calculate the position along a tube direction of the first segment that results in the smallest position residual in the precision plane of the second segment given the segment direction for segment 1 in global coordinates

Implements Muon::IMuonSegmentInOverlapResolvingTool.

Definition at line 305 of file MuonSegmentInOverlapResolvingTool.cxx.

307 {
308  bool goodMatch = true;
309 
310  // get geomtry summary for segment
311  SegmentGeometrySummary segmentGeometry = segmentGeometrySummary(seg1);
312  SegmentGeometrySummary segmentGeometry2 = segmentGeometrySummary(seg2);
313 
314  int nbins = 2;
315  double tubeStep = segmentGeometry.hvPosInSegFrame - segmentGeometry.roPosInSegFrame;
316 
317  double posStep = tubeStep / (nbins - 1);
318 
319  double resfirst{1e9}, reslast{1e9}, posfirst{1e9}, poslast{1e9};
320  double locy = seg1.localParameters().contains(Trk::locY) ? seg1.localParameters()[Trk::locY] : 0.;
321 
322  for (int j = 0; j < nbins; ++j) {
323  double distToRO = segmentGeometry.roPosInSegFrame + posStep * j;
324 
325  // create local position
326  Amg::Vector2D lpos(distToRO, locy);
327 
328  // segment reference surface
329  const Trk::PlaneSurface& segmentSurface = seg2.associatedSurface();
330 
331  // get global position
332  Amg::Vector3D gpos;
333  seg1.associatedSurface().localToGlobal(lpos, segDir1Min, gpos);
334 
335  // calculate intersection
336  Trk::Intersection intersect = segmentSurface.straightLineIntersection(gpos, segDir1Min, false, false);
337  if (!intersect.valid || !segmentSurface.globalToLocal(intersect.position, segDir1Min, lpos)) {
338  // if( !intersect.valid || !segmentSurface.globalToLocal(intersect.intersection,segDir1Min,lpos) ){
339  ATH_MSG_WARNING(" Intersect with surface position " << Amg::toString(gpos) << " direction: phi "
340  << segDir1Min.phi() << " theta "
341  << segDir1Min.theta());
342  } else {
343 
344  // now we have the prediction of the track in the segment frame, lets look at residuals
345  double resy = lpos[Trk::locY] - seg2.localParameters()[Trk::locY];
346 
347  if (j == 0) {
348  resfirst = resy;
349  posfirst = distToRO;
350  }
351  if (j == nbins - 1) {
352  reslast = resy;
353  poslast = distToRO;
354  }
355  }
356  }
357 
358  double distPosMin2{1e9}, distPosInTube2{1e9}, distPosMin{1e9}, distPosInTube{1e9}, resyMin{1e9};
359  Amg::Vector3D segPos(0., 0., 0.);
360  double rangeCut = 1e5;
361  if (resfirst < rangeCut && reslast < rangeCut && posfirst < rangeCut && poslast < rangeCut) {
362  double resDif = reslast - resfirst;
363  double posDif = poslast - posfirst;
364  if (std::abs(resDif) < 1e-6) {
365  ATH_MSG_DEBUG(" Unexpected residual difference " << resDif);
366  resDif = resDif < 0. ? -1e-6 : 1e-6;
367  }
368  if (std::abs(posDif) < 1e-6) {
369  ATH_MSG_DEBUG(" Unexpected position difference " << posDif);
370  posDif = posDif < 0. ? -1e-6 : 1e-6;
371  }
372  distPosMin = posfirst - resfirst / (resDif) * (posDif);
373  distPosInTube = segmentGeometry.positionInsideTube(distPosMin);
374  resyMin = resfirst + (resDif) * (distPosInTube - posfirst) / (posDif);
375 
376  double locx = distPosInTube;
377  double locy = seg1.localParameters().contains(Trk::locY) ? seg1.localParameters()[Trk::locY] : 0.;
378 
379  // create local position
380  Amg::Vector2D lpos(locx, locy);
381 
382  // segment reference surface
383  const Trk::PlaneSurface& segmentSurface = seg2.associatedSurface();
384 
385  // get global position
386  Amg::Vector3D gpos;
387  seg1.associatedSurface().localToGlobal(lpos, segDir1Min, gpos);
388  segPos = gpos;
389 
390  // calculate intersection
391  Trk::Intersection intersect = segmentSurface.straightLineIntersection(gpos, segDir1Min, false, false);
392  if (!intersect.valid) {
393  ATH_MSG_WARNING(" Intersect with surface position " << Amg::toString(gpos) << " direction: phi "
394  << segDir1Min.phi() << " theta "
395  << segDir1Min.theta());
396  goodMatch = false;
397  } else {
398  Amg::Vector3D locExSeg2 = segmentGeometry2.globalToSeg * intersect.position;
399  distPosMin2 = locExSeg2.x();
400  distPosInTube2 = segmentGeometry2.positionInsideTube(distPosMin2);
401  }
402 
403  } else {
404  goodMatch = false;
405  }
406 
407  return {distPosMin, distPosInTube, segmentGeometry.shortestChannelLength, distPosMin2,
408  distPosInTube2, segmentGeometry2.shortestChannelLength, resyMin, goodMatch,
409  segPos};
410 }

◆ checkPhiHitConsistency()

double Muon::MuonSegmentInOverlapResolvingTool::checkPhiHitConsistency ( const EventContext &  ctx,
const Muon::MuonSegment segment,
SegmentPhiMatchResult phiMatchResult,
SegmentPositionMatchResult matchResult 
) const
private

compare phi hits with segment parameters, return average pull of the phi hits

Definition at line 492 of file MuonSegmentInOverlapResolvingTool.cxx.

495 {
496 
497  // calculate average pull of phi measurements
498  unsigned int nphiMeas = 0;
499  double averagePull = 0.;
500 
501  // calculate segment AtaPlane
502  // SegmentGeometrySummary geometry = segmentGeometrySummary( segment );
503  double locx = posMatchResult.positionInTube1;
504  double locy = segment.localParameters().contains(Trk::locY) ? segment.localParameters()[Trk::locY] : 0.;
505  Trk::AtaPlane segPars(locx, locy, phiMatchResult.segmentDirection1.phi(), phiMatchResult.segmentDirection1.theta(),
506  0., segment.associatedSurface());
507 
508  // loop over hits and calculate residuals for phi hits
509  for (const Trk::MeasurementBase* meas : segment.containedMeasurements()) {
510 
511  Identifier id = m_edmHelperSvc->getIdentifier(*meas);
512  if (!id.is_valid() || !m_idHelperSvc->measuresPhi(id)) continue;
513 
514  // predict onto segment surface
515  const Trk::Surface& measSurf = meas->associatedSurface();
516 
517  // propagate station parameters to segment
518  std::unique_ptr<const Trk::TrackParameters> exPars {
519  m_propagator->propagate(
520  ctx,
521  segPars,
522  measSurf,
524  false,
526  if (!exPars) {
527  ATH_MSG_WARNING(" Failed to propagate parameter to segment surface" << std::endl
528  << " pars "
529  << m_printer->print(segPars));
530  continue;
531  }
532 
533  std::optional<Trk::ResidualPull> resPull { m_pullCalculator->residualPull(meas, exPars.get(), Trk::ResidualPull::Unbiased)};
534  if (!resPull) {
535  ATH_MSG_DEBUG(" calculation of residual/pull failed !!!!! ");
536  continue;
537  }
538 
539  // sanity check
540  if (resPull->pull().size() != 1) {
541  ATH_MSG_WARNING(" ResidualPull with empty pull vector for channel " << m_idHelperSvc->toString(id));
542  continue;
543  }
544  const double pull = resPull->pull().front();
545  averagePull += pull;
546  ++nphiMeas;
547 
548  }
549  if (nphiMeas != 0) averagePull /= nphiMeas;
550  return averagePull;
551 }

◆ 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; }

◆ estimateSegmentDirection()

Amg::Vector3D Muon::MuonSegmentInOverlapResolvingTool::estimateSegmentDirection ( const MuonSegment seg1,
const MuonSegment seg2,
double &  phi,
double &  stereoangle 
) const
private

Definition at line 69 of file MuonSegmentInOverlapResolvingTool.cxx.

71 {
72  //
73  // From two segments the direction and position of the segments are determined
74  // assuming a straight line
75  //
76  // if a stereoangle is present one can determine: phi and x local for both segments
77  //
78 
79  // bool check = false;
80 
81  // Confusing use of objects:
82  // This is needed because otherwise the Transform3D DOES NOT know
83  // whether it transforms a position or a direction
84  //
85  const Amg::Transform3D& gToGlobal1 = seg1.associatedSurface().transform();
86  const Amg::Transform3D& gToGlobal2 = seg2.associatedSurface().transform();
87  Amg::Transform3D gToLocal1 = seg1.associatedSurface().transform().inverse();
88  Amg::Transform3D gToLocal2 = seg2.associatedSurface().transform().inverse();
89  //
90  const Amg::Vector3D& gDir1 = seg1.globalDirection();
91  const Amg::Vector3D& gDir2 = seg2.globalDirection();
92  // Confusing but Amg::Vector3D can hold a 3D local direction
93  Amg::Vector3D lDir1 = gToLocal1.linear() * gDir1;
94  // Amg::Vector3D lDir2 = gToLocal2.linear()*gDir2;
95  // segment 2 local direction in frame of segment 1
96  Amg::Vector3D lDir12 = gToLocal1.linear() * gDir2;
97  // Amg::Vector3D lDir21 = gToLocal2.linear()*gDir1;
98 
99  Amg::Vector3D segLocDiro(1., 0., 0.);
100  // orthogonal vector to segment 2 in local frame of segment 1
101  Amg::Vector3D lDiro12 = gToLocal1.linear() * (gToGlobal2.linear() * segLocDiro);
102  // orthogonal vector to segment 1in local frame of segment 2
103  Amg::Vector3D lDiro21 = gToLocal2.linear() * (gToGlobal1.linear() * segLocDiro);
104 
105  stereoangle = std::acos(lDiro12.x());
106 
107  // We have the following equations for segment 2 in local frame of segment 1
108  // dx1 = free
109  // dy1 = lDir1.y() = a * lDir12.y() + b * lDiro12.y()
110  // dz1 = lDir1.z() = a * lDir12.z() + b * lDiro12.z()
111 
112  double b = lDir1.y() * lDir12.z() - lDir1.z() * lDir12.y();
113  double a = lDir1.y() * lDiro12.z() - lDir1.z() * lDiro12.y();
114  double dxn = lDir12.x();
115  double dyn = lDir12.y();
116  double dzn = lDir12.z();
117  if (std::abs(a) > 1e-2) {
118  dxn = lDir12.x() - b * lDiro12.x() / a;
119  dyn = lDir12.y() - b * lDiro12.y() / a;
120  dzn = lDir12.z() - b * lDiro12.z() / a;
121  }
122  double norm = std::hypot(dxn, dyn, dzn);
123  if (norm < 1e-6) {
124  ATH_MSG_DEBUG(" Unexpected normalisation " << norm);
125  norm = 1e-6;
126  }
127  if (dxn * lDir1.x() + dyn * lDir1.y() + dzn * lDir1.z() < 0) norm = -norm;
128  dxn = dxn / norm;
129  dyn = dyn / norm;
130  dzn = dzn / norm;
131 
132  // The final result for the direction of the two segments
133 
134  // New Local direction of segment 1
135  Amg::Vector3D lDirn1(dxn, dyn, dzn);
136  // Global direction of both segments
137  Amg::Vector3D gDirn = gToGlobal1.linear() * lDirn1;
138  // New Local direction of segment 2
139  Amg::Vector3D lDirn2 = gToLocal2.linear() * gDirn;
140  phi = gDirn.phi();
141  double theta = gDirn.theta();
142 
143  const Amg::Vector3D& gPos1 = seg1.globalPosition();
144  // Confusing but Amg::Vector3D can hold a 3D local position
145  Amg::Vector3D lPos1 = gToLocal1 * gPos1;
146  Amg::Vector3D lPos21 = gToLocal2 * gPos1;
147  const Amg::Vector3D& gPos2 = seg2.globalPosition();
148  Amg::Vector3D lPos12 = gToLocal1 * gPos2;
149  Amg::Vector3D lPos2 = gToLocal2 * gPos2;
150  // In local frame of segment 2 shift segment 1 to obtain zero residual
151  double res21 = (lPos2.y() - lPos21.y()) * lDirn2.z() - (lPos2.z() - lPos21.z()) * lDirn2.y();
152  double localx1 = 0.;
153  double step = (lDiro21.y() * lDirn2.z() - lDiro21.z() * lDirn2.y());
154  if (std::abs(step) > 1e-5) {
155  localx1 = res21 / step;
156  }
157  ATH_MSG_DEBUG(" localx1 " << localx1 << " res21 " << res21 << " step " << step);
158 
159  // Result: New local and global position of segment 1
160  Amg::Vector3D lPosn1(lPos1.x() + localx1, lPos1.y(), lPos1.z());
161  Amg::Vector3D gPosn1 = gToGlobal1 * lPosn1;
162  // In local frame of segment 1 shift segment 2 to obtain zero residual
163  double res12 = (lPos1.y() - lPos12.y()) * lDirn1.z() - (lPos1.z() - lPos12.z()) * lDirn1.y();
164  step = (lDiro12.y() * lDirn1.z() - lDiro12.z() * lDirn1.y());
165  double localx2 = 0.;
166  if (std::abs(step) > 1e-5) {
167  localx2 = res12 / step;
168  }
169  ATH_MSG_DEBUG(" localx2 " << localx2 << " res12 " << res12 << " step " << step);
170 
171  // Result: New local and global position of segment 2
172  Amg::Vector3D lPosn2(lPos2.x() + localx2, lPos2.y(), lPos2.z());
173  Amg::Vector3D gPosn2 = gToGlobal2 * lPosn2;
174  ATH_MSG_DEBUG(" segment 1 local position "
175  << lPos1 << " new " << lPosn1 << std::endl
176  << " segment 1 global position " << gPos1 << " new " << gPosn1 << std::endl
177  << " segment 2 local position " << lPos2 << " new " << lPosn2 << std::endl
178  << " segment 2 global position " << gPos2 << " new " << gPosn2);
179 
180  // This gives the direction from the position of the segments
181  Amg::Vector3D gDirPos = gPosn2 - gPosn1;
182  if (gDir1.x() * gDirPos.x() + gDir1.y() * gDirPos.y() + gDir1.z() * gDirPos.z() < 0) {
183  gDirPos = -gPosn2 + gPosn1;
184  }
185  double dtheta = theta - gDirPos.theta();
186  double dphi = phi - gDirPos.phi();
187  ATH_MSG_DEBUG(" theta " << theta << " gDirPos theta " << gDirPos.theta() << " dtheta " << dtheta << " phi " << phi
188  << " gDirPos phi " << gDirPos.phi() << " dphi " << dphi);
189  return gDirn;
190 }

◆ 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

◆ initialize()

StatusCode Muon::MuonSegmentInOverlapResolvingTool::initialize ( )

AlgTool initilize.

Definition at line 28 of file MuonSegmentInOverlapResolvingTool.cxx.

29 {
31 
32  ATH_CHECK(m_edmHelperSvc.retrieve());
33  ATH_CHECK(m_printer.retrieve());
34  ATH_CHECK(m_idHelperSvc.retrieve());
35  ATH_CHECK(m_propagator.retrieve());
36  ATH_CHECK(m_pullCalculator.retrieve());
37 
38  return StatusCode::SUCCESS;
39 }

◆ 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()

static const InterfaceID& Muon::IMuonSegmentInOverlapResolvingTool::interfaceID ( )
inlinestaticinherited

access to tool interface

Definition at line 150 of file IMuonSegmentInOverlapResolvingTool.h.

150  {
151  static const InterfaceID IID_IMuonSegmentInOverlapResolvingTool("Muon::IMuonSegmentInOverlapResolvingTool", 1, 0);
152  return IID_IMuonSegmentInOverlapResolvingTool;
153  }

◆ matchResult()

MuonSegmentInOverlapResolvingTool::SegmentMatchResult Muon::MuonSegmentInOverlapResolvingTool::matchResult ( const EventContext &  ctx,
const MuonSegment seg1,
const MuonSegment seg2 
) const
virtual

performance match and return result

Implements Muon::IMuonSegmentInOverlapResolvingTool.

Definition at line 456 of file MuonSegmentInOverlapResolvingTool.cxx.

457 {
458 
459  ATH_MSG_DEBUG(" First segment " << m_printer->print(seg1) << std::endl
460  << " Second segment " << m_printer->print(seg2));
461  SegmentMatchResult result = SegmentMatchResult();
462 
463  // calculate the phi angle that matches the two local segment angles
464  result.phiResult = bestPhiMatchAnalytic(seg1, seg2);
465 
466  // calculate the position along the tube that minimizes the position residual for both segments
467  result.segmentResult1 = bestPositionAlongTubeMatch(seg1, seg2, result.phiResult.segmentDirection1);
468  result.segmentResult2 = bestPositionAlongTubeMatch(seg2, seg1, result.phiResult.segmentDirection2);
469 
470  // calculate the average pull of the phi hits on the segments with the new parameters
471  result.averagePhiHitPullSegment1 = checkPhiHitConsistency(ctx, seg1, result.phiResult, result.segmentResult1);
472  result.averagePhiHitPullSegment2 = checkPhiHitConsistency(ctx, seg2, result.phiResult, result.segmentResult2);
473 
474  if (result.segmentResult1.goodMatch && result.segmentResult2.goodMatch) {
475 
476  // calculate vector connecting the two new segment positions
477  Amg::Vector3D difPos = result.segmentResult2.segmentPosition - result.segmentResult1.segmentPosition;
478 
479  // check if vectors are pointing in the same direction, else flip
480  if (result.phiResult.segmentDirection1.y() * difPos.y() < 0.) {
481  difPos *= -1.;
482  }
483 
484  // calculate difference in angle between phi from phi match and the two new segment positions
485  result.angularDifferencePhi = difPos.deltaPhi(result.phiResult.segmentDirection1);
486  }
487  return result;
488 }

◆ 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  }

◆ segmentGeometrySummary()

MuonSegmentInOverlapResolvingTool::SegmentGeometrySummary Muon::MuonSegmentInOverlapResolvingTool::segmentGeometrySummary ( const MuonSegment seg) const
virtual

calculate geometrical information for a segment

Implements Muon::IMuonSegmentInOverlapResolvingTool.

Definition at line 414 of file MuonSegmentInOverlapResolvingTool.cxx.

415 {
416 
417  SegmentGeometrySummary summary;
418  // loop over hits
419  Identifier tubeId1;
420  const MuonGM::MdtReadoutElement* detEl = nullptr;
421  double shortestTubeLen = 1e9;
422  Amg::Vector3D roPos;
423  Amg::Vector3D tubeCenter;
424  bool hasMdt = false;
425  for (const Trk::MeasurementBase* meas :seg.containedMeasurements()) {
426 
427  const MdtDriftCircleOnTrack* mdt = dynamic_cast<const MdtDriftCircleOnTrack*>(meas);
428  if (mdt) {
429  hasMdt = true;
430  const Identifier& id = mdt->identify();
431  int layer = m_idHelperSvc->mdtIdHelper().tubeLayer(id);
432  int tube = m_idHelperSvc->mdtIdHelper().tube(id);
433  double tubelen = mdt->prepRawData()->detectorElement()->getActiveTubeLength(layer, tube);
434  if (tubelen < shortestTubeLen) {
435  shortestTubeLen = tubelen;
436  roPos = mdt->prepRawData()->detectorElement()->ROPos(id);
437  tubeCenter = mdt->prepRawData()->detectorElement()->surface(id).center();
438  detEl = mdt->prepRawData()->detectorElement();
439  tubeId1 = id;
440  }
441  }
442  }
443  summary.detEl = detEl;
444  summary.hasMdt = hasMdt;
445  summary.segToGlobal = seg.associatedSurface().transform();
446  summary.globalToSeg = summary.segToGlobal.inverse();
447  summary.roPosInSegFrame = (summary.globalToSeg * roPos).x();
448  double distTubeCenterFromRO = (summary.globalToSeg * tubeCenter).x() - summary.roPosInSegFrame;
449  summary.hvPosInSegFrame = summary.roPosInSegFrame + 2 * distTubeCenterFromRO;
450  summary.shortestChannelLength = std::abs(2 * distTubeCenterFromRO);
451 
452  return summary;
453 }

◆ 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.

◆ updateSegmentDirection()

Amg::Vector3D Muon::MuonSegmentInOverlapResolvingTool::updateSegmentDirection ( const MuonSegment seg,
double  phi 
) const
virtual

recalculate the segment direction give a new angle phi, keeps the angle in the precision plane fixed

Implements Muon::IMuonSegmentInOverlapResolvingTool.

Definition at line 42 of file MuonSegmentInOverlapResolvingTool.cxx.

43 {
44 
45  Amg::Transform3D gToStation = seg.associatedSurface().transform().inverse();
46  Amg::Vector3D phiDir(1., 0., 0.);
47  Amg::setThetaPhi(phiDir, seg.globalDirection().theta(), phi);
48  Amg::Vector3D lphiDir = gToStation.linear() * phiDir;
49  Amg::Vector3D lsegDir = gToStation.linear() * seg.globalDirection();
50  double road_dz = lphiDir.z();
51  double seg_dy = lsegDir.y();
52  double seg_dz = lsegDir.z();
53  if (road_dz * seg_dz < 0) {
54  seg_dy *= -1.;
55  seg_dz *= -1.;
56  }
57  if (std::abs(seg_dz) < 1e-6) {
58  seg_dz = 1e-6;
59  ATH_MSG_DEBUG(" Unexpected local direction of segment " << lsegDir);
60  }
61  double scale = road_dz / seg_dz;
62  seg_dy *= scale;
63  Amg::Vector3D locDir(lphiDir.x(), seg_dy, road_dz);
64  Amg::Vector3D gDir = seg.associatedSurface().transform().linear() * locDir;
65  return gDir;
66 }

◆ 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_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_edmHelperSvc

ServiceHandle<IMuonEDMHelperSvc> Muon::MuonSegmentInOverlapResolvingTool::m_edmHelperSvc
private
Initial value:
{
this,
"edmHelper",
"Muon::MuonEDMHelperSvc/MuonEDMHelperSvc",
"Handle to the service providing the IMuonEDMHelperSvc interface",
}

EDM Helper tool.

Definition at line 88 of file MuonSegmentInOverlapResolvingTool.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_idHelperSvc

ServiceHandle<Muon::IMuonIdHelperSvc> Muon::MuonSegmentInOverlapResolvingTool::m_idHelperSvc
private
Initial value:
{
this,
"MuonIdHelperSvc",
"Muon::MuonIdHelperSvc/MuonIdHelperSvc",
}

Definition at line 83 of file MuonSegmentInOverlapResolvingTool.h.

◆ m_magFieldProperties

Trk::MagneticFieldProperties Muon::MuonSegmentInOverlapResolvingTool::m_magFieldProperties
private

magnetic field properties

Definition at line 111 of file MuonSegmentInOverlapResolvingTool.h.

◆ m_printer

PublicToolHandle<MuonEDMPrinterTool> Muon::MuonSegmentInOverlapResolvingTool::m_printer
private
Initial value:
{
this,
"Printer",
"Muon::MuonEDMPrinterTool/MuonEDMPrinterTool",
}

EDM printer tool.

Definition at line 95 of file MuonSegmentInOverlapResolvingTool.h.

◆ m_propagator

ToolHandle<Trk::IPropagator> Muon::MuonSegmentInOverlapResolvingTool::m_propagator
private
Initial value:
{
this,
"AtlasRungeKuttaPropagator",
"Trk::RungeKuttaPropagator/AtlasRungeKuttaPropagator",
}

Definition at line 100 of file MuonSegmentInOverlapResolvingTool.h.

◆ m_pullCalculator

ToolHandle<Trk::IResidualPullCalculator> Muon::MuonSegmentInOverlapResolvingTool::m_pullCalculator
private
Initial value:
{
this,
"ResidualPullCalculator",
"Trk::ResidualPullCalculator/ResidualPullCalculator",
}

Definition at line 105 of file MuonSegmentInOverlapResolvingTool.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:
Trk::anyDirection
@ anyDirection
Definition: PropDirection.h:22
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
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
PlotCalibFromCool.norm
norm
Definition: PlotCalibFromCool.py:100
Muon::MuonSegmentInOverlapResolvingTool::checkPhiHitConsistency
double checkPhiHitConsistency(const EventContext &ctx, const Muon::MuonSegment &segment, SegmentPhiMatchResult &phiMatchResult, SegmentPositionMatchResult &matchResult) const
compare phi hits with segment parameters, return average pull of the phi hits
Definition: MuonSegmentInOverlapResolvingTool.cxx:492
Muon::MuonSegmentInOverlapResolvingTool::m_printer
PublicToolHandle< MuonEDMPrinterTool > m_printer
EDM printer tool.
Definition: MuonSegmentInOverlapResolvingTool.h:95
Trk::Intersection
Definition: Intersection.h:24
get_generator_info.result
result
Definition: get_generator_info.py:21
Trk::locY
@ locY
local cartesian
Definition: ParamDefs.h:38
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
Muon::MuonSegmentInOverlapResolvingTool::m_propagator
ToolHandle< Trk::IPropagator > m_propagator
Definition: MuonSegmentInOverlapResolvingTool.h:100
AthCommonDataStore::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
initialize
void initialize()
Definition: run_EoverP.cxx:894
Trk::ResidualPull::Unbiased
@ Unbiased
RP with track state that has measurement not included.
Definition: ResidualPull.h:57
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::MuonSegmentInOverlapResolvingTool::m_edmHelperSvc
ServiceHandle< IMuonEDMHelperSvc > m_edmHelperSvc
EDM Helper tool.
Definition: MuonSegmentInOverlapResolvingTool.h:88
read_hist_ntuple.t
t
Definition: read_hist_ntuple.py:5
yodamerge_tmp.scale
scale
Definition: yodamerge_tmp.py:138
x
#define x
Muon::MuonSegmentInOverlapResolvingTool::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonSegmentInOverlapResolvingTool.h:83
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
IDTPMcnv.htype
htype
Definition: IDTPMcnv.py:29
xAOD::phi
setEt phi
Definition: TrigEMCluster_v1.cxx:29
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
AthCommonDataStore
Definition: AthCommonDataStore.h:52
Amg::toString
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
Definition: GeoPrimitivesToStringConverter.h:40
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
Muon::MuonSegmentInOverlapResolvingTool::m_magFieldProperties
Trk::MagneticFieldProperties m_magFieldProperties
magnetic field properties
Definition: MuonSegmentInOverlapResolvingTool.h:111
MuonGM::MdtReadoutElement
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MdtReadoutElement.h:51
lumiFormat.i
int i
Definition: lumiFormat.py:85
Muon::MuonSegmentInOverlapResolvingTool::updateSegmentDirection
Amg::Vector3D updateSegmentDirection(const MuonSegment &seg, double phi) const
recalculate the segment direction give a new angle phi, keeps the angle in the precision plane fixed
Definition: MuonSegmentInOverlapResolvingTool.cxx:42
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
Muon::MuonSegmentInOverlapResolvingTool::bestPositionAlongTubeMatch
SegmentPositionMatchResult bestPositionAlongTubeMatch(const MuonSegment &seg1, const MuonSegment &seg2, const Amg::Vector3D &segDir1Min) const
calculate the position along a tube direction of the first segment that results in the smallest posit...
Definition: MuonSegmentInOverlapResolvingTool.cxx:305
python.StandardJetMods.pull
pull
Definition: StandardJetMods.py:282
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
AthCommonDataStore< AthCommonMsg< AlgTool > >::m_detStore
StoreGateSvc_t m_detStore
Pointer to StoreGate (detector store by default)
Definition: AthCommonDataStore.h:393
jobOption.theta
theta
Definition: jobOption.ParticleGun_fwd_sequence.py:13
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
merge_scale_histograms.doc
string doc
Definition: merge_scale_histograms.py:9
id
SG::auxid_t id
Definition: Control/AthContainers/Root/debug.cxx:227
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
plotBeamSpotMon.b
b
Definition: plotBeamSpotMon.py:77
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
Trk::PlaneSurface::straightLineIntersection
virtual Intersection straightLineIntersection(const Amg::Vector3D &pos, const Amg::Vector3D &dir, bool forceDir, Trk::BoundaryCheck bchk) const override final
fast straight line intersection schema - standard: provides closest intersection and (signed) path le...
Definition: PlaneSurface.cxx:223
SCT_CalibAlgs::nbins
@ nbins
Definition: SCT_CalibNumbers.h:10
python.copyTCTOutput.locDir
locDir
Definition: copyTCTOutput.py:113
a
TList * a
Definition: liststreamerinfos.cxx:10
Muon::MuonSegmentInOverlapResolvingTool::m_pullCalculator
ToolHandle< Trk::IResidualPullCalculator > m_pullCalculator
Definition: MuonSegmentInOverlapResolvingTool.h:105
h
Amg::intersect
std::optional< double > intersect(const AmgVector(N)&posA, const AmgVector(N)&dirA, const AmgVector(N)&posB, const AmgVector(N)&dirB)
Calculates the point B' along the line B that's closest to a second line A.
Definition: GeoPrimitivesHelpers.h:347
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
Trk::PlaneSurface
Definition: PlaneSurface.h:64
SG::VarHandleBase::vhKey
SG::VarHandleKey & vhKey()
Return a non-const reference to the HandleKey.
Definition: StoreGate/src/VarHandleBase.cxx:623
LArCellBinning.step
step
Definition: LArCellBinning.py:158
python.Bindings.keys
keys
Definition: Control/AthenaPython/python/Bindings.py:798
Muon::MuonSegmentInOverlapResolvingTool::bestPhiMatchAnalytic
SegmentPhiMatchResult bestPhiMatchAnalytic(const MuonSegment &seg1, const MuonSegment &seg2) const
calculate the angle phi for which the angular residual in the precision plane of the second segment i...
Definition: MuonSegmentInOverlapResolvingTool.cxx:194
Trk::PlaneSurface::localToGlobal
virtual void localToGlobal(const Amg::Vector2D &locp, const Amg::Vector3D &mom, Amg::Vector3D &glob) const override final
Specified for PlaneSurface: LocalToGlobal method without dynamic memory allocation.
Definition: PlaneSurface.cxx:204
Muon::MuonSegmentInOverlapResolvingTool::segmentGeometrySummary
SegmentGeometrySummary segmentGeometrySummary(const MuonSegment &seg) const
calculate geometrical information for a segment
Definition: MuonSegmentInOverlapResolvingTool.cxx:414
Trk::Surface
Definition: Tracking/TrkDetDescr/TrkSurfaces/TrkSurfaces/Surface.h:75
AthCommonDataStore::declareGaudiProperty
Gaudi::Details::PropertyBase & declareGaudiProperty(Gaudi::Property< T > &hndl, const SG::VarHandleKeyType &)
specialization for handling Gaudi::Property<SG::VarHandleKey>
Definition: AthCommonDataStore.h:156
calibdata.tube
tube
Definition: calibdata.py:31
fitman.k
k
Definition: fitman.py:528
Amg::setThetaPhi
void setThetaPhi(Amg::Vector3D &v, double theta, double phi)
sets the theta and phi angle of a vector without changing the magnitude
Definition: GeoPrimitivesHelpers.h:70
NSWL1::PadTriggerAdapter::segment
Muon::NSW_PadTriggerSegment segment(const NSWL1::PadTrigger &data)
Definition: PadTriggerAdapter.cxx:5
Identifier
Definition: IdentifierFieldParser.cxx:14
SCT_Monitoring::summary
@ summary
Definition: SCT_MonitoringNumbers.h:65