Unverified Commit 68810aa2 authored by Yih-Dar's avatar Yih-Dar Committed by GitHub
Browse files

fix doc example - TypeError: forward() got an unexpected keyword argument 'input_ids' (#15092)


Co-authored-by: default avatarydshieh <ydshieh@users.noreply.github.com>
parent ca76618d
...@@ -1323,7 +1323,7 @@ class Speech2TextForConditionalGeneration(Speech2TextPreTrainedModel): ...@@ -1323,7 +1323,7 @@ class Speech2TextForConditionalGeneration(Speech2TextPreTrainedModel):
>>> input_features = processor( >>> input_features = processor(
... ds["speech"][0], sampling_rate=16000, return_tensors="pt" ... ds["speech"][0], sampling_rate=16000, return_tensors="pt"
>>> ).input_features # Batch size 1 >>> ).input_features # Batch size 1
>>> generated_ids = model.generate(input_ids=input_features) >>> generated_ids = model.generate(inputs=input_features)
>>> transcription = processor.batch_decode(generated_ids) >>> transcription = processor.batch_decode(generated_ids)
```""" ```"""
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment