I have a problem with Pydub module running in Windows and Linux. When I try open a mp3 file thus:
from pydub import AudioSegment
sound = AudioSegment.from_mp3("test.mp3")
Console show me the next message:
WindowsError: [Error 2] The system can not find the file specified
But...I have the file (test.mp3) in the same folder that the script, the name is correct.
Why I have this problem? (In Linux, have the same error)
test.mp3
has to be in the directory where you run the script from (import os; print(os.getcwd())
to show it), not from the directory where the script is. – Disproof