-
Notifications
You must be signed in to change notification settings - Fork 479
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
KeyError: 'lm_head.weight' while lora extraction #484
Comments
I am getting the same error, for all of the following model types:
I believe these two issues offer hints: In particular, it has something to do with lm_head being a different name in these architectures. @David-AU-github had a solution for Llama 3.2 3B, which may also work for Qwen with a few changes. It would appear that adding aliases would not break anything, if I am understanding this correctly.
|
Oh, it appears someone else ran into this issue and made a PR, solving it a different way: https://github.com/arcee-ai/mergekit/pull/483/files Similar issue: #447 |
Unfortunately, that PR didn't work for me, it spits out messages like:
I think it is due to each of those weights having different names from Llama 3.1 8B (the "model." prefix) but I'm not 100% sure. https://huggingface.co/meta-llama/Llama-3.1-8B/blob/main/model.safetensors.index.json I'm going to tinker with the aliases some more. |
I got this error during LoRA Extraction. Parameters:
finetuned_model: ngxson/MiniThinky-v2-1B-Llama-3.2 (llama3.2-1b, fp16, not merged)
base_model: unsloth/Llama-3.2-1B-Instruct (base of finetuned_model, fp16)
rank: 32
Full logs:
The same error occurs when extracting Qwen models. If the error occurs for everything, then what is the functionality?
I hope someone can help me)
The text was updated successfully, but these errors were encountered: