[5480] | 1 | #/bin/bash |
---|
| 2 | #! |
---|
| 3 | #PBS -N nemo_sette |
---|
[6140] | 4 | #PBS -l walltime=00:08:00 |
---|
[5480] | 5 | #PBS -j oe |
---|
[6140] | 6 | #PBS -q normal |
---|
[5480] | 7 | #PBS -l SELECT |
---|
| 8 | |
---|
| 9 | export PBS_O_WORKDIR=$(readlink -f $PBS_O_WORKDIR) |
---|
| 10 | export OMP_NUM_THREADS=1 |
---|
| 11 | cd $PBS_O_WORKDIR |
---|
| 12 | export XIO_HOME=/projects/ocean/nemo/xios/xios_1.0_r618_20150619/XIOS |
---|
| 13 | # |
---|
| 14 | echo " "; |
---|
| 15 | export OMP_NUM_THREADS=1 |
---|
| 16 | O_PER_NODE=32 |
---|
| 17 | X_PER_NODE=4 |
---|
| 18 | OCORES=NPROCS |
---|
| 19 | XCORES=NXIOPROCS |
---|
| 20 | if [ $OCORES -le 32 ] ; then O_PER_NODE=$OCORES; fi |
---|
| 21 | export SETTE_DIR=DEF_SETTE_DIR |
---|
| 22 | |
---|
| 23 | ############################################################### |
---|
| 24 | # |
---|
| 25 | # |
---|
| 26 | # load sette functions (only post_test_tidyup needed) |
---|
| 27 | # |
---|
| 28 | . ${SETTE_DIR}/all_functions.sh |
---|
| 29 | ############################################################### |
---|
| 30 | # |
---|
| 31 | # Don't remove neither change the following line |
---|
| 32 | # BODY |
---|
| 33 | # |
---|
| 34 | # Test specific settings. Do not hand edit these lines; the fcm_job.sh script will set these |
---|
| 35 | # (via sed operating on this template job file). Note that the number of compute nodes required |
---|
| 36 | # is also set by the fcm_job.sh on the PBS select header line above. |
---|
| 37 | # |
---|
| 38 | # These variables are needed by post_test_tidyup function in all_functions.sh |
---|
| 39 | # |
---|
| 40 | export INPUT_DIR=DEF_INPUT_DIR |
---|
| 41 | export CONFIG_DIR=DEF_CONFIG_DIR |
---|
| 42 | export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION |
---|
| 43 | export NEW_CONF=DEF_NEW_CONF |
---|
| 44 | export CMP_NAM=DEF_CMP_NAM |
---|
| 45 | export TEST_NAME=DEF_TEST_NAME |
---|
| 46 | export EXE_DIR=DEF_EXE_DIR |
---|
| 47 | ulimit -c unlimited |
---|
| 48 | ulimit -s unlimited |
---|
| 49 | export FORT_FMT_RECL=132 |
---|
| 50 | # |
---|
| 51 | # end of set up |
---|
| 52 | ############################################################### |
---|
| 53 | # |
---|
| 54 | # change to the working directory |
---|
| 55 | # |
---|
| 56 | cd $EXE_DIR |
---|
| 57 | echo Directory is `pwd` |
---|
| 58 | |
---|
| 59 | if [ $XCORES -gt 0 ]; then |
---|
| 60 | # |
---|
| 61 | # Run MPMD case |
---|
| 62 | # |
---|
| 63 | #XIOS will run on a separate node so will run in parallel queue |
---|
| 64 | if [ ! -f ./xios_server.exe ] && [ -f ${XIO_HOME}/bin/xios_server.exe ]; then |
---|
| 65 | cp ${XIO_HOME}/bin/xios_server.exe . |
---|
| 66 | fi |
---|
| 67 | if [ ! -f ./xios_server.exe ]; then |
---|
| 68 | echo "./xios_server.exe not found" |
---|
| 69 | echo "run aborted" |
---|
| 70 | exit |
---|
| 71 | fi |
---|
| 72 | echo time aprun -b -n $XCORES -N $X_PER_NODE ./xios_server.exe : -n $OCORES -N $O_PER_NODE ./opa |
---|
| 73 | time aprun -b -n $XCORES -N $X_PER_NODE ./xios_server.exe : -n $OCORES -N $O_PER_NODE ./opa |
---|
| 74 | # |
---|
| 75 | else |
---|
| 76 | # |
---|
| 77 | # Run SPMD case |
---|
| 78 | # |
---|
[6140] | 79 | echo time aprun -b -n $OCORES -N $O_PER_NODE ./opa |
---|
| 80 | time aprun -b -n $OCORES -N $O_PER_NODE ./opa |
---|
[5480] | 81 | fi |
---|
| 82 | # |
---|
| 83 | |
---|
| 84 | # |
---|
| 85 | post_test_tidyup |
---|
| 86 | # END_BODY |
---|
| 87 | # Don't remove neither change the previous line |
---|
| 88 | exit |
---|
| 89 | |
---|