cwitools.utils.get_nebmask

cwitools.utils.get_nebmask(header, redshift=0, vel_window=500, mode='bmask')

Get mask of nebular emission lines for a specific FITS image and redshift.

Parameters:
  • header (astropy FITS Header) – Header for 3D (z, y, x) or 1D (z) data.
  • z (float) – The redshift of the emission to consider.
  • vel_window (float) – The velocity width of each line, in km/s.
  • use_vacuum (bool) – Set to True to convert to vacuum wavelengths.
  • mode (str) –

    Mode of the return type. ‘bmask’ - return a 1D array where 1 = masked and 0 = unmasked ‘tuples’ - return a list of tuples indicating the (lower, upper)

    wavelength for each line, based on the velocity width.
Returns:

A 1D binary mask. Values of 1 indicate masked wavelengths. OR list of float tuples: (lower, upper) bounds for each emission line.

Return type:

numpy.array