tedana.decay.modify_t2s_s0_maps

modify_t2s_s0_maps(t2s, s0, adaptive_mask, tes)[source]

Modify T2* and S0 maps to include estimates for voxels with adaptive mask == 1.

Parameters:
  • t2s ((Md,) numpy.ndarray) – “Full” T2* map. This includes T2* estimates for all voxels with adaptive mask >= 1.

  • s0 ((Md,) numpy.ndarray) – “Full” S0 map. This includes S0 estimates for all voxels with adaptive mask >= 1.

  • adaptive_mask ((Md,) numpy.ndarray) – Adaptive mask array where each value indicates the number of echoes with good signal for that voxel. This mask may be thresholded; for example, with values less than 3 set to 0. For more information on thresholding, see make_adaptive_mask.

  • tes ((E,) list) – Echo times in milliseconds.

Returns:

  • t2s ((Md,) numpy.ndarray) – “Full” T2* map with floors and ceilings applied. This includes T2* estimates for all voxels with adaptive mask >= 1.

  • s0 ((Md,) numpy.ndarray) – “Full” S0 map with floors and ceilings applied. This includes S0 estimates for all voxels with adaptive mask >= 1.

  • t2s_limited ((Md,) numpy.ndarray) – “Limited” T2* map. This includes T2* estimates for all voxels with adaptive mask > 1. Voxels with adaptive mask == 1 are set to 0.

  • s0_limited ((Md,) numpy.ndarray) – “Limited” S0 map. This includes S0 estimates for all voxels with adaptive mask > 1. Voxels with adaptive mask == 1 are set to 0.

Notes

This function replaces infinite values in the T_2^* map with 500 and T_2^* values less than or equal to zero with 1. Additionally, very small T_2^* values above zero are replaced with a floor value to prevent zero-division errors later on in the workflow. It also replaces NaN values in the S_0 map with 0.