spectrograph_flat
- jwst.flatfield.flat_field.spectrograph_flat(wl, s_flat_model, xstart, xstop, ystart, ystop, exposure_type, dispaxis, slit_name)[source]
Extract the flat for the spectrograph part.
- Parameters:
- wlndarray
Wavelength at each pixel of the 2-D slit array.
- s_flat_model
NirspecFlatModelor None Flat field for the spectrograph.
- xstart, xstop, ystart, ystopint
Starting and end pixel numbers (zero indexed) for the slice containing the data for the current slit. The start and stop values are Python slice notation, i.e., the region to be extracted is
[ystart:ystop, xstart:xstop].- exposure_typestr
The exposure type refers to fixed slit, IFU, or using the micro-shutter array.
- dispaxisint
1 means horizontal dispersion, 2 means vertical dispersion.
- slit_namestr or None
The name of the slit currently being processed.
- Returns:
- s_flatndarray of float32
The computed flat field for the spectrograph.
- s_flat_dqndarray of uint32 or None
The associated data quality array.
- s_flat_errndarray of float32 or None
The associated error array.