Encoder input
: log-mel spectrogram
[1,80,3000]
— 30 s at 16 kHz, 80 mel bins,
hop 160, window 400. This is exactly what
WhisperFeatureExtractor
produces; pad
or trim audio to 30 s as it does.
Decoder input
: the encoder output plus
decoder_input_ids [1,128]
int64,
left-aligned and padded. Start the sequence with
<|startoftranscript|>
, a language token,
<|transcribe|>
,
<|notimestamps|>
.
Decoder output
:
logits [1,128,51865]
Decoding
There is no KV cache. The decoder is a static graph over a fixed 128-token window,
so a greedy step is: take
argmax
of row
len-1
, append it, run again. Stop at
<|endoftext|>
(50257). 128 tokens covers a 30-second window of ordinary speech
with room to spare; for longer audio, start a new window.
That costs a full 128-position forward pass per token. On a 37M-parameter model
this is cheap enough to be practical, and it keeps the graph static — which is what
lets the same file run unchanged across runtimes and precisions.
The two wrappers compose back to
WhisperForConditionalGeneration
exactly
(max_abs_diff 0.000e+00), and every graph matches torch fp32 eager at the
correlations in the table above.
Median over 5 runs, Mac arm64 single process — a relative reference, not a device
number: encoder 54.5 ms (torch eager 20.5 ms), decoder 18.1 ms (eager 12.1 ms).
Two things worth knowing about the sizes
The decoder .pte is larger than the decoder's weights.
Its parameters come to
118 MB, and the file is 198 MB. Whisper ties
proj_out.weight
to
decoder.embed_tokens.weight
— one 19.9M-parameter tensor — but the two uses need
different representations in the
.pte
: an embedding table the portable kernels
index into, and the same values packed into the XNNPACK delegate's blob for the
output matmul. Tying them in PyTorch does not tie them here, and referencing the
embedding weight directly through
F.linear
does not either.
The decoder has no int8 build.
PT2E puts an observer on the int64
decoder_input_ids
feeding the token embedding, and the lookup then refuses a float
index (
tensors used as indices must be long, int, byte or bool
). The encoder takes
float mel input and quantizes without complaint, which is where the size is worth
taking anyway.
The ExecuTorch tree ships a single-graph Whisper example under
examples/models/whisper
. This is that model with the halves separated, because a
combined graph re-encodes the audio on every decoded token.
Runs of mlboydaisuke Whisper-tiny-ExecuTorch on huggingface.co
126
Total runs
23
24-hour runs
32
3-day runs
43
7-day runs
-180
30-day runs
More Information About Whisper-tiny-ExecuTorch huggingface.co Model
Whisper-tiny-ExecuTorch huggingface.co is an AI model on huggingface.co that provides Whisper-tiny-ExecuTorch's model effect (), which can be used instantly with this mlboydaisuke Whisper-tiny-ExecuTorch model. huggingface.co supports a free trial of the Whisper-tiny-ExecuTorch model, and also provides paid use of the Whisper-tiny-ExecuTorch. Support call Whisper-tiny-ExecuTorch model through api, including Node.js, Python, http.
Whisper-tiny-ExecuTorch huggingface.co is an online trial and call api platform, which integrates Whisper-tiny-ExecuTorch's modeling effects, including api services, and provides a free online trial of Whisper-tiny-ExecuTorch, you can try Whisper-tiny-ExecuTorch online for free by clicking the link below.
mlboydaisuke Whisper-tiny-ExecuTorch online free url in huggingface.co:
Whisper-tiny-ExecuTorch is an open source model from GitHub that offers a free installation service, and any user can find Whisper-tiny-ExecuTorch on GitHub to install. At the same time, huggingface.co provides the effect of Whisper-tiny-ExecuTorch install, users can directly use Whisper-tiny-ExecuTorch installed effect in huggingface.co for debugging and trial. It also supports api for free installation.
Whisper-tiny-ExecuTorch install url in huggingface.co: