I am trying to convert mp3 to wav foramt in python. I have searched and found this code
from os import path
from pydub import AudioSegment
# files
src = "transcript.mp3"
dst = "test.wav"
# convert wav to mp3
sound = AudioSegment.from_mp3(src)
sound.export(dst, format="wav")
I have installed pydub
package using this line in the anaconda3 pip install pydub
. I also installed ffmpeg for windows and I made sure it works by typing ffmpeg -version
in the command prompt.
Although I got the following error