-
Notifications
You must be signed in to change notification settings - Fork 25.2k
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
'utf-8' codec can't decode byte 0x80 in position 0: invalid start byte #1620
Comments
Hi, could you provide more information: e.g. respect the template? Please tell us which model, which bin file, with which command? |
tokenizer = BertTokenizer.from_pretrained("/home/liping/liping/bert/bert-base-cased-pytorch_model.bin") XLNetModel.from_pretrained("/data2/liping/xlnet/xlnet-base-cased-pytorch_model.bin") |
@lipingbj With the latest versions of
The following files must be located in that folder:
Please make sure that these files exist and e.g. rename That should work :) |
encoder_model = BertModel.from_pretrained("/home/liping/liping/bert/pytorch-bert-model") vocab.txt, pytorch_model.bin, config.json have included in directory bert/pytorch-bert-model OSError: Model name '/home/liping/liping/bert/pytorch-bert-model' was not found in model name list (bert-base-uncased, bert-large-uncased, bert-base-cased, bert-large-cased, bert-base-multilingual-uncased, bert-base-multilingual-cased, bert-base-chinese, bert-base-german-cased, bert-large-uncased-whole-word-masking, bert-large-cased-whole-word-masking, bert-large-uncased-whole-word-masking-finetuned-squad, bert-large-cased-whole-word-masking-finetuned-squad, bert-base-cased-finetuned-mrpc, bert-base-german-dbmdz-cased, bert-base-german-dbmdz-uncased). We assumed '/home/liping/liping/bert/pytorch-bert-model/config.json' was a path or url to a configuration file named config.json or a directory containing such a file but couldn't find any such file at this path or url. |
As the error says, "We assumed '/home/liping/liping/bert/pytorch-bert-model/config.json' was a path or url to a configuration file named config.json or a directory containing such a file but couldn't find any such file at this path or url." Your data does not seem to be in "/home/liping/liping/bert/pytorch-bert-model" |
Hello, I'm trying to load biobert into pytorch, seeing a different error: any hints? @LysandreJik |
Can you show the code that you are running to load from pre-trained weights?
As stefan-it mentioned above, the directory must contain the 3 required files. |
When I load the pretrained model from the local bin file, there is a decoding problem.
The text was updated successfully, but these errors were encountered: