We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
When loaded with transformers.AutoTokenizer.from_pretrained, the model_max_len was set to 1000000000000000019884624838656.
transformers.AutoTokenizer.from_pretrained
model_max_len
1000000000000000019884624838656
This results in IndexError: index out of range in self when using with flair in the code below.
IndexError: index out of range in self
from flair.embeddings import TransformerDocumentEmbeddings wangchanberta = TransformerDocumentEmbeddings('airesearch/wangchanberta-base-att-spm-uncased') wangchanberta .embed(sentence)
After searching, I found this issue huggingface/transformers#14315 (comment) and it stated that model_max_length is missing from the configuration file.
model_max_length
My current workaround is manually calling the following code to overrides the missing config.
wangchanberta.tokenizer.model_max_length = 510
The text was updated successfully, but these errors were encountered:
lalital
No branches or pull requests
When loaded with
transformers.AutoTokenizer.from_pretrained
, themodel_max_len
was set to1000000000000000019884624838656
.This results in
IndexError: index out of range in self
when using with flair in the code below.After searching, I found this issue huggingface/transformers#14315 (comment) and it stated that
model_max_length
is missing from the configuration file.My current workaround is manually calling the following code to overrides the missing config.
The text was updated successfully, but these errors were encountered: