We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
根据README里的指引,测试了单卡和多卡运行,遇到了几个问题想请教下大佬:
本地环境配置
遇到的问题
--load-4bit出现报错
Traceback (most recent call last): File "/home/kemove/miniconda3/envs/py39-test/lib/python3.9/runpy.py", line 197, in _run_module_as_main return _run_code(code, main_globals, None, File "/home/kemove/miniconda3/envs/py39-test/lib/python3.9/runpy.py", line 87, in _run_code exec(code, run_globals) File "/home/kemove/zyq/giit/Qilin-Med-VL/llava/serve/cli.py", line 122, in <module> main(args) File "/home/kemove/zyq/giit/Qilin-Med-VL/llava/serve/cli.py", line 39, in main tokenizer, model, image_processor, context_len = load_pretrained_model(args.model_path, args.model_base, model_name, args.load_8bit, args.load_4bit, device=args.device) File "/home/kemove/zyq/giit/Qilin-Med-VL/llava/model/builder.py", line 103, in load_pretrained_model model = LlavaLlamaForCausalLM.from_pretrained(model_path, low_cpu_mem_usage=True, **kwargs) File "/home/kemove/miniconda3/envs/py39-test/lib/python3.9/site-packages/transformers/modeling_utils.py", line 2629, in from_pretrained model = cls(config, *model_args, **model_kwargs) TypeError: __init__() got an unexpected keyword argument 'load_in_4bit'
--load-8bit出现报错:RuntimeError: probability tensor contains either inf, nan or element < 0
RuntimeError: probability tensor contains either inf, nan or element < 0
查阅资料发现,其他模型也存在类似的问题,原因在于load_8bit.
本地环境为6*V100,测试以下2种策略:
device_map='auto'
import os #两卡ok,超过2会报错:RuntimeError: probability tensor contains either `inf`, `nan` or element < 0 os.environ['CUDA_VISIBLE_DEVICES'] = '2,3'
实测QiLin-Med-VL模型发现,以下策略能够正常运行:
实测demo:
想请教作者的问题:
谢谢~
The text was updated successfully, but these errors were encountered:
No branches or pull requests
根据README里的指引,测试了单卡和多卡运行,遇到了几个问题想请教下大佬:
1. 单卡运行
本地环境配置
遇到的问题
查阅资料发现,其他模型也存在类似的问题,原因在于load_8bit.
2. 多卡运行
本地环境为6*V100,测试以下2种策略:
device_map='auto'
,模型会默认使用6张卡进行加载,推理时出现报错:RuntimeError: probability tensor contains either inf, nan or element < 0
3. 总结
实测QiLin-Med-VL模型发现,以下策略能够正常运行:
实测demo:

想请教作者的问题:
谢谢~
The text was updated successfully, but these errors were encountered: