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

显存占用过大疑问 #429

Open
Upcreat opened this issue Aug 22, 2024 · 1 comment
Open

显存占用过大疑问 #429

Upcreat opened this issue Aug 22, 2024 · 1 comment
Assignees

Comments

@Upcreat
Copy link

Upcreat commented Aug 22, 2024

使用示例代码进行推理,4bit的在回答的时候单张图像最大达到了38G的显存占用,是否是正常的。无量化的模型版本直接报错了。
from lmdeploy import TurbomindEngineConfig, pipeline
from lmdeploy.vl import load_image
engine_config = TurbomindEngineConfig(model_format='awq')
pipe = pipeline('internlm/internlm-xcomposer2d5-7b-4bit', backend_config=engine_config)
image = load_image('/root/workspace/InternLM-XComposer/examples/cars1.jpg')
response = pipe(('describe this image', image))
print(response.text)

image

@yuhangzang
Copy link
Collaborator

The GPU memory usage is depended on the hd_num parameter (control the input image resolution).

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

3 participants