tedana.decay.fit_decay

fit_decay(data, tes, mask, masksum, fittype)[source]

Fit voxel-wise monoexponential decay models to data

Parameters:
  • data ((S x E [x T]) array_like) – Multi-echo data array, where S is samples, E is echos, and T is time
  • tes ((E,) list) – Echo times
  • mask ((S,) array_like) – Boolean array indicating samples that are consistently (i.e., across time AND echoes) non-zero
  • masksum ((S,) array_like) – Valued array indicating number of echos that have sufficient signal in given sample
  • fittype ({loglin, curvefit}) – The type of model fit to use
Returns:

  • t2s_limited ((S,) numpy.ndarray) – Limited T2* map. The limited map only keeps the T2* values for data where there are at least two echos with good signal.
  • s0_limited ((S,) numpy.ndarray) – Limited S0 map. The limited map only keeps the S0 values for data where there are at least two echos with good signal.
  • t2ss ((S x E-1) numpy.ndarray) – Voxel-wise T2* estimates using ascending numbers of echoes, starting with 2.
  • s0vs ((S x E-1) numpy.ndarray) – Voxel-wise S0 estimates using ascending numbers of echoes, starting with 2.
  • t2s_full ((S,) numpy.ndarray) – Full T2* map. For voxels affected by dropout, with good signal from only one echo, the full map uses the T2* estimate from the first two echoes.
  • s0_full ((S,) numpy.ndarray) – Full S0 map. For voxels affected by dropout, with good signal from only one echo, the full map uses the S0 estimate from the first two echoes.

Notes

  1. Fit monoexponential decay function to all values for a given voxel across TRs, per TE, to estimate voxel-wise S_0 and T_2^*:

    S(TE) = S_0 * exp(-R_2^* * TE)

T_2^* = 1 / R_2^*

  2. Replace infinite values in T_2^* map with 500 and NaN values in S_0 map with 0.

  3. Generate limited T_2^* and S_0 maps by doing something.