massive debugging petapm.c, almost works #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# main test workflow; ported from .travis.yaml | |
name: main | |
on: | |
push: | |
branches: [ '*', $default-branch ] | |
pull_request: | |
branches: [ $default-branch ] | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
env: | |
OMP_NUM_THREADS: 2 | |
defaults: | |
run: | |
shell: bash -l {0} | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v4 | |
- name: Install MPI | |
run: sudo apt install -y -q build-essential mpich libmpich-dev python-is-python3 python3 | |
- name: Cache conda | |
uses: actions/cache@v4 | |
env: | |
# Increase this value to reset cache. | |
CACHE_NUMBER: 0 | |
with: | |
path: ~/conda_pkgs_dir | |
key: | |
${{ runner.os }}-conda-${{ env.CACHE_NUMBER }} | |
- name: Cache depends/ | |
uses: actions/cache@v4 | |
with: | |
key: ${{ runner.os }}-build-${{ hashFiles('depends/Makefile') }} | |
path: | | |
~/depends/install | |
~/depends/include | |
~/depends/download | |
~/depends/src | |
~/depends/lib | |
- name: Setup Conda Environment | |
uses: conda-incubator/setup-miniconda@v3 | |
with: | |
miniconda-version: latest | |
activate-environment: test | |
environment-file: maintainer/conda-env.yaml | |
channels: bccp | |
show-channel-urls: true | |
use-only-tar-bz2: true | |
- run: | |
conda info | |
- name: Build | |
run: | | |
cp platform-options/Options.mk.travis Options.mk | |
make | |
- name: Unit tests | |
run: | | |
make test | |
- name: examples/travis | |
run: | | |
cd examples/travis | |
python3 ../../tools/make_class_power.py paramfile.genic --extraz 82.3333 65.6667 | |
mpirun -np 2 ../../genic/MP-GenIC paramfile.genic | |
mpirun -np 2 ../../gadget/MP-Gadget paramfile.gadget 1 # this starts from the IC | |
python check-results.py | |
mpirun -np 2 ../../gadget/MP-Gadget paramfile.gadget 99 #Checks the gravity force error | |
mpirun -np 2 ../../gadget/MP-Gadget paramfile.gadget 99 2 | |
python ../../tools/convert_bigfile_gadget_hdf5.py --input output/PART_000 --output output | |
- name: examples/dm-small | |
run: | | |
cd examples/dm-small | |
#python3 ../../tools/make_class_power.py paramfile.genic --extraz 4 3 | |
mpirun -np 2 ../../genic/MP-GenIC paramfile.genic | |
mpirun -np 2 ../../gadget/MP-Gadget paramfile.gadget | |
mpirun -np 2 ../../gadget/MP-Gadget paramfile.gadget 3 2 # Check FOF mode works | |
python check_results.py | |
- name: examples/star-small | |
run: | | |
cd examples/star-small | |
mpirun -np 2 ../../genic/MP-GenIC paramfile.genic | |
mpirun -np 2 ../../gadget/MP-Gadget paramfile.gadget | |
python check_results.py |