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

doc(hpc): update HPC README #1294

Closed
Closed
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
52 changes: 50 additions & 2 deletions .hpc/BUILD.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

# Building MODFLOW 6 on HPC systems

## SLURM job
Expand All @@ -15,6 +16,53 @@ export PKG_CONFIG_PATH=/opt/cray/pe/mpt/7.7.19/gni/mpich-intel/16.0/lib/pkgconfi

srun --reservation=dev --account=impd --pty bash

meson setup builddir -Ddebug=false --prefix=$(pwd) --libdir=bin -Dcray=true -Ddebug=false --wipe
meson setup builddir -Ddebug=false --prefix=$(pwd) --libdir=bin --bindir=bin -Dcray=true -Ddebug=false --wipe
meson install -C builddir
```
```

# Installing a new version of MODFLOW 6 on HPC systems


After building the new version (`6.x.x`) of MODFLOW 6 using a SLURM or interactive job you will need to install the new version and create a new module file.

## Install a new version of MODFLOW 6

Create a directory for the new version in `/home/software/denali/contrib/impd/apps/modflow/`

Since MODFLOW 6 is currently only being compiled with INTEL (version 19.1.0.166), make the following subdirectories in the `/home/software/denali/contrib/impd/apps/modflow/6.x.x` directory you just created.

1. `/INTEL/19.1.0.166/bin`
2. `/INTEL/19.1.0.166/lib`

Copy `mf6` and `zbud6` to the `/INTEL/19.1.0.166/bin` and `libmf6.so` to the `/INTEL/19.1.0.166/lib` subdirectories using

```
rsync ..\bin\mf6 /home/software/denali/contrib/impd/apps/modflow/6.x.x//INTEL/19.1.0.166/bin/
```

```
rsync ..\bin\zbud6 /home/software/denali/contrib/impd/apps/modflow/6.x.x//INTEL/19.1.0.166/bin/
```

```
rsync ..\bin\libmf6.so /home/software/denali/contrib/impd/apps/modflow/6.x.x//INTEL/19.1.0.166/lib/
```
## Create a module file for a new version of MODFLOW 6

Make a copy of an existing module file using
```
rsync /home/software/denali/contrib/impd/modulefiles/modflow/6.4.2 /home/software/denali/contrib/impd/modulefiles/modflow/6.x.x
```

Edit `product_version` in the new module file from `6.4.2` to `6.x.x`.


## Accessing a new MODFLOW 6 module file

Until a system administrator makes the module file for the new version of MODFLOW 6 generally available the following commands can be used in a slurm script or an interactive job

```
module use --append /home/software/denali/contrib/impd/modulefiles
module load modflow/6.x.x

```
2 changes: 1 addition & 1 deletion .hpc/cray-meson-build.slurm.batch
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ BINDIR=$MODFLOW6ROOT/bin
TESTDIR=$MODFLOW6ROOT/.mf6minsim

# build MODFLOW 6
CC=cc CXX=CC F77=ftn F90=ftn FC=ftn meson setup builddir --prefix=$(pwd) --libdir=bin -Dcray=true -Ddebug=false --wipe
CC=cc CXX=CC F77=ftn F90=ftn FC=ftn meson setup builddir --prefix=$(pwd) --bindir=bin --libdir=bin -Dcray=true -Ddebug=false --wipe
meson install -C builddir

# test MODFLOW 6 build
Expand Down
2 changes: 1 addition & 1 deletion autotest/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def test_cli_version():
)
print(version)
v_split = version.split(".")
assert len(v_split) == 3
assert len(v_split) in (3, 4)
assert all(s.isdigit() for s in v_split[:2])
sol = split_nonnumeric(v_split[2])
assert sol[0].isdigit()
6 changes: 3 additions & 3 deletions doc/version.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

major = 6
minor = 4
micro = 2
label = '+'
micro = 3
label = 'dev0'
__version__ = '{:d}.{:d}.{:d}'.format(major, minor, micro)
if label:
__version__ += '{}{}'.format(__version__, label)
__version__ += '{}.{}'.format(__version__, label)
2 changes: 1 addition & 1 deletion doc/version.tex
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
\newcommand{\modflowversion}{mf6.4.2+}
\newcommand{\modflowversion}{mf6.4.3.dev0}
\newcommand{\modflowdate}{June 29, 2023}
\newcommand{\currentmodflowversion}{Version \modflowversion---\modflowdate}
2 changes: 1 addition & 1 deletion meson.build
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
project(
'MODFLOW 6',
'fortran',
version: '6.4.2+',
version: '6.4.3.dev0',
license: 'CC0',
meson_version: '>= 1.1.0',
default_options : [
Expand Down
2 changes: 1 addition & 1 deletion src/Utilities/version.f90
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ module VersionModule
public
! -- modflow 6 version
integer(I4B), parameter :: IDEVELOPMODE = 1
character(len=*), parameter :: VERSIONNUMBER = '6.4.2+'
character(len=*), parameter :: VERSIONNUMBER = '6.4.3.dev0'
character(len=*), parameter :: VERSIONTAG = ' (preliminary) 06/29/2023'
character(len=40), parameter :: VERSION = VERSIONNUMBER//VERSIONTAG
character(len=2), parameter :: MFVNAM = ' 6'
Expand Down
6 changes: 3 additions & 3 deletions version.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

major = 6
minor = 4
micro = 2
label = '+'
micro = 3
label = 'dev0'
__version__ = '{:d}.{:d}.{:d}'.format(major, minor, micro)
if label:
__version__ += '{}{}'.format(__version__, label)
__version__ += '{}.{}'.format(__version__, label)