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_test-cases.sh in utils/CI/sette – NEMO

source: utils/CI/sette/sette_test-cases.sh @ 9963

Last change on this file since 9963 was 9963, checked in by acc, 4 years ago

minor changes to sette_test-cases.sh to fix and tidy up the OVERFLOW experiments. These changes should make sure only the appropriate configuration namelist is copied to each experiment directory

  • Property svn:executable set to *
File size: 27.9 KB
Line 
1#!/bin/bash
2############################################################
3# Author : Simona Flavoni for NEMO
4# Contact: sflod@locean-ipsl.upmc.fr
5#
6# sette_test-cases.sh   : principal script of SET TEsts for NEMO (SETTE)
7#                       : this script : compiles, run and tests TEST_CASES
8#
9#                       : TO DO: test if nitend is equal to end of run.stat
10# ----------------------------------------------------------------------
11# NEMO/SETTE , NEMO Consortium (2018)
12# Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
13# ----------------------------------------------------------------------
14#
15#
16#############################################################
17#set -vx
18set -o posix
19#set -u
20#set -e
21# ===========
22# DESCRIPTION
23# ===========
24#
25# Variables to be checked by user:
26#
27# COMPILER          : name of compiler as defined in NEMOGCM/ARCH directory
28# BATCH_COMMAND_PAR :  name of the command for submitting parallel batch jobs
29# BATCH_COMMAND_SEQ :  name of the command for submitting sequential batch jobs 
30# INTERACT_FLAG     : flag to run in interactive mode "yes"
31#                           to run in batch mode "no"
32# MPIRUN_FLAG       : flag to run in parallel (MPI) "yes"
33#                           to run in sequential mode (NB_PROC = 1) "no"
34# USING_XIOS        : flag to control the activation of key_iomput
35#                      "yes" to compile using key_iomput and link to the external XIOS library
36#                      "no"  to compile without key_iomput and link to the old IOIPSL library
37# USING_MPMD        : flag to control the use of stand-alone IO servers
38#                     requires USING_XIOS="yes"
39#                      "yes" to run in MPMD (detached) mode with stand-alone IO servers
40#                      "no"  to run in SPMD (attached) mode without separate IO servers
41# NUM_XIOSERVERS    : number of stand-alone IO servers to employ
42#                     set to zero if USING_MPMD="no"
43#
44# Principal script is sette_test-cases.sh, that calls
45#
46#  makenemo  : to create successive exectuables in ${CONFIG_NAME}/BLD/bin/nemo.exe
47#              and links to nemo in ${CONFIG_NAME}/EXP00)
48#
49#  param.cfg : sets and loads following directories:
50#
51#   FORCING_DIR         : is the directory for forcing files (tarfile)
52#   INPUT_DIR           : is the directory for input files storing
53#   TMPDIR              : is the temporary directory (if needed)
54#   NEMO_VALIDATION_DIR : is the validation directory
55#
56#   (NOTE: this file is the same for all configrations to be tested with sette_test-cases.sh)
57#
58#   all_functions.sh : loads functions used by sette (note: new functions can be added here)
59#   set_namelist     : function declared in all_functions that sets namelist parameters
60#   post_test_tidyup : creates validation storage directory and copies required output files
61#                      (run.stat and ocean.output) in it after execution of test.
62#
63#  VALIDATION tree is:
64#
65#   NEMO_VALIDATION_DIR/WCONFIG_NAME/WCOMPILER_NAME/TEST_NAME/REVISION_NUMBER(or DATE)
66#
67#  prepare_exe_dir.sh : defines and creates directory where the test is executed
68#                       execution directory takes name of TEST_NAME defined for every test
69#                       in sette_test-cases.sh. (each test in executed in its own directory)
70#
71#  prepare_job.sh     : to generate the script run_job.sh
72#
73#  fcm_job.sh         : run in batch (INTERACT_FLAG="no") or interactive (INTERACT_FLAG="yes")
74#                        see sette_test-cases.sh and BATCH_TEMPLATE directory
75#
76#  NOTE: jobs requiring initial or forcing data need to have an input_CONFIG.cfg in which
77#        can be found paths to the input tar file)
78#  NOTE: if job is not launched for any reason you have the executable ready in ${EXE_DIR}
79#        directory
80#  NOTE: the changed namelists are left in ${EXE_DIR} directory whereas original namelists
81#        remain in ${NEW_CONF}/EXP00
82#
83#  NOTE: a log file, output.sette, is created in ${SETTE_DIR} with the echoes of
84#        executed commands
85#
86#  NOTE: if sette_test-cases.sh is stopped in output.sette there is written the last command
87#        executed by sette_test-cases.sh
88#
89# example use: ./sette_test-cases.sh
90#########################################################################################
91#
92# Compiler among those in NEMOGCM/ARCH
93COMPILER=X64_ADA
94
95export BATCH_COMMAND_PAR="llsubmit"
96export BATCH_COMMAND_SEQ=$BATCH_COMMAND_PAR
97export INTERACT_FLAG="no"
98export MPIRUN_FLAG="yes"
99export USING_XIOS="yes"
100#
101export DEL_KEYS="key_iomput"
102if [ ${USING_XIOS} == "yes" ] 
103 then
104   export DEL_KEYS=""
105fi
106#
107# Settings which control the use of stand alone servers (only relevant if using xios)
108#
109export USING_MPMD="no"
110export NUM_XIOSERVERS=4
111export JOB_PREFIX=batch-mpmd
112#
113if [ ${USING_MPMD} == "no" ] 
114 then
115   export NUM_XIOSERVERS=0
116   export JOB_PREFIX=batch
117fi
118#
119#
120if [ ${USING_MPMD} == "yes" ] && [ ${USING_XIOS} == "no"]
121 then
122   echo "Incompatible choices. MPMD mode requires the XIOS server"
123   exit
124fi
125
126# Directory to run the tests
127SETTE_DIR=$(cd $(dirname "$0"); pwd)
128MAIN_DIR=$(dirname $SETTE_DIR)
129CONFIG_DIR0=${MAIN_DIR}/cfgs
130TOOLS_DIR=${MAIN_DIR}/tools
131
132CMP_NAM=${1:-$COMPILER}
133# Copy job_batch_COMPILER file for specific compiler into job_batch_template
134cd ${SETTE_DIR}
135cp BATCH_TEMPLATE/${JOB_PREFIX}-${COMPILER} job_batch_template || exit
136# Description of configuration tested:
137# OVERFLOW       : 1  TEST s-coordinates : (tracers) Advection schemes: FCT2, FCT4, ubs
138#                                        & (dynamics) advection schemes: flux form (ubs, centered), vector form (een)
139#                          zps-coordinates : (tracers) Advection schemes: FCT2, FCT4, ubs
140#                                        & (dynamics) advection schemes: flux form (ubs, centered), vector form (een, and een + Hollingsworth correction)
141# LOCK_EXCHANGE  : 2
142# VORTEX         : 3
143# ICEDYN         : 4
144# ISOMIP         : 5
145# WAD
146
147
148for config in 1 2 3 4 5
149do
150
151# ---------
152#  OVERFLOW
153# ---------
154if [ ${config} -eq 1 ] ;  then
155    ## Restartability tests for OVERFLOW
156    export TEST_NAME="LONG"
157    cd ${MAIN_DIR}
158    . ./makenemo -m ${CMP_NAM} -n OVERFLOW_ST -a OVERFLOW -j 8 del_key ${DEL_KEYS}
159    cd ${SETTE_DIR}
160    . ./param.cfg
161    . ./all_functions.sh
162    . ./prepare_exe_dir.sh
163    JOB_FILE=${EXE_DIR}/run_job.sh
164    NPROC=1
165    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
166    cd ${EXE_DIR} 
167    set_namelist namelist_cfg cn_exp \"OVF_LONG\"
168    set_namelist namelist_cfg nn_it000 1
169    set_namelist namelist_cfg nn_itend 120
170    set_namelist namelist_cfg nn_stock 60
171    if [ ${USING_MPMD} == "yes" ] ; then
172       set_xio_using_server iodef.xml true
173    else
174       set_xio_using_server iodef.xml false
175    fi
176    cd ${SETTE_DIR}
177    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
178
179    cd ${SETTE_DIR}
180    export TEST_NAME="SHORT"
181    . ./prepare_exe_dir.sh
182    cd ${EXE_DIR}
183    set_namelist namelist_cfg cn_exp \"OVF_SHORT\"
184    set_namelist namelist_cfg nn_it000 61
185    set_namelist namelist_cfg nn_itend 120
186    set_namelist namelist_cfg nn_stock 60
187    set_namelist namelist_cfg ln_rstart .true.
188    set_namelist namelist_cfg nn_rstctl 2
189    set_namelist namelist_cfg cn_ocerst_in \"OVF_LONG_00000060_restart\"
190    if [ ${USING_MPMD} == "yes" ] ; then
191       set_xio_using_server iodef.xml true
192    else
193       set_xio_using_server iodef.xml false
194    fi
195    ln -sf ../LONG/OVF_LONG_00000060_restart.nc .
196
197    cd ${SETTE_DIR}
198    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
199    cd ${SETTE_DIR}
200    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
201
202
203    ## Test for all advection, vert. coordinates, vector form, flux form: test runability and complete all time steps
204    ## Needed namelist-xxxx for every type of run tested
205    cd ${CONFIG_DIR}/${NEW_CONF}/EXP00
206
207    for file in $(echo `ls namelist_*_cfg `) ; do
208        TEST_NAME=`echo $file | sed -e "s/namelist_//" | sed -e "s/_cfg//"`
209        TEST_NAME="EXP-${TEST_NAME}"
210        if [ ! -d ${CONFIG_DIR}/${NEW_CONF}/${TEST_NAME} ] ; then mkdir ${CONFIG_DIR}/${NEW_CONF}/${TEST_NAME} ; fi
211        export TEST_NAME="${TEST_NAME}"
212         ##
213        cd ${SETTE_DIR}
214        . ./param.cfg
215        . ./all_functions.sh
216        . ./prepare_exe_dir.sh
217        JOB_FILE=${EXE_DIR}/run_job.sh
218        NPROC=1
219        if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
220        cd ${EXE_DIR}
221        rm namelist_*_*_*_*
222        cp -pL ${CONFIG_DIR}/${NEW_CONF}/EXP00/$file namelist_cfg
223        if [ ${USING_MPMD} == "yes" ] ; then
224           set_xio_using_server iodef.xml true
225        else
226           set_xio_using_server iodef.xml false
227        fi
228        cd ${SETTE_DIR}
229        . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
230        cd ${SETTE_DIR}
231        . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
232       ##
233     done
234fi
235
236# --------------
237#  LOCK_EXCHANGE
238# --------------
239if [ ${config} -eq 2 ] ;  then
240    ## Restartability tests for LOCK_EXCHANGE
241    export TEST_NAME="LONG"
242    cd ${MAIN_DIR}
243    . ./makenemo -m ${CMP_NAM} -n LOCK_EXCHANGE_ST -a OVERFLOW -j 8 del_key ${DEL_KEYS}
244    cd ${SETTE_DIR}
245    . ./param.cfg
246    . ./all_functions.sh
247    . ./prepare_exe_dir.sh
248    JOB_FILE=${EXE_DIR}/run_job.sh
249    NPROC=1
250    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
251    cd ${EXE_DIR}
252    set_namelist namelist_cfg cn_exp \"LOCK_LONG\"
253    set_namelist namelist_cfg nn_it000 1
254    set_namelist namelist_cfg nn_stock 60
255    set_namelist namelist_cfg nn_itend 120
256    if [ ${USING_MPMD} == "yes" ] ; then
257       set_xio_using_server iodef.xml true
258    else
259       set_xio_using_server iodef.xml false
260    fi
261    cd ${SETTE_DIR}
262    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
263
264    cd ${SETTE_DIR}
265    export TEST_NAME="SHORT"
266    . ./prepare_exe_dir.sh
267    cd ${EXE_DIR}
268    set_namelist namelist_cfg cn_exp \"LOCK_SHORT\"
269    set_namelist namelist_cfg nn_it000 61
270    set_namelist namelist_cfg nn_itend 120
271    set_namelist namelist_cfg nn_stock 60
272    set_namelist namelist_cfg ln_rstart .true.
273    set_namelist namelist_cfg nn_rstctl 2
274    set_namelist namelist_cfg cn_ocerst_in \"LOCK_LONG_00000060_restart\"
275    if [ ${USING_MPMD} == "yes" ] ; then
276       set_xio_using_server iodef.xml true
277    else
278       set_xio_using_server iodef.xml false
279    fi
280    ln -sf ../LONG/LOCK_LONG_00000060_restart.nc .
281
282    cd ${SETTE_DIR}
283    . ./prepare_job.sh input_EMPTY.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
287    ## Test for all advection, vector form, flux form: test runability and complete all time steps
288    ## Needed namelist-xxxx for every type of run tested
289    cd ${CONFIG_DIR}/${NEW_CONF}/EXP00
290
291    for file in $(echo `ls namelist_*_cfg `) ; do
292        TEST_NAME=`ls $file | sed -e "s/namelist_//" | sed -e "s/_cfg//"`
293        TEST_NAME="EXP-${TEST_NAME}"
294        `mkdir ${CONFIG_DIR}/${NEW_CONF}/${TEST_NAME}`
295        export TEST_NAME="${TEST_NAME}"
296         ## 
297        cd ${SETTE_DIR}
298        . ./param.cfg
299        . ./all_functions.sh
300        . ./prepare_exe_dir.sh
301        JOB_FILE=${EXE_DIR}/run_job.sh
302        NPROC=1
303        if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
304        cd ${EXE_DIR}
305        if [ ${USING_MPMD} == "yes" ] ; then
306           set_xio_using_server iodef.xml true
307        else
308           set_xio_using_server iodef.xml false
309        fi
310        cd ${SETTE_DIR}
311        . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
312        cd ${SETTE_DIR}
313        . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
314       ##
315   done
316fi
317
318# ---------
319# VORTEX
320# ---------
321if [ ${config} -eq 3 ] ;  then 
322## Restartability tests for VORTEX
323    export TEST_NAME="LONG"
324    cd ${MAIN_DIR}
325    . ./makenemo -m ${CMP_NAM} -n VORTEX_ST -a VORTEX -j 8  del_key ${DEL_KEYS}
326    cd ${SETTE_DIR}
327    . ./param.cfg
328    . ./all_functions.sh
329    . ./prepare_exe_dir.sh
330    JOB_FILE=${EXE_DIR}/run_job.sh
331    NPROC=6
332    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
333    cd ${EXE_DIR}
334    set_namelist namelist_cfg cn_exp \"VORTEX_LONG\"
335    set_namelist namelist_cfg nn_it000 1
336    set_namelist namelist_cfg nn_itend 240
337    set_namelist namelist_cfg nn_stock 120
338   
339    set_namelist 1_namelist_cfg cn_exp \"VORTEX_LONG\"
340    set_namelist 1_namelist_cfg nn_it000 1
341    set_namelist 1_namelist_cfg nn_itend 720
342    set_namelist 1_namelist_cfg nn_stock 360
343   
344    if [ ${USING_MPMD} == "yes" ] ; then
345        set_xio_using_server iodef.xml true
346    else
347        set_xio_using_server iodef.xml false
348    fi
349    cd ${SETTE_DIR}
350    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
351   
352    cd ${SETTE_DIR}
353    export TEST_NAME="SHORT"
354    . ./prepare_exe_dir.sh
355    cd ${EXE_DIR}
356    set_namelist namelist_cfg cn_exp \"VORTEX_SHORT\"
357    set_namelist namelist_cfg nn_it000 121
358    set_namelist namelist_cfg nn_itend 240
359    set_namelist namelist_cfg nn_stock 120
360    set_namelist namelist_cfg ln_rstart .true.
361    set_namelist namelist_cfg nn_rstctl 2
362    set_namelist namelist_cfg cn_ocerst_in \"VORTEX_LONG_00000120_restart\"
363   
364    set_namelist 1_namelist_cfg cn_exp \"VORTEX_SHORT\"
365    set_namelist 1_namelist_cfg nn_it000 361
366    set_namelist 1_namelist_cfg nn_itend 720
367    set_namelist 1_namelist_cfg nn_stock 360
368    set_namelist 1_namelist_cfg ln_rstart .true.
369    set_namelist 1_namelist_cfg nn_rstctl 2
370    set_namelist 1_namelist_cfg cn_ocerst_in \"VORTEX_LONG_00000360_restart\"
371     
372    if [ ${USING_MPMD} == "yes" ] ; then
373        set_xio_using_server iodef.xml true
374    else
375        set_xio_using_server iodef.xml false
376    fi
377    if [ $NPROC -eq 1 ] ;  then
378        ln -sf ../LONG/VORTEX_LONG_00000120_restart.nc .
379        ln -sf ../LONG/1_VORTEX_LONG_00000360_restart.nc .
380    else
381        for (( i=1; i<=$NPROC; i++)) ; do
382            L_NPROC=$(( $i - 1 ))
383            L_NPROC=`printf "%04d\n" ${L_NPROC}`
384            ln -sf ../LONG/VORTEX_LONG_00000120_restart_${L_NPROC}.nc .
385            ln -sf ../LONG/1_VORTEX_LONG_00000360_restart_${L_NPROC}.nc .
386        done
387    fi
388    cd ${SETTE_DIR}
389    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
390    cd ${SETTE_DIR}
391    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
392
393## Reproducibility tests for VORTEX
394    export TEST_NAME="REPRO_2_3"
395    cd ${MAIN_DIR}
396    cd ${SETTE_DIR}
397    . ./param.cfg
398    . ./all_functions.sh
399    . ./prepare_exe_dir.sh
400    JOB_FILE=${EXE_DIR}/run_job.sh
401    NPROC=6
402    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
403    cd ${EXE_DIR}
404    set_namelist namelist_cfg cn_exp \"VORTEX_23\"
405    set_namelist namelist_cfg nn_it000 1
406    set_namelist namelist_cfg nn_itend 240
407    set_namelist namelist_cfg nn_stock 120
408    set_namelist namelist_cfg jpni 2
409    set_namelist namelist_cfg jpnj 3
410    set_namelist namelist_cfg jpnij 6
411   
412    set_namelist 1_namelist_cfg cn_exp \"VORTEX_23\"
413    set_namelist 1_namelist_cfg nn_it000 1
414    set_namelist 1_namelist_cfg nn_itend 720
415    set_namelist 1_namelist_cfg nn_stock 360
416    set_namelist 1_namelist_cfg jpni 2
417    set_namelist 1_namelist_cfg jpnj 3
418    set_namelist 1_namelist_cfg jpnij 6
419
420    if [ ${USING_MPMD} == "yes" ] ; then
421       set_xio_using_server iodef.xml true
422    else
423       set_xio_using_server iodef.xml false
424    fi
425    cd ${SETTE_DIR}
426    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
427    cd ${SETTE_DIR}
428    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
429
430    cd ${SETTE_DIR}
431    export TEST_NAME="REPRO_3_2"
432    . ./prepare_exe_dir.sh
433    JOB_FILE=${EXE_DIR}/run_job.sh
434    NPROC=6
435    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
436    cd ${EXE_DIR}
437
438    set_namelist namelist_cfg cn_exp \"VORTEX_32\"
439    set_namelist namelist_cfg nn_it000 1
440    set_namelist namelist_cfg nn_itend 240
441    set_namelist namelist_cfg nn_stock 120
442    set_namelist namelist_cfg jpni 3
443    set_namelist namelist_cfg jpnj 2
444    set_namelist namelist_cfg jpnij 6
445   
446    set_namelist 1_namelist_cfg cn_exp \"VORTEX_32\"
447    set_namelist 1_namelist_cfg nn_it000 1
448    set_namelist 1_namelist_cfg nn_itend 720
449    set_namelist 1_namelist_cfg nn_stock 360
450    set_namelist 1_namelist_cfg jpni 3
451    set_namelist 1_namelist_cfg jpnj 2
452    set_namelist 1_namelist_cfg jpnij 6
453   
454    if [ ${USING_MPMD} == "yes" ] ; then
455       set_xio_using_server iodef.xml true
456    else
457       set_xio_using_server iodef.xml false
458    fi
459    cd ${SETTE_DIR}
460    . ./prepare_job.sh input_EMPTY.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
461    cd ${SETTE_DIR}
462    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
463
464fi
465
466
467# ---------
468# ICEDYN
469# ---------
470if [ ${config} -eq 4 ] ;  then 
471## Restartability tests for ICEDYN
472    export TEST_NAME="LONG"
473    cd ${MAIN_DIR}
474    . ./makenemo -m ${CMP_NAM} -n ICEDYN_ST -a ICEDYN -j 8  del_key ${DEL_KEYS}
475    cd ${SETTE_DIR}
476    . ./param.cfg
477    . ./all_functions.sh
478    . ./prepare_exe_dir.sh
479    JOB_FILE=${EXE_DIR}/run_job.sh
480    NPROC=6
481    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
482    cd ${EXE_DIR}
483    set_namelist namelist_cfg cn_exp \"ICEDYN_LONG\"
484    set_namelist namelist_cfg nn_it000 1
485    set_namelist namelist_cfg nn_itend 200
486    set_namelist namelist_cfg nn_stock 100
487   
488    #set_namelist namelist_ice_cfg ln_icethd .true.
489    set_namelist namelist_ice_cfg ln_icedyn .true.
490    set_namelist namelist_ice_cfg ln_dynFULL .true.
491    set_namelist namelist_ice_cfg ln_dynRHGADV .false.
492    set_namelist namelist_ice_cfg ln_dynADV .false.
493   
494    set_namelist 1_namelist_cfg cn_exp \"ICEDYN_LONG\"
495    set_namelist 1_namelist_cfg nn_it000 1
496    set_namelist 1_namelist_cfg nn_itend 600
497    set_namelist 1_namelist_cfg nn_stock 300
498   
499    #set_namelist 1_namelist_ice_cfg ln_icethd .true.
500    set_namelist 1_namelist_ice_cfg ln_icedyn .true.
501    set_namelist 1_namelist_ice_cfg ln_dynFULL .true.
502    set_namelist 1_namelist_ice_cfg ln_dynRHGADV .false.
503    set_namelist 1_namelist_ice_cfg ln_dynADV .false.
504    if [ ${USING_MPMD} == "yes" ] ; then
505        set_xio_using_server iodef.xml true
506    else
507        set_xio_using_server iodef.xml false
508    fi
509    cd ${SETTE_DIR}
510    . ./prepare_job.sh input_ICEDYN.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
511   
512    cd ${SETTE_DIR}
513    export TEST_NAME="SHORT"
514    . ./prepare_exe_dir.sh
515    cd ${EXE_DIR}
516    set_namelist namelist_cfg cn_exp \"ICEDYN_SHORT\"
517    set_namelist namelist_cfg nn_it000 101
518    set_namelist namelist_cfg nn_itend 200
519    set_namelist namelist_cfg nn_stock 100
520    set_namelist namelist_cfg ln_rstart .true.
521    set_namelist namelist_cfg nn_rstctl 2
522   
523    #set_namelist namelist_ice_cfg ln_icethd .true.
524    set_namelist namelist_ice_cfg ln_icedyn .true.
525    set_namelist namelist_ice_cfg ln_dynFULL .true.
526    set_namelist namelist_ice_cfg ln_dynRHGADV .false.
527    set_namelist namelist_ice_cfg ln_dynADV .false.
528    set_namelist namelist_cfg cn_ocerst_in \"ICEDYN_LONG_00000100_restart\"
529    set_namelist namelist_ice_cfg cn_icerst_in \"ICEDYN_LONG_00000100_restart_ice\"
530   
531    set_namelist 1_namelist_cfg cn_exp \"ICEDYN_SHORT\"
532    set_namelist 1_namelist_cfg nn_it000 301
533    set_namelist 1_namelist_cfg nn_itend 600
534    set_namelist 1_namelist_cfg nn_stock 300
535    set_namelist 1_namelist_cfg ln_rstart .true.
536    set_namelist 1_namelist_cfg nn_rstctl 2
537   
538    #set_namelist 1_namelist_ice_cfg ln_icethd .true.
539    set_namelist 1_namelist_ice_cfg ln_icedyn .true.
540    set_namelist 1_namelist_ice_cfg ln_dynFULL .true.
541    set_namelist 1_namelist_ice_cfg ln_dynRHGADV .false.
542    set_namelist 1_namelist_ice_cfg ln_dynADV .false.
543    set_namelist 1_namelist_cfg cn_ocerst_in \"ICEDYN_LONG_00000300_restart\"
544    set_namelist 1_namelist_ice_cfg cn_icerst_in \"ICEDYN_LONG_00000300_restart_ice\"
545   
546   
547    if [ ${USING_MPMD} == "yes" ] ; then
548        set_xio_using_server iodef.xml true
549    else
550        set_xio_using_server iodef.xml false
551    fi
552    if [ $NPROC -eq 1 ] ;  then
553        ln -sf ../LONG/ICEDYN_LONG_00000100_restart.nc .
554        ln -sf ../LONG/ICEDYN_LONG_00000100_restart_ice.nc .
555        ln -sf ../LONG/1_ICEDYN_LONG_00000300_restart.nc .
556        ln -sf ../LONG/1_ICEDYN_LONG_00000300_restart_ice.nc .
557    else
558        for (( i=1; i<=$NPROC; i++)) ; do
559            L_NPROC=$(( $i - 1 ))
560            L_NPROC=`printf "%04d\n" ${L_NPROC}`
561            ln -sf ../LONG/ICEDYN_LONG_00000100_restart_${L_NPROC}.nc .
562            ln -sf ../LONG/ICEDYN_LONG_00000100_restart_ice_${L_NPROC}.nc .
563            ln -sf ../LONG/1_ICEDYN_LONG_00000300_restart_${L_NPROC}.nc .
564            ln -sf ../LONG/1_ICEDYN_LONG_00000300_restart_ice_${L_NPROC}.nc .
565        done
566    fi
567
568    cd ${SETTE_DIR}
569    . ./prepare_job.sh input_ICEDYN.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
570    cd ${SETTE_DIR}
571    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
572
573
574## Reproducibility tests for ICEDYN
575    export TEST_NAME="REPRO_2_3"
576    cd ${MAIN_DIR}
577    cd ${SETTE_DIR}
578    . ./param.cfg
579    . ./all_functions.sh
580    . ./prepare_exe_dir.sh
581    JOB_FILE=${EXE_DIR}/run_job.sh
582    NPROC=6
583    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
584    cd ${EXE_DIR}
585    set_namelist namelist_cfg cn_exp \"ICEDYN_23\"
586    set_namelist namelist_cfg nn_it000 1
587    set_namelist namelist_cfg nn_itend 200
588    set_namelist namelist_cfg nn_stock 100
589    set_namelist namelist_cfg jpni 2
590    set_namelist namelist_cfg jpnj 3
591    set_namelist namelist_cfg jpnij 6
592
593    #set_namelist namelist_ice_cfg ln_icethd .true.
594    set_namelist namelist_ice_cfg ln_icedyn .true.
595    set_namelist namelist_ice_cfg ln_dynFULL .true.
596    set_namelist namelist_ice_cfg ln_dynRHGADV .false.
597    set_namelist namelist_ice_cfg ln_dynADV .false.
598   
599    set_namelist 1_namelist_cfg cn_exp \"ICEDYN_23\"
600    set_namelist 1_namelist_cfg nn_it000 1
601    set_namelist 1_namelist_cfg nn_itend 600
602    set_namelist 1_namelist_cfg nn_stock 300
603    set_namelist 1_namelist_cfg jpni 2
604    set_namelist 1_namelist_cfg jpnj 3
605    set_namelist 1_namelist_cfg jpnij 6
606
607    #set_namelist 1_namelist_ice_cfg ln_icethd .true.
608    set_namelist 1_namelist_ice_cfg ln_icedyn .true.
609    set_namelist 1_namelist_ice_cfg ln_dynFULL .true.
610    set_namelist 1_namelist_ice_cfg ln_dynRHGADV .false.
611    set_namelist 1_namelist_ice_cfg ln_dynADV .false.
612
613    if [ ${USING_MPMD} == "yes" ] ; then
614       set_xio_using_server iodef.xml true
615    else
616       set_xio_using_server iodef.xml false
617    fi
618    cd ${SETTE_DIR}
619    . ./prepare_job.sh input_ICEDYN.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
620    cd ${SETTE_DIR}
621    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
622
623    cd ${SETTE_DIR}
624    export TEST_NAME="REPRO_3_2"
625    . ./prepare_exe_dir.sh
626    JOB_FILE=${EXE_DIR}/run_job.sh
627    NPROC=6
628    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
629    cd ${EXE_DIR}
630
631    set_namelist namelist_cfg cn_exp \"ICEDYN_32\"
632    set_namelist namelist_cfg nn_it000 1
633    set_namelist namelist_cfg nn_itend 200
634    set_namelist namelist_cfg nn_stock 100
635    set_namelist namelist_cfg jpni 3
636    set_namelist namelist_cfg jpnj 2
637    set_namelist namelist_cfg jpnij 6
638
639    #set_namelist namelist_ice_cfg ln_icethd .true.
640    set_namelist namelist_ice_cfg ln_icedyn .true.
641    set_namelist namelist_ice_cfg ln_dynFULL .true.
642    set_namelist namelist_ice_cfg ln_dynRHGADV .false.
643    set_namelist namelist_ice_cfg ln_dynADV .false.
644   
645    set_namelist 1_namelist_cfg cn_exp \"ICEDYN_32\"
646    set_namelist 1_namelist_cfg nn_it000 1
647    set_namelist 1_namelist_cfg nn_itend 600
648    set_namelist 1_namelist_cfg nn_stock 300
649    set_namelist 1_namelist_cfg jpni 3
650    set_namelist 1_namelist_cfg jpnj 2
651    set_namelist 1_namelist_cfg jpnij 6
652
653    #set_namelist 1_namelist_ice_cfg ln_icethd .true.
654    set_namelist 1_namelist_ice_cfg ln_icedyn .true.
655    set_namelist 1_namelist_ice_cfg ln_dynFULL .true.
656    set_namelist 1_namelist_ice_cfg ln_dynRHGADV .false.
657    set_namelist 1_namelist_ice_cfg ln_dynADV .false.
658   
659    if [ ${USING_MPMD} == "yes" ] ; then
660       set_xio_using_server iodef.xml true
661    else
662       set_xio_using_server iodef.xml false
663    fi
664    cd ${SETTE_DIR}
665    . ./prepare_job.sh input_ICEDYN.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
666    cd ${SETTE_DIR}
667    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
668
669fi
670
671# ------
672# ISOMIP
673# ------
674if [ ${config} -eq 5 ] ;  then
675## Restartability tests
676    export TEST_NAME="LONG"
677    cd ${MAIN_DIR}
678    . ./makenemo -m ${CMP_NAM} -n ISOMIP_ST -a ISOMIP -j 8 del_key ${DEL_KEYS}
679    cd ${SETTE_DIR}
680    . ./param.cfg
681    . ./all_functions.sh
682    . ./prepare_exe_dir.sh
683    JOB_FILE=${EXE_DIR}/run_job.sh
684    NPROC=15
685    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
686    cd ${EXE_DIR}
687    set_namelist namelist_cfg cn_exp \"ISOMIP_LONG\"
688    set_namelist namelist_cfg nn_it000 1
689    set_namelist namelist_cfg nn_itend 96
690    set_namelist namelist_cfg nn_stock 48
691    set_namelist namelist_cfg jpni 5
692    set_namelist namelist_cfg jpnj 3
693    set_namelist namelist_cfg jpnij 15
694    if [ ${USING_MPMD} == "yes" ] ; then
695       set_xio_using_server iodef.xml true
696    else
697       set_xio_using_server iodef.xml false
698    fi
699    cd ${SETTE_DIR}
700    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
701
702    cd ${SETTE_DIR}
703    export TEST_NAME="SHORT"
704    . ./prepare_exe_dir.sh
705    cd ${EXE_DIR}
706    set_namelist namelist_cfg cn_exp \"ISOMIP_SHORT\"
707    set_namelist namelist_cfg nn_it000 49
708    set_namelist namelist_cfg nn_itend 96
709    set_namelist namelist_cfg nn_stock 48
710    set_namelist namelist_cfg ln_rstart .true.
711    set_namelist namelist_cfg nn_rstctl 2
712    set_namelist namelist_cfg jpni 5
713    set_namelist namelist_cfg jpnj 3
714    set_namelist namelist_cfg jpnij 15
715    set_namelist namelist_cfg cn_ocerst_in \"ISOMIP_LONG_00000048_restart\"
716    if [ ${USING_MPMD} == "yes" ] ; then
717       set_xio_using_server iodef.xml true
718    else
719       set_xio_using_server iodef.xml false
720    fi
721    for (( i=1; i<=$NPROC; i++)) ; do
722        L_NPROC=$(( $i - 1 ))
723        L_NPROC=`printf "%04d\n" ${L_NPROC}`
724        ln -sf ../LONG/ISOMIP_LONG_00000048_restart_${L_NPROC}.nc .
725    done
726
727    cd ${SETTE_DIR}
728    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
729    cd ${SETTE_DIR}
730    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
731
732## Reproducibility tests
733    export TEST_NAME="REPRO_7_3"
734    cd ${MAIN_DIR}
735    cd ${SETTE_DIR}
736    . ./param.cfg
737    . ./all_functions.sh
738    . ./prepare_exe_dir.sh
739    JOB_FILE=${EXE_DIR}/run_job.sh
740    NPROC=21
741    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
742    cd ${EXE_DIR}
743    set_namelist namelist_cfg cn_exp \"ISOMIP_73\"
744    set_namelist namelist_cfg nn_it000 1
745    set_namelist namelist_cfg nn_itend 48
746    set_namelist namelist_cfg jpni 7
747    set_namelist namelist_cfg jpnj 3
748    set_namelist namelist_cfg jpnij 21
749    if [ ${USING_MPMD} == "yes" ] ; then
750       set_xio_using_server iodef.xml true
751    else
752       set_xio_using_server iodef.xml false
753    fi
754    cd ${SETTE_DIR}
755    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
756    cd ${SETTE_DIR}
757    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
758
759    cd ${SETTE_DIR}
760    export TEST_NAME="REPRO_8_4"
761    . ./prepare_exe_dir.sh
762    JOB_FILE=${EXE_DIR}/run_job.sh
763    NPROC=32
764    if [ -f ${JOB_FILE} ] ; then \rm ${JOB_FILE} ; fi
765    cd ${EXE_DIR}
766    set_namelist namelist_cfg cn_exp \"ISOMIP_84\"
767    set_namelist namelist_cfg nn_it000 1
768    set_namelist namelist_cfg nn_itend 48
769    set_namelist namelist_cfg jpni 8
770    set_namelist namelist_cfg jpnj 4
771    set_namelist namelist_cfg jpnij 32
772    if [ ${USING_MPMD} == "yes" ] ; then
773       set_xio_using_server iodef.xml true
774    else
775       set_xio_using_server iodef.xml false
776    fi
777    cd ${SETTE_DIR}
778    . ./prepare_job.sh input_ISOMIP.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE} ${NUM_XIOSERVERS}
779    cd ${SETTE_DIR}
780    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
781
782fi
783
784#----
785done
Note: See TracBrowser for help on using the repository browser.