ATLAS Offline Software
SensorSimPlanarTool.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #include "SensorSimPlanarTool.h"
9 #include "InDetSimEvent/SiHit.h"
12 
15 
16 #include "CLHEP/Random/RandFlat.h"
17 #include "CLHEP/Random/RandGaussZiggurat.h"
18 
19 #include "CLHEP/Units/PhysicalConstants.h"
21 
22 #include "GaudiKernel/SystemOfUnits.h"
23 
24 #include "TFile.h"
25 
26 #include <cmath>
27 #include <memory>
28 
29 using namespace InDetDD;
30 
31 //===============================================
32 // C O N S T R U C T O R
33 //===============================================
34 SensorSimPlanarTool::SensorSimPlanarTool(const std::string& type, const std::string& name, const IInterface* parent) :
36 
37  // This is a waste in some cases, but we need at most 3x3 elements
38  // Reserving 9 removes the need to allocate new memory multipe time thus speeding up the code a bit
39  m_centrePixelNNEtaPhi.resize(9);
40 }
41 
43 
44 //===============================================
45 // I N I T I A L I Z E
46 //===============================================
48  ATH_MSG_DEBUG("SensorSimPlanarTool::initialize()");
50 
51  ATH_CHECK(m_radDamageUtil.retrieve());
52  ATH_MSG_DEBUG("RadDamageUtil tool retrieved successfully");
53 
54  ATH_CHECK(m_lorentzAngleTool.retrieve());
55 
57  //If any fluence or voltage initialized negative use benchmark maps and not interpolation
58  std::vector<std::string> mapsPath_list;
59  std::vector<std::string> TCADpath_list;
60 
61  // Use all TCAD E field files in this directory for creating E field via interpolation (pruned filed excluded)
62  std::string iblFiles = PathResolverFindCalibDirectory("PixelDigitization/TCAD_IBL_efields/fei4-200um/");
63  std::string sensorFiles = PathResolverFindCalibDirectory("PixelDigitization/TCAD_Blayer_efields/fei4-250um/");
64 
65  // For each layer one configuration
66  TCADpath_list = {
67  iblFiles, sensorFiles, sensorFiles, sensorFiles
68  };
69 
70  if (m_fluenceMap.size() == 0 || m_fluenceLayer.size() == 0 || m_voltageLayer.size() == 0 ||
71  m_fluenceMap.size() != m_fluenceLayer.size() || m_fluenceMap.size() != m_voltageLayer.size()) {
72  ATH_MSG_INFO("Use interpolation, but the input map/fluence/valtage are not set.");
73  return StatusCode::FAILURE;
74  }
75  ATH_MSG_INFO("No benchmark value set for fluence. Use interpolation.");
76 
77  mapsPath_list.clear();
78  for (size_t i = 0; i < m_fluenceMap.size(); i++) {
79  mapsPath_list.push_back(PathResolverFindCalibFile(m_fluenceMap[i]));
80  }
81 
82  // *****************************
83  // *** Setup Maps ****
84  // *****************************
85  //TODO This is only temporary until remotely stored maps and locally generated maps can be implemented
86  //E field already implemented: needs fluence and bias voltage given as Property m_fluence, m_fluenceB, ...,
87  // m_fluence1, ...
88  for (unsigned int i = 0; i < mapsPath_list.size(); i++) {
89  ATH_MSG_INFO("Using maps located in: " << mapsPath_list.at(i) << " for layer No." << i);
90  ATH_MSG_INFO("Create E field via interpolation based on files from: " << TCADpath_list.at(i));
91  std::unique_ptr<TFile> mapsFile(TFile::Open((mapsPath_list.at(i)).c_str(), "READ")); //this is the ramo potential.
92  if (!mapsFile) {
93  ATH_MSG_ERROR("Cannot open file: " << mapsPath_list.at(i));
94  return StatusCode::FAILURE;
95  }
96 
97  //Setup ramo weighting field map
98  std::unique_ptr<TH3F> ramoPotentialMap_hold(mapsFile->Get<TH3F>("hramomap1"));
99  if (!ramoPotentialMap_hold) {
100  ramoPotentialMap_hold.reset(mapsFile->Get<TH3F>("ramo3d"));
101  ATH_MSG_INFO("Did not find a Ramo potential map. Will use an approximate form.");
102  }
103  if (!ramoPotentialMap_hold) {
104  ATH_MSG_WARNING("Not implemented yet - exit");
105  return StatusCode::FAILURE; //Obviously, remove this when gen. code is set up
106  }
107  ramoPotentialMap_hold->SetDirectory(nullptr);
108  m_ramoPotentialMap.emplace_back();
109  ATH_CHECK(m_ramoPotentialMap.back().setHisto3D(ramoPotentialMap_hold.get()));
110  //Now setup the E-field.
111  TH1F* eFieldMap_hold(nullptr);
112  CHECK(m_radDamageUtil->generateEfieldMap(eFieldMap_hold, nullptr, m_fluenceLayer[i], m_voltageLayer[i], i,
113  TCADpath_list.at(i), true));
114 
115  eFieldMap_hold->SetDirectory(nullptr);
116 
117  TH2F* lorentzMap_e_hold(nullptr);
118  TH2F* lorentzMap_h_hold(nullptr);
119  TH2F* distanceMap_h_hold(nullptr);
120  TH2F* distanceMap_e_hold(nullptr);
121  TH1F* timeMap_e_hold(nullptr);
122  TH1F* timeMap_h_hold(nullptr);
123 
124  ATH_CHECK(m_radDamageUtil->generateDistanceTimeMap(distanceMap_e_hold, distanceMap_h_hold, timeMap_e_hold,
125  timeMap_h_hold, lorentzMap_e_hold, lorentzMap_h_hold,
126  eFieldMap_hold, nullptr));
127 
128  // For debugging and documentation: uncomment to save different maps which are based on the interpolated E field
129  if (m_radDamageUtil->saveDebugMaps()) {
130  TString prename = "map_layer_";
131  prename += i;
132  prename += "distance_e.root";
133  distanceMap_e_hold->SaveAs(prename, "");
134  prename.ReplaceAll("_e", "_h");
135  distanceMap_h_hold->SaveAs(prename, "");
136  prename.ReplaceAll("distance", "time");
137  timeMap_h_hold->SaveAs(prename, "");
138  prename.ReplaceAll("_h", "_e");
139  timeMap_e_hold->SaveAs(prename, "");
140  prename.ReplaceAll("time", "lorentz");
141  lorentzMap_e_hold->SaveAs(prename, "");
142  prename.ReplaceAll("_e", "_h");
143  lorentzMap_h_hold->SaveAs(prename, "");
144  }
145  //Safetycheck
146  if (!distanceMap_e_hold || !distanceMap_h_hold || !timeMap_e_hold || !timeMap_h_hold ||
147  !lorentzMap_e_hold || !lorentzMap_h_hold) {
148  ATH_MSG_ERROR("Unable to load at least one of the distance/time/Lorentz angle maps.");
149  return StatusCode::FAILURE;//Obviously, remove this when gen. code is set up
150  }
151 
152  lorentzMap_e_hold->SetDirectory(nullptr);
153  lorentzMap_h_hold->SetDirectory(nullptr);
154  distanceMap_e_hold->SetDirectory(nullptr);
155  distanceMap_h_hold->SetDirectory(nullptr);
156  timeMap_e_hold->SetDirectory(nullptr);
157  timeMap_h_hold->SetDirectory(nullptr);
158 
159  m_distanceMap_e.emplace_back();
160  m_distanceMap_h.emplace_back();
161  ATH_CHECK(m_distanceMap_e.back().setHisto2D(distanceMap_e_hold));
162  ATH_CHECK(m_distanceMap_h.back().setHisto2D(distanceMap_h_hold));
163  m_lorentzMap_e.emplace_back();
164  m_lorentzMap_h.emplace_back();
165  ATH_CHECK(m_lorentzMap_e.back().setHisto2D(lorentzMap_e_hold));
166  ATH_CHECK(m_lorentzMap_h.back().setHisto2D(lorentzMap_h_hold));
167 
168  delete eFieldMap_hold;
169  delete lorentzMap_e_hold;
170  delete lorentzMap_h_hold;
171  delete distanceMap_e_hold;
172  delete distanceMap_h_hold;
173  delete timeMap_e_hold;
174  delete timeMap_h_hold;
175 
176  mapsFile->Close();
177  }
178  }
179 
180  // read the correction histograms
181  if (m_radiationDamageSimulationType == RadiationDamageSimulationType::TEMPLATE_CORRECTION) {
182 
183  constexpr std::size_t numberOfLayers = 4;
184 
185  ATH_MSG_INFO("Opening file: " << m_templateCorrectionRootFile << " for radiation damage correction");
186  std::unique_ptr<TFile> file(TFile::Open(PathResolverFindCalibFile(m_templateCorrectionRootFile).c_str(), "READ"));
187  if (!file) {
188  ATH_MSG_ERROR("Unable to read the ROOT file needed for radiation damage correction at: " << m_templateCorrectionRootFile);
189  return StatusCode::FAILURE;
190  }
191 
192  if (m_lorentzAngleCorrectionHistos.size() != numberOfLayers) {
193  ATH_MSG_ERROR("The size of the vector of Lorentz angle histogram paths is " << m_lorentzAngleCorrectionHistos.size() << " instead of " << numberOfLayers);
194  return StatusCode::FAILURE;
195  }
196 
197  if (m_chargeCorrectionHistos.size() != numberOfLayers) {
198  ATH_MSG_ERROR("The size of the vector of charge correction histogram paths is " << m_chargeCorrectionHistos.size() << " instead of " << numberOfLayers);
199  return StatusCode::FAILURE;
200  }
201 
202  if (m_distanceCorrectionHistos.size() != numberOfLayers) {
203  ATH_MSG_ERROR("The size of the vector of distance correction histogram paths is " << m_distanceCorrectionHistos.size() << " instead of " << numberOfLayers);
204  return StatusCode::FAILURE;
205  }
206 
207  for (const std::string& i : m_lorentzAngleCorrectionHistos) {
208  ATH_MSG_INFO("Reading histogram: " << i << " for Lorentz angle correction needed for Pixel radiation damage simulation");
209  std::unique_ptr<TH1> h(file->Get<TH1>(i.c_str()));
210  if (!h) {
211  ATH_MSG_ERROR("Cannot read histogram " << i << " needed for Lorentz angle correction");
212  return StatusCode::FAILURE;
213  }
214 
215  m_lorentzCorrection.emplace_back();
216  ATH_CHECK(m_lorentzCorrection.back().setHisto1D(h.get()));
217  }
218 
219  for (const std::string& i : m_chargeCorrectionHistos) {
220  ATH_MSG_INFO("Reading histogram: " << i << " for charge correction needed for Pixel radiation damage simulation");
221  std::unique_ptr<TH1> h(file->Get<TH1>(i.c_str()));
222  if (!h) {
223  ATH_MSG_ERROR("Cannot read histogram " << i << " needed for charge correction");
224  return StatusCode::FAILURE;
225  }
226 
227  m_chargeCorrection.emplace_back();
228  ATH_CHECK(m_chargeCorrection.back().setHisto1D(h.get()));
229  }
230 
231  for (const std::string& i : m_distanceCorrectionHistos) {
232  ATH_MSG_INFO("Reading histogram: " << i << " for distance correction needed for Pixel radiation damage simulation");
233  std::unique_ptr<TH1> h(file->Get<TH1>(i.c_str()));
234  if (!h) {
235  ATH_MSG_ERROR("Cannot read histogram " << i << " needed for distance correction");
236  return StatusCode::FAILURE;
237  }
238 
239  m_distanceCorrection.emplace_back();
240  ATH_CHECK(m_distanceCorrection.back().setHisto1D(h.get()));
241  }
242 
243  file->Close();
244  }
245 
246  return StatusCode::SUCCESS;
247 }
248 
249 //===============================================
250 // F I N A L I Z E
251 //===============================================
253  ATH_MSG_DEBUG("SensorSimPlanarTool::finalize()");
254  return StatusCode::SUCCESS;
255 }
256 
257 //===============================================
258 // I N D U C E C H A R G E
259 //===============================================
261  SiChargedDiodeCollection& chargedDiodes,
262  const InDetDD::SiDetectorElement& Module,
263  const InDetDD::PixelModuleDesign& p_design,
264  std::vector< std::pair<double, double> >& trfHitRecord,
265  std::vector<double>& initialConditions,
266  CLHEP::HepRandomEngine* rndmEngine,
267  const EventContext &ctx) {
268 
269  bool isITk(false);
271  isITk = true;
272  if (p_design.is3D() && m_digitizeITk3Das3D) {
273  return StatusCode::SUCCESS;
274  }
275  } else {
276  // So far, this is only discriminating variable from 3D sensor.
277  if (p_design.numberOfCircuits() < 2) {
278  if (!Module.isDBM()) { //DBM modules also processed here
279  return StatusCode::SUCCESS;
280  }
281  }
282  }
283 
284  const PixelID* p_pixelId = static_cast<const PixelID*>(Module.getIdHelper());
285  int layer = p_pixelId->layer_disk(Module.identify());
286 
287  //Load values from energyDeposition
288  double eta_0 = initialConditions[0];
289  double phi_0 = initialConditions[1];
290  double depth_0 = initialConditions[2];
291  double dEta = initialConditions[3];
292  double dPhi = initialConditions[4];
293  double dDepth = initialConditions[5];
294  double ncharges = initialConditions[6];
295  double iTotalLength = initialConditions[7];
296 
297  const double oneOverNchargesTimes1e6 = 1./(1.E+6 * ncharges);
298 
299  //Set up physical detector properties, switch on detector material
300  ATH_MSG_DEBUG("Applying planar sensor simulation");
301  double sensorThickness = Module.design().thickness();
302  const InDet::SiliconProperties& siProperties = m_siPropertiesTool->getSiProperties(Module.identifyHash(), ctx);
303 
304  int etaCells = p_design.columns();
305  int phiCells = p_design.rows();
306 
307  double eleholePairEnergy = 0;
308  double smearRand = 0;
309 
310  if (Module.isDBM()) {
311  eleholePairEnergy = 1. / (13. * CLHEP::eV); // was 3.62 eV.
312  m_diffusionConstant = .00265;
313  smearRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
314  } else {
315  eleholePairEnergy = siProperties.electronHolePairsPerEnergy();
316  m_diffusionConstant = .007;
317  }
318 
319  double collectionDist = 0.2 * CLHEP::mm;
320  double smearScale = 1. + 0.35 * smearRand;
321  double tanLorentz(0);
322  double coLorentz(0);
323  if (m_radiationDamageSimulationType != RadiationDamageSimulationType::TEMPLATE_CORRECTION) {
324  tanLorentz = m_lorentzAngleTool->getTanLorentzAngle(Module.identifyHash(), ctx);
325  coLorentz = std::sqrt(1.0 + (tanLorentz*tanLorentz));
326  }
327 
328  //**************************************//
329  //*** Now diffuse charges to surface *** //
330  //**************************************//
331  // pre-make HepMcParticleLink
332  const HepMcParticleLink particleLink = HepMcParticleLink::getRedirectedLink(phit->particleLink(), phit.eventId(), ctx); // This link should now correctly resolve to the TruthEvent McEventCollection in the main StoreGateSvc.
333  const double pHitTime = hitTime(phit);
334 
335  const double halfEtaPitch = 0.5*Module.etaPitch();
336  const double halfPhiPitch = 0.5*Module.phiPitch();
337 
338  if (m_radiationDamageSimulationType == RadiationDamageSimulationType::RAMO_POTENTIAL && !(Module.isDBM()) && Module.isBarrel()) {
340  const PixelRadiationDamageFluenceMapData *fluenceData = *fluenceDataHandle;
341 
342  std::pair<double, double> trappingTimes;
343  if (m_doInterpolateEfield) {
344  trappingTimes = m_radDamageUtil->getTrappingTimes(m_fluenceLayer[layer]);
345  }
346  else {
347  trappingTimes = m_radDamageUtil->getTrappingTimes(fluenceData->getFluenceLayer(layer));
348  }
349 
350  const PixelHistoConverter& distanceMap_e = m_doInterpolateEfield ? m_distanceMap_e[layer] : fluenceData->getDistanceMap_e(layer);
351  const PixelHistoConverter& distanceMap_h = m_doInterpolateEfield ? m_distanceMap_h[layer] : fluenceData->getDistanceMap_h(layer);
352  const PixelHistoConverter& lorentzMap_e = m_doInterpolateEfield ? m_lorentzMap_e[layer] : fluenceData->getLorentzMap_e(layer);
353  const PixelHistoConverter& lorentzMap_h = m_doInterpolateEfield ? m_lorentzMap_h[layer] : fluenceData->getLorentzMap_h(layer);
354  const PixelHistoConverter& ramoPotentialMap = m_doInterpolateEfield ? m_ramoPotentialMap[layer] : fluenceData->getRamoPotentialMap(layer);
355 
356  std::map<unsigned, std::pair<SiLocalPosition, double>> cachedChargeMap;
357  std::map<unsigned, SiCellId> diodeCellMap;
358  for (const auto& iHitRecord : trfHitRecord) {
359 
360  double eta_i = eta_0;
361  double phi_i = phi_0;
362  double depth_i = depth_0;
363  if (iTotalLength) {
364  eta_i += 1.0 * iHitRecord.first / iTotalLength * dEta;
365  phi_i += 1.0 * iHitRecord.first / iTotalLength * dPhi;
366  depth_i += 1.0 * iHitRecord.first / iTotalLength * dDepth;
367  }
368 
369  //Find the position of the centre of the pixel in which the charge carriers are created, wrt centre of module
370  SiLocalPosition pos_i = Module.hitLocalToLocal(eta_i, phi_i);
371  SiCellId pixel_i = Module.cellIdOfPosition(pos_i);
372  if (!pixel_i.isValid()) continue;
373 
374  // Distance between charge and readout side. p_design->readoutSide() is
375  // +1 if readout side is in +ve depth axis direction and visa-versa.
376  double dist_electrode = 0.5 * sensorThickness - Module.design().readoutSide() * depth_i;
377  if (dist_electrode < 0) {
378  dist_electrode = 0;
379  }
380 
381  SiLocalPosition centreOfPixel_i = p_design.positionFromColumnRow(pixel_i.etaIndex(), pixel_i.phiIndex());
382 
383  //Make limits for NN loop
384  const int nnLoop_pixelEtaMax = std::min(1, pixel_i.etaIndex());
385  const int nnLoop_pixelEtaMin = std::max(-1, pixel_i.etaIndex() + 1 - etaCells);
386  const int nnLoop_pixelPhiMax = std::min(1, pixel_i.phiIndex());
387  const int nnLoop_pixelPhiMin = std::max(-1, pixel_i.phiIndex() + 1 - phiCells);
388 
389  std::array<double, 3> sensorScales{};
390 
391  const std::size_t distance_f_e_bin_x = distanceMap_e.getBinX(dist_electrode);
392  const std::size_t distance_f_h_bin_x = distanceMap_h.getBinX(dist_electrode);
393  const std::size_t tanLorentz_e_bin_x = lorentzMap_e.getBinX(dist_electrode);
394  const std::size_t tanLorentz_h_bin_x = lorentzMap_h.getBinX(dist_electrode);
395 
396  const std::size_t sizePhi = std::abs(nnLoop_pixelPhiMax - nnLoop_pixelPhiMin) + 1;
397 
398  const auto pixel_eta = pixel_i.etaIndex();
399  const auto pixel_phi = pixel_i.phiIndex();
400 
401  for (int p = nnLoop_pixelEtaMin; p <= nnLoop_pixelEtaMax; p++) {
402  const std::size_t ieta = p - nnLoop_pixelEtaMin;
403  // scale factors accounting for different pixel sizes
404  double scale_f = 1.;
405  double columnWidth = p_design.widthFromColumnRange(pixel_eta - p, pixel_eta - p);
406  if (std::abs(columnWidth - 0.6) < 1e-9) {
407  scale_f = 4. / 6.;
408  } else if (std::abs(columnWidth - 0.45) < 1e-9) {
409  scale_f = 25. / 45.;
410  } else if (std::abs(columnWidth - 0.5) < 1e-9) {
411  scale_f = 25. / 50.;
412  }
413  sensorScales[ieta] = scale_f;
414 
415  for (int q = nnLoop_pixelPhiMin; q <= nnLoop_pixelPhiMax; q++) {
416  const SiLocalPosition& centreOfPixel_nn = p_design.positionFromColumnRow(pixel_eta - p,
417  pixel_phi - q);
418  const std::size_t iphi = q - nnLoop_pixelPhiMin;
419  const std::size_t index = iphi + ieta*sizePhi;
420  m_centrePixelNNEtaPhi[index].first = centreOfPixel_nn.xEta();
421  m_centrePixelNNEtaPhi[index].second = centreOfPixel_nn.xPhi();
422  }
423  }
424 
425 
426  for (int j = 0; j < ncharges; j++) {
427  // amount of energy to be converted into charges at current step
428  double energy_per_step = oneOverNchargesTimes1e6 * iHitRecord.second;
429  double u = CLHEP::RandFlat::shoot(rndmEngine, 0.0, 1.0);
430  // need to update to std::logf when we update gcc - this is a known bug in gcc libc
431  const double drifttime_e = (-1.) * (trappingTimes.first) * logf(u); //ns
432  u = CLHEP::RandFlat::shoot(rndmEngine, 0.0, 1.0);
433  const double drifttime_h = (-1.) * (trappingTimes.second) * logf(u); //ns
434 
435  //Now, need the z-position at the trap.
436  //TODO: the holes map does not currently extend for a drift time long enough that, any hole will reach
437  //the corresponding electrode. This needs to be rectified by either (a) extrapolating the current map or
438  //(b) making a new map with a y-axis (drift time) that extends to at least 18 ns so all charge carriers reach
439  // electrode.
440  //However, if choose (b), will need to reduce granularity of map.
441  const double depth_f_e = distanceMap_e.getContent(distance_f_e_bin_x, distanceMap_e.getBinY(drifttime_e));
442  const double depth_f_h = distanceMap_h.getContent(distance_f_h_bin_x, distanceMap_h.getBinY(drifttime_h));
443  const double tanLorentz_e = lorentzMap_e.getContent(tanLorentz_e_bin_x, lorentzMap_e.getBinY(depth_f_e));
444  const double tanLorentz_h = lorentzMap_h.getContent(tanLorentz_h_bin_x, lorentzMap_h.getBinY(depth_f_h));
445  const double dz_e = std::abs(dist_electrode - depth_f_e);
446  const double dz_h = std::abs(depth_f_h - dist_electrode);
447  const double coLorentz_e = std::sqrt(1.0 + (tanLorentz_e*tanLorentz_e));
448 
449  //Apply drift due to Lorentz force and diffusion
450  double phiRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
451 
452  //Apply diffusion. rdif is teh max. diffusion
453  const double rdif_e = this->m_diffusionConstant * std::sqrt(dz_e * coLorentz_e / 0.3);
454  const double phi_f_e = phi_i + dz_e * tanLorentz_e + rdif_e * phiRand;
455  double etaRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
456  double eta_f_e = eta_i + rdif_e * etaRand;
457 
458  phiRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
459  const double coLorentz_h = std::sqrt(1.0 + (tanLorentz_h*tanLorentz_h));
460  const double rdif_h = this->m_diffusionConstant * std::sqrt(dz_h * coLorentz_h / 0.3);
461  const double phi_f_h = phi_i + dz_h * tanLorentz_h + rdif_h * phiRand;
462  etaRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
463  double eta_f_h = eta_i + rdif_h * etaRand;
464 
465 
466  // Slim Edge for IBL planar sensors:
468  applyIBLSlimEdges(energy_per_step, eta_f_e);
469  applyIBLSlimEdges(energy_per_step, eta_f_h);
470  }
471 
472  const std::size_t ramo_f_e_bin_z = ramoPotentialMap.getBinZ(1e3*depth_f_e);
473  const std::size_t ramo_f_h_bin_z = ramoPotentialMap.getBinZ(1e3*depth_f_h);
474 
475  const bool isFirstZ_e = ramoPotentialMap.isFirstZ(1e3*depth_f_e);
476  const bool isOverflowZ_h = ramoPotentialMap.isOverflowZ(1e3*depth_f_h);
477 
478  const double pixelEta_f_e = eta_f_e - centreOfPixel_i.xEta();
479  const double pixelPhi_f_e = phi_f_e - centreOfPixel_i.xPhi();
480 
481  const double pixelEta_f_h = eta_f_h - centreOfPixel_i.xEta();
482  const double pixelPhi_f_h = phi_f_h - centreOfPixel_i.xPhi();
483 
484  //Loop over nearest neighbours in x and y
485  //We assume that the lateral diffusion is minimal
486  for (int p = nnLoop_pixelEtaMin; p <= nnLoop_pixelEtaMax; p++) {
487  const std::size_t ieta = p - nnLoop_pixelEtaMin;
488 
489  for (int q = nnLoop_pixelPhiMin; q <= nnLoop_pixelPhiMax; q++) {
490  //Since both e-h charge carriers start in the same place, they have the same initial ramo value
491  //Centre of nearest neighbour (nn) pixel
492 
493  const std::size_t iphi = q - nnLoop_pixelPhiMin;
494  const std::size_t index = iphi + ieta*sizePhi;
495  //What is the displacement of the nn pixel from the primary pixel.
496  //This is to index the correct entry in the Ramo weighting potential map
497  const std::pair<double,double>& centrePixelNN = m_centrePixelNNEtaPhi[index];
498  const double dPhi_nn_centre = centrePixelNN.second - centreOfPixel_i.xPhi(); //in mm
499  const double dEta_nn_centre = centrePixelNN.first - centreOfPixel_i.xEta(); //in mm
500 
501  //This all has to be done relative to the (0,0) position since the
502  //Ramo weighting potential is only mapped out for 1/8th of a pixel. Much of this logic is reflecting the
503  // charge carrier across the boundaries.
504  //Find the displacment of the charge carriers from the centre of the pixel in +ve quadrant
505 
506  //Final position of charge carriers wrt nn centre
507  const double dEta_f_e = std::abs(pixelEta_f_e - dEta_nn_centre)*sensorScales[ieta];
508  const double dPhi_f_e = std::abs(pixelPhi_f_e - dPhi_nn_centre);
509  const double dEta_f_h = 1e3*std::abs(pixelEta_f_h - dEta_nn_centre)*sensorScales[ieta];
510  const double dPhi_f_h = 1e3*std::abs(pixelPhi_f_h - dPhi_nn_centre);
511 
512  //Boundary check on maps
513  double ramo_f_e = 0.0;
514  double ramo_f_h = 0.0;
515 
516  if (isFirstZ_e) {
517  if (dEta_f_e >= halfEtaPitch || dPhi_f_e >= halfPhiPitch) {
518  ramo_f_e = 0.0;
519  } else {
520  ramo_f_e = 1.0;
521  }
522  } else {
523  ramo_f_e = ramoPotentialMap.getContent(ramoPotentialMap.getBinX(1e3*dPhi_f_e), ramoPotentialMap.getBinY(1e3*dEta_f_e), ramo_f_e_bin_z);
524  }
525 
526  //Account for the imperfect binning that would cause charge to be double-counted
527  if (isOverflowZ_h) {
528  ramo_f_h = 0;
529  } else {
530  ramo_f_h = ramoPotentialMap.getContent(ramoPotentialMap.getBinX(dPhi_f_h), ramoPotentialMap.getBinY(dEta_f_h), ramo_f_h_bin_z);
531  }
532 
533  //Given final position of charge carrier, find induced charge. The difference in Ramo weighting potential
534  // gives the fraction of charge induced.
535  //The energy_per_step is transformed into charge with the eleholePair per Energy
536  const double potentialDiff = ramo_f_e - ramo_f_h;
537  // this variable ^ can be used to apply some cut to skip the loop
538  const double induced_charge = potentialDiff * energy_per_step * eleholePairEnergy;
539 
540  unsigned key = (static_cast<unsigned>(pixel_eta-p) << 16) | static_cast<unsigned>(pixel_phi-q);
541  auto cacheIterator = cachedChargeMap.find(key);
542  if(cacheIterator == cachedChargeMap.end()) {
543  cachedChargeMap.insert(std::make_pair(key, std::make_pair(Module.hitLocalToLocal(centrePixelNN.first, centrePixelNN.second), induced_charge)));
544  } else {
545  cacheIterator->second.second += induced_charge;
546  }
547  } //For q
548  } //for p
549  }//end cycle for charge
550  } //trfHitRecord.size()
551 
552  std::for_each(cachedChargeMap.begin(), cachedChargeMap.end(), [&diodeCellMap, &Module, &chargedDiodes, &pHitTime, &particleLink](auto& pos_charge_pair){
553  auto& key = pos_charge_pair.first;
554  auto& chargePos = pos_charge_pair.second.first;
555  auto& charge_value = pos_charge_pair.second.second;
556 
557  const SiSurfaceCharge scharge(chargePos, SiCharge(charge_value, pHitTime, SiCharge::track, particleLink));
558  auto diodeIterator = diodeCellMap.find(key);
559  if(diodeIterator == diodeCellMap.end()) diodeIterator = diodeCellMap.insert(std::make_pair(key, Module.cellIdOfPosition(scharge.position()))).first;
560  const SiCellId& thisDiode = diodeIterator->second;
561  if (thisDiode.isValid()) {
562  const SiCharge& charge = scharge.charge();
563  chargedDiodes.add(thisDiode, charge);
564  }
565  });
566 
567  }
568  else if (m_radiationDamageSimulationType == RadiationDamageSimulationType::TEMPLATE_CORRECTION && !(Module.isDBM()) && Module.isBarrel()){ // will run radiation damage but with the template method
569 
570  // For Pixel, the layers in the barrel are 0, 1, 2 and 3
571  // But for ITk Pixel, these are 1, 2, 3 and 4
572  // So, we need to adjust for the position in the vector for ITk
573 
574  int layerToRead = isITk && m_digitizeITk3Das3D ? layer - 1 : layer;
575 
576  // temporary solution for treating 3D as planar in the digitisation
577  if (layerToRead > 3) {
578  layerToRead = 3;
579  }
580 
581  const PixelHistoConverter& distanceCorrectionHist = m_distanceCorrection[layerToRead];
582  const PixelHistoConverter& lorentzCorrectionHist = m_lorentzCorrection[layerToRead];
583  const PixelHistoConverter& chargeCorrectionHist = m_chargeCorrection[layerToRead];
584 
585  for (const auto & iHitRecord : trfHitRecord) {
586  double eta_i = eta_0;
587  double phi_i = phi_0;
588  double depth_i = depth_0;
589  if (iTotalLength) {
590  eta_i += 1.0 * iHitRecord.first / iTotalLength * dEta;
591  phi_i += 1.0 * iHitRecord.first / iTotalLength * dPhi;
592  depth_i += 1.0 * iHitRecord.first / iTotalLength * dDepth;
593  }
594 
595  const double depthZ = (depth_i + 0.5*sensorThickness)/Gaudi::Units::micrometer; // to get it in micro meters
596 
597  const double dist_electrode = distanceCorrectionHist.getContent(depthZ)*Gaudi::Units::micrometer; // to get it in mm
598 
599  // get corrected LA
600  tanLorentz = lorentzCorrectionHist.getContent(depthZ);
601  coLorentz = std::sqrt(1.0 + (tanLorentz*tanLorentz));
602 
603  // for charge corrections
604  const double chargeCorrection = chargeCorrectionHist.getContent(depthZ);
605 
606  // nonTrapping probability
607  double nontrappingProbability = 1.0;
608  if (Module.isDBM()) {
609  nontrappingProbability = exp(-dist_electrode / collectionDist);
610  }
611 
612  for (int j = 0; j < ncharges; j++) {
613  // amount of energy to be converted into charges at current step
614  double energy_per_step = oneOverNchargesTimes1e6 * iHitRecord.second;
615  // diffusion sigma
616  double rdif = this->m_diffusionConstant * std::sqrt(dist_electrode * coLorentz / 0.3);
617 
618  // position at the surface
619  double phiRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
620  double phi_drifted = phi_i + dist_electrode * tanLorentz + rdif * phiRand;
621  double etaRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
622  double eta_drifted = eta_i + rdif * etaRand;
623 
624  // Slim Edge for IBL planar sensors:
625  if (!(Module.isDBM()) && p_design.getReadoutTechnology() == InDetDD::PixelReadoutTechnology::FEI4) {
626  applyIBLSlimEdges(energy_per_step, eta_drifted);
627  }
628 
629  // Get the charge position in Reconstruction local coordinates.
630  const SiLocalPosition& chargePos = Module.hitLocalToLocal(eta_drifted, phi_drifted);
631 
632  // The parametrization of the sensor efficiency (if needed)
633  double ed = 0;
634  if (Module.isDBM()) {
635  ed = energy_per_step * eleholePairEnergy * nontrappingProbability * smearScale;
636  } else {
637  ed = energy_per_step * eleholePairEnergy;
638  }
639  // apply the correction from radiation damage
640  ed *= chargeCorrection;
641 
642  //The following lines are adapted from SiDigitization's Inserter class
643  const SiSurfaceCharge scharge(chargePos, SiCharge(ed, pHitTime, SiCharge::track, particleLink));
644 
645  const SiCellId& diode = Module.cellIdOfPosition(scharge.position());
646 
647  if (diode.isValid()) {
648  const SiCharge& charge = scharge.charge();
649  chargedDiodes.add(diode, charge);
650  }
651  }//end cycle for charge
652  }//trfHitRecord.size()
653  } else { // run without radiation damage
654  for (const auto & iHitRecord : trfHitRecord) {
655  double eta_i = eta_0;
656  double phi_i = phi_0;
657  double depth_i = depth_0;
658  if (iTotalLength) {
659  eta_i += 1.0 * iHitRecord.first / iTotalLength * dEta;
660  phi_i += 1.0 * iHitRecord.first / iTotalLength * dPhi;
661  depth_i += 1.0 * iHitRecord.first / iTotalLength * dDepth;
662  }
663 
664  // Distance between charge and readout side. p_design->readoutSide() is
665  // +1 if readout side is in +ve depth axis direction and visa-versa.
666  double dist_electrode = 0.5 * sensorThickness - Module.design().readoutSide() * depth_i;
667  if (dist_electrode < 0) {
668  dist_electrode = 0;
669  }
670 
671  // nonTrapping probability
672  double nontrappingProbability = 1.0;
673  if (Module.isDBM()) {
674  nontrappingProbability = exp(-dist_electrode / collectionDist);
675  }
676 
677  for (int j = 0; j < ncharges; j++) {
678  // amount of energy to be converted into charges at current step
679  double energy_per_step = oneOverNchargesTimes1e6 * iHitRecord.second;
680  // diffusion sigma
681  double rdif = this->m_diffusionConstant * std::sqrt(dist_electrode * coLorentz / 0.3);
682 
683  // position at the surface
684  double phiRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
685  double phi_drifted = phi_i + dist_electrode * tanLorentz + rdif * phiRand;
686  double etaRand = CLHEP::RandGaussZiggurat::shoot(rndmEngine);
687  double eta_drifted = eta_i + rdif * etaRand;
688 
689  // Slim Edge for IBL planar sensors:
690  if (!(Module.isDBM()) && p_design.getReadoutTechnology() == InDetDD::PixelReadoutTechnology::FEI4) {
691  applyIBLSlimEdges(energy_per_step, eta_drifted);
692  }
693 
694  // Get the charge position in Reconstruction local coordinates.
695  const SiLocalPosition& chargePos = Module.hitLocalToLocal(eta_drifted, phi_drifted);
696 
697  // The parametrization of the sensor efficiency (if needed)
698  double ed = 0;
699  if (Module.isDBM()) {
700  ed = energy_per_step * eleholePairEnergy * nontrappingProbability * smearScale;
701  } else {
702  ed = energy_per_step * eleholePairEnergy;
703  }
704 
705  //The following lines are adapted from SiDigitization's Inserter class
706  const SiSurfaceCharge scharge(chargePos, SiCharge(ed, pHitTime, SiCharge::track, particleLink));
707 
708  const SiCellId& diode = Module.cellIdOfPosition(scharge.position());
709 
710  if (diode.isValid()) {
711  const SiCharge& charge = scharge.charge();
712  chargedDiodes.add(diode, charge);
713  }
714  }//end cycle for charge
715  }
716  }
717 
718  return StatusCode::SUCCESS;
719 }
720 
721 void SensorSimPlanarTool::applyIBLSlimEdges(double& energy_per_step, double& eta_drifted) {
722  if (std::abs(eta_drifted) > 20.440) {
723  energy_per_step = 0.0;
724  }
725  if (std::abs(eta_drifted) < 20.440 && std::abs(eta_drifted) > 20.200) {
726  if (eta_drifted > 0) {
727  energy_per_step = energy_per_step * (68.13 - eta_drifted * 3.333);
728  eta_drifted = eta_drifted - 0.250;
729  } else {
730  energy_per_step = energy_per_step * (68.13 + eta_drifted * 3.333);
731  eta_drifted = eta_drifted + 0.250;
732  }
733  }
734  if (std::abs(eta_drifted) < 20.200 && std::abs(eta_drifted) > 20.100) {
735  if (eta_drifted > 0) {
736  energy_per_step = energy_per_step * (41.2 - eta_drifted * 2.0);
737  eta_drifted = eta_drifted - 0.250;
738  } else {
739  energy_per_step = energy_per_step * (41.2 + eta_drifted * 2.0);
740  eta_drifted = eta_drifted + 0.250;
741  }
742  }
743 }
PixelID.h
This is an Identifier helper class for the Pixel subdetector. This class is a factory for creating co...
AllowedVariables::e
e
Definition: AsgElectronSelectorTool.cxx:37
SiSurfaceCharge
Definition: SiSurfaceCharge.h:23
InDetDD::SolidStateDetectorElementBase::cellIdOfPosition
SiCellId cellIdOfPosition(const Amg::Vector2D &localPos) const
As in previous method but returns SiCellId.
Definition: SolidStateDetectorElementBase.cxx:224
SensorSimPlanarTool::m_fluenceLayer
Gaudi::Property< std::vector< double > > m_fluenceLayer
Definition: SensorSimPlanarTool.h:85
SensorSimPlanarTool::m_distanceCorrection
std::vector< PixelHistoConverter > m_distanceCorrection
Definition: SensorSimPlanarTool.h:56
SensorSimPlanarTool::m_distanceMap_e
std::vector< PixelHistoConverter > m_distanceMap_e
Definition: SensorSimPlanarTool.h:49
InDetDD::DetectorDesign::thickness
double thickness() const
Method which returns thickness of the silicon wafer.
Definition: DetectorDesign.h:271
max
#define max(a, b)
Definition: cfImp.cxx:41
SG::ReadCondHandle
Definition: ReadCondHandle.h:44
ATH_MSG_INFO
#define ATH_MSG_INFO(x)
Definition: AthMsgStreamMacros.h:31
PixelHistoConverter::getBinY
std::size_t getBinY(Args &&...args) const
Definition: PixelHistoConverter.h:79
InDetDD::PixelModuleDesign
Definition: PixelModuleDesign.h:48
InDetDD::PixelModuleDesign::columns
int columns() const
Number of cell columns per module:
Definition: PixelModuleDesign.h:322
SensorSimTool::m_radiationDamageSimulationType
Gaudi::Property< int > m_radiationDamageSimulationType
Definition: SensorSimTool.h:87
SiHit.h
index
Definition: index.py:1
InDetDD::PixelModuleDesign::rows
int rows() const
Number of cell rows per module:
Definition: PixelModuleDesign.h:327
SensorSimPlanarTool::m_chargeCorrection
std::vector< PixelHistoConverter > m_chargeCorrection
Definition: SensorSimPlanarTool.h:55
SiCharge::track
@ track
Definition: SiCharge.h:28
SensorSimPlanarTool::m_distanceMap_h
std::vector< PixelHistoConverter > m_distanceMap_h
Definition: SensorSimPlanarTool.h:50
InDetDD::SiCellId::isValid
bool isValid() const
Test if its in a valid state.
Definition: SiCellId.h:136
InDetDD::DetectorDesign::readoutSide
int readoutSide() const
ReadoutSide.
Definition: DetectorDesign.h:291
SiCharge
Definition: SiCharge.h:25
SensorSimPlanarTool::m_centrePixelNNEtaPhi
std::vector< std::pair< double, double > > m_centrePixelNNEtaPhi
Definition: SensorSimPlanarTool.h:53
InDetDD::SiCellId::phiIndex
int phiIndex() const
Get phi index. Equivalent to strip().
Definition: SiCellId.h:122
TimedHitPtr< SiHit >
SensorSimTool::m_fluenceDataKey
SG::ReadCondHandleKey< PixelRadiationDamageFluenceMapData > m_fluenceDataKey
Definition: SensorSimTool.h:116
SensorSimTool::m_chargeCorrectionHistos
Gaudi::Property< std::vector< std::string > > m_chargeCorrectionHistos
Definition: SensorSimTool.h:104
SensorSimPlanarTool::m_lorentzCorrection
std::vector< PixelHistoConverter > m_lorentzCorrection
Definition: SensorSimPlanarTool.h:54
drawFromPickle.exp
exp
Definition: drawFromPickle.py:36
python.TrigEgammaMonitorHelper.TH2F
def TH2F(name, title, nxbins, bins_par2, bins_par3, bins_par4, bins_par5=None, bins_par6=None, path='', **kwargs)
Definition: TrigEgammaMonitorHelper.py:45
SensorSimTool::m_siPropertiesTool
ToolHandle< ISiPropertiesTool > m_siPropertiesTool
Definition: SensorSimTool.h:77
InDetDD::SolidStateDetectorElementBase::etaPitch
double etaPitch() const
Pitch (inline methods)
Trk::u
@ u
Enums for curvilinear frames.
Definition: ParamDefs.h:77
InDetDD::SolidStateDetectorElementBase::identifyHash
virtual IdentifierHash identifyHash() const override final
identifier hash (inline)
PixelRadiationDamageFluenceMapData::getLorentzMap_e
const PixelHistoConverter & getLorentzMap_e(int layer) const
Definition: PixelRadiationDamageFluenceMapData.cxx:38
InDetDD::SolidStateDetectorElementBase::getIdHelper
const AtlasDetectorID * getIdHelper() const
Returns the id helper (inline)
PathResolverFindCalibDirectory
std::string PathResolverFindCalibDirectory(const std::string &logical_file_name)
Definition: PathResolver.cxx:432
InDetDD::PixelReadoutTechnology::RD53
@ RD53
InDetDD::SiLocalPosition
Definition: SiLocalPosition.h:31
InDetDD::PixelModuleDesign::positionFromColumnRow
SiLocalPosition positionFromColumnRow(const int column, const int row) const
Given row and column index of a diode, return position of diode center ALTERNATIVE/PREFERED way is to...
Definition: PixelModuleDesign.cxx:219
InDetDD::SiLocalPosition::xPhi
double xPhi() const
position along phi direction:
Definition: SiLocalPosition.h:123
PixelHistoConverter::getBinZ
std::size_t getBinZ(Args &&...args) const
Definition: PixelHistoConverter.h:84
SensorSimTool::initialize
virtual StatusCode initialize()
Definition: SensorSimTool.h:54
InDetDD::SiDetectorElement::phiPitch
double phiPitch() const
Pitch (inline methods)
python.utils.AtlRunQueryDQUtils.p
p
Definition: AtlRunQueryDQUtils.py:210
InDetDD::PixelModuleDesign::widthFromColumnRange
double widthFromColumnRange(const int colMin, const int colMax) const
Method to calculate eta width from a column range.
Definition: PixelModuleDesign.cxx:132
InDetDD::SiCellId::etaIndex
int etaIndex() const
Get eta index.
Definition: SiCellId.h:114
SensorSimPlanarTool::m_lorentzMap_h
std::vector< PixelHistoConverter > m_lorentzMap_h
Definition: SensorSimPlanarTool.h:52
ATH_MSG_ERROR
#define ATH_MSG_ERROR(x)
Definition: AthMsgStreamMacros.h:33
CheckAppliedSFs.e3
e3
Definition: CheckAppliedSFs.py:264
SiChargedDiodeCollection
Definition: SiChargedDiodeCollection.h:109
PixelHistoConverter
Definition: PixelHistoConverter.h:25
PixelRadiationDamageFluenceMapData
Definition: PixelRadiationDamageFluenceMapData.h:25
lumiFormat.i
int i
Definition: lumiFormat.py:85
InDetDD::SiLocalPosition::xEta
double xEta() const
position along eta direction:
Definition: SiLocalPosition.h:118
h
SensorSimPlanarTool::finalize
virtual StatusCode finalize() override
Definition: SensorSimPlanarTool.cxx:252
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
extractSporadic.h
list h
Definition: extractSporadic.py:97
ATH_MSG_DEBUG
#define ATH_MSG_DEBUG(x)
Definition: AthMsgStreamMacros.h:29
PixelRadiationDamageFluenceMapData::getLorentzMap_h
const PixelHistoConverter & getLorentzMap_h(int layer) const
Definition: PixelRadiationDamageFluenceMapData.cxx:39
TRT::Hit::layer
@ layer
Definition: HitInfo.h:79
TauGNNUtils::Variables::Track::dPhi
bool dPhi(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)
Definition: TauGNNUtils.cxx:538
SensorSimPlanarTool::m_doInterpolateEfield
Gaudi::Property< bool > m_doInterpolateEfield
Definition: SensorSimPlanarTool.h:69
InDetDD::PixelModuleDesign::numberOfCircuits
int numberOfCircuits() const
Total number of circuits:
Definition: PixelModuleDesign.h:297
PixelHistoConverter::isFirstZ
bool isFirstZ(const float value) const
Definition: PixelHistoConverter.cxx:101
file
TFile * file
Definition: tile_monitor.h:29
test_pyathena.parent
parent
Definition: test_pyathena.py:15
ATH_CHECK
#define ATH_CHECK
Definition: AthCheckMacros.h:40
CHECK
#define CHECK(...)
Evaluate an expression and check for errors.
Definition: Control/AthenaKernel/AthenaKernel/errorcheck.h:422
python.SystemOfUnits.micrometer
int micrometer
Definition: SystemOfUnits.py:71
SensorSimPlanarTool::m_voltageLayer
Gaudi::Property< std::vector< float > > m_voltageLayer
Definition: SensorSimPlanarTool.h:92
SensorSimPlanarTool::m_fluenceMap
Gaudi::Property< std::vector< std::string > > m_fluenceMap
Definition: SensorSimPlanarTool.h:74
SensorSimPlanarTool::m_radDamageUtil
ToolHandle< RadDamageUtil > m_radDamageUtil
Definition: SensorSimPlanarTool.h:99
InDetDD::SolidStateDetectorElementBase::hitLocalToLocal
Amg::Vector2D hitLocalToLocal(double xEta, double xPhi) const
Simulation/Hit local frame to reconstruction local frame.
Definition: SolidStateDetectorElementBase.cxx:95
min
#define min(a, b)
Definition: cfImp.cxx:40
PixelID::layer_disk
int layer_disk(const Identifier &id) const
Definition: PixelID.h:626
PathResolver.h
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:221
PixelRadiationDamageFluenceMapData::getDistanceMap_e
const PixelHistoConverter & getDistanceMap_e(int layer) const
Definition: PixelRadiationDamageFluenceMapData.cxx:40
SensorSimPlanarTool::initialize
virtual StatusCode initialize() override
Definition: SensorSimPlanarTool.cxx:47
python.SystemOfUnits.eV
int eV
Definition: SystemOfUnits.py:155
charge
double charge(const T &p)
Definition: AtlasPID.h:538
InDetDD::SiDetectorElement
Definition: SiDetectorElement.h:109
InDetDD::PixelReadoutTechnology::FEI4
@ FEI4
InDetDD::SiDetectorElement::isBarrel
bool isBarrel() const
SensorSimPlanarTool::SensorSimPlanarTool
SensorSimPlanarTool()
SensorSimTool::m_distanceCorrectionHistos
Gaudi::Property< std::vector< std::string > > m_distanceCorrectionHistos
Definition: SensorSimTool.h:110
SensorSimPlanarTool::induceCharge
virtual StatusCode induceCharge(const TimedHitPtr< SiHit > &phit, SiChargedDiodeCollection &chargedDiodes, const InDetDD::SiDetectorElement &Module, const InDetDD::PixelModuleDesign &p_design, std::vector< std::pair< double, double > > &trfHitRecord, std::vector< double > &initialConditions, CLHEP::HepRandomEngine *rndmEngine, const EventContext &ctx) override
Definition: SensorSimPlanarTool.cxx:260
InDet::SiliconProperties
Definition: SiliconProperties.h:24
InDetDD::PixelModuleDesign::getReadoutTechnology
PixelReadoutTechnology getReadoutTechnology() const
Definition: PixelModuleDesign.h:368
SiDetectorElement.h
PathResolverFindCalibFile
std::string PathResolverFindCalibFile(const std::string &logical_file_name)
Definition: PathResolver.cxx:431
PixelRadiationDamageFluenceMapData::getFluenceLayer
double getFluenceLayer(int layer) const
Definition: PixelRadiationDamageFluenceMapData.cxx:30
InDetDD::SiCellId
Definition: SiCellId.h:29
python.SystemOfUnits.mm
int mm
Definition: SystemOfUnits.py:83
PixelHistoConverter::isOverflowZ
bool isOverflowZ(const float value) const
Definition: PixelHistoConverter.h:44
DeMoScan.index
string index
Definition: DeMoScan.py:364
SensorSimTool::m_digitizeITk3Das3D
Gaudi::Property< bool > m_digitizeITk3Das3D
Definition: SensorSimTool.h:122
InDetDD::PixelModuleDesign::is3D
virtual bool is3D() const
Definition: PixelModuleDesign.h:363
PixelRadiationDamageFluenceMapData::getDistanceMap_h
const PixelHistoConverter & getDistanceMap_h(int layer) const
Definition: PixelRadiationDamageFluenceMapData.cxx:41
SensorSimPlanarTool.h
TimedHitPtr::eventId
unsigned short eventId() const
the index of the component event in PileUpEventInfo.
Definition: TimedHitPtr.h:45
ATH_MSG_WARNING
#define ATH_MSG_WARNING(x)
Definition: AthMsgStreamMacros.h:32
InDetDD
Message Stream Member.
Definition: FakeTrackBuilder.h:8
PixelModuleDesign.h
InDetDD::SiDetectorElement::isDBM
bool isDBM() const
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
InDet::SiliconProperties::electronHolePairsPerEnergy
double electronHolePairsPerEnergy() const
Definition: SiliconProperties.cxx:238
SensorSimPlanarTool::m_lorentzMap_e
std::vector< PixelHistoConverter > m_lorentzMap_e
Definition: SensorSimPlanarTool.h:51
extractSporadic.q
list q
Definition: extractSporadic.py:98
SensorSimPlanarTool::m_lorentzAngleTool
ToolHandle< ISiLorentzAngleTool > m_lorentzAngleTool
Definition: SensorSimPlanarTool.h:104
SensorSimTool
Definition: SensorSimTool.h:38
SensorSimPlanarTool::m_ramoPotentialMap
std::vector< PixelHistoConverter > m_ramoPotentialMap
Definition: SensorSimPlanarTool.h:48
python.TrigEgammaMonitorHelper.TH1F
def TH1F(name, title, nxbins, bins_par2, bins_par3=None, path='', **kwargs)
Definition: TrigEgammaMonitorHelper.py:24
hitTime
float hitTime(const AFP_SIDSimHit &hit)
Definition: AFP_SIDSimHit.h:39
SensorSimTool::m_templateCorrectionRootFile
Gaudi::Property< std::string > m_templateCorrectionRootFile
Definition: SensorSimTool.h:92
PixelHistoConverter::getBinX
std::size_t getBinX(Args &&...args) const
Definition: PixelHistoConverter.h:74
InDetDD::SiDetectorElement::design
virtual const SiDetectorDesign & design() const override final
access to the local description (inline):
TauGNNUtils::Variables::Track::dEta
bool dEta(const xAOD::TauJet &tau, const xAOD::TauTrack &track, double &out)
Definition: TauGNNUtils.cxx:527
SensorSimPlanarTool::~SensorSimPlanarTool
virtual ~SensorSimPlanarTool()
PixelID
Definition: PixelID.h:67
SensorSimPlanarTool::applyIBLSlimEdges
static void applyIBLSlimEdges(double &energyPerStep, double &eta_drifted)
Definition: SensorSimPlanarTool.cxx:721
SiSurfaceCharge.h
PixelRadiationDamageFluenceMapData::getRamoPotentialMap
const PixelHistoConverter & getRamoPotentialMap(int layer) const
Definition: PixelRadiationDamageFluenceMapData.cxx:42
InDetDD::SolidStateDetectorElementBase::identify
virtual Identifier identify() const override final
identifier of this detector element (inline)
SiliconProperties.h
SensorSimTool::m_lorentzAngleCorrectionHistos
Gaudi::Property< std::vector< std::string > > m_lorentzAngleCorrectionHistos
Definition: SensorSimTool.h:98
SiChargedDiodeCollection.h
PixelHistoConverter::getContent
float getContent(std::size_t x) const
Definition: PixelHistoConverter.h:34
mapkey::key
key
Definition: TElectronEfficiencyCorrectionTool.cxx:37
SensorSimPlanarTool::m_diffusionConstant
Gaudi::Property< double > m_diffusionConstant
Definition: SensorSimPlanarTool.h:64