|
 |
|
| HGCHEbackDigitizer (const edm::ParameterSet &ps) |
|
void | runDigitizer (std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine) override |
|
| ~HGCHEbackDigitizer () override |
|
DetId::Detector | det () const |
|
void | GenerateGaussianNoise (CLHEP::HepRandomEngine *engine, const double NoiseMean, const double NoiseStd) |
| Gaussian Noise Generation Member Function. More...
|
|
| HGCDigitizerBase (const edm::ParameterSet &ps) |
| CTOR. More...
|
|
float | keV2fC () const |
| getters More...
|
|
void | run (std::unique_ptr< DColl > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, uint32_t digitizationType, CLHEP::HepRandomEngine *engine) |
| steer digitization mode More...
|
|
virtual void | runDigitizer (std::unique_ptr< DColl > &coll, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine)=0 |
| to be specialized by top class More...
|
|
void | runSimple (std::unique_ptr< DColl > &coll, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine) |
| a trivial digitization: sum energies and digitize More...
|
|
ForwardSubdetector | subdet () const |
|
std::array< float, 3 > | tdcForToAOnset () const |
|
float | tdcOnset () const |
|
bool | toaModeByEnergy () const |
|
void | updateOutput (std::unique_ptr< DColl > &coll, const DFr &rawDataFrame) |
| prepares the output according to the number of time samples to produce More...
|
|
virtual | ~HGCDigitizerBase () |
| DTOR. More...
|
|
|
void | runCaliceLikeDigitizer (std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine) |
|
void | runEmptyDigitizer (std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine) |
|
void | runRealisticDigitizer (std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine) |
|
Definition at line 15 of file HGCHEbackDigitizer.cc.
◆ HGCHEbackDigitizer()
Definition at line 53 of file HGCHEbackDigitizer.cc.
55 algo_ =
cfg.getParameter<uint32_t>(
"algo");
70 xTalk_ =
cfg.getParameter<
double>(
"xTalk");
References algo_, looper::cfg, HGCDigitizerBase::det_, doseMapFile_, edm::ParameterSet::getParameter(), DetId::HGCalHSc, HGCDigitizerBase::keV2fC_, keV2MIP_, noise_MIP_, nPEperMIP_, nTotalPE_, scal_, scaleByDose_, hgcalDigitizer_cfi::scaleByDoseAlgo, HGCDigitizerBase::scaleByDoseFactor_, scaleBySipmArea_, scaleByTileArea_, sdPixels_, HGCalRadiationMap::setDoseMap(), HGCalRadiationMap::setFluenceScaleFactor(), HGCalSciNoiseMap::setSipmMap(), sipmMapFile_, AlCaHLTBitMon_QueryRunRegistry::string, thresholdFollowsMIP_, and xTalk_.
◆ ~HGCHEbackDigitizer()
HGCHEbackDigitizer::~HGCHEbackDigitizer |
( |
| ) |
|
|
override |
◆ runCaliceLikeDigitizer()
Definition at line 241 of file HGCHEbackDigitizer.cc.
247 constexpr
bool debug(
false);
256 for (
const auto&
id : validIds) {
257 chargeColl.fill(0.
f);
258 HGCSimHitDataAccumulator::iterator it = simData.find(
id);
259 HGCCellInfo& cell = (simData.end() == it ? zeroData : it->second);
262 for (
size_t i = 0;
i < cell.
hit_info[0].size(); ++
i) {
267 const uint32_t npe = std::floor(CLHEP::RandPoissonQ::shoot(engine, totalIniMIPs *
nPEperMIP_));
277 nPixel = (uint32_t)
std::max(CLHEP::RandGaussQ::shoot(engine, (
double)nPixel,
sdPixels_), 0.);
280 float totalMIPs(0.
f), xtalk = 0.f;
289 chargeColl[
i] = totalMIPs;
294 <<
" keV -> " << totalIniMIPs <<
" raw-MIPs -> " << chargeColl[
i]
References hgc_digi_utils::addCellMetadata(), debug, f, myMath::fast_expf(), myMath::fast_logf(), dqmMemoryStats::float, hgc_digi::HGCCellInfo::hit_info, mps_fire::i, keV2MIP_, SiStripPI::max, HGCDigitizerBase::myFEelectronics_, noise_MIP_, nPEperMIP_, nTotalPE_, sdPixels_, HGCDigitizerBase::updateOutput(), x, and xTalk_.
Referenced by runDigitizer().
◆ runDigitizer()
◆ runEmptyDigitizer()
◆ runRealisticDigitizer()
Definition at line 127 of file HGCHEbackDigitizer.cc.
133 constexpr
bool debug(
false);
144 for (
const auto&
id : validIds) {
145 chargeColl.fill(0.
f);
147 HGCSimHitDataAccumulator::iterator it = simData.find(
id);
148 HGCCellInfo& cell = (simData.end() == it ? zeroData : it->second);
153 float sipmFactor = 1.;
168 scaledPePerMip *= dosePair.first;
169 tunedNoise = dosePair.second;
175 scaledPePerMip *= sipmFactor;
176 tunedNoise *=
sqrt(sipmFactor);
181 float meanN =
std::pow(tunedNoise, 2);
183 for (
size_t i = 0;
i < cell.
hit_info[0].size(); ++
i) {
188 const uint32_t npeS = std::floor(CLHEP::RandPoissonQ::shoot(engine, totalIniMIPs * scaledPePerMip) + 0.5);
191 const uint32_t npeN = std::floor(CLHEP::RandPoissonQ::shoot(engine, meanN) + 0.5);
194 const uint32_t npe = npeS + npeN;
197 float nTotalPixels =
nTotalPE_ * sipmFactor;
209 if (
debug && totalIniMIPs > 0) {
210 LogDebug(
"HGCHEbackDigitizer") <<
"npeS: " << npeS <<
" npeN: " << npeN <<
" npe: " << npe
211 <<
" meanN: " << meanN <<
" noise_MIP_: " <<
noise_MIP_
212 <<
" nPEperMIP_: " <<
nPEperMIP_ <<
" scaledPePerMip: " << scaledPePerMip
213 <<
" nPixel: " << nPixel;
214 LogDebug(
"HGCHEbackDigitizer") <<
"totalIniMIPs: " << totalIniMIPs <<
" totalMIPs: " << totalMIPs << std::endl;
218 chargeColl[
i] = totalMIPs;
231 : std::floor(adcThr / adcLsb));
233 this->
myFEelectronics_->runShaper(newDataFrame, chargeColl, toa, engine, thrADC);
References hgc_digi_utils::addCellMetadata(), HGCalRadiationMap::computeRadius(), debug, HGCDigitizerBase::det(), f, myMath::fast_expf(), DetId::HGCalHSc, hgc_digi::HGCCellInfo::hit_info, mps_fire::i, keV2MIP_, LogDebug, SiStripPI::max, HGCDigitizerBase::myFEelectronics_, noise_MIP_, nPEperMIP_, nTotalPE_, or, funct::pow(), CosmicsPD_Skims::radius, scal_, HGCalSciNoiseMap::scaleByDose(), scaleByDose_, HGCalSciNoiseMap::scaleBySipmArea(), scaleBySipmArea_, HGCalSciNoiseMap::scaleByTileArea(), scaleByTileArea_, HGCalRadiationMap::setGeometry(), mathSSE::sqrt(), thresholdFollowsMIP_, HGCDigitizerBase::updateOutput(), x, and xTalk_.
Referenced by runDigitizer().
◆ algo_
uint32_t HGCHEbackDigitizer::algo_ |
|
private |
◆ doseMapFile_
std::string HGCHEbackDigitizer::doseMapFile_ |
|
private |
◆ keV2MIP_
float HGCHEbackDigitizer::keV2MIP_ |
|
private |
◆ noise_MIP_
float HGCHEbackDigitizer::noise_MIP_ |
|
private |
◆ nPEperMIP_
float HGCHEbackDigitizer::nPEperMIP_ |
|
private |
◆ nTotalPE_
float HGCHEbackDigitizer::nTotalPE_ |
|
private |
◆ scal_
◆ scaleByDose_
bool HGCHEbackDigitizer::scaleByDose_ |
|
private |
◆ scaleBySipmArea_
bool HGCHEbackDigitizer::scaleBySipmArea_ |
|
private |
◆ scaleByTileArea_
bool HGCHEbackDigitizer::scaleByTileArea_ |
|
private |
◆ sdPixels_
float HGCHEbackDigitizer::sdPixels_ |
|
private |
◆ sipmMapFile_
std::string HGCHEbackDigitizer::sipmMapFile_ |
|
private |
◆ thresholdFollowsMIP_
bool HGCHEbackDigitizer::thresholdFollowsMIP_ |
|
private |
◆ xTalk_
float HGCHEbackDigitizer::xTalk_ |
|
private |
bool thresholdFollowsMIP_
double scaleByDoseFactor_
void runRealisticDigitizer(std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine)
void setGeometry(const CaloSubdetectorGeometry *)
void runCaliceLikeDigitizer(std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine)
double scaleByTileArea(const HGCScintillatorDetId &, const double)
returns the signal scaling and the noise
std::array< HGCSimData_t, nSamples > HGCSimHitData
models the behavior of the front-end electronics
void setSipmMap(const std::string &)
void setDoseMap(const std::string &, const unsigned int)
std::array< HGCSimHitData, 2 > hit_info
void setFluenceScaleFactor(double val)
HGCDigitizerBase(const edm::ParameterSet &ps)
CTOR.
Log< level::Info, true > LogVerbatim
void addCellMetadata(HGCCellInfo &info, const HGCalGeometry *geom, const DetId &detid)
void updateOutput(std::unique_ptr< DColl > &coll, const DFr &rawDataFrame)
prepares the output according to the number of time samples to produce
std::unique_ptr< HGCFEElectronics< DFr > > myFEelectronics_
double computeRadius(const HGCScintillatorDetId &)
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e< void, edm::EventID const &, edm::Timestamp const & > We also list in braces which AR_WATCH_USING_METHOD_ is used for those or
T getParameter(std::string const &) const
Power< A, B >::type pow(const A &a, const B &b)
double scaleBySipmArea(const HGCScintillatorDetId &, const double)
std::pair< double, double > scaleByDose(const HGCScintillatorDetId &, const double)
void runEmptyDigitizer(std::unique_ptr< HGCalDigiCollection > &digiColl, hgc::HGCSimHitDataAccumulator &simData, const CaloSubdetectorGeometry *theGeom, const std::unordered_set< DetId > &validIds, CLHEP::HepRandomEngine *engine)
DetId::Detector det() const