istft#
- ShortTimeFFT.istft(S, k0=0, k1=None, *, f_axis=-2, t_axis=-1)[source]#
Inverse short-time Fourier transform.
- Parameters:
- Sndarray
A complex valued array where f_axis denotes the frequency values and the t_axis dimension the temporal values of the STFT values.
- k0, k1int, optional
The start and the end index of the reconstructed signal. The default (
k0 = 0,k1 = None) assumes that the maximum length signal should be reconstructed.- f_axis, t_axisint, optional
The axes in S denoting the frequency and the time dimension.
- Returns:
- ndarray
Array of dimension
S.ndim - 1which is real ifonesided_fftis set, else complex.
- Raises:
- ValueError
If the STFT is not invertible, or the parameters are out of bounds.
See also
invertibleCheck if STFT is invertible.
stftPerform Short-time Fourier transform.
scipy.signal.ShortTimeFFTClass this method belongs to.
Notes
It is required that S has
f_ptsentries along the f_axis. For the t_axis it is assumed that the first entry corresponds top_min*delta_t(being <= 0). The length of t_axis needs to be compatible with k1. I.e.,S.shape[t_axis] >= self.p_max(k1)must hold, if k1 is notNone. Else k1 is set tok_maxwith:q_max = S.shape[t_range] + self.p_min k_max = (q_max - 1) * self.hop + self.m_num - self.m_num_mid
The Short-Time Fourier Transform section of the SciPy User Guide discussed the slicing behavior by means of an example.