facebookresearch / denoiser

Real Time Speech Enhancement in the Waveform Domain (Interspeech 2020)We provide a PyTorch implementation of the paper Real Time Speech Enhancement in the Waveform Domain. In which, we present a causal speech enhancement model working on the raw waveform that runs in real-time on a laptop CPU. The proposed model is based on an encoder-decoder architecture with skip-connections. It is optimized on both time and frequency domains, using multiple loss functions. Empirical evidence shows that it is capable of removing various kinds of background noise including stationary and non-stationary noises, as well as room reverb. Additionally, we suggest a set of data augmentation techniques applied directly on the raw waveform which further improve model performance and its generalization abilities.
Other
1.62k stars 299 forks source link

Processing bytes instead of numpy array (Using PyAudio) #132

Open qalabeabbas49 opened 1 year ago

qalabeabbas49 commented 1 year ago

Hi, I am working on a project where I have audio data as bytes stream (from PyAudio). I want to use the denoiser to clean the audio in real-time (using live.py).

My question is it possible to process the bytes instead of the NumPy array? If so, what should be my approach, and which parameters do I need to change?

Any leads are much appreciated.

Thanks

adiyoss commented 1 year ago

At the moment the model gets as input a numpy array representing the raw-waveform. If you want to use bytes instead, the easiest way imo would be to convert it to numpy.