Skip to content

Commit

Permalink
ci: Move mpi examples to new runner.
Browse files Browse the repository at this point in the history
  • Loading branch information
rhodrin committed Jan 5, 2021
1 parent 47a9885 commit 0bbc1ad
Showing 1 changed file with 24 additions and 13 deletions.
37 changes: 24 additions & 13 deletions .github/workflows/examples-mpi.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,12 @@
# Runner information:
# Standard F4s_v2 (4 vcpus, 8 GiB memory)
# Intel Xeon® Platinum 8168 (SkyLake)
# CPU: Intel(R) Core(TM) i7-6700K CPU @ 4.00GHz

name: Examples-mpi

env:
OUTPUT_PATH: ${{ github.workspace }}
ENVHOME: "/home/devito/environments"

on:
# Trigger the workflow on push or pull request,
# but only for the master branch
Expand All @@ -17,25 +20,33 @@ on:
jobs:
build:
name: Examples with mpi
runs-on: [self-hosted, mpi]
runs-on: ["self-hosted", "mpi", "examples"]

env:
DEVITO_MPI: "1"
DEVITO_LANGUAGE: "openmp"
OMP_NUM_THREADS: "2"
DEVITO_ARCH: "gcc-7"
DEVITO_ARCH: "gcc"
DEVITO_BACKEND: "core"
CC: "gcc-7"
CXX: "g++-7"
CC: "gcc"
CXX: "g++"

steps:
- name: Checkout devito
uses: actions/checkout@v1
uses: actions/checkout@v2.3.2

# We can use the same env as for asv here
- name: Set VIRTUAL_ENV
run: |
echo "VIRTUAL_ENV=$ENVHOME/asv" >> $GITHUB_ENV
echo "PATH=$VIRTUAL_ENV/bin:$PATH" >> $GITHUB_ENV
- name: Set PATH
run: |
echo "PATH=$VIRTUAL_ENV/bin:$PATH" >> $GITHUB_ENV
- name: Install dependencies
run: |
pip3 install --upgrade pip
pip3 install -e .[extras]
pip install --upgrade pip
pip install -e .
- name: Test mpi notebooks
run : |
Expand All @@ -46,10 +57,10 @@ jobs:
- name: Test seismic examples
run: |
mpirun -n 4 py.test examples/seismic/tti/tti_example.py
mpirun -n 4 py.test examples/seismic/elastic/elastic_example.py
mpirun -n 4 py.test examples/seismic/viscoacoustic/viscoacoustic_example.py
mpirun -n 4 py.test examples/seismic/viscoelastic/viscoelastic_example.py
mpirun -n 4 pytest examples/seismic/tti/tti_example.py
mpirun -n 4 pytest examples/seismic/elastic/elastic_example.py
mpirun -n 4 pytest examples/seismic/viscoacoustic/viscoacoustic_example.py
mpirun -n 4 pytest examples/seismic/viscoelastic/viscoelastic_example.py
- name: Test fwi examples with mpi
run: |
Expand Down

0 comments on commit 0bbc1ad

Please sign in to comment.