Skip to content

Forced KPP simulations

Annette Osprey edited this page Jan 4, 2024 · 1 revision

Forced KPP simulations

Instructions for running a 10-day simulation across the Maritime Continent on ARCHER2, using OpenMP parallelism.

Updated from https://www.notion.so/Forced-KPP-simulations

Extract the code

On ARCHER2, clone the github repository:

git clone https://github.com/NCAS-CMS/KPP_ocean.git
cd KPP_ocean

Checkout the r207_archer2 branch, which includes required fixes:

git fetch 
git switch dev/annette/r207_archer2

Set up the parameter.inc file

Copy in the TerraMarris file, and symlink it:

cp /work/y07/shared/umshared/kpp/terramaris_forced/parameter.inc.tm_2km-regrid15km . 
ln -sf parameter.inc.tm_2km-regrid15km parameter.inc

Build the model

Load NetCDF modules:

module load cray-hdf5
module load cray-netcdf

Compile:

make -f Makefile.linux_cray-archer2 forced

Set up run directory

Make a directory to run the model from (e.g run_KPP_ocean_TM):

cd ../
mkdir run_KPP_ocean_TM
cd run_KPP_ocean_TM

Copy in the TerraMarris ancillary files and namelists:

cp /work/y07/shared/umshared/kpp/terramaris_forced/* . 

Edit the slurm submission script

Edit KPPocean.slurm to set your project code, e.g.:

#SBATCH --account=n02-cms

Set the path to the KPP executable you built, e.g.:

export KPP_EXEC=/work/n02/n02/annette/KPP/KPP_ocean/KPP_ocean

Submit the batch job

sbatch KPPocean.slurm