-
Hi, I am new to this, so I used ChatGPT to guide me with the following steps:
If I run whisper: I get nice subs, but the time-stamps are wrong in a way impossible to correct them with SubtitleEdit unless aligning each of the subs one by one. Chat told me to use this python script: import whisper
# Load the Whisper model
model = whisper.load_model("base") # Change "base" to "small", "medium", or "large" if needed
# Transcribe the audio
result = model.transcribe("audio.wav", task="transcribe", word_timestamps=True)
# Save the transcription as an SRT file
with open("output.srt", "w", encoding="utf-8") as f:
f.write(result["srt"]) First it failed with:
Chat me told to edit 'C:\Users\m1\AppData\Local\Programs\Python\Python313\Lib\site-packages\whisper.py' and replace And now I get:
I'm stuck! Any help would be appreciated. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
The simplest way to get an SRT with word timestamps is to use the command line. If you are using the latest whisper, try the turbo model first. For example,
You can see the full range of command line options with
I don't recommend chatGPT as your primary resource to understand whisper. Search these discussion boards first, there are a few years worth of questions and answers across different platforms. |
Beta Was this translation helpful? Give feedback.
The simplest way to get an SRT with word timestamps is to use the command line. If you are using the latest whisper, try the turbo model first. For example,
whisper audio.wav --model turbo --task transcribe --word_timestamps True
whisper audio1.wav audio2.mp3 video3.mp4 --model turbo --task transcribe --word_timestamps True
You can see the full range of command line options with
whisper --help
I don't recommend chatGPT as your primary resource to understand whisper. Search these discussion boards first, there are a few years worth of questions and answers across different platforms.