InternLM / InternLM-XComposer

InternLM-XComposer-2.5: A Versatile Large Vision Language Model Supporting Long-Contextual Input and Output
2.14k stars 133 forks source link

LoRA微调后的InternLM-XComposer2-VL-7B 无法加载 #180

Closed seifer08ms closed 4 months ago

seifer08ms commented 4 months ago

根据 微调文档Readme 安装环境准备数据,微调internlm-xcomposer2-vl-7b。训练后根据文档方法加载LoRA权重,出现问题: ValueError: Tokenizer class InternLMXComposer2Tokenizer does not exist or is not currently imported. image 尝试升级transformers到4.33.2,未解决。尝试升级transformers到最新版本,会提示 要设置trust_remote_code=True,但代码里已经设置为True:

The repository for /root/InternLM-XComposer/finetune/output/finetune/checkpoint-1375 contains custom code which must be execu
ted to correctly load the model. You can inspect the repository content at https://hf.co//root/InternLM-XComposer/finetune/ou
tput/finetune/checkpoint-1375.                                                                                               
You can avoid this prompt in future by passing the argument `trust_remote_code=True`. 
yuhangzang commented 4 months ago

The discussion in this issue may be helpful for you: https://github.com/THUDM/ChatGLM3/issues/826

seifer08ms commented 4 months ago

The discussion in this issue may be helpful for you: THUDM/ChatGLM3#826

Thanks for your reply. What is the actual meaning of updating hf model files in their discussion?

yuhangzang commented 4 months ago

You may check whether your local HF model matches the newest HF version f8e6ab8