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

llava-phi3 模型转换到llava模型报错。求助,怎么解决? #641

Open
awzhgw opened this issue May 4, 2024 · 1 comment
Open
Assignees

Comments

@awzhgw
Copy link

awzhgw commented May 4, 2024

python
Traceback (most recent call last):
File "/export/App/training_platform/PinoModel/xtuner/xtuner/configs/llava/phi3_mini_4k_v16/convert_xtuner_weights_to_llava.py", line 99, in
main()
File "/export/App/training_platform/PinoModel/xtuner/xtuner/configs/llava/phi3_mini_4k_v16/convert_xtuner_weights_to_llava.py", line 94, in main
convert_to_llava(args.text_model_id, args.vision_model_id,
File "/export/App/training_platform/PinoModel/xtuner/xtuner/configs/llava/phi3_mini_4k_v16/convert_xtuner_weights_to_llava.py", line 80, in convert_to_llava
model.load_state_dict(state_dict, strict=True, assign=True)
File "/usr/local/lib/python3.10/dist-packages/torch/nn/modules/module.py", line 2152, in load_state_dict
raise RuntimeError('Error(s) in loading state_dict for {}:\n\t{}'.format(
RuntimeError: Error(s) in loading state_dict for LlavaLlamaForCausalLM:
Missing key(s) in state_dict: "model.image_newline".

@pppppM
Copy link
Collaborator

pppppM commented May 6, 2024

@awzhgw convert_xtuner_weights_to_llava.py 这个脚本,只支持 llm 是 llama 结构的模型

我们马上会更新 phi3 的转换脚本,需要把 phi3 先转为 llama 才行

@pppppM pppppM self-assigned this May 6, 2024
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