Skip to content
This repository has been archived by the owner on May 3, 2024. It is now read-only.

Commit

Permalink
move noise RMS to hgcroc emulator conditions tables
Browse files Browse the repository at this point in the history
  • Loading branch information
tomeichlersmith committed Nov 7, 2022
1 parent 26c45dc commit 9813e96
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 11 deletions.
3 changes: 0 additions & 3 deletions include/Ecal/EcalDigiProducer.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,9 +98,6 @@ class EcalDigiProducer : public framework::Producer {
*/
bool zero_suppression_;

/// Store Average Noise RMS for no-zero-suppresion noise emulation mode
double avgNoiseRMS_;

///////////////////////////////////////////////////////////////////////////////////////
// Other member variables

Expand Down
6 changes: 1 addition & 5 deletions python/digi.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,6 @@ def EcalHgcrocEmulator() :
to a test readout of an ECal module and then thresholds to the
default construction using 37k electrons as the number of
electrons per MIP.
Noise RMS is calculated using the average readout pad capacitance (20pF),
noise at zero capacitance (700 electrons), and noise increase
per capacitance increase (25 electrons per pF).
"""

from LDMX.Tools import HgcrocEmulator
Expand All @@ -42,7 +38,6 @@ def EcalHgcrocEmulator() :
hgcroc.timeDnSlope = 87.7649
hgcroc.timePeak = 77.732

hgcroc.noiseRMS = (700. + 25.*20.)*(0.1602/1000.)*(1./20.) #mV
hgcroc.nADCs = 10
hgcroc.iSOI = 2

Expand Down Expand Up @@ -92,6 +87,7 @@ def __init__(self, instance_name = 'ecalDigis', si_thickness = 0.3) :
avgGain = 0.3125/20.
self.avgReadoutThreshold = 53.*avgGain
self.avgPedestal = 50.*avgGain
self.avgNoiseRMS = 2.0*avgGain

# Should we suppress noise "hits" below readout threshold?
self.zero_suppression = True
Expand Down
2 changes: 2 additions & 0 deletions python/ecal_hardcoded_conditions.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

EcalHgcrocConditionsHardcode=SimpleCSVDoubleTableProvider("EcalHgcrocConditions", [
"PEDESTAL",
"NOISE",
"MEAS_TIME",
"PAD_CAPACITANCE",
"TOT_MAX",
Expand All @@ -42,6 +43,7 @@

EcalHgcrocConditionsHardcode.validForAllRows([
50. , #PEDESTAL
2.0, #NOISE
0.0, #MEAS_TIME - ns
20., #PAD_CAPACITANCE - pF
200., #TOT_MAX - ns - maximum time chip would be in TOT mode
Expand Down
5 changes: 2 additions & 3 deletions src/Ecal/EcalDigiProducer.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -52,10 +52,9 @@ void EcalDigiProducer::configure(framework::config::Parameters& ps) {
// Configure generator that will produce noise hits in empty channels
double readoutThreshold = ps.getParameter<double>("avgReadoutThreshold");
double pedestal = ps.getParameter<double>("avgPedestal");
// saved because it might be used later
avgNoiseRMS_ = hgcrocParams.getParameter<double>("noiseRMS");
double noiseRMS = ps.getParameter<double>("avgNoiseRMS");
// rms noise in mV
noiseGenerator_->setNoise(avgNoiseRMS_);
noiseGenerator_->setNoise(noiseRMS);
// mean noise amplitude (if using Gaussian Model for the noise) in mV
noiseGenerator_->setPedestal(pedestal);
// threshold for readout in mV
Expand Down

0 comments on commit 9813e96

Please sign in to comment.