Changeset 8468


Ignore:
Timestamp:
2017-08-28T16:32:29+02:00 (3 years ago)
Author:
flavoni
Message:

#1936: add in sette_rpt.sh difference of SAS restart_ice files

Location:
trunk/NEMOGCM/SETTE
Files:
2 deleted
21 edited

Legend:

Unmodified
Added
Removed
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ALTIX_NAUTILUS_MPT

    r3631 r8468  
    6565  export INPUT_DIR=DEF_INPUT_DIR 
    6666  export CONFIG_DIR=DEF_CONFIG_DIR 
     67  export TOOLS_DIR=DEF_TOOLS_DIR 
    6768  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    6869  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-IBM_EKMAN_INGV

    r5301 r8468  
    4747  export INPUT_DIR=DEF_INPUT_DIR 
    4848  export CONFIG_DIR=DEF_CONFIG_DIR 
     49  export TOOLS_DIR=DEF_TOOLS_DIR 
    4950  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    5051  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-PW6_CALYPSO

    r3294 r8468  
    4343  export INPUT_DIR=DEF_INPUT_DIR 
    4444  export CONFIG_DIR=DEF_CONFIG_DIR 
     45  export TOOLS_DIR=DEF_TOOLS_DIR 
    4546  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4647  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-PW7_METO

    r4285 r8468  
    4848  export INPUT_DIR=DEF_INPUT_DIR 
    4949  export CONFIG_DIR=DEF_CONFIG_DIR 
     50  export TOOLS_DIR=DEF_TOOLS_DIR 
    5051  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    5152  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-PW7_MONSOON

    r5029 r8468  
    4747  export INPUT_DIR=DEF_INPUT_DIR 
    4848  export CONFIG_DIR=DEF_CONFIG_DIR 
     49  export TOOLS_DIR=DEF_TOOLS_DIR 
    4950  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    5051  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-X64_ADA

    r8284 r8468  
    4444  export INPUT_DIR=DEF_INPUT_DIR 
    4545  export CONFIG_DIR=DEF_CONFIG_DIR 
     46  export TOOLS_DIR=DEF_TOOLS_DIR 
    4647  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4748  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-X64_ADA_DEBUG

    r8284 r8468  
    4444  export INPUT_DIR=DEF_INPUT_DIR 
    4545  export CONFIG_DIR=DEF_CONFIG_DIR 
     46  export TOOLS_DIR=DEF_TOOLS_DIR 
    4647  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4748  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-X64_ADA_O0

    r8284 r8468  
    4545  export INPUT_DIR=DEF_INPUT_DIR 
    4646  export CONFIG_DIR=DEF_CONFIG_DIR 
     47  export TOOLS_DIR=DEF_TOOLS_DIR 
    4748  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4849  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-X64_CURIE

    r5407 r8468  
    4545  export INPUT_DIR=DEF_INPUT_DIR 
    4646  export CONFIG_DIR=DEF_CONFIG_DIR 
     47  export TOOLS_DIR=DEF_TOOLS_DIR 
    4748  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4849  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-X64_MOBILIS

    r7646 r8468  
    4242  export INPUT_DIR=DEF_INPUT_DIR 
    4343  export CONFIG_DIR=DEF_CONFIG_DIR 
     44  export TOOLS_DIR=DEF_TOOLS_DIR 
    4445  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4546  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-XC40_METO

    r6140 r8468  
    4040  export INPUT_DIR=DEF_INPUT_DIR 
    4141  export CONFIG_DIR=DEF_CONFIG_DIR 
     42  export TOOLS_DIR=DEF_TOOLS_DIR 
    4243  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4344  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-XC_ARCHER_INTEL

    r4814 r8468  
    5050  export INPUT_DIR=DEF_INPUT_DIR 
    5151  export CONFIG_DIR=DEF_CONFIG_DIR 
     52  export TOOLS_DIR=DEF_TOOLS_DIR 
    5253  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    5354  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ifort_athena

    r7646 r8468  
    4343  export INPUT_DIR=DEF_INPUT_DIR 
    4444  export CONFIG_DIR=DEF_CONFIG_DIR 
     45  export TOOLS_DIR=DEF_TOOLS_DIR 
    4546  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4647  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-ifort_athena_xios

    r7646 r8468  
    4949  export INPUT_DIR=DEF_INPUT_DIR 
    5050  export CONFIG_DIR=DEF_CONFIG_DIR 
     51  export TOOLS_DIR=DEF_TOOLS_DIR 
    5152  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    5253  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-macport_osx

    r4147 r8468  
    4444  export INPUT_DIR=DEF_INPUT_DIR 
    4545  export CONFIG_DIR=DEF_CONFIG_DIR 
     46  export TOOLS_DIR=DEF_TOOLS_DIR 
    4647  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4748  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-macport_osx_debug

    r7646 r8468  
    4444  export INPUT_DIR=DEF_INPUT_DIR 
    4545  export CONFIG_DIR=DEF_CONFIG_DIR 
     46  export TOOLS_DIR=DEF_TOOLS_DIR 
    4647  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4748  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/batch-mpmd-ALTIX_NAUTILUS_MPT

    r3736 r8468  
    6868  export INPUT_DIR=DEF_INPUT_DIR 
    6969  export CONFIG_DIR=DEF_CONFIG_DIR 
     70  export TOOLS_DIR=DEF_TOOLS_DIR 
    7071  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    7172  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/BATCH_TEMPLATE/sette_batch_template

    r3608 r8468  
    4444  export INPUT_DIR=DEF_INPUT_DIR 
    4545  export CONFIG_DIR=DEF_CONFIG_DIR 
     46  export TOOLS_DIR=DEF_TOOLS_DIR 
    4647  export NEMO_VALIDATION_DIR=DEF_NEMO_VALIDATION 
    4748  export NEW_CONF=DEF_NEW_CONF 
  • trunk/NEMOGCM/SETTE/all_functions.sh

    r7715 r8468  
    172172echo "COMPILER is : ${CMP_NAM}" 
    173173echo "TEST is : ${TEST_NAME}" 
     174echo "TOOLS directory is : ${TOOLS_DIR}" 
    174175################################################################ 
    175176# SMALL DEBUG 
  • trunk/NEMOGCM/SETTE/prepare_job.sh

    r7753 r8468  
    151151fi 
    152152################################################################ 
    153  
    154 ########################################################################## 
    155 # COPY RESTART FILES (if needed; i.e. only for SHORT job in RESTART TESTS) 
    156 # get the input tarfile if needed 
    157 # SF : not ok for the moment because at this point is needed cn_exp variable, 
    158 # SF : here it it not known. 
    159 #\cd ${EXE_DIR} 
    160 #if [ "$(echo ${TEST_NAME} | grep -c "SHORT" )" -ne 0 ] ; then 
    161 #    for (( i=1; i<=${NB_PROC}; ${NB_PROC}++)) ; do 
    162 #        L_NPROC=`printf "%04d\n" $i` 
    163 #        ln -sf ../LONG/${NEW_CONF}_00000060_restart_${L_NPROC-1}.nc . 
    164 #    done 
    165 #fi 
    166 ## SF : other way 
    167 ##      for file in ../LONG/${NEW_CONF}_*restart_0*.nc ; do 
    168 ##              ncpu=`echo $file | awk -F '_' '{print $NF}' | cut -f 1 -d '.'` 
    169 ##              ln -sf ${file}  . 
    170 ##      done 
    171 ##fi 
    172 ########################################################################## 
    173153 
    174154################################################################ 
     
    309289             -e"s:DEF_EXE_DIR:${EXE_DIR}:" \ 
    310290             -e"s:DEF_CONFIG_DIR:${CONFIG_DIR}:" \ 
     291             -e"s:DEF_TOOLS_DIR:${TOOLS_DIR}:" \ 
    311292             -e"s:MPI_FLAG:${MPI_FLAG}:" \ 
    312293             -e"s:DEF_NEMO_VALIDATION:${NEMO_VALIDATION_DIR}:" -e"s:DEF_NEW_CONF:${NEW_CONF}:" \ 
  • trunk/NEMOGCM/SETTE/sette_rpt.sh

    r7715 r8468  
    11#!/bin/bash -f 
     2#set -vx 
    23# 
    34# simple SETTE report generator. 
     
    1011######################### Start of function definitions ################################# 
    1112## 
     13 
     14function restfile() { 
     15# Rebuild ice restart for SAS CONFIG, and restartability checks. Expects LONG and SHORT run directories. 
     16# For Stand Alone Surface configuration ocean is not running, just run ice model; so no outputs ocean files. 
     17# Compares LONG rebuild restart ice file with equivalent entry from the SHORT rebuild restart ice file. 
     18# 
     19  vdir=$1 
     20  nam=$2 
     21  pass=$3 
     22# 
     23  if [ -d $vdir/$nam ]; then 
     24    dorv=`ls -1rt $vdir/$nam/$mach/ | tail -1l ` 
     25    dorv=`echo $dorv | sed -e 's:.*/::'` 
     26    rep1=`ls -1rt $vdir/$nam/$mach/$dorv/ | tail -2l | head -1 ` 
     27    rep2=`ls -1rt $vdir/$nam/$mach/$dorv/ | tail -1l` 
     28    cd ${SAS_RESTART_DIR}/LONG 
     29    #SF add here compilation of rebuild_tools to rebuild restart files, and add comparison of restart files 
     30    cd ${TOOLS_DIR} 
     31    ./maketools -n REBUILD_NEMO -m ${mach} > /dev/null 2>&1 
     32    cd ${TOOLS_DIR}/REBUILD_NEMO 
     33    #SF echo "REBUILD LONG restart SAS files, without standard output" 
     34    ./rebuild_nemo -t 4 ../../CONFIG/SAS_LONG/LONG/SAS_00000100_restart_ice  $NPROC > /dev/null 2>&1 
     35    #SF echo "REBUILD SHORT restart SAS files, without standard output" 
     36    ./rebuild_nemo -t 4 ../../CONFIG/SAS_LONG/SHORT/SAS_00000100_restart_ice $NPROC >&- 
     37    cd ${SAS_RESTART_DIR}/LONG 
     38    #SF echo "COPY rebuild restart files" 
     39    cp SAS_00000100_restart_ice.nc $vdir/$nam/$mach/$dorv/LONG/. 
     40    cp ../SHORT/SAS_00000100_restart_ice.nc $vdir/$nam/$mach/$dorv/SHORT/. 
     41 
     42    f1o=$vdir/$nam/$mach/$dorv/LONG/SAS_00000100_restart_ice.nc 
     43    f2o=$vdir/$nam/$mach/$dorv/SHORT/SAS_00000100_restart_ice.nc 
     44    if  [ ! -f $f1o ] &&  [ ! -f $f2o ] ; then 
     45      printf "%-20s %s\n" $nam " REBUILD SAS restart ice DOES NOT exists; incomplete test"; 
     46      return; 
     47    fi 
     48    # 
     49    done_oce=0 
     50    # 
     51    if  [  -f $f1o ] && [  -f $f2o ]; then 
     52      cmp -s $f1o $f2o  
     53      #SF  cmp SAS_00000100_restart_ice.nc  ../SHORT/SAS_00000100_restart_ice.nc  > diff_restart.txt 
     54      if [ $? == 0 ]; then 
     55        if [ $pass == 0 ]; then 
     56          printf "%-20s %s %s\n" $nam  " SAS restart files are IDENTICAL :  passed : " $dorv 
     57        fi 
     58      else 
     59        printf "%-20s %s %s\n" $nam  " SAS restart files are DIFFERENT : FAILED : " $dorv  
     60        # 
     61   # Offer view of differences on the second pass 
     62   # 
     63        if [ $pass == 1 ]; then 
     64          echo "BE CAREFUL:  NEED cdo to see differences!!!!! IF it is not the case you need to do difference of netcdf file by hand" 
     65          echo "<return> to view restart_ice.nc differences" 
     66          read y 
     67          cdo -diffv $f1o $f2o 
     68          done_oce=1 
     69          #echo "<return> to continue" 
     70          #read y 
     71        fi 
     72      fi 
     73    fi 
     74# 
     75fi 
     76} 
     77 
    1278function resttest() {  
    1379# 
     
    199265  mach=`grep "COMPILER=" ./sette.sh | sed -e 's/COMPILER=//'` 
    200266  NEMO_VALID=`grep "NEMO_VALIDATION_DIR=" ./param.cfg | sed -e 's/NEMO_VALIDATION_DIR=//'` 
     267# Directory to run the tests 
     268 SETTE_DIR=$(cd $(dirname "$0"); pwd) 
     269 MAIN_DIR=$(dirname $SETTE_DIR) 
     270 CONFIG_DIR0=${MAIN_DIR}/CONFIG 
     271 TOOLS_DIR=${MAIN_DIR}/TOOLS 
     272 COMPIL_DIR=${TOOLS_DIR}/COMPILE 
     273 NPROC=32 
     274 
     275  SAS_RESTART_DIR=${CONFIG_DIR0}/SAS_LONG 
    201276# 
    202277  if [ ! -d $NEMO_VALID ]; then 
     
    205280  fi 
    206281# 
     282 
    207283# The script also needs the date or revision tag. Currently this is taken from the latest sub-directory found in each directory 
    208284 
     
    212288 if [ $pass == 1 ]; then echo "---------------2nd pass------------------";fi 
    213289# 
     290 
     291# Rebuild and restartability test for SAS 
     292# 
     293 for restart_file in WSAS_LONG 
     294 do 
     295 #  restfile $SAS_RESTART_DIR LONG $pass 
     296   restfile $NEMO_VALID $restart_file $pass 
     297 done 
     298# 
    214299# Restartability test 
    215300# 
    216  for restart_test in WGYREPIS_LONG WORCA2LIM3PIS_LONG WORCA2OFFPIS_LONG WAMM12_LONG WSAS_LONG WISOMIP_LONG WORCA2AGUL_LONG 
     301 for restart_test in WGYREPIS_LONG WORCA2LIM3PIS_LONG WORCA2OFFPIS_LONG WAMM12_LONG WISOMIP_LONG WORCA2AGUL_LONG 
    217302 do 
    218303   resttest $NEMO_VALID $restart_test $pass 
Note: See TracChangeset for help on using the changeset viewer.