mirror of
https://github.com/hiyouga/LLaMA-Factory.git
synced 2026-05-28 02:48:54 +08:00
[docker] update npu docker (#10479)
This commit is contained in:
2
.github/workflows/docker.yml
vendored
2
.github/workflows/docker.yml
vendored
@@ -109,7 +109,7 @@ jobs:
|
|||||||
platforms: linux/amd64,linux/arm64
|
platforms: linux/amd64,linux/arm64
|
||||||
file: ./docker/docker-npu/Dockerfile
|
file: ./docker/docker-npu/Dockerfile
|
||||||
build-args: |
|
build-args: |
|
||||||
BASE_IMAGE=quay.io/ascend/cann:8.3.rc2-a3-ubuntu22.04-py3.11
|
BASE_IMAGE=quay.io/ascend/cann:9.0.0-a3-ubuntu22.04-py3.11
|
||||||
push: ${{ github.event_name != 'pull_request' }}
|
push: ${{ github.event_name != 'pull_request' }}
|
||||||
tags: |
|
tags: |
|
||||||
docker.io/hiyouga/llamafactory:${{ steps.version.outputs.tag }}-npu-a3
|
docker.io/hiyouga/llamafactory:${{ steps.version.outputs.tag }}-npu-a3
|
||||||
|
|||||||
6
.github/workflows/tests_npu.yml
vendored
6
.github/workflows/tests_npu.yml
vendored
@@ -38,7 +38,7 @@ jobs:
|
|||||||
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
|
cancel-in-progress: ${{ github.ref != 'refs/heads/main' }}
|
||||||
|
|
||||||
container:
|
container:
|
||||||
image: ascendai/cann:8.3.rc2-910b-ubuntu22.04-py3.11
|
image: ascendai/cann:9.0.0-910b-ubuntu22.04-py3.11
|
||||||
env:
|
env:
|
||||||
HF_ENDPOINT: https://hf-mirror.com
|
HF_ENDPOINT: https://hf-mirror.com
|
||||||
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
HF_TOKEN: ${{ secrets.HF_TOKEN }}
|
||||||
@@ -65,8 +65,8 @@ jobs:
|
|||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
uv venv
|
uv venv
|
||||||
uv pip install -r requirements/npu.txt
|
|
||||||
uv pip install -e .
|
uv pip install -e .
|
||||||
|
uv pip install -r requirements/npu.txt
|
||||||
uv pip install -r requirements/dev.txt
|
uv pip install -r requirements/dev.txt
|
||||||
|
|
||||||
- name: Install node
|
- name: Install node
|
||||||
@@ -89,5 +89,7 @@ jobs:
|
|||||||
make build
|
make build
|
||||||
|
|
||||||
- name: Test with pytest
|
- name: Test with pytest
|
||||||
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
|
source /usr/local/Ascend/ascend-toolkit/set_env.sh
|
||||||
make test
|
make test
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
# https://hub.docker.com/r/ascendai/cann/tags
|
# https://hub.docker.com/r/ascendai/cann/tags
|
||||||
|
|
||||||
ARG BASE_IMAGE=quay.io/ascend/cann:8.5.1-910b-ubuntu22.04-py3.11
|
ARG BASE_IMAGE=quay.io/ascend/cann:9.0.0-910b-ubuntu22.04-py3.11
|
||||||
FROM ${BASE_IMAGE}
|
FROM ${BASE_IMAGE}
|
||||||
|
|
||||||
# Installation arguments
|
# Installation arguments
|
||||||
|
|||||||
@@ -33,7 +33,7 @@ services:
|
|||||||
dockerfile: ./docker/docker-npu/Dockerfile
|
dockerfile: ./docker/docker-npu/Dockerfile
|
||||||
context: ../..
|
context: ../..
|
||||||
args:
|
args:
|
||||||
BASE_IMAGE: quay.io/ascend/cann:8.5.1-a3-ubuntu22.04-py3.11
|
BASE_IMAGE: quay.io/ascend/cann:9.0.0-a3-ubuntu22.04-py3.11
|
||||||
PIP_INDEX: https://pypi.org/simple
|
PIP_INDEX: https://pypi.org/simple
|
||||||
container_name: llamafactory-a3
|
container_name: llamafactory-a3
|
||||||
image: llamafactory:npu-a3
|
image: llamafactory:npu-a3
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
torch==2.7.1
|
torch==2.7.1
|
||||||
torch-npu==2.7.1.post2
|
torch-npu==2.7.1.post4
|
||||||
torchvision==0.22.1
|
torchvision==0.22.1
|
||||||
torchaudio==2.7.1
|
torchaudio==2.7.1
|
||||||
|
decorator
|
||||||
|
|||||||
Reference in New Issue
Block a user