--- MITgcm/verification/testreport 2006/03/20 21:50:36 1.77 +++ MITgcm/verification/testreport 2006/06/18 21:20:51 1.82 @@ -1,6 +1,6 @@ #! /usr/bin/env bash # -# $Header: /home/ubuntu/mnt/e9_copy/MITgcm/verification/testreport,v 1.77 2006/03/20 21:50:36 jmc Exp $ +# $Header: /home/ubuntu/mnt/e9_copy/MITgcm/verification/testreport,v 1.82 2006/06/18 21:20:51 jmc Exp $ # $Name: $ # @@ -181,10 +181,10 @@ testoutput_ad() { - grep $3 $1/results_ad/output.txt_adm | awk '{print NR " " $5}' > t05.txt - grep $3 $1/$2/output.txt_adm | awk '{print NR " " $5}' > t15.txt - grep $3 $1/results_ad/output.txt_adm | awk '{print NR " " $6}' > t06.txt - grep $3 $1/$2/output.txt_adm | awk '{print NR " " $6}' > t16.txt + grep $3 $1/results_ad/output_adm.txt | awk '{print NR " " $5}' > t05.txt + grep $3 $1/$2/output_adm.txt | awk '{print NR " " $5}' > t15.txt + grep $3 $1/results_ad/output_adm.txt | awk '{print NR " " $6}' > t06.txt + grep $3 $1/$2/output_adm.txt | awk '{print NR " " $6}' > t16.txt join t05.txt t15.txt > t5.txt join t06.txt t16.txt > t6.txt echo "-1" >> t5.txt @@ -304,7 +304,6 @@ command="$command --mods=../code" else command="$command --mods=../code_ad" - command="$command -adof=../../../tools/adjoint_options/adjoint_staf" fi if test "x$OPTFILE" != xNONE ; then command="$command --optfile=$OPTFILE" @@ -490,18 +489,22 @@ fi done else - files=`( cd ../input ; ls -1 *.bin | grep -v CVS )` - for i in $files ; do - if test ! -d "../input/"$i ; then - ln -sf "../input/"$i $i - fi - done files=`( cd ../input_ad ; ls -1 | grep -v CVS )` for i in $files ; do if test ! -d "../input_ad/"$i ; then ln -sf "../input_ad/"$i $i fi done + if test -d "../input" ; then + files=`( cd ../input ; ls -1 | grep -v CVS )` + for i in $files ; do + if test ! -d "../input/"$i ; then + if test ! -r $i ; then + ln -sf "../input/"$i $i + fi + fi + done + fi fi ) fi @@ -535,7 +538,7 @@ # if test "x$ADM" = x ; then # cp output.txt $CDIR"/output.txt" # else - # cp output.txt_adm $CDIR"/output.txt_adm" + # cp output_adm.txt $CDIR"/output_adm.txt" # fi if test -s STDERR.0000 ; then cp STDERR.0000 $CDIR"/STDERR.0000" ; fi return 0 @@ -636,12 +639,12 @@ scandirs() { - if [ $# -eq 0 ]; then - for arg in * ; do - test -d $arg/input && echo $arg - done + if [ $# -eq 1 ]; then + for arg in * ; do + test -d $arg/$1 && echo $arg + done else - echo $* + echo $* fi } @@ -804,7 +807,11 @@ fi if test "x$TESTDIRS" = x ; then - TESTDIRS=`scandirs` + if test "x$ADM" = xt ; then + TESTDIRS=`scandirs results_ad` + else + TESTDIRS=`scandirs results` + fi fi if test "x$OPTFILE" = xNONE -a "x$MITGCM_OF" != x ; then @@ -813,7 +820,7 @@ if test "x$ADM" = xt ; then EXECUTABLE="mitgcmuv_ad" - OUTPUTFILE="output.txt_adm" + OUTPUTFILE="output_adm.txt" else EXECUTABLE="mitgcmuv" OUTPUTFILE="output.txt" @@ -950,7 +957,7 @@ if test "x$ADM" = x ; then fout=$dir"/results/output.txt" else - fout=$dir"/results_ad/output.txt_adm" + fout=$dir"/results_ad/output_adm.txt" fi if test ! -r $fout ; then echo "can't read \"$fout\" -- skipping $dir"