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.sh in trunk/NEMOGCM/SETTE – NEMO

source: trunk/NEMOGCM/SETTE/sette.sh @ 7753

Last change on this file since 7753 was 7753, checked in by mocavero, 6 years ago

Reverting trunk to remove OpenMP

  • Property svn:executable set to *
File size: 54.4 KB
Line 
1#!/bin/bash
2############################################################
3# Author : Simona Flavoni for NEMO
4# Contact: sflod@locean-ipsl.upmc.fr
5# 2013   : A.C. Coward added options for testing with XIOS in dettached mode
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#############################################################
14#set -vx
15set -o posix
16#set -u
17#set -e
18# ===========
19# DESCRIPTION
20# ===========
21#
22# Variables to be checked by user:
23#
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"
40#
41# Principal script is sette.sh, that calls
42#
43#  makenemo  : to create successive exectuables in ${CONFIG_NAME}/BLD/bin/nemo.exe
44#              and links to opa in ${CONFIG_NAME}/EXP00)
45#
46#  param.cfg : sets and loads following directories:
47#
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)
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#
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
58#                      (solver.stat and ocean.output) in it after execution of test.
59#
60#  VALIDATION tree is:
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
65#                       execution directory takes name of TEST_NAME defined for every test
66#                       in sette.sh. (each test in executed in its own directory)
67#
68#  prepare_job.sh     : to generate the script run_job.sh
69#
70#  fcm_job.sh         : run in batch (INTERACT_FLAG="no") or interactive (INTERACT_FLAG="yes")
71#                        see sette.sh and BATCH_TEMPLATE directory
72#
73#  NOTE: jobs requiring initial or forcing data need to have an input_CONFIG.cfg in which
74#        can be found paths to the input tar file)
75#  NOTE: if job is not launched for any reason you have the executable ready in ${EXE_DIR}
76#        directory
77#  NOTE: the changed namelists are left in ${EXE_DIR} directory whereas original namelists
78#        remain in ${NEW_CONF}/EXP00
79#
80#  NOTE: a log file, output.sette, is created in ${SETTE_DIR} with the echoes of
81#        executed commands
82#
83#  NOTE: if sette.sh is stopped in output.sette there is written the last command
84#        executed by sette.sh
85#
86# example use: ./sette.sh
87#########################################################################################
88#
89# Compiler among those in NEMOGCM/ARCH
90COMPILER=X64_ADA
91
92export BATCH_COMMAND_PAR="llsubmit"
93export BATCH_COMMAND_SEQ=$BATCH_COMMAND_PAR
94export INTERACT_FLAG="no"
95export MPIRUN_FLAG="yes"
96export USING_XIOS="yes"
97#
98export DEL_KEYS="key_iomput"
99if [ ${USING_XIOS} == "yes" ] 
100 then
101   export DEL_KEYS=""
102fi
103#
104# Settings which control the use of stand alone servers (only relevant if using xios)
105#
106export USING_MPMD="no"
107export NUM_XIOSERVERS=4
108export JOB_PREFIX=batch-mpmd
109#
110if [ ${USING_MPMD} == "no" ] 
111 then
112   export NUM_XIOSERVERS=0
113   export JOB_PREFIX=batch
114fi
115#
116#
117if [ ${USING_MPMD} == "yes" ] && [ ${USING_XIOS} == "no"]
118 then
119   echo "Incompatible choices. MPMD mode requires the XIOS server"
120   exit
121fi
122
123# Directory to run the tests
124SETTE_DIR=$(cd $(dirname "$0"); pwd)
125MAIN_DIR=$(dirname $SETTE_DIR)
126CONFIG_DIR0=${MAIN_DIR}/CONFIG
127TOOLS_DIR=${MAIN_DIR}/TOOLS
128COMPIL_DIR=${TOOLS_DIR}/COMPILE
129
130CMP_NAM=${1:-$COMPILER}
131# Copy job_batch_COMPILER file for specific compiler into job_batch_template
132cd ${SETTE_DIR}
133cp BATCH_TEMPLATE/${JOB_PREFIX}-${COMPILER} job_batch_template || exit
134# Description of configuration tested:
135# GYRE_PISCES       :  1 &  2
136# ORCA2_LIM3_PISCES :  3 &  4
137# ORCA2_OFF_PISCES  :  5 &  6
138# AMM12             :  7 &  8
139# SAS               :  9     fos SAS there is no solver so is useless to test REPRO
140# ISOMIP            : 10 & 11
141# ORCA2_LIM3_OBS    : 12
142# ORCA2_AGRIF_LIM3  : 13 & 14
143#                     15 & 16
144
145for config in 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
146
147do
148
149# TESTS FOR GYRE_PISCES CONFIGURATION
150if [ ${config} -eq 1 ] ;  then
151    ## Restartability tests for GYRE_PISCES
152    export TEST_NAME="LONG"
153    cd ${CONFIG_DIR0}
154    . ./makenemo -m ${CMP_NAM} -n GYREPIS_LONG -r GYRE_PISCES -j 8 del_key ${DEL_KEYS}
155    cd ${SETTE_DIR}
156    . ./param.cfg
157    . ./all_functions.sh
158    . ./prepare_exe_dir.sh
159    JOB_FILE=${EXE_DIR}/run_job.sh
160    NPROC=32
161    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
162    cd ${EXE_DIR} 
163    set_namelist namelist_cfg cn_exp \"GYREPIS_LONG\"
164    set_namelist namelist_cfg nn_it000 1
165    set_namelist namelist_cfg nn_itend 120
166    set_namelist namelist_cfg nn_stock 60
167    set_namelist namelist_cfg ln_clobber .true.
168    set_namelist namelist_cfg ln_linssh .true.
169    set_namelist namelist_cfg ln_read_cfg .false.
170    set_namelist namelist_cfg nn_fwb 0
171    set_namelist namelist_cfg jpni 4
172    set_namelist namelist_cfg jpnj 8
173    set_namelist namelist_cfg jpnij 32
174    if [ ${USING_MPMD} == "yes" ] ; then
175       set_xio_using_server iodef.xml true
176    else
177       set_xio_using_server iodef.xml false
178    fi
179    cd ${SETTE_DIR}
180    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
181
182    cd ${SETTE_DIR}
183    export TEST_NAME="SHORT"
184    . ./prepare_exe_dir.sh
185    cd ${EXE_DIR}
186    set_namelist namelist_cfg cn_exp \"GYREPIS_SHORT\"
187    set_namelist namelist_cfg nn_it000 61
188    set_namelist namelist_cfg nn_itend 120
189    set_namelist namelist_cfg nn_stock 60
190    set_namelist namelist_cfg ln_rstart .true.
191    set_namelist namelist_cfg nn_rstctl 2
192    set_namelist namelist_cfg ln_clobber .true.
193    set_namelist namelist_cfg ln_linssh .true.
194    set_namelist namelist_cfg ln_read_cfg .false.
195    set_namelist namelist_cfg nn_fwb 0
196    set_namelist namelist_cfg jpni 4
197    set_namelist namelist_cfg jpnj 8
198    set_namelist namelist_cfg jpnij 32
199    set_namelist namelist_top_cfg ln_rsttr .true.
200    set_namelist namelist_top_cfg nn_rsttr 2
201    set_namelist namelist_cfg cn_ocerst_in \"GYREPIS_LONG_00000060_restart\"
202    set_namelist namelist_top_cfg cn_trcrst_in \"GYREPIS_LONG_00000060_restart_trc\"
203    if [ ${USING_MPMD} == "yes" ] ; then
204       set_xio_using_server iodef.xml true
205    else
206       set_xio_using_server iodef.xml false
207    fi
208    for (( i=1; i<=$NPROC; i++)) ; do
209        L_NPROC=$(( $i - 1 ))
210        L_NPROC=`printf "%04d\n" ${L_NPROC}`
211        ln -sf ../LONG/GYREPIS_LONG_00000060_restart_${L_NPROC}.nc .
212        ln -sf ../LONG/GYREPIS_LONG_00000060_restart_trc_${L_NPROC}.nc .
213    done
214    if [ ${USING_MPMD} == "yes" ] ; then
215       set_xio_using_server iodef.xml true
216    else
217       set_xio_using_server iodef.xml false
218    fi
219    cd ${SETTE_DIR}
220    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
221    cd ${SETTE_DIR}
222    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
223fi
224
225if [ ${config} -eq 2 ] ;  then
226    ## Reproducibility tests for GYRE_PISCES
227    export TEST_NAME="REPRO_4_8"
228    cd ${CONFIG_DIR0}
229    . ./makenemo -m ${CMP_NAM} -n GYREPIS_32 -r GYRE_PISCES -j 8 del_key ${DEL_KEYS}
230    cd ${SETTE_DIR}
231    . ./param.cfg
232    . ./all_functions.sh
233    . ./prepare_exe_dir.sh
234    JOB_FILE=${EXE_DIR}/run_job.sh
235    NPROC=32
236    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
237    cd ${EXE_DIR}
238    set_namelist namelist_cfg cn_exp \"GYREPIS_48\"
239    set_namelist namelist_cfg nn_it000 1
240    set_namelist namelist_cfg nn_itend 60
241    set_namelist namelist_cfg nn_fwb 0
242    set_namelist namelist_cfg ln_ctl .false.
243    set_namelist namelist_cfg ln_clobber .true.
244    set_namelist namelist_cfg ln_linssh .true.
245    set_namelist namelist_cfg ln_read_cfg .false.
246    set_namelist namelist_cfg jpni 4
247    set_namelist namelist_cfg jpnj 8
248    set_namelist namelist_cfg jpnij 32
249    if [ ${USING_MPMD} == "yes" ] ; then
250       set_xio_using_server iodef.xml true
251    else
252       set_xio_using_server iodef.xml false
253    fi
254    cd ${SETTE_DIR}
255    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
256    cd ${SETTE_DIR}
257    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
258
259    cd ${SETTE_DIR}
260    export TEST_NAME="REPRO_8_4"
261    . ./prepare_exe_dir.sh
262    JOB_FILE=${EXE_DIR}/run_job.sh
263    NPROC=32
264    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
265    cd ${EXE_DIR}
266    set_namelist namelist_cfg cn_exp \"GYREPIS_84\"
267    set_namelist namelist_cfg nn_it000 1
268    set_namelist namelist_cfg nn_itend 60
269    set_namelist namelist_cfg nn_fwb 0
270    set_namelist namelist_cfg ln_ctl .false.
271    set_namelist namelist_cfg ln_clobber .true.
272    set_namelist namelist_cfg ln_linssh .true.
273    set_namelist namelist_cfg ln_read_cfg .false.
274    set_namelist namelist_cfg jpni 8
275    set_namelist namelist_cfg jpnj 4
276    set_namelist namelist_cfg jpnij 32
277    if [ ${USING_MPMD} == "yes" ] ; then
278       set_xio_using_server iodef.xml true
279    else
280       set_xio_using_server iodef.xml false
281    fi
282    cd ${SETTE_DIR}
283    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
284    cd ${SETTE_DIR}
285    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
286
287fi
288
289# TESTS FOR ORCA2_LIM3_PISCES CONFIGURATION
290if [ ${config} -eq 3 ] ;  then
291    ## Restartability tests for ORCA2_LIM3_PISCES
292    export TEST_NAME="LONG"
293    cd ${CONFIG_DIR0}
294    . ./makenemo -m ${CMP_NAM} -n ORCA2LIM3PIS_LONG -r ORCA2_LIM3_PISCES -j 8 del_key ${DEL_KEYS}
295    cd ${SETTE_DIR}
296    . ./param.cfg
297    . ./all_functions.sh
298    . ./prepare_exe_dir.sh
299    JOB_FILE=${EXE_DIR}/run_job.sh
300    NPROC=32
301    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
302    cd ${EXE_DIR}
303    set_namelist namelist_cfg cn_exp \"O2L3P_LONG\"
304    set_namelist namelist_cfg nn_it000 1
305    set_namelist namelist_cfg nn_itend 150
306    set_namelist namelist_cfg nn_stock 75
307    set_namelist namelist_cfg ln_clobber .true.
308    set_namelist namelist_cfg ln_read_cfg .true.
309    set_namelist namelist_cfg ln_linssh .false.
310    set_namelist namelist_cfg nn_fwb 0
311    set_namelist namelist_cfg jpni 4
312    set_namelist namelist_cfg jpnj 8
313    set_namelist namelist_cfg jpnij 32
314    set_namelist namelist_top_cfg ln_trcdta .false.
315    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
316    # if not you need input files, and for tests is not necessary
317    set_namelist namelist_pisces_cfg ln_presatm .false.
318    set_namelist namelist_pisces_cfg ln_varpar .false.
319    set_namelist namelist_pisces_cfg ln_dust .false.
320    set_namelist namelist_pisces_cfg ln_solub .false.
321    set_namelist namelist_pisces_cfg ln_river .false.
322    set_namelist namelist_pisces_cfg ln_ndepo .false.
323    set_namelist namelist_pisces_cfg ln_ironsed .false.
324    set_namelist namelist_pisces_cfg ln_ironice .false.
325    set_namelist namelist_pisces_cfg ln_hydrofe .false.
326    if [ ${USING_MPMD} == "yes" ] ; then
327       set_xio_using_server iodef.xml true
328    else
329       set_xio_using_server iodef.xml false
330    fi
331    cd ${SETTE_DIR}
332    . ./prepare_job.sh input_ORCA2_LIM3_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
333   
334    cd ${SETTE_DIR}
335    export TEST_NAME="SHORT"
336    . ./prepare_exe_dir.sh
337    cd ${EXE_DIR}
338    set_namelist namelist_cfg cn_exp \"O2L3P_SHORT\"
339    set_namelist namelist_cfg nn_it000 76
340    set_namelist namelist_cfg nn_itend 150
341    set_namelist namelist_cfg nn_stock 75
342    set_namelist namelist_cfg ln_rstart .true.
343    set_namelist namelist_cfg nn_rstctl 2
344    set_namelist namelist_cfg ln_clobber .true.
345    set_namelist namelist_cfg ln_read_cfg .true.
346    set_namelist namelist_cfg ln_linssh .false.
347    set_namelist namelist_cfg ln_icebergs .true.
348    set_namelist namelist_cfg nn_fwb 0
349    set_namelist namelist_cfg jpni 4
350    set_namelist namelist_cfg jpnj 8
351    set_namelist namelist_cfg jpnij 32
352    set_namelist namelist_top_cfg ln_rsttr .true.
353    set_namelist namelist_top_cfg nn_rsttr 2
354    set_namelist namelist_cfg cn_ocerst_in \"O2L3P_LONG_00000075_restart\"
355    set_namelist namelist_ice_cfg cn_icerst_in \"O2L3P_LONG_00000075_restart_ice\"
356    set_namelist namelist_top_cfg cn_trcrst_in \"O2L3P_LONG_00000075_restart_trc\"
357    # put ln_ironsed, ln_river, ln_ndepo, ln_dust
358    # if not you need input files, and for tests is not necessary
359    set_namelist namelist_pisces_cfg ln_presatm .false.
360    set_namelist namelist_pisces_cfg ln_varpar .false.
361    set_namelist namelist_pisces_cfg ln_dust .false.
362    set_namelist namelist_pisces_cfg ln_solub .false.
363    set_namelist namelist_pisces_cfg ln_river .false.
364    set_namelist namelist_pisces_cfg ln_ndepo .false.
365    set_namelist namelist_pisces_cfg ln_ironsed .false.
366    set_namelist namelist_pisces_cfg ln_ironice .false.
367    set_namelist namelist_pisces_cfg ln_hydrofe .false.
368    # put ln_pisdmp to false : no restoring to global mean value
369    set_namelist namelist_pisces_cfg ln_pisdmp .false.
370    for (( i=1; i<=$NPROC; i++)) ; do
371        L_NPROC=$(( $i - 1 ))
372        L_NPROC=`printf "%04d\n" ${L_NPROC}`
373        ln -sf ../LONG/O2L3P_LONG_00000075_restart_${L_NPROC}.nc .
374        ln -sf ../LONG/O2L3P_LONG_00000075_restart_trc_${L_NPROC}.nc .
375        ln -sf ../LONG/O2L3P_LONG_00000075_restart_ice_${L_NPROC}.nc .
376        ln -sf ../LONG/O2L3P_LONG_icebergs_00000075_restart_${L_NPROC}.nc O2L3P_LONG_00000075_restart_icebergs_${L_NPROC}.nc
377    done
378    if [ ${USING_MPMD} == "yes" ] ; then
379       set_xio_using_server iodef.xml true
380    else
381       set_xio_using_server iodef.xml false
382    fi
383    cd ${SETTE_DIR}
384    . ./prepare_job.sh input_ORCA2_LIM3_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
385    cd ${SETTE_DIR}
386    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
387fi
388
389if [ ${config} -eq 4 ] ;  then
390    ## Reproducibility tests for ORCA2_LIM3_PISCES
391    export TEST_NAME="REPRO_4_8"
392    cd ${CONFIG_DIR0}
393    . ./makenemo -m ${CMP_NAM} -n ORCA2LIM3PIS_32 -r ORCA2_LIM3_PISCES -j 8 del_key ${DEL_KEYS}
394    cd ${SETTE_DIR}
395    . ./param.cfg
396    . ./all_functions.sh
397    . ./prepare_exe_dir.sh
398    JOB_FILE=${EXE_DIR}/run_job.sh
399    NPROC=32
400    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
401    cd ${EXE_DIR}
402    set_namelist namelist_cfg nn_it000 1
403    set_namelist namelist_cfg nn_itend 75
404    set_namelist namelist_cfg nn_fwb 0
405    set_namelist namelist_cfg ln_ctl .false.
406    set_namelist namelist_cfg ln_clobber .true.
407    set_namelist namelist_cfg ln_read_cfg .true.
408    set_namelist namelist_cfg ln_linssh .false.
409    set_namelist namelist_cfg ln_icebergs .true.
410    set_namelist namelist_cfg jpni 4
411    set_namelist namelist_cfg jpnj 8
412    set_namelist namelist_cfg jpnij 32
413    set_namelist namelist_top_cfg ln_trcdta .false.
414    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
415    # if not you need input files, and for tests is not necessary
416    set_namelist namelist_pisces_cfg ln_presatm .false.
417    set_namelist namelist_pisces_cfg ln_varpar .false.
418    set_namelist namelist_pisces_cfg ln_dust .false.
419    set_namelist namelist_pisces_cfg ln_solub .false.
420    set_namelist namelist_pisces_cfg ln_river .false.
421    set_namelist namelist_pisces_cfg ln_ndepo .false.
422    set_namelist namelist_pisces_cfg ln_ironsed .false.
423    set_namelist namelist_pisces_cfg ln_ironice .false.
424    set_namelist namelist_pisces_cfg ln_hydrofe .false.
425    # put ln_pisdmp to false : no restoring to global mean value
426    set_namelist namelist_pisces_cfg ln_pisdmp .false.
427    if [ ${USING_MPMD} == "yes" ] ; then
428       set_xio_using_server iodef.xml true
429    else
430       set_xio_using_server iodef.xml false
431    fi
432    cd ${SETTE_DIR}
433    . ./prepare_job.sh input_ORCA2_LIM3_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
434    cd ${SETTE_DIR}
435    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
436
437    cd ${SETTE_DIR}
438    export TEST_NAME="REPRO_8_4"
439    . ./prepare_exe_dir.sh
440    JOB_FILE=${EXE_DIR}/run_job.sh
441    NPROC=32
442    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
443    cd ${EXE_DIR}
444    set_namelist namelist_cfg nn_it000 1
445    set_namelist namelist_cfg nn_itend 75
446    set_namelist namelist_cfg ln_clobber .true.
447    set_namelist namelist_cfg ln_read_cfg .true.
448    set_namelist namelist_cfg ln_linssh .false.
449    set_namelist namelist_cfg ln_icebergs .true.
450    set_namelist namelist_cfg nn_fwb 0
451    set_namelist namelist_cfg jpni 8
452    set_namelist namelist_cfg jpnj 4
453    set_namelist namelist_cfg jpnij 32
454    set_namelist namelist_top_cfg ln_trcdta .false.
455    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
456    # if not you need input files, and for tests is not necessary
457    set_namelist namelist_pisces_cfg ln_presatm .false.
458    set_namelist namelist_pisces_cfg ln_varpar .false.
459    set_namelist namelist_pisces_cfg ln_dust .false.
460    set_namelist namelist_pisces_cfg ln_solub .false.
461    set_namelist namelist_pisces_cfg ln_river .false.
462    set_namelist namelist_pisces_cfg ln_ndepo .false.
463    set_namelist namelist_pisces_cfg ln_ironsed .false.
464    set_namelist namelist_pisces_cfg ln_ironice .false.
465    set_namelist namelist_pisces_cfg ln_hydrofe .false.
466    # put ln_pisdmp to false : no restoring to global mean value
467    set_namelist namelist_pisces_cfg ln_pisdmp .false.
468    if [ ${USING_MPMD} == "yes" ] ; then
469       set_xio_using_server iodef.xml true
470    else
471       set_xio_using_server iodef.xml false
472    fi
473    cd ${SETTE_DIR}
474    . ./prepare_job.sh input_ORCA2_LIM3_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
475    cd ${SETTE_DIR}
476    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
477fi
478
479# TESTS FOR ORCA2_OFF_PISCES CONFIGURATION
480if [ ${config} -eq 5 ] ;  then
481    ## Restartability tests for ORCA2_OFF_PISCES
482    export TEST_NAME="LONG"
483    cd ${CONFIG_DIR0}
484    . ./makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_LONG -r ORCA2_OFF_PISCES -j 8 del_key ${DEL_KEYS}
485    cd ${SETTE_DIR}
486    . ./param.cfg
487    . ./all_functions.sh
488    . ./prepare_exe_dir.sh
489    JOB_FILE=${EXE_DIR}/run_job.sh
490    NPROC=32
491    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
492    cd ${EXE_DIR}
493    set_namelist namelist_cfg cn_exp \"OFFP_LONG\"
494    set_namelist namelist_cfg nn_it000 1
495    set_namelist namelist_cfg nn_itend 40
496    set_namelist namelist_cfg nn_stock 20
497    set_namelist namelist_cfg ln_clobber .true.
498    set_namelist namelist_cfg ln_read_cfg .true.
499    set_namelist namelist_cfg ln_linssh .true.
500    set_namelist namelist_cfg jpni 4
501    set_namelist namelist_cfg jpnj 8
502    set_namelist namelist_cfg jpnij 32
503    set_namelist namelist_top_cfg ln_trcdta .false.
504    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
505    # if not you need input files, and for tests is not necessary
506    set_namelist namelist_pisces_cfg ln_presatm .false.
507    set_namelist namelist_pisces_cfg ln_varpar .false.
508    set_namelist namelist_pisces_cfg ln_dust .false.
509    set_namelist namelist_pisces_cfg ln_solub .false.
510    set_namelist namelist_pisces_cfg ln_river .false.
511    set_namelist namelist_pisces_cfg ln_ndepo .false.
512    set_namelist namelist_pisces_cfg ln_ironsed .false.
513    set_namelist namelist_pisces_cfg ln_ironice .false.
514    set_namelist namelist_pisces_cfg ln_hydrofe .false.
515    # put ln_pisdmp to false : no restoring to global mean value
516    set_namelist namelist_pisces_cfg ln_pisdmp .false.
517    if [ ${USING_MPMD} == "yes" ] ; then
518       set_xio_using_server iodef.xml true
519    else
520       set_xio_using_server iodef.xml false
521    fi
522    cd ${SETTE_DIR}
523    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
524   
525    cd ${SETTE_DIR}
526    export TEST_NAME="SHORT"
527    . ./prepare_exe_dir.sh
528    cd ${EXE_DIR}
529    set_namelist namelist_cfg cn_exp \"OFFP_SHORT\"
530    set_namelist namelist_cfg nn_it000 21
531    set_namelist namelist_cfg nn_itend 40
532    set_namelist namelist_cfg nn_stock 20
533    set_namelist namelist_cfg ln_clobber .true.
534    set_namelist namelist_cfg ln_read_cfg .true.
535    set_namelist namelist_cfg ln_linssh .true.
536    set_namelist namelist_cfg jpni 4
537    set_namelist namelist_cfg jpnj 8
538    set_namelist namelist_cfg jpnij 32
539    set_namelist namelist_top_cfg ln_rsttr .true.
540    set_namelist namelist_top_cfg nn_rsttr 2
541    set_namelist namelist_top_cfg cn_trcrst_in \"OFFP_LONG_00000020_restart_trc\"
542    for (( i=1; i<=$NPROC; i++)) ; do
543        L_NPROC=$(( $i - 1 ))
544        L_NPROC=`printf "%04d\n" ${L_NPROC}`
545        ln -sf ../LONG/OFFP_LONG_00000020_restart_trc_${L_NPROC}.nc .
546    done
547    # put ln_ironsed, ln_river, ln_ndepo, ln_dust
548    # if not you need input files, and for tests is not necessary
549    set_namelist namelist_pisces_cfg ln_presatm .false.
550    set_namelist namelist_pisces_cfg ln_varpar .false.
551    set_namelist namelist_pisces_cfg ln_dust .false.
552    set_namelist namelist_pisces_cfg ln_solub .false.
553    set_namelist namelist_pisces_cfg ln_river .false.
554    set_namelist namelist_pisces_cfg ln_ndepo .false.
555    set_namelist namelist_pisces_cfg ln_ironsed .false.
556    set_namelist namelist_pisces_cfg ln_ironice .false.
557    set_namelist namelist_pisces_cfg ln_hydrofe .false.
558    # put ln_pisdmp to false : no restoring to global mean value
559    set_namelist namelist_pisces_cfg ln_pisdmp .false.
560    if [ ${USING_MPMD} == "yes" ] ; then
561       set_xio_using_server iodef.xml true
562    else
563       set_xio_using_server iodef.xml false
564    fi
565    cd ${SETTE_DIR}
566    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME}  ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
567    cd ${SETTE_DIR}
568    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
569fi
570
571if [ ${config} -eq 6 ] ;  then
572    ## Reproducibility tests for ORCA2_OFF_PISCES
573    export TEST_NAME="REPRO_4_8"
574    cd ${CONFIG_DIR0}
575    . ./makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_32 -r ORCA2_OFF_PISCES -j 8 del_key ${DEL_KEYS}
576    cd ${SETTE_DIR}
577    . ./param.cfg
578    . ./all_functions.sh
579    . ./prepare_exe_dir.sh
580    JOB_FILE=${EXE_DIR}/run_job.sh
581    NPROC=32
582    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
583    cd ${EXE_DIR}
584    set_namelist namelist_cfg nn_it000 1
585    set_namelist namelist_cfg nn_itend 40
586    set_namelist namelist_cfg ln_ctl .false.
587    set_namelist namelist_cfg ln_clobber .true.
588    set_namelist namelist_cfg ln_read_cfg .true.
589    set_namelist namelist_cfg ln_linssh .true.
590    set_namelist namelist_cfg jpni 4
591    set_namelist namelist_cfg jpnj 8
592    set_namelist namelist_cfg jpnij 32
593    set_namelist namelist_top_cfg ln_trcdta .false.
594    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
595    # if not you need input files, and for tests is not necessary
596    set_namelist namelist_pisces_cfg ln_presatm .false.
597    set_namelist namelist_pisces_cfg ln_varpar .false.
598    set_namelist namelist_pisces_cfg ln_dust .false.
599    set_namelist namelist_pisces_cfg ln_solub .false.
600    set_namelist namelist_pisces_cfg ln_river .false.
601    set_namelist namelist_pisces_cfg ln_ndepo .false.
602    set_namelist namelist_pisces_cfg ln_ironsed .false.
603    set_namelist namelist_pisces_cfg ln_ironice .false.
604    set_namelist namelist_pisces_cfg ln_hydrofe .false.
605    # put ln_pisdmp to false : no restoring to global mean value
606    set_namelist namelist_pisces_cfg ln_pisdmp .false.
607    if [ ${USING_MPMD} == "yes" ] ; then
608       set_xio_using_server iodef.xml true
609    else
610       set_xio_using_server iodef.xml false
611    fi
612    cd ${SETTE_DIR}
613    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
614    cd ${SETTE_DIR}
615    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
616
617    cd ${SETTE_DIR}
618    export TEST_NAME="REPRO_8_4"
619    . ./prepare_exe_dir.sh
620    JOB_FILE=${EXE_DIR}/run_job.sh
621    NPROC=32
622    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
623    cd ${EXE_DIR}
624    set_namelist namelist_cfg nn_it000 1
625    set_namelist namelist_cfg nn_itend 40
626    set_namelist namelist_cfg ln_ctl .false.
627    set_namelist namelist_cfg ln_clobber .true.
628    set_namelist namelist_cfg ln_read_cfg .true.
629    set_namelist namelist_cfg ln_linssh .true.
630    set_namelist namelist_cfg jpni 8
631    set_namelist namelist_cfg jpnj 4
632    set_namelist namelist_cfg jpnij 32
633    set_namelist namelist_top_cfg ln_trcdta .false.
634    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
635    # if not you need input files, and for tests is not necessary
636    set_namelist namelist_pisces_cfg ln_presatm .false.
637    set_namelist namelist_pisces_cfg ln_varpar .false.
638    set_namelist namelist_pisces_cfg ln_dust .false.
639    set_namelist namelist_pisces_cfg ln_solub .false.
640    set_namelist namelist_pisces_cfg ln_river .false.
641    set_namelist namelist_pisces_cfg ln_ndepo .false.
642    set_namelist namelist_pisces_cfg ln_ironsed .false.
643    set_namelist namelist_pisces_cfg ln_ironice .false.
644    set_namelist namelist_pisces_cfg ln_hydrofe .false.
645    # put ln_pisdmp to false : no restoring to global mean value
646    set_namelist namelist_pisces_cfg ln_pisdmp .false.
647    if [ ${USING_MPMD} == "yes" ] ; then
648       set_xio_using_server iodef.xml true
649    else
650       set_xio_using_server iodef.xml false
651    fi
652    cd ${SETTE_DIR}
653    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
654    cd ${SETTE_DIR}
655    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
656fi
657
658# TESTS FOR AMM12 CONFIGURATION
659if [ ${config} -eq 7 ] ;  then
660    ## Restartability tests for AMM12
661    export TEST_NAME="LONG"
662    cd ${CONFIG_DIR0}
663    . ./makenemo -m ${CMP_NAM} -n AMM12_LONG -r AMM12 -j 8 add_key "key_tide" del_key ${DEL_KEYS}
664    cd ${SETTE_DIR}
665    . ./param.cfg
666    . ./all_functions.sh
667    . ./prepare_exe_dir.sh
668    JOB_FILE=${EXE_DIR}/run_job.sh
669    NPROC=32
670    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
671    cd ${EXE_DIR}
672    set_namelist namelist_cfg nn_it000 1
673    set_namelist namelist_cfg nn_itend 576
674    set_namelist namelist_cfg nn_stock 288
675    set_namelist namelist_cfg nn_fwb 0
676    set_namelist namelist_cfg ln_ctl .false.
677    set_namelist namelist_cfg ln_clobber .true.
678    set_namelist namelist_cfg ln_read_cfg .true.
679    set_namelist namelist_cfg ln_linssh .false.
680    set_namelist namelist_cfg jpni 4
681    set_namelist namelist_cfg jpnj 8
682    set_namelist namelist_cfg jpnij 32
683    if [ ${USING_MPMD} == "yes" ] ; then
684       set_xio_using_server iodef.xml true
685    else
686       set_xio_using_server iodef.xml false
687    fi
688    cd ${SETTE_DIR}
689    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
690
691    cd ${SETTE_DIR}
692    export TEST_NAME="SHORT"
693    . ./prepare_exe_dir.sh
694    cd ${EXE_DIR}
695    set_namelist namelist_cfg nn_it000 289
696    set_namelist namelist_cfg nn_itend 576
697    set_namelist namelist_cfg nn_fwb 0
698    set_namelist namelist_cfg ln_ctl .false.
699    set_namelist namelist_cfg ln_clobber .true.
700    set_namelist namelist_cfg ln_read_cfg .true.
701    set_namelist namelist_cfg ln_linssh .false.
702    set_namelist namelist_cfg jpni 4
703    set_namelist namelist_cfg jpnj 8
704    set_namelist namelist_cfg jpnij 32
705    set_namelist namelist_cfg ln_rstart .true.
706    set_namelist namelist_cfg nn_rstctl 2
707    set_namelist namelist_cfg cn_ocerst_in \"AMM12_00000288_restart_oce_out\"
708    set_namelist namelist_cfg nn_date0 20120102
709    for (( i=1; i<=$NPROC; i++)) ; do
710        L_NPROC=$(( $i - 1 ))
711        L_NPROC=`printf "%04d\n" ${L_NPROC}`
712        ln -sf ../LONG/AMM12_00000288_restart_oce_out_${L_NPROC}.nc .
713    done
714    if [ ${USING_MPMD} == "yes" ] ; then
715       set_xio_using_server iodef.xml true
716    else
717       set_xio_using_server iodef.xml false
718    fi
719    cd ${SETTE_DIR}
720    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
721    cd ${SETTE_DIR}
722    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
723fi
724
725if [ ${config} -eq 8 ] ;  then
726## Reproducibility tests for AMM12
727    export TEST_NAME="REPRO_8_4"
728    cd ${CONFIG_DIR0}
729    . ./makenemo -m ${CMP_NAM} -n AMM12_32 -r AMM12 -j 8 del_key ${DEL_KEYS}
730    cd ${SETTE_DIR}
731    . ./param.cfg
732    . ./all_functions.sh
733    . ./prepare_exe_dir.sh
734    JOB_FILE=${EXE_DIR}/run_job.sh
735    NPROC=32
736    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
737    cd ${EXE_DIR}
738    set_namelist namelist_cfg nn_it000 1
739    set_namelist namelist_cfg nn_itend 576
740    set_namelist namelist_cfg nn_fwb 0
741    set_namelist namelist_cfg ln_ctl .false.
742    set_namelist namelist_cfg ln_clobber .true.
743    set_namelist namelist_cfg ln_read_cfg .true.
744    set_namelist namelist_cfg ln_linssh .false.
745    set_namelist namelist_cfg jpni 8
746    set_namelist namelist_cfg jpnj 4
747    set_namelist namelist_cfg jpnij 32
748    if [ ${USING_MPMD} == "yes" ] ; then
749       set_xio_using_server iodef.xml true
750    else
751       set_xio_using_server iodef.xml false
752    fi
753    cd ${SETTE_DIR}
754    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
755    cd ${SETTE_DIR}
756    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
757
758    cd ${SETTE_DIR}
759    export TEST_NAME="REPRO_4_8"
760    . ./prepare_exe_dir.sh
761    JOB_FILE=${EXE_DIR}/run_job.sh
762    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
763    cd ${EXE_DIR}
764    set_namelist namelist_cfg nn_it000 1
765    set_namelist namelist_cfg nn_itend 576
766    set_namelist namelist_cfg nn_fwb 0
767    set_namelist namelist_cfg ln_ctl .false.
768    set_namelist namelist_cfg ln_clobber .true.
769    set_namelist namelist_cfg ln_read_cfg .true.
770    set_namelist namelist_cfg ln_linssh .false.
771    set_namelist namelist_cfg jpni 4
772    set_namelist namelist_cfg jpnj 8
773    set_namelist namelist_cfg jpnij 32
774    if [ ${USING_MPMD} == "yes" ] ; then
775       set_xio_using_server iodef.xml true
776    else
777       set_xio_using_server iodef.xml false
778    fi
779    cd ${SETTE_DIR}
780    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
781    cd ${SETTE_DIR}
782    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
783fi
784
785
786# TESTS FOR ORCA2_SAS_LIM3 CONFIGURATION
787if [ ${config} -eq 9 ] ;  then
788    ## Restartability tests for SAS
789    export TEST_NAME="LONG"
790    cd ${CONFIG_DIR0}
791    . ./makenemo -m ${CMP_NAM} -n SAS_LONG -r ORCA2_SAS_LIM3 -j 8 del_key ${DEL_KEYS}
792    cd ${SETTE_DIR}
793    . ./param.cfg
794    . ./all_functions.sh
795    . ./prepare_exe_dir.sh
796    JOB_FILE=${EXE_DIR}/run_job.sh
797    NPROC=32
798    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
799    cd ${EXE_DIR}
800    set_namelist namelist_cfg cn_exp \"SAS\"
801    set_namelist namelist_cfg nn_it000 1
802    set_namelist namelist_cfg nn_itend 100
803    set_namelist namelist_cfg nn_stock 50
804    set_namelist namelist_cfg ln_ctl .false.
805    set_namelist namelist_cfg ln_clobber .true.
806    set_namelist namelist_cfg ln_read_cfg .true.
807    set_namelist namelist_cfg ln_linssh .true.
808    set_namelist namelist_cfg nn_fwb 0
809    set_namelist namelist_cfg jpni 4
810    set_namelist namelist_cfg jpnj 8
811    set_namelist namelist_cfg jpnij 32
812    if [ ${USING_MPMD} == "yes" ] ; then
813       set_xio_using_server iodef.xml true
814    else
815       set_xio_using_server iodef.xml false
816    fi
817    cd ${SETTE_DIR}
818    . ./prepare_job.sh input_SAS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
819
820    cd ${SETTE_DIR}
821    export TEST_NAME="SHORT"
822    . ./prepare_exe_dir.sh
823    cd ${EXE_DIR}
824    set_namelist namelist_cfg cn_exp \"SAS\"
825    set_namelist namelist_cfg nn_it000 51
826    set_namelist namelist_cfg nn_itend 100
827    set_namelist namelist_cfg ln_ctl .false.
828    set_namelist namelist_cfg ln_clobber .true.
829    set_namelist namelist_cfg ln_read_cfg .true.
830    set_namelist namelist_cfg ln_linssh .true.
831    set_namelist namelist_cfg nn_fwb 0
832    set_namelist namelist_cfg jpni 4
833    set_namelist namelist_cfg jpnj 8
834    set_namelist namelist_cfg jpnij 32
835    set_namelist namelist_cfg ln_rstart .true.
836    set_namelist namelist_cfg nn_rstctl 2
837    set_namelist namelist_ice_cfg cn_icerst_in \"SAS_00000050_restart_ice\"
838    if [ ${USING_MPMD} == "yes" ] ; then
839       set_xio_using_server iodef.xml true
840    else
841       set_xio_using_server iodef.xml false
842    fi
843    for (( i=1; i<=$NPROC; i++)) ; do
844        L_NPROC=$(( $i - 1 ))
845        L_NPROC=`printf "%04d\n" ${L_NPROC}`
846        ln -sf ../LONG/SAS_00000050_restart_ice_${L_NPROC}.nc .
847    done
848    cd ${SETTE_DIR}
849    . ./prepare_job.sh input_SAS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
850    cd ${SETTE_DIR}
851    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
852fi
853
854# TESTS FOR ISOMIP CONFIGURATION
855if [ ${config} -eq 10 ] ;  then
856    ## Restartability tests for ISOMIP
857    export TEST_NAME="LONG"
858    cd ${CONFIG_DIR0}
859    . ./makenemo -m ${CMP_NAM} -n ISOMIP_LONG -r ISOMIP -a TEST_CASES -j 8 del_key ${DEL_KEYS}
860    cd ${SETTE_DIR}
861    . ./param.cfg
862    . ./all_functions.sh
863    . ./prepare_exe_dir.sh
864    JOB_FILE=${EXE_DIR}/run_job.sh
865    NPROC=32
866    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
867    cd ${EXE_DIR}
868    set_namelist namelist_cfg cn_exp \"ISOMIP_LONG\"
869    set_namelist namelist_cfg nn_it000 1
870    set_namelist namelist_cfg nn_itend 96
871    set_namelist namelist_cfg nn_stock 48
872    set_namelist namelist_cfg ln_clobber .true.
873    set_namelist namelist_cfg ln_read_cfg .false.
874    set_namelist namelist_cfg jpni 4
875    set_namelist namelist_cfg jpnj 8
876    set_namelist namelist_cfg jpnij 32
877    if [ ${USING_MPMD} == "yes" ] ; then
878       set_xio_using_server iodef.xml true
879    else
880       set_xio_using_server iodef.xml false
881    fi
882    cd ${SETTE_DIR}
883    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
884
885    cd ${SETTE_DIR}
886    export TEST_NAME="SHORT"
887    . ./prepare_exe_dir.sh
888    cd ${EXE_DIR}
889    set_namelist namelist_cfg cn_exp \"ISOMIP_SHORT\"
890    set_namelist namelist_cfg nn_it000 49
891    set_namelist namelist_cfg nn_itend 96
892    set_namelist namelist_cfg nn_stock 48
893    set_namelist namelist_cfg ln_rstart .true.
894    set_namelist namelist_cfg nn_rstctl 2
895    set_namelist namelist_cfg ln_clobber .true.
896    set_namelist namelist_cfg ln_read_cfg .false.
897    set_namelist namelist_cfg jpni 4
898    set_namelist namelist_cfg jpnj 8
899    set_namelist namelist_cfg jpnij 32
900    set_namelist namelist_cfg cn_ocerst_in \"ISOMIP_LONG_00000048_restart\"
901    if [ ${USING_MPMD} == "yes" ] ; then
902       set_xio_using_server iodef.xml true
903    else
904       set_xio_using_server iodef.xml false
905    fi
906    for (( i=1; i<=$NPROC; i++)) ; do
907        L_NPROC=$(( $i - 1 ))
908        L_NPROC=`printf "%04d\n" ${L_NPROC}`
909        ln -sf ../LONG/ISOMIP_LONG_00000048_restart_${L_NPROC}.nc .
910    done
911    if [ ${USING_MPMD} == "yes" ] ; then
912       set_xio_using_server iodef.xml true
913    else
914       set_xio_using_server iodef.xml false
915    fi
916    cd ${SETTE_DIR}
917    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
918    cd ${SETTE_DIR}
919    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
920fi
921if [ ${config} -eq 11 ] ;  then
922    ## Reproducibility tests for ISOMIP
923    export TEST_NAME="REPRO_4_8"
924    cd ${CONFIG_DIR0}
925    . ./makenemo -m ${CMP_NAM} -n ISOMIP_32 -r ISOMIP -a TEST_CASES -j 8 del_key ${DEL_KEYS}
926    cd ${SETTE_DIR}
927    . ./param.cfg
928    . ./all_functions.sh
929    . ./prepare_exe_dir.sh
930    JOB_FILE=${EXE_DIR}/run_job.sh
931    NPROC=32
932    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
933    cd ${EXE_DIR}
934    set_namelist namelist_cfg cn_exp \"ISOMIP_14\"
935    set_namelist namelist_cfg nn_it000 1
936    set_namelist namelist_cfg nn_itend 48
937    set_namelist namelist_cfg ln_ctl .false.
938    set_namelist namelist_cfg ln_clobber .true.
939    set_namelist namelist_cfg ln_read_cfg .false.
940    set_namelist namelist_cfg jpni 4
941    set_namelist namelist_cfg jpnj 8
942    set_namelist namelist_cfg jpnij 32
943    if [ ${USING_MPMD} == "yes" ] ; then
944       set_xio_using_server iodef.xml true
945    else
946       set_xio_using_server iodef.xml false
947    fi
948    cd ${SETTE_DIR}
949    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
950    cd ${SETTE_DIR}
951    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
952
953    cd ${SETTE_DIR}
954    export TEST_NAME="REPRO_8_4"
955    . ./prepare_exe_dir.sh
956    JOB_FILE=${EXE_DIR}/run_job.sh
957    NPROC=32
958    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
959    cd ${EXE_DIR}
960    set_namelist namelist_cfg cn_exp \"ISOMIP_22\"
961    set_namelist namelist_cfg nn_it000 1
962    set_namelist namelist_cfg nn_itend 48
963    set_namelist namelist_cfg ln_ctl .false.
964    set_namelist namelist_cfg ln_clobber .true.
965    set_namelist namelist_cfg ln_read_cfg .false.
966    set_namelist namelist_cfg jpni 8
967    set_namelist namelist_cfg jpnj 4
968    set_namelist namelist_cfg jpnij 32
969    if [ ${USING_MPMD} == "yes" ] ; then
970       set_xio_using_server iodef.xml true
971    else
972       set_xio_using_server iodef.xml false
973    fi
974    cd ${SETTE_DIR}
975    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
976    cd ${SETTE_DIR}
977    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
978
979fi
980
981## Test assimilation interface code, OBS and ASM for reproducibility
982## Restartability not tested (ASM code not restartable while increments are being applied)
983if [ ${config} -eq 12 ] ; then
984   ## Reproducibility tests for ORCA2_LIM3_OBS
985    export TEST_NAME="REPRO_4_8"
986    cd ${CONFIG_DIR0}
987    . ./makenemo -m ${CMP_NAM} -n ORCA2_LIM3_OBS -r ORCA2_LIM3_PISCES -j 8 add_key "key_asminc"
988    cd ${SETTE_DIR}
989    . ./param.cfg
990    . ./all_functions.sh
991    . ./prepare_exe_dir.sh
992    JOB_FILE=${EXE_DIR}/run_job.sh
993    NPROC=32
994    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
995    cd ${EXE_DIR}
996    set_namelist namelist_cfg nn_it000 1
997    set_namelist namelist_cfg nn_itend 75
998    set_namelist namelist_cfg nn_fwb 0
999    set_namelist namelist_cfg ln_ctl .false.
1000    set_namelist namelist_cfg ln_clobber .true.
1001    set_namelist namelist_cfg ln_read_cfg .true.
1002    set_namelist namelist_cfg ln_linssh .false.
1003    set_namelist namelist_cfg ln_icebergs .false.
1004    set_namelist namelist_cfg jpni 4
1005    set_namelist namelist_cfg jpnj 8
1006    set_namelist namelist_cfg jpnij 32
1007    set_namelist namelist_cfg ln_diaobs .true.
1008    set_namelist namelist_cfg ln_t3d .true.
1009    set_namelist namelist_cfg ln_s3d .true.
1010    set_namelist namelist_cfg ln_sst .true.
1011    set_namelist namelist_cfg ln_sla .true.
1012    set_namelist namelist_cfg ln_sic .true.
1013    set_namelist namelist_cfg ln_vel3d .true.
1014    set_namelist namelist_cfg ln_bkgwri .true.
1015    set_namelist namelist_cfg ln_trainc .true.
1016    set_namelist namelist_cfg ln_dyninc .true.
1017    set_namelist namelist_cfg ln_sshinc .true.
1018    set_namelist namelist_cfg ln_asmiau .true.
1019    #remove all useless options for pisces (due to ORCA2_LIM3_PISCES reference configuration)
1020    set_namelist namelist_top_cfg ln_trcdta .false.
1021    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
1022    # if not you need input files, and for tests is not necessary
1023    set_namelist namelist_pisces_cfg ln_presatm .false.
1024    set_namelist namelist_pisces_cfg ln_varpar .false.
1025    set_namelist namelist_pisces_cfg ln_dust .false.
1026    set_namelist namelist_pisces_cfg ln_solub .false.
1027    set_namelist namelist_pisces_cfg ln_river .false.
1028    set_namelist namelist_pisces_cfg ln_ndepo .false.
1029    set_namelist namelist_pisces_cfg ln_ironsed .false.
1030    set_namelist namelist_pisces_cfg ln_ironice .false.
1031    set_namelist namelist_pisces_cfg ln_hydrofe .false.
1032    if [ ${USING_MPMD} == "yes" ] ; then
1033       set_xio_using_server iodef.xml true
1034    else
1035       set_xio_using_server iodef.xml false
1036    fi
1037    cd ${SETTE_DIR}
1038    . ./prepare_job.sh input_ORCA2_LIM3_OBS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1039    cd ${SETTE_DIR}
1040    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1041
1042   cd ${SETTE_DIR}
1043    export TEST_NAME="REPRO_8_4"
1044    . ./prepare_exe_dir.sh
1045    JOB_FILE=${EXE_DIR}/run_job.sh
1046    NPROC=32
1047    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1048    cd ${EXE_DIR}
1049    set_namelist namelist_cfg nn_it000 1
1050    set_namelist namelist_cfg nn_itend 75
1051    set_namelist namelist_cfg nn_fwb 0
1052    set_namelist namelist_cfg ln_ctl .false.
1053    set_namelist namelist_cfg ln_clobber .true.
1054    set_namelist namelist_cfg ln_read_cfg .true.
1055    set_namelist namelist_cfg ln_linssh .false.
1056    set_namelist namelist_cfg ln_icebergs .false.
1057    set_namelist namelist_cfg jpni 8
1058    set_namelist namelist_cfg jpnj 4
1059    set_namelist namelist_cfg jpnij 32
1060    set_namelist namelist_cfg ln_diaobs .true.
1061    set_namelist namelist_cfg ln_t3d .true.
1062    set_namelist namelist_cfg ln_s3d .true.
1063    set_namelist namelist_cfg ln_sst .true.
1064    set_namelist namelist_cfg ln_sla .true.
1065    set_namelist namelist_cfg ln_sic .true.
1066    set_namelist namelist_cfg ln_vel3d .true.
1067    set_namelist namelist_cfg ln_bkgwri .true.
1068    set_namelist namelist_cfg ln_trainc .true.
1069    set_namelist namelist_cfg ln_dyninc .true.
1070    set_namelist namelist_cfg ln_sshinc .true.
1071    set_namelist namelist_cfg ln_asmiau .true.
1072    #remove all useless options for pisces (due to ORCA2_LIM3_PISCES reference configuration)
1073    set_namelist namelist_top_cfg ln_trcdta .false.
1074    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
1075    # if not you need input files, and for tests is not necessary
1076    set_namelist namelist_pisces_cfg ln_presatm .false.
1077    set_namelist namelist_pisces_cfg ln_varpar .false.
1078    set_namelist namelist_pisces_cfg ln_dust .false.
1079    set_namelist namelist_pisces_cfg ln_solub .false.
1080    set_namelist namelist_pisces_cfg ln_river .false.
1081    set_namelist namelist_pisces_cfg ln_ndepo .false.
1082    set_namelist namelist_pisces_cfg ln_ironsed .false.
1083    set_namelist namelist_pisces_cfg ln_ironice .false.
1084    set_namelist namelist_pisces_cfg ln_hydrofe .false.
1085    if [ ${USING_MPMD} == "yes" ] ; then
1086       set_xio_using_server iodef.xml true
1087    else
1088       set_xio_using_server iodef.xml false
1089    fi
1090    cd ${SETTE_DIR}
1091    . ./prepare_job.sh input_ORCA2_LIM3_OBS.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1092    cd ${SETTE_DIR}
1093    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1094fi
1095# TEST FOR ORCA2_LIM3_AGRIF : simple test of running AGRIF (no restartability neither reproducibility tests)
1096if [ ${config} -eq 13 ] ;  then
1097    ## ORCA2_LIM3 with Agulhas AGRIF zoom in MPI
1098    export TEST_NAME="SHORT"
1099    cd ${CONFIG_DIR0}
1100    . ./makenemo -m ${CMP_NAM} -n ORCA2AGUL_1_2 -r ORCA2_LIM3_PISCES -j 8 add_key "key_agrif" del_key "key_zdftmx"
1101    cd ${SETTE_DIR}
1102    . ./param.cfg
1103    . ./all_functions.sh
1104    . ./prepare_exe_dir.sh
1105    JOB_FILE=${EXE_DIR}/run_job.sh
1106    NPROC=2
1107    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1108    cd ${EXE_DIR}
1109    set_namelist namelist_cfg nn_it000 1
1110    set_namelist namelist_cfg nn_itend 75
1111    set_namelist namelist_cfg ln_ctl .false.
1112    set_namelist namelist_cfg ln_clobber .true.
1113    set_namelist namelist_cfg ln_read_cfg .true.
1114    set_namelist namelist_cfg ln_linssh .true.
1115    set_namelist namelist_cfg ln_hpg_sco .false.
1116    set_namelist namelist_cfg ln_hpg_zps .true.
1117    set_namelist namelist_cfg nn_fwb 0
1118    set_namelist namelist_cfg jpni 1
1119    set_namelist namelist_cfg jpnj 2
1120    set_namelist namelist_cfg jpnij 2
1121    set_namelist 1_namelist_cfg nn_it000 1
1122    set_namelist 1_namelist_cfg nn_itend 150
1123    set_namelist 1_namelist_cfg ln_ctl .false.
1124    set_namelist 1_namelist_cfg ln_clobber .true.
1125    set_namelist 1_namelist_cfg ln_read_cfg .true.
1126    set_namelist 1_namelist_cfg ln_linssh .true.
1127    set_namelist 1_namelist_cfg ln_hpg_sco .false.
1128    set_namelist 1_namelist_cfg ln_hpg_zps .true.
1129    if [ ${USING_MPMD} == "yes" ] ; then
1130       set_xio_using_server iodef.xml true
1131    else
1132       set_xio_using_server iodef.xml false
1133    fi
1134    cd ${SETTE_DIR}
1135    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1136    cd ${SETTE_DIR}
1137    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1138fi
1139
1140# test code corruption with AGRIF
1141# Compile and run with or without AGRIF ORCA2_LIM3
1142if [ ${config} -eq 14 ] ;  then
1143    # First run same as 15 but without zoom
1144    export TEST_NAME="SHORT_NOZOOM"
1145    cd ${CONFIG_DIR0}
1146    . ./makenemo -m ${CMP_NAM} -n ORCA2AGUL_2_2 -r ORCA2_LIM3_PISCES -j 8 add_key "key_agrif" del_key "key_zdftmx"
1147    cd ${SETTE_DIR}
1148    . ./param.cfg
1149    . ./all_functions.sh
1150    . ./prepare_exe_dir.sh
1151    JOB_FILE=${EXE_DIR}/run_job.sh
1152    NPROC=4
1153    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1154    cd ${EXE_DIR}
1155    set_namelist namelist_cfg nn_it000 1
1156    set_namelist namelist_cfg nn_itend 75
1157    set_namelist namelist_cfg ln_ctl .false.
1158    set_namelist namelist_cfg ln_clobber .true.
1159    set_namelist namelist_cfg ln_read_cfg .true.
1160    set_namelist namelist_cfg ln_linssh .true.
1161    set_namelist namelist_cfg ln_hpg_sco .false.
1162    set_namelist namelist_cfg ln_hpg_zps .true.
1163    set_namelist namelist_cfg nn_fwb 0
1164    set_namelist namelist_cfg jpni 2
1165    set_namelist namelist_cfg jpnj 2
1166    set_namelist namelist_cfg jpnij 4
1167#
1168#   Set the number of fine grids to zero:   
1169    sed -i "1s/.*/0/" ${EXE_DIR}/AGRIF_FixedGrids.in
1170
1171    if [ ${USING_MPMD} == "yes" ] ; then
1172       set_xio_using_server iodef.xml true
1173    else
1174       set_xio_using_server iodef.xml false
1175    fi
1176    cd ${SETTE_DIR}
1177    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1178    cd ${SETTE_DIR}
1179    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1180
1181    export TEST_NAME="SHORT_NOAGRIF"
1182    cd ${CONFIG_DIR0}
1183    . ./makenemo -m ${CMP_NAM} -n ORCA2AGUL_2_2_NAG -r ORCA2_LIM3_PISCES -j 8 del_key "key_zdftmx"
1184    cd ${SETTE_DIR}
1185    . ./param.cfg
1186    . ./all_functions.sh
1187    . ./prepare_exe_dir.sh
1188    JOB_FILE=${EXE_DIR}/run_job.sh
1189    NPROC=4
1190    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1191    cd ${EXE_DIR}
1192    set_namelist namelist_cfg nn_it000 1
1193    set_namelist namelist_cfg nn_itend 75
1194    set_namelist namelist_cfg ln_ctl .false.
1195    set_namelist namelist_cfg ln_clobber .true.
1196    set_namelist namelist_cfg ln_read_cfg .true.
1197    set_namelist namelist_cfg ln_linssh .true.
1198    set_namelist namelist_cfg ln_hpg_sco .false.
1199    set_namelist namelist_cfg ln_hpg_zps .true.
1200    set_namelist namelist_cfg nn_fwb 0
1201    set_namelist namelist_cfg jpni 2
1202    set_namelist namelist_cfg jpnj 2
1203    set_namelist namelist_cfg jpnij 4
1204#
1205    if [ ${USING_MPMD} == "yes" ] ; then
1206       set_xio_using_server iodef.xml true
1207    else
1208       set_xio_using_server iodef.xml false
1209    fi
1210    cd ${SETTE_DIR}
1211    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1212    cd ${SETTE_DIR}
1213    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1214
1215fi
1216
1217## Restartability tests for ORCA2_LIM3_AGRIF
1218if [ ${config} -eq 15 ] ;  then
1219    export TEST_NAME="LONG"
1220    cd ${CONFIG_DIR0}
1221    . ./makenemo -m ${CMP_NAM} -n ORCA2AGUL_LONG -r ORCA2_LIM3_PISCES -j 8 add_key "key_agrif" del_key "key_zdftmx"
1222    cd ${SETTE_DIR}
1223    . ./param.cfg
1224    . ./all_functions.sh
1225    . ./prepare_exe_dir.sh
1226    JOB_FILE=${EXE_DIR}/run_job.sh
1227    NPROC=4
1228    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1229    cd ${EXE_DIR}
1230    set_namelist namelist_cfg cn_exp \"O2LP_LONG\"
1231    set_namelist namelist_cfg nn_it000 1
1232    set_namelist namelist_cfg nn_itend 150
1233    set_namelist namelist_cfg nn_stock 75
1234    set_namelist namelist_cfg ln_clobber .true.
1235    set_namelist namelist_cfg ln_read_cfg .true.
1236    set_namelist namelist_cfg ln_linssh .true.
1237    set_namelist namelist_cfg ln_hpg_sco .false.
1238    set_namelist namelist_cfg ln_hpg_zps .true.
1239    set_namelist namelist_cfg nn_fwb 0
1240    set_namelist namelist_cfg jpni 2
1241    set_namelist namelist_cfg jpnj 2
1242    set_namelist namelist_cfg jpnij 4
1243    set_namelist 1_namelist_cfg cn_exp \"O2LP_LONG\"
1244    set_namelist 1_namelist_cfg nn_it000 1
1245    set_namelist 1_namelist_cfg nn_itend 300
1246    set_namelist 1_namelist_cfg nn_stock 150
1247    set_namelist 1_namelist_cfg ln_ctl .false.
1248    set_namelist 1_namelist_cfg ln_clobber .true.
1249    set_namelist 1_namelist_cfg ln_read_cfg .true.
1250    set_namelist 1_namelist_cfg ln_linssh .true.
1251    set_namelist 1_namelist_cfg ln_hpg_sco .false.
1252    set_namelist 1_namelist_cfg ln_hpg_zps .true.
1253#
1254    if [ ${USING_MPMD} == "yes" ] ; then
1255       set_xio_using_server iodef.xml true
1256    else
1257       set_xio_using_server iodef.xml false
1258    fi
1259    cd ${SETTE_DIR}
1260    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1261   
1262    cd ${SETTE_DIR}
1263    export TEST_NAME="SHORT"
1264    . ./prepare_exe_dir.sh
1265    cd ${EXE_DIR}
1266    set_namelist namelist_cfg cn_exp \"O2LP_SHORT\"
1267    set_namelist namelist_cfg nn_it000 76
1268    set_namelist namelist_cfg nn_itend 150
1269    set_namelist namelist_cfg nn_stock 75
1270    set_namelist namelist_cfg ln_rstart .true.
1271    set_namelist namelist_cfg nn_rstctl 2
1272    set_namelist namelist_cfg ln_clobber .true.
1273    set_namelist namelist_cfg ln_read_cfg .true.
1274    set_namelist namelist_cfg ln_linssh .true.
1275    set_namelist namelist_cfg ln_hpg_sco .false.
1276    set_namelist namelist_cfg ln_hpg_zps .true.
1277    set_namelist namelist_cfg nn_fwb 0
1278    set_namelist namelist_cfg jpni 2
1279    set_namelist namelist_cfg jpnj 2
1280    set_namelist namelist_cfg jpnij 4
1281    set_namelist 1_namelist_cfg cn_exp \"O2LP_SHORT\"
1282    set_namelist 1_namelist_cfg nn_it000 151
1283    set_namelist 1_namelist_cfg nn_itend 300
1284    set_namelist 1_namelist_cfg nn_stock 150
1285    set_namelist 1_namelist_cfg ln_rstart .true.
1286    set_namelist 1_namelist_cfg nn_rstctl 2
1287    set_namelist 1_namelist_cfg ln_clobber .true.
1288    set_namelist 1_namelist_cfg ln_read_cfg .true.
1289    set_namelist 1_namelist_cfg ln_linssh .true.
1290    set_namelist 1_namelist_cfg ln_hpg_sco .false.
1291    set_namelist 1_namelist_cfg ln_hpg_zps .true.
1292    set_namelist namelist_cfg cn_ocerst_in \"O2LP_LONG_00000075_restart\"
1293    set_namelist namelist_ice_cfg cn_icerst_in \"O2LP_LONG_00000075_restart_ice\"
1294    set_namelist 1_namelist_cfg cn_ocerst_in \"O2LP_LONG_00000150_restart\"
1295
1296    for (( i=1; i<=$NPROC; i++)) ; do
1297        L_NPROC=$(( $i - 1 ))
1298        L_NPROC=`printf "%04d\n" ${L_NPROC}`
1299        ln -sf ../LONG/O2LP_LONG_00000075_restart_${L_NPROC}.nc .
1300        ln -sf ../LONG/O2LP_LONG_00000075_restart_ice_${L_NPROC}.nc .
1301        ln -sf ../LONG/1_O2LP_LONG_00000150_restart_${L_NPROC}.nc .
1302    done
1303    if [ ${USING_MPMD} == "yes" ] ; then
1304       set_xio_using_server iodef.xml true
1305    else
1306       set_xio_using_server iodef.xml false
1307    fi
1308    cd ${SETTE_DIR}
1309    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1310    cd ${SETTE_DIR}
1311    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1312fi
1313
1314## Reproducibility tests for ORCA2_LIM3_AGRIF
1315if [ ${config} -eq 16 ] ;  then
1316    export TEST_NAME="REPRO_4_4"
1317    cd ${CONFIG_DIR0}
1318    . ./makenemo -m ${CMP_NAM} -n ORCA2AGUL_16 -r ORCA2_LIM3_PISCES -j 8 add_key "key_agrif" del_key "key_zdftmx"
1319    cd ${SETTE_DIR}
1320    . ./param.cfg
1321    . ./all_functions.sh
1322    . ./prepare_exe_dir.sh
1323    JOB_FILE=${EXE_DIR}/run_job.sh
1324    NPROC=16
1325    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1326    cd ${EXE_DIR}
1327    set_namelist namelist_cfg nn_it000 1
1328    set_namelist namelist_cfg nn_itend 75
1329    set_namelist namelist_cfg ln_ctl .false.
1330    set_namelist namelist_cfg ln_clobber .true.
1331    set_namelist namelist_cfg ln_read_cfg .true.
1332    set_namelist namelist_cfg ln_linssh .true.
1333    set_namelist namelist_cfg ln_hpg_sco .false.
1334    set_namelist namelist_cfg ln_hpg_zps .true.
1335    set_namelist namelist_cfg nn_fwb 0
1336    set_namelist namelist_cfg jpni 4
1337    set_namelist namelist_cfg jpnj 4
1338    set_namelist namelist_cfg jpnij 16
1339    set_namelist 1_namelist_cfg nn_it000 1
1340    set_namelist 1_namelist_cfg nn_itend 150
1341    set_namelist 1_namelist_cfg ln_ctl .false.
1342    set_namelist 1_namelist_cfg ln_clobber .true.
1343    set_namelist 1_namelist_cfg ln_read_cfg .true.
1344    set_namelist 1_namelist_cfg ln_linssh .true.
1345    set_namelist 1_namelist_cfg ln_hpg_sco .false.
1346    set_namelist 1_namelist_cfg ln_hpg_zps .true.
1347
1348    if [ ${USING_MPMD} == "yes" ] ; then
1349       set_xio_using_server iodef.xml true
1350    else
1351       set_xio_using_server iodef.xml false
1352    fi
1353    cd ${SETTE_DIR}
1354    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1355    cd ${SETTE_DIR}
1356    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1357
1358    cd ${SETTE_DIR}
1359    export TEST_NAME="REPRO_2_8"
1360    . ./prepare_exe_dir.sh
1361    JOB_FILE=${EXE_DIR}/run_job.sh
1362    NPROC=16
1363    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
1364    cd ${EXE_DIR}
1365    set_namelist namelist_cfg nn_it000 1
1366    set_namelist namelist_cfg nn_itend 75
1367    set_namelist namelist_cfg ln_ctl .false.
1368    set_namelist namelist_cfg ln_clobber .true.
1369    set_namelist namelist_cfg ln_read_cfg .true.
1370    set_namelist namelist_cfg ln_linssh .true.
1371    set_namelist namelist_cfg ln_hpg_sco .false.
1372    set_namelist namelist_cfg ln_hpg_zps .true.
1373    set_namelist namelist_cfg nn_fwb 0
1374    set_namelist namelist_cfg jpni 2
1375    set_namelist namelist_cfg jpnj 8
1376    set_namelist namelist_cfg jpnij 16
1377    set_namelist 1_namelist_cfg nn_it000 1
1378    set_namelist 1_namelist_cfg nn_itend 150
1379    set_namelist 1_namelist_cfg ln_ctl .false.
1380    set_namelist 1_namelist_cfg ln_clobber .true.
1381    set_namelist 1_namelist_cfg ln_read_cfg .true.
1382    set_namelist 1_namelist_cfg ln_linssh .true.
1383    set_namelist 1_namelist_cfg ln_hpg_sco .false.
1384    set_namelist 1_namelist_cfg ln_hpg_zps .true.
1385
1386    if [ ${USING_MPMD} == "yes" ] ; then
1387       set_xio_using_server iodef.xml true
1388    else
1389       set_xio_using_server iodef.xml false
1390    fi
1391    cd ${SETTE_DIR}
1392    . ./prepare_job.sh input_ORCA2_LIM3_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
1393    cd ${SETTE_DIR}
1394    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
1395fi
1396
1397done
Note: See TracBrowser for help on using the repository browser.