-
-
Notifications
You must be signed in to change notification settings - Fork 185
66 lines (60 loc) · 2.47 KB
/
conda.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
name: Conda install
on:
# Uncomment the below 'push' to trigger on push
#push:
# branches:
# - "**"
schedule:
# '*' is a special character in YAML, so string must be quoted
- cron: "0 2 * * WED"
workflow_dispatch: ~
jobs:
conda-install:
name: Install and test
strategy:
matrix:
os: [ubuntu-latest, macos-13, macos-14, windows-2022]
python-version: ["3.9", "3.10", "3.11", "3.12"]
petsc-scalar-type: ["real"]
include:
- os: ubuntu-latest
python-version: "3.12"
petsc-scalar-type: "complex"
runs-on: ${{ matrix.os }}
timeout-minutes: 30
# This is necessary to ensure conda environment is activated in every step.
defaults:
run:
shell: bash -el {0}
steps:
- uses: conda-incubator/setup-miniconda@v3
with:
auto-update-conda: true
python-version: ${{ matrix.python-version }}
# TODO: These could probably be merged into one cross-platform step.
- name: Install DOLFINx with MPICH (Unix-like)
if: ${{ runner.os == 'macOS' || runner.os == 'Linux' }}
run: |
conda install -c conda-forge fenics-dolfinx mpich petsc=*=${{ matrix.petsc-scalar-type }}*
- name: Install DOLFINx (Windows)
if: ${{ runner.os == 'Windows' }}
run: |
conda install -c conda-forge fenics-dolfinx
- name: Test (Unix-like)
if: ${{ runner.os == 'macOS' || runner.os == 'Linux' }}
run: |
conda info
conda list
mpiexec --version
mpiexec -v -np 1 python -c "from mpi4py import MPI; import dolfinx; dolfinx.mesh.create_rectangle(comm=MPI.COMM_WORLD, points=((0, 0), (2, 1)), n=(32, 16))"
mpiexec -v -np 2 python -c "from mpi4py import MPI; import dolfinx; dolfinx.mesh.create_rectangle(comm=MPI.COMM_WORLD, points=((0, 0), (2, 1)), n=(32, 16))"
# NOTE: Late 2024, Intel MPI is only correctly setup using cmd.exe.
- name: Test (Windows)
if: ${{ runner.os == 'Windows' }}
shell: cmd /C CALL {0}
run: |
conda info
conda list
mpiexec --version
mpiexec -v -np 1 python -c "from mpi4py import MPI; import dolfinx; dolfinx.mesh.create_rectangle(comm=MPI.COMM_WORLD, points=((0, 0), (2, 1)), n=(32, 16))"
mpiexec -v -np 2 python -c "from mpi4py import MPI; import dolfinx; dolfinx.mesh.create_rectangle(comm=MPI.COMM_WORLD, points=((0, 0), (2, 1)), n=(32, 16))"