ATLAS Offline Software
MuonSegmentToCalibSegment.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
7 #include <iostream>
8 
9 #include "MdtCalibSvc/MdtCalibrationSvcInput.h"
10 #include "MdtCalibSvc/MdtCalibrationSvcSettings.h"
23 #include "StoreGate/WriteHandle.h"
27 namespace MuonCalib {
28 
29  MuonSegmentToCalibSegment::MuonSegmentToCalibSegment(const std::string& name, ISvcLocator* pSvcLocator) :
30  AthAlgorithm(name, pSvcLocator) {}
31 
32  // Initialize
34  if (m_TrkSegKey.size() < m_segment_authors.size()) { m_segment_authors.value().resize(m_TrkSegKey.size(), -1); }
35 
36  std::string managerName = "Muon";
38  ATH_CHECK(m_idToFixedIdTool.retrieve());
39  ATH_CHECK(m_assocTool.retrieve());
40  ATH_CHECK(m_idHelperSvc.retrieve());
43 
44  ATH_CHECK(m_CombSegKey.initialize());
46  ATH_CHECK(m_TrkSegKey.initialize());
48 
49  // Get the maximum number of segments each algorithm can
50  // store in the ntuple
55 
56  if (m_TrkSegKey.size()) { m_maxStoredSegs.value() /= m_TrkSegKey.size(); }
57  ATH_MSG_INFO("Maximum number of stored segments for each algorithm = " << m_maxStoredSegs);
58 
59  ATH_MSG_INFO("Initialisation ended ");
60  return StatusCode::SUCCESS;
61  }
62 
64  ATH_MSG_DEBUG(" execute() ");
65  ATH_CHECK(convertPatterns(Gaudi::Hive::currentContext()));
66  return StatusCode::SUCCESS;
67  }
68 
70  std::unique_ptr<MuonCalibPatternCollection> newPatterns) const {
71  SG::WriteHandle writeHandle{m_patternKey, ctx};
72 
73  ATH_CHECK(writeHandle.record(std::move(newPatterns)));
74  return StatusCode::SUCCESS;
75  }
76 
82  std::unique_ptr<MuonCalibPatternCollection> patterns = std::make_unique<MuonCalibPatternCollection>();
83 
84  ATH_MSG_DEBUG(" convertPatterns() ");
85 
87  const MuonGM::MuonDetectorManager* MuonDetMgr = DetectorManagerHandle.cptr();
88  if (!MuonDetMgr) {
89  ATH_MSG_ERROR("Null pointer to the read MuonDetectorManager conditions object");
90  return StatusCode::FAILURE;
91  }
92 
93  if (!m_readSegments) {
94  const MuonSegmentCombinationCollection* segCombis = nullptr;
95  ATH_CHECK(retrieveContainer(ctx, m_CombSegKey, segCombis));
96 
99 
100  ATH_MSG_DEBUG(" Looping over segment combination " << segCombis->size());
101 
102  for (; sit != sit_end; ++sit) {
103  // get association to pattern
104  const Muon::MuonPatternCombination* pat = nullptr;
106  if ((range.first) != (range.second)) {
107  if (m_assocTool->count(*sit) != 1) {
108  ATH_MSG_INFO(" This MuonSegPatAssMap for MDTs should only have one entry!! ");
109  } // retrieve association map:
110  pat = (range.first)->second;
111  } else {
112  ATH_MSG_WARNING("MDT Combination missing from the map - something is wrong! " << *sit);
113  }
114 
116 
117  ATH_MSG_DEBUG("New segment combination covering " << (*sit)->numberOfStations() << " station ");
118 
119  // loop over segments in combination
120  unsigned int nstations = (*sit)->numberOfStations();
121  for (unsigned int i = 0; i != nstations; ++i) {
122  Muon::MuonSegmentCombination::SegmentVec* stationSegs = (*sit)->stationSegments(i);
123 
124  ATH_MSG_VERBOSE("New station with " << stationSegs->size() << " segments ");
125  for (const std::unique_ptr<Muon::MuonSegment>& seg : *stationSegs) {
126  if (!seg) {
127  ATH_MSG_WARNING(" go NULL pointer for MuonSegment ");
128  continue;
129  }
130 
131  std::shared_ptr<MuonCalibSegment> mdtSeg{createMuonCalibSegment(*seg, MuonDetMgr)};
132  mdtSeg->setAuthor(seg->author());
133  calibpat->addMuonSegment(mdtSeg);
134  }
135  }
136  // add pattern to segment
137  patterns->push_back(calibpat);
138  }
139 
140  } else {
141  // loop over MDT segment collections
142 
143  std::vector<int>::const_iterator autIt = m_segment_authors.begin();
144 
146  int nStoredSegments = 0;
147 
148  const Trk::SegmentCollection* segCol = nullptr;
149  if (!retrieveContainer(ctx, key, segCol).isSuccess()) { ++autIt; }
150  ATH_MSG_DEBUG(" Looping over segments " << segCol->size());
151  for (const Trk::Segment* seg_it : *segCol) {
152  if (nStoredSegments >= m_maxStoredSegs) {
153  ATH_MSG_INFO("For " << key.fullKey() << ", hit max number of segments = " << nStoredSegments);
154  break;
155  }
156 
157  if (!seg_it) {
158  ATH_MSG_WARNING(" go NULL pointer for Segment ");
159  continue;
160  }
161 
162  const Muon::MuonSegment* seg = dynamic_cast<const Muon::MuonSegment*>(seg_it);
163  if (!seg) {
164  ATH_MSG_WARNING(" dynamic_cast to MuonSegment failed ");
165  continue;
166  }
167 
168  // one pattern per segment
169  ATH_MSG_DEBUG("WARNING, empty muoncalibpattern created");
170  std::unique_ptr<MuonCalibPattern> pat = std::make_unique<MuonCalibPattern>();
171 
172  std::shared_ptr<MuonCalibSegment> mdtSeg{createMuonCalibSegment(*seg, MuonDetMgr)};
173  if (*autIt < 0)
174  mdtSeg->setAuthor(seg->author());
175  else
176  mdtSeg->setAuthor(*autIt);
177 
178  pat->addMuonSegment(mdtSeg);
179 
180  // add pattern to segment
181  patterns->push_back(std::move(pat));
182  ++nStoredSegments;
183  }
184  ++autIt;
185  }
186  }
187 
188  // retrieve CscSegmentCombis
189  if (m_useCscSegments) {
190  const MuonSegmentCombinationCollection* segCombis = nullptr;
191  ATH_CHECK(retrieveContainer(ctx, m_CscSegKey, segCombis));
194 
195  ATH_MSG_DEBUG(" Looping over Csc segment combination " << segCombis->size());
196 
197  for (; sit != sit_end; ++sit) {
198  // don't create pattern when csc segment combination is empty (bug in csc segmentmaker?, 3-12-7, JS)
199  if ((*sit)->numberOfStations() == 1) {
200  if ((*sit)->stationSegments(0)->size() == 0) continue;
201  }
202 
203  // get association to pattern
204  const Muon::MuonPatternCombination* pat = nullptr;
206  if ((range.first) != (range.second)) {
207  pat = (range.first)->second;
208  } else {
209  ATH_MSG_DEBUG("CSC Combination missing from the map - No combined pattern found for this CSC Segment Combination! "
210  << *sit);
211  }
212 
214 
215  ATH_MSG_DEBUG("New Csc segment combination covering " << (*sit)->numberOfStations() << " station ");
216 
217  // loop over segments in combination
218  unsigned int nstations = (*sit)->numberOfStations();
219  for (unsigned int i = 0; i != nstations; ++i) {
220  Muon::MuonSegmentCombination::SegmentVec* stationSegs = (*sit)->stationSegments(i);
221 
222  ATH_MSG_VERBOSE("New Csc station with " << stationSegs->size() << " segments ");
223 
224  Muon::MuonSegmentCombination::SegmentVec::iterator segit = stationSegs->begin();
225  Muon::MuonSegmentCombination::SegmentVec::iterator segit_end = stationSegs->end();
226 
227  for (; segit != segit_end; ++segit) {
228  Muon::MuonSegment* seg = (*segit).get();
229 
230  if (!seg) {
231  ATH_MSG_WARNING(" go NULL pointer for MuonSegment ");
232  continue;
233  }
234 
235  std::shared_ptr<MuonCalibSegment> CscSeg{createMuonCalibSegment(*seg, MuonDetMgr)};
236  CscSeg->setAuthor(seg->author());
237  calibpat->addMuonSegment(CscSeg);
238  }
239  }
240 
241  // add pattern to segment
242  patterns->push_back(calibpat);
243  }
244  }
245  // store patterns in storegate
246  ATH_CHECK(savePatterns(ctx, std::move(patterns)));
247  return StatusCode::SUCCESS;
248  }
249 
251  if (seg.numberOfContainedROTs() == 0) {
252  ATH_MSG_DEBUG(" Oops, segment without hits!!! ");
253  return Identifier();
254  }
255 
256  for (unsigned int irot = 0; irot < seg.numberOfContainedROTs(); irot++) {
257  // use pointer to rot
258  const Trk::RIO_OnTrack* rot = seg.rioOnTrack(irot);
259 
260  if (m_idHelperSvc->isMdt(rot->identify())) {
261  return rot->identify();
262  } else if (m_idHelperSvc->isCsc(rot->identify())) {
263  return rot->identify();
264  }
265  }
266 
267  // if we get here the segment did not contain any csc or mdt hits, in which case we return the identifier of the first rot
268  return seg.rioOnTrack(0)->identify();
269  }
270 
272  const MuonGM::MuonDetectorManager* MuonDetMgr) const {
273  if (m_idHelperSvc->isMdt(id)) {
274  const MuonGM::MdtReadoutElement* detEl = MuonDetMgr->getMdtReadoutElement(id);
275  if (!detEl) {
276  ATH_MSG_WARNING("getGlobalToStation failed to retrieve detEL byebye");
277  } else {
278  return detEl->GlobalToAmdbLRSTransform();
279  }
280  } else if (m_idHelperSvc->isCsc(id)) {
281  const MuonGM::CscReadoutElement* detEl = MuonDetMgr->getCscReadoutElement(id);
282  if (!detEl) {
283  ATH_MSG_WARNING("getGlobalToStation failed to retrieve detEL byebye");
284  } else {
285  return detEl->transform().inverse();
286  }
287  } else if (m_idHelperSvc->isTgc(id)) {
288  const MuonGM::TgcReadoutElement* detEl = MuonDetMgr->getTgcReadoutElement(id);
289  if (!detEl) {
290  ATH_MSG_WARNING("getGlobalToStation failed to retrieve detEL byebye");
291  } else {
292  return detEl->transform().inverse();
293  }
294  } else if (m_idHelperSvc->isRpc(id)) {
295  const MuonGM::RpcReadoutElement* detEl = MuonDetMgr->getRpcReadoutElement(id);
296  if (!detEl) {
297  ATH_MSG_WARNING("getGlobalToStation failed to retrieve detEL byebye");
298  } else {
299  return detEl->transform().inverse();
300  }
301  }
302  ATH_MSG_WARNING(" Oops, should not be here, returning default transform ");
303  return Amg::Transform3D();
304  }
306  const MuonGM::MuonDetectorManager* MuonDetMgr) const {
307  // convert MuonSegment to MuonCalibSegment
308 
309  Identifier chid = getChId(seg);
310 
311  // global to station transformation for this chamber
312  Amg::Transform3D gToStationCheck = seg.associatedSurface().transform().inverse();
313  Amg::Transform3D gToStation = getGlobalToStation(chid, MuonDetMgr);
314  // create the local position and direction vector
315  const Amg::Vector3D& segPosG(seg.globalPosition());
316  const Amg::Vector3D& segDirG(seg.globalDirection());
317 
318  // calculate local position and direction of segment
319  Amg::Vector3D segPosL = gToStation * segPosG;
320  Amg::Vector3D segDirL = gToStation.linear() * segDirG;
321  Amg::Vector3D segDirLCheck = gToStationCheck.linear() * segDirG;
322 
323  double qualityFactor(1e9);
324  if (seg.fitQuality()) { qualityFactor = seg.fitQuality()->chiSquared(); }
325  // get segment quality
326  unsigned int segQuality = getQuality(seg);
327 
328  // pointer to new MuonSegment
329  MuonCalibSegment* mdtSeg =
330  new MuonCalibSegment(qualityFactor, segPosL, Amg::Vector3D(segDirL.unit()), gToStation.inverse(), segQuality);
331  double t0Shift = 0.;
332  if (seg.hasFittedT0()) { mdtSeg->setFittedT0(seg.time()); }
333 
334  Identifier cachedId; // Cached Identifier of previous hit (invalid for now)
335 
336  double chi2check = 0;
337  double thetap = std::atan2(mdtSeg->direction().y(), mdtSeg->direction().z());
338  double cosin = std::cos(thetap);
339  double sinus = std::sin(thetap);
340  double thetan = std::atan2(mdtSeg->direction().z(), mdtSeg->direction().y());
341  double thetaCheck = std::atan2(segDirLCheck[2], segDirLCheck[1]);
342  ATH_MSG_DEBUG(" MuonSegment TO CalibSegment segment found ");
343  if (msgLvl(MSG::DEBUG)) {
344  if (std::abs(thetaCheck - thetan) > 0.0001) ATH_MSG_DEBUG(" ALARM angle difference " << thetaCheck - thetan);
345  ATH_MSG_DEBUG(" segPosL " << segPosL << " segPosG " << segPosG << " local angle " << thetan << " thetaCheck " << thetaCheck);
346  ATH_MSG_DEBUG(" segDirL " << segDirL << " segDirG " << segDirG << " phi " << segDirG.phi() << " segDirLCheck " << segDirLCheck);
347  }
348  bool segment_with_multiple_t0s(false);
349  // for debug purposes count number of mdt,csc,tgc and rpc segments
350  int nm(0), nr(0), nt(0), nc(0);
351 
352  // loop over hits
353  const std::vector<const Trk::MeasurementBase*>& rots = seg.containedMeasurements();
354  std::vector<const Trk::MeasurementBase*>::const_iterator rit = rots.begin();
355  std::vector<const Trk::MeasurementBase*>::const_iterator rit_end = rots.end();
356  for (; rit != rit_end; ++rit) {
357  Identifier id;
358  const Trk::RIO_OnTrack* rot = dynamic_cast<const Trk::RIO_OnTrack*>(*rit);
359  const Trk::CompetingRIOsOnTrack* rotc = dynamic_cast<const Trk::CompetingRIOsOnTrack*>(*rit);
360  bool competingRio = false;
361  if (rot) {
362  // loop over Rios
363  const Trk::PrepRawData* prd = rot->prepRawData();
364  id = prd->identify();
365  } else {
366  // loop over Competing Rios
367  if (rotc) {
368  id = rotc->rioOnTrack(0).identify();
369  competingRio = true;
370  } else {
371  continue;
372  }
373  }
374 
375  if (m_idHelperSvc->isMdt(id)) {
376  if (competingRio) {
377  ATH_MSG_WARNING(" MDT hit is competing Rio !!! ");
378  continue;
379  }
380  // Mdt digit
381  ++nm;
382 
383  const Muon::MdtDriftCircleOnTrack* mrot = dynamic_cast<const Muon::MdtDriftCircleOnTrack*>(rot);
384  if (!mrot) {
385  ATH_MSG_WARNING("This is not a MdtDriftCircleOnTrack!!! ");
386  continue;
387  }
388  // mdtSegment = true;
389 
390  // get digit from segment
391  const Muon::MdtPrepData* prd = mrot->prepRawData();
392 
393  // digit identifier
394  id = prd->identify();
395 
396  // get MdtDetectorElement for current digit
397  const MuonGM::MdtReadoutElement* detEl = prd->detectorElement();
398 
399  // get tube geometry
400  const Trk::StraightLineSurface* pStraightLineSurface =
401  dynamic_cast<const Trk::StraightLineSurface*>(&(detEl->surface(prd->identify())));
402  if (!pStraightLineSurface) {
403  ATH_MSG_WARNING("This has no StraightLineSurface !!! ");
404  continue;
405  }
406 
407  // Prd has no second coordinate
408  Amg::Vector3D tubePosLoc = gToStation * prd->globalPosition();
409 
410  // Get local tube direction, orient tube direction along the x local axis direction and get all DCA stuff in local
411  // coordinates
412  Amg::Vector3D tubeDirGlo = (pStraightLineSurface->transform()).rotation().col(2);
413  Amg::Vector3D tubeDirLoc = gToStation.linear() * tubeDirGlo;
414  ATH_MSG_DEBUG(" tubeDirLoc " << tubeDirLoc);
415  tubeDirLoc = tubeDirLoc.unit();
416  if (tubeDirLoc.x() < 0.) tubeDirLoc = -tubeDirLoc;
417 
418  Amg::Vector3D segPosLoc(mdtSeg->position());
419  Amg::Vector3D segDirLoc(mdtSeg->direction());
420  segDirLoc = segDirLoc.unit();
421 
422  Amg::Vector3D TubSegLoc(segPosLoc - tubePosLoc);
423 
424  Amg::Vector3D segDirLocprojected = segDirLoc - (tubeDirLoc.dot(segDirLoc)) * tubeDirLoc;
425  segDirLocprojected = segDirLocprojected.unit();
426 
427  double ImpactParameter = tubeDirLoc.dot(TubSegLoc.cross(segDirLocprojected));
428 
429  double ScaleDenomi = 1. - std::pow(tubeDirLoc.dot(segDirLoc), 2);
430  double ScaleOnTube = (tubeDirLoc.dot(TubSegLoc) - (segDirLoc.dot(TubSegLoc)) * (tubeDirLoc.dot(segDirLoc))) / ScaleDenomi;
431  double ScaleOnSeg = (-segDirLoc.dot(TubSegLoc) + (tubeDirLoc.dot(TubSegLoc)) * (tubeDirLoc.dot(segDirLoc))) / ScaleDenomi;
432 
433  Amg::Vector3D tubePosLocAtDCA = tubePosLoc + ScaleOnTube * tubeDirLoc;
434  Amg::Vector3D segPosLocAtDCA = segPosLoc + ScaleOnSeg * segDirLoc;
435 
436  Amg::Vector3D segPosAtDCA = gToStation.inverse() * segPosLocAtDCA;
437 
438  // global and local position of rot
439  Amg::Vector3D trk_pos_rot(mrot->globalPosition());
440  Amg::Vector3D trk_pos_loc_rot = gToStation * trk_pos_rot;
441 
442  double rtrk = cosin * (mdtSeg->position().y() - tubePosLoc.y()) - sinus * (mdtSeg->position().z() - tubePosLoc.z());
443 
444  // Recalculate Point of closest approach (taking local x from second measurments)
445  double locx = trk_pos_loc_rot.x();
446  double locy = tubePosLoc.y() + cosin * rtrk;
447  double locz = tubePosLoc.z() - sinus * rtrk;
448  Amg::Vector3D trk_pos_loc(locx, locy, locz);
449  Amg::Vector3D trk_pos = gToStation.inverse() * trk_pos_loc;
450  ATH_MSG_DEBUG(" trk_pos_loc_rot " << trk_pos_loc_rot << " tubePosLoc " << tubePosLoc << " trk_pos_loc " << trk_pos_loc
451  << " trk_pos_rot " << trk_pos_rot);
452 
453  ATH_MSG_DEBUG(" standard rtrk " << rtrk << " ImpactParameter " << ImpactParameter << " diff rtrk " << rtrk - ImpactParameter
454  << " trk_pos " << trk_pos << " OR segPosAtDCA " << segPosAtDCA);
455 
456  if (std::abs(rtrk - ImpactParameter) > 0.001)
457  ATH_MSG_DEBUG(" ALARM Impact parameter difference " << rtrk - ImpactParameter);
458 
459  // Alternative
460  if (seg.author() == 3 || m_newImpactParameter) {
461  rtrk = ImpactParameter;
462  trk_pos = segPosAtDCA;
463  }
464 
465  ATH_MSG_DEBUG("MDT RIO tdc " << prd->tdc() << " adc " << prd->adc() << " r_time "
466  << rot->localParameters()[Trk::driftRadius] << " r_track " << rtrk);
467 
468  tubePosLoc[Trk::locX] = trk_pos_loc.x();
469 
470  // Alternative
471  if (seg.author() == 3) { tubePosLoc = tubePosLocAtDCA; }
472 
473  double xLocTwin(-99999999.);
474 
475  // Store local twin tube coordinate
476  if (prd->localPosition()[Trk::locY]) {
477  Identifier test_prd_Id = prd->detectorElement()->identify();
478  ATH_MSG_DEBUG(" Twin Position : prd->localPosition()[Trk::locY] = "
479  << prd->localPosition()[Trk::locY] << " in station "
480  << m_idHelperSvc->mdtIdHelper().stationNameString(m_idHelperSvc->mdtIdHelper().stationName(test_prd_Id))
481  << " multilayer = " << m_idHelperSvc->mdtIdHelper().multilayer(test_prd_Id)
482  << " layer = " << m_idHelperSvc->mdtIdHelper().tubeLayer(test_prd_Id)
483  << " tube = " << m_idHelperSvc->mdtIdHelper().tube(test_prd_Id)
484  << " modulo4 = " << (m_idHelperSvc->mdtIdHelper().tube(test_prd_Id) % 4));
485 
486  Amg::Vector3D lposTrking(0., 0., prd->localPosition()[Trk::locY]);
487  Amg::Vector3D gposAMDB = detEl->surface(id).transform() * lposTrking;
488  Amg::Vector3D lposAMDB = detEl->GlobalToAmdbLRSTransform() * gposAMDB;
489  ATH_MSG_DEBUG(" CHECK lposTrking = " << lposTrking.z() << " lposAMDB " << lposAMDB.x());
490 
491  xLocTwin = lposAMDB.x();
492  }
493 
494  Amg::Vector3D tubePos = gToStation.inverse() * tubePosLoc;
495  // If the wire is rotated wrt segmentsurface we need this transform
496  // get distance to readoud from detector manager
497  double distRo_det = detEl->distanceFromRO(mrot->globalPosition(), id);
498 
499  // create new MdtCalibHit
500  MdtCalibHit calibHit(id, prd->tdc(), prd->adc(), tubePos, tubePosLoc, detEl);
501  calibHit.setGlobalPointOfClosestApproach(trk_pos);
502 
503  calibHit.setLocalPos(tubePosLoc);
504  calibHit.setLocXtwin(xLocTwin);
505 
506  MdtCalibrationSvcSettings settings;
507  // Copy settings from ROT
508  // Window lower & upper bounds not set yet
509  const Muon::MuonDriftCircleErrorStrategy& rotErrorStrategy = mrot->errorStrategy();
510  settings.doTof = rotErrorStrategy.creationParameter(Muon::MuonDriftCircleErrorStrategy::TofCorrection);
511  settings.doProp = rotErrorStrategy.creationParameter(Muon::MuonDriftCircleErrorStrategy::PropCorrection);
512  settings.doTemp = rotErrorStrategy.creationParameter(Muon::MuonDriftCircleErrorStrategy::TempCorrection);
515  settings.doSlew = rotErrorStrategy.creationParameter(Muon::MuonDriftCircleErrorStrategy::SlewCorrection);
517  settings.windowSetting = rotErrorStrategy.calibWindow();
518  settings.initialize();
519  bool apply_t0 = ((m_updateForT0Shift < 0) ? rotErrorStrategy.creationParameter(Muon::MuonDriftCircleErrorStrategy::T0Refit)
520  : static_cast<bool>(m_updateForT0Shift)) &&
521  seg.hasFittedT0();
522  if (apply_t0 && (t0Shift == 0.0)) { t0Shift = seg.time(); }
523  MdtCalibrationSvcInput input;
524  if (m_doTof) input.tof = calibHit.globalPointOfClosestApproach().mag() * (1. / 299.792458);
525  input.trackDirection = &seg.globalDirection();
526 
527  input.pointOfClosestApproach = &calibHit.globalPointOfClosestApproach();
528  bool sameChamber = false;
529  if (cachedId.is_valid()) {
530  sameChamber = (m_idHelperSvc->mdtIdHelper().stationName(id) == m_idHelperSvc->mdtIdHelper().stationName(cachedId)) &&
531  (m_idHelperSvc->mdtIdHelper().stationEta(id) == m_idHelperSvc->mdtIdHelper().stationEta(cachedId)) &&
532  (m_idHelperSvc->mdtIdHelper().stationPhi(id) == m_idHelperSvc->mdtIdHelper().stationPhi(cachedId));
533  }
534  if (!sameChamber) ATH_MSG_DEBUG("Moving to a new chamber! " << cachedId << " to " << id);
535  // We're done with the cached Id for now, so immediately reassign it
536  cachedId = id;
537 
538  if (t0Shift == 0 || seg.author() != 3 || sameChamber) {
539  // There is one t0 shift for the whole segment - only one calibration is needed
540  input.tof += t0Shift;
541  ATH_MSG_DEBUG("Author " << seg.author() << " added single t0 shift of " << t0Shift);
542  } else {
543  segment_with_multiple_t0s = true;
544  // We may be in a new chamber, with a different fitted t0
545  m_calibrationTool->driftRadiusFromTime(calibHit, input, settings);
546 
547  // Reset the value of the t0 shift
548  t0Shift = calibHit.driftTime() - mrot->driftTime();
549  input.tof += t0Shift;
550  ATH_MSG_DEBUG("t0 shift updated to " << t0Shift);
551 
552  if (std::abs(seg.time() - t0Shift) > 0.01 && std::abs(t0Shift) > 0.01) {
553  ATH_MSG_INFO(" Inconsistent fitted t0 found: from ROT " << t0Shift << " from segment " << seg.time());
554  }
555  }
556 
557  // Calculate drift radius from drift time using MdtCalibrationSvc
558  double oldDriftTime = calibHit.driftTime(); // 0 unless we shift t0
559  m_calibrationTool->driftRadiusFromTime(calibHit, input, settings);
560 
561  double timeDif = calibHit.driftTime() - mrot->driftTime();
562 
563  // Store Sign of DriftRadius from Tracking (ROT) convention
564  float driftR = calibHit.driftRadius();
565  float sigmaDriftR = calibHit.sigmaDriftRadius();
566  if (rot->localParameters()[Trk::driftRadius] < 0) {
567  driftR = -driftR;
568  calibHit.setDriftRadius(driftR, sigmaDriftR);
569  }
570 
571  if (std::abs(timeDif) >= 0.1 && !segment_with_multiple_t0s) {
572  ATH_MSG_WARNING(" Bad T0Shift " << t0Shift << " cor " << timeDif << " ROT " << mrot->driftRadius() << " t "
573  << mrot->driftTime() << " calib " << calibHit.driftRadius() << " t "
574  << calibHit.driftTime() << " old " << oldDriftTime << " author " << seg.author());
575  }
576  if (std::abs(mrot->driftRadius() - calibHit.driftRadius()) > 0.01 && !segment_with_multiple_t0s) {
577  ATH_MSG_WARNING("Detected radius difference> 10 mu. MROT r= " << mrot->driftRadius()
578  << " calib r=" << calibHit.driftRadius());
579  }
580  ATH_MSG_DEBUG("B-field correction: " << calibHit.lorentzTime());
581 
582  // fill distance to track
583  calibHit.setDistanceToTrack(rtrk, 0.);
584 
585  // set distance to readout
586  calibHit.setDistanceToReadout(distRo_det);
587 
588  // convert MdtCalibHit to MdtCalibHitBase and then delete it
589  // add hit to MuonSegment
590 
591  double resi = std::abs(driftR) - std::abs(rtrk);
592  if (rtrk < 0) resi = -resi;
593  double error2 = rot->localCovariance()(0, 0);
594  double chi2c = (resi * resi) / error2;
595  chi2check += chi2c;
596  if (msgLvl(MSG::DEBUG) && seg.author() == 4) {
597  // Craig Blocker his checks
598  MuonFixedId fixid = m_idToFixedIdTool->idToFixedId(id);
599  std::string st = fixid.stationNumberToFixedStationString(fixid.stationName());
600  int ml = fixid.mdtMultilayer();
601  int la = fixid.mdtTubeLayer();
602  ATH_MSG_DEBUG(" station " << st << " eta " << fixid.eta() << " phi " << fixid.phi() << " ML " << ml << " Layer " << la
603  << " drift R " << driftR << " MROT drift R " << mrot->driftRadius() << " drift Time "
604  << mrot->driftTime() << " ROT error " << std::sqrt(error2) << " residual " << resi
605  << " tubePosLoc " << tubePosLoc << " t0 shift " << t0Shift << " chi2c " << chi2c);
606  if (std::sqrt(error2) < 1.999) ATH_MSG_DEBUG(" ALARM TOO SMALL drift error ");
607  if (chi2c > qualityFactor) ATH_MSG_DEBUG(" ALARM TOO LARGE chi2 single hit ");
608  }
609  MdtCalibHitBase* basehit = calibHit.hitBase(*m_idToFixedIdTool);
610  basehit->setSegmentT0Applied(apply_t0);
611  mdtSeg->addHitOnTrack(basehit);
612 
613  } else if (m_idHelperSvc->isRpc(id)) {
614  // rpc ROT
615  ++nr;
616 
617  int nRios = 1;
618 
619  if (competingRio) nRios = rotc->numberOfContainedROTs();
620  for (int irio = 0; irio < nRios; ++irio) {
621  // Loop over competing Rios or Rios
622  if (competingRio) rot = &rotc->rioOnTrack(irio);
623 
624  if (msgLvl(MSG::DEBUG)) {
625  if (!competingRio) ATH_MSG_DEBUG("Found RPC Rio !");
626  if (competingRio) ATH_MSG_DEBUG("Found RPC Competing Rio !");
627  }
628 
629  const Muon::RpcClusterOnTrack* rrot = dynamic_cast<const Muon::RpcClusterOnTrack*>(rot);
630  if (!rrot) {
631  ATH_MSG_WARNING("This is not a RpcClusterOnTrack!!! ");
632  continue;
633  }
634 
635  const Muon::RpcPrepData* rprd = rrot->prepRawData();
636  id = rprd->identify();
637  int nStrips = rprd->rdoList().size();
638  // get detector element
639  const MuonGM::RpcReadoutElement* detEl = rprd->detectorElement();
640 
641  double stripWidth = detEl->StripWidth(m_idHelperSvc->rpcIdHelper().measuresPhi(id));
642  double time = rprd->time();
643  double error = std::sqrt(rrot->localCovariance()(0, 0));
644  Amg::Vector3D rgp = rrot->globalPosition();
645 
646  Amg::Vector3D rlp = gToStation * rgp;
647 
648  // get strip lengths
649  double stripLen = detEl->StripLength(m_idHelperSvc->rpcIdHelper().measuresPhi(id));
650 
651  double distRO;
652  if (m_idHelperSvc->rpcIdHelper().measuresPhi(id)) {
653  distRO = detEl->distanceToPhiReadout(rgp, id);
654  } else {
655  distRO = detEl->distanceToEtaReadout(rgp, id);
656  }
657 
658  RpcCalibHitBase* rpcCH = new RpcCalibHitBase(nStrips, stripWidth, time, error, rgp, rlp);
659 
660  MuonFixedId fixid = m_idToFixedIdTool->idToFixedId(id);
661  rpcCH->setIdentifier(fixid);
662  rpcCH->setStripLength(stripLen);
663  rpcCH->setDistanceToRO(distRO);
664 
665  mdtSeg->addHitOnTrack(rpcCH);
666  }
667  } else if (m_idHelperSvc->isTgc(id)) {
668  ++nt;
669 
670  int nRios = 1;
671 
672  if (competingRio) nRios = rotc->numberOfContainedROTs();
673  for (int irio = 0; irio < nRios; ++irio) {
674  // Loop over competing Rios or Rios
675  if (competingRio) rot = &rotc->rioOnTrack(irio);
676 
677  if (msgLvl(MSG::DEBUG)) {
678  if (!competingRio) ATH_MSG_DEBUG("Found TGC Rio !");
679  if (competingRio) ATH_MSG_DEBUG("Found TGC Competing Rio !");
680  }
681 
682  const Muon::TgcClusterOnTrack* trot = dynamic_cast<const Muon::TgcClusterOnTrack*>(rot);
683  if (!trot) {
684  ATH_MSG_WARNING("This is not a TgcClusterOnTrack!!! ");
685  continue;
686  }
687 
688  const Muon::TgcPrepData* tprd = trot->prepRawData();
689  id = tprd->identify();
690  ATH_MSG_DEBUG("TGC RIO ");
691 
692  int nStrips = tprd->rdoList().size();
693 
694  double stripWidth;
695  bool measuresPhi = (bool)m_idHelperSvc->tgcIdHelper().isStrip(tprd->identify());
696  int gasGap = m_idHelperSvc->tgcIdHelper().gasGap(tprd->identify());
697  int channel = m_idHelperSvc->tgcIdHelper().channel(tprd->identify());
698  const MuonGM::TgcReadoutElement* detEl = tprd->detectorElement();
699  if (!measuresPhi) {
700  stripWidth = detEl->gangMaxZ(gasGap, channel) - detEl->gangMinZ(gasGap, channel);
701  } else {
702  Amg::Vector3D localPos = detEl->transform(tprd->identify()).inverse() * detEl->channelPos(tprd->identify());
703  stripWidth = detEl->stripMaxX(gasGap, channel, localPos.y()) - detEl->stripMinX(gasGap, channel, localPos.y());
704  }
705 
706  double error = std::sqrt(trot->localCovariance()(0, 0));
707  Amg::Vector3D tgp = trot->globalPosition();
708 
709  Amg::Vector3D tlp = gToStation * tgp;
710  TgcCalibHitBase* tgcCH = new TgcCalibHitBase(nStrips, stripWidth, error, tgp, tlp);
711 
712  MuonFixedId fixid = m_idToFixedIdTool->idToFixedId(id);
713 
714  tgcCH->setIdentifier(fixid);
715 
716  mdtSeg->addHitOnTrack(tgcCH);
717  }
718  } else if (m_idHelperSvc->isCsc(id)) {
719  ++nc;
720 
721  int nRios = 1;
722 
723  if (competingRio) nRios = rotc->numberOfContainedROTs();
724  for (int irio = 0; irio < nRios; ++irio) {
725  // Loop over competing Rios or Rios
726  if (competingRio) rot = &rotc->rioOnTrack(irio);
727  ATH_MSG_DEBUG((competingRio ? "Found CSC Competing Rio !" : "Found CSC Rio !"));
728  const Muon::CscClusterOnTrack* crot = dynamic_cast<const Muon::CscClusterOnTrack*>(rot);
729  if (!crot) {
730  ATH_MSG_WARNING("This is not a CscClusterOnTrack!!!");
731  continue;
732  }
733 
734  const Muon::CscPrepData* cprd = crot->prepRawData();
735  Identifier id = cprd->identify();
736 
737  int nStrips = cprd->rdoList().size();
738 
739  int measuresPhi = m_idHelperSvc->cscIdHelper().measuresPhi(id);
740  int chamberLayer = m_idHelperSvc->cscIdHelper().chamberLayer(id);
741  double stripWidth = cprd->detectorElement()->cathodeReadoutPitch(chamberLayer, measuresPhi);
742  int charge = cprd->charge();
743 
744  double error = std::sqrt(crot->localCovariance()(0, 0));
745  Amg::Vector3D cgp = crot->globalPosition();
746 
747  Amg::Vector3D clp = gToStation * cgp;
748  CscCalibHitBase* cscCH = new CscCalibHitBase(nStrips, stripWidth, charge, error, cgp, clp);
749 
750  MuonFixedId fixid = m_idToFixedIdTool->idToFixedId(id);
751 
752  cscCH->setIdentifier(fixid);
753 
754  mdtSeg->addHitOnTrack(cscCH);
755  ATH_MSG_DEBUG("mdtSeg->cscHitsOnTrack()=" << mdtSeg->cscHitsOnTrack());
756  ATH_MSG_DEBUG("mdtSeg->hitsOnTrack()=" << mdtSeg->hitsOnTrack());
757  // set the global to amdb transform in case of first hit
758  }
759 
760  } else {
761  ATH_MSG_WARNING("ERROR unknown RIO type ");
762  }
763  }
764  ATH_MSG_VERBOSE("Number of *&* mdt " << nm << " rpc " << nr << " tgc " << nt << " csc " << nc);
765 
766  // add magnetic-field entries for MDT hits //
767 
768  if (msgLvl(MSG::DEBUG) && seg.author() == 4) {
769  if (qualityFactor > 0.0001) {
770  if (chi2check / qualityFactor > 1.01 || chi2check / qualityFactor < 0.99) {
771  ATH_MSG_DEBUG(" ALARM wrong chi2 "
772  << "Mdt segment chi2 " << qualityFactor << " mdt hits " << nm << " chi2check " << chi2check << " t0Shift "
773  << t0Shift);
774  } else {
775  ATH_MSG_DEBUG(" good chi2 "
776  << "Mdt segment chi2 " << qualityFactor << " mdt hits " << nm << " chi2check " << chi2check << " t0Shift "
777  << t0Shift);
778  }
779  } else {
780  ATH_MSG_DEBUG(" good chi2 "
781  << "Mdt segment chi2 " << qualityFactor << " mdt hits " << nm << " chi2check " << chi2check << " t0Shift "
782  << t0Shift);
783  }
784  }
785 
786  return mdtSeg;
787  } // createMuonCalibSegment
788 
790  ATH_MSG_VERBOSE("createMuonCalibPattern");
791  MuonCalibPattern* calibpat = nullptr;
793  if (pat) {
794  const Trk::TrackParameters* trkparameters = pat->trackParameter();
795  const Trk::Perigee* perigee = dynamic_cast<const Trk::Perigee*>(trkparameters);
796  if (perigee) {
797  const AmgVector(5) parameters = perigee->parameters();
798  pars.phi = parameters[Trk::phi];
799  pars.theta = parameters[Trk::theta];
800  pars.dist0 = -perigee->position().y() * std::cos(pars.phi) + perigee->position().x() * std::sin(pars.phi);
801  double charge = pars.dist0 > 0 ? 1. : -1;
802 
803  // Approximate conversion of radius of curvature to Pinv in MeV-1
804  pars.invP = (10. * charge) / (perigee->momentum().mag());
805  pars.z0 = perigee->position().z();
806  ATH_MSG_DEBUG(" r0,z0 " << pars.dist0 << " " << pars.z0 << " phi,theta " << pars.phi << " " << pars.theta);
807  ATH_MSG_DEBUG(" pat " << perigee->position() << " " << perigee->momentum());
808  } else {
809  ATH_MSG_WARNING("Trackparameters are not set or is not a Perigee!! Pattern gets empty parameters");
810  }
811 
812  // Here I have to add the nmdt, nrpc, ntgc and ncsc...
813  const std::vector<Muon::MuonPatternChamberIntersect>& mpcivec = pat->chamberData();
814  std::vector<Muon::MuonPatternChamberIntersect>::const_iterator pat_it = mpcivec.begin();
815  for (; pat_it != mpcivec.end(); ++pat_it) {
816  const std::vector<const Trk::PrepRawData*> prdvec = (*pat_it).prepRawDataVec();
817  std::vector<const Trk::PrepRawData*>::const_iterator prd_it = prdvec.begin();
818  for (; prd_it != prdvec.end(); ++prd_it) {
819  Identifier id = (*prd_it)->identify();
820  if (m_idHelperSvc->isMdt(id)) {
821  pars.nmdt += 1000; // a mdt is always an eta-hit.
822  } else if (m_idHelperSvc->isRpc(id)) {
823  if (m_idHelperSvc->rpcIdHelper().measuresPhi(id))
824  pars.nrpc += 1;
825  else
826  pars.nrpc += 1000;
827  } else if (m_idHelperSvc->isTgc(id)) {
828  if (m_idHelperSvc->tgcIdHelper().isStrip(id))
829  pars.ntgc += 1;
830  else
831  pars.ntgc += 1000;
832  } else if (m_idHelperSvc->isCsc(id)) {
833  if (m_idHelperSvc->cscIdHelper().measuresPhi(id))
834  pars.ncsc += 1;
835  else
836  pars.ncsc += 1000;
837  } else
838  ATH_MSG_INFO("PrepRawData on pat is not a muon-technom_logy");
839  }
840  }
841  calibpat = new MuonCalibPattern(pars);
842  } else {
843  ATH_MSG_DEBUG("WARNING, empty muoncalibpattern created");
844  calibpat = new MuonCalibPattern();
845  }
846  return calibpat;
847  }
848 
850  ATH_MSG_DEBUG(" plotting quality ");
851  // try to dynamic_cast to MdtSegmentQuality in order to obtain quality
852 
853  const Muon::MuonSegmentQuality* q = dynamic_cast<const Muon::MuonSegmentQuality*>(seg.fitQuality());
854 
855  if (!q) {
856  // NO quality available for CSC
857  return 0;
858  }
859  ATH_MSG_DEBUG("Got MuonSegmentQuality "
860  << " hots " << q->numberDoF() + 2 << " number of holes " << q->channelsWithoutHit().size());
861 
862  unsigned int packedInfo = 0;
863 
864  packedInfo += 100 * (q->channelsWithoutHit().size() < 9 ? q->channelsWithoutHit().size() : 9);
865 
866  ATH_MSG_DEBUG(" packedInfo " << packedInfo);
867  return packedInfo;
868  }
869 
870  template <class container_type>
872  const container_type*& container_ptr) const {
873  SG::ReadHandle<container_type> readHandle{key, ctx};
874  if (!readHandle.isValid()) {
875  ATH_MSG_WARNING("Failed to retrieve " << key.fullKey());
876  return StatusCode::FAILURE;
877  }
878  container_ptr = readHandle.cptr();
879 
880  const container_type* container{readHandle.cptr()};
881  if (!container) {
882  ATH_MSG_WARNING("Failed to retrieve " << key.fullKey());
883  return StatusCode::FAILURE;
884  }
885  return StatusCode::SUCCESS;
886  }
887 
888 } // namespace MuonCalib
Muon::MuonSegmentQuality
Definition: MuonSegmentQuality.h:34
xAOD::iterator
JetConstituentVector::iterator iterator
Definition: JetConstituentVector.cxx:68
MuonCalib::MuonSegmentToCalibSegment::m_calibrationTool
ToolHandle< MdtCalibrationTool > m_calibrationTool
pointer to MdtCalibSvc
Definition: MuonSegmentToCalibSegment.h:86
MuonGM::MuonDetectorManager::getRpcReadoutElement
const RpcReadoutElement * getRpcReadoutElement(const Identifier &id) const
access via extended identifier (requires unpacking)
Definition: MuonDetDescr/MuonReadoutGeometry/src/MuonDetectorManager.cxx:168
MuonCalib::MuonSegmentToCalibSegment::MuonSegmentToCalibSegment
MuonSegmentToCalibSegment(const std::string &name, ISvcLocator *pSvcLocator)
Algorithm constructor.
Definition: MuonSegmentToCalibSegment.cxx:29
make_hlt_rep.pars
pars
Definition: make_hlt_rep.py:90
MdtCalibHit::setLocalPos
void setLocalPos(const Amg::Vector3D &localPos)
sets the position in the station coordinates
Definition: MdtCalibHit.h:354
MuonCalib::MuonCalibSegment::hitsOnTrack
unsigned int hitsOnTrack() const
retrieve the sum of all XxxCalibHits assigned to the MuonCalibSegment
Definition: MuonCalibSegment.cxx:136
python.SystemOfUnits.second
int second
Definition: SystemOfUnits.py:120
Muon::MuonDriftCircleErrorStrategy
Definition: MuonDriftCircleErrorStrategy.h:15
Muon::MuonDriftCircleErrorStrategy::WireSagTimeCorrection
@ WireSagTimeCorrection
Wire sag correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:30
MuonGM::MuonClusterReadoutElement::transform
virtual const Amg::Transform3D & transform() const override
Return local to global transform.
Definition: MuonClusterReadoutElement.h:124
dumpTgcDigiDeadChambers.gasGap
list gasGap
Definition: dumpTgcDigiDeadChambers.py:33
DataModel_detail::const_iterator
Const iterator class for DataVector/DataList.
Definition: DVLIterator.h:82
MdtCalibHit::globalPointOfClosestApproach
const Amg::Vector3D & globalPointOfClosestApproach() const
retrieve the point of closest approach in global coordinates
Definition: MdtCalibHit.h:415
MuonPatternChamberIntersect.h
MuonCalib::TgcCalibHitBase
Definition: TgcCalibHitBase.h:43
MuonCalib::MuonSegmentToCalibSegment::m_newImpactParameter
Gaudi::Property< bool > m_newImpactParameter
Definition: MuonSegmentToCalibSegment.h:73
MuonCalibSegment.h
TrackParameters.h
MuonGM::RpcReadoutElement::StripLength
double StripLength(bool measphi) const
returns the strip length for the phi or eta plane
MuonCalib::MuonSegmentToCalibSegment::m_doTof
Gaudi::Property< bool > m_doTof
Definition: MuonSegmentToCalibSegment.h:98
Muon::MuonClusterOnTrack::globalPosition
virtual const Amg::Vector3D & globalPosition() const override
Returns global position.
Definition: MuonClusterOnTrack.cxx:93
plotting.yearwise_efficiency.channel
channel
Definition: yearwise_efficiency.py:28
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
Muon::MdtDriftCircleOnTrack::prepRawData
virtual const MdtPrepData * prepRawData() const override final
Returns the PrepRawData used to create this corrected measurement.
Definition: MdtDriftCircleOnTrack.h:257
Trk::locX
@ locX
Definition: ParamDefs.h:43
MuonCalib::MuonSegmentToCalibSegment::m_idToFixedIdTool
ToolHandle< IIdToFixedIdTool > m_idToFixedIdTool
Definition: MuonSegmentToCalibSegment.h:91
CompetingRIOsOnTrack.h
Trk::locY
@ locY
local cartesian
Definition: ParamDefs.h:44
Muon::CscPrepData::charge
int charge() const
Returns the charge.
Definition: CscPrepData.h:153
MuonCalib::MuonSegmentToCalibSegment::m_segment_authors
Gaudi::Property< std::vector< int > > m_segment_authors
Definition: MuonSegmentToCalibSegment.h:72
MuonCalib::MdtCalibHitBase::setSegmentT0Applied
void setSegmentT0Applied(bool flag)
sets flag if Segment T0 has been applied to hit
Definition: MdtCalibHitBase.cxx:102
SG::ReadHandle
Definition: StoreGate/StoreGate/ReadHandle.h:70
patterns
std::vector< std::string > patterns
Definition: listroot.cxx:187
Trk::ParametersT
Dummy class used to allow special convertors to be called for surfaces owned by a detector element.
Definition: EMErrorDetail.h:25
Muon::MuonSegment::rioOnTrack
const Trk::RIO_OnTrack * rioOnTrack(unsigned int) const
returns the RIO_OnTrack (also known as ROT) objects depending on the integer
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:187
conifer::pow
constexpr int pow(int x)
Definition: conifer.h:20
MuonGM::MuonReadoutElement::GlobalToAmdbLRSTransform
virtual Amg::Transform3D GlobalToAmdbLRSTransform() const
Definition: MuonDetDescr/MuonReadoutGeometry/src/MuonReadoutElement.cxx:153
MuonCalib::CscCalibHitBase
Definition: CscCalibHitBase.h:38
MuonCalib::MuonCalibPattern::defineParams
Definition: MuonCalibPattern.h:55
MdtCalibHit::setLocXtwin
void setLocXtwin(float xtwin)
sets twin local position
Definition: MdtCalibHit.h:403
MuonCalib::MuonFixedId::mdtMultilayer
int mdtMultilayer() const
Mdt specific:
Definition: MuonFixedId.h:835
Muon::TgcClusterOnTrack
Class to represent calibrated clusters formed from TGC strips.
Definition: TgcClusterOnTrack.h:46
MuonCalib::MuonCalibSegment
Definition: MuonCalibSegment.h:39
Muon::MuonDriftCircleErrorStrategy::calibWindow
unsigned long calibWindow() const
Returns calibration configuration.
Definition: MuonDriftCircleErrorStrategy.h:90
Trk::PrepRawData::rdoList
const std::vector< Identifier > & rdoList() const
return the List of rdo identifiers (pointers)
AthCommonMsg< Algorithm >::msgLvl
bool msgLvl(const MSG::Level lvl) const
Definition: AthCommonMsg.h:30
MuonCalib::MuonCalibSegment::position
const Amg::Vector3D & position() const
retrieve local position of segment (on station level)
Definition: MuonCalibSegment.cxx:186
Muon::MdtDriftCircleOnTrack::errorStrategy
const MuonDriftCircleErrorStrategy & errorStrategy() const
Get information about the creation strategy used by Muon::MdtDriftCircleOnTrackCreator when making th...
Definition: MdtDriftCircleOnTrack.h:283
MuonGM::RpcReadoutElement
An RpcReadoutElement corresponds to a single RPC module; therefore typicaly a barrel muon station con...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/RpcReadoutElement.h:54
Muon::TgcPrepData::detectorElement
virtual const MuonGM::TgcReadoutElement * detectorElement() const override final
Returns the detector element corresponding to this PRD The pointer will be zero if the det el is not ...
Definition: TgcPrepData.h:120
Trk::RIO_OnTrack
Definition: RIO_OnTrack.h:70
Muon::RpcClusterOnTrack
Class to represent calibrated clusters formed from RPC strips.
Definition: RpcClusterOnTrack.h:35
MuonSegmentQuality.h
MuonGM::CscReadoutElement
Definition: CscReadoutElement.h:56
drawFromPickle.cos
cos
Definition: drawFromPickle.py:36
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
MdtDriftCircleOnTrack.h
SG::ReadHandleKey
Property holding a SG store/key/clid from which a ReadHandle is made.
Definition: StoreGate/StoreGate/ReadHandleKey.h:39
Muon::MdtPrepData::adc
int adc() const
Returns the ADC (typically range is 0 to 250)
Definition: MdtPrepData.h:166
MuonSegmentToCalibSegment.h
Muon::MuonSegment::numberOfContainedROTs
unsigned int numberOfContainedROTs() const
number of RIO_OnTracks
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:199
Identifier::is_valid
bool is_valid() const
Check if id is in a valid state.
Muon::MuonSegment::hasFittedT0
bool hasFittedT0() const
returns whether the segment has a fitted t0
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:212
MuonCalib::MuonSegmentToCalibSegment::m_patternKey
SG::WriteHandleKey< MuonCalibPatternCollection > m_patternKey
pattern location
Definition: MuonSegmentToCalibSegment.h:77
Muon::MdtDriftCircleOnTrack::globalPosition
virtual const Amg::Vector3D & globalPosition() const override final
Returns the global Position.
Definition: MdtDriftCircleOnTrack.cxx:108
Muon::MuonDriftCircleErrorStrategy::PropCorrection
@ PropCorrection
Propagation correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:27
MdtCalibHit::setDistanceToReadout
void setDistanceToReadout(double dist)
sets the distance to read out
Definition: MdtCalibHit.h:387
MdtCalibHit::hitBase
MuonCalib::MdtCalibHitBase * hitBase(const MuonCalib::IIdToFixedIdTool &) const
return a pointer to the MdtCalibHit object to be used in the calibration framework
Definition: MdtCalibHit.cxx:29
Muon::MuonDriftCircleErrorStrategy::TempCorrection
@ TempCorrection
Temperature correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:28
MdtCalibHit::setGlobalPointOfClosestApproach
void setGlobalPointOfClosestApproach(const Amg::Vector3D &point)
sets point of closest approach in global coordinates
Definition: MdtCalibHit.h:356
Muon::MdtDriftCircleOnTrack::driftTime
double driftTime() const
Returns the value of the drift time used to obtain the drift radius.
Definition: MdtDriftCircleOnTrack.h:280
MuonGM::TgcReadoutElement::channelPos
Amg::Vector3D channelPos(const Identifier &id) const
Returns the position of the active channel (wireGang or strip)
Muon::MuonDriftCircleErrorStrategy::T0Refit
@ T0Refit
A special error was applied to account for the T0 refit (user defined via jobProperties)
Definition: MuonDriftCircleErrorStrategy.h:24
MuonGM::MdtReadoutElement::distanceFromRO
double distanceFromRO(const Amg::Vector3D &GlobalHitPosition, const Identifier &id) const
MuonCalib::MuonCalibSegment::direction
const Amg::Vector3D & direction() const
retrieve local direction of segment (on station level) retrieve the transformation from local chamber...
Definition: MuonCalibSegment.cxx:187
MuonGM::MuonDetectorManager::getTgcReadoutElement
const TgcReadoutElement * getTgcReadoutElement(const Identifier &id) const
access via extended identifier (requires unpacking)
Definition: MuonDetDescr/MuonReadoutGeometry/src/MuonDetectorManager.cxx:247
TgcClusterOnTrack.h
Muon::RpcPrepData::time
float time() const
Returns the time.
Definition: RpcPrepData.h:197
Muon::TgcClusterOnTrack::prepRawData
virtual const TgcPrepData * prepRawData() const
Returns the TgcPrepData - is a TRT_DriftCircle in this scope.
Definition: TgcClusterOnTrack.h:129
MuonCalib::MuonSegmentToCalibSegment::execute
StatusCode execute()
Algorithm execute, called once per event.
Definition: MuonSegmentToCalibSegment.cxx:63
MuonCalib::MuonSegmentToCalibSegment::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonSegmentToCalibSegment.h:83
WriteHandle.h
Handle class for recording to StoreGate.
Muon::MuonDriftCircleErrorStrategy::SlewCorrection
@ SlewCorrection
Slewing correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:31
Trk::CompetingRIOsOnTrack::rioOnTrack
virtual const RIO_OnTrack & rioOnTrack(unsigned int) const =0
returns the RIO_OnTrack (also known as ROT) objects depending on the integer.
MuonCalib::MuonCalibSegment::cscHitsOnTrack
unsigned int cscHitsOnTrack() const
retrieve the number of CscCalibHitBase s assigned to this segment
Definition: MuonCalibSegment.cxx:156
RpcClusterOnTrack.h
MdtCalibHit::driftRadius
double driftRadius() const
retrieve drift radius
Definition: MdtCalibHit.h:425
MdtCalibHit::setDriftRadius
void setDriftRadius(double r, double sigmaR)
sets drift radius and drift radius error
Definition: MdtCalibHit.h:364
MuonCalib::MuonSegmentToCalibSegment::getQuality
unsigned int getQuality(const Muon::MuonSegment &seg) const
Definition: MuonSegmentToCalibSegment.cxx:849
MuonCalib::MuonSegmentToCalibSegment::getChId
Identifier getChId(const Muon::MuonSegment &seg) const
Definition: MuonSegmentToCalibSegment.cxx:250
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
MuonGM::MuonDetectorManager::getMdtReadoutElement
const MdtReadoutElement * getMdtReadoutElement(const Identifier &id) const
access via extended identifier (requires unpacking)
Definition: MuonDetDescr/MuonReadoutGeometry/src/MuonDetectorManager.cxx:204
MuonGM::MdtReadoutElement
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MdtReadoutElement.h:50
MuonCalib::MuonSegmentToCalibSegment::retrieveContainer
StatusCode retrieveContainer(const EventContext &ctx, const SG::ReadHandleKey< container_type > &key, const container_type *&container_ptr) const
Definition: MuonSegmentToCalibSegment.cxx:871
MuonGM::RpcReadoutElement::distanceToPhiReadout
double distanceToPhiReadout(const Amg::Vector3D &P) const
Definition: MuonDetDescr/MuonReadoutGeometry/src/RpcReadoutElement.cxx:223
Trk::CompetingRIOsOnTrack::numberOfContainedROTs
virtual unsigned int numberOfContainedROTs() const =0
Number of RIO_OnTracks to be contained by this CompetingRIOsOnTrack.
lumiFormat.i
int i
Definition: lumiFormat.py:92
Muon::RpcPrepData
Class to represent RPC measurements.
Definition: RpcPrepData.h:35
Muon::RpcPrepData::detectorElement
virtual const MuonGM::RpcReadoutElement * detectorElement() const override final
Returns the detector element corresponding to this PRD.
Definition: RpcPrepData.h:202
MuonGM::MuonDetectorManager::getCscReadoutElement
const CscReadoutElement * getCscReadoutElement(const Identifier &id) const
access via extended identifier (requires unpacking)
Definition: MuonDetDescr/MuonReadoutGeometry/src/MuonDetectorManager.cxx:225
Identifier
Definition: DetectorDescription/Identifier/Identifier/Identifier.h:32
Muon::CscPrepData
Class representing clusters from the CSC.
Definition: CscPrepData.h:39
Trk::theta
@ theta
Definition: ParamDefs.h:72
Muon::MuonDriftCircleErrorStrategy::TofCorrection
@ TofCorrection
Time of flight correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:26
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
MdtCalibHit::sigmaDriftRadius
double sigmaDriftRadius() const
retrieve the error on the radius of the drift circle
Definition: MdtCalibHit.h:427
xAOD::rotation
rotation
Definition: TrackSurface_v1.cxx:15
AmgVector
AmgVector(4) T2BSTrackFilterTool
Definition: T2BSTrackFilterTool.cxx:114
Trk::driftRadius
@ driftRadius
trt, straws
Definition: ParamDefs.h:59
Muon::IMuonPatternSegmentAssociationTool::AssociationMapRange
std::pair< AssociationMap::const_iterator, AssociationMap::const_iterator > AssociationMapRange
Definition: IMuonPatternSegmentAssociationTool.h:27
Amg::Transform3D
Eigen::Affine3d Transform3D
Definition: GeoPrimitives.h:46
PlotPulseshapeFromCool.input
input
Definition: PlotPulseshapeFromCool.py:106
Trk::Segment::containedMeasurements
const std::vector< const Trk::MeasurementBase * > & containedMeasurements() const
returns the vector of Trk::MeasurementBase objects
Definition: TrkEvent/TrkSegment/TrkSegment/Segment.h:166
Trk::Segment
Definition: TrkEvent/TrkSegment/TrkSegment/Segment.h:56
MuonPatternCombination.h
CscClusterOnTrack.h
Trk::CompetingRIOsOnTrack
Base class for all CompetingRIOsOnTack implementations, extends the common MeasurementBase.
Definition: CompetingRIOsOnTrack.h:64
MuonGM::TgcReadoutElement
A TgcReadoutElement corresponds to a single TGC chamber; therefore typically a TGC station contains s...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/TgcReadoutElement.h:42
plotBeamSpotVxVal.range
range
Definition: plotBeamSpotVxVal.py:195
MuonCalib
CscCalcPed - algorithm that finds the Cathode Strip Chamber pedestals from an RDO.
Definition: CscCalcPed.cxx:22
Muon::MdtPrepData::globalPosition
virtual const Amg::Vector3D & globalPosition() const
Returns the global position of the CENTER of the drift tube (i.e.
Definition: MdtPrepData.h:149
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
Muon::MuonDriftCircleErrorStrategy::BackgroundCorrection
@ BackgroundCorrection
Background correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:32
MuonCalib::MuonSegmentToCalibSegment::getGlobalToStation
Amg::Transform3D getGlobalToStation(const Identifier &id, const MuonGM::MuonDetectorManager *MuonDetMgr) const
Definition: MuonSegmentToCalibSegment.cxx:271
Trk::ParametersBase
Definition: ParametersBase.h:55
SG::VarHandleKey::initialize
StatusCode initialize(bool used=true)
If this object is used as a property, then this should be called during the initialize phase.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:103
Muon::MdtDriftCircleOnTrack::driftRadius
double driftRadius() const
Returns the value of the drift radius.
Definition: MdtDriftCircleOnTrack.h:277
MdtCalibHit
Definition: MdtCalibHit.h:50
MuonCalib::MuonFixedId::stationNumberToFixedStationString
static std::string stationNumberToFixedStationString(const int station)
Definition: MuonFixedId.h:747
DataVector< Muon::MuonSegmentCombination >
Muon::MuonDriftCircleErrorStrategy::MagFieldCorrection
@ MagFieldCorrection
Magnetic field correction was applied in calibration.
Definition: MuonDriftCircleErrorStrategy.h:29
AthAlgorithm
Definition: AthAlgorithm.h:47
Trk::MeasurementBase::localCovariance
const Amg::MatrixX & localCovariance() const
Interface method to get the localError.
Definition: MeasurementBase.h:138
Muon::CscPrepData::detectorElement
virtual const MuonGM::CscReadoutElement * detectorElement() const override final
Return the detector element corresponding to this PRD.
Definition: CscPrepData.h:148
MuonCalib::RpcCalibHitBase::setStripLength
void setStripLength(double stripLength)
sets the strip length
Definition: RpcCalibHitBase.cxx:19
Trk::PrepRawData
Definition: PrepRawData.h:62
MdtCalibHit.h
MuonGM::nStrips
int nStrips(const MuonGM::TgcReadoutElement &readoutEle, int layer)
Definition: MuonDetDescr/MuonGeoModelTest/src/GeoModelTgcTest.cxx:46
Muon::RpcClusterOnTrack::prepRawData
virtual const RpcPrepData * prepRawData() const override final
Returns the RpcPrepData - is a TRT_DriftCircle in this scope.
Definition: RpcClusterOnTrack.h:127
MuonCalib::MuonSegmentToCalibSegment::savePatterns
StatusCode savePatterns(const EventContext &ctx, std::unique_ptr< MuonCalibPatternCollection > newPatterns) const
save global patterns to storegate
Definition: MuonSegmentToCalibSegment.cxx:69
dso-stats.pat
pat
Definition: dso-stats.py:39
Trk::PrepRawData::identify
Identifier identify() const
return the identifier
MuonCalib::RpcCalibHitBase::setIdentifier
void setIdentifier(const MuonFixedId &id)
sets the MuonFixedId of the hit
Definition: RpcCalibHitBase.cxx:16
MuonCalib::MuonSegmentToCalibSegment::m_maxStoredSegs
Gaudi::Property< int > m_maxStoredSegs
maximum number of segments each algorithm can store in ntuple
Definition: MuonSegmentToCalibSegment.h:101
MdtCalibHit::setDistanceToTrack
void setDistanceToTrack(double dist, double sigmaDist)
sets the distance to the fitted track and its error
Definition: MdtCalibHit.h:369
MuonCalib::MuonSegmentToCalibSegment::m_CscSegKey
SG::ReadHandleKey< MuonSegmentCombinationCollection > m_CscSegKey
Definition: MuonSegmentToCalibSegment.h:68
Muon::MdtPrepData::tdc
int tdc() const
Returns the TDC (typically range is 0 to 2500).
Definition: MdtPrepData.h:161
id
SG::auxid_t id
Definition: Control/AthContainers/Root/debug.cxx:194
MdtCalibHit::lorentzTime
double lorentzTime() const
retrieve the timing correction due to the magnetic field (lorentz angle)
Definition: MdtCalibHit.h:441
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:195
MuonCalib::MuonFixedId::stationName
int stationName() const
Definition: MuonFixedId.h:651
MuonCalib::MuonSegmentToCalibSegment::m_updateForT0Shift
Gaudi::Property< int > m_updateForT0Shift
-1: Take infirmation from error-strategy 0: fitted t0 is not applied to drift times 1: fitted t0 is a...
Definition: MuonSegmentToCalibSegment.h:97
Trk::PrepRawData::localPosition
const Amg::Vector2D & localPosition() const
return the local position reference
MuonCalib::MuonCalibPattern::addMuonSegment
void addMuonSegment(MuonCalibSegPtr seg)
Definition: MuonCalibPattern.cxx:33
Muon::MdtDriftCircleOnTrack
This class represents the corrected MDT measurements, where the corrections include the effects of wi...
Definition: MdtDriftCircleOnTrack.h:37
charge
double charge(const T &p)
Definition: AtlasPID.h:494
MuonCalib::MuonFixedId
Definition: MuonFixedId.h:50
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
Muon::MdtPrepData
Class to represent measurements from the Monitored Drift Tubes.
Definition: MdtPrepData.h:37
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
Trk::RIO_OnTrack::prepRawData
virtual const Trk::PrepRawData * prepRawData() const =0
returns the PrepRawData (also known as RIO) object to which this RIO_OnTrack is associated.
Muon::CscClusterOnTrack::prepRawData
virtual const CscPrepData * prepRawData() const override final
Returns the CscPrepData - is a CscPrepData in this scope.
Definition: CscClusterOnTrack.h:154
Trk::MeasurementBase::localParameters
const LocalParameters & localParameters() const
Interface method to get the LocalParameters.
Definition: MeasurementBase.h:132
MuonCalib::MuonFixedId::phi
int phi() const
Definition: MuonFixedId.h:704
DataVector::end
const_iterator end() const noexcept
Return a const_iterator pointing past the end of the collection.
MuonCalib::MuonSegmentToCalibSegment::m_DetectorManagerKey
SG::ReadCondHandleKey< MuonGM::MuonDetectorManager > m_DetectorManagerKey
MuonDetectorManager from the conditions store.
Definition: MuonSegmentToCalibSegment.h:80
MuonCalib::MuonCalibSegment::setFittedT0
void setFittedT0(double t0)
sets t0 field
Definition: MuonCalibSegment.cxx:124
MuonGM::RpcReadoutElement::StripWidth
double StripWidth(bool measphi) const
returns the strip width for the phi or eta plane
MuonCalib::MuonSegmentToCalibSegment::m_useCscSegments
Gaudi::Property< bool > m_useCscSegments
Definition: MuonSegmentToCalibSegment.h:64
SG::WriteHandle
Definition: StoreGate/StoreGate/WriteHandle.h:76
MuonCalib::MuonCalibSegment::addHitOnTrack
void addHitOnTrack(MdtCalibHitBase *hit)
add the MdtCalibHitBase to the set assigned to the segment
Definition: MuonCalibSegment.cxx:194
Muon::CscClusterOnTrack
Class to represent the calibrated clusters created from CSC strips.
Definition: CscClusterOnTrack.h:47
MuonCalib::CscCalibHitBase::setIdentifier
void setIdentifier(const MuonFixedId &id)
sets the MuonFixedId
Definition: CscCalibHitBase.cxx:27
CalibCoolCompareRT.nm
nm
Definition: CalibCoolCompareRT.py:110
CaloSwCorrections.time
def time(flags, cells_name, *args, **kw)
Definition: CaloSwCorrections.py:242
MuonCalib::MuonCalibPattern
Definition: MuonCalibPattern.h:42
MuonCalib::MuonSegmentToCalibSegment::initialize
StatusCode initialize()
Algorithm initialize.
Definition: MuonSegmentToCalibSegment.cxx:33
MuonCalib::MdtCalibHitBase
Definition: MdtCalibHitBase.h:38
MuonGM::MuonDetectorManager
The MuonDetectorManager stores the transient representation of the Muon Spectrometer geometry and pro...
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MuonDetectorManager.h:49
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
MuonCalib::MuonSegmentToCalibSegment::m_readSegments
Gaudi::Property< bool > m_readSegments
segment location
Definition: MuonSegmentToCalibSegment.h:63
Muon::MuonSegmentCombination::SegmentVec
std::vector< std::unique_ptr< MuonSegment > > SegmentVec
Definition: MuonSegmentCombination.h:32
DEBUG
#define DEBUG
Definition: page_access.h:11
MuonGM::MuonReadoutElement::identify
Identifier identify() const override final
Returns the ATLAS Identifier of the MuonReadOutElement.
Definition: MuonDetDescr/MuonReadoutGeometry/MuonReadoutGeometry/MuonReadoutElement.h:184
Muon::TgcPrepData
Class to represent TGC measurements.
Definition: TgcPrepData.h:32
MuonGM::MdtReadoutElement::surface
virtual const Trk::Surface & surface() const override final
Return surface associated with this detector element.
Definition: MuonDetDescr/MuonReadoutGeometry/src/MdtReadoutElement.cxx:875
Trk::RIO_OnTrack::identify
virtual Identifier identify() const final
return the identifier -extends MeasurementBase
Definition: RIO_OnTrack.h:155
extractSporadic.q
list q
Definition: extractSporadic.py:98
physics_parameters.parameters
parameters
Definition: physics_parameters.py:144
Trk::FitQuality::chiSquared
double chiSquared() const
returns the of the overall track fit
Definition: FitQuality.h:56
MuonSegment.h
Trk::Segment::author
Author author() const
return segment author
Definition: TrkEvent/TrkSegment/TrkSegment/Segment.h:199
MuonCalib::MuonFixedId::eta
int eta() const
Definition: MuonFixedId.h:681
Trk::phi
@ phi
Definition: ParamDefs.h:81
Muon::MuonSegment::globalPosition
virtual const Amg::Vector3D & globalPosition() const override final
global position
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:157
MuonCalib::MuonSegmentToCalibSegment::createMuonCalibPattern
MuonCalibPattern * createMuonCalibPattern(const Muon::MuonPatternCombination *pat) const
Definition: MuonSegmentToCalibSegment.cxx:789
MuonCalib::TgcCalibHitBase::setIdentifier
void setIdentifier(const MuonFixedId &id)
sets the identifier (MuonFixedId)
Definition: TgcCalibHitBase.cxx:24
MuonGM::RpcReadoutElement::distanceToEtaReadout
double distanceToEtaReadout(const Amg::Vector3D &P) const
Definition: MuonDetDescr/MuonReadoutGeometry/src/RpcReadoutElement.cxx:278
Trk::SpaceTimePointBase::time
float time() const
access to the measured time
Definition: SpaceTimePointBase.h:47
MuonCalib::MuonSegmentToCalibSegment::m_TrkSegKey
SG::ReadHandleKeyArray< Trk::SegmentCollection > m_TrkSegKey
Definition: MuonSegmentToCalibSegment.h:70
Muon::MuonSegment
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:45
drawFromPickle.sin
sin
Definition: drawFromPickle.py:36
beamspotnt.nt
def nt
Definition: bin/beamspotnt.py:1063
MdtCalibHit::driftTime
double driftTime() const
retrieve drift time
Definition: MdtCalibHit.h:423
Muon::MuonPatternCombination
The MuonPatternCombination class provides the means to store the output of the initial global pattern...
Definition: MuonPatternCombination.h:29
Trk::Segment::fitQuality
const FitQuality * fitQuality() const
return the FitQuality object, returns NULL if no FitQuality is defined
Definition: TrkEvent/TrkSegment/TrkSegment/Segment.h:160
FitQuality.h
MuonCalib::MuonSegmentToCalibSegment::m_CombSegKey
SG::ReadHandleKey< MuonSegmentCombinationCollection > m_CombSegKey
Definition: MuonSegmentToCalibSegment.h:66
MuonCalib::RpcCalibHitBase
Definition: RpcCalibHitBase.h:47
xAOD::bool
setBGCode setTAP setLVL2ErrorBits bool
Definition: TrigDecision_v1.cxx:60
error
Definition: IImpactPoint3dEstimator.h:70
Trk::Surface::transform
const Amg::Transform3D & transform() const
Returns HepGeom::Transform3D by reference.
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
Muon::MdtPrepData::detectorElement
virtual const MuonGM::MdtReadoutElement * detectorElement() const override
Returns the detector element corresponding to this PRD.
Definition: MdtPrepData.h:156
CscCalibHitBase.h
Muon::MuonDriftCircleErrorStrategy::creationParameter
bool creationParameter(CreationParameter) const
Definition: MuonDriftCircleErrorStrategy.h:84
MuonCalib::MuonSegmentToCalibSegment::convertPatterns
StatusCode convertPatterns(const EventContext &ctx)
Definition: MuonSegmentToCalibSegment.cxx:77
MdtCalibHitBase.h
MuonCalib::MuonCalibSegment::setAuthor
void setAuthor(int author)
sets author field
Definition: MuonCalibSegment.cxx:123
plotBeamSpotMon.nc
int nc
Definition: plotBeamSpotMon.py:83
MuonCalib::RpcCalibHitBase::setDistanceToRO
void setDistanceToRO(const double distance)
sets the distance of the hit to readout
Definition: RpcCalibHitBase.cxx:24
MuonCalib::MuonSegmentToCalibSegment::createMuonCalibSegment
MuonCalibSegment * createMuonCalibSegment(const Muon::MuonSegment &seg, const MuonGM::MuonDetectorManager *MuonDetMgr) const
Definition: MuonSegmentToCalibSegment.cxx:305
Trk::StraightLineSurface
Definition: StraightLineSurface.h:51
MuonCalib::MuonFixedId::mdtTubeLayer
int mdtTubeLayer() const
Mdt specific:
Definition: MuonFixedId.h:813
Muon::MuonSegment::associatedSurface
virtual const Trk::PlaneSurface & associatedSurface() const override final
returns the surface for the local to global transformation
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:175
DataVector::begin
const_iterator begin() const noexcept
Return a const_iterator pointing at the beginning of the collection.
Muon::MuonSegment::globalDirection
const Amg::Vector3D & globalDirection() const
global direction
Definition: MuonSpectrometer/MuonReconstruction/MuonRecEvent/MuonSegment/MuonSegment/MuonSegment.h:163
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
MuonGM::CscReadoutElement::cathodeReadoutPitch
double cathodeReadoutPitch(int chLayer, int measuresPhi) const
Definition: CscReadoutElement.cxx:147
MuonCalib::MuonSegmentToCalibSegment::m_assocTool
ToolHandle< Muon::IMuonPatternSegmentAssociationTool > m_assocTool
IdentifierTool initialization.
Definition: MuonSegmentToCalibSegment.h:89