wiki:LMDZoGuOR

Version 21 (modified by jgipsl, 13 years ago) (diff)

--

Configuration LMDZOR_v4 =

LMDZOR_v4 is the current version using LMDZ and ORCHIDEE. It is a configuration in phase with the coupled model IPSL-CM5. It can be used with LMDZ4 production version LMDZ4_AR5 or with one of the latest versions of LMDZ5/trunk.

Before running this model set up, choice between 2 mode has to be done : Interannuel AMIP simulation or climatologic simulation. No default setup is done. Nearly all the time, modifications in the lmdz.card or orchidee.card have to be done. Contact me if you need to modifie the lmdz.driver or orchidee.driver.

/J Ghattas


This configuration is a modified copy of LMDZ4OR_v3. Modifications are :

  • the grille 280x280x39 is added. This grid contains a zoom over Africa
  • only one run directory exist : LMDZOR. This directory can be used for different type of simulation for exemple AMIP interannual or climatolical run. Or nudged run with regular or zoomed grid. Only the .card changes for different run. The PARAM directory and the .driver are the same.

CREATE experience for creation of initial state and interpolating of boundary conditions

This experience is used to create boundary condition and initial state condition for LMDZ using the executable ce0l.e or create_etat0_limit.e. The CREATE experience does not have a PARAM directory. In CREATE/COMP/lmdz.card the parameter PARAM_DIR points to ../LMDZOR/PARAM.

In the CREATE experience, 2 cases for the boundary conditions are predefined : Creation using sea-surface temperature(SST) and sea-ice cover(SIC) from climatology AMIP files or for interannual AMIP files. According to the case, do a manual copy or link, for interannual AMIP :

ln -s config.card_Interannuel config.card; cd COMP; ln -s lmdz.card_Interannuel lmdz.card

or for climtology AMIP :

ln -s config.card_Climat config.card; cd COMP; ln -s lmdz.card_Climat lmdz.card

Boundary conditions using the model output

To create boundary conditions using output from LMDZ from a previous run do following steps : NB: it is not possible to use version LMDZ4_AR5 of ce0l. Use version LMDZ5/trunk revision 1508 or later. Once the boundary files limit.nc are created they can be used also with earlyer versions of LMDZ such as LMDZ4_AR5.

Step 1
Identify time series for the simulations that will be used and split them into yearly files. For the SST use the variable tsol_oce from LMDZ and for SIC use the variable pourc_sic. The variables should be at monthly time serie format. For exemple for the coupled rcp4.5 simulation at CCRT use files :

/dmnfs/cont003/p86denv/IGCM_OUT/IPSLCM5A/PROD/rcp45/v3.rcp45.1/ATM/Analyse/TS_MO/v3.rcp45.1_20060101_21251231_1M_tsol_oce.nc
/dmnfs/cont003/p86denv/IGCM_OUT/IPSLCM5A/PROD/rcp45/v3.rcp45.1/ATM/Analyse/TS_MO/v3.rcp45.1_20060101_21251231_1M_pourc_sic.nc

To split the time series into yearly files with 12 time steps in each file use cdo. For exemple :

cdo splityear model_output_file_tsol_oce  $WORKDIR/MY_DIR/v3.rcp45.1_tsol_oce_
cdo splityear model_output_file_pourc_sic $WORKDIR/MY_DIR/v3.rcp45.1_pourc_sic_

Step 1 bis If you whant to create anomaly SST instead of plein model output SST : do it now. See below.

Step 2
The yearly files are directly usable with the ce0l program revision 1508 LMDZ5/trunk or later. They should be renamed as histmth_sst.nc and histmth_sic.nc before running. The AMIP files must not be in the same run directory, in that case they will be used instead of the model output files. Use the CREATE interannual experience to create the interval of years needed. Change first in lmdz.card_Interannual AMIP yearly files towards yearly time series :

[BoundaryFiles]
List=   (${R_INIT}/ATM/${config_UserChoices_TagName}/AMIP/amipbc_sst_360x180_${year}.nc, amipbc_sst_1x1.nc), \
        (${R_INIT}/ATM/${config_UserChoices_TagName}/AMIP/amipbc_sic_360x180_${year}.nc, amipbc_sic_1x1.nc), \

into

[BoundaryFiles]
List=   (/the/whole/path/to/the/yearly/files_tosl_oce_${year}.nc,  histmth_sst.nc), \
        (/the/whole/path/to/the/yearly/files_pourc_sic_${year}.nc, histmth_sic.nc), \

Interpolating files for nudging

Script to do this are stored in CREATE/SCRIPT. To interpolated ERA-Interim use the script interp_from_era.ksh. You must first modify the beginning of this script. To interpolated LMDZ model output files use the script interp_from_TS.ksh. Both of these scripts depends on the script era2gcm.ksh. These scripts tested at mercure and ulam.

LMDZOR experience for running the gcm

In the LMDZOR experience, a climat or a AMIP(interannual) experience can be run. Before run a manual copy or link must be done :

cd LMDZOR/COMP; ln -s lmdz.card_Climat lmdz.card; ln -s orchidee.card_Climat orchidee.card

or

cd LMDZOR/COMP; ln -s lmdz.card_AMIP lmdz.card; ln -s orchidee.card_AMIP orchidee.card

Parametres in config.card such as JobName, CalendarType, DateBegin, DateEnd must be considered and eventally modified according to desired experience.


Problems running at VARGAS?

  • You should not compile with -O5 at VARGAS. Compile with -O3 or lower optimization. Default compiler xlf 13.1.0.3 is ok with -O3.
  • If the executable create_etat0_limit or ce0l exits with following error message you need to update your LMDZ version to revision 1476 at branch LMDZ4_AR5 or higher :

ERROR: 0032-184 MPI was not finalized in routine unknown, task 0

  • Check memory in your job. For higher resolutions you may need to add threads just to have more memory. You must then compile in mpi mode (default for create_etat0_limit.e.para) and not mixt mpi_openmpi. In your job, add @ parallel_threads = 8. This gives you 8 times more memory per process mpi availible and you can multiply data_limit and stack_limit by 8. When adding threads you should remove @ resources = ConsumableCpus(1). For exemple for resolution 280x280x39 put in your job :

# @ total_tasks = 32
# @ environment = "BATCH_NUM_PROC_TOT=32"
# @ parallel_threads = 8
# @ data_limit  = 18.0gb
# @ stack_limit = 6.0gb,6.0gb
### @ resources = ConsumableCpus(1)
  • You must desactivate the filtre fft if using branch LMDZ4_AR5 or earlier version of LMDZ. In run.def set use_filtre_fft = n.
  • In config.card you must change to
    JobRunOptions=''
    
    otherwise you'll have following error message :

ERROR: 0031-636 User requested or EOF termination of pm_command


Interpolation of nudge files

The files that will be used for the nudging must be interpolated to the model grid before running the gcm. This can be done either using a script get_era.x or using a patch in libIGCM, see below.

Interpolation using get_era.x

Follow step 1 to 3.

1) Create file grilles_gcm.nc
LMDZ contains a program that creates a file netcdf containg the grid u and v. This program is located in file LMDZ5/libf/dyn3d/grilles_gcm_netcdf.F. Compile this program with the same resolution as the gcm. For exemple if using the LMDZOR_v4/Makefile, add in Makefile :

(cd ../../modeles/LMDZ; ./makelmdz_fcm -cpp ORCHIDEE_NOOPENMP -d $(RESOL_LMDZ) -arch $(FCM_ARCH) grilles_gcm_netcdf ; cp bin/grilles_gcm_netcdf_$(RESOL_LMDZ)_phylmd_seq.e ../../bin/grilles_gcm_netcdf.e ; )

For a regular grid no parameter files are needed, just execute the program. If you have a zoom, execute the program together with your parameter files (run.def, gcm.def).

2) Modify and run get_era.x
The script get_era.x is stored in LMDZOR_v4/CREATE/SCRIPT and it is used together with era2gcm.x and add_step.x. These scripts have to be adapted according to the machine and file locations. To extract only interpolation scripts :

svn co http://forge.ipsl.jussieu.fr/igcmg/svn/CONFIG/LMDZOR/branches/LMDZOR_v4/CREATE/SCRIPT

Modifications :

  • in get_era.x set year and month to be interpolated. Set path to your grilles_gcm.nc file
  • in era2gcm.x set ANA_DIR to the path of ERAI files

During execution of get_era.x the directory OUT_ERAI will be created in the running directory.

3) Move interpolated files to archive directory

Interpolation using a patch in libIGCM

Interpolation is done in the CREATE job at the same time as execution of create_etat0_limit for creation of boudary files limit.nc. Using lmdz.card_Interannuel and config.card_Interannuel is necessary to interpolate over several years. libIGCM tag v1_10 is requierd.

To activate the patch modifications in CREATE/COMP/lmdz.card_Interannuel is needed. Add the files to interpolate in [BoundaryFiles]/List and in [OutputFiles]/List and add the paragraf [Nudge_Interp] in the end of lmdz.card. Here below is an exemple how to add u. In the same lmdz.card it is possible to add different files u,v,t,... using the same syntax :

[BoundaryFiles]
List=   (${R_INIT}/ATM/${config_UserChoices_TagName}/AMIP/amipbc_sst_360x180_${year}.nc, amipbc_sst_1x1.nc), \
	(${R_INIT}/ATM/${config_UserChoices_TagName}/AMIP/amipbc_sic_360x180_${year}.nc, amipbc_sic_1x1.nc), \
	(${R_INIT}/ATM/${config_UserChoices_TagName}/Ozone/HYBRIDE/v2.clim/tro3_${year}.new.nc, climoz.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}01.aphei.GLOBAL_075.nc, u_1_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}02.aphei.GLOBAL_075.nc, u_2_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}03.aphei.GLOBAL_075.nc, u_3_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}04.aphei.GLOBAL_075.nc, u_4_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}05.aphei.GLOBAL_075.nc, u_5_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}06.aphei.GLOBAL_075.nc, u_6_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}07.aphei.GLOBAL_075.nc, u_7_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}08.aphei.GLOBAL_075.nc, u_8_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}09.aphei.GLOBAL_075.nc, u_9_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}10.aphei.GLOBAL_075.nc, u_10_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}11.aphei.GLOBAL_075.nc, u_11_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year}/u.${year}12.aphei.GLOBAL_075.nc, u_12_${year}.nc), \
        (/u/rech/psl/rpsl376/ERAI/NETCDF/GLOBAL_075/4xdaily/AN_PL/${year_p1}/u.${year_p1}01.aphei.GLOBAL_075.nc, u_13_${year}.nc)

...

[OutputFiles]
List=	( limit.nc,       ${R_OUT_ATM_O}/Boundary/${config_UserChoices_JobName}_${year}_limit.nc,       NONE), \
	( climoz_LMDZ.nc, ${R_OUT_ATM_O}/Boundary/${config_UserChoices_JobName}_${year}_climoz_LMDZ.nc, NONE), \
	( start.nc,       ${R_OUT_ATM_O}/Restart/${config_UserChoices_JobName}_${year}_start.nc,        NONE), \
	( startphy.nc,    ${R_OUT_ATM_O}/Restart/${config_UserChoices_JobName}_${year}_startphy.nc,     NONE), \
        ( u_1_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}01_u.nc,       Post_Interp), \
        ( u_2_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}02_u.nc,       NONE), \
        ( u_3_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}03_u.nc,       NONE), \
        ( u_4_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}04_u.nc,       NONE), \
        ( u_5_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}05_u.nc,       NONE), \
        ( u_6_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}06_u.nc,       NONE), \
        ( u_7_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}07_u.nc,       NONE), \
        ( u_8_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}08_u.nc,       NONE), \
        ( u_9_${year}.nc,  ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}09_u.nc,       NONE), \
        ( u_10_${year}.nc, ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}10_u.nc,       NONE), \
        ( u_11_${year}.nc, ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}11_u.nc,       NONE), \
        ( u_12_${year}.nc, ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}12_u.nc,       NONE), \
        ( u_13_${year}.nc, ${R_OUT_ATM_O}/Nudgefiles/${config_UserChoices_JobName}_${year}13_u.nc,       NONE)



# This patch is applied to the first file but it will work on all files u01.nc - u13.nc
[Post_Interp]
Patches = (Patch_20101208_nudge_interp)
GatherWithInternal = ()
TimeSeriesVars2D = ()
ChunckJob2D = NONE
TimeSeriesVars3D = ()
ChunckJob3D = NONE
Seasonal=OFF

In config.card it is necessary to put :

RebuildFrequency=1Y

Differentes experiences

Différences actuelle entre LMDZOR et AMIP :

Fichier LMDZOR AMIP Commentaires
COMP/lmdz.card ELC-${RESOL_ATM_3D} ELI-${RESOL_ATM_3D} CREATE (nom du job create_etat0_limit)
clim_start.nc ${year}_start.nc fichier climat / inter annuelle
clim_startphy.nc ${year}_startphy.nc fichier climat / inter annuelle
clim_limit.nc ${year}_limit.nc fichier climat / inter annuelle
aerosols_11YearsClim_1860.nc aerosols_11YearsClim_1855.nc aerosols.nat.nc
aerosols_11YearsClim_1995.nc aerosols1980.nc
aerosols_11YearsClim_${year}.nc aerosols${year}.nc, 1:12: (smoothfile : à partir de la 1ère toutes les 12 périodes (mois) [min]:[modulo:][max] )
climoz_LMDZ_1995.nc climoz_LMDZ_${year}.nc, climoz_LMDZ.nc, 1:12: climoz_LMDZ.nc
CO2_1765_2005.txt
CH4_1765_2005.txt
N2O_1765_2005.txt
CFC11_1765_2005.txt
CFC12_1765_2005.txt
guide.def a mettre aussi dans LMDZOR!||
COMP/lmdz.driver IPCC_CO2= ... ; LMDZ_sed physiq.def co2_ppm ${IPCC_CO2} update physiq.def with values from file .txt :
solaire, co2_ppm, CH4_ppb, N2O_ppb, CFC11_ppt, CFC12_ppt
COMP/orchidee.card PFTmap_IPCC_2000.nc ${BC_SRF_PFTmap} = PFTmap_1850to2005_AR5_LUHa.rc2.nc new function in driver will choose PFTmap
or ORCHIDEE_PFTmap_2006to2100_AR5_RCP8.5_MESSAGE.nc
COMP/orchidee.driver srf_period_start new function for choice of PFTmap before and after 2004
cas test : modif for certain years VEGET_REINIT
cas test : modif for certain years VEGET_YEAR
PARAM/orchidee.def 0Y 1Y VEGET_UPDATE
n y LAND_COVER_CHANGE = n
PARAM/physiq.def_L39 0.008 0.0 pmagic
1366.0896 1365.6537 solaire RQ: le valeur dans AMIP sera ecraser
actuel annuel aer_type

Commentaires :

  • orchidee.driver pourrait être le même car srf_period_start prend effet en utilisant le variable ${BC_SRF_PFTmap}, qui se fait dans orchidee.card. On pourrait donc avoir : orchidee.card_Climat et orchidee.card_Interannuel
  • Les différentes valeurs dans les .def pourrait être mis dans lmdz.card et orchidee.card pour ensuite être modifié avec sed
  • guide.def pourrait etre mis dans les 2 expériences