cheaha_vessels_segment.sh 708 Bytes
Newer Older
Brent Womble's avatar
Brent Womble committed
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
#!/bin/bash
jobs=/data/user/bwomble/jobs_old_segment
sub_dir=/data/user/bwomble/Input_old_segment
mkdir $jobs

cd $sub_dir

for sub in 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20
do

#Create job script files
cat > $jobs/old_segment_$sub.sh <<EOF
#!/bin/bash

cd $sub_dir/$subject/

module load rc/matlab/R2013a
matlab -nodesktop -nosplash -r "cheaha_old_segment('$sub_dir','$sub')"

EOF
done

for sub in 01 02 03 04 05 06 07 08 09 10 11 12 13 14 15 16 17 18 19 20
do

#Submit jobs
pushd $jobs
echo "submitting segment job for $sub"
sbatch --job-name=old_segment_$sub --output=old_segment_$sub.txt --ntasks=1 --partition=long --mem-per-cpu=4096 --time=150:00:00 old_segment_$sub.sh 
popd

done