SIGN IN SIGN UP

[Whisper] Fix batch decode_with_timestamps in WhisperTokenizer.decode() (#47997)

[Whisper] Fix batch decode_with_timestamps handling in WhisperTokenizer.decode()

PR #40936 (05c0e1d390) made batch_decode delegate to decode() natively,
passing a 2D list of token ids. The decode_with_timestamps branch was not
updated to handle batched input, causing TypeError when >= compared a list
to an int. Add the same isinstance check already present in the else branch.

Fixes test_whisper_longform_single_batch (first failing in CI on 2025-11-28,
introduced by PR #40936 on 2025-11-27).

Co-authored-by: ydshieh <ydshieh@users.noreply.github.com>
Y
Yih-Dar committed
64b6595f0cad3d9ec64e541749cf51eee1e72b73
Parent: 16cbed7
Committed by GitHub <noreply@github.com> on 8/16/2026, 4:24:28 PM