Skip to content

Update ci.yaml

Update ci.yaml #635

Workflow file for this run

name: ci
on:
push
# pull_request_review:
# types: [submitted]
jobs:
approved:
# if: github.event.review.state == 'approved'
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
py-version:
- 3.8
- 3.9
- '3.10'
mpi: [ 'mpich' ]
install-options: [ '.', '.[hdf5,netcdf]' ]
pytorch-version:
- 'torch==1.8.1+cpu torchvision==0.9.1+cpu torchaudio==0.8.1 numpy==1.20.0'
- 'torch==1.9.1+cpu torchvision==0.10.1+cpu torchaudio==0.9.1'
- 'torch==1.10.1+cpu torchvision==0.11.2+cpu torchaudio==0.10.1'
- 'torch==1.11.0+cpu torchvision==0.12.0+cpu torchaudio==0.11.0'
- 'torch==1.12.1+cpu torchvision==0.13.1+cpu torchaudio==0.12.1'
- 'torch==1.13.1+cpu torchvision==0.14.1+cpu torchaudio==0.13.1'
- 'torch torchvision torchaudio'
exclude:
- py-version: '3.10'
pytorch-version: 'torch==1.8.1+cpu torchvision==0.9.1+cpu torchaudio==0.8.1 numpy==1.20.0'
- py-version: '3.10'
pytorch-version: 'torch==1.9.1+cpu torchvision==0.10.1+cpu torchaudio==0.9.1'
- py-version: '3.10'
pytorch-version: 'torch==1.10.1+cpu torchvision==0.11.2+cpu torchaudio==0.10.1'
name: Python ${{ matrix.py-version }} with ${{ matrix.pytorch-version }}; options ${{ matrix.install-options }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup MPI
uses: mpi4py/setup-mpi@v1
with:
mpi: ${{ matrix.mpi }}
- name: Use Python ${{ matrix.py-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.py-version }}
architecture: x64
- name: Test
run: |
pip install pytest
pip install ${{ matrix.pytorch-version }} --extra-index-url https://download.pytorch.org/whl/cpu
pip install ${{ matrix.install-options }}
mpirun -n 2 pytest heat/
# mpirun -n 3 pytest heat/
# mpirun -n 4 pytest heat/