wiki:Documentation/UserGuide/InstallingORCHIDEEBasic

Version 17 (modified by jgipsl, 2 years ago) (diff)

--

How to install ORCHIDEE with modipsl and libIGCM for offline use

Here I describe how to install a version of ORCHIDEE created after the re-organization of driver sources, this means all versions of ORCHIDEE containg the src_driver directory. If the branch or personal version you want to use contains both ORCHIDEE and ORCHIDEE_OL directories, then you can extract using the script recup_my_ORCHIDEE. Otherwise if you have only ORCHIDEE directory, extract using the script model as below. The configuration files will then be the latest trunk version.

NEW!!! This page has been updated to use the compiling method with fcm. If you want to know more about compiling ORCHIDEE, see HowTo/CompileMethods.

ORCHIDEE trunk version

To extract and compile the latest trunk version of ORCHIDEE and configuration files for offline simulations (note that for obelix you may need to load the openmpi library first with the command 'module load openmpi') :

svn co http://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk modipsl
cd modipsl/util
./model ORCHIDEE_trunk
cd ../config/ORCHIDEE_OL
gmake

Specific revision on the trunk

It is possible to define a specific revision on the trunk before extraction. The file util/mod.def describes the contents for all predefined configurations. For example the content in configuration ORCHIDEE_trunk are ORCHIDEE, XIOS, IOIPSL, libIGCM and configuration directory ORCHIDEE_OL. All these components have a specific revision number set in mod.def or HEAD which means the latest revision on the version.

Change in mod.def before extracting the model by ./model ORCHIDEE_trunk to have the revision XXX on trunk ORCHIDEE:

#-C- ORCHIDEE_trunk  trunk/ORCHIDEE                           HEAD    14 ORCHIDEE           modeles
#-C- ORCHIDEE_trunk  trunk/ORCHIDEE_OL                        HEAD    14 ORCHIDEE_OL        config

into

#-C- ORCHIDEE_trunk  trunk/ORCHIDEE                           XXX     14 ORCHIDEE           modeles
#-C- ORCHIDEE_trunk  trunk/ORCHIDEE_OL                        HEAD    14 ORCHIDEE_OL        config

Note that for most cases you do not need to change ORCHIDEE_OL revision. This directory contains the configurations files to run with libIGCM. Sometimes there are incoherences between older revisions of ORCHIDEE and the latest version of the configuration but in most cases it is recommended to take the latest version of the configuration.

It is also possible to change the revision of ORCHIDEE after the configuration has been extracted. In that case, go to modeles/ORCHIDEE directory and update using svn:

cd modipsl/modeles/ORCHIDEE
svn info                                       # To know which version you extracted
svn stat                                       # To know if you have any local modifications
svn update -r XXX

Branch or other version on svn

Do as for the trunk but modify the file mod.def to extract a specific version of ORCHIDEE before launching the command ./model ORCHIDEE_trunk. The file mod.def specifies all components to be extracted with the script model for each configuration predefined.

Do first:

svn co http://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk modipsl
cd modipsl/util

Edit now the file mod.def for the line corresponding to extraction of ORCHIDEE sources for target ORCHIDEE_trunk.
Following line needs to be changed :

#-C- ORCHIDEE_trunk  trunk/ORCHIDEE                           HEAD   14 ORCHIDEE         modeles

Replace trunk/ORCHIDEE by the path to your branch or personal directory. HEAD can also be changed to a specific revision number. For example for the branch ORCHIDEE-MICT, following should be set:

#-C- ORCHIDEE_trunk  branches/ORCHIDEE-MICT/ORCHIDEE               HEAD   14 ORCHIDEE         modeles

You can also change the config/ORCHIDEE_OL folder if your branch has a specific one. For this, change also trunk/ORCHIDEE_OL on the following line in mod.def:

#-C- ORCHIDEE_trunk  trunk/ORCHIDEE_OL                        HEAD    14 ORCHIDEE_OL        config

Now continue with the extraction of the model:

./model ORCHIDEE_trunk
cd ../config/ORCHIDEE_OL
gmake

ORCHIDEE latest tag (1.9.6) or AR5 version(tag 1.9.5)

To extract and compile the latest tagged version of ORCHIDEE and configuration files for offline simulations (use ORDHIDEE_TAG for tag 1.9.6 and ORCHIDEE_SVN_AR5 for tag 1.9.5):

svn co http://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk modipsl
cd modipsl/util
./model ORCHIDEE_TAG                         # or for AR5 : ./model ORCHIDEE_SVN_AR5
cd ../modeles/ORCHIDEE_OL
gmake orchidee_ol

Optional method for a branch or other version on svn

You can also install the trunk and afterwards remove ORCHIDEE and change it to another version from svn or a local version. In this case you will keep the configuration files from the trunk version :

svn co http://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk modipsl
cd modipsl/util
./model ORCHIDEE_trunk
cd ../modeles
rm -fr ORCHIDEE
svn co svn://forge.ipsl.jussieu.fr/orchidee/branches/xxxxxxx/ORCHIDEE ORCHIDEE     # or a copy from a local version of ORCHIDEE
cd ../util ; ./ins_make      # Create makefiles
cd ../modeles/ORCHIDEE
gmake driver

NB! For old branches with fortran code in ORCHIDEE_OL directory

For exemple orchidee_FM

In the trunk and in the newer branches, the directory ORCHIDEE/src_driver contain the source code for the driver. In older versions, these files were stored in ORCHIDEE_OL directory. Therefor for these older branches, you have to extract ORCHIDEE and ORCHIDEE_OL from the branch. For running with libIGCM, we recomand to use the trunk version of the scripts in ORCHIDEE_OL. Extract the trunk/ORCHIDEE_OL and save it in ORCHIDEE_OL.trunk. In mod.def, the lines corresponding to extraction of ORCHIDEE becomes the following :

#-C- ORCHIDEE_trunk  branches/MYOLDBRANCHE/ORCHIDEE           HEAD    14 ORCHIDEE           modeles
#-C- ORCHIDEE_trunk  branches/MYOLDBRANCHE/ORCHIDEE_OL        HEAD    14 ORCHIDEE_OL        modeles
#-C- ORCHIDEE_trunk  trunk/ORCHIDEE_OL                        HEAD    14 ORCHIDEE_OL.trunk  config

Note that the compiling is different:

cd modipsl/modeles/ORCHIDEE_OL
gmake orchidee_ol
gmake teststomate
gmake forcesoil