4 | | more information under edition... |
| 4 | When doing simulation with the model, the parameter file run.def must be edited according to the set up of the experiment. |
| 5 | While running ORCHIDEE using the configurations with libIGCM, the modifications are done by the drivers : orchidee_ol.driver, sechiba.driver and stomate.driver for the offline case. Some of the standard choice in the set up for an experiment is done in the cards : config.card, orchidee_ol.card, sechiba.card and stomate.card. For example the choice of hydrology scheme is done in sechiba.card. More unusual choice are done directly in run.def file. |
| 6 | |
| 7 | The method for manipulation of parameters files in the offline and coupled libIGCM configurations have changed. The new method is based on the use of the functions IGCM_comp_modifyDefFile (for run.def, orchidee.def,... ) and IGCM_comp_modifyXmlFile (for xml files). The components drivers call one of these functions for each variable that has to be modified. |
| 8 | |
| 9 | == New method: in new ORCHIDEE_OL offline configuration, LMDZOR_v6 and IPSLCM6 configurations == |
| 10 | This is the method used in ORCHIDEE_OL since rev [2524].[[BR]] |
| 11 | |
| 12 | * Highlight: The drivers do not do any hidden modifications. |
| 13 | * A value set in run.def can only be modified by the driver if it is set equal AUTO |
| 14 | * A parameter can not be added by the driver |
| 15 | |
| 16 | '''Two types of parameters''' |
| 17 | * ''nonblocker parameter'' can be modified or removed from run.def. |
| 18 | Example ''nonblocker'' parameter, extract from PARAM/run.def in ORCHIDEE_OL/OOL_SEC_STO: |
| 19 | {{{ |
| 20 | # SECHIBA history output level (0..10) |
| 21 | SECHIBA_HISTLEVEL = _AUTO_ |
| 22 | }}} |
| 23 | |
| 24 | The variable SECHIBA_HISTLEVEL is set to AUTO because it is normally modified with a value from the default set up in sechiba.card. The value can be changed directly in run.def, for example SECHIBA_HISTLEVEL=3, and in that case, it will not be modified again by the driver. |
| 25 | |
| 26 | * ''blocker parameter'' can not be modified or removed from run.def. |
| 27 | Example, extract from PARAM/run.def in ORCHIDEE_OL/OOL_SEC_STO: |
| 28 | {{{ |
| 29 | # Name of restart to read for initial conditions of STOMATE |
| 30 | STOMATE_RESTART_FILEIN = _AUTOBLOCKER_ |
| 31 | }}} |
| 32 | The variable STOMATE_RESTART_FILEIN is set changed due to restart options set in config.card. It is an important parameter and is therefore a so called ''blocker parameter''. If a blocker parameter is changed, the job will stop before launching the model. For example if it is set to STOMATE_RESTART_FILEIN=stomate_rest_in.nc, then the job will stop. This parameter must contain the key word AUTO. |
| 33 | |
| 34 | |
| 35 | '''Implementation'''[[BR]] |
| 36 | The component's driver call the libIGCM function IGCM_comp_modifyDefFile (for run.def, orchidee.def,... ) or IGCM_comp_modifyXmlFile (for xml files) for each variable that needs to be manipulated. |
| 37 | |
| 38 | Example from sechiba.driver: |
| 39 | {{{ |
| 40 | IGCM_comp_modifyDefFile nonblocker run.def SECHIBA_HISTLEVEL ${sechiba_UserChoices_sechiba_LEVEL} |
| 41 | }}} |
| 42 | The first argument "nonblocker" gives the type of the parameter. In this case, nonblocker means that the parameter can be modified or removed from the parameter file. The other argmuments are file name, parameter name and final value. |
| 43 | |
| 44 | Example from stomate.driver: |
| 45 | {{{ |
| 46 | if ( [ ${CumulPeriod} -eq 1 ] && [ "${config_SBG_Restart}" = "n" ] ) ; then |
| 47 | echo "STOMATE : without restart" |
| 48 | IGCM_comp_modifyDefFile blocker run.def STOMATE_RESTART_FILEIN NONE |
| 49 | else |
| 50 | IGCM_comp_modifyDefFile blocker run.def STOMATE_RESTART_FILEIN stomate_rest_in.nc |
| 51 | fi |
| 52 | }}} |
| 53 | The function is here called with different values(NONE or stomate_rest_in.nc) for the parameter(STOMATE_RESTART_FILEIN) depending on which CumulPeriod and if an option for restart is set in config.card. The first argument is blocker which means that it can not be change from the parameter file. |
| 54 | |
| 55 | |
| 56 | == Method in previous ORCHIDEE_OL configuration == |
| 57 | This is the method used in ORCHIDEE_OL for revision older than rev 2523. |
| 58 | * A value set in run.def can not be modified if it is not set to AUTO |
| 59 | * PARAM/run.def is empty but the driver will add several parameters |
| 60 | |
| 61 | |
| 62 | In orchidee_ol.driver there is a function ORCHIDEE_def. This function is used to modify or add parameters in run.def file. In the beginning, PARAM/run.def file is nearly empty. The orchidee_ol.driver, sechiaba.driver and stomate.driver will add several parameters depending on settings in config.card, orchidee_ol.card, sechiba.card and stomate.card. '''If a parameter is already set in PARAM/run.def, the value will not be overwritten.''' |
| 63 | |
| 64 | |
| 65 | == Method in LMDZOR_v5 and all other _v5 configurations == |
| 66 | In these configurations, in the .def files all variables modified by the driver are set =AUTO. '''Even if one these parameters is changed, in PARAM/orchidee.def for example, the driver will overwrite the value.''' A message is written in Script_Output text file. |