ATLAS Offline Software
MuonSegmentTagTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // MuonSegmentTagTool
7 // AlgTool performing MS segment tagging of ID tracks.
8 // A SegmentTag is added to the InDetCandidate object.
9 //
11 
12 #include "MuonSegmentTagTool.h"
13 
14 #include <cstdio>
15 #include <iomanip>
16 #include <optional>
17 #include <vector>
18 
19 #include "AthLinks/ElementLink.h"
29 #include "TrkTrack/Track.h"
31 #include "xAODMuon/MuonSegment.h"
33 namespace {
34  using Intersection = Muon::MuonSystemExtension::Intersection;
35  using LayerIndex = Muon::MuonStationIndex::LayerIndex;
36  using StationIndex = Muon::MuonStationIndex::StIndex;
37 
40  struct SegmentExtrCache {
41  SegmentExtrCache(const std::shared_ptr<const Trk::AtaPlane>& extp, const Trk::Surface& surf) :
42  segment_surface{&surf}, segment_pars{extp} {}
43  const Trk::Surface* segment_surface{nullptr};
44  std::shared_ptr<const Trk::AtaPlane> segment_pars{nullptr};
45  };
46 } // namespace
47 namespace MuonCombined {
48 
49  MuonSegmentTagTool::MuonSegmentTagTool(const std::string& type, const std::string& name, const IInterface* parent) :
51  declareInterface<IMuonSegmentTagTool>(this);
52  }
53 
55  ATH_CHECK(m_printer.retrieve());
56  ATH_CHECK(m_MuTagMatchingTool.retrieve());
58  ATH_CHECK(m_idHelperSvc.retrieve());
59  ATH_CHECK(m_edmHelperSvc.retrieve());
60  ATH_CHECK(m_segmentSelector.retrieve());
61 
62  ATH_MSG_INFO("Initializing MuonSegmentTagTool");
63 
64  ATH_MSG_DEBUG("Initialisation started ");
65  ATH_MSG_DEBUG("================================ ");
66  ATH_MSG_DEBUG("=Proprieties are ");
67  ATH_MSG_DEBUG("================================ ");
68  return StatusCode::SUCCESS;
69  }
70 
72  ATH_MSG_INFO("Total number of considered ID tracks " << m_ntotTracks);
73  ATH_MSG_INFO("Total number of ID tracks with angular match " << m_nangleMatch);
74  ATH_MSG_INFO("Total number of preselected ID tracks " << m_npmatch);
75  ATH_MSG_INFO("Total number of ID tracks at MS entry " << m_natMSEntrance);
76  ATH_MSG_INFO("Total number of accepted ID tracks " << m_naccepted);
77  for (unsigned int i = 0; i < SurfDef::NumSurf; ++i) {
78  const double recyc_extr = m_recycledIntersect[i] + m_extrapolated[i];
79  auto calc_ratio = [&recyc_extr](unsigned int N) -> double { return recyc_extr > 0. ? 100. * N / recyc_extr : 0; };
80  ATH_MSG_INFO("Layer " << m_surfaces.stationType(i) << " processed " << int(recyc_extr) << " extrapolated " << m_extrapolated[i]
81  << " (" << calc_ratio(m_extrapolated[i]) << " %) "
82  << " recycled " << m_recycledIntersect[i] << " (" << calc_ratio(m_recycledIntersect[i]) << "%) "
83  << " good " << m_goodExtrapolated[i] << " (" << calc_ratio(m_goodExtrapolated[i]) << "%)");
84  }
85  return StatusCode::SUCCESS;
86  }
87  void MuonSegmentTagTool::tag(const EventContext& ctx, const InDetCandidateCollection& inDetCandidates,
88  const std::vector<const Muon::MuonSegment*>& segments, InDetCandidateToTagMap* tagMap) const {
89  if (inDetCandidates.empty()) return;
90 
91  std::vector<const Muon::MuonSegment*> FilteredSegmentCollection = getCandidateSegments(segments);
92 
93  ATH_MSG_DEBUG("Filtered segments... in: " << segments.size() << ", out: " << FilteredSegmentCollection.size());
94 
95  if (FilteredSegmentCollection.empty()) return;
96 
97  unsigned int trackCount{0};
98  ATH_MSG_DEBUG("performing tag of " << inDetCandidates.size() << " tracks with " << FilteredSegmentCollection.size()
99  << " segments. ");
100  // Checking which surfaces have segments, to avoid useless extrapolations
101 
102  const SortedSegmentMap populStat = findPopulatedStations(FilteredSegmentCollection);
103 
104  std::vector<MuonCombined::MuonSegmentInfo> segmentsInfoSelected;
105  segmentsInfoSelected.reserve(FilteredSegmentCollection.size());
106  for (const MuonCombined::InDetCandidate* idTP : inDetCandidates) {
107  // ensure that the id trackparticle has a track
108  // Ignore if this is a siAssociated disk (and property set).
109  if (m_ignoreSiAssocated && idTP->isSiliconAssociated()) continue;
110 
111  ++trackCount;
112 
113  bool matchedSegment{false};
114  const xAOD::TrackParticle& track = idTP->indetTrackParticle();
115 
116  //
117  // Remove low p and low Field region defined by p < 6 and eta between 1.4-1.7
118  //
120  const double eta = std::abs(track.eta());
121  const double p = std::abs(1.0 / track.qOverP());
122  if (eta > 1.4 && eta < 1.7 && p < 6000.) continue;
123  }
124  ATH_MSG_DEBUG("Treating track " << trackCount << " " << idTP->toString());
125 
127  if (!track.summaryValue(numSCTHits, xAOD::numberOfSCTHits)) ATH_MSG_DEBUG("TrackParticle missing numberOfSCTHits");
128  if (!track.summaryValue(numPixelHits, xAOD::numberOfPixelHits)) ATH_MSG_DEBUG("TrackParticle missing numberOfPixelHits");
129 
130  unsigned int nrIDetaHits = numSCTHits + numPixelHits;
131  const bool trkEtaInfo = nrIDetaHits >= 5;
132  if (!trkEtaInfo) ATH_MSG_DEBUG("Track has no ID eta information! (" << nrIDetaHits << " etaHits)");
133 
134  ++m_ntotTracks;
135 
137  const SortedSegmentMap assocStat = m_doBidirectional ? populStat : findCandidateStations(*idTP, populStat);
138  if (assocStat.empty()) continue;
139 
140  const unsigned int num_assoc_segs =
141  std::accumulate(populStat.begin(), populStat.end(), 0,
142  [](unsigned int N, const std::pair<int, std::vector<const Muon::MuonSegment*>>& seg_stat) {
143  return N + seg_stat.second.size();
144  });
145 
146  std::vector<MuonCombined::MuonSegmentInfo> segmentsInfo;
147  segmentsInfo.reserve(num_assoc_segs);
148  const int multiply = 1 + m_doBidirectional;
149 
150  std::optional<std::vector<std::string>> didExtrapolate =
151  m_doTable ? std::make_optional<std::vector<std::string>>(SurfDef::NumSurf * multiply, "o") : std::nullopt;
152  std::optional<std::vector<std::string>> segStation =
153  m_doTable ? std::make_optional<std::vector<std::string>>(num_assoc_segs, "XXX") : std::nullopt;
154  std::optional<std::vector<std::vector<std::string>>> trkToSegment =
155  m_doTable ? std::make_optional<std::vector<std::vector<std::string>>>(SurfDef::NumSurf * multiply, *segStation)
156  : std::nullopt;
157 
158  const int numberOfExtrapolations = 1 + m_doBidirectional;
159  std::array<std::shared_ptr<const Trk::TrackParameters>, 2> trackAtMSEntrance;
160 
162  for (int i_extrapolations = 0; i_extrapolations < numberOfExtrapolations; ++i_extrapolations) {
163  // in case of along momentum extrapolation, use pre-existing extrapolation if available
164  const Trk::CaloExtension* extension = idTP->getCaloExtension();
165  const Muon::MuonSystemExtension* msExtension = idTP->getExtension();
166  std::vector<Intersection> intersections;
167  if (i_extrapolations == 0) {
169  if (msExtension) intersections = msExtension->layerIntersections();
170  if (extension && extension->muonEntryLayerIntersection()) {
172  trackAtMSEntrance[i_extrapolations] = pars.uniqueClone();
173  ATH_MSG_DEBUG("Got MS entry pos: r " << pars.position().perp() << " z " << pars.position().z() << " momentum "
174  << pars.momentum().perp() << " cov " << pars.covariance());
175  }
177  } else
178  intersections.clear();
180  if (!trackAtMSEntrance[i_extrapolations]) {
181  trackAtMSEntrance[i_extrapolations] =
182  m_MuTagMatchingTool->ExtrapolateTrktoMSEntrance(ctx, *track.track(), Trk::alongMomentum);
183  }
184 
185  if (!trackAtMSEntrance[i_extrapolations]) {
186  ATH_MSG_DEBUG("there is no track at MS entrance... not tagging for direction " << i_extrapolations);
187  continue;
188  }
189  ++m_natMSEntrance;
190 
191  std::shared_ptr<const Trk::TrackParameters> atSurface{trackAtMSEntrance[i_extrapolations]},
192  nextSurface{trackAtMSEntrance[i_extrapolations]};
193  bool barrel_extp{false}, endcap_extp{false};
194 
195  ATH_MSG_DEBUG("Start extrapolation " << i_extrapolations << " found in total " << num_assoc_segs
196  << " associated segments.");
197 
198  for (auto& stat_pair : assocStat) {
199  const int surface_counter = stat_pair.first;
200  const int extrapolation_counter = i_extrapolations * SurfDef::NumSurf + surface_counter;
201  const std::vector<const Muon::MuonSegment*>& targets = stat_pair.second;
202 
203  ATH_MSG_DEBUG("Surface " << m_surfaces.stationType(surface_counter));
205  if (m_doTable) (*didExtrapolate)[extrapolation_counter] = "X";
206 
207  std::optional<std::vector<std::string>> segVsSurf =
208  m_doTable ? std::make_optional<std::vector<std::string>>(num_assoc_segs, "xxx") : std::nullopt;
209  const Trk::Surface* surface = m_surfaces.getSurface(surface_counter);
210 
211  const bool is_barrel = surface_counter < SurfDef::EIA;
214  bool extrapolate{true};
215  if (!intersections.empty()) {
216  const bool is_aside = surface_counter < SurfDef::EIC;
218  Intersection best_intersec;
219  for (const Intersection& intersect : intersections) {
220  if (m_surfaces.stIdxToSurfDef(intersect.layerSurface.stIndex(), is_aside) != surface_counter) continue;
221  if (!best_intersec.trackParameters || std::abs(getPropDistance(*intersect.trackParameters, *surface)) <
222  std::abs(getPropDistance(*best_intersec.trackParameters, *surface)))
223  best_intersec = intersect;
224  }
225  if (best_intersec.trackParameters) {
226  atSurface = best_intersec.trackParameters;
227  extrapolate = false;
228  barrel_extp |= is_barrel;
229  endcap_extp |= !is_barrel;
230  ++m_recycledIntersect[surface_counter];
231  }
232  }
233 
234  if (extrapolate) {
235  if (m_doTable) (*didExtrapolate)[extrapolation_counter] = "V";
240  if (!is_barrel && barrel_extp && !endcap_extp) {
241  atSurface = trackAtMSEntrance[i_extrapolations];
242  endcap_extp = true;
243  }
244  const Trk::PropDirection surf_dir =
245  getPropDistance(*atSurface, *surface) > 0 ? Trk::alongMomentum : Trk::oppositeMomentum;
246  ATH_MSG_DEBUG("Extrapolate " << m_surfaces.stationType(surface_counter) << " from (" << atSurface->position().perp()
247  << ", " << atSurface->position().z() << "), to surface "
248  << "(" << surface->globalReferencePoint().perp() << ","
249  << surface->globalReferencePoint().z() << ") "
250  << (surf_dir == Trk::alongMomentum ? "along" : "opposite") << " momentum");
251 
252  nextSurface = m_MuTagMatchingTool->ExtrapolateTrktoMSSurface(ctx, *surface, *atSurface, surf_dir);
254  ++m_extrapolated[surface_counter];
255  if (nextSurface) {
256  atSurface = nextSurface;
257  barrel_extp |= is_barrel;
258  endcap_extp |= !is_barrel;
260  if (m_doTable) (*trkToSegment)[extrapolation_counter] = (*segVsSurf);
261  } else {
262  continue;
263  }
264  } else if (m_doTable)
265  (*didExtrapolate)[extrapolation_counter] = "S";
266 
267  ++m_goodExtrapolated[surface_counter];
268 
269  std::vector<SegmentExtrCache> seg_extps{};
270  seg_extps.reserve(targets.size());
271  ATH_MSG_VERBOSE("Perform segment matching");
272  int segmentCount{-1}; // Variable used for debugging
273  for (const Muon::MuonSegment* seg_ptr : targets) {
274  ++segmentCount;
275  if (m_doTable) { (*segStation)[segmentCount] = " "; }
276 
279  bool isMatched{false};
280  if (!m_doTable) {
281  isMatched = m_MuTagMatchingTool->match(*atSurface, *seg_ptr, surface_counter);
282  } else {
283  if (!m_MuTagMatchingTool->surfaceMatch(*seg_ptr, surface_counter)) {
284  (*segVsSurf)[segmentCount] = "surface";
285  continue;
286  }
287  ATH_MSG_VERBOSE("treating track " << trackCount << " (extrapolation = " << i_extrapolations << ") and Segment "
288  << (*segStation)[segmentCount] << " (segment " << segmentCount << ")");
289 
290  if (!m_MuTagMatchingTool->phiMatch(*atSurface, *seg_ptr)) {
291  (*segVsSurf)[segmentCount] = "RghPhi";
292  continue;
293  }
294  if (trkEtaInfo) {
295  if (is_barrel) {
296  if (!m_MuTagMatchingTool->thetaMatch(*atSurface, *seg_ptr)) {
297  (*segVsSurf)[segmentCount] = "RghTheta";
298  continue;
299  }
300  } else {
301  if (!m_MuTagMatchingTool->rMatch(*atSurface, *seg_ptr)) {
302  (*segVsSurf)[segmentCount] = "RghR";
303  continue;
304  }
305  }
306  isMatched = true;
307  } else { // trk has no eta info
308  ATH_MSG_DEBUG("bypassed roughEta/roughR cut since ID has no eta info!");
309  isMatched = true;
310  }
311  }
312 
313  if (!isMatched) {
314  if (m_doTable) {
315  ATH_MSG_DEBUG("isMatched is " << isMatched << " at this point, incoherent!");
316  if (!trkEtaInfo)
317  (*segVsSurf)[segmentCount] = "posPhi";
318  else
319  (*segVsSurf)[segmentCount] = "pos";
320  }
321  continue;
322  }
325 
326  std::shared_ptr<const Trk::AtaPlane> atSegSurface;
328  std::vector<SegmentExtrCache>::const_iterator cache_itr = std::find_if(
329  seg_extps.begin(), seg_extps.end(),
330  [seg_ptr](const SegmentExtrCache& cache) { return cache.segment_surface == &(seg_ptr->associatedSurface()); });
331  if (cache_itr != seg_extps.end()) {
332  atSegSurface = cache_itr->segment_pars;
333  ATH_MSG_DEBUG("Recycle extrapolation");
334  } else {
335  const Trk::PropDirection seg_dir =
336  getPropDistance(*atSurface, seg_ptr->associatedSurface()) > 0 ? Trk::alongMomentum : Trk::oppositeMomentum;
337  ATH_MSG_DEBUG("Extrapolate "
338  << m_surfaces.stationType(surface_counter) << " from (" << atSurface->position().perp() << ", "
339  << atSurface->position().z() << "), to segment "
340  << "(" << seg_ptr->globalPosition().perp() << "," << seg_ptr->globalPosition().z() << ") "
341  << (seg_dir == Trk::alongMomentum ? "along" : "opposite") << " momentum");
342  atSegSurface = m_MuTagMatchingTool->ExtrapolateTrktoSegmentSurface(ctx, *seg_ptr, *atSurface, seg_dir);
343  seg_extps.emplace_back(atSegSurface, seg_ptr->associatedSurface());
344  }
345  if (!atSegSurface || !atSegSurface->covariance() || !Amg::hasPositiveDiagElems(*atSegSurface->covariance()))
346  continue;
347  const AmgSymMatrix(5) invCov = atSegSurface->covariance()->inverse();
348  if (!Amg::hasPositiveDiagElems(invCov)) continue;
349 
351  m_MuTagMatchingTool->muTagSegmentInfo(ctx, track.track(), *seg_ptr, atSegSurface);
352  isMatched = m_MuTagMatchingTool->matchSegmentPosition(info, trkEtaInfo);
353  if (!isMatched) {
354  if (m_doTable) {
355  if (!trkEtaInfo)
356  (*segVsSurf)[segmentCount] = "posPhi";
357  else
358  (*segVsSurf)[segmentCount] = "pos";
359  }
360  continue;
361  }
362  isMatched = m_MuTagMatchingTool->matchSegmentDirection(info, trkEtaInfo);
363 
364  if (!isMatched) {
365  if (m_doTable) {
366  if (!trkEtaInfo)
367  (*segVsSurf)[segmentCount] = "dirPhi";
368  else
369  (*segVsSurf)[segmentCount] = "dir";
370  }
371  continue;
372  }
373 
374  isMatched = m_MuTagMatchingTool->matchDistance(info);
375 
376  if (!isMatched) {
377  if (m_doTable) { (*segVsSurf)[segmentCount] = "dist"; }
378  continue;
379  }
380 
381  isMatched = m_MuTagMatchingTool->matchCombinedPull(info);
382  if (!isMatched) {
383  if (m_doTable) { (*segVsSurf)[segmentCount] = "cpull"; }
384  continue;
385  }
386 
388  isMatched = m_MuTagMatchingTool->matchPtDependentPull(info, *track.track());
389  if (!isMatched) {
390  if (m_doTable) { (*segVsSurf)[segmentCount] = "ptpull"; }
391  continue;
392  }
393  }
394  if (m_doTable) (*segVsSurf)[segmentCount] = "TAG";
395  matchedSegment = true;
396  ATH_MSG_DEBUG("Tagged the track with Segment " << segmentCount);
397 
398  segmentsInfo.push_back(std::move(info));
399 
400  } // end loop over segments
401 
402  if (m_doTable) (*trkToSegment)[extrapolation_counter] = (*segVsSurf);
403  } // end loop over MS surfaces
404 
405  } // end loop over nr Directions of extrapolation.
406 
407  if (m_doTable) { printTable(*didExtrapolate, *segStation, *trkToSegment); }
408 
409  if (!matchedSegment) {
410  ATH_MSG_DEBUG("ID " << std::setw(3) << trackCount << " could not be matched with any segment on any abstract surface");
411  continue;
412  }
413 
414  // The loop over SM surfaces yielded matches for the extrapolated track.
415  // Per match, a MuTagObject is created and added to the MuTagObjectContainer
416  // A Track which has at least one match with the extrapolated track may be called a muon
417  //----------------------------------------------------------------
418  //----------------------------------------------------------------
419  if (!segmentsInfo.empty()) {
420  ++m_naccepted;
421  ATH_MSG_DEBUG("number of accepted tracks " << m_naccepted << " segmentsInfo size " << segmentsInfo.size());
422 
423  std::vector<MuonCombined::MuonSegmentInfo> segmentsInfoSolved =
424  m_MuTagAmbiguitySolverTool->selectBestMuTaggedSegments(ctx, segmentsInfo);
425  segmentsInfoSelected.insert(segmentsInfoSelected.end(), std::make_move_iterator(segmentsInfoSolved.begin()),
426  std::make_move_iterator(segmentsInfoSolved.end()));
427  ATH_MSG_DEBUG("segmentsInfoSelected size " << segmentsInfoSelected.size());
428  }
429 
430  } // end loop over tracks
431 
432  ATH_MSG_DEBUG("segmentsInfoSelected size after track loop " << segmentsInfoSelected.size());
433  std::vector<MuonCombined::MuonSegmentInfo> segmentsInfoFinal =
434  m_MuTagAmbiguitySolverTool->solveAmbiguities(ctx, segmentsInfoSelected);
435  ATH_MSG_DEBUG("segmentsInfoFinal size " << segmentsInfoFinal.size());
436 
437  if (msgLevel(MSG::DEBUG)) {
438  for (unsigned int ns1 = 0; ns1 < segmentsInfoFinal.size(); ++ns1) {
439  if (ns1 == 0)
440  ATH_MSG_DEBUG(m_printer->print(*segmentsInfoFinal[ns1].track));
441  else if (segmentsInfoFinal[ns1].track != segmentsInfoFinal[ns1 - 1].track)
442  ATH_MSG_DEBUG(m_printer->print(*segmentsInfoFinal[ns1].track));
443  ATH_MSG_DEBUG(m_printer->print(*segmentsInfoFinal[ns1].segment));
444  }
445  }
446 
447  for (const InDetCandidate* idTP : inDetCandidates) {
448  const Trk::Track* track = idTP->indetTrackParticle().track();
449  std::vector<MuonCombined::MuonSegmentInfo> segmentsInfoTag;
450  segmentsInfoTag.reserve(segmentsInfoFinal.size());
451 
452  for (unsigned int ns1 = 0; ns1 < segmentsInfoFinal.size(); ++ns1) {
453  if (segmentsInfoFinal[ns1].track == track && segmentsInfoFinal[ns1].nsegments > 0) {
454  segmentsInfoTag.push_back(segmentsInfoFinal[ns1]);
455  }
456  }
457  if (segmentsInfoTag.empty()) continue;
458  ATH_MSG_DEBUG("make Segment Tag object for " << m_printer->print(*track) << " nr segments " << segmentsInfoTag.size());
459  SegmentTag* tag = new SegmentTag(segmentsInfoTag);
460  tagMap->addEntry(idTP, tag);
461  }
462  }
463 
464  void MuonSegmentTagTool::printTable(const std::vector<std::string>& didEx, const std::vector<std::string>& segStation,
465  const std::vector<std::vector<std::string>>& segToSurf) const {
466  ATH_MSG_DEBUG(std::setw(6) << ""
467  << "EX? (o: no extrap, X: extrap failed, V: extrap OK)");
468 
469  if (msgLvl(MSG::DEBUG)) msg(MSG::DEBUG) << "Surface" << std::setw(2) << "";
470  for (unsigned int segment_counter = 0; segment_counter < segStation.size(); ++segment_counter) {
471  if (msgLvl(MSG::DEBUG)) msg(MSG::DEBUG) << std::setw(10) << segStation[segment_counter];
472  }
474 
475  unsigned int extrapolation_counter(0);
476  std::string signstr("");
477  if (m_doBidirectional) signstr = "+";
478 
479  for (int counter = 0; counter < SurfDef::NumSurf; ++counter) {
480  if (msgLvl(MSG::DEBUG))
481  msg(MSG::DEBUG) << std::setw(5) << m_surfaces.stationType(counter) << signstr << std::setw(3)
482  << didEx[extrapolation_counter];
483  for (unsigned int segment_counter = 0; segment_counter < segStation.size(); ++segment_counter) {
484  if (msgLvl(MSG::DEBUG)) msg(MSG::DEBUG) << std::setw(10) << (segToSurf[extrapolation_counter])[segment_counter];
485  } // end loop segments
487  ++extrapolation_counter;
488  } // end loop surfaces
489 
490  if (m_doBidirectional) {
491  signstr = "-";
492  for (unsigned int counter = 0; counter < SurfDef::NumSurf; ++counter) {
493  if (msgLvl(MSG::DEBUG))
494  msg(MSG::DEBUG) << std::setw(5) << m_surfaces.stationType(counter) << signstr << std::setw(3)
495  << didEx[extrapolation_counter];
496  for (unsigned int segment_counter = 0; segment_counter < segStation.size(); ++segment_counter) {
497  if (msgLvl(MSG::DEBUG)) msg(MSG::DEBUG) << std::setw(10) << (segToSurf[extrapolation_counter])[segment_counter];
498  } // end loop segments
500  ++extrapolation_counter;
501  } // end loop surfaces
502  }
503  }
504  std::vector<const Muon::MuonSegment*> MuonSegmentTagTool::getCandidateSegments(
505  const std::vector<const Muon::MuonSegment*>& segments) const {
506  if (!m_doSegmentsFilter) {
507  ATH_MSG_VERBOSE("No segment filtering required. ");
508  return segments;
509  }
510  std::vector<const Muon::MuonSegment*> FilteredSegmentCollection;
511  FilteredSegmentCollection.reserve(segments.size());
512 
513  for (const Muon::MuonSegment* itSeg : segments) {
514  int quality = m_segmentSelector->quality(*itSeg);
515  ATH_MSG_DEBUG(" Segment quality " << quality);
516  if (quality < m_segmentQualityCut) continue;
517  Muon::IMuonSegmentHitSummaryTool::HitCounts hitCounts = m_hitSummaryTool->getHitCounts(*itSeg);
518  if (hitCounts.ncscHits() > 0)
519  ATH_MSG_DEBUG(" CSC segment ");
520  else {
521  if (hitCounts.nmdtHoles >= m_nmdtHoles) continue;
522  if (hitCounts.nmdtHits() < m_nmdtHits) continue; // precision hits
523  if (hitCounts.nmdtHitsMl1 > 0 && hitCounts.nmdtHitsMl1 < m_nmdtHitsML) continue;
524  if (hitCounts.nmdtHitsMl2 > 0 && hitCounts.nmdtHitsMl2 < m_nmdtHitsML) continue;
525  // If Trigger hits are expected one should at least find one
526  ATH_MSG_DEBUG(" expected TrigHits " << hitCounts.nexpectedTrigHitLayers << " TrigHits found "
527  << hitCounts.nphiTrigHitLayers + hitCounts.netaTrigHitLayers);
528  if (m_triggerHitCut && hitCounts.nexpectedTrigHitLayers > 1 && hitCounts.nphiTrigHitLayers == 0 &&
529  hitCounts.netaTrigHitLayers == 0)
530  continue;
531  }
532  if (m_segmentQualityCut > 0) {
533  Identifier chId = m_edmHelperSvc->chamberId(*itSeg);
534  StationIndex stIndex = m_idHelperSvc->stationIndex(chId);
535  if (!m_triggerHitCut && stIndex == Muon::MuonStationIndex::EM) {
536  // don't apply the TGC requirement for the first station as it sometimes has not trigger hits due to TGC acceptance
537  int stationEta = m_idHelperSvc->stationEta(chId);
538  if (std::abs(stationEta) != 1) {
539  // remove EM segments without trigger hits
540  if (hitCounts.nphiTrigHitLayers == 0 && hitCounts.netaTrigHitLayers == 0) continue;
541  }
542  }
543  if (stIndex == Muon::MuonStationIndex::EI) {
544  // remove CSC segment with hits in only one projection
546  if (m_idHelperSvc->isCsc(chId) && !hitCounts.ncscHits.hasEtaAndPhi()) continue;
547  }
548  }
549  FilteredSegmentCollection.emplace_back(itSeg);
550  }
551  return FilteredSegmentCollection;
552  }
554  const std::vector<const Muon::MuonSegment*>& filteredSegments) const {
555  SortedSegmentMap sortedSegments{};
556  for (const Muon::MuonSegment* itSeg : filteredSegments) {
557  const Identifier chId = m_edmHelperSvc->chamberId(*itSeg);
558  const int surf_def = MuonCombined::MuonSegmentTagSurfaces::stIdxToSurfDef(m_idHelperSvc->stationIndex(chId),
559  m_idHelperSvc->stationEta(chId) > 0);
560  std::vector<const Muon::MuonSegment*>& surf_vec = sortedSegments[surf_def];
561  if (surf_vec.empty()) surf_vec.reserve(filteredSegments.size());
562  surf_vec.push_back(itSeg);
563  }
564  return sortedSegments;
565  }
567  const MuonCombined::InDetCandidate& id_cand, const MuonSegmentTagTool::SortedSegmentMap& filteredSegments) const {
568  SortedSegmentMap sortedSegments;
569 
570  bool hasAngleMatch{false}, hasMatch{false};
571  const Trk::Track* track = id_cand.indetTrackParticle().track();
572  const Amg::Vector3D id_mom = track->perigeeParameters()->momentum();
573 
574  const double qID = track->perigeeParameters()->charge();
575  const double pID = id_mom.mag();
576 
577  if (pID <= 20000. * (qID * id_mom.eta() - 2)) { return sortedSegments; }
578 
579  const Trk::CaloExtension* extension = id_cand.getCaloExtension();
580  const Trk::TrackParameters* ms_entry = extension ? extension->muonEntryLayerIntersection() : nullptr;
581  const double ThetaID = (ms_entry ? ms_entry->position() : id_mom).theta();
582 
583  std::vector<int> id_sectors;
584  if (ms_entry) m_sectorMapping.getSectors(ms_entry->position().phi(), id_sectors);
585  auto sector_match = [&, this](const Amg::Vector3D& seg_pos) -> bool {
586  if (!ms_entry) return std::abs(qID * seg_pos.deltaPhi(id_mom) - qID / pID) < 0.6;
587  std::vector<int> seg_sectors;
588  m_sectorMapping.getSectors(seg_pos.phi(), seg_sectors);
589  return std::find_if(id_sectors.begin(), id_sectors.end(), [&seg_sectors](const int id_sec) {
590  return std::find(seg_sectors.begin(), seg_sectors.end(), id_sec) != seg_sectors.end();
591  }) != id_sectors.end();
592  };
593 
594  for (const auto& key_pair : filteredSegments) {
595  const int surf_def = key_pair.first;
596  const std::vector<const Muon::MuonSegment*>& source_vec = key_pair.second;
597  std::vector<const Muon::MuonSegment*> target_vec;
598  target_vec.reserve(source_vec.size());
599  for (const Muon::MuonSegment* itSeg : source_vec) {
600  const Amg::Vector3D& pos = itSeg->globalPosition();
601  const double dTheta = pos.theta() - ThetaID;
602  const bool theta_match = ms_entry ? std::abs(dTheta) < 0.2 : (qID * dTheta < 0.2 && qID * dTheta > -0.6);
603  if (!theta_match) {
604  ATH_MSG_VERBOSE("dTheta cut failed");
605  continue;
606  }
607  if (!sector_match(pos)) {
608  ATH_MSG_VERBOSE("dPhi cut failed");
609  continue;
610  }
611  hasAngleMatch = true;
612  const Identifier chId = m_edmHelperSvc->chamberId(*itSeg);
613  if (!m_idHelperSvc->isCsc(chId)) hasMatch = true;
614  target_vec.push_back(itSeg);
615  }
616  if (target_vec.empty()) continue;
617  sortedSegments[surf_def] = std::move(target_vec);
618  }
619  if (hasAngleMatch) ++m_nangleMatch;
620  if (hasMatch)
621  ++m_npmatch;
622  else
623  sortedSegments.clear();
624  return sortedSegments;
625  }
626  double MuonSegmentTagTool::getPropDistance(const Trk::TrackParameters& start_pars, const Trk::Surface& target_surf) {
627  Trk::DistanceSolution distSol = target_surf.straightLineDistanceEstimate(start_pars.position(), start_pars.momentum().normalized());
628  if (distSol.numberOfSolutions() > 0) return distSol.first();
629  return distSol.toPointOfClosestApproach();
630  }
631 } // namespace MuonCombined
grepfile.info
info
Definition: grepfile.py:38
MuonCombined::SegmentTag
TagBase implementation for a segment tagger.
Definition: SegmentTag.h:14
make_hlt_rep.pars
pars
Definition: make_hlt_rep.py:90
MuonCombined::MuonSegmentTagTool::m_doBidirectional
Gaudi::Property< bool > m_doBidirectional
Definition: MuonSegmentTagTool.h:87
MuonCombined::MuonSegmentInfo
Definition: MuonSegmentInfo.h:23
MuonCombined::MuonSegmentTagTool::m_segmentQualityCut
Gaudi::Property< int > m_segmentQualityCut
Definition: MuonSegmentTagTool.h:93
MuonCombined::MuonSegmentTagTool::m_nangleMatch
std::atomic_uint m_nangleMatch
Definition: MuonSegmentTagTool.h:107
Amg::hasPositiveDiagElems
bool hasPositiveDiagElems(const AmgSymMatrix(N) &mat)
Returns true if all diagonal elements of the covariance matrix are finite aka sane in the above defin...
Definition: EventPrimitivesCovarianceHelpers.h:96
MuonCombined::MuonSegmentTagTool::tag
void tag(const EventContext &ctx, const InDetCandidateCollection &inDetCandidates, const std::vector< const Muon::MuonSegment * > &segments, InDetCandidateToTagMap *tagMap) const override
IMuonSegmentTagTool interface: build muons from ID and MuonSegments.
Definition: MuonSegmentTagTool.cxx:87
MuonCombined::MuonSegmentTagTool::m_naccepted
std::atomic_uint m_naccepted
Definition: MuonSegmentTagTool.h:110
python.PerfMonSerializer.p
def p
Definition: PerfMonSerializer.py:743
TrackParameters.h
Trk::DistanceSolution::toPointOfClosestApproach
double toPointOfClosestApproach() const
Distance to point of closest approach along direction.
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
xAOD::uint8_t
uint8_t
Definition: Muon_v1.cxx:575
MuonCombined::MuonSegmentTagTool::m_doPtDependentPullCut
Gaudi::Property< bool > m_doPtDependentPullCut
Definition: MuonSegmentTagTool.h:89
Trk::Track
The ATLAS Track class.
Definition: Tracking/TrkEvent/TrkTrack/TrkTrack/Track.h:73
Trk::DistanceSolution
Definition: DistanceSolution.h:25
Trk::CaloExtension
Tracking class to hold the extrapolation from a particle from the ID to the muon system (or the other...
Definition: CaloExtension.h:18
MuonCombined::InDetCandidateToTagMap
Definition: InDetCandidateToTagMap.h:15
Muon::IMuonSegmentHitSummaryTool::HitCounts::nmdtHitsMl1
uint8_t nmdtHitsMl1
Definition: IMuonSegmentHitSummaryTool.h:40
eta
Scalar eta() const
pseudorapidity method
Definition: AmgMatrixBasePlugin.h:79
Trk::ParametersBase::position
const Amg::Vector3D & position() const
Access method for the position.
Trk::oppositeMomentum
@ oppositeMomentum
Definition: PropDirection.h:21
Trk::DistanceSolution::numberOfSolutions
int numberOfSolutions() const
Number of intersection solutions.
Trk::Surface::straightLineDistanceEstimate
virtual DistanceSolution straightLineDistanceEstimate(const Amg::Vector3D &pos, const Amg::Vector3D &dir) const =0
fast straight line distance evaluation to Surface
MuonCombined::MuonSegmentTagTool::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonSegmentTagTool.h:71
Muon::MuonSectorMapping::getSectors
void getSectors(double phi, std::vector< int > &sectors) const
returns the main sector plus neighboring if the phi position is in an overlap region
Definition: MuonSectorMapping.h:93
MuonCombined::MuonSegmentTagTool::m_hitSummaryTool
ToolHandle< Muon::IMuonSegmentHitSummaryTool > m_hitSummaryTool
Definition: MuonSegmentTagTool.h:82
accumulate
bool accumulate(AccumulateMap &map, std::vector< module_t > const &modules, FPGATrackSimMatrixAccumulator const &acc)
Accumulates an accumulator (e.g.
Definition: FPGATrackSimMatrixAccumulator.cxx:22
theta
Scalar theta() const
theta method
Definition: AmgMatrixBasePlugin.h:71
Muon::IMuonSegmentHitSummaryTool::EtaPhiHitCount::hasEtaAndPhi
bool hasEtaAndPhi() const
Definition: IMuonSegmentHitSummaryTool.h:23
MuonCombined::MuonSegmentTagSurfaces::getSurface
const Trk::Surface * getSurface(SurfDef surf) const
Definition: MuonSegmentTagSurfaces.h:57
MuonSegment.h
Muon::MuonStationIndex::LayerIndex
LayerIndex
enum to classify the different layers in the muon spectrometer
Definition: MuonStationIndex.h:38
MuonCombined::MuonSegmentTagTool::findPopulatedStations
SortedSegmentMap findPopulatedStations(const std::vector< const Muon::MuonSegment * > &filteredSegments) const
Creates the sorted segment map.
Definition: MuonSegmentTagTool.cxx:553
MuonCombined::MuonSegmentTagSurfaces::stIdxToSurfDef
static int stIdxToSurfDef(Muon::MuonStationIndex::StIndex st_idx, bool pos_eta)
Transforms the Muon Station index to a SurfDef index.
Definition: MuonSegmentTagSurfaces.cxx:21
CaloExtension.h
AthCommonMsg< AlgTool >::msgLvl
bool msgLvl(const MSG::Level lvl) const
Definition: AthCommonMsg.h:30
MuonCombined::InDetCandidate
Definition: InDetCandidate.h:18
MuonCombined::MuonSegmentTagTool::m_surfaces
const MuonCombined::MuonSegmentTagSurfaces m_surfaces
Definition: MuonSegmentTagTool.h:102
xAOD::numberOfPixelHits
@ numberOfPixelHits
these are the pixel hits, including the b-layer [unit8_t].
Definition: TrackingPrimitives.h:259
InDetSecVtxTruthMatchUtils::isMatched
bool isMatched(int matchInfo)
Definition: InDetSecVtxTruthMatchTool.h:48
Trk::alongMomentum
@ alongMomentum
Definition: PropDirection.h:20
JetTiledMap::N
@ N
Definition: TiledEtaPhiMap.h:44
Trk::DistanceSolution::first
double first() const
Distance to first intersection solution along direction.
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
MuonCombined::MuonSegmentTagTool::m_nmdtHits
Gaudi::Property< unsigned int > m_nmdtHits
Definition: MuonSegmentTagTool.h:94
Trk::CaloExtension::muonEntryLayerIntersection
const TrackParameters * muonEntryLayerIntersection() const
access to intersection with the muon entry layer return NULL if the intersection failed
Definition: CaloExtension.h:70
MuonSegmentInfo.h
AmgSymMatrix
#define AmgSymMatrix(dim)
Definition: EventPrimitives.h:52
Muon::IMuonSegmentHitSummaryTool::HitCounts::netaTrigHitLayers
uint8_t netaTrigHitLayers
Definition: IMuonSegmentHitSummaryTool.h:52
MuonCombined::MuonSegmentTagTool::initialize
StatusCode initialize() override
Definition: MuonSegmentTagTool.cxx:54
MuonSegmentContainer.h
MuonCombined::MuonSegmentTagTool::m_MuTagMatchingTool
ToolHandle< IMuTagMatchingTool > m_MuTagMatchingTool
Definition: MuonSegmentTagTool.h:76
MuonCombined::MuonSegmentTagTool::m_edmHelperSvc
ServiceHandle< Muon::IMuonEDMHelperSvc > m_edmHelperSvc
Definition: MuonSegmentTagTool.h:72
IMuonCombinedTagTool.h
Track.h
MuonCombined::MuonSegmentTagTool::m_ntotTracks
std::atomic_uint m_ntotTracks
Definition: MuonSegmentTagTool.h:106
Muon::IMuonSegmentHitSummaryTool::HitCounts::nmdtHits
uint8_t nmdtHits() const
Returns the number of hits in both MDT layers.
Definition: IMuonSegmentHitSummaryTool.h:60
MuonCombined::MuonSegmentTagTool::m_nmdtHitsML
Gaudi::Property< unsigned int > m_nmdtHitsML
Definition: MuonSegmentTagTool.h:96
MuonCombined::MuonSegmentTagTool::m_triggerHitCut
Gaudi::Property< bool > m_triggerHitCut
Definition: MuonSegmentTagTool.h:98
MuonCombined::MuonSegmentTagTool::MuonSegmentTagTool
MuonSegmentTagTool(const std::string &type, const std::string &name, const IInterface *parent)
Definition: MuonSegmentTagTool.cxx:49
Trk::ParametersT::associatedSurface
virtual const S & associatedSurface() const override final
Access to the Surface method.
MuonCombined::InDetCandidateToTagMap::addEntry
void addEntry(const InDetCandidate *idcand, TagBase *tag)
Definition: InDetCandidateToTagMap.cxx:8
Trk::PropDirection
PropDirection
Definition: PropDirection.h:19
MuonCombined::MuonSegmentTagTool::m_sectorMapping
const Muon::MuonSectorMapping m_sectorMapping
sector mapping helper
Definition: MuonSegmentTagTool.h:104
Muon::IMuonSegmentHitSummaryTool::HitCounts::nexpectedTrigHitLayers
uint8_t nexpectedTrigHitLayers
Definition: IMuonSegmentHitSummaryTool.h:54
MuonCombined::MuonSegmentTagTool::findCandidateStations
SortedSegmentMap findCandidateStations(const MuonCombined::InDetCandidate &Id_trk, const SortedSegmentMap &filteredSegments) const
Returns an array encoding which muon segments are compatible with the IdCandidate.
Definition: MuonSegmentTagTool.cxx:566
MuonCombined::MuonSegmentTagSurfaces::stationType
const std::string stationType(unsigned int count) const
Definition: MuonSegmentTagSurfaces.h:50
MuonCombined::MuonSegmentTagTool::m_doSegmentsFilter
Gaudi::Property< bool > m_doSegmentsFilter
Definition: MuonSegmentTagTool.h:85
lumiFormat.i
int i
Definition: lumiFormat.py:92
xAOD::numPixelHits
@ numPixelHits
Definition: TrackingPrimitives.h:533
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
Muon::MuonStationIndex::EI
@ EI
Definition: MuonStationIndex.h:26
MuonCombined::MuonSegmentTagTool::m_doTable
Gaudi::Property< bool > m_doTable
Definition: MuonSegmentTagTool.h:86
Muon::MuonSystemExtension
Tracking class to hold the extrapolation from a particle from the calo entry to the end of muon syste...
Definition: MuonSystemExtension.h:18
xAOD::numSCTHits
@ numSCTHits
Definition: TrackingPrimitives.h:534
test_pyathena.parent
parent
Definition: test_pyathena.py:15
MuonCombined::MuonSegmentTagTool::m_MuTagAmbiguitySolverTool
ToolHandle< IMuTagAmbiguitySolverTool > m_MuTagAmbiguitySolverTool
Definition: MuonSegmentTagTool.h:77
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
MuonCombined::MuonSegmentTagTool::m_segmentSelector
ToolHandle< Muon::IMuonSegmentSelectionTool > m_segmentSelector
Definition: MuonSegmentTagTool.h:80
TrackSummary.h
Trk::ParametersBase
Definition: ParametersBase.h:55
DataVector
Derived DataVector<T>.
Definition: DataVector.h:581
MuonCombined::MuonSegmentTagTool::SortedSegmentMap
std::map< int, std::vector< const Muon::MuonSegment * > > SortedSegmentMap
The segment vector is sorted into a map where the key is the associated surface definition of each se...
Definition: MuonSegmentTagTool.h:61
InDetCandidate.h
MuonCombined::MuonSegmentTagTool::printTable
void printTable(const std::vector< std::string > &didEx, const std::vector< std::string > &segStation, const std::vector< std::vector< std::string >> &segToSurf) const
method for extra DEBUG
Definition: MuonSegmentTagTool.cxx:464
MuonSegmentTagTool.h
MuonCombined::MuonSegmentTagTool::m_nmdtHoles
Gaudi::Property< unsigned int > m_nmdtHoles
Definition: MuonSegmentTagTool.h:95
MuonCombined::MuonSegmentTagTool::finalize
StatusCode finalize() override
Definition: MuonSegmentTagTool.cxx:71
SegmentTag.h
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:192
MuonCandidate.h
Muon::IMuonSegmentHitSummaryTool::HitCounts::nphiTrigHitLayers
uint8_t nphiTrigHitLayers
Number of eta stereo hits.
Definition: IMuonSegmentHitSummaryTool.h:51
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
MuonCombined::InDetCandidate::getCaloExtension
const Trk::CaloExtension * getCaloExtension() const
Definition: InDetCandidate.cxx:47
MuonCombined::MuonSegmentTagTool::getPropDistance
static double getPropDistance(const Trk::TrackParameters &start_pars, const Trk::Surface &target_surf)
Returns the straight line distance estimation of the parameters to the surface.
Definition: MuonSegmentTagTool.cxx:626
python.LumiBlobConversion.pos
pos
Definition: LumiBlobConversion.py:18
MuonCombined::MuonSegmentTagTool::m_ignoreSiAssocated
Gaudi::Property< bool > m_ignoreSiAssocated
Definition: MuonSegmentTagTool.h:99
Muon::IMuonSegmentHitSummaryTool::HitCounts
Definition: IMuonSegmentHitSummaryTool.h:37
MuonCombined::MuonSegmentTagTool::m_natMSEntrance
std::atomic_uint m_natMSEntrance
Definition: MuonSegmentTagTool.h:109
EventPrimitivesCovarianceHelpers.h
Trk::ParametersBase::momentum
const Amg::Vector3D & momentum() const
Access method for the momentum.
Muon::IMuonSegmentHitSummaryTool::HitCounts::nmdtHoles
uint8_t nmdtHoles
Definition: IMuonSegmentHitSummaryTool.h:42
Muon::IMuonSegmentHitSummaryTool::HitCounts::ncscHits
EtaPhiHitCount ncscHits
Definition: IMuonSegmentHitSummaryTool.h:45
MuonCombined::MuonSegmentTagTool::m_printer
ToolHandle< Muon::MuonEDMPrinterTool > m_printer
Definition: MuonSegmentTagTool.h:75
MuonCombined::MuonSegmentTagTool::m_npmatch
std::atomic_uint m_npmatch
Definition: MuonSegmentTagTool.h:108
MuonCombined::InDetCandidate::indetTrackParticle
const xAOD::TrackParticle & indetTrackParticle() const
access TrackParticle
Definition: InDetCandidate.cxx:27
Amg::intersect
std::optional< double > intersect(const AmgVector(N)&posA, const AmgVector(N)&dirA, const AmgVector(N)&posB, const AmgVector(N)&dirB)
Calculates the closest approach of two lines.
Definition: GeoPrimitivesHelpers.h:302
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
MuonCombined
The MuonTagToSegMap is an auxillary construct that links the MuonSegments associated with a combined ...
Definition: IMuonSystemExtensionTool.h:23
DEBUG
#define DEBUG
Definition: page_access.h:11
AthCommonMsg< AlgTool >::msg
MsgStream & msg() const
Definition: AthCommonMsg.h:24
Muon::MuonSystemExtension::layerIntersections
const std::vector< Intersection > & layerIntersections() const
access to the intersections with the layers.
Definition: MuonSystemExtension.h:62
xAOD::numberOfSCTHits
@ numberOfSCTHits
number of hits in SCT [unit8_t].
Definition: TrackingPrimitives.h:268
MuonHough::extrapolate
float extrapolate(const MuonLayerHough::Maximum &ref, const MuonLayerHough::Maximum &ex, bool doparabolic=false)
Definition: MuonLayerHough.cxx:519
MuonSegment.h
Muon::MuonStationIndex::StIndex
StIndex
enum to classify the different station layers in the muon spectrometer
Definition: MuonStationIndex.h:23
Muon::MuonSystemExtension::Intersection
data per intersection
Definition: MuonSystemExtension.h:21
xAOD::track
@ track
Definition: TrackingPrimitives.h:512
xAOD::TrackParticle_v1
Class describing a TrackParticle.
Definition: TrackParticle_v1.h:43
xAOD::TrackParticle_v1::track
const Trk::Track * track() const
Returns a pointer (which can be NULL) to the Trk::Track which was used to make this TrackParticle.
Definition: TrackParticle_v1.cxx:805
Muon::MuonSegment
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:45
MuonCombined::MuonSegmentTagTool::m_removeLowPLowFieldRegion
Gaudi::Property< bool > m_removeLowPLowFieldRegion
Definition: MuonSegmentTagTool.h:90
AthAlgTool
Definition: AthAlgTool.h:26
test_pyathena.counter
counter
Definition: test_pyathena.py:15
Trk::Surface
Definition: Tracking/TrkDetDescr/TrkSurfaces/TrkSurfaces/Surface.h:75
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
DataVector::empty
bool empty() const noexcept
Returns true if the collection is empty.
MuonCombined::MuonSegmentTagTool::getCandidateSegments
std::vector< const Muon::MuonSegment * > getCandidateSegments(const std::vector< const Muon::MuonSegment * > &segments) const
Filters the input segments based on the number of hits fit quality etc.
Definition: MuonSegmentTagTool.cxx:504
Muon::MuonStationIndex::EM
@ EM
Definition: MuonStationIndex.h:26
Muon::IMuonSegmentHitSummaryTool::HitCounts::nmdtHitsMl2
uint8_t nmdtHitsMl2
Definition: IMuonSegmentHitSummaryTool.h:41