ORCHIDEE

De Wikicima
(Diferencias entre revisiones)
Saltar a: navegación, buscar
(Running the model)
(Test: let's look at Marcos Juárez, Córdoba, Argentina)
 
(No se muestran 50 ediciones intermedias realizadas por 2 usuarios)
Línea 1: Línea 1:
 
= ORCHIDEE =
 
= ORCHIDEE =
   
This manual provides the information about the land-surface model ORCHIDEE ([http://forge.ipsl.jussieu.fr/orchidee orchidee]) from ''Institute Pierre Simone Laplace'' ([https://www.ipsl.fr/en IPSL]). Its installation on the HPC of the CIMA called <code>hydra</code>
+
This manual provides the information about the land-surface model [https://orchidee.ipsl.fr/ ORCHIDEE] (technical page for [http://forge.ipsl.jussieu.fr/orchidee advanced users]) from ''Institute Pierre Simone Laplace'' ([https://www.ipsl.fr/en IPSL]). Its installation on the HPC of the CIMA called <code>hydra</code>.
   
 
= Model description =
 
= Model description =
Línea 7: Línea 7:
 
* ORCHIDEE: sechiba & stomate
 
* ORCHIDEE: sechiba & stomate
 
* Two major modes of simulations: Off-line (no feedback) / on-line (LMDZ, WRF)
 
* Two major modes of simulations: Off-line (no feedback) / on-line (LMDZ, WRF)
  +
  +
All forcing data to run ORCHIDEE is located here in CIMA's HPC:
  +
<pre>
  +
${ORforcing}=/share/DATA/ORCHIDEE/IGCM/
  +
</pre>
   
 
== Off-line atmospheric forcings ==
 
== Off-line atmospheric forcings ==
* Desdcribed here: [https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/Forcings ORforcings]
+
Desdcribed here: [https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/Forcings ORforcings]
** Atmoshperic variables required by ORCHIDEE: <code>LWdown, PSurf, Qair, Rainf, SWdown, Snowf, Tair, Wind_E, Wind_N</code>
+
** CRU-NCEP (v5.4, 0.5&deg;): mixing CRU with NCEP: <code>cruncep_halfdeg_[YYYY].nc</code> at <code>hydra</code> (taking <code>${ORforcing}=/share/ORCHIDEE/data/IGCM/SRF</code>):
+
Atmoshperic variables required by ORCHIDEE: <code>LWdown, PSurf, Qair, Rainf, SWdown, Snowf, Tair, Wind_E, Wind_N</code>
<pre>${ORforcing}/METEO/CRU-NCEP/v5.4/halfdeg</pre>
+
  +
Available data-bases in hydra:
  +
* WFDE5 CRU GPCC (v1, 0.5&deg;): mixing ERA5 CRU and GPCC: <code>WFDE5_CRU_GPCC_[YYYY].nc</code> at <code>hydra</code>:
  +
<pre>${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/</pre>
   
 
== Morphological forcings as data-base ==
 
== Morphological forcings as data-base ==
** To be interpolated to the domain of simulation (region and resolution) at the first time step (done by ORCHIDEE)
+
Installed in CIMA's HPC hydra at
** Mandatory:
+
<pre>
  +
/share/DATA/ORCHIDEE/IGCM/SRF
  +
</pre>
  +
  +
To be interpolated to the domain of simulation (region and resolution) at the first time step (done by ORCHIDEE)
  +
Mandatory:
  +
 
=== PFT map ===
 
=== PFT map ===
   
**** 13 PFT, percentage of each by grid-point (<code>maxvegetfrac</code>, see table for equivalencies of PFT)
+
15 PFT, percentage of each by grid-point (<code>maxvegetfrac</code>, see table for equivalencies of PFT)
  +
 
{| class="wikitable"
 
{| class="wikitable"
 
! num
 
! num
Línea 49: Línea 54:
 
|-
 
|-
 
| 13 || C4 agriculture
 
| 13 || C4 agriculture
  +
|-
  +
| 14 || C3 tropical natural grassland
  +
|-
  +
| 15 || C4 boreal natural grassland
 
|}
 
|}
**** <code>PFTmap_IPCC_[YYYY].nc</code> (0.5&deg;, basic), a file per/year ESA-LUH2, historical, v1.2 at:
+
<pre>${ORforcing}/PFTMAPS/CMIP6/ESA-LUH2/historical/v1.2/</pre>
+
<code>PFTmap_IPCC_[YYYY].nc</code> (0.5&deg;, basic), a file per/year ESA-LUH2, v2 at:
**** <code>carteveg5km.nc</code> (Olson's global classification of 94 PFT, 5km transformation to 13 PFT) No temporal evolution at:
+
<pre>${ORforcing}/PFTMAPS/CMIP6/ESA-LUH2v2/historical/15PFT.v2/PFTmap_2000.nc</pre>
  +
<code>carteveg5km.nc</code> (Olson's global classification of 94 PFT, 5km transformation)
  +
  +
No temporal evolution at:
 
<pre>${ORforcing}/PFTMAPS/</pre>
 
<pre>${ORforcing}/PFTMAPS/</pre>
  +
 
[[File:Olson_vegetmap.png|frame|50px|Global Olson vegetation at 5 km of resolution Homolosine projection]]
 
[[File:Olson_vegetmap.png|frame|50px|Global Olson vegetation at 5 km of resolution Homolosine projection]]
   
 
=== Soil characterisitcs ===
 
=== Soil characterisitcs ===
**** <code>soilcolor</code> used to define background-albedo: albedowet, albedodry (using values from 1 to 8). To be find in <code>soils_param.nc, soils_param_zobler.nc</code>
+
**** <code>soiltexture</code> to define soil type, to be grouped as 3 types: corse, medium, fine (from 7 values). 3 different sources:
+
* <code>soilcolor</code> used to define background-albedo: albedowet, albedodry (using values from 1 to 8). To be find in <code>soils_param.nc, soils_param_zobler.nc</code>
***** <code>soils_param.nc</code> (1.&deg;, basic)
+
* <code>soiltexture</code> to define soil type, to be grouped as 3 types: corse, medium, fine (from 7 values). 3 different sources:
***** <code>soils_param_zobler.nc</code>: 7 types (1&deg;)
+
* <code>soils_param.nc</code> (1.&deg;, basic)
***** <code>soils_param_usda.nc</code>: 12 types (0.08331404&deg;)
+
* <code>soils_param_zobler.nc</code>: 7 types (1&deg;)
  +
* <code>soils_param_usda.nc</code>: 12 types (0.08331404&deg;)
   
 
=== WOODHARVEST ===
 
=== WOODHARVEST ===
Línea 70: Línea 80:
   
 
=== Additional ===
 
=== Additional ===
*** LAI: on runs without <code>stomate</code> (otherwise, LAI is dynamic), one needs to provide climatologies of the LAI: 13 LAI values which evolves along time (monthly climatology) <code>lai2D_[00/01/03].nc</code>
+
* LAI: on runs without <code>stomate</code> (otherwise, LAI is dynamic), one needs to provide climatologies of the LAI: 13 LAI values which evolves along time (monthly climatology) <code>lai2D_[00/01/03].nc</code>
*** Albedo: on runs without <code>stomate</code> (otherwise, albedo is dynamic) new maps only for the bare soil albedo at higher resolution to avoid the use of <code>soilcolor</code> from <code>soils_param.nc</code>. Fixed values for wet/dry background albedo. Or a new file
+
* Albedo: on runs without <code>stomate</code> (otherwise, albedo is dynamic) new maps only for the bare soil albedo at higher resolution to avoid the use of <code>soilcolor</code> from <code>soils_param.nc</code>. Fixed values for wet/dry background albedo. Or a new file
**** <code>alb_bg_jrctip.nc</code>: albedos climatologies retrieved from MODIS satellite JRC-TIP package
+
** <code>alb_bg_jrctip.nc</code>: albedos climatologies retrieved from MODIS satellite JRC-TIP package
**** <code>alb_bg_modisopt_2D.nc</code>: Another non.climatological albedo from MODIS
+
** <code>alb_bg_modisopt_2D.nc</code>: Another non.climatological albedo from MODIS
 
<pre>${ORforcing}/albedo</pre>
 
<pre>${ORforcing}/albedo</pre>
*** Routing: <code>routing.nc</code>: worldwide data-base of river basins at 0.5&deg;: 1-8 direction, <89 point at the sea, ... (<code>trip</code>), riverID (<code>basins</code>), water retention (<code>topoind</code>), etc..., <code>cartepente2d_15min.nc</code> topography slope (0.25&deg;)
+
* Routing: <code>routing.nc</code>: worldwide data-base of river basins at 0.5&deg;: 1-8 direction, <89 point at the sea, ... (<code>trip</code>), riverID (<code>basins</code>), water retention (<code>topoind</code>), etc..., <code>cartepente2d_15min.nc</code> topography slope (0.25&deg;)
*** Floodplains: <code>floodplain.nc</code> To account for maximum flooded area: <code>lake, dam, swamp, saline, pond, irrig</code>
+
* Floodplains: <code>floodplain.nc</code> To account for maximum flooded area: <code>lake, dam, swamp, saline, pond, irrig</code>
*** Chemistry: <code>orchidee_fertilizer_1995.nc</code> with fertilization (for N<sub>2</sub>) for rice and the others
+
* Chemistry: <code>orchidee_fertilizer_1995.nc</code> with fertilization (for N<sub>2</sub>) for rice and the others
*** Reference Temperature: To be used as a reference temperature for the soil (<code>reftemp.nc</code>)
+
* Reference Temperature: To be used as a reference temperature for the soil (<code>reftemp.nc</code>)
   
* All ORCHIDEE configuration is controlled by <code>run.def</code>.: Domain, period, physics activation, sechiba/stomate, routing, floodplains, ... [https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/OrchideeParameters ORparameters]
+
All ORCHIDEE configuration is controlled by <code>run.def</code>.: Domain, period, physics activation, sechiba/stomate, routing, floodplains, ... [https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/OrchideeParameters ORparameters]
* I/O controlled by <code>*.xml</code> files from [http://forge.ipsl.jussieu.fr/ioserver/ XIOS] libraries
+
** <code>iodef.xml</code>: main XIOS configuration
+
I/O controlled by <code>*.xml</code> files from [http://forge.ipsl.jussieu.fr/ioserver/ XIOS] libraries
** <code>context_orchidee.xml</code>: I/O global configuration for ORCHIDEE
+
* <code>iodef.xml</code>: main XIOS configuration
** <code>field_def_orchidee.xml</code>: definition of I/O variables (names, units, dimensions, long-name, ...)
+
* <code>context_orchidee.xml</code>: I/O global configuration for ORCHIDEE
** <code>file_def_orchidee.xml</code>: definition of variables at each file (output frequency, level of output, ...)
+
* <code>field_def_orchidee.xml</code>: definition of I/O variables (names, units, dimensions, long-name, ...)
  +
* <code>file_def_orchidee.xml</code>: definition of variables at each file (output frequency, level of output, ...)
   
 
= Installation =
 
= Installation =
Línea 101: Línea 111:
   
 
= Running the model =
 
= Running the model =
ORCHDEE can run in a large variety of forms. Here is desribed a simple way to run a year of simulation
+
ORCHIDEE can run in a large variety of forms. Here is desribed a simple way to run a year of simulation using the off-line configuration and the trunk branch.
* Assuming a working directory <code>${WORKDIR}</code> (e.g.: <code>/home/lluis.fita/estudios/LUPA</code>). Creation of the running folder
+
<pre>$ mkdir -p tests/control
+
== Benchmark ==
$ cd tests/control</pre>
+
* Writting of a simple <code>run.def</code> with stomate and routing activated for the 1977 year
+
Following this [https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/UserGuide/TestCase1 instructions] we downloaded the necessary forcings in <code> /share/DATA/ORCHIDEE/benchmark </code>
  +
  +
  +
For this experiment, our <code>WORKDIR</code>:
 
<pre>
 
<pre>
# Use XIOS for writing diagnostics file
+
/home/lluis.fita/estudios/ORbenchmark
# defulat = n
+
</pre>
XIOS_ORCHIDEE_OK = y
 
#
 
START_DATE = 1977-01-01_00
 
END_DATE = 1978-01-01_00
 
TIME_LENGTH = 1Y
 
DT_SECHIBA = 1800
 
   
# Atmospheric forcing file
+
Linking all data:
FORCING_FILE = atmos_forcing.nc
+
<pre type="shell">
  +
ln -s /share/DATA/ORCHIDEE/benchmark/link_ORbenchmark_files.bash ./
  +
./link_ORbenchmark_files.bash
  +
</pre>
   
#
+
Configuring XIOS:
# South America
+
<pre type="shell">
#
+
cp /share/ORCHIDEE/modipsl/modeles/ORCHIDEE/src_xml/* ./
#WEST_EAST = -85., -31.
 
#SOUTH_NORTH = -57, 14.
 
LIMIT_WEST = -85.
 
LIMIT_EAST = -31.
 
LIMIT_SOUTH = -57.
 
LIMIT_NORTH = 14.
 
MERID_RES = 0.5
 
ZONAL_RES = 0.5
 
   
VEGET_YEAR=1
+
diff file_def_orchidee.xml /share/ORCHIDEE/modipsl/modeles/ORCHIDEE/src_xml/file_def_orchidee.xml
  +
44c44
  +
< <file id="sechiba1" name="sechiba_history" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="sechiba1" name="sechiba_history" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
391c391
  +
< <file id="sechiba2" name="sechiba_out_2" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="sechiba2" name="sechiba_out_2" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
633c633
  +
< <file id="sechiba3" name="sechiba_history_4dim" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="sechiba3" name="sechiba_history_4dim" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
837c837
  +
< <file id="stomate1" name="stomate_history" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="stomate1" name="stomate_history" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
1246c1246
  +
< <file id="stomate2" name="stomate_ipcc_history" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="stomate2" name="stomate_ipcc_history" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
1329c1329
  +
< <file id="stomate3" name="stomate_history_4dim" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="stomate3" name="stomate_history_4dim" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
1407c1407
  +
< <file id="stomate4" name="stomate_fixed_dia" output_level="10" output_freq="1d" enabled=".TRUE.">
  +
---
  +
> <file id="stomate4" name="stomate_fixed_dia" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
  +
</pre>
  +
  +
Getting the configuration and modifying its values:
  +
<pre type="shell">
  +
cp /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/run.def ./
  +
diff run.def /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/run.def
  +
12c12
  +
< TIME_LENGTH = 1D
  +
---
  +
> TIME_LENGTH = _AUTO_
  +
17c17
  +
< TIME_SKIP = 0
  +
---
  +
> TIME_SKIP = _AUTO_
  +
21c21
  +
< DRIVER_reset_time = n
  +
---
  +
> DRIVER_reset_time = _AUTO_
  +
24c24
  +
< RESTART_FILEIN = NONE
  +
---
  +
> RESTART_FILEIN = _AUTOBLOCKER_
  +
28c28
  +
< ATM_CO2 = 350.
  +
---
  +
> ATM_CO2 = _AUTO_: DEFAULT = 350.
  +
33,36c33,36
  +
< LIMIT_WEST=-5
  +
< LIMIT_NORTH=5
  +
< LIMIT_SOUTH=40
  +
< LIMIT_EAST=55
  +
---
  +
> #LIMIT_WEST=8
  +
> #LIMIT_NORTH=48
  +
> #LIMIT_SOUTH=46
  +
> #LIMIT_EAST=10
  +
</pre>
  +
  +
Getting orchidee's configuration:
  +
  +
<PRE STYLE="shell">
  +
cp /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/orchidee.def ./
  +
diff orchidee.def /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/orchidee.def
  +
41c41
  +
< SECHIBA_restart_in = NONE
  +
---
  +
> SECHIBA_restart_in = _AUTOBLOCKER_
  +
45c45
  +
< STOMATE_RESTART_FILEIN = NONE
  +
---
  +
> STOMATE_RESTART_FILEIN = _AUTOBLOCKER_
  +
52c52
  +
< XIOS_ORCHIDEE_OK = y
  +
---
  +
> XIOS_ORCHIDEE_OK = _AUTOBLOCKER_
  +
56c56
  +
< SECHIBA_HISTFILE2 = n
  +
---
  +
> SECHIBA_HISTFILE2 = _AUTO_
  +
61c61
  +
< WRITE_STEP = 0
  +
---
  +
> WRITE_STEP = _AUTO_
  +
65c65
  +
< WRITE_STEP2 = 0
  +
---
  +
> WRITE_STEP2 = _AUTO_
  +
69c69
  +
< STOMATE_HIST_DT = 0
  +
---
  +
> STOMATE_HIST_DT = _AUTO_
  +
74c74
  +
< STOMATE_IPCC_HIST_DT = 0
  +
---
  +
> STOMATE_IPCC_HIST_DT = _AUTO_
  +
135c135
  +
< RIVER_DESC = n
  +
---
  +
> RIVER_DESC = _AUTO_
  +
146c146
  +
< VEGET_UPDATE = 0Y
  +
---
  +
> VEGET_UPDATE = _AUTO_
  +
196c196
  +
< STOMATE_OK_STOMATE = y
  +
---
  +
> STOMATE_OK_STOMATE = _AUTOBLOCKER_
  +
206c206
  +
< NINPUT_UPDATE = 0Y
  +
---
  +
> NINPUT_UPDATE = _AUTO_
  +
209c209
  +
< STOMATE_IMPOSE_CN = n
  +
---
  +
> STOMATE_IMPOSE_CN = _AUTO_
  +
</PRE>
  +
  +
And ORCHIDEE's PFTs
  +
<PRE STYLE="shell">
  +
cp /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/orchidee_pft.def_15pft.1ac ./orchidee_pft.def
  +
</PRE>
  +
  +
Getting the basic PBS job to run ORCHIDEE:
  +
<pre type="shell">
  +
cp /share/ORCHIDEE/launch_orchidee.pbs ./
  +
</pre>
  +
  +
Launching
  +
<pre type="shell">
  +
qsub launch_orchidee.pbs
  +
</pre>
  +
  +
== Test: let's look at Marcos Juárez, Córdoba, Argentina ==
  +
  +
Assuming a working directory <code>${WORKDIR}</code> (e.g.: <code>/home/lluis.fita/estudios/SensLuLc_MarcosJuarez/trunk</code>)
  +
  +
Writing of a simple <code>run.def</code> with stomate and routing activated for the 1980 year (the meaning and default values of all parameters are available [https://forge.ipsl.jussieu.fr/orchidee/wiki/Documentation/OrchideeParameters here]
  +
  +
<pre>
  +
*****************************************************************************
  +
START_DATE = 2001-01-01 00:00:00
  +
END_DATE = 2001-12-31 24:00:00
  +
TIME_LENGTH = 1Y
  +
DT_SECHIBA = 900
  +
#SPREAD_PREC_SEC = 3600 # The default is half the forcing time step
  +
FORCING_FILE = forcing_yearm1.nc forcing_year.nc forcing_yearp1.nc
  +
  +
GRID_FILE = NONE
  +
# South America
  +
#LIMIT_WEST = -90.0
  +
#LIMIT_EAST = -30.0
  +
#LIMIT_SOUTH = -60.0
  +
#LIMIT_NORTH = 15.0
  +
# Marcos Juarez
  +
LIMIT_WEST = -64.0
  +
LIMIT_EAST = -60.0
  +
LIMIT_SOUTH = -34.0
  +
LIMIT_NORTH = -30.0
  +
#*****************************************************************************
   
# Activation of stomate
+
# Activate Stomate component (default y)
STOMATE_OK_CO2= y
 
 
STOMATE_OK_STOMATE= y
 
STOMATE_OK_STOMATE= y
 
STOMATE_OK_NCYCLE=FALSE
 
STOMATE_OK_NCYCLE=FALSE
   
# For routing
+
#
RIVER_ROUTING = y
+
# Parameters related to the restart file and the start date
ROUTING_FILE = routing.nc
+
#**************************************************************************
  +
# Time in the forcing file at which the model start if start date is not set by the forcing file (default 0)
  +
TIME_SKIP = 0
  +
  +
# Time length for one intergration
  +
# (default full lenght of forcing file)
  +
#TIME_LENGTH = _AUTO_
  +
  +
# If DRIVER_reset_time=y, read the year from forcing file instead of taking it from restart file (default n)
  +
#DRIVER_reset_time = _AUTO_
  +
  +
# Name of restart file for the driver (default NONE)
  +
RESTART_FILEIN = NONE
  +
  +
# Name of restart file for sechiba part of the model (default NONE)
  +
#SECHIBA_restart_in = _AUTOBLOCKER_
  +
  +
  +
# Name of restart file for stomate part of the model (default NONE)
  +
#STOMATE_RESTART_FILEIN = _AUTOBLOCKER_
  +
  +
# Parameters related to the diagnostic output files
  +
#**************************************************************************
  +
# Use XIOS for writing diagnostics file (default y)
  +
XIOS_ORCHIDEE_OK = n
  +
  +
# Flag to activate sechiba_out_2.nc history file when using IOIPSL for SECHIBA (defulat n)
  +
SECHIBA_HISTFILE2 = n
  +
  +
# Writefrequency in seconds in sechiba_history.nc when using IOIPSL (default 86400)
  +
# If WRITE_STEP=0 then all IOIPSL output are deactivated
  +
WRITE_STEP = 0
  +
  +
# Writefrequency in seconds sechiba_out_2.nc when using IOIPSL (default 1800)
  +
WRITE_STEP2 = 0
  +
  +
# Writefrequency in days in stomate_history.nc when using IOIPSL (default 10)
  +
STOMATE_HIST_DT = 0
  +
  +
# Writefrequency in days or -1 for monthly output in stomate_ipcc_history.nc when using IOIPSL (default 0)
  +
STOMATE_IPCC_HIST_DT = 0
  +
  +
PRINTLEV=1000
  +
  +
# Hydrology parameters
  +
#**************************************************************************
  +
# Activate the multi-layer diffusion scheme adapted from CWRR (default y)
 
HYDROL_CWRR = y
 
HYDROL_CWRR = y
DT_ROUTING = 86400
+
  +
# Activate river routing (default y)
  +
RIVER_ROUTING = n
  +
ROUTING_METHOD = highres
  +
ROUTING_FILE = routing.nc
  +
DT_ROUTING = 900
  +
# Activate creation of river_desc.nc file
  +
# RIVER_DESC will be activated only the first execution in the simulation
 
RIVER_DESC = y
 
RIVER_DESC = y
RIVER_DESC_FILE = river_desc.nc
 
ROUTING_RIVERS = 50
 
   
# Debug standard output printing level
+
# SOILTYPE_CLASSIF : Type of classification used for the map of soil types (default zobler)
PRINTLEV = 0</pre>
+
SOILTYPE_CLASSIF = zobler
* Linking atomspheric forcing files (0.5&deg; CRU-NCEP v5.4 files)
+
<pre>$ ln -s /share/ORCHIDEE/data/IGCM/SRF/METEO/CRU-NCEP/v5.4/halfdeg/cruncep_halfdeg_1977.nc ./atmos_forcing.nc</pre>
+
# Parameters related to vegetation map
* Linking the routing data-base
+
#**************************************************************************
<pre>$ ln -s /share/ORCHIDEE/data/IGCM/SRF/routing.nc ./</pre>
+
# Update vegetation frequency (default 0Y)
* Linking the topographical slope
+
VEGET_UPDATE = 0Y
<pre>$ ln -s /share/ORCHIDEE/data/IGCM/SRF/cartepente2d_15min.nc ./</pre>
+
* Linking the morphological files
+
# Read lai map (default n)
<pre>$ ln -s /share/ORCHIDEE/data/IGCM/SRF/soils_param.nc ./
+
LAI_MAP = n
$ ln -s /share/ORCHIDEE/data/IGCM/SRF/PFTmap_IPCC_1850.nc ./PFTmap.nc</pre>
+
* Getting the XIOS files
+
# Prescribed vegetation (default n)
<pre>$ cp /share/modipsl/modeles/ORCHIDEE/src_xml/*xml ./</pre>
+
IMPOSE_VEG = n
* Edit the <code>file_def_orchidee.xml</code> to define output frequency and level of of output (remove all the <code>_AUTO_</code>)
+
  +
# Parameters related to surface and thermal physical properties
  +
#************************************************************************
  +
# ROUGH_DYN : Account for a dynamic roughness height (activation of Su et al. parametrization) (default y)
  +
ROUGH_DYN=y
  +
  +
# OK_FREEZE : Activate the complet soil freezing scheme (default y)
  +
OK_FREEZE=y
  +
  +
# OK_EXPLICITSNOW : Activate explict snow scheme (default y)
  +
OK_EXPLICITSNOW=y
  +
  +
# Carbon related parameters
  +
#**************************************************************************
  +
# Analytic spinup (default n)
  +
SPINUP_ANALYTIC = n
  +
SPINUP_PERIOD = -1
  +
  +
# Value for atmospheric CO2 (default=350)
  +
ATM_CO2 = 350
  +
  +
# Activate harvest of wood (default y)
  +
DO_WOOD_HARVEST=y
  +
  +
# Deactivate fire (default FIRE_DISABLE=y)
  +
FIRE_DISABLE=y
  +
  +
# Optimized parameters to be used with PFTmap with 15 pfts such as
  +
# files in IGCM/SRF/PFTMAPS/CMIP6/ESA-LUH2v2/historical/15PFT.v1
  +
#**************************************************************************
  +
# Use 15 PFTs. Note that PFTmap.nc must contains 15PFTs.
  +
# PFT=10, 14 and 15 share the same parametrization except for VCMAX25, LAI_MAX, FRAC_GROWTHRESP,
  +
# MAINT_RESP_SLOPE_C and ALWAYS_INIT specified below.
  +
# (default NVM=13)
  +
NVM=15
  +
PFT_TO_MTC=1,2,3,4,5,6,7,8,9,10,11,12,13,10,10
  +
PFT_NAME__10='temperate C3 grass '
  +
PFT_NAME__14='tropical C3 grass '
  +
PFT_NAME__15='boreal C3 grass '
  +
  +
VCMAX25__10 = 50.0
  +
VCMAX25__14 = 50.0
  +
VCMAX25__15 = 40.0
  +
  +
LAI_MAX__10 = 2.5
  +
LAI_MAX__14 = 2.5
  +
LAI_MAX__15 = 2.0
  +
  +
FRAC_GROWTHRESP__10 = 0.28
  +
FRAC_GROWTHRESP__14 = 0.35
  +
FRAC_GROWTHRESP__15 = 0.35
  +
  +
MAINT_RESP_SLOPE_C__10 = 0.16
  +
MAINT_RESP_SLOPE_C__14 = 0.12
  +
MAINT_RESP_SLOPE_C__15 = 0.25
  +
  +
ALWAYS_INIT__10 = y
  +
ALWAYS_INIT__14 = n
  +
ALWAYS_INIT__15 = y
  +
</pre>
  +
  +
Linking atomspheric forcing files (0.5&deg; WFDE5 CRU GPCC v1 files)
  +
<pre>
  +
$ ln -s ${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_2000.nc ./forcing_yearm1.nc
  +
$ ln -s ${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_2001.nc ./forcing_year.nc
  +
$ ln -s ${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_2002.nc ./forcing_yearp1.nc
  +
</pre>
  +
  +
Linking the routing data-base
  +
<pre>$ ln -s ${ORforcing}/SRF/routing.nc ./</pre>
  +
  +
Linking the topographical slope
  +
<pre>$ ln -s ${ORforcing}/SRF/cartepente2d_15min.nc ./</pre>
  +
  +
Initial temperature of the soil
  +
<pre>ln -s /share/DATA/ORCHIDEE/IGCM/SRF/reftemp.nc ./</pre>
  +
  +
Linking the morphological files
  +
<pre>$ ln -s ${ORforcing}/SRF/SOIL/soils_param_zobler.nc ./soils_param.nc
  +
$ ln -s $ORforcing/SRF/PFTMAPS/CMIP6/ESA-LUH2v2/historical/15PFT.v2/PFTmap_1980.nc ./PFTmap.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/SOIL/soil_bulk_and_ph.nc ./
  +
</pre>
  +
  +
Linking the files related with the Nitrogen's cycle
  +
<pre type="shell">
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/synthetic/historical/Nfer_pasture_2001.nc ./nfer_pasture.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/synthetic/historical/Nfer_cropland_2001.nc ./nfer_cropland.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/manure/historical/Nmanure_pasture_2001.nc ./nmanure_pasture.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/manure/historical/Nmanure_cropland_2001.nc ./nmanure_cropland_2001.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_DEPOSITION/CCMI_ndep/historical/CCMI_ndep_nhx_2001.nc ./ndep_nhx.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_DEPOSITION/CCMI_ndep/historical/CCMI_ndep_noy_2001.nc ./ndep_noy.nc
  +
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/BNF/bnf_1850.nc ./bnf.nc
  +
</pre>
  +
  +
Getting the XIOS files (they might be version-dependant, therfore, it is recommended to get them directly from the same folder where the compiled version of ORCHIDEE is located, INSTALLDIR=/share/ORCHIDEE/)
  +
<pre>$ cp $INSTALLDIR/modipsl/modeles/ORCHIDEE/src_xml/*xml ./</pre>
  +
  +
Edit the <code>file_def_orchidee.xml</code> to define output frequency and level of of output (remove all the <code>_AUTO_</code>)
 
<pre>$ vim file_def_orchidee.xml</pre>
 
<pre>$ vim file_def_orchidee.xml</pre>
* The final configuration gets:
+
  +
The final configuration gets:
 
<pre>$ cat file_def_orchidee.xml | grep 'file id'
 
<pre>$ cat file_def_orchidee.xml | grep 'file id'
<file id="sechiba1" name="sechiba_history" output_level="11" output_freq="1d" enabled=".TRUE.">
+
<file id="sechiba1" name="sechiba_history" output_level="11" output_freq="1d" enabled=".TRUE.">
<file id="sechiba2" name="sechiba_out_2" output_level="2" output_freq="1mo" enabled=".FALSE.">
+
<file id="sechiba2" name="sechiba_out_2" output_level="2" output_freq="1mo" enabled=".FALSE.">
<file id="sechiba3" name="sechiba_history_4dim" output_level="11" output_freq="1d" enabled=".TRUE.">
+
<file id="sechiba3" name="sechiba_history_4dim" output_level="11" output_freq="1d" enabled=".TRUE.">
<file id="sechiba1_alma" name="sechiba_history_alma" output_level="10" output_freq="1mo" enabled=".FALSE.">
+
<file id="sechiba1_alma" name="sechiba_history_alma" output_level="10" output_freq="1mo" enabled=".FALSE.">
<file id="sechiba2_alma" name="sechiba_out_2_alma" output_level="10" output_freq="1d" enabled=".FALSE.">
+
<file id="sechiba2_alma" name="sechiba_out_2_alma" output_level="10" output_freq="1d" enabled=".FALSE.">
  +
<file id="sechiba4" name="sechiba_interp_diag" output_level="3" output_freq="1d" enabled=".TRUE.">
 
<file id="stomate1" name="stomate_history" output_level="10" output_freq="1d" enabled=".TRUE.">
 
<file id="stomate1" name="stomate_history" output_level="10" output_freq="1d" enabled=".TRUE.">
<file id="stomate2" name="stomate_ipcc_history" output_level="1" output_freq="1mo" enabled=".FALSE."></pre>
+
<file id="stomate2" name="stomate_ipcc_history" output_level="1" output_freq="1mo" enabled=".FALSE.">
* Linking the ORCHIDEE executable
+
<file id="stomate3" name="stomate_history_4dim" output_level="11" output_freq="1d" enabled=".TRUE.">
<pre>$ ln -s [INSTALLDIR]/modipsl/bin/orchidee_ol ./</pre>
+
<file id="stomate4" name="stomate_fixed_dia" output_level="4" output_freq="1d" enabled=".FALSE.">
* Getting the PBS scheduling job to run ORCHIDEE
+
</pre>
<pre>$ cp /share/ORCHIDEE/run_or.pbs ./</pre>
+
Linking the ORCHIDEE executable
* Launching the model
+
<pre>$ ln -s $INSTALLDIR/modipsl/bin/orchideedriver_prod ./orchideedriver
<pre>$ qsub run_or.pbs</pre>
+
$ ln -s /share/ORCHIDEE/modipsl/bin/xios_server_prod.exe ./xios.exe
* If everything went fine, one should have (at least)
+
</pre>
  +
  +
Getting the PBS scheduling job to run ORCHIDEE
  +
<pre>$ cp /share/ORCHIDEE/launch_orchidee.pbs ./</pre>
  +
  +
Launching the model
  +
<pre>$ qsub launch_orchidee.pbs</pre>
  +
  +
There is a problem with the meteorological forcing data <code>IGCM/SRF/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_[nnnn].nc</code>, its time axis is units are: <code>'hours since 1900-01-01 00:00:00'</code>. But this gives an <code>IOIPSL</code> error from <code>flinopen_work</code> subroutine from <code>IOIPSL/src/flincom.f90</code> (lines #586-600):
  +
<pre style="Fortran">
  +
!---
  +
!-- 5.1 Find the time axis. Prefered method is the 'timestep since'
  +
!---
  +
gdtmaf_id = -1
  +
gdtt_id = -1
  +
old_id = -1
  +
DO iv=1,ncnbva(fid_out)
  +
name=''
  +
iret = NF90_INQUIRE_VARIABLE (fid, iv, name=name)
  +
units=''
  +
iret = NF90_GET_ATT (fid, iv, 'units', units)
  +
IF (INDEX(units,'seconds since') > 0) gdtmaf_id = iv
  +
IF (INDEX(units,'timesteps since') > 0) gdtt_id = iv
  +
IF (INDEX(name, 'tstep') > 0 .OR. INDEX(name,'time') > 0 ) old_id = iv
  +
ENDDO
  +
</pre>
  +
Therefore, axis time units have to changed to <code>'seconds since 1900-01-01 00:00:00'</code>
  +
<!--
  +
python3 $pyHOME3/nc_var.py -o valmod -S mulc,3600 -f ~/sandbox/get/WFDE5_CRU_GPCC_2002.nc -v time
  +
python3 $pyHOME3/nc_var.py -o varaddattrk -S 'units|seconds!since!1900-01-01!00:00:00|S' -v time -f sandbox/get/WFDE5_CRU_GPCC_2002.nc
  +
-->
  +
  +
If everything went fine, one should have (at least)
  +
=== single file output ===
 
<pre>orout/sechiba_history.nc orout/sechiba_history_4dim.nc stomate_history.nc</pre>
 
<pre>orout/sechiba_history.nc orout/sechiba_history_4dim.nc stomate_history.nc</pre>
** <code>sechiba_history.nc</code>, <code>sechiba_history_4dim.nc</code>, <code>stomate_history.nc</code>: Outputs (optional, only when stomate is activated)
+
* <code>sechiba_history.nc</code>, <code>sechiba_history_4dim.nc</code>, <code>stomate_history.nc</code>: Outputs (optional, only when stomate is activated)
** <code>sechiba_rest_out.nc</code>, <code>stomate_restart.nc</code>: restarts for <code>sechiba<code> and <code>stomate</code> (optional, only when stomate is activated)
+
* <code>sechiba_rest_out.nc</code>, <code>stomate_restart.nc</code>: restarts for <code>sechiba<code> and <code>stomate</code> (optional, only when stomate is activated)
** <code>out_orchidee_[nnnn]</code>: standard output files for each process
+
* <code>out_orchidee_[nnnn]</code>: standard output files for each process
** <code>river_desc.nc</code>: output with river description (optional, only when routing is activated)
+
* <code>river_desc.nc</code>: output with river description (optional, only when routing is activated)
   
= Compiling rebuild =
+
=== multiple file output ===
  +
In case we run without XIOS, each processor will produce an output file. We need to use the <code>rebuild</code> utility for that
  +
<pre style="sell">
  +
sechiba_history_[nnnn].nc, sechiba_interp_diag_[nnnn].nc, stomate_history_[nnnn].nc, stomate_history_4dim_[nnnn].nc
  +
$ /share/ORCHIDEE/modipsl/modeles/IOIPSL/bin/rebuild -h
   
Due to the fact that <code>hydra</code> does not have the netcdf libraries compiled in parallel, ORCHDEE output is written with multiple files being a file for each process. In order to overcome this output. IPSL does prepare a tool to join the files and provide the expected output. This tool is called <code>rebuild</code> (a Kornshell script which encapsulates de exacutable <code>flio_rbld</code>) and it comes with the <code>IOIPSL</code> libraries. The IOIPSL libraries, are a set of old libraries developed by the IPSL (M. A. Foujuls, J. Polcher among others) to deal with the netCDF data access for all the models developed at the IOIPSL. Compiling IOIPSL (following [http://lmdz.lmd.jussieu.fr/utilisateurs/faq-en/installation/comment-installer-ioipsl-et-loutil-rebuild install rebuild]. It has to be compiled independently. Here it is explained how it has to be done.
+
"rebuild"
  +
rebuild a model_file from several input files.
  +
Each input file contains the model_data for a domain.
   
* Go to the instalation directory <code>[INSTALLDIR]</code> (at hydra <code>share</code>)
+
Usage :
<pre>$ cd [INSTALLDIR]</pre>
+
rebuild [-h]
* getting the last version of the code
+
rebuild [-v level] [-f] -o output_file_name input_file_names
<pre>$ svn co https://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk modipsl_IOIPSLtools</pre>
 
* going to prepare compilation/installation
 
<pre>$ cd modipsl_IOIPSLtools/util</pre>
 
* preparing environment
 
<pre>./model IOIPSL_PLUS</pre>
 
* We got some issues with the ports, thus, it needs to be manually done:
 
<pre>$ cd ../modeles</pre>
 
* Getting IOIPSL ('''NOTE:''' notice the difference in library's version from the previous one):
 
<pre>$ svn co https://forge.ipsl.jussieu.fr/igcmg/svn/IOIPSL/tags/v2_2_3 IOIPSL</pre>
 
* Comming back to the <code>util</code> folder
 
<pre>$ cd ../util</pre>
 
* Creation of the compilation environment for <code>`hydra'</code> using <code>'ifort'</code> inside <code>AA_make.gdef</code> as in the full compilation
 
<pre>$ cp ../../modipsl/util/AA_make.gdef ./</pre>
 
* Preparing makefiles
 
<pre>$ ./ins_make -t "ifort_hydra" -p I4R8</pre>
 
* going to src folder to compile
 
<pre>$ cd ../modeles/IOIPSL/src</pre>
 
* cleaning (you never know...)
 
<pre>$ make clean</pre>
 
* compiling
 
<pre>$ make >& run_make.log</pre>
 
* Checking no errors:
 
<pre>$ cat -n run_make.log | grep Error</pre>
 
* compilation of tools (file concatenation)
 
<pre>$ cd ../tools </pre>
 
* cleaning (you never know...)
 
<pre>$ make clean</pre>
 
* compiling
 
<pre>$ make >& run_make.log</pre>
 
* Checking no errors:
 
<pre>$ cat -n run_make.log | grep Error</pre>
 
* One should have:
 
<pre>$ ls ../../../bin/
 
flio_rbld rebuild</pre>
 
   
= debug Instalation =
+
Options :
Getting a debugging copy for test purposes
+
-h : help
  +
-v O/1/2/3 : verbose mode (verbosity increasing with level)
  +
-f : executing mode
  +
(execute the program even if the number of input files
  +
is not equal to the total number of domains)
  +
</pre>
  +
We reconstruct:
  +
<pre style="shell">
  +
/share/ORCHIDEE/modipsl/modeles/IOIPSL/bin/rebuild -o sechiba_history.nc sechiba_history_????.nc
  +
</pre>
   
== Instalation steps using modipsl ==
+
== Running the model in DCAO's computational lab ==
* Go to the instalation directory <code>[INSTALLDIR]</code> (<code>/share</code> in <code>hydra</code>)
+
Follow this link [[runORDCAO]] to set-up the runs in the machines of DCAO's computational laboratory
<pre>$ cd [INSTALLDIR]</pre>
 
* Getting the IPSL-models suite (r 3379)
 
<pre>$ svn co https://forge.ipsl.jussieu.fr/igcmg/svn/modipsl/trunk modipsl_dbg</pre>
 
* Once we got the codes, we need to copy the specificities of the installation for <code>hydra</code>
 
<pre>$ cp ../../modipsl/util/AA_make.gdef ./
 
$ cp ../../modipsl/modeles/XIOS/arch/*hydra* ../modeles/XIOS/arch/
 
$ cp ../../modipsl/modeles/ORCHIDEE/arch/*hydra* ../modeles/ORCHIDEE/arch/</pre>
 
* Everything is the same as for the installation, except that we need to indicate debugging compilation:
 
<pre>./ins_make -t ifort_hydra -d >& run_ins_make.log</pre>
 
* And on <code>Makefile</code> from <code>config/ORCHIDEE_OL</code>, change all the <code>-prod</code> by <code>-debug</code>
 
<pre>(...)
 
xios :
 
(cd ../../modeles/XIOS ; ./make_xios --netcdf_lib netcdf4_seq \
 
--debug --arch ${FCM_ARCH} --job 8 ; cp bin/xios_server.exe ../../bin/. ; )
 
(...)
 
driver :
 
(cd ../../modeles/ORCHIDEE ; ./makeorchidee_fcm -j 8 -parallel mpi -debug -arch ${FCM_ARCH} -driver ; )
 
(...)
 
driver_xios :
 
(cd ../../modeles/ORCHIDEE ; ./makeorchidee_fcm -xios2 -j 8 -parallel mpi -debug -arch ${FCM_ARCH} -driver ; )
 
(...)</pre>
 
* Compiling:
 
<pre>$ gmake >& run_gmake.log</pre>
 
* Checking if everything went fine:
 
<pre>$ cat -n run_gmake.log | grep Error
 
$ cat -n run_gmake.log | grep undefined
 
$ ls ../../bin/
 
orchidee_ol xios_server.exe</pre>
 
   
 
= OR4L: L. Fita's work-flow management for ORCHIDEE =
 
= OR4L: L. Fita's work-flow management for ORCHIDEE =
Línea 187: Línea 195:
   
 
However, L. Fita developed an independent simpler and less potent work-flow called OR4L. See how it works in this wiki page [[ORCHIDEE/OR4L OR4L]]
 
However, L. Fita developed an independent simpler and less potent work-flow called OR4L. See how it works in this wiki page [[ORCHIDEE/OR4L OR4L]]
  +
  +
= OR_1proc: DCAO's 1-proc work-flow management for ORCHIDEE =
  +
DCAO's computational lab machines are 1 processors standard machines. A new work-flow management has been created for such cases. Mostly related to the UMI & DCAO course of [[http://www.cima.fcen.uba.ar/UMI/wrk/modelado-2019.php land-atmosphere interaction and its modelling]]. All the iformation is available in the wiki page [[OR1proc OR 1proc]]

Última revisión de 17:20 27 jul 2023

Contenido

[editar] ORCHIDEE

This manual provides the information about the land-surface model ORCHIDEE (technical page for advanced users) from Institute Pierre Simone Laplace (IPSL). Its installation on the HPC of the CIMA called hydra.

[editar] Model description

  • ORCHIDEE: sechiba & stomate
  • Two major modes of simulations: Off-line (no feedback) / on-line (LMDZ, WRF)

All forcing data to run ORCHIDEE is located here in CIMA's HPC:

${ORforcing}=/share/DATA/ORCHIDEE/IGCM/

[editar] Off-line atmospheric forcings

Desdcribed here: ORforcings

Atmoshperic variables required by ORCHIDEE: LWdown, PSurf, Qair, Rainf, SWdown, Snowf, Tair, Wind_E, Wind_N

Available data-bases in hydra:

  • WFDE5 CRU GPCC (v1, 0.5°): mixing ERA5 CRU and GPCC: WFDE5_CRU_GPCC_[YYYY].nc at hydra:
${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/

[editar] Morphological forcings as data-base

Installed in CIMA's HPC hydra at

/share/DATA/ORCHIDEE/IGCM/SRF

To be interpolated to the domain of simulation (region and resolution) at the first time step (done by ORCHIDEE) Mandatory:

[editar] PFT map

15 PFT, percentage of each by grid-point (maxvegetfrac, see table for equivalencies of PFT)

num description
1 bare ground
2 tropical broad-leaved evergreen
3 tropical broad-leaved raingreen
4 temperate needleleaf evergreen
5 temperate broad-leaved evergreen
6 temperate broad-leaved summergreen
7 boreal needleleaf evergreen
8 boreal broad-leaved summergreen
9 boreal needleleaf summergreen
10 C3 grass
11 C4 grass
12 C3 agriculture
13 C4 agriculture
14 C3 tropical natural grassland
15 C4 boreal natural grassland

PFTmap_IPCC_[YYYY].nc (0.5°, basic), a file per/year ESA-LUH2, v2 at:

${ORforcing}/PFTMAPS/CMIP6/ESA-LUH2v2/historical/15PFT.v2/PFTmap_2000.nc

carteveg5km.nc (Olson's global classification of 94 PFT, 5km transformation)

No temporal evolution at:

${ORforcing}/PFTMAPS/
(thumbnail)
Global Olson vegetation at 5 km of resolution Homolosine projection

[editar] Soil characterisitcs

  • soilcolor used to define background-albedo: albedowet, albedodry (using values from 1 to 8). To be find in soils_param.nc, soils_param_zobler.nc
  • soiltexture to define soil type, to be grouped as 3 types: corse, medium, fine (from 7 values). 3 different sources:
  • soils_param.nc (1.°, basic)
  • soils_param_zobler.nc: 7 types (1°)
  • soils_param_usda.nc: 12 types (0.08331404°)

[editar] WOODHARVEST

[editar] SOIL_BULK

[editar] Additional

  • LAI: on runs without stomate (otherwise, LAI is dynamic), one needs to provide climatologies of the LAI: 13 LAI values which evolves along time (monthly climatology) lai2D_[00/01/03].nc
  • Albedo: on runs without stomate (otherwise, albedo is dynamic) new maps only for the bare soil albedo at higher resolution to avoid the use of soilcolor from soils_param.nc. Fixed values for wet/dry background albedo. Or a new file
    • alb_bg_jrctip.nc: albedos climatologies retrieved from MODIS satellite JRC-TIP package
    • alb_bg_modisopt_2D.nc: Another non.climatological albedo from MODIS
${ORforcing}/albedo
  • Routing: routing.nc: worldwide data-base of river basins at 0.5°: 1-8 direction, <89 point at the sea, ... (trip), riverID (basins), water retention (topoind), etc..., cartepente2d_15min.nc topography slope (0.25°)
  • Floodplains: floodplain.nc To account for maximum flooded area: lake, dam, swamp, saline, pond, irrig
  • Chemistry: orchidee_fertilizer_1995.nc with fertilization (for N2) for rice and the others
  • Reference Temperature: To be used as a reference temperature for the soil (reftemp.nc)

All ORCHIDEE configuration is controlled by run.def.: Domain, period, physics activation, sechiba/stomate, routing, floodplains, ... ORparameters

I/O controlled by *.xml files from XIOS libraries

  • iodef.xml: main XIOS configuration
  • context_orchidee.xml: I/O global configuration for ORCHIDEE
  • field_def_orchidee.xml: definition of I/O variables (names, units, dimensions, long-name, ...)
  • file_def_orchidee.xml: definition of variables at each file (output frequency, level of output, ...)

[editar] Installation

This installation guide is based on the installation in different machines from CIMA/DCAO computational resources:

which it must have pre-installed: netCDF libraries (netcdf-dev, netcdff), MPI libraries (mpi, mpich), Fortan and C compilers (gcc, gcc++ gfortran), pre-processing tools (cpp), subversion repository code tool (svn), Makefile (make, gmake), shells (ksh, csh)


NOTE

Each new version of the code, has its own XIOS files! Make sure that you're using the right ones!! (otherwise, you would have an error...)

[editar] Running the model

ORCHIDEE can run in a large variety of forms. Here is desribed a simple way to run a year of simulation using the off-line configuration and the trunk branch.

[editar] Benchmark

Following this instructions we downloaded the necessary forcings in /share/DATA/ORCHIDEE/benchmark


For this experiment, our WORKDIR:

/home/lluis.fita/estudios/ORbenchmark

Linking all data:

ln -s /share/DATA/ORCHIDEE/benchmark/link_ORbenchmark_files.bash ./
./link_ORbenchmark_files.bash

Configuring XIOS:

cp /share/ORCHIDEE/modipsl/modeles/ORCHIDEE/src_xml/* ./

diff file_def_orchidee.xml /share/ORCHIDEE/modipsl/modeles/ORCHIDEE/src_xml/file_def_orchidee.xml
44c44
<   <file id="sechiba1" name="sechiba_history" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="sechiba1" name="sechiba_history" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
391c391
<   <file id="sechiba2" name="sechiba_out_2" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="sechiba2" name="sechiba_out_2" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
633c633
<   <file id="sechiba3" name="sechiba_history_4dim" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="sechiba3" name="sechiba_history_4dim" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
837c837
<   <file id="stomate1" name="stomate_history" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="stomate1" name="stomate_history" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
1246c1246
<   <file id="stomate2" name="stomate_ipcc_history" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="stomate2" name="stomate_ipcc_history" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
1329c1329
<   <file id="stomate3" name="stomate_history_4dim" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="stomate3" name="stomate_history_4dim" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">
1407c1407
<   <file id="stomate4" name="stomate_fixed_dia" output_level="10" output_freq="1d" enabled=".TRUE.">
---
>   <file id="stomate4" name="stomate_fixed_dia" output_level="_AUTO_" output_freq="_AUTO_" enabled="_AUTO_">

Getting the configuration and modifying its values:

cp /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/run.def ./
diff run.def /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/run.def
12c12
< TIME_LENGTH = 1D
---
> TIME_LENGTH = _AUTO_
17c17
< TIME_SKIP = 0
---
> TIME_SKIP = _AUTO_
21c21
< DRIVER_reset_time = n
---
> DRIVER_reset_time = _AUTO_
24c24
< RESTART_FILEIN = NONE
---
> RESTART_FILEIN = _AUTOBLOCKER_
28c28
< ATM_CO2 = 350.
---
> ATM_CO2 = _AUTO_: DEFAULT = 350.
33,36c33,36
< LIMIT_WEST=-5
< LIMIT_NORTH=5
< LIMIT_SOUTH=40
< LIMIT_EAST=55
---
> #LIMIT_WEST=8
> #LIMIT_NORTH=48
> #LIMIT_SOUTH=46
> #LIMIT_EAST=10

Getting orchidee's configuration:

cp /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/orchidee.def ./
diff orchidee.def /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/orchidee.def
41c41
< SECHIBA_restart_in = NONE
---
> SECHIBA_restart_in = _AUTOBLOCKER_
45c45
< STOMATE_RESTART_FILEIN = NONE
---
> STOMATE_RESTART_FILEIN = _AUTOBLOCKER_
52c52
< XIOS_ORCHIDEE_OK = y
---
> XIOS_ORCHIDEE_OK = _AUTOBLOCKER_
56c56
< SECHIBA_HISTFILE2 = n
---
> SECHIBA_HISTFILE2 = _AUTO_
61c61
< WRITE_STEP = 0
---
> WRITE_STEP = _AUTO_
65c65
< WRITE_STEP2 = 0
---
> WRITE_STEP2 = _AUTO_ 
69c69
< STOMATE_HIST_DT = 0
---
> STOMATE_HIST_DT = _AUTO_
74c74
< STOMATE_IPCC_HIST_DT = 0
---
> STOMATE_IPCC_HIST_DT = _AUTO_
135c135
< RIVER_DESC = n
---
> RIVER_DESC = _AUTO_
146c146
< VEGET_UPDATE = 0Y
---
> VEGET_UPDATE = _AUTO_
196c196
< STOMATE_OK_STOMATE = y
---
> STOMATE_OK_STOMATE = _AUTOBLOCKER_ 
206c206
< NINPUT_UPDATE = 0Y
---
> NINPUT_UPDATE = _AUTO_
209c209
< STOMATE_IMPOSE_CN = n
---
> STOMATE_IMPOSE_CN = _AUTO_

And ORCHIDEE's PFTs

cp /share/ORCHIDEE/modipsl/config/ORCHIDEE_OL/OOL_SEC_STO_FG2/PARAM/orchidee_pft.def_15pft.1ac ./orchidee_pft.def

Getting the basic PBS job to run ORCHIDEE:

cp /share/ORCHIDEE/launch_orchidee.pbs ./

Launching

qsub launch_orchidee.pbs

[editar] Test: let's look at Marcos Juárez, Córdoba, Argentina

Assuming a working directory ${WORKDIR} (e.g.: /home/lluis.fita/estudios/SensLuLc_MarcosJuarez/trunk)

Writing of a simple run.def with stomate and routing activated for the 1980 year (the meaning and default values of all parameters are available here

*****************************************************************************
START_DATE = 2001-01-01 00:00:00
END_DATE = 2001-12-31 24:00:00
TIME_LENGTH = 1Y
DT_SECHIBA = 900
#SPREAD_PREC_SEC = 3600 # The default is half the forcing time step
FORCING_FILE = forcing_yearm1.nc forcing_year.nc forcing_yearp1.nc

GRID_FILE = NONE
# South America
#LIMIT_WEST = -90.0
#LIMIT_EAST = -30.0
#LIMIT_SOUTH = -60.0
#LIMIT_NORTH = 15.0
# Marcos Juarez
LIMIT_WEST = -64.0
LIMIT_EAST = -60.0
LIMIT_SOUTH = -34.0
LIMIT_NORTH = -30.0
#*****************************************************************************

# Activate Stomate component (default y)
STOMATE_OK_STOMATE= y
STOMATE_OK_NCYCLE=FALSE

#
# Parameters related to the restart file and the start date
#**************************************************************************
# Time in the forcing file at which the model start if start date is not set by the forcing file (default 0)
TIME_SKIP = 0

# Time length for one intergration
# (default full lenght of forcing file)
#TIME_LENGTH = _AUTO_

# If DRIVER_reset_time=y, read the year from forcing file instead of taking it from restart file (default n)
#DRIVER_reset_time = _AUTO_

# Name of restart file for the driver (default NONE)
RESTART_FILEIN = NONE

# Name of restart file for sechiba part of the model (default NONE)
#SECHIBA_restart_in = _AUTOBLOCKER_


# Name of restart file for stomate part of the model (default NONE)
#STOMATE_RESTART_FILEIN = _AUTOBLOCKER_

# Parameters related to the diagnostic output files
#**************************************************************************
# Use XIOS for writing diagnostics file (default y)
XIOS_ORCHIDEE_OK = n

# Flag to activate sechiba_out_2.nc history file when using IOIPSL for SECHIBA (defulat n)
SECHIBA_HISTFILE2 = n

# Writefrequency in seconds in sechiba_history.nc when using IOIPSL (default 86400)
# If WRITE_STEP=0 then all IOIPSL output are deactivated
WRITE_STEP = 0

# Writefrequency in seconds sechiba_out_2.nc when using IOIPSL (default 1800)
WRITE_STEP2 = 0

# Writefrequency in days in stomate_history.nc when using IOIPSL (default 10)
STOMATE_HIST_DT = 0

# Writefrequency in days or -1 for monthly output in stomate_ipcc_history.nc when using IOIPSL (default 0)
STOMATE_IPCC_HIST_DT = 0

PRINTLEV=1000

# Hydrology parameters
#**************************************************************************
# Activate the multi-layer diffusion scheme adapted from CWRR (default y)
HYDROL_CWRR = y

# Activate river routing (default y)
RIVER_ROUTING = n
ROUTING_METHOD = highres
ROUTING_FILE = routing.nc
DT_ROUTING = 900
# Activate creation of river_desc.nc file
# RIVER_DESC will be activated only the first execution in the simulation
RIVER_DESC = y

# SOILTYPE_CLASSIF :  Type of classification used for the map of soil types (default zobler)
SOILTYPE_CLASSIF = zobler

# Parameters related to vegetation map
#**************************************************************************
# Update vegetation frequency (default 0Y)
VEGET_UPDATE = 0Y

# Read lai map (default n)
LAI_MAP = n

# Prescribed vegetation (default n)
IMPOSE_VEG = n

# Parameters related to surface and thermal physical properties
#************************************************************************
# ROUGH_DYN : Account for a dynamic roughness height (activation of Su et al. parametrization) (default y)
ROUGH_DYN=y

# OK_FREEZE :  Activate the complet soil freezing scheme (default y)
OK_FREEZE=y

# OK_EXPLICITSNOW :  Activate explict snow scheme (default y)
OK_EXPLICITSNOW=y

# Carbon related parameters
#**************************************************************************
# Analytic spinup (default n)
SPINUP_ANALYTIC = n
SPINUP_PERIOD = -1

# Value for atmospheric CO2 (default=350)
ATM_CO2 = 350

# Activate harvest of wood (default y)
DO_WOOD_HARVEST=y

# Deactivate fire (default FIRE_DISABLE=y)
FIRE_DISABLE=y

# Optimized parameters to be used with PFTmap with 15 pfts such as
# files in IGCM/SRF/PFTMAPS/CMIP6/ESA-LUH2v2/historical/15PFT.v1
#**************************************************************************
# Use 15 PFTs. Note that PFTmap.nc must contains 15PFTs.
# PFT=10, 14 and 15 share the same parametrization except for VCMAX25, LAI_MAX, FRAC_GROWTHRESP,
# MAINT_RESP_SLOPE_C and ALWAYS_INIT specified below.
# (default NVM=13)
NVM=15
PFT_TO_MTC=1,2,3,4,5,6,7,8,9,10,11,12,13,10,10
PFT_NAME__10='temperate C3           grass      '
PFT_NAME__14='tropical  C3           grass      '
PFT_NAME__15='boreal    C3           grass      '

VCMAX25__10 = 50.0
VCMAX25__14 = 50.0
VCMAX25__15 = 40.0

LAI_MAX__10 = 2.5
LAI_MAX__14 = 2.5
LAI_MAX__15 = 2.0

FRAC_GROWTHRESP__10 = 0.28
FRAC_GROWTHRESP__14 = 0.35
FRAC_GROWTHRESP__15 = 0.35

MAINT_RESP_SLOPE_C__10 = 0.16
MAINT_RESP_SLOPE_C__14 = 0.12
MAINT_RESP_SLOPE_C__15 = 0.25

ALWAYS_INIT__10 = y
ALWAYS_INIT__14 = n
ALWAYS_INIT__15 = y

Linking atomspheric forcing files (0.5° WFDE5 CRU GPCC v1 files)

$ ln -s ${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_2000.nc ./forcing_yearm1.nc
$ ln -s ${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_2001.nc ./forcing_year.nc
$ ln -s ${ORforcing}/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_2002.nc ./forcing_yearp1.nc

Linking the routing data-base

$ ln -s ${ORforcing}/SRF/routing.nc ./

Linking the topographical slope

$ ln -s ${ORforcing}/SRF/cartepente2d_15min.nc ./

Initial temperature of the soil

ln -s /share/DATA/ORCHIDEE/IGCM/SRF/reftemp.nc ./

Linking the morphological files

$ ln -s ${ORforcing}/SRF/SOIL/soils_param_zobler.nc ./soils_param.nc
$ ln -s $ORforcing/SRF/PFTMAPS/CMIP6/ESA-LUH2v2/historical/15PFT.v2/PFTmap_1980.nc ./PFTmap.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/SOIL/soil_bulk_and_ph.nc ./

Linking the files related with the Nitrogen's cycle

$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/synthetic/historical/Nfer_pasture_2001.nc ./nfer_pasture.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/synthetic/historical/Nfer_cropland_2001.nc ./nfer_cropland.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/manure/historical/Nmanure_pasture_2001.nc ./nmanure_pasture.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_FERTILISATION/NMIP/manure/historical/Nmanure_cropland_2001.nc ./nmanure_cropland_2001.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_DEPOSITION/CCMI_ndep/historical/CCMI_ndep_nhx_2001.nc ./ndep_nhx.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/N_DEPOSITION/CCMI_ndep/historical/CCMI_ndep_noy_2001.nc ./ndep_noy.nc
$ ln -s /share/DATA/ORCHIDEE/IGCM/SRF/NITROGEN/BNF/bnf_1850.nc ./bnf.nc

Getting the XIOS files (they might be version-dependant, therfore, it is recommended to get them directly from the same folder where the compiled version of ORCHIDEE is located, INSTALLDIR=/share/ORCHIDEE/)

$ cp $INSTALLDIR/modipsl/modeles/ORCHIDEE/src_xml/*xml ./

Edit the file_def_orchidee.xml to define output frequency and level of of output (remove all the _AUTO_)

$ vim file_def_orchidee.xml

The final configuration gets:

$ cat file_def_orchidee.xml | grep 'file id' 
 <file id="sechiba1" name="sechiba_history" output_level="11" output_freq="1d" enabled=".TRUE.">
  <file id="sechiba2" name="sechiba_out_2" output_level="2" output_freq="1mo" enabled=".FALSE.">
  <file id="sechiba3" name="sechiba_history_4dim" output_level="11" output_freq="1d" enabled=".TRUE.">
  <file id="sechiba1_alma" name="sechiba_history_alma" output_level="10" output_freq="1mo" enabled=".FALSE.">
  <file id="sechiba2_alma" name="sechiba_out_2_alma" output_level="10" output_freq="1d" enabled=".FALSE.">
  <file id="sechiba4" name="sechiba_interp_diag" output_level="3" output_freq="1d" enabled=".TRUE.">
  <file id="stomate1" name="stomate_history" output_level="10" output_freq="1d" enabled=".TRUE.">
  <file id="stomate2" name="stomate_ipcc_history" output_level="1" output_freq="1mo" enabled=".FALSE.">
  <file id="stomate3" name="stomate_history_4dim" output_level="11" output_freq="1d" enabled=".TRUE.">
  <file id="stomate4" name="stomate_fixed_dia" output_level="4" output_freq="1d" enabled=".FALSE.">

Linking the ORCHIDEE executable

$ ln -s $INSTALLDIR/modipsl/bin/orchideedriver_prod ./orchideedriver
$ ln -s /share/ORCHIDEE/modipsl/bin/xios_server_prod.exe ./xios.exe

Getting the PBS scheduling job to run ORCHIDEE

$ cp /share/ORCHIDEE/launch_orchidee.pbs ./

Launching the model

$ qsub launch_orchidee.pbs

There is a problem with the meteorological forcing data IGCM/SRF/METEO/WFDE5_CRU_GPCC/v1/WFDE5_CRU_GPCC_[nnnn].nc, its time axis is units are: 'hours since 1900-01-01 00:00:00'. But this gives an IOIPSL error from flinopen_work subroutine from IOIPSL/src/flincom.f90 (lines #586-600):

!---
!-- 5.1 Find the time axis. Prefered method is the 'timestep since'
!---
    gdtmaf_id = -1
    gdtt_id = -1
    old_id = -1
    DO iv=1,ncnbva(fid_out)
      name=''
      iret = NF90_INQUIRE_VARIABLE (fid, iv, name=name)
      units=''
      iret = NF90_GET_ATT (fid, iv, 'units', units)
      IF (INDEX(units,'seconds since') > 0) gdtmaf_id = iv
      IF (INDEX(units,'timesteps since') > 0) gdtt_id = iv
      IF (INDEX(name, 'tstep') > 0 .OR. INDEX(name,'time') > 0 ) old_id = iv
    ENDDO

Therefore, axis time units have to changed to 'seconds since 1900-01-01 00:00:00'

If everything went fine, one should have (at least)

[editar] single file output

orout/sechiba_history.nc  orout/sechiba_history_4dim.nc  stomate_history.nc
  • sechiba_history.nc, sechiba_history_4dim.nc, stomate_history.nc: Outputs (optional, only when stomate is activated)
  • sechiba_rest_out.nc, stomate_restart.nc: restarts for sechiba<code> and <code>stomate (optional, only when stomate is activated)
  • out_orchidee_[nnnn]: standard output files for each process
  • river_desc.nc: output with river description (optional, only when routing is activated)

[editar] multiple file output

In case we run without XIOS, each processor will produce an output file. We need to use the rebuild utility for that

sechiba_history_[nnnn].nc, sechiba_interp_diag_[nnnn].nc, stomate_history_[nnnn].nc, stomate_history_4dim_[nnnn].nc
$ /share/ORCHIDEE/modipsl/modeles/IOIPSL/bin/rebuild -h

"rebuild"
  rebuild a model_file from several input files.
Each input file contains the model_data for a domain.

Usage :
  rebuild [-h]
  rebuild [-v level] [-f] -o output_file_name input_file_names

Options :
  -h         : help
  -v O/1/2/3 : verbose mode (verbosity increasing with level)
  -f         : executing mode
               (execute the program even if the number of input files
                is not equal to the total number of domains)

We reconstruct:

/share/ORCHIDEE/modipsl/modeles/IOIPSL/bin/rebuild -o sechiba_history.nc sechiba_history_????.nc

[editar] Running the model in DCAO's computational lab

Follow this link runORDCAO to set-up the runs in the machines of DCAO's computational laboratory

[editar] OR4L: L. Fita's work-flow management for ORCHIDEE

ORCHIDEE should be run with libIGCM which is a work-flow management for ORCHIDEE developed at the IPSL.

However, L. Fita developed an independent simpler and less potent work-flow called OR4L. See how it works in this wiki page ORCHIDEE/OR4L OR4L

[editar] OR_1proc: DCAO's 1-proc work-flow management for ORCHIDEE

DCAO's computational lab machines are 1 processors standard machines. A new work-flow management has been created for such cases. Mostly related to the UMI & DCAO course of [land-atmosphere interaction and its modelling]. All the iformation is available in the wiki page OR1proc OR 1proc

Herramientas personales