source: branches/Mars_McMismatchStudy/qsub/FACT.sub_call_mc.sh@ 19902

Last change on this file since 19902 was 17986, checked in by ghughes, 10 years ago
batch scripts update
  • Property svn:executable set to *
File size: 853 bytes
Line 
1#!/bin/bash
2
3if [[ $# < 1 ]]
4then
5 echo ""
6 echo "FACT.sub_call_mc.sh <input dir> <output dir>"
7 echo ""
8 exit
9fi
10
11cd $MARSSYS
12
13INDIR=$1
14OUTDIR=$2
15
16TEMPFILE="temp.call.file"
17
18## TODO ths will need fixing
19ls $INDIR/cer* | head -n 1 > $TEMPFILE
20
21while read LINE
22do
23
24 INFILE=$LINE
25
26 NUMBER=`echo $LINE | sed s/cer/" "/g | gawk '{print $2}'`
27
28 QSUB=$MARSSYS"/batch/queue/FACT.qsub_call_mc_"$NUMBER".sh"
29 QSUBERR=$MARSSYS"/batch/queue/FACT.qsub_call_mc_"$NUMBER".err"
30 QSUBOUT=$MARSSYS"/batch/queue/FACT.qsub_call_mc_"$NUMBER".out"
31
32 sed -e "s|FFFFF|$INFILE|" \
33 -e "s|DDDDD|$OUTDIR|" $MARSSYS"/batch/FACT.qsub_call_mc.sh" > $QSUB
34
35 chmod +x $QSUB
36
37 qsub -q fact_medium -b yes -o $QSUBOUT -e $QSUBERR $QSUB
38 ##qsub -q test -b yes -o $QSUBOUT -e $QSUBERR $QSUB
39 ##qsub -b yes -o $QSUBOUT -e $QSUBERR $QSUB
40
41done <$TEMPFILE
42
43rm $TEMPFILE
Note: See TracBrowser for help on using the repository browser.