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 device override in model.py #28

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

Conversation

guangyaodou
Copy link

Fixed device override when loading Llama models.

@iamgroot42
Copy link
Owner

@guangyaodou thanks for the PR. Just to make sure- everything works as expected for Llama with this fix, right? Can you try it once

@guangyaodou
Copy link
Author

@iamgroot42 Hi. I just tried it and it will only prevent overriding my device for Llama models. With this being said, I think one should also change device_map in this line to device_map (which is not included in this PR).

Also, based on the discussion in this post, Llama3 now uses different tokenizer and should only be initialized with AutoTokenizer. This means that initialization of Llama model should also be changed to Autotokenizer. Please let me know if you want me to include these changes in the PR.

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