calculate_noise_parameters

lstchain.image.modifier.calculate_noise_parameters(simtel_filename, data_dl1_filename, config_filename=None)

Calculates the parameters needed to increase the noise in an MC DL1 file to match the noise in a real data DL1 file, using add_noise_in_pixels The returned parameters are those needed by the function add_noise_in_pixels (see description in its documentation above).

Parameters:
simtel_filename: `str`

a simtel file containing showers, from the same production (same NSB and telescope settings) as the MC DL1 file below. It must contain pixel-wise info on true number of p.e.’s from C-photons ( will be used to identify pixels which only contain noise).

data_dl1_filename: `str`

a real data DL1 file (processed with calibration settings corresponding to those with which the MC is to be processed). It must contain calibrated images, i.e. “DL1a” data. This file has the “target” noise which we want to have in the MC files, for better agreement of data and simulations.

config_filename: `str`

configuration file containing the calibration settings used for processing both the data and the MC files above

Returns:
extra_noise_in_dim_pixels: float

Extra noise of dim pixels (number of NSB photoelectrons).

extra_bias_in_dim_pixels: float

Extra bias of dim pixels (direct shift in photoelectrons).

extra_noise_in_bright_pixels: float

Extra noise of bright pixels (number of NSB photoelectrons).