Recover background audio with librosa and saving it with soundfile

2 · Vicente G. Reyes · Feb. 20, 2023, 11:40 p.m.
In my previous article I separated the vocals from the instruments but didn't save it. This article is aimed towards saving the audio from IPython.Audio in IPython. The full spectrum, foreground spectrum and background spectrum from my previous article looked like this: The other goal I tied myself to was to play the audio from the instruments only which I'll also show in this article. To save the audio, we use soundfile's write() function and get the audio data, sample rate and save it as .wav...