You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 12 Next »

This page contains a guide to the building and running a Single-Column Model (SCM), which is derived from OpenIFS 48r1.



Installing and building the SCM

The SCM source code is extracted and installed alongside OpenIFS. Thus, if not done already, to install the SCM please follow the instructions detailed in Getting started.

In short the once the source code is extracted and installed from https://sites.ecmwf.int/openifs/openifs-data/src/48r1/openifs-48r1.tar.gz, then the code can be built using the following

# load the OpenIFS and SCM environment variables
source /path/to/file/location/oifs-config.edit_me.sh
# using our installation example:
# source $HOME/openifs-48r1.1/oifs-config.edit_me.sh

# change to the home directory for OpenIFS and SCM 
cd $OIFS_HOME
# Use the openifs-test.sh script to build and automatically test OpenIFS and the SCM
$OIFS_TEST/openifs-test.sh -cbt

The above commands assume that the base prerequisites for OpenIFS and the SCM are installed on the system. This is the case on the ECMWF Atos Sequana XH2000 HPC facility (hpc2020) but on other systems, the prerequisites need to be installed. A description/recipe for the prerequisites can be found on the Getting started on docker page.

Once successful, the above commands will build double and single precision SCM executables (MASTER_scm.DP and MASTER_scm.SP, respectively), which are used to run the SCM derived from OpenIFS. The executables are located in  $OIFS_HOME/build/bin.

  • The location and name of the executable for the SCM is defined in the platform configuration file (oifs-config.edit_me.sh) as $SCM_EXEC

Download and extraction of the OpenIFS 48r1 sources tarball is only required if a user has not previously done this for a general OpenIFS install.

If a user has already downloaded the OpenIFS package to install the 3D model, there is no need to extract the package again, since the SCM is packaged with OpenIFS. 

Setting up the SCM for a test-case

Before the SCM can be run, it is necessary to

  • load the SCM environment variables by source the oifs-config.edit_me.sh
  • obtain and extract the SCM test-case package

Load SCM environment variables

As with OpenIFS, the operation of the SCM depends on some environment variables being loaded. The recommended way to load is by sourcing the oifs-config.edit_me.sh file, i.e., 

source /path/to/file/location/oifs-config.edit_me.sh
# using our installation example:
# source $HOME/openifs-48r1.1/oifs-config.edit_me.sh

This will load all the OpenIFS and SCM environment variables. The OpenIFS variables are described in Getting started, so here we focus on the SCM variables, which are defined in oifs-config.edit_me.sh, with comments, as shown below

#---Single-column model environment variables
#---Test case list, which can contain DYCOMS, BOMEX AND TWPICE
export SCM_CASE_LIST="BOMEX TWPICE"

#---SCM experiment name, please set to anything that is relevant
#---to your test
export SCM_EXPT_NAME="ref-oifs-scm-dp"

#---Path to the executable for the SCM. This is the
#---default path for the exe, produced by openifs-test.sh.
#---DP means double precision. To run single precision change
#---DP to SP
export SCM_EXEC="${OIFS_HOME}/build/bin/MASTER_scm.DP"

#---Default assumed paths, only change if you know what you are doing
export SCM_TEST="${OIFS_HOME}/scripts/scm"
export SCM_RUNDIR="${OIFS_EXPT}/scm_openifs/48r1/scm-projects/ref48r1"
export SCM_PROJDIR="${OIFS_EXPT}/scm_openifs/48r1/scm-projects"
export SCM_VERSIONDIR="${OIFS_EXPT}/scm_openifs/48r1"

It is worth noting that the SCM environment variables depend on the OIFS_HOME  and OIFS_EXPT, which are also defined by sourcing oifs-config.edit_me.sh. In the above there is the assumption that the SCM executable exists in ${OIFS_HOME}/build/bin and that the SCM test case package exists in OIFS_EXPT.

Extract SCM test-case package

In a similar fashion to the OpenIFS package and the experiment data, the SCM test-case package can be download from https://sites.ecmwf.int/openifs/openifs-data/scm/48r1/scm_openifs_48r1.1.tar.gz. Please note that access to this web site is restricted to registered OpenIFS users, i.e. your personal ECMWF account must have been added to the OpenIFS user policy.

In the example below we assume that the SCM package shall be installed in the $OIFS_EXPT directory, where the $OIFS_EXPT is the OpenIFS experiment directory, which is defined oifs-config.edit_me.sh, and that wget utility is available for convenient download: 

cd $OIFS_EXPT
wget https://sites.ecmwf.int/openifs/openifs-data/scm/48r1/scm_openifs_48r1.1.tar.gz
tar -xvzf scm_openifs_48r1.tar.gz

The untarred SCM package is small, ~45 Mb and data produced by a standard individual SCM simulation is also low. However, if I user is planning to perform many simulations and store the data, which is often the case, the disk space usage can become large. If this is the plan, then a user may need to consider installing the SCM test-case package on a larger disk area than HOME

Once installed it is important to ensure that the $OIFS_EXPT is set to the directory that scm_openifs has been installed in. For example, in the template oifs-config.edit_me.sh, $OIFS_EXPT=${HOME}/openifs-expt . In this scenario, the directory scm_openifs needs to be in $OIFS_EXPT or `${HOME}/openifs-expt/.  

Run the SCM

Once the above has been completed, it is necessary to select which test-case to run. There is a choice of the following 3 testcases

  • DYCOMS - marine stratocumulus case
  • BOMEX - trade-wind cumulus case 
  • TWPICE - A multi-day deep convective case

The case can be set in the oifs-config.edit_me.sh, using SCM_CASE_LIST 

SCM_CASE_LIST="BOMEX TWPICE DYCOMS"

The above will run all the cases. If making this change in oifs-config.edit_me.sh, remember to source the file once the change has been made.

Once the cases are set, then do the following to run the SCM

cd $OIFS_HOME
$SCM_TEST/callscm

This will run all the cases defined in SCM_CASE_LIST and write the output to $SCM_RUNDIR

  • No labels