mirror of
https://github.com/openai/whisper.git
synced 2026-02-06 11:18:13 +00:00
Bugfix: Illogical "Avoid computing higher temperatures on no_speech" (#1903)
* Bugfix: Illogical "Avoid computing higher temperatures on no_speech" Bugfix for https://github.com/openai/whisper/pull/1279 It's "silence" when decoding has failed due to `compression_ratio_threshold` too, when further down the code it's not "silence" anymore. "Silence" should be only when decoding has failed due to `logprob_threshold`. Like described there:8bc8860694/whisper/transcribe.py (L421)And in code there:8bc8860694/whisper/transcribe.py (L243-L251)* Fix if "logprob_threshold=None" --------- Co-authored-by: Jong Wook Kim <jongwook@openai.com>
This commit is contained in:
parent
fc5ded7d90
commit
90db0de189
@ -214,6 +214,8 @@ def transcribe(
|
||||
if (
|
||||
no_speech_threshold is not None
|
||||
and decode_result.no_speech_prob > no_speech_threshold
|
||||
and logprob_threshold is not None
|
||||
and decode_result.avg_logprob < logprob_threshold
|
||||
):
|
||||
needs_fallback = False # silence
|
||||
if not needs_fallback:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user