get_signal_mask#

mufasa.signals.get_signal_mask(cube, snr_cut=3, minsize=2, expand=20, clean=True, return_rms=False)[source]#

Provide a 3D mask indicating signal regions based on RMS and SNR threshold.

Parameters:
  • cube (SpectralCube) – SpectralCube object.

  • snr_cut (float, optional) – Signal-to-noise threshold to define signals.

  • minsize (int, optional) – Minimum size of connected components in spectral direction.

  • expand (int, optional) – Number of spectral channels to expand signal regions.

  • clean (bool, optional) – Remove spatially isolated pixels.

  • return_rms (bool, optional) – Whether to return RMS along with the signal mask.

Returns:

  • ndarray – Signal mask.

  • Quantity, optional – RMS value if return_rms is True.