KEMBAR78
update decoder_vocab_size when resizing embeds by patil-suraj · Pull Request #16700 · huggingface/transformers · GitHub
Skip to content

Conversation

@patil-suraj
Copy link
Contributor

What does this PR do?

  • Update the config.decoder_vocab_size when resizing embeds if the enc, dec embeds are shared.
  • Use config.decoder_vocab_size to reshape the lm_logits

Fixes #16670

@HuggingFaceDocBuilderDev
Copy link

HuggingFaceDocBuilderDev commented Apr 11, 2022

The documentation is not available anymore as the PR was closed or merged.

Copy link
Collaborator

@sgugger sgugger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing!

@patil-suraj patil-suraj merged commit 1471857 into huggingface:main Apr 11, 2022
@patil-suraj patil-suraj deleted the fix-marian-resize branch April 11, 2022 16:02
elusenji pushed a commit to elusenji/transformers that referenced this pull request Jun 12, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Bug in Marian model (or tokenizer) in transformers==4.18.0

3 participants