17 if [ ! -f CrombieSlimmingConfig.sh ]
20 echo
"CrombieSlimmingConfig.sh isn't here." 21 echo
"You should probably go somewhere else." 29 if [
"$CMSSW_BASE" =
"" ]
32 echo
"Require you to be cmsenv somewhere" 39 logFile=$(pwd)/LxbatchFileChecks.log
49 submitLog=
"Ran crombie submitlxbatch$sub at "$(date -u)
50 export subLogCharNum=${
51 delim=$(perl -e
'print "=" x $ENV{'subLogCharNum
'}';)
53 echo
"$delim" >> $logFile
54 echo
"$submitLog" >> $logFile
55 echo
"$delim" >> $logFile
64 source CrombieSlimmingConfig.sh
68 echo
"${CrombieFilesPerJob:?}" > /dev/null
69 echo
"${CrombieQueue:?}" > /dev/null
70 echo
"${CrombieEosDir:?}" > /dev/null
71 echo
"${CrombieTempDir:?}" > /dev/null
72 echo
"${CrombieFullDir:?}" > /dev/null
73 echo
"${CrombieSlimmerScript:?}" > /dev/null
74 echo
"${CrombieJobScriptList:?}" > /dev/null
75 echo
"${CrombieCheckerScript:?}" > /dev/null
77 export haddFile=$CrombieTempDir/myHadd.txt
79 if [
"$CrombieNBatchProcs" =
"" ]
82 if [
"$CrombieQueue" =
"2nw4cores" ]
97 if [
"$fresh" !=
"resub" -a
"$fresh" !=
"hadd" ]
100 crombie dumpfilelist eos
105 echo
"Crashed while dumping file list." 114 if [
"$fresh" !=
"hadd" ]
117 rootNames=$(ls $CrombieTempDir/$CrombieFileBase\_*_*.txt | sed
's/.txt//')
119 for outFile
in $rootNames
122 if [ ! -f $outFile.root ]
125 echo
"Making: $outFile" 126 command=
"bsub -q $CrombieQueue -n $CrombieNBatchProcs -o bout/out_$(date +%y%m%d)_$(basename $outFile)_%J.log crombie dojob $outFile" 128 if [
"$fresh" =
"test" ]
146 echo
"Going directly to hadd step." 150 if [
"$ranOnFile" -eq 0 ]
153 echo
"${CrombieNLocalProcs:?}" > /dev/null
154 cat $haddFile | xargs -n2 -P$CrombieNLocalProcs crombie hadd
155 echo
"All files merged!"