r/rust • u/wizenink • Oct 26 '25
stft-rs, simple, streaming based STFT computing crate
Hey r/rust, just published an STFT crate based on rustfft. This was a side-rabbithole while implementing some model on Burn, which eventually became a simple library.
Contributions, feedback and criticism welcome!
28
Upvotes
28
u/pokemonplayer2001 Oct 26 '25
Maybe you, like me, did not know was STFT was:
https://en.wikipedia.org/wiki/Short-time_Fourier_transform
2
u/RandallOfLegend Oct 26 '25
I appreciate that your dependencies are minimal.
I may use this in the near future! Nice work.
2
u/words_number Oct 26 '25
Very cool, I like the detailed readme! But I think the current implementation cannot be used for real-time audio processing, because your push_frame and push_samples methods allocate. Or am I missing something? I just scrolled through the code on mobile to look for low hanging optimization potential and noticed that.
2
u/jondo2010 Oct 26 '25
This looks cool. High-quality README appreciated!