diart
diart copied to clipboard
Switch to a faster library for dynamic resampling
Looks like torchaudio.Resample is not very fast compared to other libraries implementing resampling in python.
See https://github.com/jonashaag/audio-resampling-in-python
Looks like we could switch to soxr and get a 10x speed increase.
hi Juan. I found a cheap way to avoid resampling if you're using pipewire is to force the rate with
pw-metadata -n settings 0 clock.force-rate 16000
that's for microphone reording.
There's also an aubio library which provides resampling. It provides a python module
https://aubio.org/doc/latest/synth_2test-sampler_8c-example.html