Skip to content

Commit 8cf518f

Browse files
committed
ci: switch to amazon runners
1 parent 0744e23 commit 8cf518f

File tree

1 file changed

+21
-25
lines changed

1 file changed

+21
-25
lines changed

.github/workflows/unittest.yaml

Lines changed: 21 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -10,33 +10,29 @@ jobs:
1010
unittest:
1111
strategy:
1212
matrix:
13-
os:
14-
- ubuntu-20.04
15-
- "linux.4xlarge.nvidia.gpu"
16-
runs-on: ${{ matrix.os }}
17-
steps:
18-
- name: Setup Python
19-
uses: actions/setup-python@v2
20-
with:
21-
python-version: "3.10"
22-
architecture: x64
23-
- name: Checkout
24-
uses: actions/checkout@v2
25-
- name: Install Dependencies
26-
run: |
27-
set -eux
13+
include:
14+
- runs-on: "linux.2xlarge"
15+
gpu-arch-type: "cuda"
16+
gpu-arch-version: "12.1"
17+
- runs-on: "linux.4xlarge.nvidia.gpu"
18+
gpu-arch-type: "cpu"
19+
gpu-arch-version: ""
2820

29-
sudo apt-get install -y protobuf-compiler
21+
uses: pytorch/test-infra/.github/workflows/linux_job.yml@main
22+
with:
23+
timeout: 120
24+
runner: ${{ matrix.runs-on }}
25+
gpu-arch-type: ${{ matrix.gpu-arch-type }}
26+
gpu-arch-version: ${{ matrix.gpu-arch-version }}
27+
script: |
28+
conda create -n venv python=3.10 -y
29+
conda activate venv
3030
31-
pip install -e .[dev] -v
32-
- name: Run Python Tests
33-
run: |
34-
set -eux
31+
yum install -y protobuf-compiler
3532
36-
pytest -v
37-
- name: Run Rust Lint
38-
run: |
39-
set -eux
33+
python -m pip install --upgrade pip
34+
pip install -e .[dev] -v
4035
41-
cargo test -v
36+
pytest -v
37+
cargo test -v
4238

0 commit comments

Comments
 (0)