New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
sette_reference-configurations.sh in utils/CI/r12931_sette_ticket2462 – NEMO

source: utils/CI/r12931_sette_ticket2462/sette_reference-configurations.sh @ 13900

Last change on this file since 13900 was 13755, checked in by andmirek, 4 years ago

Ticket #2462: Sette to test restarts read/write with XIOS

  • Property svn:executable set to *
File size: 63.3 KB
RevLine 
[3520]1#!/bin/bash
[3708]2############################################################
[3520]3# Author : Simona Flavoni for NEMO
[4245]4# Contact: sflod@locean-ipsl.upmc.fr
5# 2013   : A.C. Coward added options for testing with XIOS in dettached mode
[3520]6#
7# sette.sh   : principal script of SET TEsts for NEMO (SETTE)
8# ----------------------------------------------------------------------
9# NEMO/SETTE , NEMO Consortium (2010)
10# Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
11# ----------------------------------------------------------------------
12#
13#############################################################
[7744]14#set -vx
[3520]15set -o posix
16#set -u
17#set -e
[4245]18# ===========
[3520]19# DESCRIPTION
20# ===========
21#
22# Variables to be checked by user:
23#
[4245]24# COMPILER          : name of compiler as defined in NEMOGCM/ARCH directory
25# BATCH_COMMAND_PAR :  name of the command for submitting parallel batch jobs
26# BATCH_COMMAND_SEQ :  name of the command for submitting sequential batch jobs 
27# INTERACT_FLAG     : flag to run in interactive mode "yes"
28#                           to run in batch mode "no"
29# MPIRUN_FLAG       : flag to run in parallel (MPI) "yes"
30#                           to run in sequential mode (NB_PROC = 1) "no"
31# USING_XIOS        : flag to control the activation of key_iomput
32#                      "yes" to compile using key_iomput and link to the external XIOS library
33#                      "no"  to compile without key_iomput and link to the old IOIPSL library
34# USING_MPMD        : flag to control the use of stand-alone IO servers
35#                     requires USING_XIOS="yes"
36#                      "yes" to run in MPMD (detached) mode with stand-alone IO servers
37#                      "no"  to run in SPMD (attached) mode without separate IO servers
38# NUM_XIOSERVERS    : number of stand-alone IO servers to employ
39#                     set to zero if USING_MPMD="no"
[3520]40#
41# Principal script is sette.sh, that calls
42#
[4245]43#  makenemo  : to create successive exectuables in ${CONFIG_NAME}/BLD/bin/nemo.exe
[9576]44#              and links to nemo in ${CONFIG_NAME}/EXP00)
[3520]45#
46#  param.cfg : sets and loads following directories:
47#
[4245]48#   FORCING_DIR         : is the directory for forcing files (tarfile)
49#   INPUT_DIR           : is the directory for input files storing
50#   TMPDIR              : is the temporary directory (if needed)
[3520]51#   NEMO_VALIDATION_DIR : is the validation directory
52#
53#   (NOTE: this file is the same for all configrations to be tested with sette)
54#
[4245]55#   all_functions.sh : loads functions used by sette (note: new functions can be added here)
56#   set_namelist     : function declared in all_functions that sets namelist parameters
57#   post_test_tidyup : creates validation storage directory and copies required output files
[9019]58#                      (run.stat and ocean.output) in it after execution of test.
[3520]59#
[4245]60#  VALIDATION tree is:
[3520]61#
62#   NEMO_VALIDATION_DIR/WCONFIG_NAME/WCOMPILER_NAME/TEST_NAME/REVISION_NUMBER(or DATE)
63#
64#  prepare_exe_dir.sh : defines and creates directory where the test is executed
[4245]65#                       execution directory takes name of TEST_NAME defined for every test
66#                       in sette.sh. (each test in executed in its own directory)
[3520]67#
[10755]68#  set_valid_dir       : rename ocean.output/run.stat and tracer.stat to avoid checking them in the report
69#
[10698]70#  clean_valid_dir    : rename ocean.output/run.stat and tracer.stat to avoid checking them in the report
71#                       ( not doing it could lead to false positive )
72#
[4245]73#  prepare_job.sh     : to generate the script run_job.sh
[3520]74#
[4245]75#  fcm_job.sh         : run in batch (INTERACT_FLAG="no") or interactive (INTERACT_FLAG="yes")
76#                        see sette.sh and BATCH_TEMPLATE directory
[3520]77#
[4245]78#  NOTE: jobs requiring initial or forcing data need to have an input_CONFIG.cfg in which
79#        can be found paths to the input tar file)
80#  NOTE: if job is not launched for any reason you have the executable ready in ${EXE_DIR}
81#        directory
82#  NOTE: the changed namelists are left in ${EXE_DIR} directory whereas original namelists
83#        remain in ${NEW_CONF}/EXP00
[3520]84#
[4245]85#  NOTE: a log file, output.sette, is created in ${SETTE_DIR} with the echoes of
86#        executed commands
[3520]87#
[4245]88#  NOTE: if sette.sh is stopped in output.sette there is written the last command
89#        executed by sette.sh
[3520]90#
[4245]91# example use: ./sette.sh
92#########################################################################################
[3520]93#
[10687]94# LOAD param value
[10717]95SETTE_DIR=$(cd $(dirname "$0"); pwd)
96MAIN_DIR=$(dirname $SETTE_DIR)
[10687]97. ./param.cfg
[7743]98
[10687]99export BATCH_COMMAND_PAR=${BATCH_CMD}
100export BATCH_COMMAND_SEQ=${BATCH_CMD}
[4990]101export INTERACT_FLAG="no"
[4245]102export MPIRUN_FLAG="yes"
[9941]103export USING_ICEBERGS="yes"
[3520]104#
[4245]105export DEL_KEYS="key_iomput"
106if [ ${USING_XIOS} == "yes" ] 
107 then
108   export DEL_KEYS=""
109fi
[3520]110#
[10687]111export ADD_KEYS=""
112if [ ${ADD_NOSIGNEDZERO} == "yes" ]
113 then
114   export ADD_KEYS="key_nosignedzero"
115fi
116#
[4245]117# Settings which control the use of stand alone servers (only relevant if using xios)
[3520]118#
[10632]119export NUM_XIOSERVERS=4
[11140]120export JOB_PREFIX=${JOB_PREFIX_MPMD}
[3520]121#
[4245]122if [ ${USING_MPMD} == "no" ] 
123 then
124   export NUM_XIOSERVERS=0
[11140]125   export JOB_PREFIX=${JOB_PREFIX_NOMPMD}
[4245]126fi
[3520]127#
128#
[10573]129if [ ${USING_MPMD} == "yes" ] && [ ${USING_XIOS} == "no" ]
[4245]130 then
131   echo "Incompatible choices. MPMD mode requires the XIOS server"
132   exit
133fi
[3520]134
135# Directory to run the tests
[9602]136CONFIG_DIR0=${MAIN_DIR}/cfgs
137TOOLS_DIR=${MAIN_DIR}/tools
[3520]138
139CMP_NAM=${1:-$COMPILER}
140# Copy job_batch_COMPILER file for specific compiler into job_batch_template
141cd ${SETTE_DIR}
[4245]142cp BATCH_TEMPLATE/${JOB_PREFIX}-${COMPILER} job_batch_template || exit
[10747]143# Description of available configurations:
144# GYRE_PISCES       :
145# ORCA2_ICE_PISCES  :
146# ORCA2_OFF_PISCES  :
147# AMM12             :
148# SAS               :
149# ORCA2_ICE_OBS     :
150# AGRIF             : test AGRIF in a double zoom configuration in the nordic seas + 1 zoom in the eq. Pacific (AGRIF_DEMO)
151#                       and check that key_agrif without zoom = no key_agrif
[13754]152# WED025           : regional configuration including sea-ice and tides (Spitzbergen)
[4147]153
[10747]154for config in ${TEST_CONFIGS}
[3520]155do
156
[9518]157# -----------
158# GYRE_PISCES
159# -----------
[10747]160if [ ${config} == "GYRE_PISCES" ] ;  then
[9518]161## Restartability tests for GYRE_PISCES
[13754]162    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
163    then
164   ITEND=12    # 1 day
165    else
166   ITEND=1080  # 90 days
167    fi
168    ITRST=$( printf "%08d" $(( ${ITEND} / 2 )) )
[3520]169    export TEST_NAME="LONG"
[9658]170    cd ${MAIN_DIR}
[12569]171    #
172    # syncronisation if target directory/file exist (not done by makenemo)
173    . ${SETTE_DIR}/all_functions.sh
174    sync_config  GYRE_PISCES GYRE_PISCES_ST 'cfgs'
175    clean_config GYRE_PISCES GYRE_PISCES_ST 'cfgs'
176    #
[11497]177    . ./makenemo -m ${CMP_NAM} -n GYRE_PISCES_ST -r GYRE_PISCES -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[3520]178    cd ${SETTE_DIR}
[4252]179    . ./param.cfg
180    . ./all_functions.sh
181    . ./prepare_exe_dir.sh
[10755]182    set_valid_dir
[10698]183    clean_valid_dir
[3520]184    JOB_FILE=${EXE_DIR}/run_job.sh
[9525]185    NPROC=8
[4245]186    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[4147]187    cd ${EXE_DIR} 
[7715]188    set_namelist namelist_cfg cn_exp \"GYREPIS_LONG\"
[4147]189    set_namelist namelist_cfg nn_it000 1
[13754]190    set_namelist namelist_cfg nn_itend ${ITEND}
191    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]192    set_namelist namelist_cfg ln_linssh .true.
[9525]193    set_namelist namelist_cfg jpni 2
194    set_namelist namelist_cfg jpnj 4
[10573]195    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
196    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[12999]197    if [ ${USING_XIOS_RRW} == "yes" ]
198       then
199       set_namelist namelist_cfg nn_wxios 1
200    fi
[4245]201    if [ ${USING_MPMD} == "yes" ] ; then
202       set_xio_using_server iodef.xml true
203    else
204       set_xio_using_server iodef.xml false
205    fi
206    cd ${SETTE_DIR}
[10755]207    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]208
209    cd ${SETTE_DIR}
210    export TEST_NAME="SHORT"
[4252]211    . ./prepare_exe_dir.sh
[10755]212    set_valid_dir
[10698]213    clean_valid_dir
[3520]214    cd ${EXE_DIR}
[7715]215    set_namelist namelist_cfg cn_exp \"GYREPIS_SHORT\"
[13754]216    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
217    set_namelist namelist_cfg nn_itend ${ITEND}
218    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[4147]219    set_namelist namelist_cfg ln_rstart .true.
220    set_namelist namelist_cfg nn_rstctl 2
[7646]221    set_namelist namelist_cfg ln_linssh .true.
[9525]222    set_namelist namelist_cfg jpni 2
223    set_namelist namelist_cfg jpnj 4
[10573]224    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
225    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[7744]226    set_namelist namelist_top_cfg ln_rsttr .true.
227    set_namelist namelist_top_cfg nn_rsttr 2
[13754]228    set_namelist namelist_cfg cn_ocerst_in \"GYREPIS_LONG_${ITRST}_restart\"
229    set_namelist namelist_top_cfg cn_trcrst_in \"GYREPIS_LONG_${ITRST}_restart_trc\"
[12999]230    if [ ${USING_XIOS_RRW} == "yes" ]
231       then
232       set_namelist namelist_cfg nn_wxios 1
233       set_namelist namelist_cfg ln_xios_read .true.
234    fi
[4245]235    if [ ${USING_MPMD} == "yes" ] ; then
236       set_xio_using_server iodef.xml true
237    else
238       set_xio_using_server iodef.xml false
239    fi
[13755]240
241    if [ ${USING_XIOS_RRW} == "yes" ]
242       then
243        ln -sf ../LONG/GYREPIS_LONG_${ITRST}_restart.nc .
244        ln -sf ../LONG/GYREPIS_LONG_${ITRST}_restart_trc.nc .
245    else
246        for (( i=1; i<=$NPROC; i++)) ; do
247            L_NPROC=$(( $i - 1 ))
248            L_NPROC=`printf "%04d\n" ${L_NPROC}`
249            ln -sf ../LONG/GYREPIS_LONG_${ITRST}_restart_${L_NPROC}.nc .
250            ln -sf ../LONG/GYREPIS_LONG_${ITRST}_restart_trc_${L_NPROC}.nc .
251        done
252    fi
[3520]253    cd ${SETTE_DIR}
[10755]254    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]255    cd ${SETTE_DIR}
[3532]256    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3520]257
[9518]258## Reproducibility tests for GYRE_PISCES
[9525]259    export TEST_NAME="REPRO_2_4"
[9658]260    cd ${MAIN_DIR}
[3520]261    cd ${SETTE_DIR}
[4252]262    . ./param.cfg
263    . ./all_functions.sh
264    . ./prepare_exe_dir.sh
[10755]265    set_valid_dir
[10698]266    clean_valid_dir
[3520]267    JOB_FILE=${EXE_DIR}/run_job.sh
[9525]268    NPROC=8
[4245]269    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]270    cd ${EXE_DIR}
[7715]271    set_namelist namelist_cfg cn_exp \"GYREPIS_48\"
[4147]272    set_namelist namelist_cfg nn_it000 1
[13754]273    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]274    set_namelist namelist_cfg ln_linssh .true.
[9525]275    set_namelist namelist_cfg jpni 2
276    set_namelist namelist_cfg jpnj 4
[10573]277    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
278    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[13755]279    if [ ${USING_XIOS_RRW} == "yes" ]
280       then
[12999]281       set_namelist namelist_cfg nn_wxios 1
282    fi
[4245]283    if [ ${USING_MPMD} == "yes" ] ; then
284       set_xio_using_server iodef.xml true
285    else
286       set_xio_using_server iodef.xml false
287    fi
[3520]288    cd ${SETTE_DIR}
[10755]289    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]290    cd ${SETTE_DIR}
291    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
292
293    cd ${SETTE_DIR}
[9525]294    export TEST_NAME="REPRO_4_2"
[4252]295    . ./prepare_exe_dir.sh
[10755]296    set_valid_dir
[10698]297    clean_valid_dir
[3680]298    JOB_FILE=${EXE_DIR}/run_job.sh
[9525]299    NPROC=8
[4245]300    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]301    cd ${EXE_DIR}
[7715]302    set_namelist namelist_cfg cn_exp \"GYREPIS_84\"
[4147]303    set_namelist namelist_cfg nn_it000 1
[13754]304    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]305    set_namelist namelist_cfg ln_linssh .true.
[9525]306    set_namelist namelist_cfg jpni 4
307    set_namelist namelist_cfg jpnj 2
[10573]308    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
309    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[4245]310    if [ ${USING_MPMD} == "yes" ] ; then
311       set_xio_using_server iodef.xml true
312    else
313       set_xio_using_server iodef.xml false
314    fi
[3520]315    cd ${SETTE_DIR}
[10755]316    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]317    cd ${SETTE_DIR}
318    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3532]319
[3520]320fi
321
[9518]322# -----------------
[9663]323# ORCA2_ICE_PISCES
[9518]324# -----------------
[10747]325if [ ${config} == "ORCA2_ICE_PISCES" ] ;  then
[9663]326## Restartability tests for ORCA2_ICE_PISCES
[13754]327    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
328    then
329   ITEND=16   # 1 day
330    else
331   ITEND=992  # 62 days
332    fi
333    ITRST=$( printf "%08d" $(( ${ITEND} / 2 )) )
[7646]334    export TEST_NAME="LONG"
[9658]335    cd ${MAIN_DIR}
[12569]336    #
337    # syncronisation if target directory/file exist (not done by makenemo)
338    . ${SETTE_DIR}/all_functions.sh
339    sync_config  ORCA2_ICE_PISCES ORCA2_ICE_PISCES_ST 'cfgs'
340    clean_config ORCA2_ICE_PISCES ORCA2_ICE_PISCES_ST 'cfgs'
341    #
[11497]342    . ./makenemo -m ${CMP_NAM} -n ORCA2_ICE_PISCES_ST -r ORCA2_ICE_PISCES -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[7646]343    cd ${SETTE_DIR}
344    . ./param.cfg
345    . ./all_functions.sh
346    . ./prepare_exe_dir.sh
[10755]347    set_valid_dir
[10698]348    clean_valid_dir
[7646]349    JOB_FILE=${EXE_DIR}/run_job.sh
350    NPROC=32
351    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
352    cd ${EXE_DIR}
[13755]353    if [ ${USING_XIOS_RRW} == "yes" ]
354       then
355       set_namelist namelist_cfg nn_wxios 1
356    fi
[7646]357    set_namelist namelist_cfg cn_exp \"O2L3P_LONG\"
358    set_namelist namelist_cfg nn_it000 1
[13754]359    set_namelist namelist_cfg nn_itend ${ITEND}
360    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]361    set_namelist namelist_cfg jpni 4
362    set_namelist namelist_cfg jpnj 8
[10573]363    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
364    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[9933]365    set_namelist namelist_cfg ln_use_calving .true.
[10189]366    set_namelist namelist_cfg ln_wave .true.
367    set_namelist namelist_cfg ln_cdgw .true.
368    set_namelist namelist_cfg ln_sdw  .true.
369    set_namelist namelist_cfg nn_sdrift 1
370    set_namelist namelist_cfg ln_stcor .true.
371    set_namelist namelist_cfg ln_tauwoc .true.
[9904]372    #
373    if [ ${USING_ICEBERGS} == "no" ] ; then set_namelist namelist_cfg ln_icebergs .false. ; fi
[10687]374    # for debugging purposes set_namelist namelist_cfg rn_test_box -180.0, 180.0, -90.0, -55.0
[9904]375    #
[9019]376    set_namelist namelist_ice_cfg ln_icediachk .true.
[4147]377    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]378    set_namelist namelist_top_cfg ln_trcbc  .false.
379    # put ln_ironsed, ln_hydrofe to false
[3520]380    # if not you need input files, and for tests is not necessary
[4147]381    set_namelist namelist_pisces_cfg ln_varpar .false.
382    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]383    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]384    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[9203]385    # put ln_pisdmp to false : no restoring to global mean value
386    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[4245]387    if [ ${USING_MPMD} == "yes" ] ; then
388       set_xio_using_server iodef.xml true
389    else
390       set_xio_using_server iodef.xml false
391    fi
[3520]392    cd ${SETTE_DIR}
[10755]393    . ./prepare_job.sh input_ORCA2_ICE_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3532]394   
395    cd ${SETTE_DIR}
[3520]396    export TEST_NAME="SHORT"
[4252]397    . ./prepare_exe_dir.sh
[10755]398    set_valid_dir
[10698]399    clean_valid_dir
[3520]400    cd ${EXE_DIR}
[7646]401    set_namelist namelist_cfg cn_exp \"O2L3P_SHORT\"
[13754]402    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
403    set_namelist namelist_cfg nn_itend ${ITEND}
404    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[4147]405    set_namelist namelist_cfg ln_rstart .true.
406    set_namelist namelist_cfg nn_rstctl 2
[7646]407    set_namelist namelist_cfg jpni 4
408    set_namelist namelist_cfg jpnj 8
[10573]409    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
410    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[9920]411    set_namelist namelist_cfg nn_test_icebergs -1
[10189]412    set_namelist namelist_cfg ln_wave .true.
413    set_namelist namelist_cfg ln_cdgw .true.
414    set_namelist namelist_cfg ln_sdw  .true.
415    set_namelist namelist_cfg nn_sdrift 1
416    set_namelist namelist_cfg ln_stcor .true.
417    set_namelist namelist_cfg ln_tauwoc .true.
[12999]418    if [ ${USING_XIOS_RRW} == "yes" ]
419       then
420       set_namelist namelist_cfg nn_wxios 1
421       set_namelist namelist_cfg ln_xios_read .true.
422    fi
[9904]423    #
424    if [ ${USING_ICEBERGS} == "no" ] ; then set_namelist namelist_cfg ln_icebergs .false. ; fi
[10732]425    # for debugging purposes set_namelist namelist_cfg rn_test_box -180.0, 180.0, -90.0, -55.0
[9904]426    #
[9933]427    set_namelist namelist_ice_cfg ln_icediachk .true.
[4147]428    set_namelist namelist_top_cfg ln_rsttr .true.
429    set_namelist namelist_top_cfg nn_rsttr 2
[13754]430    set_namelist namelist_cfg cn_ocerst_in \"O2L3P_LONG_${ITRST}_restart\"
431    set_namelist namelist_cfg cn_icbrst_in \"O2L3P_LONG_${ITRST}_restart_icb\"
432    set_namelist namelist_top_cfg cn_trcrst_in \"O2L3P_LONG_${ITRST}_restart_trc\"
433    set_namelist namelist_ice_cfg cn_icerst_in \"O2L3P_LONG_${ITRST}_restart_ice\"
[12428]434    set_namelist namelist_top_cfg ln_trcbc  .false.
435    # put ln_ironsed, ln_hydrofe to false
[3520]436    # if not you need input files, and for tests is not necessary
[4147]437    set_namelist namelist_pisces_cfg ln_varpar .false.
438    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]439    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]440    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[3680]441    # put ln_pisdmp to false : no restoring to global mean value
[4147]442    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[13755]443    if [ ${USING_XIOS_RRW} == "yes" ]
444       then
445           ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart.nc .
446           ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_trc.nc .
447           ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_ice.nc .
448           if [ ${USING_ICEBERGS} == "yes" ]
449                  then
450                   for (( i=1; i<=$NPROC; i++)) ; do
451                      L_NPROC=$(( $i - 1 ))
452                      L_NPROC=`printf "%04d\n" ${L_NPROC}`
453                      ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_icb_${L_NPROC}.nc O2L3P_LONG_${ITRST}_restart_icb_${L_NPROC}.nc
454                   done
455           fi
456    else
457        for (( i=1; i<=$NPROC; i++)) ; do
458           L_NPROC=$(( $i - 1 ))
459           L_NPROC=`printf "%04d\n" ${L_NPROC}`
460           ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_${L_NPROC}.nc .
461           ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_trc_${L_NPROC}.nc .
462           ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_ice_${L_NPROC}.nc .
463           if [ ${USING_ICEBERGS} == "yes" ]
464               then
465                ln -sf ../LONG/O2L3P_LONG_${ITRST}_restart_icb_${L_NPROC}.nc O2L3P_LONG_${ITRST}_restart_icb_${L_NPROC}.nc
466           fi
467       done
[12999]468    fi
[4245]469    if [ ${USING_MPMD} == "yes" ] ; then
470       set_xio_using_server iodef.xml true
471    else
472       set_xio_using_server iodef.xml false
473    fi
[3520]474    cd ${SETTE_DIR}
[10755]475    . ./prepare_job.sh input_ORCA2_ICE_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]476    cd ${SETTE_DIR}
[3532]477    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3520]478
[9663]479## Reproducibility tests for ORCA2_ICE_PISCES
[7646]480    export TEST_NAME="REPRO_4_8"
[9658]481    cd ${MAIN_DIR}
[3520]482    cd ${SETTE_DIR}
[4252]483    . ./param.cfg
484    . ./all_functions.sh
485    . ./prepare_exe_dir.sh
[10755]486    set_valid_dir
[10698]487    clean_valid_dir
[3520]488    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]489    NPROC=32
[4245]490    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]491    cd ${EXE_DIR}
[9019]492    set_namelist namelist_cfg cn_exp \"O2L3P_48\"
[4147]493    set_namelist namelist_cfg nn_it000 1
[13754]494    set_namelist namelist_cfg nn_itend ${ITEND}
[4147]495    set_namelist namelist_cfg jpni 4
[7646]496    set_namelist namelist_cfg jpnj 8
[10573]497    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
498    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[10189]499    set_namelist namelist_cfg ln_wave .true.
500    set_namelist namelist_cfg ln_cdgw .true.
501    set_namelist namelist_cfg ln_sdw  .true.
502    set_namelist namelist_cfg nn_sdrift 1
503    set_namelist namelist_cfg ln_stcor .true.
504    set_namelist namelist_cfg ln_tauwoc .true.
505
[9904]506    if [ ${USING_ICEBERGS} == "no" ] ; then set_namelist namelist_cfg ln_icebergs .false. ; fi
[10687]507    # for debugging purposes set_namelist namelist_cfg rn_test_box -180.0, 180.0, -90.0, -55.0
508
[4147]509    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]510    set_namelist namelist_top_cfg ln_trcbc  .false.
511    # put ln_ironsed, ln_hydrofe to false
[3520]512    # if not you need input files, and for tests is not necessary
[4147]513    set_namelist namelist_pisces_cfg ln_varpar .false.
514    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]515    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]516    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[3680]517    # put ln_pisdmp to false : no restoring to global mean value
[4147]518    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[4245]519    if [ ${USING_MPMD} == "yes" ] ; then
520       set_xio_using_server iodef.xml true
521    else
522       set_xio_using_server iodef.xml false
523    fi
[3520]524    cd ${SETTE_DIR}
[10755]525    . ./prepare_job.sh input_ORCA2_ICE_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]526    cd ${SETTE_DIR}
[3532]527    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3520]528
529    cd ${SETTE_DIR}
[7646]530    export TEST_NAME="REPRO_8_4"
[4252]531    . ./prepare_exe_dir.sh
[10755]532    set_valid_dir
[10698]533    clean_valid_dir
[3680]534    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]535    NPROC=32
[4245]536    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]537    cd ${EXE_DIR}
[9019]538    set_namelist namelist_cfg cn_exp \"O2L3P_84\"
[4147]539    set_namelist namelist_cfg nn_it000 1
[13754]540    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]541    set_namelist namelist_cfg jpni 8
542    set_namelist namelist_cfg jpnj 4
[10573]543    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
544    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[10189]545    set_namelist namelist_cfg ln_wave .true.
546    set_namelist namelist_cfg ln_cdgw .true.
547    set_namelist namelist_cfg ln_sdw  .true.
548    set_namelist namelist_cfg nn_sdrift 1
549    set_namelist namelist_cfg ln_stcor .true.
550    set_namelist namelist_cfg ln_tauwoc .true.
[10687]551
[9904]552    if [ ${USING_ICEBERGS} == "no" ] ; then set_namelist namelist_cfg ln_icebergs .false. ; fi
[10687]553    # for debugging purposes set_namelist namelist_cfg rn_test_box -180.0, 180.0, -90.0, -55.0
554
[4147]555    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]556    set_namelist namelist_top_cfg ln_trcbc  .false.
557    # put ln_ironsed, ln_hydrofe to false
[3520]558    # if not you need input files, and for tests is not necessary
[4147]559    set_namelist namelist_pisces_cfg ln_varpar .false.
560    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]561    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]562    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[13755]563    if [ ${USING_XIOS_RRW} == "yes" ]
564       then
565       set_namelist namelist_cfg nn_wxios 1
566    fi
[3680]567    # put ln_pisdmp to false : no restoring to global mean value
[4147]568    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[4245]569    if [ ${USING_MPMD} == "yes" ] ; then
570       set_xio_using_server iodef.xml true
571    else
572       set_xio_using_server iodef.xml false
573    fi
[3520]574    cd ${SETTE_DIR}
[10755]575    . ./prepare_job.sh input_ORCA2_ICE_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]576    cd ${SETTE_DIR}
577    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
578fi
579
[9518]580# ----------------
581# ORCA2_OFF_PISCES
582# ----------------
[10747]583if [ ${config} == "ORCA2_OFF_PISCES" ] ;  then
[9518]584## Restartability tests for ORCA2_OFF_PISCES
[13754]585    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
586    then
587   ITEND=16   # 4 days
588    else
589   ITEND=380  # 95 days
590    fi
591    ITRST=$( printf "%08d" $(( ${ITEND} / 2 )) )
[3520]592    export TEST_NAME="LONG"
[9658]593    cd ${MAIN_DIR}
[12569]594    #
595    # syncronisation if target directory/file exist (not done by makenemo)
596    . ${SETTE_DIR}/all_functions.sh
597    sync_config  ORCA2_OFF_PISCES ORCA2_OFF_PISCES_ST 'cfgs'
598    clean_config ORCA2_OFF_PISCES ORCA2_OFF_PISCES_ST 'cfgs'
599    #
[11497]600    . ./makenemo -m ${CMP_NAM} -n ORCA2_OFF_PISCES_ST -r ORCA2_OFF_PISCES -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[3520]601    cd ${SETTE_DIR}
[4252]602    . ./param.cfg
603    . ./all_functions.sh
604    . ./prepare_exe_dir.sh
[10755]605    set_valid_dir
[10698]606    clean_valid_dir
[3520]607    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]608    NPROC=32
[4245]609    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]610    cd ${EXE_DIR}
[4147]611    set_namelist namelist_cfg cn_exp \"OFFP_LONG\"
612    set_namelist namelist_cfg nn_it000 1
[13754]613    set_namelist namelist_cfg nn_itend ${ITEND}
614    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]615    set_namelist namelist_cfg jpni 4
616    set_namelist namelist_cfg jpnj 8
[10573]617    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
618    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[9904]619    set_namelist namelist_cfg ln_qsr_rgb .true.
[4147]620    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]621    set_namelist namelist_top_cfg ln_trcbc  .false.
622    # put ln_ironsed, ln_hydrofe to false
[3520]623    # if not you need input files, and for tests is not necessary
[4147]624    set_namelist namelist_pisces_cfg ln_varpar .false.
625    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]626    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]627    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[3680]628    # put ln_pisdmp to false : no restoring to global mean value
[4147]629    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[13755]630    if [ ${USING_XIOS_RRW} == "yes" ]
631       then
632       set_namelist namelist_cfg nn_wxios 1
633    fi
[4245]634    if [ ${USING_MPMD} == "yes" ] ; then
635       set_xio_using_server iodef.xml true
636    else
637       set_xio_using_server iodef.xml false
638    fi
[3520]639    cd ${SETTE_DIR}
[10755]640    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]641   
642    cd ${SETTE_DIR}
643    export TEST_NAME="SHORT"
[4252]644    . ./prepare_exe_dir.sh
[10755]645    set_valid_dir
[10698]646    clean_valid_dir
[3520]647    cd ${EXE_DIR}
[4147]648    set_namelist namelist_cfg cn_exp \"OFFP_SHORT\"
[13754]649    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
650    set_namelist namelist_cfg nn_itend ${ITEND}
651    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]652    set_namelist namelist_cfg jpni 4
653    set_namelist namelist_cfg jpnj 8
[10573]654    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
655    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[9904]656    set_namelist namelist_cfg ln_qsr_rgb .true.
[13755]657    set_namelist namelist_top_cfg ln_rsttr .true.
658    set_namelist namelist_top_cfg nn_rsttr 2
659    set_namelist namelist_top_cfg cn_trcrst_in \"OFFP_LONG_${ITRST}_restart_trc\"
660    if [ ${USING_XIOS_RRW} == "yes" ]
661       then
[12999]662       set_namelist namelist_cfg nn_wxios 1
663       set_namelist namelist_cfg ln_xios_read .true.
664    fi
[13755]665    if [ ${USING_XIOS_RRW} == "yes" ]
666       then
667        ln -sf ../LONG/OFFP_LONG_${ITRST}_restart_trc.nc .
668    else
669        for (( i=1; i<=$NPROC; i++)) ; do
670            L_NPROC=$(( $i - 1 ))
671            L_NPROC=`printf "%04d\n" ${L_NPROC}`
672            ln -sf ../LONG/OFFP_LONG_${ITRST}_restart_trc_${L_NPROC}.nc .
673        done
674    fi
[12428]675    set_namelist namelist_top_cfg ln_trcbc  .false.
676    # put ln_ironsed, ln_hydrofe to false
[3520]677    # if not you need input files, and for tests is not necessary
[4147]678    set_namelist namelist_pisces_cfg ln_varpar .false.
679    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]680    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]681    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[3680]682    # put ln_pisdmp to false : no restoring to global mean value
[4147]683    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[4245]684    if [ ${USING_MPMD} == "yes" ] ; then
685       set_xio_using_server iodef.xml true
686    else
687       set_xio_using_server iodef.xml false
688    fi
[3520]689    cd ${SETTE_DIR}
[10755]690    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME}  ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]691    cd ${SETTE_DIR}
692    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
693
[9518]694## Reproducibility tests for ORCA2_OFF_PISCES
[7646]695    export TEST_NAME="REPRO_4_8"
[9658]696    cd ${MAIN_DIR}
[3520]697    cd ${SETTE_DIR}
[4252]698    . ./param.cfg
699    . ./all_functions.sh
700    . ./prepare_exe_dir.sh
[10755]701    set_valid_dir
[10698]702    clean_valid_dir
[3520]703    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]704    NPROC=32
[4245]705    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]706    cd ${EXE_DIR}
[9019]707    set_namelist namelist_cfg cn_exp \"OFFP_48\"
[4147]708    set_namelist namelist_cfg nn_it000 1
[13754]709    set_namelist namelist_cfg nn_itend ${ITEND}
[4147]710    set_namelist namelist_cfg jpni 4
[7646]711    set_namelist namelist_cfg jpnj 8
[10573]712    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
713    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[9904]714    set_namelist namelist_cfg ln_qsr_rgb .true.
[4147]715    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]716    set_namelist namelist_top_cfg ln_trcbc  .false.
717    # put ln_ironsed, ln_hydrofe to false
[3520]718    # if not you need input files, and for tests is not necessary
[4147]719    set_namelist namelist_pisces_cfg ln_varpar .false.
720    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]721    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]722    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[3680]723    # put ln_pisdmp to false : no restoring to global mean value
[4147]724    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[13755]725    if [ ${USING_XIOS_RRW} == "yes" ]
726       then
727       set_namelist namelist_cfg nn_wxios 1
728    fi
[4245]729    if [ ${USING_MPMD} == "yes" ] ; then
730       set_xio_using_server iodef.xml true
731    else
732       set_xio_using_server iodef.xml false
733    fi
[3520]734    cd ${SETTE_DIR}
[10755]735    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]736    cd ${SETTE_DIR}
[3532]737    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3520]738
739    cd ${SETTE_DIR}
[7646]740    export TEST_NAME="REPRO_8_4"
[4252]741    . ./prepare_exe_dir.sh
[10755]742    set_valid_dir
[10698]743    clean_valid_dir
[3680]744    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]745    NPROC=32
[4245]746    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]747    cd ${EXE_DIR}
[9019]748    set_namelist namelist_cfg cn_exp \"OFFP_84\"
[4147]749    set_namelist namelist_cfg nn_it000 1
[13754]750    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]751    set_namelist namelist_cfg jpni 8
752    set_namelist namelist_cfg jpnj 4
[10573]753    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
754    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[9904]755    set_namelist namelist_cfg ln_qsr_rgb .true.
[4147]756    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]757    set_namelist namelist_top_cfg ln_trcbc  .false.
758    # put ln_ironsed, ln_hydrofe to false
[3520]759    # if not you need input files, and for tests is not necessary
[4147]760    set_namelist namelist_pisces_cfg ln_varpar .false.
761    set_namelist namelist_pisces_cfg ln_ironsed .false.
[7646]762    set_namelist namelist_pisces_cfg ln_ironice .false.
[4147]763    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[3680]764    # put ln_pisdmp to false : no restoring to global mean value
[4147]765    set_namelist namelist_pisces_cfg ln_pisdmp .false.
[4245]766    if [ ${USING_MPMD} == "yes" ] ; then
767       set_xio_using_server iodef.xml true
768    else
769       set_xio_using_server iodef.xml false
770    fi
[3520]771    cd ${SETTE_DIR}
[10755]772    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]773    cd ${SETTE_DIR}
774    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
775fi
776
[9518]777# -----
778# AMM12
779# -----
[10747]780if [ ${config} == "AMM12" ] ;  then
[3532]781    ## Restartability tests for AMM12
[13754]782    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
783    then
784   ITEND=12   # 3 h
785    else
786   ITEND=576  # 4 days
787    fi
788    ITRST=$( printf "%08d" $(( ${ITEND} / 2 )) )
[3532]789    export TEST_NAME="LONG"
[9658]790    cd ${MAIN_DIR}
[12569]791    #
792    # syncronisation if target directory/file exist (not done by makenemo)
793    . ${SETTE_DIR}/all_functions.sh
794    sync_config  AMM12 AMM12_ST 'cfgs'
795    clean_config AMM12 AMM12_ST 'cfgs'
796    #
[11497]797    . ./makenemo -m ${CMP_NAM} -n AMM12_ST -r AMM12 -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[3520]798    cd ${SETTE_DIR}
[4252]799    . ./param.cfg
800    . ./all_functions.sh
801    . ./prepare_exe_dir.sh
[10755]802    set_valid_dir
[10698]803    clean_valid_dir
[3520]804    JOB_FILE=${EXE_DIR}/run_job.sh
805    NPROC=32
[4245]806    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]807    cd ${EXE_DIR}
[9019]808    set_namelist namelist_cfg cn_exp \"AMM12_LONG\"
[4147]809    set_namelist namelist_cfg nn_it000 1
[13754]810    set_namelist namelist_cfg nn_itend ${ITEND}
811    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]812    set_namelist namelist_cfg jpni 4
813    set_namelist namelist_cfg jpnj 8
[10573]814    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[12999]815    if [ ${USING_XIOS_RRW} == "yes" ]
816       then
817       set_namelist namelist_cfg nn_wxios 1
818    fi
[4245]819    if [ ${USING_MPMD} == "yes" ] ; then
820       set_xio_using_server iodef.xml true
821    else
822       set_xio_using_server iodef.xml false
823    fi
[3520]824    cd ${SETTE_DIR}
[10755]825    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]826
827    cd ${SETTE_DIR}
[3532]828    export TEST_NAME="SHORT"
[4379]829    . ./prepare_exe_dir.sh
[10755]830    set_valid_dir
[10698]831    clean_valid_dir
[3520]832    cd ${EXE_DIR}
[9019]833    set_namelist namelist_cfg cn_exp \"AMM12_SHORT\"
[13754]834    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
835    set_namelist namelist_cfg nn_itend ${ITEND}
836    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]837    set_namelist namelist_cfg jpni 4
838    set_namelist namelist_cfg jpnj 8
[10573]839    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[4147]840    set_namelist namelist_cfg ln_rstart .true.
841    set_namelist namelist_cfg nn_rstctl 2
[13754]842    set_namelist namelist_cfg cn_ocerst_in \"AMM12_LONG_${ITRST}_restart\"
[4252]843    set_namelist namelist_cfg nn_date0 20120102
[13755]844    if [ ${USING_XIOS_RRW} == "yes" ]
845       then
846       set_namelist namelist_cfg nn_wxios 1
847       set_namelist namelist_cfg ln_xios_read .true.
848    fi
849    if [ ${USING_XIOS_RRW} == "yes" ]
850       then
851        ln -sf ../LONG/AMM12_LONG_${ITRST}_restart.nc .
852    else
853        for (( i=1; i<=$NPROC; i++)) ; do
854            L_NPROC=$(( $i - 1 ))
855            L_NPROC=`printf "%04d\n" ${L_NPROC}`
856            ln -sf ../LONG/AMM12_LONG_${ITRST}_restart_${L_NPROC}.nc .
857        done
858    fi
[4245]859    if [ ${USING_MPMD} == "yes" ] ; then
860       set_xio_using_server iodef.xml true
861    else
862       set_xio_using_server iodef.xml false
863    fi
[3520]864    cd ${SETTE_DIR}
[10755]865    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]866    cd ${SETTE_DIR}
[3532]867    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3520]868
[3680]869## Reproducibility tests for AMM12
870    export TEST_NAME="REPRO_8_4"
[9658]871    cd ${MAIN_DIR}
[3520]872    cd ${SETTE_DIR}
[4252]873    . ./param.cfg
874    . ./all_functions.sh
875    . ./prepare_exe_dir.sh
[10755]876    set_valid_dir
[10698]877    clean_valid_dir
[3520]878    JOB_FILE=${EXE_DIR}/run_job.sh
879    NPROC=32
[4245]880    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]881    cd ${EXE_DIR}
[9019]882    set_namelist namelist_cfg cn_exp \"AMM12_84\"
[4147]883    set_namelist namelist_cfg nn_it000 1
[13754]884    set_namelist namelist_cfg nn_itend ${ITEND}
[4147]885    set_namelist namelist_cfg jpni 8
886    set_namelist namelist_cfg jpnj 4
[10573]887    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[13755]888    if [ ${USING_XIOS_RRW} == "yes" ]
889       then
[12999]890       set_namelist namelist_cfg nn_wxios 1
891    fi
[4245]892    if [ ${USING_MPMD} == "yes" ] ; then
893       set_xio_using_server iodef.xml true
894    else
895       set_xio_using_server iodef.xml false
896    fi
[3520]897    cd ${SETTE_DIR}
[10755]898    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]899    cd ${SETTE_DIR}
900    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
901
902    cd ${SETTE_DIR}
[3680]903    export TEST_NAME="REPRO_4_8"
[4252]904    . ./prepare_exe_dir.sh
[10755]905    set_valid_dir
[10698]906    clean_valid_dir
[5478]907    JOB_FILE=${EXE_DIR}/run_job.sh
908    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[3520]909    cd ${EXE_DIR}
[9019]910    set_namelist namelist_cfg cn_exp \"AMM12_48\"
[4147]911    set_namelist namelist_cfg nn_it000 1
[13754]912    set_namelist namelist_cfg nn_itend ${ITEND}
[4147]913    set_namelist namelist_cfg jpni 4
914    set_namelist namelist_cfg jpnj 8
[10573]915    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[4245]916    if [ ${USING_MPMD} == "yes" ] ; then
917       set_xio_using_server iodef.xml true
918    else
919       set_xio_using_server iodef.xml false
920    fi
[3520]921    cd ${SETTE_DIR}
[10755]922    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[3520]923    cd ${SETTE_DIR}
[3532]924    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[3520]925fi
926
927
[9518]928# ---------
929# ORCA2_SAS
930# ---------
[10747]931if [ ${config} == "SAS" ] ;  then
[9518]932## Restartability tests
[13754]933    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
934    then
935   ITEND=16   # 1 day
936    else
937   ITEND=256  # 16 days
938    fi
939    ITRST=$( printf "%08d" $(( ${ITEND} / 2 )) )
[4147]940    export TEST_NAME="LONG"
[9658]941    cd ${MAIN_DIR}
[12569]942    #
943    # syncronisation if target directory/file exist (not done by makenemo)
944    . ${SETTE_DIR}/all_functions.sh
945    sync_config  ORCA2_SAS_ICE ORCA2_SAS_ICE_ST 'cfgs'
946    clean_config ORCA2_SAS_ICE ORCA2_SAS_ICE_ST 'cfgs'
947    #
[11497]948    . ./makenemo -m ${CMP_NAM} -n ORCA2_SAS_ICE_ST -r ORCA2_SAS_ICE -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[4147]949    cd ${SETTE_DIR}
[4252]950    . ./param.cfg
951    . ./all_functions.sh
952    . ./prepare_exe_dir.sh
[10755]953    set_valid_dir
[10698]954    clean_valid_dir
[4147]955    JOB_FILE=${EXE_DIR}/run_job.sh
956    NPROC=32
[7646]957    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
[4147]958    cd ${EXE_DIR}
959    set_namelist namelist_cfg cn_exp \"SAS\"
960    set_namelist namelist_cfg nn_it000 1
[13754]961    set_namelist namelist_cfg nn_itend ${ITEND}
962    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]963    set_namelist namelist_cfg jpni 4
964    set_namelist namelist_cfg jpnj 8
[10573]965    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9019]966    set_namelist namelist_ice_cfg ln_icediachk .true.
[12999]967    if [ ${USING_XIOS_RRW} == "yes" ]
968       then
969       set_namelist namelist_cfg nn_wxios 1
970    fi
[4245]971    if [ ${USING_MPMD} == "yes" ] ; then
972       set_xio_using_server iodef.xml true
973    else
974       set_xio_using_server iodef.xml false
975    fi
[4147]976    cd ${SETTE_DIR}
[10755]977    . ./prepare_job.sh input_SAS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[4147]978
979    cd ${SETTE_DIR}
980    export TEST_NAME="SHORT"
[4252]981    . ./prepare_exe_dir.sh
[10755]982    set_valid_dir
[10698]983    clean_valid_dir
[4147]984    cd ${EXE_DIR}
985    set_namelist namelist_cfg cn_exp \"SAS\"
[13754]986    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
987    set_namelist namelist_cfg nn_itend ${ITEND}
988    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[7646]989    set_namelist namelist_cfg jpni 4
990    set_namelist namelist_cfg jpnj 8
[10573]991    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[7646]992    set_namelist namelist_cfg ln_rstart .true.
[4147]993    set_namelist namelist_cfg nn_rstctl 2
[9019]994    set_namelist namelist_cfg nn_date0 010109
[13754]995    set_namelist namelist_cfg cn_ocerst_in \"SAS_${ITRST}_restart\"
996    set_namelist namelist_ice_cfg cn_icerst_in \"SAS_${ITRST}_restart_ice\"
[13755]997    if [ ${USING_MPMD} == "yes" ] ; then
998       set_xio_using_server iodef.xml true
999    else
1000       set_xio_using_server iodef.xml false
1001    fi
[12999]1002    if [ ${USING_XIOS_RRW} == "yes" ]
1003       then
1004       set_namelist namelist_cfg nn_wxios 1
1005       set_namelist namelist_cfg ln_xios_read .true.
1006    fi
[13755]1007    if [ ${USING_XIOS_RRW} == "yes" ]
1008       then
1009        ln -sf ../LONG/SAS_${ITRST}_restart.nc .
1010        ln -sf ../LONG/SAS_${ITRST}_restart_ice.nc .
[4245]1011    else
[13755]1012        for (( i=1; i<=$NPROC; i++)) ; do
1013            L_NPROC=$(( $i - 1 ))
1014            L_NPROC=`printf "%04d\n" ${L_NPROC}`
1015            ln -sf ../LONG/SAS_${ITRST}_restart_${L_NPROC}.nc .
1016            ln -sf ../LONG/SAS_${ITRST}_restart_ice_${L_NPROC}.nc .
1017        done
[4245]1018    fi
[4147]1019    cd ${SETTE_DIR}
[10755]1020    . ./prepare_job.sh input_SAS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[4147]1021    cd ${SETTE_DIR}
1022    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1023
[9518]1024## Reproducibility tests
[13754]1025    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
1026    then
1027   ITEND=16  # 1 day
1028    else
1029   ITEND=80  # 5 days
1030    fi
[9518]1031    export TEST_NAME="REPRO_4_8"
[9658]1032    cd ${MAIN_DIR}
[4990]1033    cd ${SETTE_DIR}
1034    . ./param.cfg
1035    . ./all_functions.sh
1036    . ./prepare_exe_dir.sh
[10755]1037    set_valid_dir
[10698]1038    clean_valid_dir
[4990]1039    JOB_FILE=${EXE_DIR}/run_job.sh
[9518]1040    NPROC=32
[4990]1041    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1042    cd ${EXE_DIR}
[9518]1043    set_namelist namelist_cfg cn_exp \"SAS_48\"
[4990]1044    set_namelist namelist_cfg nn_it000 1
[13754]1045    set_namelist namelist_cfg nn_itend ${ITEND}
[9518]1046    set_namelist namelist_cfg jpni 4
1047    set_namelist namelist_cfg jpnj 8
[10573]1048    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[4990]1049    if [ ${USING_MPMD} == "yes" ] ; then
1050       set_xio_using_server iodef.xml true
1051    else
1052       set_xio_using_server iodef.xml false
1053    fi
1054    cd ${SETTE_DIR}
[10755]1055    . ./prepare_job.sh input_SAS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[4990]1056    cd ${SETTE_DIR}
1057    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
[9019]1058
[4990]1059    cd ${SETTE_DIR}
[7646]1060    export TEST_NAME="REPRO_8_4"
[4990]1061    . ./prepare_exe_dir.sh
[10755]1062    set_valid_dir
[10698]1063    clean_valid_dir
[4990]1064    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]1065    NPROC=32
[4990]1066    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1067    cd ${EXE_DIR}
[9518]1068    set_namelist namelist_cfg cn_exp \"SAS_84\"
[4990]1069    set_namelist namelist_cfg nn_it000 1
[13754]1070    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]1071    set_namelist namelist_cfg jpni 8
1072    set_namelist namelist_cfg jpnj 4
[10573]1073    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[13755]1074    if [ ${USING_XIOS_RRW} == "yes" ]
1075       then
[12999]1076       set_namelist namelist_cfg nn_wxios 1
1077    fi
[4990]1078    if [ ${USING_MPMD} == "yes" ] ; then
1079       set_xio_using_server iodef.xml true
1080    else
1081       set_xio_using_server iodef.xml false
1082    fi
1083    cd ${SETTE_DIR}
[10755]1084    . ./prepare_job.sh input_SAS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[4990]1085    cd ${SETTE_DIR}
1086    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1087
1088fi
1089
[9518]1090
1091# --------------
[9663]1092# ORCA2_ICE_OBS
[9518]1093# --------------
[4990]1094## Test assimilation interface code, OBS and ASM for reproducibility
1095## Restartability not tested (ASM code not restartable while increments are being applied)
[10747]1096if [ ${config} == "ORCA2_ICE_OBS" ] ; then
[9518]1097## Reproducibility tests
[13754]1098    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
1099    then
1100   ITEND=16  # 1 day
1101    else
1102   ITEND=80  # 5 days
1103    fi
[7646]1104    export TEST_NAME="REPRO_4_8"
[9658]1105    cd ${MAIN_DIR}
[12569]1106    #
1107    # syncronisation if target directory/file exist (not done by makenemo)
1108    . ${SETTE_DIR}/all_functions.sh
1109    sync_config  ORCA2_ICE_PISCES ORCA2_ICE_OBS_ST 'cfgs'
1110    clean_config ORCA2_ICE_PISCES ORCA2_ICE_OBS_ST 'cfgs'
1111    #
[13754]1112    . ./makenemo -m ${CMP_NAM} -n ORCA2_ICE_OBS_ST -r ORCA2_ICE_PISCES -d "OCE ICE"  -j 8 add_key "key_asminc ${ADD_KEYS}" del_key "key_top ${DEL_KEYS}"
[4990]1113    cd ${SETTE_DIR}
1114    . ./param.cfg
1115    . ./all_functions.sh
1116    . ./prepare_exe_dir.sh
[10755]1117    set_valid_dir
[10698]1118    clean_valid_dir
[4990]1119    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]1120    NPROC=32
[4990]1121    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1122    cd ${EXE_DIR}
[9019]1123    set_namelist namelist_cfg cn_exp \"O2L3OBS_48\"
[4990]1124    set_namelist namelist_cfg nn_it000 1
[13754]1125    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]1126    set_namelist namelist_cfg ln_read_cfg .true.
[4990]1127    set_namelist namelist_cfg jpni 4
[7646]1128    set_namelist namelist_cfg jpnj 8
[10573]1129    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
1130    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[6140]1131    set_namelist namelist_cfg ln_diaobs .true.
[4990]1132    set_namelist namelist_cfg ln_t3d .true.
1133    set_namelist namelist_cfg ln_s3d .true.
1134    set_namelist namelist_cfg ln_sst .true.
1135    set_namelist namelist_cfg ln_sla .true.
[6140]1136    set_namelist namelist_cfg ln_sic .true.
1137    set_namelist namelist_cfg ln_vel3d .true.
[4990]1138    set_namelist namelist_cfg ln_bkgwri .true.
1139    set_namelist namelist_cfg ln_trainc .true.
1140    set_namelist namelist_cfg ln_dyninc .true.
1141    set_namelist namelist_cfg ln_sshinc .true.
1142    set_namelist namelist_cfg ln_asmiau .true.
[9663]1143    #remove all useless options for pisces (due to ORCA2_ICE_PISCES reference configuration)
[7722]1144    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]1145    set_namelist namelist_top_cfg ln_trcbc  .false.
[7722]1146    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
1147    # if not you need input files, and for tests is not necessary
1148    set_namelist namelist_pisces_cfg ln_varpar .false.
1149    set_namelist namelist_pisces_cfg ln_ironsed .false.
1150    set_namelist namelist_pisces_cfg ln_ironice .false.
1151    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[4990]1152    if [ ${USING_MPMD} == "yes" ] ; then
1153       set_xio_using_server iodef.xml true
1154    else
1155       set_xio_using_server iodef.xml false
1156    fi
1157    cd ${SETTE_DIR}
[10755]1158    . ./prepare_job.sh input_ORCA2_ICE_OBS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[4990]1159    cd ${SETTE_DIR}
1160    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1161
1162   cd ${SETTE_DIR}
[7646]1163    export TEST_NAME="REPRO_8_4"
[4990]1164    . ./prepare_exe_dir.sh
[10755]1165    set_valid_dir
[10698]1166    clean_valid_dir
[4990]1167    JOB_FILE=${EXE_DIR}/run_job.sh
[7646]1168    NPROC=32
[4990]1169    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1170    cd ${EXE_DIR}
[9019]1171    set_namelist namelist_cfg cn_exp \"O2L3OBS_84\"
[4990]1172    set_namelist namelist_cfg nn_it000 1
[13754]1173    set_namelist namelist_cfg nn_itend ${ITEND}
[7646]1174    set_namelist namelist_cfg ln_read_cfg .true.
1175    set_namelist namelist_cfg jpni 8
1176    set_namelist namelist_cfg jpnj 4
[10573]1177    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
1178    set_namelist namelist_cfg sn_cfctl%l_trcstat .true.
[6140]1179    set_namelist namelist_cfg ln_diaobs .true.
[4990]1180    set_namelist namelist_cfg ln_t3d .true.
1181    set_namelist namelist_cfg ln_s3d .true.
1182    set_namelist namelist_cfg ln_sst .true.
1183    set_namelist namelist_cfg ln_sla .true.
[6140]1184    set_namelist namelist_cfg ln_sic .true.
1185    set_namelist namelist_cfg ln_vel3d .true.
[4990]1186    set_namelist namelist_cfg ln_bkgwri .true.
1187    set_namelist namelist_cfg ln_trainc .true.
1188    set_namelist namelist_cfg ln_dyninc .true.
1189    set_namelist namelist_cfg ln_sshinc .true.
1190    set_namelist namelist_cfg ln_asmiau .true.
[9663]1191    #remove all useless options for pisces (due to ORCA2_ICE_PISCES reference configuration)
[7722]1192    set_namelist namelist_top_cfg ln_trcdta .false.
[12428]1193    set_namelist namelist_top_cfg ln_trcbc  .false.
[7722]1194    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
1195    # if not you need input files, and for tests is not necessary
1196    set_namelist namelist_pisces_cfg ln_varpar .false.
1197    set_namelist namelist_pisces_cfg ln_ironsed .false.
1198    set_namelist namelist_pisces_cfg ln_ironice .false.
1199    set_namelist namelist_pisces_cfg ln_hydrofe .false.
[12999]1200    if [ ${USING_XIOS_RRW} == "yes" ]
1201       then
1202       set_namelist namelist_cfg nn_wxios 1
1203    fi
[4990]1204    if [ ${USING_MPMD} == "yes" ] ; then
1205       set_xio_using_server iodef.xml true
1206    else
1207       set_xio_using_server iodef.xml false
1208    fi
1209    cd ${SETTE_DIR}
[10755]1210    . ./prepare_job.sh input_ORCA2_ICE_OBS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[4990]1211    cd ${SETTE_DIR}
1212    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1213fi
[5589]1214
[9483]1215# ------------
[9663]1216# AGRIF ICE
[9483]1217# -----------
[10747]1218if [ ${config} == "AGRIF" ] ;  then
[9518]1219## Restartability tests
[13754]1220    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
1221    then
1222   ITEND=4   # 6h
1223    else
1224   ITEND=20  # 1d and 6h
1225    fi
1226    ITRST=$(   printf "%08d" $(( ${ITEND} / 2 )) )
1227    ITRST_1=$( printf "%08d" $(( ${ITEND} / 2 )) )
1228    ITRST_2=$( printf "%08d" $(( ${ITEND} * 4 / 2 )) )
1229    ITRST_3=$( printf "%08d" $(( ${ITEND} * 4 * 3 / 2 )) )
[9483]1230    export TEST_NAME="LONG"
[9658]1231    cd ${MAIN_DIR}
[12569]1232    #
1233    # syncronisation if target directory/file exist (not done by makenemo)
1234    . ${SETTE_DIR}/all_functions.sh
1235    sync_config  AGRIF_DEMO AGRIF_DEMO_ST 'cfgs'
1236    clean_config AGRIF_DEMO AGRIF_DEMO_ST 'cfgs'
1237    #
[11497]1238    . ./makenemo -m ${CMP_NAM} -n AGRIF_DEMO_ST -r AGRIF_DEMO -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[9483]1239    cd ${SETTE_DIR}
1240    . ./param.cfg
1241    . ./all_functions.sh
1242    . ./prepare_exe_dir.sh
[10755]1243    set_valid_dir
[10698]1244    clean_valid_dir
[9483]1245    JOB_FILE=${EXE_DIR}/run_job.sh
[9776]1246    NPROC=16
[9483]1247    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1248    cd ${EXE_DIR}
1249    set_namelist namelist_cfg cn_exp \"AGRIF_LONG\"
1250    set_namelist namelist_cfg nn_it000 1
[13754]1251    set_namelist namelist_cfg nn_itend ${ITEND}
1252    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[10573]1253    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9483]1254    set_namelist 1_namelist_cfg cn_exp \"AGRIF_LONG\"
1255    set_namelist 1_namelist_cfg nn_it000 1
[13754]1256    set_namelist 1_namelist_cfg nn_itend ${ITEND}
1257    set_namelist 1_namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[10573]1258    set_namelist 1_namelist_cfg sn_cfctl%l_runstat .true.
[9483]1259    set_namelist 2_namelist_cfg cn_exp \"AGRIF_LONG\"
1260    set_namelist 2_namelist_cfg nn_it000 1
[13754]1261    set_namelist 2_namelist_cfg nn_itend $(( ${ITEND} * 4 ))
1262    set_namelist 2_namelist_cfg nn_stock $(( ${ITEND} * 4 / 2 ))
[10573]1263    set_namelist 2_namelist_cfg sn_cfctl%l_runstat .true.
[9776]1264    set_namelist 3_namelist_cfg cn_exp \"AGRIF_LONG\"
1265    set_namelist 3_namelist_cfg nn_it000 1
[13754]1266    set_namelist 3_namelist_cfg nn_itend $(( ${ITEND} * 4 * 3 ))
1267    set_namelist 3_namelist_cfg nn_stock $(( ${ITEND} * 4 * 3 / 2 ))
[10573]1268    set_namelist 3_namelist_cfg sn_cfctl%l_runstat .true.
[13755]1269    if [ ${USING_XIOS_RRW} == "yes" ]
1270       then
1271       set_namelist namelist_cfg nn_wxios 1
1272    fi
[9483]1273    if [ ${USING_MPMD} == "yes" ] ; then
1274       set_xio_using_server iodef.xml true
1275    else
1276       set_xio_using_server iodef.xml false
1277    fi
1278    cd ${SETTE_DIR}
[10755]1279    . ./prepare_job.sh input_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9483]1280   
1281    cd ${SETTE_DIR}
1282    export TEST_NAME="SHORT"
1283    . ./prepare_exe_dir.sh
[10755]1284    set_valid_dir
[10698]1285    clean_valid_dir
[9483]1286    cd ${EXE_DIR}
1287    set_namelist namelist_cfg cn_exp \"AGRIF_SHORT\"
[13754]1288    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
1289    set_namelist namelist_cfg nn_itend ${ITEND}
1290    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[10573]1291    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9483]1292    set_namelist namelist_cfg ln_rstart .true.
1293    set_namelist namelist_cfg nn_rstctl 2
1294    set_namelist 1_namelist_cfg cn_exp \"AGRIF_SHORT\"
[13754]1295    set_namelist 1_namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
1296    set_namelist 1_namelist_cfg nn_itend ${ITEND}
1297    set_namelist 1_namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[10573]1298    set_namelist 1_namelist_cfg sn_cfctl%l_runstat .true.
[9483]1299    set_namelist 1_namelist_cfg ln_rstart .true.
1300    set_namelist 1_namelist_cfg nn_rstctl 2
1301    set_namelist 2_namelist_cfg cn_exp \"AGRIF_SHORT\"
[13754]1302    set_namelist 2_namelist_cfg nn_it000 $(( ${ITEND} * 4 / 2 + 1 ))
1303    set_namelist 2_namelist_cfg nn_itend $(( ${ITEND} * 4 ))
1304    set_namelist 2_namelist_cfg nn_stock $(( ${ITEND} * 4 / 2 ))
[10573]1305    set_namelist 2_namelist_cfg sn_cfctl%l_runstat .true.
[9483]1306    set_namelist 2_namelist_cfg ln_rstart .true.
1307    set_namelist 2_namelist_cfg nn_rstctl 2
[9776]1308    set_namelist 3_namelist_cfg cn_exp \"AGRIF_SHORT\"
[13754]1309    set_namelist 3_namelist_cfg nn_it000 $(( ${ITEND} * 4 * 3 / 2 + 1 ))
1310    set_namelist 3_namelist_cfg nn_itend $(( ${ITEND} * 4 * 3 ))
1311    set_namelist 3_namelist_cfg nn_stock $(( ${ITEND} * 4 * 3 / 2 ))
[10573]1312    set_namelist 3_namelist_cfg sn_cfctl%l_runstat .true.
[9776]1313    set_namelist 3_namelist_cfg ln_rstart .true.
1314    set_namelist 3_namelist_cfg nn_rstctl 2
[13754]1315    set_namelist namelist_cfg cn_ocerst_in \"AGRIF_LONG_${ITRST}_restart\"
1316    set_namelist namelist_ice_cfg cn_icerst_in \"AGRIF_LONG_${ITRST}_restart_ice\"
1317    set_namelist 1_namelist_cfg cn_ocerst_in \"AGRIF_LONG_${ITRST_1}_restart\"
1318    set_namelist 1_namelist_ice_cfg cn_icerst_in \"AGRIF_LONG_${ITRST_1}_restart_ice\"
1319    set_namelist 2_namelist_cfg cn_ocerst_in \"AGRIF_LONG_${ITRST_2}_restart\"
1320    set_namelist 2_namelist_ice_cfg cn_icerst_in \"AGRIF_LONG_${ITRST_2}_restart_ice\"
1321    set_namelist 3_namelist_cfg cn_ocerst_in \"AGRIF_LONG_${ITRST_3}_restart\"
1322    set_namelist 3_namelist_ice_cfg cn_icerst_in \"AGRIF_LONG_${ITRST_3}_restart_ice\"
[13755]1323    if [ ${USING_XIOS_RRW} == "yes" ]
1324       then
1325       set_namelist namelist_cfg nn_wxios 1
1326       set_namelist namelist_cfg ln_xios_read .true.
1327    fi
[9483]1328
[13755]1329    if [ ${USING_XIOS_RRW} == "yes" ]
1330       then
1331            ln -sf ../LONG/AGRIF_LONG_${ITRST}_restart.nc .
1332            ln -sf ../LONG/AGRIF_LONG_${ITRST}_restart_ice.nc .
1333            ln -sf ../LONG/1_AGRIF_LONG_${ITRST_1}_restart.nc .
1334            ln -sf ../LONG/1_AGRIF_LONG_${ITRST_1}_restart_ice.nc .
1335            ln -sf ../LONG/2_AGRIF_LONG_${ITRST_2}_restart.nc .
1336            ln -sf ../LONG/2_AGRIF_LONG_${ITRST_2}_restart_ice.nc .
1337            ln -sf ../LONG/3_AGRIF_LONG_${ITRST_3}_restart.nc .
1338            ln -sf ../LONG/3_AGRIF_LONG_${ITRST_3}_restart_ice.nc .
1339    else
1340        for (( i=1; i<=$NPROC; i++)) ; do
1341            L_NPROC=$(( $i - 1 ))
1342            L_NPROC=`printf "%04d\n" ${L_NPROC}`
1343            ln -sf ../LONG/AGRIF_LONG_${ITRST}_restart_${L_NPROC}.nc .
1344            ln -sf ../LONG/AGRIF_LONG_${ITRST}_restart_ice_${L_NPROC}.nc .
1345            ln -sf ../LONG/1_AGRIF_LONG_${ITRST_1}_restart_${L_NPROC}.nc .
1346            ln -sf ../LONG/1_AGRIF_LONG_${ITRST_1}_restart_ice_${L_NPROC}.nc .
1347            ln -sf ../LONG/2_AGRIF_LONG_${ITRST_2}_restart_${L_NPROC}.nc .
1348            ln -sf ../LONG/2_AGRIF_LONG_${ITRST_2}_restart_ice_${L_NPROC}.nc .
1349            ln -sf ../LONG/3_AGRIF_LONG_${ITRST_3}_restart_${L_NPROC}.nc .
1350            ln -sf ../LONG/3_AGRIF_LONG_${ITRST_3}_restart_ice_${L_NPROC}.nc .
1351        done
1352    fi
[9483]1353    if [ ${USING_MPMD} == "yes" ] ; then
1354       set_xio_using_server iodef.xml true
1355    else
1356       set_xio_using_server iodef.xml false
1357    fi
1358    cd ${SETTE_DIR}
[10755]1359    . ./prepare_job.sh input_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9483]1360    cd ${SETTE_DIR}
1361    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1362
[9518]1363## Reproducibility tests
[11800]1364    export TEST_NAME="REPRO_2_8"
[9658]1365    cd ${MAIN_DIR}
[9483]1366    cd ${SETTE_DIR}
1367    . ./param.cfg
1368    . ./all_functions.sh
1369    . ./prepare_exe_dir.sh
[10755]1370    set_valid_dir
[10698]1371    clean_valid_dir
[9483]1372    JOB_FILE=${EXE_DIR}/run_job.sh
[11800]1373    NPROC=16
[9483]1374    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1375    cd ${EXE_DIR}
[11800]1376    set_namelist namelist_cfg cn_exp \"AGRIF_28\"
[9483]1377    set_namelist namelist_cfg nn_it000 1
[13754]1378    set_namelist namelist_cfg nn_itend ${ITEND}
[11800]1379    set_namelist namelist_cfg jpni 2
[9483]1380    set_namelist namelist_cfg jpnj 8
[10573]1381    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[11800]1382    set_namelist 1_namelist_cfg cn_exp \"AGRIF_28\"
[9483]1383    set_namelist 1_namelist_cfg nn_it000 1
[13754]1384    set_namelist 1_namelist_cfg nn_itend ${ITEND}
[11800]1385    set_namelist 1_namelist_cfg jpni 2
[9483]1386    set_namelist 1_namelist_cfg jpnj 8
[10573]1387    set_namelist 1_namelist_cfg sn_cfctl%l_runstat .true.
[11800]1388    set_namelist 2_namelist_cfg cn_exp \"AGRIF_28\"
[9483]1389    set_namelist 2_namelist_cfg nn_it000 1
[13754]1390    set_namelist 2_namelist_cfg nn_itend $(( ${ITEND} * 4 ))
[11800]1391    set_namelist 2_namelist_cfg jpni 2
[9483]1392    set_namelist 2_namelist_cfg jpnj 8
[10573]1393    set_namelist 2_namelist_cfg sn_cfctl%l_runstat .true.
[11800]1394    set_namelist 3_namelist_cfg cn_exp \"AGRIF_28\"
[9776]1395    set_namelist 3_namelist_cfg nn_it000 1
[13754]1396    set_namelist 3_namelist_cfg nn_itend $(( ${ITEND} * 4 * 3 ))
[11800]1397    set_namelist 3_namelist_cfg jpni 2
[9776]1398    set_namelist 3_namelist_cfg jpnj 8
[10573]1399    set_namelist 3_namelist_cfg sn_cfctl%l_runstat .true.
[9483]1400
[13755]1401    if [ ${USING_XIOS_RRW} == "yes" ]
1402       then
1403       set_namelist namelist_cfg nn_wxios 1
1404    fi
1405
[9483]1406    if [ ${USING_MPMD} == "yes" ] ; then
1407       set_xio_using_server iodef.xml true
1408    else
1409       set_xio_using_server iodef.xml false
1410    fi
1411    cd ${SETTE_DIR}
[10755]1412    . ./prepare_job.sh input_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9483]1413    cd ${SETTE_DIR}
1414    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1415
1416    cd ${SETTE_DIR}
[11800]1417    export TEST_NAME="REPRO_4_4"
[9483]1418    . ./prepare_exe_dir.sh
[10755]1419    set_valid_dir
[10698]1420    clean_valid_dir
[9483]1421    JOB_FILE=${EXE_DIR}/run_job.sh
[11800]1422    NPROC=16
[9483]1423    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1424    cd ${EXE_DIR}
[11800]1425    set_namelist namelist_cfg cn_exp \"AGRIF_44\"
[9483]1426    set_namelist namelist_cfg nn_it000 1
[13754]1427    set_namelist namelist_cfg nn_itend ${ITEND}
[11800]1428    set_namelist namelist_cfg jpni 4
[9483]1429    set_namelist namelist_cfg jpnj 4
[10573]1430    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[11800]1431    set_namelist 1_namelist_cfg cn_exp \"AGRIF_44\"
[9483]1432    set_namelist 1_namelist_cfg nn_it000 1
[13754]1433    set_namelist 1_namelist_cfg nn_itend ${ITEND}
[11800]1434    set_namelist 1_namelist_cfg jpni 4
[9483]1435    set_namelist 1_namelist_cfg jpnj 4
[10573]1436    set_namelist 1_namelist_cfg sn_cfctl%l_runstat .true.
[11800]1437    set_namelist 2_namelist_cfg cn_exp \"AGRIF_44\"
[9483]1438    set_namelist 2_namelist_cfg nn_it000 1
[13754]1439    set_namelist 2_namelist_cfg nn_itend $(( ${ITEND} * 4 ))
[11800]1440    set_namelist 2_namelist_cfg jpni 4
[9483]1441    set_namelist 2_namelist_cfg jpnj 4
[10573]1442    set_namelist 2_namelist_cfg sn_cfctl%l_runstat .true.
[12428]1443    set_namelist 3_namelist_cfg cn_exp \"AGRIF_44\"
[9776]1444    set_namelist 3_namelist_cfg nn_it000 1
[13754]1445    set_namelist 3_namelist_cfg nn_itend $(( ${ITEND} * 4 * 3 ))
[11800]1446    set_namelist 3_namelist_cfg jpni 4
[9776]1447    set_namelist 3_namelist_cfg jpnj 4
[10573]1448    set_namelist 3_namelist_cfg sn_cfctl%l_runstat .true.
[9483]1449    if [ ${USING_MPMD} == "yes" ] ; then
1450       set_xio_using_server iodef.xml true
1451    else
1452       set_xio_using_server iodef.xml false
1453    fi
1454    cd ${SETTE_DIR}
[10755]1455    . ./prepare_job.sh input_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9483]1456    cd ${SETTE_DIR}
1457    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1458
[9507]1459## test code corruption with AGRIF (phase 1) ==> Compile with key_agrif but run with no zoom
[13754]1460    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
1461    then
1462   ITEND=16   # 1d
1463    else
1464   ITEND=150  # 5d and 9h
1465    fi
[9507]1466    export TEST_NAME="ORCA2"
[9658]1467    cd ${MAIN_DIR}
[9483]1468    cd ${SETTE_DIR}
1469    . ./param.cfg
1470    . ./all_functions.sh
1471    . ./prepare_exe_dir.sh
[10755]1472    set_valid_dir
[10698]1473    clean_valid_dir
[9483]1474    JOB_FILE=${EXE_DIR}/run_job.sh
1475    NPROC=32
1476    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1477    cd ${EXE_DIR}
[9507]1478    set_namelist namelist_cfg cn_exp \"ORCA2\"
[9483]1479    set_namelist namelist_cfg nn_it000 1
[13754]1480    set_namelist namelist_cfg nn_itend ${ITEND}
[10573]1481    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9507]1482
[9483]1483#   Set the number of fine grids to zero:   
1484    sed -i "1s/.*/0/" ${EXE_DIR}/AGRIF_FixedGrids.in
1485
1486    if [ ${USING_MPMD} == "yes" ] ; then
1487       set_xio_using_server iodef.xml true
1488    else
1489       set_xio_using_server iodef.xml false
1490    fi
1491    cd ${SETTE_DIR}
[10755]1492    . ./prepare_job.sh input_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9483]1493    cd ${SETTE_DIR}
1494    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1495
1496fi
1497
[9525]1498
[9776]1499## test code corruption with AGRIF (phase 2) ==> Compile without key_agrif (to be compared with AGRIF_DEMO_ST/ORCA2)
[10747]1500if [ ${config} == "AGRIF" ] ;  then
[9507]1501    export TEST_NAME="ORCA2"
[9658]1502    cd ${MAIN_DIR}
[12569]1503    #
1504    # syncronisation if target directory/file exist (not done by makenemo)
1505    . ${SETTE_DIR}/all_functions.sh
1506    sync_config  AGRIF_DEMO AGRIF_DEMO_NOAGRIF_ST 'cfgs'
1507    clean_config AGRIF_DEMO AGRIF_DEMO_NOAGRIF_ST 'cfgs'
1508    #
[13754]1509    . ./makenemo -m ${CMP_NAM} -n AGRIF_DEMO_NOAGRIF_ST -r AGRIF_DEMO -j 8 add_key "${ADD_KEYS}" del_key "key_agrif ${DEL_KEYS}"
[9483]1510    cd ${SETTE_DIR}
1511    . ./param.cfg
1512    . ./all_functions.sh
1513    . ./prepare_exe_dir.sh
[10755]1514    set_valid_dir
[10698]1515    clean_valid_dir
[9483]1516    JOB_FILE=${EXE_DIR}/run_job.sh
1517    NPROC=32
1518    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1519    cd ${EXE_DIR}
[9507]1520    set_namelist namelist_cfg cn_exp \"ORCA2\"
[9483]1521    set_namelist namelist_cfg nn_it000 1
[13754]1522    set_namelist namelist_cfg nn_itend ${ITEND}
[10573]1523    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9483]1524#
1525    if [ ${USING_MPMD} == "yes" ] ; then
1526       set_xio_using_server iodef.xml true
1527    else
1528       set_xio_using_server iodef.xml false
1529    fi
1530    cd ${SETTE_DIR}
[10755]1531    . ./prepare_job.sh input_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9483]1532    cd ${SETTE_DIR}
1533    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1534
1535fi
1536
[9553]1537# -------
[13754]1538# WED025
[9553]1539# -------
[13754]1540if [ ${config} == "WED025" ] ;  then
[9553]1541## Restartability tests
[13754]1542    if [ $( echo ${CMP_NAM} | grep -ic debug ) -eq 1 ]
1543    then
1544   ITEND=12   # 4h
1545    else
1546   ITEND=720  # 10 days
1547    fi
1548    ITRST=$( printf "%08d" $(( ${ITEND} / 2 )) )
[9553]1549    export TEST_NAME="LONG"
[9658]1550    cd ${MAIN_DIR}
[12569]1551    #
1552    # syncronisation if target directory/file exist (not done by makenemo)
1553    . ${SETTE_DIR}/all_functions.sh
[13754]1554    sync_config  WED025 WED025_ST 'cfgs'
1555    clean_config WED025 WED025_ST 'cfgs'
[12569]1556    #
[13754]1557    . ./makenemo -m ${CMP_NAM} -n WED025_ST -r WED025 -j 8 add_key "${ADD_KEYS}" del_key "${DEL_KEYS}"
[9553]1558    cd ${SETTE_DIR}
1559    . ./param.cfg
1560    . ./all_functions.sh
1561    . ./prepare_exe_dir.sh
[10755]1562    set_valid_dir
[10698]1563    clean_valid_dir
[9553]1564    JOB_FILE=${EXE_DIR}/run_job.sh
1565    NPROC=32
1566    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1567    cd ${EXE_DIR}
[13754]1568    set_namelist namelist_cfg cn_exp \"WED025_LONG\"
[9553]1569    set_namelist namelist_cfg nn_it000 1
[13754]1570    set_namelist namelist_cfg nn_itend ${ITEND}
1571    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
1572    set_namelist namelist_cfg nn_date0 20000115
[9553]1573    set_namelist namelist_cfg jpni 4
1574    set_namelist namelist_cfg jpnj 8
[10573]1575    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9744]1576    #set_namelist namelist_ice_cfg ln_icediachk .true.
[12999]1577    if [ ${USING_XIOS_RRW} == "yes" ]
1578       then
1579       set_namelist namelist_cfg nn_wxios 1
1580    fi
[9553]1581    if [ ${USING_MPMD} == "yes" ] ; then
1582       set_xio_using_server iodef.xml true
1583    else
1584       set_xio_using_server iodef.xml false
1585    fi
1586    cd ${SETTE_DIR}
[13754]1587    . ./prepare_job.sh input_WED025.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9553]1588   
1589    cd ${SETTE_DIR}
1590    export TEST_NAME="SHORT"
1591    . ./prepare_exe_dir.sh
[10755]1592    set_valid_dir
[10698]1593    clean_valid_dir
[9553]1594    cd ${EXE_DIR}
[13754]1595    set_namelist namelist_cfg cn_exp \"WED025_SHORT\"
1596    set_namelist namelist_cfg nn_it000 $(( ${ITEND} / 2 + 1 ))
1597    set_namelist namelist_cfg nn_itend ${ITEND}
1598    set_namelist namelist_cfg nn_stock $(( ${ITEND} / 2 ))
[9553]1599    set_namelist namelist_cfg ln_rstart .true.
1600    set_namelist namelist_cfg nn_rstctl 2
1601    set_namelist namelist_cfg jpni 4
1602    set_namelist namelist_cfg jpnj 8
[10573]1603    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[13754]1604    set_namelist namelist_cfg cn_ocerst_in \"WED025_LONG_${ITRST}_restart\"
1605    set_namelist namelist_ice_cfg cn_icerst_in \"WED025_LONG_${ITRST}_restart_ice\"
[13755]1606    if [ ${USING_XIOS_RRW} == "yes" ]
1607       then
1608       set_namelist namelist_cfg nn_wxios 1
1609       set_namelist namelist_cfg ln_xios_read .true.
1610    fi
1611    if [ ${USING_XIOS_RRW} == "yes" ]
1612       then
1613            ln -sf ../LONG/WED025_LONG_${ITRST}_restart.nc .
1614            ln -sf ../LONG/WED025_LONG_${ITRST}_restart_ice.nc .
1615    else
1616        for (( i=1; i<=$NPROC; i++)) ; do
1617            L_NPROC=$(( $i - 1 ))
1618            L_NPROC=`printf "%04d\n" ${L_NPROC}`
1619            ln -sf ../LONG/WED025_LONG_${ITRST}_restart_${L_NPROC}.nc .
1620            ln -sf ../LONG/WED025_LONG_${ITRST}_restart_ice_${L_NPROC}.nc .
1621        done
1622    fi
[9553]1623    if [ ${USING_MPMD} == "yes" ] ; then
1624       set_xio_using_server iodef.xml true
1625    else
1626       set_xio_using_server iodef.xml false
1627    fi
1628    cd ${SETTE_DIR}
[13754]1629    . ./prepare_job.sh input_WED025.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9553]1630    cd ${SETTE_DIR}
1631    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1632
1633## Reproducibility tests
[13754]1634    export TEST_NAME="REPRO_5_6"
[9658]1635    cd ${MAIN_DIR}
[9553]1636    cd ${SETTE_DIR}
1637    . ./param.cfg
1638    . ./all_functions.sh
1639    . ./prepare_exe_dir.sh
[10755]1640    set_valid_dir
[10698]1641    clean_valid_dir
[9553]1642    JOB_FILE=${EXE_DIR}/run_job.sh
1643    NPROC=32
1644    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1645    cd ${EXE_DIR}
[13754]1646    set_namelist namelist_cfg cn_exp \"WED025_56\"
[9553]1647    set_namelist namelist_cfg nn_it000 1
[13754]1648    set_namelist namelist_cfg nn_itend ${ITEND}
1649    set_namelist namelist_cfg nn_date0 20000115
1650    set_namelist namelist_cfg jpni 6
1651    set_namelist namelist_cfg jpnj 7
[10573]1652    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[9553]1653    if [ ${USING_MPMD} == "yes" ] ; then
1654       set_xio_using_server iodef.xml true
1655    else
1656       set_xio_using_server iodef.xml false
1657    fi
1658    cd ${SETTE_DIR}
[13754]1659    . ./prepare_job.sh input_WED025.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9553]1660    cd ${SETTE_DIR}
1661    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1662
1663    cd ${SETTE_DIR}
1664    export TEST_NAME="REPRO_8_4"
1665    . ./prepare_exe_dir.sh
[10755]1666    set_valid_dir
[10698]1667    clean_valid_dir
[9553]1668    JOB_FILE=${EXE_DIR}/run_job.sh
1669    NPROC=32
1670    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1671    cd ${EXE_DIR}
[13754]1672    set_namelist namelist_cfg cn_exp \"WED025_84\"
[9553]1673    set_namelist namelist_cfg nn_it000 1
[13754]1674    set_namelist namelist_cfg nn_itend ${ITEND}
1675    set_namelist namelist_cfg nn_date0 20000115
[9553]1676    set_namelist namelist_cfg jpni 8
1677    set_namelist namelist_cfg jpnj 4
[10573]1678    set_namelist namelist_cfg sn_cfctl%l_runstat .true.
[13755]1679    if [ ${USING_XIOS_RRW} == "yes" ]
1680       then
[12999]1681       set_namelist namelist_cfg nn_wxios 1
1682    fi
[9553]1683    if [ ${USING_MPMD} == "yes" ] ; then
1684       set_xio_using_server iodef.xml true
1685    else
1686       set_xio_using_server iodef.xml false
1687    fi
1688    cd ${SETTE_DIR}
[13754]1689    . ./prepare_job.sh input_WED025.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS} ${NEMO_VALID}
[9553]1690    cd ${SETTE_DIR}
1691    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1692fi
1693
1694
[3520]1695done
Note: See TracBrowser for help on using the repository browser.