Skip to content

Commit 202cbd4

Browse files
committed
update to dev/emc
2 parents 61717ee + b418ae1 commit 202cbd4

File tree

337 files changed

+34659
-14036
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

337 files changed

+34659
-14036
lines changed
+77
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
name: 'Build-.testing-prerequisites'
2+
description: 'Build pre-requisites for .testing including FMS and a symmetric MOM6 executable'
3+
inputs:
4+
build_symmetric:
5+
description: 'If true, will build the symmetric MOM6 executable'
6+
required: false
7+
default: 'true'
8+
install_python:
9+
description: 'If true, will install the local python env needed for .testing'
10+
required: false
11+
default: 'true'
12+
runs:
13+
using: 'composite'
14+
steps:
15+
- name: Git info
16+
shell: bash
17+
run: |
18+
echo "::group::Git commit info"
19+
echo "git log:"
20+
git log | head -60
21+
echo "::endgroup::"
22+
23+
- name: Env
24+
shell: bash
25+
run: |
26+
echo "::group::Environment"
27+
env
28+
echo "::endgroup::"
29+
30+
- name: Install needed packages for compiling
31+
shell: bash
32+
run: |
33+
echo "::group::Install linux packages"
34+
sudo apt-get update
35+
sudo apt-get install netcdf-bin libnetcdf-dev libnetcdff-dev mpich libmpich-dev
36+
echo "::endgroup::"
37+
38+
- name: Compile FMS library
39+
shell: bash
40+
run: |
41+
echo "::group::Compile FMS library"
42+
cd .testing
43+
make deps/lib/libFMS.a -s -j
44+
echo "::endgroup::"
45+
46+
- name: Store compiler flags used in Makefile
47+
shell: bash
48+
run: |
49+
echo "::group::config.mk"
50+
cd .testing
51+
echo "FCFLAGS_DEBUG=-g -O0 -Wextra -Wno-compare-reals -fbacktrace -ffpe-trap=invalid,zero,overflow -fcheck=bounds" >> config.mk
52+
echo "FCFLAGS_REPRO=-g -O2 -fbacktrace" >> config.mk
53+
echo "FCFLAGS_INIT=-finit-real=snan -finit-integer=2147483647 -finit-derived" >> config.mk
54+
echo "FCFLAGS_COVERAGE=--coverage" >> config.mk
55+
cat config.mk
56+
echo "::endgroup::"
57+
58+
- name: Compile MOM6 in symmetric memory mode
59+
shell: bash
60+
run: |
61+
echo "::group::Compile MOM6 in symmetric memory mode"
62+
cd .testing
63+
test ${{ inputs.build_symmetric }} == true && make build/symmetric/MOM6 -j
64+
echo "::endgroup::"
65+
66+
- name: Install local python venv for generating input data
67+
shell: bash
68+
run: |
69+
echo "::group::Create local python env for input data generation"
70+
cd .testing
71+
test ${{ inputs.install_python }} == true && make work/local-env
72+
echo "::endgroup::"
73+
74+
- name: Set flags
75+
shell: bash
76+
run: |
77+
echo "TIMEFORMAT=... completed in %lR (user: %lU, sys: %lS)" >> $GITHUB_ENV

.github/workflows/coupled-api.yml

+33
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: API for coupled drivers
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-top-api:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/testing-setup
19+
with:
20+
build_symmetric: 'false'
21+
install_python: 'false'
22+
23+
- name: Compile MOM6 for the GFDL coupled driver
24+
shell: bash
25+
run: make check_mom6_api_coupled -j
26+
27+
- name: Compile MOM6 for the NUOPC driver
28+
shell: bash
29+
run: make check_mom6_api_nuopc -j
30+
31+
- name: Compile MOM6 for the MCT driver
32+
shell: bash
33+
run: make check_mom6_api_mct -j

.github/workflows/coverage.yml

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Code coverage
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
build-test-nans:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
env:
14+
REPORT_COVERAGE: true
15+
16+
steps:
17+
- uses: actions/checkout@v2
18+
with:
19+
submodules: recursive
20+
21+
- uses: ./.github/actions/testing-setup
22+
23+
- name: Run and post coverage
24+
run: make run.symmetric -k -s
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
name: Doxygen and style
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
doxygen:
7+
8+
runs-on: ubuntu-latest
9+
10+
steps:
11+
- uses: actions/checkout@v2
12+
with:
13+
submodules: recursive
14+
15+
- name: Check white space (non-blocking)
16+
run: |
17+
./.testing/trailer.py -e TEOS10 -l 120 src config_src 2>&1 | tee style_errors
18+
continue-on-error: true
19+
20+
- name: Install packages used when generating documentation
21+
run: |
22+
sudo apt-get update
23+
sudo apt-get install python3-sphinx python3-lxml perl
24+
sudo apt-get install texlive-binaries texlive-base bibtool tex-common texlive-bibtex-extra
25+
sudo apt-get install graphviz
26+
27+
- name: Build doxygen HTML
28+
run: |
29+
cd docs
30+
perl -e 'print "perl version $^V" . "\n"'
31+
mkdir _build && make nortd DOXYGEN_RELEASE=Release_1_8_13 UPDATEHTMLEQS=Y
32+
cat _build/doxygen_warn_nortd_log.txt
33+
34+
- name: Report doxygen or style errors
35+
run: |
36+
grep "warning:" docs/_build/doxygen_warn_nortd_log.txt | grep -v "as part of a" | tee doxy_errors
37+
cat style_errors doxy_errors > all_errors
38+
cat all_errors
39+
test ! -s all_errors

.github/workflows/expression.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Expression verification
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-repro-and-dims:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/testing-setup
19+
20+
- name: Compile MOM6 using repro optimization
21+
run: make build/repro/MOM6 -j
22+
23+
- name: Create validation data
24+
run: make run.symmetric -k -s
25+
26+
- name: Run tests
27+
run: make test.repros test.dims -k -s

.github/workflows/other.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: OpenMP and Restart verification
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-openmp-nan-restarts:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/testing-setup
19+
20+
- name: Compile with openMP
21+
run: make build/openmp/MOM6 -j
22+
23+
- name: Create validation data
24+
run: make run.symmetric -k -s
25+
26+
- name: Run tests
27+
run: make test.openmps test.nans test.restarts -k -s

.github/workflows/regression.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Regression
2+
3+
on: [pull_request]
4+
5+
jobs:
6+
build-test-regression:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/testing-setup
19+
20+
- name: Compile reference model
21+
run: make build.regressions MOM_TARGET_SLUG=$GITHUB_REPOSITORY MOM_TARGET_LOCAL_BRANCH=$GITHUB_BASE_REF DO_REGRESSION_TESTS=true -j
22+
23+
- name: Create validation data
24+
run: make run.symmetric -k -s
25+
26+
- name: Regression test
27+
run: make test.regressions DO_REGRESSION_TESTS=true -k -s

.github/workflows/stencil.yml

+27
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
name: Stencil related verification
2+
3+
on: [push, pull_request]
4+
5+
jobs:
6+
test-symmetric-layout-rotation:
7+
8+
runs-on: ubuntu-latest
9+
defaults:
10+
run:
11+
working-directory: .testing
12+
13+
steps:
14+
- uses: actions/checkout@v2
15+
with:
16+
submodules: recursive
17+
18+
- uses: ./.github/actions/testing-setup
19+
20+
- name: Compile MOM6 in asymmetric memory mode
21+
run: make build/asymmetric/MOM6 -j
22+
23+
- name: Create validation data
24+
run: make run.symmetric -k -s
25+
26+
- name: Run tests
27+
run: make test.grids test.layouts test.rotations -k -s

.gitignore

+1-7
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,7 @@
44
html
55

66

7-
# Build output
8-
*.o
9-
*.mod
10-
MOM6
11-
12-
13-
# Autoconf
7+
# Autoconf output
148
aclocal.m4
159
autom4te.cache/
1610
config.log

.gitlab-ci.yml

+29-4
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ setup:
3131
# Clone regressions directory
3232
- git clone --recursive http://gitlab.gfdl.noaa.gov/ogrp/Gaea-stats-MOM6-examples.git tests && cd tests
3333
# Install / update testing scripts
34-
- git clone https://github.com/adcroft/MRS.git MRS
34+
- git clone -b new-code-struct https://github.com/adcroft/MRS.git MRS
3535
# Update MOM6-examples and submodules
3636
- (cd MOM6-examples && git checkout . && git checkout dev/gfdl && git pull && git submodule init && git submodule update)
3737
- (cd MOM6-examples/src/MOM6 && git submodule update)
@@ -60,7 +60,7 @@ gnu:ocean-only-nolibs:
6060
- time tar zxf $CACHE_DIR/tests_$CI_PIPELINE_ID.tgz && cd tests
6161
- make -f MRS/Makefile.build build/gnu/env && cd build/gnu
6262
# mkdir -p build/gnu/repro/symmetric_dynamic/ocean_only && cd build/gnu/repro/symmetric_dynamic/ocean_only
63-
- ../../MOM6-examples/src/mkmf/bin/list_paths -l ../../../config_src/{solo_driver,dynamic_symmetric,ext*} ../../../src ../../MOM6-examples/src/FMS
63+
- ../../MOM6-examples/src/mkmf/bin/list_paths -l ../../../config_src/{drivers/solo_driver,memory/dynamic_symmetric,infra/FMS1,ext*} ../../../src ../../MOM6-examples/src/FMS
6464
- sed -i '/FMS\/.*\/test_/d' path_names
6565
- ../../MOM6-examples/src/mkmf/bin/mkmf -t ../../MOM6-examples/src/mkmf/templates/ncrc-gnu.mk -p MOM6 -c"-Duse_libMPI -Duse_netCDF" path_names
6666
- time (source ./env ; make NETCDF=3 REPRO=1 MOM6 -s -j)
@@ -73,7 +73,7 @@ gnu:ice-ocean-nolibs:
7373
- time tar zxf $CACHE_DIR/tests_$CI_PIPELINE_ID.tgz && cd tests
7474
- make -f MRS/Makefile.build build/gnu/env && cd build/gnu
7575
# mkdir -p build/gnu/repro/symmetric_dynamic/ocean_only && cd build/gnu/repro/symmetric_dynamic/ocean_only
76-
- ../../MOM6-examples/src/mkmf/bin/list_paths -l ../../../config_src/{coupled_driver,dynamic,ext*} ../../../src ../../MOM6-examples/src/{FMS,coupler,SIS2,icebergs,ice_param,land_null,atmos_null}
76+
- ../../MOM6-examples/src/mkmf/bin/list_paths -l ../../../config_src/{drivers/FMS_cap,memory/dynamic_nonsymmetric,infra/FMS1,ext*} ../../../src ../../MOM6-examples/src/{FMS,coupler,SIS2,icebergs,ice_param,land_null,atmos_null}
7777
- sed -i '/FMS\/.*\/test_/d' path_names
7878
- ../../MOM6-examples/src/mkmf/bin/mkmf -t ../../MOM6-examples/src/mkmf/templates/ncrc-gnu.mk -p MOM6 -c"-Duse_libMPI -Duse_netCDF -D_USE_LEGACY_LAND_ -Duse_AM3_physics" path_names
7979
- time (source ./env ; make NETCDF=3 REPRO=1 MOM6 -s -j)
@@ -117,11 +117,36 @@ run:
117117
- time tar zxf $CACHE_DIR/build-pgi-repro-$CI_PIPELINE_ID.tgz
118118
# time tar zxf $CACHE_DIR/build-gnu-debug-$CI_PIPELINE_ID.tgz
119119
- (echo '#!/bin/tcsh';echo 'make -f MRS/Makefile.tests all') > job.sh
120-
- sbatch --clusters=c3,c4 --nodes=29 --time=0:34:00 --account=gfdl_o --qos=debug --job-name=mom6_regressions --output=log.$CI_PIPELINE_ID --wait job.sh
120+
- sbatch --clusters=c3,c4 --nodes=29 --time=0:34:00 --account=gfdl_o --qos=debug --job-name=mom6_regressions --output=log.$CI_PIPELINE_ID --wait job.sh || MJOB_RETURN_STATE=Fail
121121
- cat log.$CI_PIPELINE_ID
122+
- test -z "$MJOB_RETURN_STATE"
122123
- test -f restart_results_gnu.tar.gz
123124
- time tar zvcf $CACHE_DIR/results-$CI_PIPELINE_ID.tgz *.tar.gz
124125

126+
gnu.testing:
127+
stage: run
128+
tags:
129+
- ncrc4
130+
script:
131+
- cd .testing
132+
- module unload PrgEnv-pgi PrgEnv-intel PrgEnv-gnu darshan ; module load PrgEnv-gnu ; module unload netcdf gcc ; module load gcc/7.3.0 cray-hdf5 cray-netcdf
133+
- make work/local-env
134+
- make -s -j
135+
- (echo '#!/bin/bash';echo '. ./work/local-env/bin/activate';echo 'make MPIRUN="srun -mblock --exclusive" test -s -j') > job.sh
136+
- sbatch --clusters=c3,c4 --nodes=5 --time=0:05:00 --account=gfdl_o --qos=debug --job-name=MOM6.gnu.testing --output=log.$CI_PIPELINE_ID --wait job.sh || cat log.$CI_PIPELINE_ID && make test
137+
138+
intel.testing:
139+
stage: run
140+
tags:
141+
- ncrc4
142+
script:
143+
- cd .testing
144+
- module unload PrgEnv-pgi PrgEnv-intel PrgEnv-gnu darshan; module load PrgEnv-intel; module unload netcdf intel; module load intel/18.0.6.288 cray-hdf5 cray-netcdf
145+
- make work/local-env
146+
- make -s -j
147+
- (echo '#!/bin/bash';echo '. ./work/local-env/bin/activate';echo 'make MPIRUN="srun -mblock --exclusive" test -s -j') > job.sh
148+
- sbatch --clusters=c3,c4 --nodes=5 --time=0:05:00 --account=gfdl_o --qos=debug --job-name=MOM6.gnu.testing --output=log.$CI_PIPELINE_ID --wait job.sh || cat log.$CI_PIPELINE_ID && make test
149+
125150
# Tests
126151
gnu:non-symmetric:
127152
stage: tests

.readthedocs.yml

+12-7
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,16 @@
1-
# don't build extra formats (like HTML zip)
2-
formats:
3-
- none
1+
version: 2
42

5-
# path to pip requirements file to bring in
6-
# doxygen extensions
7-
requirements_file: docs/requirements.txt
3+
# Extra formats
4+
# PDF generation is failing for now; disabled on 2020-12-02
5+
#formats:
6+
# - pdf
7+
8+
# Build documentation
9+
sphinx:
10+
configuration: docs/conf.py
811

912
python:
1013
# make sure we're using Python 3
11-
version: 3.5
14+
version: 3
15+
install:
16+
- requirements: docs/requirements.txt

0 commit comments

Comments
 (0)