Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update module loads for Alliance StdEnv/2023 #62

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 10 additions & 8 deletions salishsea_cmd/run.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@
import nemo_cmd
import yaml
from nemo_cmd.prepare import get_n_processors, get_run_desc_value, load_run_desc

from salishsea_cmd import api

log = logging.getLogger(__name__)
Expand Down Expand Up @@ -944,14 +943,16 @@ def _modules():
modules = {
"beluga": textwrap.dedent(
"""\
module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1
"""
),
"cedar": textwrap.dedent(
"""\
module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1
"""
),
"delta": textwrap.dedent(
Expand All @@ -961,8 +962,9 @@ def _modules():
),
"graham": textwrap.dedent(
"""\
module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1
"""
),
"omega": textwrap.dedent(
Expand Down Expand Up @@ -1127,7 +1129,7 @@ def _execute(
# variants
script += textwrap.dedent(
"""\
module load nco/4.9.5
module load nco/5.1.7
"""
)
script += textwrap.dedent(
Expand Down
31 changes: 17 additions & 14 deletions tests/test_run.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,8 @@
import cliff.app
import f90nml
import pytest
import yaml

import salishsea_cmd.run
import yaml


@pytest.fixture
Expand Down Expand Up @@ -1981,8 +1980,9 @@ def test_beluga(self, account, deflate):
"""\
GATHER="${HOME}/.local/bin/salishsea gather"

module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1

mkdir -p ${RESULTS_DIR}
cd ${WORK_DIR}
Expand All @@ -2003,7 +2003,7 @@ def test_beluga(self, account, deflate):
"""\

echo "Results deflation started at $(date)"
module load nco/4.9.5
module load nco/5.1.7
${DEFLATE} *_ptrc_T*.nc *_prod_T*.nc *_carp_T*.nc *_grid_[TUVW]*.nc \\
*_turb_T*.nc *_dia[12n]_T*.nc FVCOM*.nc Slab_[UV]*.nc *_mtrc_T*.nc \\
--jobs 4 --debug
Expand Down Expand Up @@ -2087,8 +2087,9 @@ def test_cedar(self, cpu_arch, nodes, cores_per_node, mem, deflate):
"""\
GATHER="${HOME}/.local/bin/salishsea gather"

module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1

mkdir -p ${RESULTS_DIR}
cd ${WORK_DIR}
Expand All @@ -2109,7 +2110,7 @@ def test_cedar(self, cpu_arch, nodes, cores_per_node, mem, deflate):
"""\

echo "Results deflation started at $(date)"
module load nco/4.9.5
module load nco/5.1.7
${DEFLATE} *_ptrc_T*.nc *_prod_T*.nc *_carp_T*.nc *_grid_[TUVW]*.nc \\
*_turb_T*.nc *_dia[12n]_T*.nc FVCOM*.nc Slab_[UV]*.nc *_mtrc_T*.nc \\
--jobs 4 --debug
Expand Down Expand Up @@ -2191,8 +2192,9 @@ def test_graham(self, account, deflate):
"""\
GATHER="${HOME}/.local/bin/salishsea gather"

module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1

mkdir -p ${RESULTS_DIR}
cd ${WORK_DIR}
Expand All @@ -2213,7 +2215,7 @@ def test_graham(self, account, deflate):
"""\

echo "Results deflation started at $(date)"
module load nco/4.9.5
module load nco/5.1.7
${DEFLATE} *_ptrc_T*.nc *_prod_T*.nc *_carp_T*.nc *_grid_[TUVW]*.nc \\
*_turb_T*.nc *_dia[12n]_T*.nc FVCOM*.nc Slab_[UV]*.nc *_mtrc_T*.nc \\
--jobs 4 --debug
Expand Down Expand Up @@ -3144,8 +3146,9 @@ def test_beluga_cedar_graham(self, system):
modules = salishsea_cmd.run._modules()
expected = textwrap.dedent(
"""\
module load StdEnv/2020
module load netcdf-fortran-mpi/4.6.0
module load StdEnv/2023
module load intel/2023.2.1
module load netcdf-fortran-mpi/4.6.1
"""
)
assert modules == expected
Expand Down Expand Up @@ -3268,7 +3271,7 @@ def test_execute_with_deflate(self, system, mpirun_cmd):
if system in {"beluga", "cedar", "graham"}:
expected += textwrap.dedent(
"""\
module load nco/4.9.5
module load nco/5.1.7
"""
)
expected += textwrap.dedent(
Expand Down