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

ValueError: When load_4bit=True in from longva.model.builder.load_pretrained_model #11

Open
hungvtm opened this issue Jul 15, 2024 · 0 comments

Comments

@hungvtm
Copy link

hungvtm commented Jul 15, 2024

Description
When using the load_pretrained_model function from longva.model.builder with load_4bit=True, the following error is encountered: ValueError: You can't pass `load_in_4bit` or `load_in_8bit` as a kwarg when passing `quantization_config` argument at the same time.

This issue occurs because the quantization_config argument is being set alongside the load_in_4bit argument, which leads to a conflict.

Proposed Solution
To resolve this issue, please remove the following line from the function:

# kwargs["load_in_4bit"] = True

This change will ensure that the conflicting argument is not set, preventing the ValueError.
This adjustment ensures that the function will work correctly when load_4bit=True.
Thank you for your attention to this issue.

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

No branches or pull requests

1 participant