signal_to_noise_oir_ccd#

astropy.stats.signal_to_noise_oir_ccd(t, source_eps, sky_eps, dark_eps, rd, npix, gain=1.0)[source]#

Computes the signal to noise ratio for source being observed in the optical/IR using a CCD.

Parameters:
tfloat or numpy.ndarray

CCD integration time in seconds

source_epsfloat

Number of electrons (photons) or DN per second in the aperture from the source. Note that this should already have been scaled by the filter transmission and the quantum efficiency of the CCD. If the input is in DN, then be sure to set the gain to the proper value for the CCD. If the input is in electrons per second, then keep the gain as its default of 1.0.

sky_epsfloat

Number of electrons (photons) or DN per second per pixel from the sky background. Should already be scaled by filter transmission and QE. This must be in the same units as source_eps for the calculation to make sense.

dark_epsfloat

Number of thermal electrons per second per pixel. If this is given in DN or ADU, then multiply by the gain to get the value in electrons.

rdfloat

Read noise of the CCD in electrons. If this is given in DN or ADU, then multiply by the gain to get the value in electrons.

npixfloat

Size of the aperture in pixels

gainfloat, optional

Gain of the CCD. In units of electrons per DN.

Returns:
SNRfloat or numpy.ndarray

Signal to noise ratio calculated from the inputs