cupyx.scipy.signal.check_NOLA(window, nperseg, noverlap, tol=1e-10)[source]#

Check whether the Nonzero Overlap Add (NOLA) constraint is met.

  • window (str or tuple or array_like) – Desired window to use. If window is a string or tuple, it is passed to get_window to generate the window values, which are DFT-even by default. See get_window for a list of windows and required parameters. If window is array_like it will be used directly as the window and its length must be nperseg.

  • nperseg (int) – Length of each segment.

  • noverlap (int) – Number of points to overlap between segments.

  • tol (float, optional) – The allowed variance of a bin’s weighted sum from the median bin sum.


verdictTrue if chosen combination satisfies the NOLA constraint within tol, False otherwise

Return type:


See also


Check whether the Constant OverLap Add (COLA) constraint is met


Short Time Fourier Transform


Inverse Short Time Fourier Transform


In order to enable inversion of an STFT via the inverse STFT in istft, the signal windowing must obey the constraint of “nonzero overlap add” (NOLA):

\[\sum_{t}w^{2}[n-tH] \ne 0\]

for all \(n\), where \(w\) is the window function, \(t\) is the frame index, and \(H\) is the hop size (\(H\) = nperseg - noverlap).

This ensures that the normalization factors in the denominator of the overlap-add inversion equation are not zero. Only very pathological windows will fail the NOLA constraint.

See [1], [2] for more information.