spectral_unmixing.match_histograms_across_time

spectral_unmixing.match_histograms_across_time(stack, *, reference_t=0)[source]

Match each time point to a reference time point using per-channel histogram matching.

Parameters:
  • stack (array-like) – Input stack in canonical TZCYX order.

  • reference_t (int, optional) – Reference time point used for histogram matching. Default is 0.

Return type:

ndarray

Returns:

np.ndarray – Histogram-matched stack with the same TZCYX shape as the input.

Notes

Matching is performed independently for each channel. If Z > 1, the full ZYX volume of each time point is matched to the corresponding reference volume of the same channel.