17 |
|
import os |
18 |
|
|
19 |
|
## setup the output dir and input files |
20 |
< |
output = "Data" |
21 |
< |
inputlist = "config/input_Data.txt" |
20 |
> |
output = "Data_Run2010A-PromptReco_JSON_140183-140399" |
21 |
> |
inputlist = "config/input_140183-140399.txt" |
22 |
|
## the cut file (still needed...) |
23 |
|
settingfile = "config/cutFileExample.txt" |
24 |
|
## number of max jobs |
25 |
< |
ijobmax = 10 |
25 |
> |
ijobmax = 8 |
26 |
|
|
27 |
|
################################################ |
28 |
|
# to write on local disks |
79 |
|
outputfile = open(outputname,'w') |
80 |
|
outputfile.write('#!/bin/bash\n') |
81 |
|
outputfile.write('#$ -N '+output+'_'+str(ijob)+'\n') |
82 |
< |
outputfile.write('#$ -l s_rt=00:30:00,h_rt=01:00:00\n') |
82 |
> |
outputfile.write('#$ -l s_rt=01:30:00,h_rt=04:00:00\n') |
83 |
|
outputfile.write('#$ -q all.q\n') |
84 |
|
outputfile.write('#$ -cwd\n') |
85 |
< |
outputfile.write('#$ -o /shome/jueugste/CMSSW/CMSSW_3_5_6_7TeV/src/DiLeptonAnalysis/NTupleProducer/test/rootEWKanalyzer/'+output+'/log/\n') |
86 |
< |
outputfile.write('#$ -e /shome/jueugste/CMSSW/CMSSW_3_5_6_7TeV/src/DiLeptonAnalysis/NTupleProducer/test/rootEWKanalyzer/'+output+'/log/\n') |
85 |
> |
outputfile.write('#$ -o /shome/jueugste/CMSSW/CMSSW_3_6_1_patch2/src/DiLeptonAnalysis/NTupleProducer/test/rootEWKanalyzer/'+output+'/log/\n') |
86 |
> |
outputfile.write('#$ -e /shome/jueugste/CMSSW/CMSSW_3_6_1_patch2/src/DiLeptonAnalysis/NTupleProducer/test/rootEWKanalyzer/'+output+'/log/\n') |
87 |
|
|
88 |
|
outputfile.write('source /swshare/cms/cmsset_default.sh\n') |
89 |
< |
outputfile.write('cd /shome/jueugste/CMSSW/CMSSW_3_5_6_7TeV/src/DiLeptonAnalysis/NTupleProducer/test/rootEWKanalyzer\n') |
89 |
> |
outputfile.write('cd /shome/jueugste/CMSSW/CMSSW_3_6_1_patch2/src/DiLeptonAnalysis/NTupleProducer/test/rootEWKanalyzer\n') |
90 |
|
outputfile.write('eval `scramv1 runtime -sh`\n') |
91 |
|
outputfile.write('export LD_LIBRARY_PATH=/swshare/glite/d-cache/dcap/lib:$LD_LIBRARY_PATH\n') |
92 |
|
outputfile.write('./main '+inputfilename+' '+settingfile+' analyze/Analysis '+outputroot+output+'_'+str(ijob)+' '+output+"/log/cutEfficiencyFile_"+str(ijob)+"\n") |
98 |
|
|
99 |
|
## now submit the jobs... |
100 |
|
for ijob in range(ijobmax): |
101 |
– |
os.system('qsub '+output+'/src/submit_'+str(ijob)+'.src') |
101 |
|
os.system('echo qsub '+output+'/src/submit_'+str(ijob)+'.src') |
102 |
+ |
os.system('qsub '+output+'/src/submit_'+str(ijob)+'.src') |