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

[Test] Save local model path in PEFT adapter config #2026

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

Conversation

ebsmothers
Copy link
Contributor

@ebsmothers ebsmothers commented Nov 19, 2024

It was pointed out in #2025 that the one-liner AutoModelForCausalLM.from_pretrained(model_id) doesn't work for our models trained with LoRA (instead you need to call AutoModelForCausalLM.from_pretrained on a hub model followed by PeftModel.from_pretrained on the LoRA-trained model). This is a demo of saving the checkpointer's directory as part of our adapter_config.json file which should enable this to work.

Edit: after discussing with @pbontrager this won't integrate well with e.g. push to hub since it assumes a local path. So I'm not sure we want to actually land this as is, the better solution may be to make some changes to tune download.

Copy link

pytorch-bot bot commented Nov 19, 2024

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/torchtune/2026

Note: Links to docs will display an error until the docs builds have been completed.

❗ 1 Active SEVs

There are 1 currently active SEVs. If your PR is affected, please view them below:

✅ No Failures

As of commit c69a4f8 with merge base bce7091 (image):
💚 Looks good so far! There are no failures yet. 💚

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@facebook-github-bot facebook-github-bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Nov 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants