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

加载模型做finetune报错alueError: Target modules ['self_attn.q_proj', 'self_attn.k_proj', 'self_attn.v_proj', 'self_attn.o_proj', 'mlp.gate_proj', 'mlp.down_proj', 'mlp.up_proj'] not found in the base model. Please check the target modules and try again. #150

Open
Qinger27 opened this issue May 7, 2024 · 7 comments

Comments

@Qinger27
Copy link

Qinger27 commented May 7, 2024

ValueError: Target modules ['self_attn.q_proj', 'self_attn.k_proj', 'self_attn.v_proj', 'self_attn.o_proj', 'mlp.gate_proj', 'mlp.down_proj', 'mlp.up_proj'] not found in the base model. Please check the target modules and try again.
请问有人遇到过这个问题吗?要怎么解决呢?

@dandanW91
Copy link

同问

@Colorfu1
Copy link

Colorfu1 commented May 7, 2024

➕1

@hjh0119
Copy link
Contributor

hjh0119 commented May 8, 2024

报错看起来像lora target module没有找成功,猜测是模块名错了,如果是QKV的话应该是wqkv
如果是V1.5模型,可以尝试用swift来微调#129

@linsiwei123
Copy link

你用的脚本应该是1.2的微调脚本吧,1.5的要把上面这些改成wqkv

@McCarthyjfq
Copy link

请问一下什么叫改成wqkv?可以具体说一下怎么改吗,谢谢!

@linsiwei123
Copy link

请问一下什么叫改成wqkv?可以具体说一下怎么改吗,谢谢!

具体来说的话,在这个文件里internvl_chat/internvl/model/internvl_chat/modeling_internvl_chat.py
你需要这么改
1716280956910
1716280971012

@czczup
Copy link
Member

czczup commented May 30, 2024

这边需要对不同语言模型用不同的key去匹配,我加个TODO。

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

7 participants