NuRadioReco.modules.channelGalacticNoiseAdder module

class NuRadioReco.modules.channelGalacticNoiseAdder.channelGalacticNoiseAdder[source]

Bases: object

Class that simulates the noise produced by galactic radio emission

Uses the pydgsm package (https://github.com/telegraphic/pygdsm), which provides radio background data based on Oliveira-Costa et al. (2008) (https://arxiv.org/abs/0802.1525) and Zheng et al. (2016) (https://arxiv.org/abs/1605.04920)

The radio sky model is evaluated on a number of points above the horizon folded with the antenna response. Since evaluating every frequency individually would be too slow, the model is evaluated for a few frequencies and the log10 of the brightness temperature is interpolated in between.

Methods

begin([skymodel, debug, n_side, freq_range, ...])

Set up important parameters for the module

run(event, station, detector[, passband])

Adds noise resulting from galactic radio emission to the channel traces

begin(skymodel=None, debug=False, n_side=4, freq_range=None, interpolation_frequencies=None, seed=None, caching=True)[source]

Set up important parameters for the module

Parameters:
skymodel: {‘gsm2008’, ‘lfmap’, ‘lfss’, ‘gsm2016’, ‘haslam’}, optional

Choose the sky model to use. If none is provided, the Global Sky Model (2008) is used as a default.

debug: bool, default: False

Deprecated. Will be removed in future versions.

n_side: int, default: 4

The n_side parameter of the healpix map. Has to be power of 2 The radio skymap is downsized to the resolution specified by the n_side parameter and for every pixel above the horizon the radio noise coming from that direction is calculated. The number of pixels used is 12 * n_side ** 2, so a larger value for n_side will result better accuracy but also greatly increase computing time.

freq_range: array of len=2, default: [10, 1000] * units.MHZ

The sky brightness temperature will be evaluated for the frequencies within this limit. Brightness temperature for frequencies in between are calculated by interpolation the log10 of the temperature The interpolation_frequencies have to cover the entire passband specified in the run method.

interpolation_frequencies: array of frequencies to interpolate to.

Kept for historic purposes with intention to deprecate in the future.

seed{None, int, array_like[ints], SeedSequence}, optional

The seed that is passed on to the numpy.random.Philox bitgenerator used for random number generation.

caching: bool, default: True

If True, the antenna response is cached for each channel. This can speed up this module by a lot. If the frequencies of the channels change, the cache is cleared.

run(event, station, detector, passband=None)[source]

Adds noise resulting from galactic radio emission to the channel traces

Parameters:
event: Event object

The event containing the station to whose channels noise shall be added

station: Station object

The station whose channels noise shall be added to

detector: Detector object

The detector description

passband: list of float, optional

Lower and upper bound of the frequency range in which noise shall be added. The default (no passband specified) is [10, 1000] MHz

NuRadioReco.modules.channelGalacticNoiseAdder.get_local_coordinates(coordinates, time, n_side)[source]

Calculates the local coordinates of the pixels of a healpix map given the site coordinates and time.

Parameters:
coordinates: tuple of float

The latitude and longitude of the site

time: astropy.time.Time

The time at which the observation is made (station time)

n_side: int

The n_side parameter of the healpix map

Returns:
local_coordinates: astropy.coordinates.SkyCoord

The local coordinates of the pixels of the healpix map