/[MITgcm]/mitgcm.org/front_content/make_summary
ViewVC logotype

Contents of /mitgcm.org/front_content/make_summary

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.51 - (show annotations) (download)
Sat Jun 20 15:57:32 2009 UTC (16 years, 1 month ago) by jmc
Branch: MAIN
Changes since 1.50: +19 -35 lines
update list of tested platforms

1 #! /usr/bin/env bash
2
3 # $Header: /u/gcmpack/mitgcm.org/front_content/make_summary,v 1.50 2009/06/15 23:44:46 jmc Exp $
4 #
5 # The purpose of this script is to create HTML summaries of the
6 # directories produced by the "parse_emails" script.
7
8
9 usage()
10 {
11 echo
12 echo "Usage: $0 [OPTIONS]"
13 echo
14 echo "where possible OPTIONS are:"
15 echo " (-help|-h) print usage"
16 echo " (-date |-d )PERIOD run for PERIOD=\"YYYY_MM\""
17 echo " [def=\"$PERIOD\"]"
18 echo
19 exit 1
20 }
21
22 CURR_PER=`date +%Y`"_"`date +%m`
23 # defaults
24 PERIOD=$CURR_PER
25
26 # Parse options
27 ac_prev=
28 for ac_option ; do
29
30 # If the previous option needs an argument, assign it.
31 if test -n "$ac_prev"; then
32 eval "$ac_prev=\$ac_option"
33 ac_prev=
34 continue
35 fi
36
37 ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
38
39 case $ac_option in
40
41 -help | --help | -h | --h)
42 usage ;;
43
44 -date | --date | -d | --d)
45 ac_prev=PERIOD ;;
46 --date=* | -date=*)
47 PERIOD=$ac_optarg ;;
48
49 *)
50 echo "Error: don't understand argument \"$ac_option\""
51 usage
52 ;;
53
54 esac
55
56 done
57
58 #INDIR="/net/orwell/export/export-9/mitgcm-testing/results/$PERIOD"
59 #OUTDIR="/home/jmc/mitgcm/test_web/summary"
60 INDIR="/u/u0/httpd/html/testing/results/$PERIOD"
61 OUTDIR="/u/u0/httpd/html/testing/summary"
62
63 OUTFILE=$OUTDIR"/output_"$PERIOD".html"
64 res_url="http://mitgcm.org/testing/"
65
66 # Create the links in $OUTFILE :
67 echo "Creating the \"latest\" file for each machine: "
68 the_date=`date`
69 cat > $OUTFILE << EOF
70 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
71 "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
72
73 <html xmlns="http://www.w3.org/1999/xhtml">
74 <head>
75 <title>MITgcm testing summary</title>
76 <meta name="author" content="Ed Hill" />
77
78 <!-- <base href="http://mitgcm.org/testing/summary/" /> -->
79
80 <!-- Hinting for menu generation -->
81 <meta name="add_name_0" content="Testing" />
82 <meta name="add_name_1" content="" />
83 <meta name="add_name_2" content="" />
84 <meta name="add_title" content="Testing" />
85 <!-- Hinting for menu generation -->
86
87 </head>
88 <body>
89 <p>The MITgcm model is tested
90 (compiled and run) in an automated fashion on a varirety of
91 different machines. The following is a summary of the MITgcm
92 verification suite for the time period: <b>$PERIOD</b>.</p>
93
94 <p>The machine naming scheme is:<br /></p>
95 <table align="center" cellpadding="0" border="0">
96 <tr bgcolor="#00cccc"> <td><b>Machine Type</b></td> <td><b>Nickname</b></td>
97 <td><b>Notes</b></td> </tr>
98
99 <tr bgcolor="#bbddff">
100 <td>Intel P4</td> <td>"faulks"</td> <td>Fedora Core 6 </td> </tr>
101 <tr bgcolor="#bbffdd">
102 <td> Intel P4 </td> <td>"meander"</td> <td>Fedora Core 7 </td> </tr>
103 <tr bgcolor="#bbddff">
104 <td> Intel P4 </td> <td>"lagoon"</td> <td>Fedora 8 </td> </tr>
105 <tr bgcolor="#bbffdd">
106 <td> Opteron Barcelona </td> <td>"harbor"</td> <td>Ubuntu 8.04 LTS (x86_64)</td> </tr>
107 <tr bgcolor="#bbddff">
108 <td> Intel Xeon (Woodcrest) </td> <td>"dickens"</td> <td>Fedora 10 (x86_64)</td> </tr>
109 <tr bgcolor="#bbffdd">
110 <td> Intel Core 2 duo </td> <td>"danton"</td> <td>Fedora 8 (x86_64)</td> </tr>
111
112 <tr bgcolor="#bbddff">
113 <td> <a href="http://acesgrid.org">ACESgrid Dell Xeon</a> </td>
114 <td>"aces"</td><td>Fedora Core 2</td> </tr>
115
116 <tr bgcolor="#bbffdd">
117 <td><a href="http://www.darwinproject.mit.edu/wiki/">Intel Xeon (Woodcrest) cluster</a>
118 </td> <td>"beagle"</td><td>Rocks 5.2 (x86_64)</td> </tr>
119
120 <!--
121 <tr bgcolor="#bbffdd">
122 <td> Intel P3/P4 Beowulf </td> <td>"myrinet"</td>
123 <td><a href="http://mitgcm.org/projects/MITGCM_CLUSTER/">MITgcm cluster
124 facility </a></td> </tr>
125 <tr bgcolor="#bbddff">
126 <td>Alpha cluster</td> <td>"halem"</td>
127 <td><a href="http://nccstag.gsfc.nasa.gov/halem/quickstart_halem.html">
128 NASA NCCS Halem</a></td> </tr>
129 <tr bgcolor="#bbffdd">
130 <td> SGI Origin 2000 </td> <td>"hopper"</td>
131 <td><a href="http://www.nas.nasa.gov/User/Systemsdocs/O2K/o2k.html">
132 NAS SGI Origin 2000 </a></td> </tr>
133 <tr bgcolor="#bbddff">
134 <td> SGI Origin 3000</td><td>"lomax"/"turing"</td>
135 <td><a href="http://www.nas.nasa.gov/User/Systemsdocs/O3K/o3k.html">
136 NAS SGI Origin 3000 </a></td> </tr>
137 -->
138
139 <tr bgcolor="#bbddff">
140 <td> SGI Altix Cluster </td> <td>"columbia"</td>
141 <td><a href="http://www.nas.nasa.gov/Resources/Systems/columbia.html">
142 NAS Columbia </a></td> </tr>
143
144 <tr bgcolor="#bbffdd">
145 <td> IBM POWER4 SP </td> <td>"edvir"</td> <td> AIX 5.2 </td> </tr>
146 <tr bgcolor="#bbddff">
147 <td> IBM POWER5+ SP </td> <td>"blueice"</td>
148 <td><a href="http://www.scd.ucar.edu/computers/blueice/">NCAR Blueice
149 </a></td> </tr>
150
151 <tr bgcolor="#bbffdd">
152 <td> AMD Opteron </td> <td>"starp"</td> <td>SuSE SLES 10 (AMD64)</td> </tr>
153
154 <tr bgcolor="#bbddff">
155 <td> Sun UltraSparc IV </td> <td>"solssrv"</td> <td>Solaris 10</td> </tr>
156 <!--
157 <tr bgcolor="#bbffdd">
158 <td> Sun UltraSparc IV </td> <td>"model"</td> <td>Solaris 9</td> </tr>
159 -->
160 <tr bgcolor="#bbffdd">
161 <td> NEC SX-8 </td> <td>"sx8"</td> <td>Super-UX </td> </tr>
162 <tr bgcolor="#bbddff">
163 <td> Cray XD1 (AMD Opteron) </td> <td>"xd1"</td>
164 <td>Cray HPC enhanced Linux 2.6.5 </td> </tr>
165 <tr bgcolor="#bbffdd">
166 <td> PowerPC970MP cluster </td> <td>"bigred"</td>
167 <td>SuSE SLES 9 (PPC) </td> </tr>
168
169 <!--
170 <tr bgcolor="#bbffdd">
171 <td><a href="http://www.testdrive.hp.com/current.shtml"> HP test-drive </a>
172 (Pentium III) </td> <td>"td152"</td> <td> FreeBSD 6.2 </td> </tr>
173 <tr bgcolor="#bbddff">
174 <td><a href="http://www.testdrive.hp.com/current.shtml"> HP test-drive </a>
175 (Itanium II) </td> <td>"td187"</td> <td>SuSE SLES 10 </td> </tr>
176 <tr bgcolor="#bbffdd">
177 <td><a href="http://www.testdrive.hp.com/current.shtml"> HP test-drive </a>
178 (PA-RISC 8900) </td> <td>"td191"</td> <td> HP-UX 11i 11.11 </td> </tr>
179 <tr bgcolor="#bbddff">
180 <td><a href="http://www.testdrive.hp.com/current.shtml"> HP test-drive </a>
181 (Itanium II) </td> <td>"td194"</td> <td> HP-UX 11i v3 </td> </tr>
182 <tr bgcolor="#bbffdd">
183 -->
184
185 <!--
186 <tr bgcolor="#bbddff"> <td> </td> <td>""</td>
187 <td></td> </tr>
188 -->
189
190 </table>
191
192 <p><br />
193 The complete output for the verification runs can be found in
194 <a href="http://mitgcm.org/testing/summary/">the summary pages</a>
195 and the <a href="http://mitgcm.org/testing/results/">testing archives</a>.
196 The latest reports are:</p>
197 <table align="center" cellpadding="0" cellspacing="0" border="0" width="95%">
198 <tr bgcolor="#00cccc">
199 <td height="0"> <b>Nickname</b> </td>
200 <td> <b>OPTFILE Name</b> </td>
201 <td> <b>Type</b> </td>
202 <td> <b>Date</b> </td>
203 <td> <b>Summary</b> </td>
204 <td> <b>Ratio</b> </td>
205 </tr>
206
207 EOF
208
209 color="#bbffdd"
210 ncolor="#bbddff"
211
212 MACHINES="faulks meander lagoon harbor dickens danton aces"
213 MACHINES="$MACHINES beagle columbia edvir rays solssrv solasrv sx8 xd1"
214 MACHINES="$MACHINES bigred starp"
215
216 ( cd $INDIR ; ls -1 -t */summary.txt | sed 's/\/summary.txt//' ) > ./dir_all
217
218 MALL=`cat ./dir_all | sed -e 's|_| |g' | awk '{print $2}' | sort | uniq`
219 for madd in $MALL ; do
220 present=0
221 for m in $MACHINES ; do
222 echo $madd | grep $m > /dev/null 2>&1
223 RETVAL=$?
224 test $RETVAL = 0 && present=1
225 continue
226 done
227 test $present = 0 && MACHINES="$MACHINES $madd"
228 done
229 #MACHINES="faulks"
230
231 for mname in $MACHINES ; do
232
233 echo " $mname"
234
235 dir_list=`grep $mname ./dir_all`
236 echo -n "" > ./mlist
237
238 for i in $dir_list ; do
239
240 dir=$INDIR"/"$i
241 OPTFILE=
242 if test -r $dir/summary.txt ; then
243 comm=`grep 'OPTFILE=' $dir/summary.txt`
244 eval $comm
245 OPTFILE=${OPTFILE##*/}
246 fi
247 if test "x$OPTFILE" = x -a -r "$dir/genmake_state" ; then
248 comm=`grep 'OPTFILE=' $dir/genmake_state 2>/dev/null`
249 eval $comm
250 OPTFILE=${OPTFILE##*/}
251 fi
252 if test "x$OPTFILE" = x ; then
253 comm=`grep '^# OPTFILE=' $dir/*/Makefile* 2>/dev/null | head -1`
254 comm=${comm##*#}
255 eval $comm
256 OPTFILE=${OPTFILE##*/}
257 fi
258 if test "x$OPTFILE" = x ; then
259 OPTFILE="not_explicitly_specified"
260 fi
261
262 ADJOINT=
263 RESTART=0
264 NOI3E=0
265 MTH=0
266 if test -r $dir/summary.txt ; then
267 comm=`grep 'ADJOINT=true' $dir/summary.txt 2>/dev/null`
268 eval $comm
269 RESTART=`grep -c 'test 2+2=4 summary' $dir/summary.txt`
270 NOI3E=`grep -c "^run: .*testreport.* '*-noieee'* " $dir/summary.txt`
271 MTH=`grep -c "^run: .*testreport.* -mth " $dir/summary.txt`
272 fi
273 if test "x$RESTART" = x0 ; then
274 kind="forward"
275 test "x$ADJOINT" = xtrue && kind="adjoint"
276 else
277 kind="restart"
278 fi
279 if test "x$NOI3E" = x1 ; then
280 OPTFILE="${OPTFILE}.noieee"
281 fi
282 if test "x$MTH" = x1 ; then
283 yy=`echo $OPTFILE | grep -c 'mth$'`
284 if test $yy = 0 ; then OPTFILE="${OPTFILE}+mth" ; fi
285 fi
286
287 t_pass="--"
288 t_tot="--"
289 if test -r $dir/summary.txt ; then
290 grep '^[YN] [YN] [YN] [YN]' $dir/summary.txt > ./all_tests 2>/dev/null
291 t_tot=`cat ./all_tests | wc -l | sed -e 's| ||g'`
292 t_pass=`grep '^Y Y Y Y' ./all_tests | grep 'pass ' | wc -l | sed -e 's| ||g'`
293 fi
294 rm -f ./all_tests
295 # echo "${dir##*/} : $t_pass out of $t_tot"
296
297 tokens=`echo $i | sed -e 's|_| |g'`
298 echo "" > ./ms_tmp
299 for tok in $tokens ; do
300 echo $tok >> ./ms_tmp
301 done
302 DAY=`cat ./ms_tmp | awk '(length($1)==8 && substr($1,0,3)=="200")'`
303 rm -f ./ms_tmp
304
305 echo "$OPTFILE$kind $DAY $OPTFILE $kind $i $t_pass:$t_tot" >> ./mlist
306
307 done
308
309 # helpful for debugging
310 # cat ./mlist
311
312 # Do we have any data? If so, create the latest pointer.
313 num=`wc -l ./mlist | awk '{print $1}'`
314 if test $num -gt 0 ; then
315
316 # swap colors
317 ctmp=$color
318 color=$ncolor
319 ncolor=$ctmp
320
321 keys=`cat ./mlist | cut -d " " -f 1 | sort | uniq`
322
323 for key in $keys ; do
324 tline=`grep "^$key " ./mlist | head -1`
325 ratio=`echo $tline | cut -d " " -f 6`
326 ldir=`echo $tline | cut -d " " -f 5`
327 kind=`echo $tline | cut -d " " -f 4`
328 optf=`echo $tline | cut -d " " -f 3`
329 DAY=`echo $tline | cut -d " " -f 2`
330 URL="results/$PERIOD/$ldir"
331 cat <<EOF >>$OUTFILE
332 <tr bgcolor="$color">
333 <td height="0"> $mname </td>
334 <td> $optf </td>
335 <td> $kind </td>
336 <td> <a href="$res_url$URL">$DAY</a> </td>
337 <td> <a href="$res_url$URL/summary.txt"> summary.txt </a> </td>
338 <td> $ratio </td>
339 </tr>
340 EOF
341 done
342 fi
343
344 done
345
346 cat >> $OUTFILE << EOF
347 <tr bgcolor="#00cccc">
348 <td height="0" colspan="6" align="center" >This table generated on: $the_date</td>
349 </tr>
350
351 </table>
352
353 <p>Examples of the scripts used for these testing runs can be obtained from: <a
354 href="http://mitgcm.org/cgi-bin/viewcvs.cgi/MITgcm/tools/example_scripts/">
355 MITgcm/tools/example_scripts</a>.</p>
356
357
358 </body>
359 </html>
360
361 EOF
362
363 rm -f ./dir_all ./mlist
364
365 #- put the file in place
366 chgrp gcmpack $OUTFILE
367 chmod 664 $OUTFILE
368 LATEST=$OUTDIR"/latest_"$PERIOD".html"
369 mv -f $OUTFILE $LATEST
370
371 if test "x$PERIOD" = "x$CURR_PER" ; then
372 cp $LATEST ./testing.xml
373 (
374 cd $OUTDIR
375 rm -f latest.html
376 ln -s $LATEST latest.html
377 )
378 fi

  ViewVC Help
Powered by ViewVC 1.1.22