Skip to content

Commit 2d2e3e6

Browse files
DarkLight1337epwalsh
authored andcommitted
[Bugfix] Fix granite speech shape validation (vllm-project#21762)
Signed-off-by: DarkLight1337 <[email protected]>
1 parent 478e6a2 commit 2d2e3e6

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

vllm/model_executor/models/granite_speech.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -64,14 +64,15 @@ class GraniteSpeechAudioInputs(TensorSchema):
6464
6565
Dimensions:
6666
- b: Batch size
67-
- nf: Number of audio features (variable length)
67+
- fi: Number of input features from the Mel spectrogram.
68+
- fo: Number of output features, i.e. the embedding size.
6869
- 160: Fixed feature dimension for Mel spectrogram features
6970
"""
7071

71-
input_features: Annotated[torch.Tensor, TensorShape("b", "nf", 160)]
72+
input_features: Annotated[torch.Tensor, TensorShape("b", "fi", 160)]
7273
"""Audio input features."""
7374

74-
input_features_mask: Annotated[torch.Tensor, TensorShape("b", "nf")]
75+
input_features_mask: Annotated[torch.Tensor, TensorShape("b", "fo")]
7576
"""Mask for variable length audio features."""
7677

7778
audio_embed_sizes: Annotated[list[int], TensorShape("b")]

0 commit comments

Comments
 (0)