![Logo](../../ATLAS-Logo-Square-Blue-RGB.png) |
ATLAS Offline Software
|
Go to the documentation of this file.
15 #include "CLHEP/Random/RandFlat.h"
16 #include "CLHEP/Random/RandGaussZiggurat.h"
32 return StatusCode::SUCCESS;
37 return StatusCode::SUCCESS;
41 CLHEP::HepRandomEngine* rndmEngine) {
60 const EventContext& ctx{Gaudi::Hive::currentContext()};
68 std::vector<Pixel1RawData*> p_rdo_small_fei4;
88 Identifier diodeID = chargedDiodes.
getId((*i_chargedDiode).first);
89 double charge = (*i_chargedDiode).second.charge();
96 const int th0 = thresholds.
value;
97 const int sigma = thresholds.sigma;
98 const int noise = thresholds.noise;
100 sigma * CLHEP::RandGaussZiggurat::shoot(rndmEngine) +
101 noise * CLHEP::RandGaussZiggurat::shoot(rndmEngine);
105 if ((*i_chargedDiode).second.totalCharge().fromTrack()) {
107 static_cast<int>(std::floor((
getG4Time((*i_chargedDiode).second.totalCharge()) +
113 const int timeWalk = 25;
115 static_cast<int>(std::floor((
getG4Time((*i_chargedDiode).second.totalCharge()) +
134 double totsig = calibData->
getTotRes(moduleHash, FE,
tot);
135 int nToT =
static_cast<int>(CLHEP::RandGaussZiggurat::shoot(rndmEngine,
tot, totsig));
142 if (nToT >= overflowToT) {
146 if (nToT <= moduleData->getToTThreshold(barrel_ec, layerIndex)) {
163 int flag = (*i_chargedDiode).second.flag();
164 int bunch = (
flag >> 8) & 0xff;
float getToT(InDetDD::PixelDiodeType type, unsigned int moduleHash, unsigned int FE, float Q) const
const InDetDD::SolidStateDetectorElementBase * element() const
static bool isDisabled(SiChargedDiode &chDiode)
int barrel_ec(const Identifier &id) const
Values of different levels (failure returns 0)
double getCrossTalk(int barrel_ec, int layer) const
PixelChargeCalib::Thresholds getThresholds(InDetDD::PixelDiodeType type, unsigned int moduleHash, unsigned int FE) const
Structs for holding charge calibration parameterisation and data.
SiChargedDiodeIterator end()
float getTotRes(unsigned int moduleHash, unsigned int FE, float Q) const
SiChargedDiodeIterator begin()
static void disabled(SiChargedDiode &chDiode, bool flag, bool mask=false)
Identifier wafer_id(int barrel_ec, int layer_disk, int phi_module, int eta_module) const
For a single crystal.
const AtlasDetectorID * getIdHelper() const
Returns the id helper (inline)
double getG4Time(const SiTotalCharge &totalCharge)
SiChargedDiodeMap::iterator SiChargedDiodeIterator
virtual Identifier identifierFromCellId(const SiCellId &cellId) const =0
Identifier <-> SiCellId (ie strip number or pixel eta_index,phi_index) Identifier from SiCellId (ie s...
Identifier getId(const InDetDD::SiCellId &id) const
IdentifierHash wafer_hash(Identifier wafer_id) const
wafer hash from id
::StatusCode StatusCode
StatusCode definition for legacy code.
static void belowThreshold(SiChargedDiode &chDiode, bool flag, bool mask=false)
static void SetBunch(SiChargedDiode &chDiode, int bunch, MsgStream *log=nullptr)
int layer_disk(const Identifier &id) const
static bool isMaskOut(SiChargedDiode &chDiode)
double charge(const T &p)
value_type push_back(value_type pElem)
Add an element to the end of the collection.
StatusCode initialize(bool used=true)
PixelReadoutTechnology getReadoutTechnology() const
void crossTalk(double crossTalk, SiChargedDiodeCollection &chargedDiodes)
constexpr int getFEI4OverflowToT() const
void randomNoise(SiChargedDiodeCollection &chargedDiodes, const PixelModuleData *moduleData, int nBcid, const PixelChargeCalibCondData *chargeCalibData, CLHEP::HepRandomEngine *rndmEngine, InDetDD::IPixelReadoutManager *pixelReadout)
void randomDisable(SiChargedDiodeCollection &chargedDiodes, const PixelModuleData *moduleData, CLHEP::HepRandomEngine *rndmEngine)
virtual Identifier identify() const override final
identifier of this detector element (inline)
void thermalNoise(double thermalNoise, SiChargedDiodeCollection &chargedDiodes, CLHEP::HepRandomEngine *rndmEngine)
virtual Identifier identify() const override final