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
90ab15cb
Commit
90ab15cb
authored
Jan 08, 2020
by
Lysandre
Committed by
Lysandre Debut
Feb 04, 2020
Browse files
Remove redundant hidden states
parent
9a50828b
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/modeling_encoder_decoder.py
src/transformers/modeling_encoder_decoder.py
+1
-1
No files found.
src/transformers/modeling_encoder_decoder.py
View file @
90ab15cb
...
...
@@ -232,7 +232,7 @@ class PreTrainedEncoderDecoder(nn.Module):
encoder_outputs
=
()
kwargs_decoder
[
"encoder_hidden_states"
]
=
encoder_hidden_states
decoder_outputs
=
self
.
decoder
(
decoder_input_ids
,
encoder_hidden_states
,
**
kwargs_decoder
)
decoder_outputs
=
self
.
decoder
(
decoder_input_ids
,
**
kwargs_decoder
)
return
decoder_outputs
+
encoder_outputs
...
...
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