LLaMA模型加载报错_sentencepiece.SentencePieceProcessor_LoadFromFile(self, arg) TypeError: not a string

tokenizer = LlamaTokenizer.from_pretrained(lora_model_path)
lora_model_path这一项不是string类型
运行命令有参数项目为:
–lora_model ziqingyang/chinese-llama-plus-lora-7b
后面的ziqingyang/chinese-llama-plus-lora-7b是huggingface名字
我修改为了
–lora_model ziqingyang\/chinese-llama-plus-lora-7b
也就是在斜杠前面加了反斜杠,就不报错了
我估计这里可能是个BUG,并没有深究,有知道的小伙伴评论告知一下。

猜你喜欢

转载自blog.csdn.net/artistkeepmonkey/article/details/130476763