Christopher Bull bio photo

Christopher Bull

Aspiring Oceanographer at Northumbria University. Big data python enthusiast. Outdoor adventurer.

Email Twitter Github

We take the steps of building a regional Ross Sea configuration using NEMO 4.2 on ARCHER2. This post is written by TiPACCs PDRA Alethea Mountford (alethea.mountford@northumbria.ac.uk), thanks Alethea!

Pre-requisites:

Suggested reading:

Create ROSS025 configuration

We can make a new ROSS025 configuration using WED025 as a reference (-r), as below

./makenemo -n ROSS025 -r WED025 -m X86_ARCHER2-Cray_4.2 -j 8

OR create and compile a new configuration from scratch

export CONFIG='ROSS025'
echo$CONFIG OCE ICE” >> cfgs/ref_cfgs.txt
mkdir cfgs/$CONFIG
echo “bld::tool::fppkeys key_xios key_si3 key_qco key_isf key_nosignedzdero” > cfgs/${CONFIG}/cpp_${CONFIG}.fcm
./makenemo -r ${CONFIG} -m X86_ARCHER2-Cray_4.2 -j 8

And check compile was successful

ls -al ${CONFIG}/BLD/bin/nemo.exe

Pre-processing tools (Nico’s regional tools)

git clone https://github.com/nicojourdain/BUILD_CONFIG_NEMO.git
cd GDW-Fortran/test
vi makefile # check the FC and NETCDF_INC variables

make
./gsw_check # no need to worry about *all* working

cd ../..

Back in the main BUILD_CONFIG_NEMO directory, compile all of the pre-processing tools

vi compile_ALL.sh # check the FC, NETCDF_INC and NETCDF_LIB variables

./compile_ALL.sh

Create a new namelist for the regional configuration (e.g. namelist_ROSS025) and link it to the pre-processing namelist that is read by the processing tools

vi namelist_${CONFIG}
ln -s -v namelist_${CONFIG} namelist_pre

Make sure to adapt the regional namelist (i.e. specify the domain bounds in order to cover the desired region).

The exact domain bounds for the ROSS025 configuration are specified as

! Choose the domain bounds on global grid that is extracted (e.g. eORCA12; WARNING: will be rounded to closest point of the coarse grid if ln_coarse_bdy = true) :
nn_imin_extract       =  199
nn_imax_extract       =  821
nn_jmin_extract       =    2
nn_jmax_extract       =  452

in the namelist_pre.

It is worth noting that all parent files used for the creation of the regional configuration must be the same grid size. Parent files were provided by Pierre Mathiot (pierre.mathiot@univ-grenoble-alpes.fr – thanks Pierre!) either through personal communication (namely the BDY files) or sourced from his global eORCA025 input files. Global files were cropped as follows

ncks -L 1 --cnk_dmn time_counter,1 --cnk_dmn y,200 --cnk_dmn x,200 --cnk_dmn nav_lev,200 -d y,0,500 source_file.nc output_file.nc

Create the bathymetry and coordinates files

This requires filling in the &general and &griddata sections of your namelist_ROSS025 file with the parent bathymetry/coordinate files and specifying the domain bounds

./extract_bathy_coord

Which should create your bathy_meter_${CONFIG}.nc and coordinate_${CONFIG}.nc files

Create the domain_cfg and mesh_mask files

Compile the NEMO DOMAINcfg tool in NEMO/tools/DOMAINcfg and REBUILD_NEMO tool in NEMO/tools/REBUILD_NEMO, i.e.

./maketools -m X86_ARCHER2-Cray_4.2 -n DOMAINcfg
./maketools -m X86_ARCHER2-Cray_4.2 -n REBUILD_NEMO

Note, that this needs to be done in the main NEMO directory (the same as when compiling NEMO itself using ./makenemo)

Create the initial state and atmospheric forcing files

Refer to the detailed instructions written by Nico Jourdain and Chris Bull using the BUILD_CONFIG_NEMO pre-processing tools

Run NEMO

With all of the files in place and the relevant .xml and namelist files, you should be ready to run NEMO. See Building and Running NEMO4 on ARCHER2 full system for a refresher on run scripts (but remember to use X86_ARCHER-Cray_4.2 when compiling and xios_trunk)

In category: nemo4