19  
查询码: 00000080
TGI下的大模型测试( Llama-2-7B-Chat-AWQ ,x86架构,ubuntu系统为例)
专家 作者: 宋美霞 于 2024年12月03日 ,于 2025年05月14日 编辑

该内容不安全,建议立即关闭当前页面(请提交者修改后重新发表,或降低系统安全级别)

1 创建docker镜像并启动docker容器

bash corex-docker-installer-4.1.2-10.2-ubuntu20.04-py3.10-x86_64.run

docker run -d --shm-size="32g" -it -v /usr/src:/usr/src -v /lib/modules:/lib/modules -v /dev:/dev -v /home:/home --name=test --privileged --cap-add=ALL --pid=host corex:4.1.2

docker exec -it test /bin/bash

2 准备测试依赖包和数据集

cd /home

bash text-generation-inference-2.1.1.run

bash llm-inference-benchmark-corex-4.1.2.run

下载并解压数据集:https://huggingface.co/datasets/THUDM/LongBench/resolve/main/data.zip

cp data.zip /home/llm-inference-benchmark/text-generation-inference

unzip data.zip

3 下载模型权重

apt-get install git-lfs curl

git clone https://hf-mirror.com/TheBloke/Llama-2-7B-Chat-AWQ

4 大模型测试

cd /home/llm-inference-benchmark/text-generation-inference/scripts

bash test_dataset_acc.sh /home/Llama-2-7B-Chat-AWQ llama2-7b-chat-awq


笔记



  目录
    天数智芯知识库系统 -V 5.2.6 -wcp