wave

sofia_redux.instruments.fifi_ls.lambda_calibrate.wave(ind, date, dichroic, blue=None, wavecal=None)[source]

Calculate wavelengths for each spectral pixel.

Requires FIFI_LS_WaveCal_Coeffs.txt file, in fifi_ls/data/wave_cal/, as provided by FIFI-LS team.

The procedure is:

  1. Read wavelength calibration file. This file is stored in a text table format, provided by the FIFI-LS instrument team. The FIFI-LS team also provides the wavelength equation.

  2. Loop over spaxels, calculating the wavelength and spectral width for each spexel, from the parameters specified in the calibration file.

  3. Return an array of wavelengths.

Parameters:
indint

Inductosyn position

datearray_like of int

[Y, M, D] vector

dichroicint

Dichroic value (105 or 130)

bluestr, optional

Either ‘B1’ to indicate first BLUE order of ‘B2’ to indicate second BLUE order. If not provided, data is assumed to be RED channel

wavecalpd.DataFrame, optional

DataFrame containing wave calibration data. May be supplied in order to remove the overhead of reading the file every iteration of this function.

Returns:
dict
Contains:
  • ‘wavelength’ (numpy.ndarray): a 2-D array (16, 25) containing the wavelength of each pixel for each module in microns.

  • ‘width’ (numpy.ndarray): a 2-D array (16, 25) containing the spectral width of each pixel for each spatial module in microns

  • ‘calfile’ (str): the name of the wavelength calibration file used