Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue: IndexError: index out of range in self #5

Open
alxhrzg opened this issue Aug 12, 2020 · 2 comments
Open

Issue: IndexError: index out of range in self #5

alxhrzg opened this issue Aug 12, 2020 · 2 comments

Comments

@alxhrzg
Copy link

alxhrzg commented Aug 12, 2020

Seems to be related to the added special tokens, can be fixed by adding:
model.resize_token_embeddings(len(tokenizer))
See a related issue with BERT: huggingface/transformers#4153

@NONOThingC
Copy link

This is aso helpful for
IndexError: index out of range in self
But it is strange that training in gpu seems dont have this problem.

@alxhrzg
Copy link
Author

alxhrzg commented Aug 15, 2020

Yes indeed, I opened this issue in a hurry (before I forget) and actually meant IndexError: index out of range in self. I will adjust it accordingly!

@alxhrzg alxhrzg changed the title Issue: NameError: name 'self' is not defined Issue: IndexError: index out of range in self Aug 15, 2020
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

No branches or pull requests

2 participants