source: branches/2013/dev_r3858_NOC_ZTC/NEMOGCM/SETTE/sette.sh @ 4254

Last change on this file since 4254 was 4254, checked in by acc, 8 years ago

Branch 2013/dev_r3858_NOC_ZTC, #863. Merge in final changes from the dev_r3867_MERCATOR1_DYN branch; mainly AGRIF and BDY compatibility

  • Property svn:executable set to *
File size: 24.9 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# INTERACT_FLAG :  flag to run in interactive mode "yes"
44#                       to run in batch mode "no"
45#
46# MPIRUN_FLAG   :  flag to run in parallel (MPI) "yes"
47#                       to run in sequential mode (NB_PROC = 1) "no"
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#  prepare_job.sh
87#
88#  to generate the script run_job.sh
89#
90#  fcm_job.sh
91#
92#   run in batch (INTERACT_FLAG="no") or interactive (INTERACT_FLAG="yes") see sette.sh and BATCH_TEMPLATE directory
93#
94#   (note this job needs to have an input_CONFIG.cfg in which can be found input tar file)
95#
96#  NOTE: if job is not launched for some problems you have executable ready in ${EXE_DIR} directory
97#
98#  NOTE: the changed namelists are leaved in ${EXE_DIR} directory whereas original namelist remains in ${NEW_CONF}/EXP00
99#
100#  in ${SETTE_DIR} is created output.sette with the echo of executed commands
101#
102#  if sette.sh is stopped in output.sette there is written the last command executed by sette.sh
103#
104#  if you run: ./sette.sh 2>&1 | tee out.sette
105#
106#  in ${SETTE_DIR} out.sette is redirected standard error & standard output
107#
108#
109# EXAMPLES
110# ========
111#
112# ::
113#
114#  $ ./sette.sh
115#
116#
117# TODO
118# ====
119#
120# option debug
121#
122# EVOLUTIONS
123# ==========
124#
125# $Id$
126#
127#   * creation
128#
129#-
130#
131#-
132# Compiler among those in NEMOGCM/ARCH
133COMPILER=PW6_VARGAS
134export BATCH_COMMAND_PAR="llsubmit"
135export BATCH_COMMAND_SEQ=$BATCH_COMMAND_PAR
136export INTERACT_FLAG="no"
137export MPIRUN_FLAG="yes"
138# IF YOU DON'T WANT TO USE XIOS : (this is a list of keys to be delete)
139export KEY_XIOS="key_iomput"
140# IF YOU WANT TO USE XIOS :
141#export KEY_XIOS=""
142
143
144# Directory to run the tests
145SETTE_DIR=$(cd $(dirname "$0"); pwd)
146MAIN_DIR=${SETTE_DIR%/SETTE}
147CONFIG_DIR=${MAIN_DIR}/CONFIG
148TOOLS_DIR=${MAIN_DIR}/TOOLS
149COMPIL_DIR=${TOOLS_DIR}/COMPILE
150
151CMP_NAM=${1:-$COMPILER}
152# Copy job_batch_COMPILER file for specific compiler into job_batch_template
153cd ${SETTE_DIR}
154cp BATCH_TEMPLATE/batch-${COMPILER} job_batch_template || exit
155
156for config in 1 2 3 4 5 6 7 8 9
157do
158
159# TESTS FOR GYRE CONFIGURATION
160if [ ${config} -eq 1 ] ;  then
161    ## Restartability tests for GYRE
162    export TEST_NAME="LONG"
163    cd ${SETTE_DIR}
164    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRE_LONG -r GYRE -j 8 add_key "key_mpp_mpi" del_key ${KEY_XIOS}
165    cd ${SETTE_DIR}
166    . param.cfg
167    . all_functions.sh
168    . prepare_exe_dir.sh
169    JOB_FILE=${EXE_DIR}/run_job.sh
170    NPROC=4
171    \rm ${JOB_FILE}
172    cd ${EXE_DIR}
173    set_namelist namelist cn_exp \"GYRE_LONG\"
174    set_namelist namelist nn_it000 1
175    set_namelist namelist nn_itend 120
176    set_namelist namelist nn_stock 60
177    set_namelist namelist ln_clobber .true.
178    set_namelist namelist nn_solv 2
179    set_namelist namelist jpni 2
180    set_namelist namelist jpnj 2
181    set_namelist namelist jpnij 4
182    cd ${SETTE_DIR}
183    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
184
185    cd ${SETTE_DIR}
186    export TEST_NAME="SHORT"
187    . prepare_exe_dir.sh
188    cd ${EXE_DIR}
189    set_namelist namelist cn_exp \"GYRE_SHORT\"
190    set_namelist namelist nn_it000 61
191    set_namelist namelist nn_itend 120
192    set_namelist namelist nn_stock 60
193    set_namelist namelist ln_rstart .true.
194    set_namelist namelist nn_rstctl 2
195    set_namelist namelist ln_clobber .true.
196    set_namelist namelist nn_solv 2
197    set_namelist namelist jpni 2
198    set_namelist namelist jpnj 2
199    set_namelist namelist jpnij 4
200    set_namelist namelist cn_ocerst_in \"GYRE_LONG_00000060_restart\"
201    for (( i=1; i<=$NPROC; i++)) ; do
202        L_NPROC=$(( $i - 1 ))
203        L_NPROC=`printf "%04d\n" ${L_NPROC}`
204        ln -sf ../LONG/GYRE_LONG_00000060_restart_${L_NPROC}.nc .
205    done
206    cd ${SETTE_DIR}
207    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
208    cd ${SETTE_DIR}
209    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
210fi
211
212if [ ${config} -eq 2 ] ;  then
213    ## Reproducibility tests for GYRE
214    export TEST_NAME="REPRO_1_4"
215    cd ${SETTE_DIR}
216    . ../CONFIG/makenemo -m ${CMP_NAM} -n GYRE_4 -r GYRE -j 8 add_key "key_mpp_mpi key_mpp_rep" del_key ${KEY_XIOS}
217    cd ${SETTE_DIR}
218    . param.cfg
219    . all_functions.sh
220    . prepare_exe_dir.sh
221    JOB_FILE=${EXE_DIR}/run_job.sh
222    NPROC=4
223    \rm ${JOB_FILE}
224    cd ${EXE_DIR}
225    set_namelist namelist cn_exp \"GYRE_14\"
226    set_namelist namelist nn_it000 1
227    set_namelist namelist nn_itend 60
228    set_namelist namelist nn_fwb 0
229    set_namelist namelist nn_bench 0
230    set_namelist namelist ln_ctl .false.
231    set_namelist namelist ln_clobber .true.
232    set_namelist namelist nn_solv 2
233    set_namelist namelist jpni 1
234    set_namelist namelist jpnj 4
235    set_namelist namelist jpnij 4
236    cd ${SETTE_DIR}
237    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
238    cd ${SETTE_DIR}
239    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
240
241    cd ${SETTE_DIR}
242    export TEST_NAME="REPRO_2_2"
243    . prepare_exe_dir.sh
244    JOB_FILE=${EXE_DIR}/run_job.sh
245    NPROC=4
246    \rm $JOB_FILE
247    cd ${EXE_DIR}
248    set_namelist namelist cn_exp \"GYRE_22\"
249    set_namelist namelist nn_it000 1
250    set_namelist namelist nn_itend 60
251    set_namelist namelist nn_fwb 0
252    set_namelist namelist ln_ctl .false.
253    set_namelist namelist ln_clobber .true.
254    set_namelist namelist nn_solv 2
255    set_namelist namelist jpni 2
256    set_namelist namelist jpnj 2
257    set_namelist namelist jpnij 4
258    cd ${SETTE_DIR}
259    . ./prepare_job.sh input_GYRE.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
260    cd ${SETTE_DIR}
261    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
262
263fi
264
265# TESTS FOR ORCA2_LIM_PISCES CONFIGURATION
266if [ ${config} -eq 3 ] ;  then
267    ## Restartability tests for ORCA2_LIM_PISCES
268    export TEST_NAME="LONG"
269    cd ${SETTE_DIR}
270    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_LONG -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_mpi" del_key ${KEY_XIOS}
271    cd ${SETTE_DIR}
272    . param.cfg
273    . all_functions.sh
274    . prepare_exe_dir.sh
275    JOB_FILE=${EXE_DIR}/run_job.sh
276    NPROC=4
277    \rm ${JOB_FILE}
278    cd ${EXE_DIR}
279    set_namelist namelist cn_exp \"O2LP_LONG\"
280    set_namelist namelist nn_it000 1
281    set_namelist namelist nn_itend 150
282    set_namelist namelist nn_stock 75
283    set_namelist namelist ln_clobber .true.
284    set_namelist namelist jpni 2
285    set_namelist namelist jpnj 2
286    set_namelist namelist jpnij 4
287    set_namelist namelist nn_solv 2
288    set_namelist namelist_top ln_trcdta .false.
289    set_namelist namelist_top ln_diatrc .false.
290    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
291    # if not you need input files, and for tests is not necessary
292    set_namelist namelist_pisces ln_presatm .false.
293    set_namelist namelist_pisces ln_varpar .false.
294    set_namelist namelist_pisces ln_dust .false.
295    set_namelist namelist_pisces ln_solub .false.
296    set_namelist namelist_pisces ln_river .false.
297    set_namelist namelist_pisces ln_ndepo .false.
298    set_namelist namelist_pisces ln_ironsed .false.
299    set_namelist namelist_pisces ln_hydrofe .false.
300    cd ${SETTE_DIR}
301    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
302   
303    cd ${SETTE_DIR}
304    export TEST_NAME="SHORT"
305    . prepare_exe_dir.sh
306    cd ${EXE_DIR}
307    set_namelist namelist cn_exp \"O2LP_SHORT\"
308    set_namelist namelist nn_it000 76
309    set_namelist namelist nn_itend 150
310    set_namelist namelist nn_stock 75
311    set_namelist namelist ln_rstart .true.
312    set_namelist namelist nn_rstctl 2
313    set_namelist namelist ln_clobber .true.
314    set_namelist namelist jpni 2
315    set_namelist namelist jpnj 2
316    set_namelist namelist jpnij 4
317    set_namelist namelist nn_solv 2
318    set_namelist namelist_top ln_diatrc .false.
319    set_namelist namelist_top ln_rsttr .true.
320    set_namelist namelist_top nn_rsttr 2
321    set_namelist namelist cn_ocerst_in \"O2LP_LONG_00000075_restart\"
322    set_namelist namelist_ice cn_icerst_in \"O2LP_LONG_00000075_restart_ice\"
323    set_namelist namelist_top cn_trcrst_in \"O2LP_LONG_00000075_restart_trc\"
324    # put ln_ironsed, ln_river, ln_ndepo, ln_dust
325    # if not you need input files, and for tests is not necessary
326    set_namelist namelist_pisces ln_presatm .false.
327    set_namelist namelist_pisces ln_varpar .false.
328    set_namelist namelist_pisces ln_dust .false.
329    set_namelist namelist_pisces ln_solub .false.
330    set_namelist namelist_pisces ln_river .false.
331    set_namelist namelist_pisces ln_ndepo .false.
332    set_namelist namelist_pisces ln_ironsed .false.
333    set_namelist namelist_pisces ln_hydrofe .false.
334    # put ln_pisdmp to false : no restoring to global mean value
335    set_namelist namelist_pisces ln_pisdmp .false.
336    for (( i=1; i<=$NPROC; i++)) ; do
337        L_NPROC=$(( $i - 1 ))
338        L_NPROC=`printf "%04d\n" ${L_NPROC}`
339        ln -sf ../LONG/O2LP_LONG_00000075_restart_${L_NPROC}.nc .
340        ln -sf ../LONG/O2LP_LONG_00000075_restart_trc_${L_NPROC}.nc .
341        ln -sf ../LONG/O2LP_LONG_00000075_restart_ice_${L_NPROC}.nc .
342    done
343    cd ${SETTE_DIR}
344    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
345    cd ${SETTE_DIR}
346    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
347fi
348
349if [ ${config} -eq 4 ] ;  then
350    ## Reproducibility tests for ORCA2_LIM_PISCES
351    export TEST_NAME="REPRO_4_4"
352    cd ${SETTE_DIR}
353    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2LIMPIS_16 -r ORCA2_LIM_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep" del_key ${KEY_XIOS}
354    cd ${SETTE_DIR}
355    . param.cfg
356    . all_functions.sh
357    . prepare_exe_dir.sh
358    JOB_FILE=${EXE_DIR}/run_job.sh
359    NPROC=16
360    \rm $JOB_FILE
361    cd ${EXE_DIR}
362    set_namelist namelist nn_it000 1
363    set_namelist namelist nn_itend 75
364    set_namelist namelist nn_fwb 0
365    set_namelist namelist ln_ctl .false.
366    set_namelist namelist ln_clobber .true.
367    set_namelist namelist jpni 4
368    set_namelist namelist jpnj 4
369    set_namelist namelist jpnij 16
370    set_namelist namelist nn_solv 2
371    set_namelist namelist_top ln_trcdta .false.
372    set_namelist namelist_top ln_diatrc .false.
373    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
374    # if not you need input files, and for tests is not necessary
375    set_namelist namelist_pisces ln_presatm .false.
376    set_namelist namelist_pisces ln_varpar .false.
377    set_namelist namelist_pisces ln_dust .false.
378    set_namelist namelist_pisces ln_solub .false.
379    set_namelist namelist_pisces ln_river .false.
380    set_namelist namelist_pisces ln_ndepo .false.
381    set_namelist namelist_pisces ln_ironsed .false.
382    set_namelist namelist_pisces ln_hydrofe .false.
383    # put ln_pisdmp to false : no restoring to global mean value
384    set_namelist namelist_pisces ln_pisdmp .false.
385    cd ${SETTE_DIR}
386    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
387    cd ${SETTE_DIR}
388    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
389
390    cd ${SETTE_DIR}
391    export TEST_NAME="REPRO_2_8"
392    . prepare_exe_dir.sh
393    JOB_FILE=${EXE_DIR}/run_job.sh
394    NPROC=16
395    \rm $JOB_FILE
396    cd ${EXE_DIR}
397    set_namelist namelist nn_it000 1
398    set_namelist namelist nn_itend 75
399    set_namelist namelist nn_fwb 0
400    set_namelist namelist ln_clobber .true.
401    set_namelist namelist jpni 2
402    set_namelist namelist jpnj 8
403    set_namelist namelist jpnij 16
404    set_namelist namelist nn_solv 2
405    set_namelist namelist_top ln_trcdta .false.
406    set_namelist namelist_top ln_diatrc .false.
407    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
408    # if not you need input files, and for tests is not necessary
409    set_namelist namelist_pisces ln_presatm .false.
410    set_namelist namelist_pisces ln_varpar .false.
411    set_namelist namelist_pisces ln_dust .false.
412    set_namelist namelist_pisces ln_solub .false.
413    set_namelist namelist_pisces ln_river .false.
414    set_namelist namelist_pisces ln_ndepo .false.
415    set_namelist namelist_pisces ln_ironsed .false.
416    set_namelist namelist_pisces ln_hydrofe .false.
417    # put ln_pisdmp to false : no restoring to global mean value
418    set_namelist namelist_pisces ln_pisdmp .false.
419    cd ${SETTE_DIR}
420    . ./prepare_job.sh input_ORCA2_LIM_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
421    cd ${SETTE_DIR}
422    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
423fi
424
425# TESTS FOR ORCA2_OFF_PISCES CONFIGURATION
426if [ ${config} -eq 5 ] ;  then
427    ## Restartability tests for ORCA2_OFF_PISCES
428    export TEST_NAME="LONG"
429    cd ${SETTE_DIR}
430    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_LONG -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep" del_key ${KEY_XIOS}
431    cd ${SETTE_DIR}
432    . param.cfg
433    . all_functions.sh
434    . prepare_exe_dir.sh
435    JOB_FILE=${EXE_DIR}/run_job.sh
436    NPROC=4
437    \rm $JOB_FILE
438    cd ${EXE_DIR}
439    set_namelist namelist cn_exp \"OFFP_LONG\"
440    set_namelist namelist nn_it000 1
441    set_namelist namelist nn_itend 40
442    set_namelist namelist nn_stock 20
443    set_namelist namelist ln_clobber .true.
444    set_namelist namelist jpni 2
445    set_namelist namelist jpnj 2
446    set_namelist namelist jpnij 4
447    set_namelist namelist_top ln_trcdta .false.
448    set_namelist namelist_top ln_diatrc .false.
449    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
450    # if not you need input files, and for tests is not necessary
451    set_namelist namelist_pisces ln_presatm .false.
452    set_namelist namelist_pisces ln_varpar .false.
453    set_namelist namelist_pisces ln_dust .false.
454    set_namelist namelist_pisces ln_solub .false.
455    set_namelist namelist_pisces ln_river .false.
456    set_namelist namelist_pisces ln_ndepo .false.
457    set_namelist namelist_pisces ln_ironsed .false.
458    set_namelist namelist_pisces ln_hydrofe .false.
459    # put ln_pisdmp to false : no restoring to global mean value
460    set_namelist namelist_pisces ln_pisdmp .false.
461    cd ${SETTE_DIR}
462    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
463   
464    cd ${SETTE_DIR}
465    export TEST_NAME="SHORT"
466    . prepare_exe_dir.sh
467    cd ${EXE_DIR}
468    set_namelist namelist cn_exp \"OFFP_SHORT\"
469    set_namelist namelist nn_it000 21
470    set_namelist namelist nn_itend 40
471    set_namelist namelist nn_stock 20
472    set_namelist namelist ln_clobber .true.
473    set_namelist namelist jpni 2
474    set_namelist namelist jpnj 2
475    set_namelist namelist jpnij 4
476    set_namelist namelist_top ln_diatrc .false.
477    set_namelist namelist_top ln_rsttr .true.
478    set_namelist namelist_top nn_rsttr 2
479    set_namelist namelist_top cn_trcrst_in \"OFFP_LONG_00000020_restart_trc\"
480    for (( i=1; i<=$NPROC; i++)) ; do
481        L_NPROC=$(( $i - 1 ))
482        L_NPROC=`printf "%04d\n" ${L_NPROC}`
483        ln -sf ../LONG/OFFP_LONG_00000020_restart_trc_${L_NPROC}.nc .
484    done
485    # put ln_ironsed, ln_river, ln_ndepo, ln_dust
486    # if not you need input files, and for tests is not necessary
487    set_namelist namelist_pisces ln_presatm .false.
488    set_namelist namelist_pisces ln_varpar .false.
489    set_namelist namelist_pisces ln_dust .false.
490    set_namelist namelist_pisces ln_solub .false.
491    set_namelist namelist_pisces ln_river .false.
492    set_namelist namelist_pisces ln_ndepo .false.
493    set_namelist namelist_pisces ln_ironsed .false.
494    set_namelist namelist_pisces ln_hydrofe .false.
495    # put ln_pisdmp to false : no restoring to global mean value
496    set_namelist namelist_pisces ln_pisdmp .false.
497    cd ${SETTE_DIR}
498    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME}  ${MPIRUN_FLAG} ${JOB_FILE}
499    cd ${SETTE_DIR}
500    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
501fi
502
503if [ ${config} -eq 6 ] ;  then
504    ## Reproducibility tests for ORCA2_OFF_PISCES
505    export TEST_NAME="REPRO_4_4"
506    cd ${SETTE_DIR}
507    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2OFFPIS_16 -r ORCA2_OFF_PISCES -j 8 add_key "key_mpp_mpi key_mpp_rep" del_key ${KEY_XIOS}
508    cd ${SETTE_DIR}
509    . param.cfg
510    . all_functions.sh
511    . prepare_exe_dir.sh
512    JOB_FILE=${EXE_DIR}/run_job.sh
513    NPROC=16
514    \rm $JOB_FILE
515    cd ${EXE_DIR}
516    set_namelist namelist nn_it000 1
517    set_namelist namelist nn_itend 40
518    set_namelist namelist ln_ctl .false.
519    set_namelist namelist ln_clobber .true.
520    set_namelist namelist jpni 4
521    set_namelist namelist jpnj 4
522    set_namelist namelist jpnij 16
523    set_namelist namelist_top ln_trcdta .false.
524    set_namelist namelist_top ln_diatrc .false.
525    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
526    # if not you need input files, and for tests is not necessary
527    set_namelist namelist_pisces ln_presatm .false.
528    set_namelist namelist_pisces ln_varpar .false.
529    set_namelist namelist_pisces ln_dust .false.
530    set_namelist namelist_pisces ln_solub .false.
531    set_namelist namelist_pisces ln_river .false.
532    set_namelist namelist_pisces ln_ndepo .false.
533    set_namelist namelist_pisces ln_ironsed .false.
534    set_namelist namelist_pisces ln_hydrofe .false.
535    # put ln_pisdmp to false : no restoring to global mean value
536    set_namelist namelist_pisces ln_pisdmp .false.
537    cd ${SETTE_DIR}
538    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
539    cd ${SETTE_DIR}
540    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
541
542    cd ${SETTE_DIR}
543    export TEST_NAME="REPRO_2_8"
544    . prepare_exe_dir.sh
545    JOB_FILE=${EXE_DIR}/run_job.sh
546    NPROC=16
547    \rm $JOB_FILE
548    cd ${EXE_DIR}
549    set_namelist namelist nn_it000 1
550    set_namelist namelist nn_itend 40
551    set_namelist namelist ln_ctl .false.
552    set_namelist namelist ln_clobber .true.
553    set_namelist namelist jpni 2
554    set_namelist namelist jpnj 8
555    set_namelist namelist jpnij 16
556    set_namelist namelist_top ln_trcdta .false.
557    set_namelist namelist_top ln_diatrc .false.
558    # put ln_ironsed, ln_river, ln_ndepo, ln_dust to false
559    # if not you need input files, and for tests is not necessary
560    set_namelist namelist_pisces ln_presatm .false.
561    set_namelist namelist_pisces ln_varpar .false.
562    set_namelist namelist_pisces ln_dust .false.
563    set_namelist namelist_pisces ln_solub .false.
564    set_namelist namelist_pisces ln_river .false.
565    set_namelist namelist_pisces ln_ndepo .false.
566    set_namelist namelist_pisces ln_ironsed .false.
567    set_namelist namelist_pisces ln_hydrofe .false.
568    # put ln_pisdmp to false : no restoring to global mean value
569    set_namelist namelist_pisces ln_pisdmp .false.
570    cd ${SETTE_DIR}
571    . ./prepare_job.sh input_ORCA2_OFF_PISCES.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
572    cd ${SETTE_DIR}
573    . ./fcm_job.sh $NPROC  ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
574fi
575
576# TESTS FOR AMM12 CONFIGURATION
577if [ ${config} -eq 7 ] ;  then
578    ## Restartability tests for AMM12
579    export TEST_NAME="LONG"
580    cd ${SETTE_DIR}
581    . ../CONFIG/makenemo -m ${CMP_NAM} -n AMM12_LONG -r AMM12 -j 8 add_key "key_tide" del_key ${KEY_XIOS}
582    cd ${SETTE_DIR}
583    . param.cfg
584    . all_functions.sh
585    . prepare_exe_dir.sh
586    JOB_FILE=${EXE_DIR}/run_job.sh
587    NPROC=32
588    \rm $JOB_FILE
589    cd ${EXE_DIR}
590    set_namelist namelist nn_it000 1
591    set_namelist namelist nn_itend 12
592    set_namelist namelist nn_stock 6
593    set_namelist namelist nn_fwb 0
594    set_namelist namelist ln_ctl .false.
595    set_namelist namelist ln_clobber .true.
596    set_namelist namelist cn_ocerst_in \"amm12.restart_20070101\"
597    set_namelist namelist jpni 8
598    set_namelist namelist jpnj 4
599    set_namelist namelist jpnij 32
600    cd ${SETTE_DIR}
601    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
602
603    cd ${SETTE_DIR}
604    export TEST_NAME="SHORT"
605    . prepare_exe_dir.sh
606    cd ${EXE_DIR}
607    set_namelist namelist nn_it000 7
608    set_namelist namelist nn_itend 12
609    set_namelist namelist nn_fwb 0
610    set_namelist namelist ln_ctl .false.
611    set_namelist namelist ln_clobber .true.
612    set_namelist namelist jpni 8
613    set_namelist namelist jpnj 4
614    set_namelist namelist jpnij 32
615    set_namelist namelist ln_rstart .true.
616    set_namelist namelist nn_rstctl 2
617    set_namelist namelist cn_ocerst_in \"AMM12_00000006_restart\"
618    for (( i=1; i<=$NPROC; i++)) ; do
619        L_NPROC=$(( $i - 1 ))
620        L_NPROC=`printf "%04d\n" ${L_NPROC}`
621        ln -sf ../LONG/AMM12_00000006_restart_${L_NPROC}.nc .
622    done
623    cd ${SETTE_DIR}
624    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
625    cd ${SETTE_DIR}
626    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
627fi
628
629if [ ${config} -eq 8 ] ;  then
630## Reproducibility tests for AMM12
631    export TEST_NAME="REPRO_8_4"
632    cd ${SETTE_DIR}
633    . ../CONFIG/makenemo -m ${CMP_NAM} -n AMM12_32 -r AMM12 -j 8 add_key "key_mpp_rep key_tide" del_key ${KEY_XIOS}
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=32
640    \rm ${JOB_FILE}
641    cd ${EXE_DIR}
642    set_namelist namelist nn_it000 1
643    set_namelist namelist nn_itend 576
644    set_namelist namelist nn_fwb 0
645    set_namelist namelist ln_ctl .false.
646    set_namelist namelist ln_clobber .true.
647    set_namelist namelist cn_ocerst_in \"amm12.restart_20070101\"
648    set_namelist namelist jpni 8
649    set_namelist namelist jpnj 4
650    set_namelist namelist jpnij 32
651    cd ${SETTE_DIR}
652    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
653    cd ${SETTE_DIR}
654    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
655
656    cd ${SETTE_DIR}
657    export TEST_NAME="REPRO_4_8"
658    . prepare_exe_dir.sh
659    cd ${EXE_DIR}
660    set_namelist namelist nn_it000 1
661    set_namelist namelist nn_itend 576
662    set_namelist namelist nn_fwb 0
663    set_namelist namelist ln_ctl .false.
664    set_namelist namelist ln_clobber .true.
665    set_namelist namelist cn_ocerst_in \"amm12.restart_20070101\"
666    set_namelist namelist jpni 4
667    set_namelist namelist jpnj 8
668    set_namelist namelist jpnij 32
669    cd ${SETTE_DIR}
670    . ./prepare_job.sh input_AMM12.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
671    cd ${SETTE_DIR}
672    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
673fi
674
675# TEST FOR ORCA2_LIM_AGRIF : simple test of running AGRIF (no restartability neither reproducibility tests)
676if [ ${config} -eq 9 ] ;  then
677    ## ORCA2_LIM with Agulhas AGRIF zoom in MPI
678    export TEST_NAME="SHORT"
679    cd ${SETTE_DIR}
680    . ../CONFIG/makenemo -m ${CMP_NAM} -n ORCA2AGUL_1_2 -r ORCA2_LIM -j 8 add_key "key_mpp_mpi key_mpp_rep key_agrif" del_key "key_zdftmx" del_key ${KEY_XIOS}
681    cd ${SETTE_DIR}
682    . param.cfg
683    . all_functions.sh
684    . prepare_exe_dir.sh
685    JOB_FILE=${EXE_DIR}/run_job.sh
686    NPROC=2
687    \rm ${JOB_FILE}
688    cd ${EXE_DIR}
689    set_namelist namelist nn_it000 1
690    set_namelist namelist nn_itend 75
691    set_namelist namelist ln_ctl .false.
692    set_namelist namelist ln_clobber .true.
693    set_namelist namelist jpni 1
694    set_namelist namelist jpnj 2
695    set_namelist namelist jpnij 2
696    set_namelist 1_namelist nn_it000 1
697    set_namelist 1_namelist nn_itend 150
698    set_namelist 1_namelist ln_ctl .false.
699    set_namelist 1_namelist ln_clobber .true.
700    cd ${SETTE_DIR}
701    . ./prepare_job.sh input_ORCA2_LIM_AGRIF.cfg $NPROC ${TEST_NAME} ${MPIRUN_FLAG} ${JOB_FILE}
702    cd ${SETTE_DIR}
703    . ./fcm_job.sh $NPROC ${JOB_FILE} ${INTERACT_FLAG} ${MPIRUN_FLAG}
704fi
705
706done
Note: See TracBrowser for help on using the repository browser.