Loading [MathJax]/extensions/tex2jax.js
ATLAS Offline Software
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
RpcFastDigiTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2025 CERN for the benefit of the ATLAS collaboration
3 */
4 #include "RpcFastDigiTool.h"
7 #include "CLHEP/Random/RandGaussZiggurat.h"
8 #include "CLHEP/Random/RandFlat.h"
9 namespace {
10  constexpr double percentage(unsigned int numerator, unsigned int denom) {
11  return 100. * numerator / std::max(denom, 1u);
12  }
14  const Eigen::Rotation2D etaToPhi{-90.*Gaudi::Units::deg};
15 }
16 namespace MuonR4 {
17 
18  RpcFastDigiTool::RpcFastDigiTool(const std::string& type, const std::string& name, const IInterface* pIID):
20 
25  m_stIdxBIL = m_idHelperSvc->rpcIdHelper().stationNameIndex("BIL");
26  m_stIdxBIS = m_idHelperSvc->rpcIdHelper().stationNameIndex("BIS");
27  return StatusCode::SUCCESS;
28  }
30  ATH_MSG_INFO("Tried to convert "<<m_allHits[0]<<"/"<<m_allHits[1]<<" hits. In, "
31  <<percentage(m_acceptedHits[0], m_allHits[0]) <<"/"
32  <<percentage(m_acceptedHits[1], m_allHits[1]) <<"% of the cases, the conversion was successful");
33  return StatusCode::SUCCESS;
34  }
35  StatusCode RpcFastDigiTool::digitize(const EventContext& ctx,
36  const TimedHits& hitsToDigit,
37  xAOD::MuonSimHitContainer* sdoContainer) const {
38  const RpcIdHelper& idHelper{m_idHelperSvc->rpcIdHelper()};
39  // Prepare the temporary cache
40  DigiCache digitCache{};
42  const Muon::DigitEffiData* efficiencyMap{nullptr};
43  ATH_CHECK(retrieveConditions(ctx, m_effiDataKey, efficiencyMap));
44 
45  CLHEP::HepRandomEngine* rndEngine = getRandomEngine(ctx);
46  xAOD::ChamberViewer viewer{hitsToDigit, m_idHelperSvc.get()};
47  do {
48  DeadTimeMap deadTimes{};
49  for (const TimedHit& simHit : viewer) {
50  if (m_digitizeMuonOnly && !MC::isMuon(simHit)){
51  continue;
52  }
53  const Identifier hitId{simHit->identify()};
54 
55  const MuonGMR4::RpcReadoutElement* readOutEle = m_detMgr->getRpcReadoutElement(hitId);
56  const Amg::Vector3D locPos{xAOD::toEigen(simHit->localPosition())};
57  RpcDigitCollection* digiColl = fetchCollection(hitId, digitCache);
58  bool run4_BIS = ((m_idHelperSvc->stationName(hitId) == m_stIdxBIS) && (abs(m_idHelperSvc->stationEta(hitId)) < 7));
59  if ((m_idHelperSvc->stationName(hitId) != m_stIdxBIL) && !(run4_BIS)) {
61  const bool digitizedEta = digitizeHit(hitId, false, *readOutEle,
62  hitTime(simHit), locPos.block<2,1>(0,0),
63  efficiencyMap, *digiColl, rndEngine, deadTimes);
64 
65  const bool digitizedPhi = digitizeHit(hitId, true, *readOutEle, hitTime(simHit),
66  etaToPhi*locPos.block<2,1>(0,0),
67  efficiencyMap, *digiColl, rndEngine, deadTimes);
68  if (digitizedEta) {
69  xAOD::MuonSimHit* sdo = addSDO(simHit, sdoContainer);
70  const Identifier digitId{(*digiColl)[digiColl->size() -1 - digitizedPhi]->identify()};
71  sdo->setIdentifier(digitId);
72  } else if (digitizedPhi) {
73  xAOD::MuonSimHit* sdo = addSDO(simHit, sdoContainer);
75  Amg::Vector3D phiPos{locPos};
76  phiPos.block<2,1>(0,0) = etaToPhi * phiPos.block<2,1>(0,0);
77  Amg::Vector3D locDir{xAOD::toEigen(simHit->localDirection())};
78  locDir.block<2,1>(0,0) = etaToPhi * locDir.block<2,1>(0,0);
79  const Identifier digitId{(*digiColl)[digiColl->size() -1]->identify()};
80  sdo->setIdentifier(digitId);
82  sdo->setLocalPosition(xAOD::toStorage(phiPos));
83  }
84  } else if (digitizeHitBI(hitId, *readOutEle, hitTime(simHit), locPos.block<2,1>(0,0),
85  efficiencyMap, *digiColl, rndEngine, deadTimes)) {
86  xAOD::MuonSimHit* sdo = addSDO(simHit, sdoContainer);
87  const Identifier digitId{(*digiColl)[digiColl->size() -1]->identify()};
88  sdo->setIdentifier(digitId);
89  }
90  }
91  } while (viewer.next());
93  ATH_CHECK(writeDigitContainer(ctx, m_writeKey, std::move(digitCache), idHelper.module_hash_max()));
94  return StatusCode::SUCCESS;
95  }
97  const bool measuresPhi,
98  const MuonGMR4::RpcReadoutElement& reEle,
99  const double hitTime,
100  const Amg::Vector2D& locPos,
101  const Muon::DigitEffiData* effiMap,
102  RpcDigitCollection& outContainer,
103  CLHEP::HepRandomEngine* rndEngine,
104  DeadTimeMap& deadTimes) const {
105 
106  ++(m_allHits[measuresPhi]);
107  const MuonGMR4::StripDesign& design{measuresPhi ? *reEle.getParameters().phiDesign
108  : *reEle.getParameters().etaDesign};
109 
110  const double uncert = design.stripPitch() / std::sqrt(12.);
111  const double smearedX = CLHEP::RandGaussZiggurat::shoot(rndEngine, locPos.x(), uncert);
112  const Amg::Vector2D locHitPos{smearedX, locPos.y()};
113 
114  if (!design.insideTrapezoid(locHitPos)) {
115  ATH_MSG_VERBOSE("The hit "<<Amg::toString(locHitPos)<<" is outside of the trapezoid bounds for "
116  <<m_idHelperSvc->toStringGasGap(gasGapId)<<", measuresPhi: "<<(measuresPhi ? "yay" : "nay"));
117  return false;
118  }
119  const int strip = design.stripNumber(locHitPos);
120  if (strip < 0) {
121  ATH_MSG_VERBOSE("Hit " << Amg::toString(locHitPos) << " cannot trigger any signal in a strip for "
122  << m_idHelperSvc->toStringGasGap(gasGapId) <<std::endl<<design<<
123  std::endl<<", measuresPhi: "<<(measuresPhi ? "yay" : "nay"));
124  return false;
125  }
126 
127  const RpcIdHelper& id_helper{m_idHelperSvc->rpcIdHelper()};
128 
129  bool isValid{false};
130  const Identifier digitId{id_helper.channelID(gasGapId,
131  id_helper.doubletZ(gasGapId),
132  id_helper.doubletPhi(gasGapId),
133  id_helper.gasGap(gasGapId),
134  measuresPhi, strip, isValid)};
135 
136  if (!isValid) {
137  ATH_MSG_WARNING("Invalid hit identifier obtained for "<<m_idHelperSvc->toStringGasGap(gasGapId)
138  <<", eta strip "<<strip<<" & hit "<<Amg::toString(locHitPos,2 )
139  <<" /// "<<design);
140  return false;
141  }
143  if (effiMap && effiMap->getEfficiency(digitId) < CLHEP::RandFlat::shoot(rndEngine,0.,1.)) {
144  ATH_MSG_VERBOSE("Hit is marked as inefficient");
145  return false;
146  }
147 
148  if (!passDeadTime(digitId, hitTime, m_deadTime, deadTimes)) {
149  ATH_MSG_VERBOSE("Reject hit due to dead map constraint");
150  return false;
151  }
153  const double signalTime = hitTime + reEle.distanceToEdge(reEle.measurementHash(digitId),
155  const double digitTime = CLHEP::RandGaussZiggurat::shoot(rndEngine, signalTime, m_stripTimeResolution);
156  outContainer.push_back(std::make_unique<RpcDigit>(digitId, digitTime, timeOverThreshold(rndEngine)));
157  ++(m_acceptedHits[measuresPhi]);
158  return true;
159  }
161  const MuonGMR4::RpcReadoutElement& reEle,
162  const double hitTime,
163  const Amg::Vector2D& locPos,
164  const Muon::DigitEffiData* effiMap,
165  RpcDigitCollection& outContainer,
166  CLHEP::HepRandomEngine* rndEngine,
167  DeadTimeMap& deadTimes) const {
168 
169  ++(m_allHits[false]);
170  const MuonGMR4::StripDesign& design{*reEle.getParameters().etaDesign};
171  const RpcIdHelper& id_helper{m_idHelperSvc->rpcIdHelper()};
172 
173 
175  const double uncert = design.stripPitch() / std::sqrt(12.);
176  const double smearedX = CLHEP::RandGaussZiggurat::shoot(rndEngine, locPos.x(), uncert);
177 
179  // True propagation time in nanoseconds along strip to y=-stripLength/2 (L) and y=stripLength/2 (R)
180  const IdentifierHash layHash = reEle.layerHash(gasGapId);
181  const double propagationTimeL = reEle.distanceToEdge(layHash, locPos, EdgeSide::readOut) / m_propagationVelocity;
182  const double propagationTimeR = reEle.distanceToEdge(layHash, locPos, EdgeSide::highVoltage)/ m_propagationVelocity;
183 
185  const double smearedTimeL = CLHEP::RandGaussZiggurat::shoot(rndEngine, propagationTimeL, m_stripTimeResolution);
186  const double smearedTimeR = CLHEP::RandGaussZiggurat::shoot(rndEngine, propagationTimeR, m_stripTimeResolution);
187 
188  const double smearedDeltaT = smearedTimeR - smearedTimeL;
189 
190  /*
191  |--- d1, t1 ---||--- d1, t1 ---||-- d --| For t2 > t1:
192  ||||||||||||||||X|||||||||||||||||||||||| <- RPC strip, deltaT = t2 - t1, d1 = v_prop * t1 (likewise for d2),
193  |-------- d2, t2 -------| X is a hit l = d1 + d2, d = d2 - d1 -> d = l - 2d1 = v_prop * deltaT
194  |----------------- l -------------------|
195  Hence, d1 = 0.5 * (l - d) = 0.5 * (l - v_prop * deltaT)
196 
197  Then converting to coordinate system where 0 -> -0.5*l to match strip local coordinates
198  d1 -> d1 = -0.5*l + 0.5* (l-d) = -0.5*d = -0.5 * v_pro*deltaT
199  */
200  const double smearedY = -0.5 * m_propagationVelocity * smearedDeltaT; //in mm
201  //If smearedDeltaT == 0 position is in the centre of the strip (0).
202 
203  const Amg::Vector2D locHitPos{smearedX, smearedY};
204 
205  if (!design.insideTrapezoid(locHitPos)) {
206  ATH_MSG_VERBOSE("The hit "<<Amg::toString(locHitPos)<<" is outside of the trapezoid bounds for "
207  <<m_idHelperSvc->toStringGasGap(gasGapId));
208  return false;
209  }
210 
211  const int strip = design.stripNumber(locHitPos);
212  if (strip < 0) {
213  ATH_MSG_VERBOSE("Hit " << Amg::toString(locHitPos) << " cannot trigger any signal in a strip for "
214  << m_idHelperSvc->toStringGasGap(gasGapId) <<std::endl<<design);
215  return false;
216  }
217 
218 
219  bool isValid{false};
220  const Identifier digitId{id_helper.channelID(gasGapId,
221  id_helper.doubletZ(gasGapId),
222  id_helper.doubletPhi(gasGapId),
223  id_helper.gasGap(gasGapId),
224  false, strip, isValid)};
225  if (!isValid) {
226  ATH_MSG_WARNING("Failed to create a valid strip "<<m_idHelperSvc->toStringGasGap(gasGapId)
227  <<", strip: "<<strip);
228  return false;
229  }
230  if (!passDeadTime(digitId, hitTime, m_deadTime, deadTimes)) {
231  ATH_MSG_VERBOSE("Reject hit due to dead map constraint");
232  return false;
233  }
234  ATH_MSG_VERBOSE("Digitize hit "<<m_idHelperSvc->toString(digitId)<<" located at: "<<Amg::toString(locHitPos));
236  const bool effiSignal1 = !effiMap || effiMap->getEfficiency(gasGapId) >= CLHEP::RandFlat::shoot(rndEngine,0., 1.);
237  const bool effiSignal2 = !effiMap || effiMap->getEfficiency(gasGapId) >= CLHEP::RandFlat::shoot(rndEngine,0., 1.);
238  if (effiSignal1) {
239  outContainer.push_back(std::make_unique<RpcDigit>(digitId, hitTime + smearedTimeR, timeOverThreshold(rndEngine)));
240  }
241  if (effiSignal2) {
242  outContainer.push_back(std::make_unique<RpcDigit>(digitId, hitTime + smearedTimeL, timeOverThreshold(rndEngine), true));
243  }
244  if (effiSignal1 || effiSignal2) {
245  ++(m_acceptedHits[false]);
246  return true;
247  }
248  return false;
249  }
250  double RpcFastDigiTool::timeOverThreshold(CLHEP::HepRandomEngine* rndmEngine) {
251  //mn Time-over-threshold modeled as a narrow and a wide gaussian
252  //mn based on the fit documented in https://its.cern.ch/jira/browse/ATLASRECTS-7820
253  constexpr double tot_mean_narrow = 16.;
254  constexpr double tot_sigma_narrow = 2.;
255  constexpr double tot_mean_wide = 15.;
256  constexpr double tot_sigma_wide = 4.5;
257 
258  double thetot = 0.;
259 
260  if (CLHEP::RandFlat::shoot(rndmEngine)<0.75) {
261  thetot = CLHEP::RandGaussZiggurat::shoot(rndmEngine, tot_mean_narrow, tot_sigma_narrow);
262  } else {
263  thetot = CLHEP::RandGaussZiggurat::shoot(rndmEngine, tot_mean_wide, tot_sigma_wide);
264  }
265 
266  return std::max(thetot, 0.);
267  }
268 
269 }
MuonR4::MuonDigitizationTool::passDeadTime
static bool passDeadTime(const Identifier &channelId, const double hitTime, const double deadTimeWindow, DeadTimeMap &deadTimeMap)
Returns whether the new digit is within the dead time window.
Definition: MuonDigitizationTool.cxx:169
xAOD::MuonSimHit_v1
Definition: MuonSimHit_v1.h:18
MuonGMR4::StripDesign
Definition: StripDesign.h:30
MuonR4::RpcFastDigiTool::m_effiDataKey
SG::ReadCondHandleKey< Muon::DigitEffiData > m_effiDataKey
Definition: RpcFastDigiTool.h:77
xAOD::MuonSimHit_v1::setIdentifier
void setIdentifier(const Identifier &id)
Sets the global ATLAS identifier.
Definition: xAODMuonSimHit_V1.cxx:43
MuonR4::RpcFastDigiTool::m_stripTimeResolution
Gaudi::Property< double > m_stripTimeResolution
Definition: RpcFastDigiTool.h:86
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
Amg::Vector2D
Eigen::Matrix< double, 2, 1 > Vector2D
Definition: GeoPrimitives.h:48
max
constexpr double max()
Definition: ap_fixedTest.cxx:33
RpcDigitCollection
Definition: RpcDigitCollection.h:17
MuonR4::RpcFastDigiTool::m_stIdxBIL
int m_stIdxBIL
Definition: RpcFastDigiTool.h:30
deg
#define deg
Definition: SbPolyhedron.cxx:17
xAOD::toStorage
MeasVector< N > toStorage(const AmgVector(N)&amgVec)
Converts the double precision of the AmgVector into the floating point storage precision of the MeasV...
Definition: MeasurementDefs.h:69
MuonGMR4::RpcReadoutElement::parameterBook::etaDesign
StripDesignPtr etaDesign
Definition: MuonPhaseII/MuonDetDescr/MuonReadoutGeometryR4/MuonReadoutGeometryR4/RpcReadoutElement.h:39
xAOD::MuonSimHit_v1::setLocalPosition
void setLocalPosition(MeasVector< 3 > vec)
Sets the local position of the traversing particle.
Definition: xAODMuonSimHit_V1.cxx:56
MuonR4::RpcFastDigiTool::initialize
StatusCode initialize() override final
Definition: RpcFastDigiTool.cxx:21
TimedHitPtr< xAOD::MuonSimHit >
ATH_MSG_VERBOSE
#define ATH_MSG_VERBOSE(x)
Definition: AthMsgStreamMacros.h:28
isValid
bool isValid(const T &p)
Av: we implement here an ATLAS-sepcific convention: all particles which are 99xxxxx are fine.
Definition: AtlasPID.h:778
SG::VarHandleKey::empty
bool empty() const
Test if the key is blank.
Definition: AthToolSupport/AsgDataHandles/Root/VarHandleKey.cxx:150
MuonR4::RpcFastDigiTool::DigiCache
OutDigitCache_t< RpcDigitCollection > DigiCache
Definition: RpcFastDigiTool.h:74
MuonGMR4::RpcReadoutElement
Definition: MuonPhaseII/MuonDetDescr/MuonReadoutGeometryR4/MuonReadoutGeometryR4/RpcReadoutElement.h:17
RpcIdHelper
Definition: RpcIdHelper.h:51
MuonR4::MuonDigitizationTool::retrieveConditions
StatusCode retrieveConditions(const EventContext &ctx, const SG::ReadCondHandleKey< Container > &key, const Container *&contPtr) const
Helper function to access the conditions data.
Trk::u
@ u
Enums for curvilinear frames.
Definition: ParamDefs.h:77
python.CaloAddPedShiftConfig.type
type
Definition: CaloAddPedShiftConfig.py:42
MuonGMR4::RpcReadoutElement::getParameters
const parameterBook & getParameters() const
Definition: MuonPhaseII/MuonDetDescr/MuonReadoutGeometryR4/src/RpcReadoutElement.cxx:34
RpcFastDigiTool.h
MuonR4::RpcFastDigiTool::RpcFastDigiTool
RpcFastDigiTool(const std::string &type, const std::string &name, const IInterface *pIID)
Definition: RpcFastDigiTool.cxx:18
MuonR4::RpcFastDigiTool::m_deadTime
Gaudi::Property< double > m_deadTime
Definition: RpcFastDigiTool.h:89
xAOD::ChamberViewer
Definition: ChamberViewer.h:65
MuonR4::RpcFastDigiTool::m_digitizeMuonOnly
Gaudi::Property< bool > m_digitizeMuonOnly
Definition: RpcFastDigiTool.h:91
Amg::toString
std::string toString(const Translation3D &translation, int precision=4)
GeoPrimitvesToStringConverter.
Definition: GeoPrimitivesToStringConverter.h:40
MuonGMR4::RpcReadoutElement::parameterBook::phiDesign
StripDesignPtr phiDesign
Definition: MuonPhaseII/MuonDetDescr/MuonReadoutGeometryR4/MuonReadoutGeometryR4/RpcReadoutElement.h:38
MuonR4::RpcFastDigiTool::digitizeHitBI
bool digitizeHitBI(const Identifier &gasGapId, const MuonGMR4::RpcReadoutElement &reEle, const double hitTime, const Amg::Vector2D &locPos, const Muon::DigitEffiData *effiMap, RpcDigitCollection &outContainer, CLHEP::HepRandomEngine *rndEngine, DeadTimeMap &deadTimes) const
Digitize the sim hit as Rpc strip 2D hit.
Definition: RpcFastDigiTool.cxx:160
MuonR4::MuonDigitizationTool::getRandomEngine
CLHEP::HepRandomEngine * getRandomEngine(const EventContext &ctx) const
Definition: MuonDigitizationTool.cxx:135
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
MuonR4::RpcFastDigiTool::m_writeKey
SG::WriteHandleKey< RpcDigitContainer > m_writeKey
Definition: RpcFastDigiTool.h:75
MuonR4::RpcFastDigiTool::m_stIdxBIS
int m_stIdxBIS
Definition: RpcFastDigiTool.h:31
Muon::DigitEffiData::getEfficiency
double getEfficiency(const Identifier &channelId, bool isInnerQ1=false) const
Returns the signal generation efficiency of the sTgc channel.
Definition: DigitEffiData.cxx:38
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
MuonGMR4::RpcReadoutElement::measurementHash
IdentifierHash measurementHash(const Identifier &measId) const override final
Constructs the identifier hash from the full measurement Identifier.
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
MuonR4::RpcFastDigiTool::digitize
StatusCode digitize(const EventContext &ctx, const TimedHits &hitsToDigit, xAOD::MuonSimHitContainer *sdoContainer) const override final
Digitize the time ordered hits and write them to the digit format specific for the detector technolog...
Definition: RpcFastDigiTool.cxx:35
DataVector
Derived DataVector<T>.
Definition: DataVector.h:794
compute_lumi.denom
denom
Definition: compute_lumi.py:76
MuonR4::RpcFastDigiTool::m_propagationVelocity
Gaudi::Property< double > m_propagationVelocity
Definition: RpcFastDigiTool.h:83
Muon::DigitEffiData
Definition: DigitEffiData.h:23
MuonR4::MuonDigitizationTool::addSDO
xAOD::MuonSimHit * addSDO(const TimedHit &hit, xAOD::MuonSimHitContainer *sdoContainer) const
Adds the timed simHit to the output SDO container.
Definition: MuonDigitizationTool.cxx:148
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
MuonR4::MuonDigitizationTool::writeDigitContainer
StatusCode writeDigitContainer(const EventContext &ctx, const SG::WriteHandleKey< DigitCont > &key, OutDigitCache_t< DigitColl > &&digitCache, unsigned int hashMax) const
Helper function to move the collected digits into the final DigitContainer.
xAOD::MuonSimHit_v1::setLocalDirection
void setLocalDirection(MeasVector< 3 > vec)
Sets the local direction of the traversing particle.
Definition: xAODMuonSimHit_V1.cxx:62
DataVector::push_back
value_type push_back(value_type pElem)
Add an element to the end of the collection.
SG::CondHandleKey::initialize
StatusCode initialize(bool used=true)
MuonGMR4::RpcReadoutElement::layerHash
IdentifierHash layerHash(const Identifier &measId) const override final
ChamberViewer.h
Amg::Vector3D
Eigen::Matrix< double, 3, 1 > Vector3D
Definition: GeoPrimitives.h:47
python.copyTCTOutput.locDir
locDir
Definition: copyTCTOutput.py:113
MuonGMR4::RpcReadoutElement::distanceToEdge
double distanceToEdge(const IdentifierHash &layerHash, const Amg::Vector2D &posInStripPlane, const EdgeSide side) const
Returns the disance to the readout.
Definition: MuonPhaseII/MuonDetDescr/MuonReadoutGeometryR4/src/RpcReadoutElement.cxx:115
MuonR4::MuonDigitizationTool::hitTime
static double hitTime(const TimedHit &hit)
Returns the global time of the hit which is the sum of eventTime & individual hit time.
Definition: MuonDigitizationTool.cxx:69
MuonR4
This header ties the generic definitions in this package.
Definition: HoughEventData.h:16
MuonR4::MuonDigitizationTool::initialize
StatusCode initialize() override
Definition: MuonDigitizationTool.cxx:17
MuonR4::MuonDigitizationTool
Barebone implementation of the I/O infrastructure for all MuonDigitizationTools.
Definition: MuonDigitizationTool.h:41
MuonR4::MuonDigitizationTool::TimedHits
std::vector< TimedHitPtr< xAOD::MuonSimHit > > TimedHits
Definition: MuonDigitizationTool.h:71
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
MuonR4::RpcFastDigiTool::finalize
StatusCode finalize() override final
Definition: RpcFastDigiTool.cxx:29
MuonR4::MuonDigitizationTool::m_idHelperSvc
ServiceHandle< Muon::IMuonIdHelperSvc > m_idHelperSvc
Definition: MuonDigitizationTool.h:142
MuonR4::MuonDigitizationTool::m_detMgr
const MuonGMR4::MuonDetectorManager * m_detMgr
Definition: MuonDigitizationTool.h:140
MuonGMR4::RpcReadoutElement::EdgeSide::highVoltage
@ highVoltage
MuonR4::MuonDigitizationTool::DeadTimeMap
std::unordered_map< Identifier, double > DeadTimeMap
Definition: MuonDigitizationTool.h:129
MuonR4::RpcFastDigiTool::digitizeHit
bool digitizeHit(const Identifier &gasGapId, const bool measuresPhi, const MuonGMR4::RpcReadoutElement &reEle, const double hitTime, const Amg::Vector2D &locPos, const Muon::DigitEffiData *effiMap, RpcDigitCollection &outContainer, CLHEP::HepRandomEngine *rndEngine, DeadTimeMap &deadTimes) const
Digitize the sim hit as Rpc strip 1D hit.
Definition: RpcFastDigiTool.cxx:96
MuonGMR4::RpcReadoutElement::EdgeSide::readOut
@ readOut
hitTime
float hitTime(const AFP_SIDSimHit &hit)
Definition: AFP_SIDSimHit.h:39
IdentifierHash
This is a "hash" representation of an Identifier. This encodes a 32 bit index which can be used to lo...
Definition: IdentifierHash.h:25
MuonR4::MuonDigitizationTool::fetchCollection
DigitColl * fetchCollection(const Identifier &hitId, OutDigitCache_t< DigitColl > &digitCache) const
Helper function that provides fetches the proper DigitCollection from the DigitCache for a given hit ...
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
MuonR4::RpcFastDigiTool::timeOverThreshold
static double timeOverThreshold(CLHEP::HepRandomEngine *rndmEngine)
Roll the time over threshold for each signal digit.
Definition: RpcFastDigiTool.cxx:250
HepMCHelpers.h
isMuon
bool isMuon(const T &p)
Definition: AtlasPID.h:176
Identifier
Definition: IdentifierFieldParser.cxx:14