File tree Expand file tree Collapse file tree 3 files changed +25
-1
lines changed
Expand file tree Collapse file tree 3 files changed +25
-1
lines changed Original file line number Diff line number Diff line change @@ -129,11 +129,16 @@ jobs:
129129 with :
130130 submodules : recursive
131131 - uses : astral-sh/setup-uv@v6
132- - name : setup
132+ - name : Python Setup
133133 run : |
134134 uv python install 3.12
135135 uv venv
136136 uv sync
137+ - name : Python Tests
138+ run : |
139+ . ./.venv/bin/activate
140+ cd cookbooks/landlab/
141+ ./test.sh
137142 - name : compile
138143 run : |
139144 mkdir build
Original file line number Diff line number Diff line change 1+ from mpi4py import MPI
2+
3+ comm = MPI .COMM_WORLD
4+ rank = comm .Get_rank ()
5+ size = comm .Get_size ()
6+
7+ sum = comm .allreduce (rank , op = MPI .SUM )
8+
9+ if rank == 0 :
10+ print (f"Hello World! I am process { rank } of { size } , sum = { sum } " )
11+
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ set -e
3+
4+ # MPI hello world to see if mpi4py works
5+
6+ cd mpi-hello-world
7+ mpirun -n 2 python test.py
8+ cd ..
You can’t perform that action at this time.
0 commit comments