NuRadioReco.modules.RNO_G.triggerBoardResponse module
- class NuRadioReco.modules.RNO_G.triggerBoardResponse.triggerBoardResponse(log_level=30)[source]
Bases:
object
Simulates the response of the trigger board, nominally the “flower board” Includes: * analog frequency filter * ADC gain to fix the noise RMS to a specified number of bits * (optional) applies digitization to the waveforms
Methods
apply_adc_gain
(station, det, trigger_channels)Calculates and applies the gain adjustment such that the correct number of "noise bits" are realized.
apply_trigger_filter
(station, ...)Applies the requested trigger filter to the trigger_channels
begin
([clock_offset, adc_output])digitize_trace
(station, det, ...)Digitizes the traces of the trigger channels.
get_noise_vrms_per_trigger_channel
(station, ...)Estimates the RMS voltage of the triggering antennas by splitting the waveforms into chunks and taking the median of standard deviation of the chunks.
run
(evt, station, det, trigger_channels[, ...])Applies the additional filters on the trigger board and performs a gain amplification to get the correct number of trigger bits.
end
- begin(clock_offset=0.0, adc_output='voltage')[source]
- Parameters:
- clock_offset: bool
If True, a random clock offset between -1 and 1 clock cycles is added
- adc_output: string
Options:
‘voltage’ to store the ADC output as discretised voltage trace
‘counts’ to store the ADC output in ADC counts
- apply_trigger_filter(station, trigger_channels, trigger_filter)[source]
Applies the requested trigger filter to the trigger_channels
- Parameters:
- stationStation
Station to use
- trigger_channelslist
Channels that this function should be applied to
- trigger_filterfunction
set of interpolations describing the gain and phase of the filter (see function load_amp_response in file /detector/RNO_G/analog_components.py)
- get_noise_vrms_per_trigger_channel(station, trigger_channels, trace_split=20)[source]
Estimates the RMS voltage of the triggering antennas by splitting the waveforms into chunks and taking the median of standard deviation of the chunks.
- Parameters:
- stationStation
Station to use
- trigger_channelslist
Channels that this function should be applied to
- trace_splitint (default: 20)
How many chunks each of the waveforms will be split into before calculating the standard deviation
- Returns:
- vrmslist of floats
RMS voltage of the waveforms
- apply_adc_gain(station, det, trigger_channels, vrms_noise=None)[source]
Calculates and applies the gain adjustment such that the correct number of “noise bits” are realized. The ADC has fixed possible gain values and this module sets the one that is closest-to-but-greater-than the ideal value
- Parameters:
- stationStation
Station to use
- detDetector
The detector description
- trigger_channelslist
Channels that this function should be applied to
- vrms_noisefloat (default: None)
The (noise) Vrms of the trigger channels including the trigger board filters If set to None, this will be estimated using the waveforms.
- Returns:
- vrms_after_gainfloat
the RMS voltage of the waveforms after the gain has been applied
- ideal_vrms: float
the ideal vrms, as measured on the ADC capacitors
- digitize_trace(station, det, trigger_channels, vrms)[source]
Digitizes the traces of the trigger channels.
This function uses the
NuRadioReco.modules.analogToDigitalConverter
module to digitize the traces. The resulting digitized traces are either in discrete voltage values or in ADC counts (depeding on the argument adc_output).- Parameters:
- stationStation
Station to use
- detDetector
The detector description
- trigger_channelslist
Channels that this function should be applied to
- vrmsfloat
The (noise) RMS voltage of the trigger channels including the trigger board filters. This can be used to simulate a dynamic range of the ADC which depends on the noise level.
- run(evt, station, det, trigger_channels, vrms=None, apply_adc_gain=True, digitize_trace=True)[source]
Applies the additional filters on the trigger board and performs a gain amplification to get the correct number of trigger bits.
- Parameters:
- evtEvent
Event to run the module on
- stationStation
Station to run the module on
- detDetector
The detector description
- trigger_channelslist
Channels that this module should consider applying the filter/board response
- vrmsfloat (default: None)
The Vrms of the trigger channels including the trigger board filters If set to None, this will be estimated using the waveforms
- apply_adc_gainbool (default: True)
Apply the gain shift to achieve the specified level of noise bits
- digitize_tracebool (default: True)
Apply the quantization to the voltages (uses
NuRadioReco.modules.analogToDigitalConverter
to do so)
- Returns:
- trigger_board_vrmsfloat
the RMS voltage of the waveforms on the trigger board after applying the ADC gain