-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathqRunMakeSmallTrees.csh
executable file
·63 lines (43 loc) · 1.8 KB
/
qRunMakeSmallTrees.csh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
#!/usr/bin/env csh
# make sure executable exists
set ExecPath = `pwd`
set Exec = "bin/MakeSmallerTrees"
# make sure executable exists
make $Exec || exit
set ResultDir = Data/SmallAuAu14
#set ResultDir = Data/Small_LowMid_Y14HT
set OutBase = Small
set TriggerName = HT2HT3
set noglob
set submitted=0
# set rerunlist = Rerun_${OutBase}_nolumi.txt
# rm -f $rerunlist
# foreach Files ( `find Data/P17id/AuAu_200_production_2014/HT/ -maxdepth 1 -name "*root" ` )
# set rerunlist = Rerun_${OutBase}_high.txt
# rm -f $rerunlist
# foreach Files ( `find Data/P17id/AuAu_200_production_high_2014/HT/ -maxdepth 1 -name "*root" ` )
# set rerunlist = Rerun_${OutBase}_mid.txt
# rm -f $rerunlist
# foreach Files ( `find Data/P17id/AuAu_200_production_mid_2014/HT/ -maxdepth 1 -name "*root" ` )
set rerunlist = Rerun_${OutBase}_low.txt
rm -f $rerunlist
foreach Files ( `find Data/P17id/AuAu_200_production_low_2014/HT/ -maxdepth 1 -name "*root" ` )
set FileBase = `basename $Files`
set OutName = ${ResultDir}/${OutBase}_${FileBase}
set LogFile = logs/MakeSmallerTrees_${OutBase}_${FileBase}.out
set ErrFile = logs/MakeSmallerTrees_${OutBase}_${FileBase}.err
set Args = ( $Files $OutName )
echo Submitting:
echo $Exec $Args
echo "Logging output to " $LogFile
echo "Logging errors to " $ErrFile
echo
# qsub -V -q erhiq -l mem=8gb -o $LogFile -e $ErrFile -- ${ExecPath}/qwrap.sh ${ExecPath} $Exec $Args
set qcommand = "qsub -V -q erhiq -l mem=2gb -W umask=0022 -r y -N SmallTrees -o $LogFile -e $ErrFile -- ${ExecPath}/qwrap.sh ${ExecPath} $Exec $Args"
set qresult=`$qcommand` || exit
echo $qresult
echo $qresult $qcommand >> $rerunlist
@ submitted = $submitted + 1
end
unset noglob
echo Submitted $submitted jobs to the grid.