Skip to content

Commit

Permalink
more return_timestamps=True
Browse files Browse the repository at this point in the history
  • Loading branch information
ylacombe committed Sep 12, 2024
1 parent 1fd3d96 commit a1217e8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tests/models/whisper/test_modeling_whisper.py
Original file line number Diff line number Diff line change
Expand Up @@ -2385,7 +2385,7 @@ def test_tiny_token_timestamp_generation_longform(self):
)

inputs = inputs.to(torch_device)
generate_outputs = model.generate(**inputs, return_segments=True, return_token_timestamps=True)
generate_outputs = model.generate(**inputs, return_segments=True, return_token_timestamps=True, return_timestamps=True)

token_timestamps_shape = [
[segment["token_timestamps"].shape for segment in segment_list]
Expand Down Expand Up @@ -3264,6 +3264,7 @@ def test_whisper_empty_longform(self):
"num_beams": 5,
"language": "fr",
"task": "transcribe",
"return_timestamps": True,
}

torch.manual_seed(0)
Expand Down

0 comments on commit a1217e8

Please sign in to comment.