Windows 安装 Xinference

0. 引言

Xorbits Inference(Xinference)是一个性能强大且功能全面的分布式推理框架。可用于大语言模型(LLM),语音识别模型,多模态模型等各种模型的推理。通过 Xorbits Inference,你可以轻松地一键部署你自己的模型或内置的前沿开源模型。无论你是研究者,开发者,或是数据科学家,都可以通过 Xorbits Inference 与最前沿的 AI 模型,发掘更多可能。

为什么选择 Xinference?

在这里插入图片描述

启动后的画面,

在这里插入图片描述

1. 创建虚拟环境

conda create -n xinference python=3.10 -y
conda activate xinference 

2. 安装 pytorch

conda install pytorch==2.0.1 torchvision==0.15.2 torchaudio==2.0.2 pytorch-cuda=11.8 -c pytorch -c nvidia

3. 安装 llama_cpp_python

pip install https://github.com/abetlen/llama-cpp-python/releases/download/v0.2.55/llama_cpp_python-0.2.55-cp310-cp310-win_amd64.whl

refer: https://github.com/abetlen/llama-cpp-python

4. 安装 chatglm-cpp

pip install https://github.com/li-plus/chatglm.cpp/releases/download/v0.3.1/chatglm_cpp-0.3.1-cp310-cp310-win_amd64.whl

refer: https://github.com/li-plus/chatglm.cpp

5. 安装 Xinference

pip install "xinference[all]"

refer: https://github.com/xorbitsai/inference

6. 设置 model 路径

在我的电脑上设置环境变量,路径请根据各自环境修改。

XINFERENCE_HOME=F:\XinferenceCache

7. 启动 Xinference

xinference-local -H <your_ip>

在这里插入图片描述
选择一个 Model 运行,

在这里插入图片描述
运行成功后,在 “Running Models” 页面可以查看,

在这里插入图片描述

8. 查看 Cluster Information

点击 Cluster Information,

在这里插入图片描述
完结!

评论 5
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值