...
...
...
...
...
...
...
...
...
Software Requirements
Fortran 90/95 and C compiler
MPI or OpenMP libraries
netCDF4 library linked with HDF5 and zip libraries and extended by the Fortran netCDF package (The netCDF4 package comes with the programs ncdump and nccopy)
UNIX utilities: make, ksh, uname, sed, awk, wget, etc.
For post-processing: Climate Data Operators (CDO) and netCDF Operators (NCO)
...
Info |
---|
SPICE CCLM_SP uses netCDF I/O of ICONCOSMO-CLM |
Create an ICON Binary
The ICON source code does not come with SPICE because it is not distributed by the CLM-Community. Copy the latest ICON source code from the ICON download page to your working directory. If you do not yet have access, i.e. no private license, go to the License page first.
Info |
---|
How to adopt and compile ICON on your computing system is not part of the SPICE documentation. Please read the ICON documentations on how to build a binary. |
...
The starter package is written for the HRLE-4 Levante at DKRZ. Additional changes need to be applied for unsage on other machines. At DKRZ the Simple Linux Utility for Resource Management SLURM is installed.
Code Block | ||
---|---|---|
| ||
$module tarload intel-xzvf icon-2.6.2.2.tar.gz $ cd icon-2.6.2.2 $ mkdir build $ cd build $ ../config/clm/mistral.intel-17.0.6 --enable-openmp --disable-coupling --disable-ocean --disable-jsbach --enable-mixed-precision $ make -j 8 |
When successful, there should be now an icon
binary in the bin
directory.
In order to use the ECRAD radiation scheme, configure as follows
Code Block | ||
---|---|---|
| ||
$ ../config/clm/mistral.intel-17.0.6_ecrad --enable-openmp --disable-coupling --disable-ocean --disable-jsbach --enable-ecrad --enable-mixed-precision |
Install SPICE
1 Get the source code
...
oneapi-compilers/2022.0.1-gcc-11.2.0
module load openmpi/4.1.2-intel-2021.5.0 |
Unpack and Configure
1. Copy the starter package from 🔑 Downloads.
2. Unpack the starter package:
Code Block | ||
---|---|---|
| ||
$ tar -xvfxzvf spicecclm-sp-v15.0.tar.gztgz $ cdmv spicecclm-sp-v15.0 $ SPDIR=$PWD # used as a shortcut in the following |
2 Get supplementary data
...
yourpath/cclm-sp |
yourpath/cclm-sp
is named SPDIR from here on.
3. Copy and unpack the supplementary data files for testing the starter package (the program wget needs to be installed on your system)
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}$SPDIR/data $ ./get_spicesp_rcmext.sh |
A directory rcm
is created holding the necessary data to run the ICON-CLM test experiment.
3 Configure SPICE and run the test examples
...
title | Configuration at DKRZ or DWD |
---|
Call the script config.sh
at DKRZ like so
...
language | bash |
---|
...
4. Change to the directory $SPDIR/configure_scripts
...
5. Adjust the settings in the file system_settings
to your computer system
6. Type the following command to create a default test experiment
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}/configure_scripts
$ ./config.sh -s dwdThis will create two directories including the basic scripts. You find them under Run the test examplesThere are two tests, one for testing ICON with GCM or reanalysis data as initial and boundary conditions ( |
this first compiles the necessary cfu program and the fortran-csv-lib, and then creates the test experiments ${SPDIR}/chain/
...
gcm2cclm/sp001
...
and
...
${SPDIR}/chain/
...
Before you start the experiment look for the following environment variables in the job_settings
of sp001 and sp002 file and adopt them to your needs.
Code Block | ||
---|---|---|
| ||
PROJECT_ACCOUNT= # your project account
EMAIL_ADDRESS= # your email address if you want to get information when your job crashes or finishes
BINARY_ICON= # ICON executable including full path
ECRADDIR= # path to the ECRAD data directory, if you plan to use the ECRAD radiation scheme |
Info | |||||
---|---|---|---|---|---|
If you are not running the tests at DKRZ: Adopt the input directory of the ERAInterim data
and probably the de-tar part in prep.job.sh. |
...
cclm2cclm/sp002
.
or, if you want to create a default experiment including add-ons:
Code Block | |||||
---|---|---|---|---|---|
| |||||
$ cd ${SPDIR}/chain/gcm2icon/sp001
$ ./subchain startThis experiment is a two month simulation, 50 km / Europe / driven bei ERAInterim After successful completion start the second one:
This experiment is a two month simulation, 3km / region around Hamburg / driven by ICON output of | |||||
Expand | |||||
| |||||
3.1 Create the supplemental programs a. Create the fortran library |
Compile
The source code for INT2LM, CCLM, and the auxiliary program packages CFU and fortran-csv-lib need to be compiled for running a simulation with the regional climate model. INT2LM and CCLM need to be compiled by yourself. CFU and fortran-csv-lib are automatically compiled when you run the config.sh
script.
Compiler options are stored in the file Fopts for each program. You need to set the appropriate compiler options for your computer system.
Compile INT2LM
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}$SPDIR/src/fortran-csv-lib $ cp LOCAL/Fopts.dkrz FoptsAdopt the Fopts file to your system and typeint2lm |
Open the Fopts script with any text editor and change the Fortran options according to your computer platform. Compile INT2LM:
Code Block | |||||
---|---|---|---|---|---|
| |||||
$ make After successful compilation you find the b. Create the |
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}/src/cfu
$ cp LOCAL/Fopts.dkrz Fopts |
Fopts
file to your system and typeIn case of problems, try module unload python3
before the make-command (conda might have installed Fortran and destroyed the Intel-Fortran). If compilation is successful an executable $SPDIR/src/int2lm/bin/int2lm.exe
is created.
You may try to perform a parallel make by typing:
Code Block | ||
---|---|---|
| ||
$ make After successful compilation you find the c. Create additional conversion programsThe programs are used to convert COSMO-CLM caf-files to ICON-CLM compatible caf-file ( Fopts file in the directory LOCAL and copy it to the base directory of libcsv (here we choose Fopts.dkrz as an example): -j N |
this results in a much faster compilation. Replace N
by the number of requested processors.
Compile CCLM
Code Block | |||||
---|---|---|---|---|---|
| |||||
$ cd ${SPDIR}$SPDIR/src/utils $ cp LOCAL/Fopts.dkrz Fopts Adopt the
After successful compilation you find the executables 3.2 Configure SPICE on your computing systemIf you intent not to run ICON-CLM at DKRZ or DWD you have to perform some adoptions. First, find out which batch system comes nearest to your system. DKRZ uses SLURM (i.e. SBATCH commands) and DWD uses the Portable Batch Commands (i.e. PBS commands). Lets suppose as an example in the following that you use SLURM on your computing system and therefore you use "dkrz" as a template. a. Change into the configure_scripts directorycclm |
Open the Fopts script with any text editor and change the Fortran options according to your computer platform. The Makefile might be edited for setting the right MACHINE (e.g., levante.atos.local). Compile CCLM:
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}/configure_scriptsb. Adopt the dkrz part in the config.sh scriptmake |
If compilation is successful an executable $SPDIR/src/cclm/bin/cclm.exe
is created.
You may try to perform a parallel make by typing:
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}/configure_scripts
$ ./config.sh -s dkrzThis will create two directories including the basic scripts. You find them under ${SPDIR}/chain/gcm2icon/sp001 . make -j N |
this results in a much faster compilation. Replace N
by the number of requested processors.
Run the test examples
There are two tests, one for testing
...
CCLM with GCM or reanalysis data as initial and boundary conditions (${SPDIR}/chain/
...
gcm2cclm/sp001) and one for testing
...
CCLM with coarse grid
...
CCLM data as initial and boundary conditions (${SPDIR}/chain/
...
cclm2cclm/sp002). Actually, sp001 creates the necessary input data for sp002.
SP001
is a two month simulation, 50 km / Europe / driven bei ERAInterim
SP002
This experiment is a two month simulation, 3km / region around Hamburg / driven by ICON output of sp001
.
Before you start the experiment look for the following environment variables in the job_
...
settings of sp001 and sp002 file and adapt them to your needs.
Code Block | |||||
---|---|---|---|---|---|
| |||||
PROJECT_ACCOUNT= # your project account
EMAIL_ADDRESS= # your email address if you want to get information when your job crashes or finishes
BINARY_ICON= # ICON executable including full path
ECRADDIR= # path to the ECRAD data directory, if you plan to use the ECRAD radiation schemeAdopt the input directory of the ERAInterim data
|
Now you should be ready to start the first experiment:
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}/chain/ gcm2icongcm2cclm/sp001 $ ./subchain startIn SPICE the |
This experiment is a two month simulation, 50 km / Europe / driven by ERAInterim
The scripts are called in the order prep.job.sh,
...
int2lm.job.sh,
...
cclm.job.sh, arch.job.sh, post.job.sh. If your job crashes in one of the scripts you do not have to run all the successful scripts again, but can start this script again after you made the corrections by submitting the appropriate command from the following list:
Code Block | ||
---|---|---|
| ||
$ ./subchain prep subchain prep $ ./subchain conv2icon $ ./subchainicon cclm noprep $ ./subchain arch $ ./subchain post |
After successful completion of
...
the sp001
experiment adapt the scripts in
...
sp002
and start this experiment:
Code Block | ||
---|---|---|
| ||
$ cd ${SPDIR}/chain/ icon2iconcclm2cclm/sp002 $ ./subchain start |
This experiment is a two-month simulation, 2 km resolution, around Hamburg, driven by the results from the sp001
experiment.