欢迎光临散文网 会员登陆 & 注册

Tigerbot,手把手教你在windows电脑上部署安装。180b超大中文语言

2023-06-07 23:02 作者:载岳  | 我要投稿

首先在d盘根目录下下载项目

git clone https://github.com/TigerResearch/TigerBot

cd TigerBot


链接: https://pan.baidu.com/s/11O5wnEJ7B3dkM1cvTdKMAA 提取码: 4g63 

下载Python310.zip



解压到TigerBot

确保你得python.exe路径为

d:\TigerBot\Python310\python.exe


https://huggingface.co/r4ziel/xformers_pre_built/blob/main/triton-2.0.0-cp310-cp310-win_amd64.whl

下载triton-2.0.0-cp310-cp310-win_amd64.whl

https://download.pytorch.org/whl/torch/

下载torch-1.13.1+cu117-cp310-cp310-win_amd64.whl



https://huggingface.co/TigerResearch/tigerbot-7b-sft/tree/main

到这里下载7b-sft的模型文件到model目录中【model目录没有自己在d:\TigerBot下创建一个】

如果想要尝试其他版本的模型,可以根据自己配置需求选择不同的模型文件下载

https://huggingface.co/TigerResearch


以下是不同模型现存的最低需求情况。


所有7b模型官方推荐最低配置是在一块3090 显卡上运行

180b模型,4bit版本的官方推荐最低2块a100 (80g)以上

180b-sft模型 官方推荐最低5块a100(80g)以上



Tigerbot-7B Bits memory(GB)

tigerbot-7b-base 16 17.2

tigerbot-7b-sft 16 17.2

tigerbot-7b-sft-4bit-128g 4 8.5



Tigerbot-180B-Research Bits memory(GB)

tigerbot-180b-sft 16 347.6

tigerbot-180b-sft-4bit-128g 4 108.5





1、

.\Python310\python.exe -m pip install pyreadline -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com


2、打开Python310\Lib\site-packages\pyreadline\py3k_compat.py

第8行替换为

    return isinstance(x, collections.abc.Callable)

保存


3、

.\Python310\python.exe -m pip install triton-2.0.0-cp310-cp310-win_amd64.whl -i https://pypi.tuna.tsinghua.edu.cn/simple


4、

#requirements.txt 内容替换为


safetensors==0.3.0

datasets==2.10.1

accelerate==0.17.1

protobuf==3.20.2

transformers==4.28.1

scikit-learn==1.0.2

torch==1.13.1

evaluate==0.4.0

texttable==1.6.7

toml==0.10.2

numpy==1.22.4

sentencepiece==0.1.98

fire==0.5.0



5、

.\Python310\python.exe -m pip install --requirement requirements.txt -i http://mirrors.aliyun.com/pypi/simple/ --trusted-host mirrors.aliyun.com


6、

.\Python310\python.exe -m pip uninstall torch

.\Python310\python.exe -m pip install torch-1.13.1+cu117-cp310-cp310-win_amd64.whl -i https://pypi.tuna.tsinghua.edu.cn/simple


7、

infer.py中加入一行

os.environ["CUDA_VISIBLE_DEVICES"] = "0"


8、

.\python310\python.exe infer.py --model_path d:\TigerBot\model\

Tigerbot,手把手教你在windows电脑上部署安装。180b超大中文语言的评论 (共 条)

分享到微博请遵守国家法律