ViewVC Help
View File | Revision Log | Show Annotations | Root Listing
root/cvsroot/UserCode/Jeng/tools/make_html1.csh
Revision: 1.4
Committed: Wed Nov 17 01:13:54 2010 UTC (14 years, 5 months ago) by jengbou
Content type: application/x-csh
Branch: MAIN
CVS Tags: gregj-20110224, gregj-20110223-v1, gregj-20110223, gregj-20110205, gregj-20110114, gregj-20110107, gregj-20101223, gregj-20101212, gregj-20101211, gregj-20101210-new, gregj-20101210, gregj-20101121, HEAD
Changes since 1.3: +22 -21 lines
Log Message:
update

File Contents

# User Rev Content
1 jengbou 1.1 #! /bin/tcsh
2     ## need make_table0.py and make_table1.py
3     if ( ! `klist |& grep -c "afs@FNAL.GOV"`) then
4     echo "No afs! Initializing..."
5     kinit -A -f jengbou@FNAL.GOV
6     aklog -cell fnal.gov -k FNAL.GOV
7     else
8     echo "Starting job"
9    
10 jengbou 1.4 set lint = ("34.72pb-1")
11     set njets = ("Incl1" "Incl2" "Incl3" "Incl4" "Excl1" "Excl2" "Excl3")
12     set categories = ("Data_MC" "Data_RelIsogt0p1ORD0gt0p02" "Data_RelIsogt0p15lt0p7ORD0gt0p025")
13 jengbou 1.2 set selects = ("Sel0" "Sel5")
14 jengbou 1.4 # set jetcolls = ("Calo" "JPT" "PF")
15     set jetcolls = ("PF")
16     set suffix = ("")
17 jengbou 1.3 set baseDir = "/Users/jengbou/Desktop/TopWork/Analysis/CMSSW_3_8_4/Results_${lint}"
18 jengbou 1.1
19 jengbou 1.2 foreach jetcol ($jetcolls)
20 jengbou 1.1
21 jengbou 1.4 set publishdir1 = "~/home/www/IKS/Results_${lint}_${jetcol}${suffix}"
22     set publishdir2 = "~/home/www/IKS/Results_${lint}_${jetcol}_KSopt${suffix}"
23 jengbou 1.1
24 jengbou 1.2 mkdir -p $publishdir1
25     mkdir -p $publishdir2
26     mkdir -p $baseDir
27     mkdir -p ${baseDir}_tmp
28    
29     python make_table0.py ${baseDir}_tmp/ $categories > ! tmp0.log
30     foreach selec ($selects)
31 jengbou 1.4 cat ${baseDir}_tmp/Summary_Results0.txt > ${selec}${suffix}/index.html
32     cat ${baseDir}_tmp/Summary_Results0.txt > ${selec}_KSopt${suffix}/index.html
33 jengbou 1.2 set idx = 1
34    
35     echo "Making table for ${selec}"
36 jengbou 1.4 mkdir -p $publishdir1/${selec}
37     mkdir -p $publishdir2/${selec}
38     mkdir -p ${selec}${suffix}
39     mkdir -p ${selec}_KSopt${suffix}
40 jengbou 1.2
41     foreach njet ($njets)
42 jengbou 1.4 python make_table1.py ${baseDir}_${njet}${suffix}/ ${selec}_${jetcol} ${njet} $categories > ! tmp1.log
43     cat ${baseDir}_${njet}${suffix}/Summary_Results1.txt >> ${selec}${suffix}/index.html
44 jengbou 1.2
45 jengbou 1.4 python make_table1.py ${baseDir}_${njet}_KSopt${suffix}/ ${selec}_${jetcol} ${njet} $categories > ! tmp2.log
46     cat ${baseDir}_${njet}_KSopt${suffix}/Summary_Results1.txt >> ${selec}_KSopt${suffix}/index.html
47 jengbou 1.2
48     @ idx++
49    
50     end
51 jengbou 1.4 echo "</table>" >> ${selec}${suffix}/index.html
52     echo "</table>" >> ${selec}_KSopt${suffix}/index.html
53     cp ${selec}${suffix}/index.html $publishdir1/${selec}/index.html
54     cp ${selec}_KSopt${suffix}/index.html $publishdir2/${selec}/index.html
55 jengbou 1.1 end
56 jengbou 1.2 rm -rf ${baseDir}_tmp
57     rm -f tmp*.log
58 jengbou 1.1 end
59    
60     endif