stft
Compute a short-time Fourier transform from a signal and sample rate to return a magnitude spectrogram, saving the matrix or rendering a PNG when needed.
Instructions
Compute a short-time Fourier transform and return the magnitude spectrogram.
The full magnitude matrix is saved as .npz when it exceeds 100 x 100 cells.
``save_spectrogram`` additionally renders a PNG with matplotlib (Agg).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| signal | Yes | ||
| window | No | hann | |
| nperseg | No | ||
| filename | No | ||
| noverlap | No | ||
| sample_rate | Yes | ||
| save_spectrogram | No |