scipy.signal.stft (and istft)
See original GitHub issueSTFT plays a vital role in audio/ speech signal processing, and it would be nice to have jax-version of scipy.signal.stft
function.
As Jax already has auto-differentiable FFT and conv1d, it can be basically a utility function that combines those two.
It would be nice if we can have SciPy-compatible STFT function in Jax.
Issue Analytics
- State:
- Created 2 years ago
- Comments:12 (7 by maintainers)
Top Results From Across the Web
scipy.signal.istft — SciPy v1.9.3 Manual
This function implements the iSTFT via the least-squares estimation algorithm detailed in [2], which produces a signal that minimizes the mean squared error ......
Read more >Invertible STFT and ISTFT in Python - scipy - Stack Overflow
For this example, I use a naive overlap-and-add method in istft . In order to reconstruct the original signal the sum of the...
Read more >SciPy Signal STFT - Seminar 02 Support Material - YouTube
Spectrograms Basics - SciPy Signal STFT - Seminar 02 Support Material - Multirate Signal Processing SeminarsGitHub: ...
Read more >librosa.core.istft
a window specification (string, tuple, or number); see scipy.signal. ... D = librosa.stft(y) >>> y_hat = librosa.istft(D) >>> y_hat array([ -4.812e-06, ...
Read more >jax.scipy.signal.istft - JAX documentation - Read the Docs
LAX-backend implementation of scipy.signal._spectral_py.istft() . Original docstring below. Parameters. Zxx (array_like) – STFT of the signal to be ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Hi @machineko, and @hawkinsp,
I think having the extra outputs in “scipy.stft” is not significan because JIT can effectively omit computation of those if we just didn’t use those outputs. And, “reflect”-paddings in librosa are implemented in scipy.stft too when boundary=“even” is provided.
So, overall, I prefer strictly maintaining scipy.stft interface if we are to put the code in Jax repo. Here’s a proposal PR. https://github.com/google/jax/pull/9422
Any feedbacks are welcome!
If JAX functions are named like
jax.scipy.XYZ
they should try to mimic thescipy
API. If they diverge, then that’s fine, but they should be called something else. What changes did you have in mind?