Table of Contents |
---|
Extract the OpenIFS package
...
...
You will need approximately 4 GB of disk space for the model sources, the bundle packages, and the built model binaries.
Code Block | ||||
---|---|---|---|---|
| ||||
git clone ssh://git@git.ecmwf.int/~daha/openifs-main-git.git |
Please note that currently access to this repository is restricted to a limited number of users.
...
...
...
- Edit the script and in line 16 set the location of your $OIFS_HOME directory which is the location where you have extracted the git repository and where this script should be located.
- The usage of the script is shown with the command:
openifs-test.sh -h
- The option
-e
defines the compiler environment (intel or gnu). The default is intel.
Run the build process and the tests using the following command:
Code Block | ||||
---|---|---|---|---|
| ||||
cd $OIFS_HOME
./bin/openifs-test.sh -cbt |
Note: It is normal to see warnings during the build process.
This will build the model binaries for the selected compiler and will run the ifs-test t21 and t42 tests.
Set up the platform configuration file
You will need to set up a configuration file for your OpenIFS installation.
- This file can be located anywhere but the recommended location would be somewhere inside your $OIFS_HOME installation.
- This file sets global variables for your model installation, depending on your local system, and it will need to be "sourced" prior to running the model.
- We provide a template for this configuration file in
$OIFS_HOME/bin/oifs48r1-config.sh
. You should edit this file and update variable OIFS_HOME with your installation's path.
We recommend that you include the following command in your shell configuration file (e.g. .bashrc):
Code Block | ||||
---|---|---|---|---|
| ||||
source /path/to/configfile/oifs48r1-config.sh |
This command should also be include in any batch job scripts that are intended to run OpenIFS.
Set up a forecast experiment
Extract the example forecast experiment i4xc.tgz
into a location suitable for model experiments.
Info |
---|
Note: The experiment directory would ideally be in a different location from the earlier model installation path $OIFS_HOME. In general, you will need more disk space for experiments, depending on the model grid resolution, the duration of the forecast experiment and the output fequency of model results. |
Example:
On the ECMWF hpc2020 our model installation $OIFS_HOME will be in $HOME/openifs
and for the experiment we extract the i4xc package in $PERM. The experiment directory shall therefore be $PERM/i4xc/2016092500
.
Ensure the namelist files for the atmospheric model (fort.4) and for the wave model (wam_namelist) are found in the experiment directory.
You will need to copy two further scripts from the OpenIFS package into your experiment directory:
- oifs-run: this is a generic run script which executes the binary model program file.
- config.h: this is configuration file that determines settings for your experiment. It will be read by oifs-run.
Copy both files from $OIFS_HOME/bin into your experiment directory.
Code Block | ||||
---|---|---|---|---|
| ||||
cp i4xc.tgz $PERM
cd $PERM
tar -xvzf i4xc.tgz
cd ./i4xc/2016092500
cp $OIFS_HOME/bin/oifs-run .
cp $OIFS_HOME/bin/config.h . |
Determine experiment parameters
You should edit the atmospheric model namelist file fort.4. It contains Fortran namelists which control model settings and switches. An important switch to edit is in namelist NAMRIP the variable CSTOP. Set this to the desired length of the forecast experiment. Experiment i4xc can be run for up to 144 hours (6 days) by setting CSTOP='h144'
.
You should edit the config.h file which determines settings for this experiment. The oifs-run script will read the settings from this file. Alternatively, the settings can be passed to the oifs-run script via command line parameters, which takes precedence over the config.h settings.
Info |
---|
Note: If no config.h file is found in the experiment directory, and if also no command line parameters are provided when calling oifs-run, then oifs-run will revert to its own default values which are not appropriate. In any case you should either edit the config.h file appropriately or provide the correct command line parameters. |
The config.h file contains the following settings:
Code Block | ||
---|---|---|
| ||
OIFS_EXPID="i4xc" # your experiment ID
OIFS_NPROC=8 # the number of MPI tasks
OIFS_NTHREAD=4 # the number of OpenMP threads
OIFS_GRIDTYPE="l" # the grid type, either 'l' for linear reduced grid, or 'o' for the cubic octahedral grid
OIFS_RES="255" # the spectral grid resolution
OIFS_NAMELIST='fort.4' # the name of the atmospheric namelist file (the default is fort.4, so this line could be omitted)
OIFS_EXE="${OIFS_HOME}/build/bin/ifsMASTER.DP" # the name and location of the model binary executable
OIFS_PPROC=true # enable postprocessing of model output after the model run
OUTPUT_ROOT=$(pwd) # folder where pproc output is created (only used if OIFS_PPROC=true). In this case an output folder is created in the experiment directory.
LFORCE=false # overwrite existing symbolic links in the experiment directory
LAUNCH="" # the platform specific run command for the MPI environment (e.g. "mpirun", "srun", etc). |
Running the experiment
After all edits to namelists and config.h have been completed the model run can be started.
Depending on the available hardware experiments can either be run interactively or as a batch job.
In order to run the experiment interactively run ./oifs-run in your terminal. If no command line parameters are provided with the oifs-run command, then the values from the config.h will be used.
On the ECMWF hpc2020, running the model script interactively should be fine for lower grid resolutions up to T255L91. If the LAUNCH variable in config.h remains empty (and no --runcmd parameter is provided in the command line) then the oifs-run script will use its default launch parameters: srun -c${OIFS_NPROC} --mem=64GB --time=60
which will work fine for OIFS_NPROC=4 or 8 with experiment i4xc.
Alternatively, a job script could be used for submitting the script to the batch scheduler. An example script for the SLURM batch schedule, used on the ECMWF hpc2020 is provided here: $OIFS_HOME/bin/run.atos.sh
This script should be edited as required. The LAUNCH command here is only "srun" without any further options, as the parallel environment settings are provided through the script headers.
Postprocessing
If the OIFS_PPROC variable has been set to true (or if the --pproc command line parameter was used) then the model output in the experiment directory is further processed after completing the model run.
In this case the script ill generate a folder called output_YYYMMDD_HHMMSS with the current date and time values. This avoids modification of previous results when repeatingt he model experiment. Variable OUTPUT_ROOT in config.h determines where this folder will be created. The default location is the experiment directory.
Postprocessing groups all output fields and diagnostic into individual GRIB files with ascending forecast time step.
...