-
Notifications
You must be signed in to change notification settings - Fork 109
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 adpater id argument #478
Conversation
@@ -90,6 +90,9 @@ def parse_args(): | |||
else: | |||
os.environ["ONEFLOW_MLIR_ENABLE_INFERENCE_OPTIMIZATION"] = "1" | |||
|
|||
pipe.load_lora_weights(args.adapter_id) | |||
pipe.fuse_lora() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
需要判断版本
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
像这样:
if hasattr(pipe, "fuse_lora"): |
pipe.fuse_lora() | ||
else: | ||
print(f"pipe.fuse_lora doesn't exist, exit") | ||
exit(1) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
发现这里不需要 exit,不 fuse_lora 也可以正常执行 @doombeaker
test on RTX 3090
onediff
6.94 it/s
pytorch
3.9 it/s