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

Last change on this file since 3532 was 3532, checked in by flavoni, 8 years ago

Sette now is working, and all routines are coherents, see ticket: #941

  • Property svn:executable set to *
File size: 22.8 KB
Line 
1#!/bin/bash
2#############################################################
3# Author : Simona Flavoni for NEMO
4# Contact : sflod@locean-ipsl.upmc.fr
5#
6# sette.sh   : principal script of SET TEsts for NEMO (SETTE)
7# ----------------------------------------------------------------------
8# NEMO/SETTE , NEMO Consortium (2010)
9# Software governed by the CeCILL licence     (NEMOGCM/NEMO_CeCILL.txt)
10# ----------------------------------------------------------------------
11#
12#############################################################
13#set -x
14set -o posix
15#set -u
16#set -e
17#+
18#
19# ================
20# sette.sh
21# ================
22#
23# ----------------------------------------------
24# Set of tests for NEMO
25# ----------------------------------------------
26#
27# SYNOPSIS
28# ========
29#
30# ::
31#
32#  $ ./sette.sh
33#
34# DESCRIPTION
35# ===========
36#
37# Variables to be checked by user:
38#
39# COMPILER : name of compiler as defined in NEMOGCM/ARCH directory
40#
41# BATCH_COMMAND :  name of the command for batch submission
42#
43# MPI_INTERACT : 
44#
45#         for MPP tests, "no" for batch execution, "yes" for interactive execution
46#
47#         NOTE: for run with 1 process tests are run always in MPI_INTERACT="yes"
48#
49# Principal script is sette.sh, that calls
50#
51#  makenemo
52#
53#   creates the exectuable in ${CONFIG_NAME}/BLD/bin/nemo.exe  (and its link opa in ${CONFIG_NAME}/EXP00)
54#
55#  param.cfg : sets and loads following directories:
56#
57#   FORCING_DIR : is the directory for forcing files (tarfile)
58#
59#   INPUT_DIR : is the directory for input files storing
60#
61#   TMPDIR : is the temporary directory (if needed)
62#
63#   NEMO_VALIDATION_DIR : is the validation directory
64#
65#   (NOTE: this file is the same for all configrations to be tested with sette)
66#
67#
68#  all_functions.sh : loads functions used by sette (note: new functions can be added here)
69#
70#   set_namelist : function declared in all_functions that set namelist parameters for tests
71#
72#   post_test_tidyup : creates validation storage directory and copy needed output files (solver.stat and ocean.output) in it after execution of test.
73#
74#   Tree of VALIDATION is:
75#
76#   NEMO_VALIDATION_DIR/WCONFIG_NAME/WCOMPILER_NAME/TEST_NAME/REVISION_NUMBER(or DATE)
77#
78#
79#  prepare_exe_dir.sh : defines and creates directory where the test is executed
80#
81#       execution directory takes name of TEST_NAME defined in every test in sette.sh
82#
83#       ( each test in executed in its own directory )
84#
85#
86#  fcm_job.sh
87#
88#   runs job in interactive or batch mode : all jobs using 1 process are run interactive, and all MPP jobs are
89#
90#   run in batch (MPI_INTERACT="no") or interactive (MPI_INTERACT="yes") see sette.sh and BATCH_TEMPLATE directory
91#
92#   (note this job needs to have an input_CONFIG.cfg in which can be found input tar file)
93#
94#  NOTE: if job is not launched for some problems you have executable ready in ${EXE_DIR} directory
95#
96#  NOTE: the changed namelists are leaved in ${EXE_DIR} directory whereas original namelist remains in ${NEW_CONF}/EXP00
97#
98#  in ${SETTE_DIR} is created output.sette with the echo of executed commands
99#
100#  if sette.sh is stopped in output.sette there is written the last command executed by sette.sh
101#
102#  if you run: ./sette.sh 2>&1 | tee out.sette
103#
104#  in ${SETTE_DIR} out.sette is redirected standard error & standard output
105#
106#
107# EXAMPLES
108# ========
109#
110# ::
111#
112#  $ ./sette.sh
113#
114#
115# TODO
116# ====
117#
118# option debug
119#
120# EVOLUTIONS
121# ==========
122#
123# $Id: sette.sh 2890 2011-10-06 11:03:48Z flavoni $
124#
125#   * creation
126#
127#-
128#
129#-
130# Compiler among those in NEMOGCM/ARCH
131COMPILER=PW6_VARGAS
132export BATCH_COMMAND_PAR="llsubmit"
133export BATCH_COMMAND_SEQ=$BATCH_COMMAND_PAR
134export INTERACT_FLAG="no"
135export MPIRUN_FLAG="yes"
136
137# Directory to run the tests
138SETTE_DIR=$(cd $(dirname "$0"); pwd)
139MAIN_DIR=${SETTE_DIR%/SETTE}
140CONFIG_DIR=${MAIN_DIR}/CONFIG
141TOOLS_DIR=${MAIN_DIR}/TOOLS
142COMPIL_DIR=${TOOLS_DIR}/COMPILE
143
144CMP_NAM=${1:-$COMPILER}
145# Copy job_batch_COMPILER file for specific compiler into job_batch_template
146cd ${SETTE_DIR}
147cp BATCH_TEMPLATE/batch-${COMPILER} job_batch_template || exit
148
149for config in 1 2 3 4 5 6 7 8 9
150do
151
152# TESTS FOR GYRE_LOBSTER CONFIGURATION
153if [ ${config} -eq 1 ] ;  then
154    ## Restartability tests for GYRE_LOBSTER
155    export TEST_NAME="LONG"
156    cd ${SETTE_DIR}
157    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRELOB_LONG -r GYRE_LOBSTER add_key "key_mpp_mpi"
158    cd ${SETTE_DIR}
159    . param.cfg
160    . all_functions.sh
161    . prepare_exe_dir.sh
162    JOB_FILE=${EXE_DIR}/run_job.sh
163    NPROC=4
164    \rm ${JOB_FILE}
165    cd ${EXE_DIR}
166    set_namelist namelist cn_exp \"GYRELOB_LONG\"
167    set_namelist namelist nn_it000 1
168    set_namelist namelist nn_itend 120
169    set_namelist namelist nn_stock 60
170    set_namelist namelist ln_clobber .true.
171    set_namelist namelist nn_solv 2
172    set_namelist namelist_top ln_diatrc .false.
173    set_namelist namelist jpni 2
174    set_namelist namelist jpnj 2
175    set_namelist namelist jpnij 4
176    cd ${SETTE_DIR}
177    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
178    cd ${SETTE_DIR}
179    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
180
181    cd ${SETTE_DIR}
182    export TEST_NAME="SHORT"
183    . prepare_exe_dir.sh
184    cd ${EXE_DIR}
185    set_namelist namelist cn_exp \"GYRELOB_SHORT\"
186    set_namelist namelist nn_it000 61
187    set_namelist namelist nn_itend 120
188    set_namelist namelist nn_stock 60
189    set_namelist namelist ln_rstart .true.
190    set_namelist namelist nn_rstctl 2
191    set_namelist namelist ln_clobber .true.
192    set_namelist namelist nn_solv 2
193    set_namelist namelist jpni 2
194    set_namelist namelist jpnj 2
195    set_namelist namelist jpnij 4
196    cp ..\/LONG\/GYRELOB_LONG_00000060_restart*.nc .
197    set_namelist namelist cn_ocerst_in \"GYRELOB_LONG_00000060_restart\"
198    set_namelist namelist_top ln_diatrc .false.
199    set_namelist namelist_top ln_rsttr .true.
200    set_namelist namelist_top nn_rsttr 2
201    set_namelist namelist_top cn_trcrst_in \"GYRELOB_LONG_00000060_restart_trc\"
202    cd ${SETTE_DIR}
203    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
204    cd ${SETTE_DIR}
205    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
206fi
207
208if [ ${config} -eq 2 ] ;  then
209    ## Repropducibility tests for GYRE_LOBSTER
210    export TEST_NAME="REPRO_1_4"
211    cd ${SETTE_DIR}
212    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRELOB_4 -r GYRE_LOBSTER add_key "key_mpp_mpi key_mpp_rep"
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=4
219    \rm ${JOB_FILE}
220    cd ${EXE_DIR}
221    set_namelist namelist cn_exp \"GYRELOB_14\"
222    set_namelist namelist nn_it000 1
223    set_namelist namelist nn_itend 60
224    set_namelist namelist nn_fwb 0
225    set_namelist namelist nn_bench 0
226    set_namelist namelist ln_ctl .false.
227    set_namelist namelist ln_clobber .true.
228    set_namelist namelist nn_solv 2
229    set_namelist namelist_top ln_diatrc .false.
230    set_namelist namelist_top ln_trcdta .false.
231    set_namelist namelist jpni 1
232    set_namelist namelist jpnj 4
233    set_namelist namelist jpnij 4
234    cd ${SETTE_DIR}
235    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
236    cd ${SETTE_DIR}
237    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
238
239    cd ${SETTE_DIR}
240    export TEST_NAME="REPRO_2_2"
241    . prepare_exe_dir.sh
242    cd ${EXE_DIR}
243    set_namelist namelist cn_exp \"GYRELOB_22\"
244    set_namelist namelist nn_it000 1
245    set_namelist namelist nn_itend 60
246    set_namelist namelist nn_fwb 0
247    set_namelist namelist ln_ctl .false.
248    set_namelist namelist ln_clobber .true.
249    set_namelist namelist nn_solv 2
250    set_namelist namelist_top ln_diatrc .false.
251    set_namelist namelist_top ln_trcdta .false.
252    set_namelist namelist jpni 2
253    set_namelist namelist jpnj 2
254    set_namelist namelist jpnij 4
255    cd ${SETTE_DIR}
256    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
257    cd ${SETTE_DIR}
258    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
259
260fi
261
262# TESTS FOR ORCA2_LIM_PISCES CONFIGURATION
263if [ ${config} -eq 3 ] ;  then
264    ## Restartability tests for ORCA2_LIM_PISCES
265    export TEST_NAME="LONG"
266    cd ${SETTE_DIR}
267    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_LONG -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_mpi" 
268    cd ${SETTE_DIR}
269    . param.cfg
270    . all_functions.sh
271    . prepare_exe_dir.sh
272    JOB_FILE=${EXE_DIR}/run_job.sh
273    NPROC=4
274    \rm ${JOB_FILE}
275    cd ${EXE_DIR}
276    set_namelist namelist cn_exp \"O2LP_LONG\"
277    set_namelist namelist nn_it000 1
278    set_namelist namelist nn_itend 150
279    set_namelist namelist nn_stock 75
280    set_namelist namelist ln_clobber .true.
281    set_namelist namelist jpni 2
282    set_namelist namelist jpnj 2
283    set_namelist namelist jpnij 4
284    set_namelist namelist nn_solv 2
285    set_namelist namelist_top ln_trcdta .false.
286    set_namelist namelist_top ln_diatrc .false.
287    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
288    # if not you need input files, and for tests is not necessary
289    set_namelist namelist_pisces ln_ironsed .false.
290    set_namelist namelist_pisces ln_river .false.
291    set_namelist namelist_pisces ln_ndepo .false.
292    set_namelist namelist_pisces ln_dust .false.
293    set_namelist namelist_pisces ln_presatm .false.
294    cd ${SETTE_DIR}
295    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
296    cd ${SETTE_DIR}
297    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
298   
299    cd ${SETTE_DIR}
300    export TEST_NAME="SHORT"
301    . prepare_exe_dir.sh
302    cd ${EXE_DIR}
303    set_namelist namelist cn_exp \"O2LP_SHORT\"
304    set_namelist namelist nn_it000 76
305    set_namelist namelist nn_itend 150
306    set_namelist namelist nn_stock 75
307    set_namelist namelist ln_rstart .true.
308    set_namelist namelist nn_rstctl 2
309    set_namelist namelist ln_clobber .true.
310    set_namelist namelist jpni 2
311    set_namelist namelist jpnj 2
312    set_namelist namelist jpnij 4
313    set_namelist namelist nn_solv 2
314    cp ../LONG/O2LP_LONG_00000075_restart*nc .
315    set_namelist namelist cn_ocerst_in \"O2LP_LONG_00000075_restart\"
316    set_namelist namelist_ice cn_icerst_in \"O2LP_LONG_00000075_restart_ice\"
317    set_namelist namelist_top ln_diatrc .false.
318    set_namelist namelist_top ln_rsttr .true.
319    set_namelist namelist_top nn_rsttr 2
320    set_namelist namelist_top cn_trcrst_in \"O2LP_LONG_00000075_restart_trc\"
321    # put ln_ironsed, ln_river, ln_ndepo, ln_dust
322    # if not you need input files, and for tests is not necessary
323    set_namelist namelist_pisces ln_ironsed .false.
324    set_namelist namelist_pisces ln_river .false.
325    set_namelist namelist_pisces ln_ndepo .false.
326    set_namelist namelist_pisces ln_dust .false.
327    set_namelist namelist_pisces ln_presatm .false.
328    cd ${SETTE_DIR}
329    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
330    cd ${SETTE_DIR}
331    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
332fi
333
334if [ ${config} -eq 4 ] ;  then
335    ## Repropducibility tests for ORCA2_LIM_PISCES
336    export TEST_NAME="REPRO_4_4"
337    cd ${SETTE_DIR}
338    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_16 -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_rep key_mpp_mpi"
339    cd ${SETTE_DIR}
340    . param.cfg
341    . all_functions.sh
342    . prepare_exe_dir.sh
343    JOB_FILE=${EXE_DIR}/run_job.sh
344    NPROC=16
345    \rm $JOB_FILE
346    cd ${EXE_DIR}
347    set_namelist namelist nn_it000 1
348    set_namelist namelist nn_itend 75
349    set_namelist namelist nn_fwb 0
350    set_namelist namelist ln_ctl .false.
351    set_namelist namelist ln_clobber .true.
352    set_namelist namelist jpni 4
353    set_namelist namelist jpnj 4
354    set_namelist namelist jpnij 16
355    set_namelist namelist nn_solv 2
356    set_namelist namelist_top ln_trcdta .false.
357    set_namelist namelist_top ln_diatrc .false.
358    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
359    # if not you need input files, and for tests is not necessary
360    set_namelist namelist_pisces ln_ironsed .false.
361    set_namelist namelist_pisces ln_river .false.
362    set_namelist namelist_pisces ln_ndepo .false.
363    set_namelist namelist_pisces ln_dust .false.
364    set_namelist namelist_pisces ln_presatm .false.
365    cd ${SETTE_DIR}
366    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
367    cd ${SETTE_DIR}
368    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
369
370    cd ${SETTE_DIR}
371    export TEST_NAME="REPRO_2_8"
372    . prepare_exe_dir.sh
373    cd ${EXE_DIR}
374    set_namelist namelist nn_it000 1
375    set_namelist namelist nn_itend 75
376    set_namelist namelist nn_fwb 0
377    set_namelist namelist ln_ctl .false.
378    set_namelist namelist ln_clobber .true.
379    set_namelist namelist jpni 2
380    set_namelist namelist jpnj 8
381    set_namelist namelist jpnij 16
382    set_namelist namelist nn_solv 2
383    set_namelist namelist_top ln_trcdta .false.
384    set_namelist namelist_top ln_diatrc .false.
385    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
386    # if not you need input files, and for tests is not necessary
387    set_namelist namelist_pisces ln_ironsed .false.
388    set_namelist namelist_pisces ln_river .false.
389    set_namelist namelist_pisces ln_ndepo .false.
390    set_namelist namelist_pisces ln_dust .false.
391    set_namelist namelist_pisces ln_presatm .false.
392    cd ${SETTE_DIR}
393    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
394    cd ${SETTE_DIR}
395    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
396fi
397
398# TESTS FOR ORCA2_OFF_PISCES CONFIGURATION
399if [ ${config} -eq 5 ] ;  then
400    ## Restartability tests for ORCA2_OFF_PISCES
401    export TEST_NAME="LONG"
402    cd ${SETTE_DIR}
403    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_LONG -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_rep"
404    cd ${SETTE_DIR}
405    . param.cfg
406    . all_functions.sh
407    . prepare_exe_dir.sh
408    JOB_FILE=${EXE_DIR}/run_job.sh
409    NPROC=4
410    \rm $JOB_FILE
411    cd ${EXE_DIR}
412    set_namelist namelist cn_exp \"OFFP_LONG\"
413    set_namelist namelist nn_it000 1
414    set_namelist namelist nn_itend 40
415    set_namelist namelist nn_stock 20
416    set_namelist namelist ln_clobber .true.
417    set_namelist namelist jpni 2
418    set_namelist namelist jpnj 2
419    set_namelist namelist jpnij 4
420    set_namelist namelist_top ln_trcdta .false.
421    set_namelist namelist_top ln_diatrc .false.
422    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
423    # if not you need input files, and for tests is not necessary
424    set_namelist namelist_pisces ln_ironsed .false.
425    set_namelist namelist_pisces ln_river .false.
426    set_namelist namelist_pisces ln_ndepo .false.
427    set_namelist namelist_pisces ln_dust .false.
428    set_namelist namelist_pisces ln_presatm .false.
429    cd ${SETTE_DIR}
430    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
431    cd ${SETTE_DIR}
432    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
433   
434    cd ${SETTE_DIR}
435    export TEST_NAME="SHORT"
436    . prepare_exe_dir.sh
437    JOB_FILE=${EXE_DIR}/run_job.sh
438    NPROC=4
439    \rm $JOB_FILE
440    cd ${EXE_DIR}
441    set_namelist namelist cn_exp \"OFFP_SHORT\"
442    set_namelist namelist nn_it000 21
443    set_namelist namelist nn_itend 40
444    set_namelist namelist nn_stock 20
445    set_namelist namelist ln_clobber .true.
446    set_namelist namelist jpni 2
447    set_namelist namelist jpnj 2
448    set_namelist namelist jpnij 4
449    cp ../LONG/OFFP_LONG_00000020_restart*nc .
450    set_namelist namelist_top ln_diatrc .false.
451    set_namelist namelist_top ln_rsttr .true.
452    set_namelist namelist_top nn_rsttr 2
453    set_namelist namelist_top cn_trcrst_in \"OFFP_LONG_00000020_restart_trc\"
454    # put ln_ironsed, ln_river, ln_ndepo, ln_dust
455    # if not you need input files, and for tests is not necessary
456    set_namelist namelist_pisces ln_ironsed .false.
457    set_namelist namelist_pisces ln_river .false.
458    set_namelist namelist_pisces ln_ndepo .false.
459    set_namelist namelist_pisces ln_dust .false.
460    set_namelist namelist_pisces ln_presatm .false.
461    cd ${SETTE_DIR}
462    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME}  ${MPIRUN_FLAG} ${JOB_FILE}
463    cd ${SETTE_DIR}
464    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
465fi
466
467if [ ${config} -eq 6 ] ;  then
468    ## Repropducibility tests for ORCA2_OFF_PISCES
469    export TEST_NAME="REPRO_4_4"
470    cd ${SETTE_DIR}
471    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_16 -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_rep key_mpp_mpi"
472    cd ${SETTE_DIR}
473    . param.cfg
474    . all_functions.sh
475    . prepare_exe_dir.sh
476    JOB_FILE=${EXE_DIR}/run_job.sh
477    NPROC=16
478    \rm $JOB_FILE
479    cd ${EXE_DIR}
480    set_namelist namelist nn_it000 1
481    set_namelist namelist nn_itend 40
482    set_namelist namelist ln_ctl .false.
483    set_namelist namelist ln_clobber .true.
484    set_namelist namelist jpni 4
485    set_namelist namelist jpnj 4
486    set_namelist namelist jpnij 16
487    set_namelist namelist_top ln_trcdta .false.
488    set_namelist namelist_top ln_diatrc .false.
489    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
490    # if not you need input files, and for tests is not necessary
491    set_namelist namelist_pisces ln_ironsed .false.
492    set_namelist namelist_pisces ln_river .false.
493    set_namelist namelist_pisces ln_ndepo .false.
494    set_namelist namelist_pisces ln_dust .false.
495    set_namelist namelist_pisces ln_presatm .false.
496    cd ${SETTE_DIR}
497    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
498    cd ${SETTE_DIR}
499    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
500
501    cd ${SETTE_DIR}
502    export TEST_NAME="REPRO_2_8"
503    . prepare_exe_dir.sh
504    cd ${EXE_DIR}
505    set_namelist namelist nn_it000 1
506    set_namelist namelist nn_itend 40
507    set_namelist namelist ln_ctl .false.
508    set_namelist namelist ln_clobber .true.
509    set_namelist namelist jpni 2
510    set_namelist namelist jpnj 8
511    set_namelist namelist jpnij 16
512    set_namelist namelist_top ln_trcdta .false.
513    set_namelist namelist_top ln_diatrc .false.
514    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
515    # if not you need input files, and for tests is not necessary
516    set_namelist namelist_pisces ln_ironsed .false.
517    set_namelist namelist_pisces ln_river .false.
518    set_namelist namelist_pisces ln_ndepo .false.
519    set_namelist namelist_pisces ln_dust .false.
520    set_namelist namelist_pisces ln_presatm .false.
521    cd ${SETTE_DIR}
522    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
523    cd ${SETTE_DIR}
524    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
525fi
526
527if [ ${config} -eq 7 ] ;  then
528    ## Restartability tests for AMM12
529    export TEST_NAME="LONG"
530    cd ${SETTE_DIR}
531    . ../CONFIG/makenemo -m ${CMP_NAM} -n AMM12_LONG -r AMM12
532    cd ${SETTE_DIR}
533    . param.cfg
534    . all_functions.sh
535    . prepare_exe_dir.sh
536    JOB_FILE=${EXE_DIR}/run_job.sh
537    NPROC=32
538    \rm $JOB_FILE
539    cd ${EXE_DIR}
540    set_namelist namelist nn_it000 1
541    set_namelist namelist nn_itend 12
542    set_namelist namelist nn_stock 6
543    set_namelist namelist nn_fwb 0
544    set_namelist namelist ln_ctl .false.
545    set_namelist namelist ln_clobber .true.
546    set_namelist namelist nn_dyn2d 2
547    set_namelist namelist nn_tra_dta 0
548    set_namelist namelist jpni 8
549    set_namelist namelist jpnj 4
550    set_namelist namelist jpnij 32
551    cd ${SETTE_DIR}
552    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
553    cd ${SETTE_DIR}
554    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
555
556    cd ${SETTE_DIR}
557    export TEST_NAME="SHORT"
558    . prepare_exe_dir.sh
559    cd ${EXE_DIR}
560    set_namelist namelist nn_it000 7
561    set_namelist namelist nn_itend 12
562    set_namelist namelist nn_fwb 0
563    set_namelist namelist ln_ctl .false.
564    set_namelist namelist ln_clobber .true.
565    set_namelist namelist nn_dyn2d 2
566    set_namelist namelist nn_tra_dta 0
567    set_namelist namelist jpni 8
568    set_namelist namelist jpnj 4
569    set_namelist namelist jpnij 32
570    set_namelist namelist ln_rstart .true.
571    set_namelist namelist nn_rstctl 2
572    set_namelist namelist cn_ocerst_in \"AMM12_00000006_restart\"
573    cp ../LONG/AMM12_00000006_restart*.nc .
574    cd ${SETTE_DIR}
575    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
576    cd ${SETTE_DIR}
577    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
578fi
579
580if [ ${config} -eq 8 ] ;  then
581    ## Reproducibility tests for AMM12
582    export TEST_NAME="REPO_8_4"
583    cd ${SETTE_DIR}
584    . ../CONFIG/makenemo -m ${CMP_NAM} -n AMM12_32 -r AMM12 add_key "key_mpp_rep"
585    cd ${SETTE_DIR}
586    . param.cfg
587    . all_functions.sh
588    . prepare_exe_dir.sh
589    JOB_FILE=${EXE_DIR}/run_job.sh
590    NPROC=32
591    \rm ${JOB_FILE}
592    cd ${EXE_DIR}
593    set_namelist namelist nn_it000 1
594    set_namelist namelist nn_itend 576
595    set_namelist namelist nn_fwb 0
596    set_namelist namelist ln_ctl .false.
597    set_namelist namelist ln_clobber .true.
598    set_namelist namelist nn_dyn2d 2
599    set_namelist namelist nn_tra_dta 0
600    set_namelist namelist jpni 8
601    set_namelist namelist jpnj 4
602    set_namelist namelist jpnij 32
603    cd ${SETTE_DIR}
604    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
605    cd ${SETTE_DIR}
606    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
607
608    cd ${SETTE_DIR}
609    export TEST_NAME="REPO_4_8"
610    . prepare_exe_dir.sh
611    cd ${EXE_DIR}
612    set_namelist namelist nn_it000 1
613    set_namelist namelist nn_itend 576
614    set_namelist namelist nn_fwb 0
615    set_namelist namelist ln_ctl .false.
616    set_namelist namelist nn_dyn2d 2
617    set_namelist namelist nn_tra_dta 0
618    set_namelist namelist ln_clobber .true.
619    set_namelist namelist jpni 4
620    set_namelist namelist jpnj 8
621    set_namelist namelist jpnij 32
622    cd ${SETTE_DIR}
623    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
624    cd ${SETTE_DIR}
625    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
626fi
627
628# TEST FOR ORCA2_LIM_AGRIF : simple test of running AGRIF (no restartability neither reproducibility tests)
629if [ ${config} -eq 9 ] ;  then
630    ## ORCA2_LIM with Agulhas AGRIF zoom in MPI
631    export TEST_NAME="SHORT"
632    cd ${SETTE_DIR}
633    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2AGUL_1_2 -r ORCA2_LIM -j 8 add_key "key_mpp_rep key_mpp_mpi key_agrif" del_key "key_zdftmx"
634    cd ${SETTE_DIR}
635    . param.cfg
636    . all_functions.sh
637    . prepare_exe_dir.sh
638    JOB_FILE=${EXE_DIR}/run_job.sh
639    NPROC=2
640    \rm ${JOB_FILE}
641    cd ${EXE_DIR}
642    set_namelist namelist nn_it000 1
643    set_namelist namelist nn_itend 75
644    set_namelist namelist ln_ctl .false.
645    set_namelist namelist ln_clobber .true.
646    set_namelist namelist jpni 1
647    set_namelist namelist jpnj 2
648    set_namelist namelist jpnij 2
649    set_namelist 1_namelist nn_it000 1
650    set_namelist 1_namelist nn_itend 150
651    set_namelist 1_namelist ln_ctl .false.
652    set_namelist 1_namelist ln_clobber .true.
653    cd ${SETTE_DIR}
654    . ./prepare_job.sh input_ORCA2_LIM_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
655    cd ${SETTE_DIR}
656    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
657fi
658
659done
Note: See TracBrowser for help on using the repository browser.