how to get timestamp for each sentence? #1348
Answered
by
phineas-pta
hunter2009pf
asked this question in
Q&A
-
I use whisper to implement autio to text. I get the correct text but without timestamp. How can I modify the codes below so that I can get the timestamp?
|
Beta Was this translation helpful? Give feedback.
Answered by
phineas-pta
May 14, 2023
Replies: 1 comment 4 replies
-
the code from README is a bit over-detailed, if you don't really need low-level controls, you can simply do import whisper
model = whisper.load_model("base")
audio = whisper.load_audio(ASRPage.output_file_path)
result = model.transcribe(audio) you can then get timestamps using |
Beta Was this translation helpful? Give feedback.
4 replies
Answer selected by
hunter2009pf
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
the code from README is a bit over-detailed, if you don't really need low-level controls, you can simply do
you can then get timestamps using
result["segments"]