Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
aaa6296d
Unverified
Commit
aaa6296d
authored
Dec 21, 2022
by
Mohit Sharma
Committed by
GitHub
Dec 21, 2022
Browse files
Fix whisper export (#20800)
* fix_whisper_export * update input * update input
parent
3090e708
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
src/transformers/models/whisper/configuration_whisper.py
src/transformers/models/whisper/configuration_whisper.py
+3
-0
No files found.
src/transformers/models/whisper/configuration_whisper.py
View file @
aaa6296d
...
@@ -264,6 +264,9 @@ class WhisperOnnxConfig(OnnxSeq2SeqConfigWithPast):
...
@@ -264,6 +264,9 @@ class WhisperOnnxConfig(OnnxSeq2SeqConfigWithPast):
time_duration
=
time_duration
,
time_duration
=
time_duration
,
frequency
=
frequency
,
frequency
=
frequency
,
)
)
encoder_sequence_length
=
encoder_inputs
[
"input_features"
].
shape
[
2
]
seq_length
=
encoder_sequence_length
//
2
if
self
.
use_past
else
seq_length
decoder_inputs
=
super
().
generate_dummy_inputs
(
decoder_inputs
=
super
().
generate_dummy_inputs
(
preprocessor
.
tokenizer
,
batch_size
,
seq_length
,
is_pair
,
framework
preprocessor
.
tokenizer
,
batch_size
,
seq_length
,
is_pair
,
framework
)
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment