Skip to content

Commit

Permalink
Fix whisper export (#1503)
Browse files Browse the repository at this point in the history
* fix whisper config

* make style

---------

Co-authored-by: Mohit Sharma <[email protected]>
  • Loading branch information
mht-sharma and mht-sharma authored Nov 2, 2023
1 parent 87fcf9f commit 1aee8ff
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion optimum/exporters/onnx/model_configs.py
Original file line number Diff line number Diff line change
Expand Up @@ -1291,7 +1291,10 @@ def inputs(self) -> Dict[str, Dict[int, str]]:


class WhisperOnnxConfig(AudioToTextOnnxConfig):
NORMALIZED_CONFIG_CLASS = NormalizedSeq2SeqConfig
NORMALIZED_CONFIG_CLASS = NormalizedSeq2SeqConfig.with_args(
encoder_num_layers="encoder_layers",
decoder_num_layers="decoder_layers",
)
ATOL_FOR_VALIDATION = 1e-3

@property
Expand Down

0 comments on commit 1aee8ff

Please sign in to comment.