Fixed Pattern Noise¶
This section describes how HDRL identifies regular noise on detector data. A classical example is provided by the pick noise, i.e. low-amplitude, quasi-periodical patterns super-imposed on the normal read-noise. It is due to electronic interference and might show up or disappear on short timescales (days or hours).
Those artifacts are visible only on the detector data but of course exist also on other calibration data and on science data where they may compromise the detector sensitivity.
In PyHDRL this is the module-level function
hdrl.func.fpn_compute. There is no Fpn class.
Algorithm¶
The algorithm implements three steps:
Derive the power spectrum of the image using the Fast Fourier Transform (FFT):
power_spec = abs(FFT_2D(img))^2Mask the peak of the power spectrum that corresponds to the pixel-to-pixel variations. By default only one pixel placed in the corner on the bottom left is masked (the DC component), but more pixels can be masked providing an optional bad pixel mask.
Calculate the standard deviation
stdand the standard deviation based on the Median Absolute Deviation (MAD)std_madof the power spectrum by taking the masked regions into account:std_mad = mad(power_spec_filter) * 1.4826
The power spectrum contains the DC component in pixel (1,1). The mask
created on the fly by setting dc_mask_x and dc_mask_y and the
optional mask are combined. The final mask used to derive std and
std_mad is attached to the power_spectrum image as a normal
CPL mask (power_spectrum.bpm).
fpn_compute() takes a cpl.core.Image. The optional mask is
a cpl.core.Mask, or None (the default) if unused. The input
image must not contain bad pixels. dc_mask_x and dc_mask_y
must be ≥ 1.
It returns a hdrl.func.FpnResult. power_spectrum is a
cpl.core.Image.
result = hdrl.func.fpn_compute(image)
power_spectrum = result.power_spectrum
std = result.std
std_mad = result.std_mad