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

ensure merged model matches the training dtype #902

Merged
merged 3 commits into from
Nov 29, 2023
Merged

Conversation

winglian
Copy link
Collaborator

seems like all the lora merges are fp16. matching the training would open up bfloat16 support which should be better.

src/axolotl/cli/__init__.py Outdated Show resolved Hide resolved
@NanoCode012
Copy link
Collaborator

NanoCode012 commented Nov 29, 2023

Perhaps, some individuals "might" want fp32? We should respect same dtype as in training. You might want to do model.to(cfg.torch_dtype). This would load the one from

https://github.com/OpenAccess-AI-Collective/axolotl/blob/71b7ea3c056f15123b56fef3151b4044c80078b4/src/axolotl/utils/config.py#L73-L78

src/axolotl/cli/__init__.py Outdated Show resolved Hide resolved
@winglian winglian merged commit 1d21aa6 into main Nov 29, 2023
4 checks passed
@winglian winglian deleted the lora-merge-dtype branch November 29, 2023 14:55
mkeoliya pushed a commit to mkeoliya/axolotl that referenced this pull request Dec 15, 2023
* ensure merged model matches the training dtype

* Update src/axolotl/cli/__init__.py

* Update src/axolotl/cli/__init__.py
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.

None yet

2 participants