更新时间:2025-10-14 GMT+08:00
分享

制作推理镜像

  1. 根据表2获取相应资源的推理基础镜像。
  2. 根据获取昇腾云版本包获取相应资源的推理软件包。
  3. 在安装有docker的环境中制作推理镜像,解压AscendCloud压缩包及该目录下的推理代码AscendCloud-LLM-xxx.zip和算子包AscendCloud-OPP-xxx.zip,并执行命令制作推理镜像。安装过程需要连接互联网git clone,请确保机器环境可以访问公网。
    制作6.5.201推理镜像:
    unzip AscendCloud-*.zip -d ./AscendCloud && cd ./AscendCloud && unzip AscendCloud-OPP-*.zip && unzip AscendCloud-OPP-*-torch-*-py*.zip -d ./AscendCloud-OPP && cd .. && unzip ./AscendCloud/AscendCloud-LLM-*.zip -d ./AscendCloud/AscendCloud-LLM && cd ./AscendCloud/AscendCloud-LLM/llm_inference/ascend_vllm/ && sh build_image.sh --base-image=${base_image} --image-name=${image_name}
    制作6.5.T908.1推理镜像:
    unzip AscendCloud-*.zip -d AscendCloud && cd AscendCloud && unzip AscendCloud-OPP-*.zip && unzip AscendCloud-OPP-*-torch-*-py*.zip -d ./AscendCloud-OPP && unzip AscendCloud-LLM*.zip -d ./AscendCloud-LLM && cp AscendCloud-LLM/llm_inference/ascend_vllm/Dockerfile . && docker build -t ${image_name} --build-arg BASE_IMAGE=${base_image} .
    参数说明:
    • ${base_image}为基础镜像地址。
    • ${image_name}为推理镜像名称,可自行指定。

相关文档