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

Initial kernel changes to support GaLore #1137

Open
wants to merge 8 commits into
base: main
Choose a base branch
from
Prev Previous commit
Next Next commit
Fix mistake
matthewdouglas committed Oct 30, 2024
commit b2a01ec90fb23e76f27fac6acc4603925e660a05
2 changes: 1 addition & 1 deletion bitsandbytes/optim/adamw.py
Original file line number Diff line number Diff line change
@@ -228,7 +228,7 @@ def step(self, closure=None):
self.prefetch_state(p)

if "rank" in group:
self.update_step(group, p, gindex, pindex, return_updates=lor_update)
self.update_step(group, lor_update, gindex, pindex, return_updates=lor_update)

# GaLore Projection Back
p.data.add_(state["projector"].project_back(lor_update))
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From Algorithm 1 in the paper:

update = project_back(lor_update)
weight.data += update