Closed JamesSatherley closed 10 months ago
It depends from where you run the executable (your are using relative path)
To list files in the current folder (and double check), you can use in python
import os
os.listdir(os.path.curdir)
I get the following output when running that line about the snippet from my screenshot;
['0.mp3', '1.mp3', '2.mp3', 'background.mp4', 'main.py', 'music.mp3', 'text.mp3', 'ttsPlayer.py', 'pycache']
The file is definitely there. I've also tried
audio = "text.mp3"
results = whisper.transcribe(model, audio)
To be 100% you can add before load_audio
assert os.path.isfile("text.mp3")
And note that you can also simply run
whisper_timestamped.transcribe(model, "text.mp3")
Anyway, I suspect the error is probably something else. It's probably not talking about the audio file, but about an installation file missing. Have you followed complete install instruction? In particular, do you have ffmpeg? https://github.com/linto-ai/whisper-timestamped#first-installation
For some reason, my audio file cannot be found;
Despite seeing it exist on the left hand side, it doesn't seem to be able to be found. Thanks