Workflow test #8
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Run Tests on gpu and iluvatar | |
| on: | |
| pull_request: | |
| paths: | |
| - "tests/**" # 将api-config 放在tests下面 命名为test.txt | |
| jobs: | |
| # upload_on_gpu: | |
| # name: Upload on bj-gpu-03 runner | |
| # runs-on: [bj-gpu-03] | |
| # container: | |
| # image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/paddlepaddle/paddle:3.2.1-gpu-cuda11.8-cudnn8.9 | |
| # steps: | |
| # - name: Checkout code | |
| # uses: actions/checkout@v4 | |
| # - name: Setup Python | |
| # uses: actions/setup-python@v5 | |
| # with: | |
| # python-version: "3.10" | |
| # - name: Install dependencies (bj-gpu-03) | |
| # shell: bash | |
| # run: | | |
| # set -euxo pipefail | |
| # pip install --pre paddlepaddle-gpu -i https://www.paddlepaddle.org.cn/packages/nightly/cu118/ | |
| # pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 | |
| # pip install func_timeout pandas pebble pynvml pyyaml | |
| # - name: Run EngineV2 (upload on bj-gpu-03) | |
| # shell: bash | |
| # run: | | |
| # set -euxo pipefail | |
| # python engineV2.py \ | |
| # --custom_device_vs_gpu=True \ | |
| # --custom_device_vs_gpu_mode=upload \ | |
| # --random_seed=42 \ | |
| # --api_config_file="tests/test.txt" \ | |
| # --num_gpus=-1 \ | |
| # --num_workers_per_gpu=1 \ | |
| # --required_memory=10.0 | |
| # - name: Package logs (bj-gpu-03) | |
| # if: always() | |
| # shell: bash | |
| # run: | | |
| # set -euxo pipefail | |
| # tar -czf test_log.tar.gz tester/api_config/test_log | |
| # - name: Upload test logs artifact (bj-gpu-03) | |
| # if: always() | |
| # uses: actions/upload-artifact@v4 | |
| # with: | |
| # name: test_log_bj-gpu-03 | |
| # path: test_log.tar.gz | |
| download_on_iluvatar: | |
| name: Download on iluvatar-gpu-2-1 runner | |
| runs-on: [iluvatar-gpu-2-1] | |
| container: | |
| image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-ixuca:latest | |
| # needs: upload_on_gpu | |
| steps: | |
| - name: Set up Proxy | |
| run: | | |
| export http_proxy=http://agent.baidu.com:8891 | |
| export https_proxy=$http_proxy | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| - name: Setup Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.10" | |
| - name: Install dependencies (iluvatar-gpu-2-1) | |
| shell: bash | |
| run: | | |
| set -euxo pipefail | |
| pip install func_timeout pandas pebble pynvml pyyaml | |
| python -m pip install paddlepaddle==3.2.0 -i https://www.paddlepaddle.org.cn/packages/stable/cpu/ | |
| python -m pip install paddle-iluvatar-gpu==3.2.0 -i https://www.paddlepaddle.org.cn/packages/stable/ixuca/ | |
| pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu | |
| - name: Run EngineV2 (download on iluvatar-gpu-2-1) | |
| shell: bash | |
| run: | | |
| set -euxo pipefail | |
| python engineV2.py \ | |
| --custom_device_vs_gpu=True \ | |
| --custom_device_vs_gpu_mode=download \ | |
| --random_seed=42 \ | |
| --api_config_file="tests/test.txt" \ | |
| --num_gpus=-1 \ | |
| --num_workers_per_gpu=1 \ | |
| --required_memory=10.0 | |
| - name: Package logs (iluvatar-gpu-2-1) | |
| if: always() | |
| shell: bash | |
| run: | | |
| set -euxo pipefail | |
| tar -czf test_log.tar.gz tester/api_config/test_log | |
| - name: Upload test logs artifact (iluvatar-gpu-2-1) | |
| if: always() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: test_log_iluvatar-gpu-2-1 | |
| path: test_log.tar.gz |