20  
查询码: 00000068
(x86) vllm加载chatglm3 6b GPTQ int4、llama3 8b GPTQ int8量化模型推理乱码解决方法
专家 作者: 宋美霞 于 2024年11月25日 ,于 2025年05月14日 编辑

部署llama3-8B-GPTQ-INT8模型

conda create --name myenv python=3.10
conda activate myenv
bash installwhl.sh /home/whl310
apt-get install git-lfs

git clone https://www.modelscope.cn/swift/Meta-Llama-3-8B-Instruct-GPTQ-Int8.git

python3 offline_inference.py --model /home/Meta-Llama-3-8B-Instruct-GPTQ-Int8 --quantization gptq -tp 1 --temperature 0.0

粘贴图片

替换vllm和ixformer包

pip3 install vllm-0.5.4+corex.4.1.0.w2436-py3-none-any.whl

pip3 install ixformer-0.6.0+corex.4.1.0.w2436-cp310-cp310-linux_x86_64.whl

再次运行模型,没有乱码了

粘贴图片

部署chatglm3-6B-gptq-4bit模型

git clone https://hf-mirror.com/ranchlai/chatglm3-6B-gptq-4bit

更新vllm和ixformer后测试

python3 offline_inference.py --model /home/chatglm3-6B-gptq-4bit --quantization gptq -tp 1 --temperature 0.0  --trust-remote-code

粘贴图片




笔记



 附件

附件类型

PNGPNG

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