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

fix error of parameter initialization for LoRA embedding #46

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

hero007feng
Copy link

I found that the parameter initialization at reset_parameters() of the Embedding class differs from the LoRa paper and other implementations at layers.py. I initialized lora_A with nn.init.normal_() while Lora_B with nn.init.zeros_(). Thanks.

@edwardjhu
Copy link
Collaborator

Thanks! This was also pointed out by someone else in an issue. I am inclined to keep it as it is for reproducibility since it's functionally equivalent to what is written in the paper. However, please let me know if this discrepancy is causing any issues!

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

Successfully merging this pull request may close these issues.

2 participants