环境信息
- os:Ubuntu 22.04.3 LTS
- 显卡:v100*2
- python:3.11
- vllm:0.6.6
- cuda:12.2
- 模型:UI-TARS-7B-DPO
安装步骤
1. 安装虚拟环境并安装相关依赖
conda create -n unsloth_env python==3.11
pip install -U transformers
VLLM_VERSION=0.6.6
CUDA_VERSION=cu124
pip install vllm==${VLLM_VERSION} --extra-index-url https://download.pytorch.org/whl/${CUDA_VERSION}
2. 下载模型文件
modelscope download --model bytedance-research/UI-TARS-7B-DPO --local_dir ./UI-TARS-7B-DPO
2.1 修改preprocessor_config.json文件
"size": {
"max_pixels": 2116800,
"min_pixels": 3136,
# 新增两行
"shortest_edge": 1000,
"longest_edge": 2000
},
3. 启动服务
CUDA_VISIBLE_DEVICES=2,3 python -m vllm.entrypoints.openai.api_server --served-model-name ui-tars --dtype=half --tensor-parallel-size 2 --trust-remote-code --model ./UI-TARS-7B-DPO/ --limit-mm-per-prompt "image=6"
参数:
–dtype=half
–tensor-parallel-size 2
–trust-remote-code
–limit-mm-per-prompt “image=6”(如果不指定会卡在第一张)
参考链接:https://github.com/vllm-project/vllm/issues/9739
启动成功:
4. 安装agent(windows)并配置

5. 效果
下载地址(html):https://download.csdn.net/download/shen12138/90602874
总结
很慢,也可能是我gpu卡太差,一个询问天气的问题,跑了将近3分钟。
2447

被折叠的 条评论
为什么被折叠?



