runOFI.sh 1.34 KB
Newer Older
1
2
#!/bin/bash

3
4
5
6
7
scriptDir="$(dirname "$0")"
source $scriptDir/config.txt
dirM="${dirCG}"
export dirCG

8
matrix="Queen_4147.rb"
9
#matrix="audikw_1.rb"
10
#matrix="bcsstk01.rsa"
11

12
procs=(2 10 20 40 80 120 160)
13
14
15
msm=(0 1)
mss=(1 2)
mrm=(0 1)
16
is_syncs=(1 0)
17
18
19
20
21
qty=1
if [ $# -ge 1 ]
then
  qty=$1
fi
22
23
24
25
26

echo $matrix
for proc in "${procs[@]}"
do
  echo "------------------------------------------run np=$proc next=0"
27
  for proc_c in "${procs[@]}"
28
  do
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
    if [ $proc -ne $proc_c ]
    then

      max_numP=$proc
      if [ "$proc_c" -gt "$proc" ];
      then
        max_numP=$proc_c
      fi
      node_qty=$(($max_numP / 20))
      if [ $node_qty -eq 0 ]
      then
        node_qty=1
      fi

      for sm_type in "${msm[@]}"
44
      do
45
46
47
48
49
50
        for rm_type in "${mrm[@]}"
        do
          for is_sync in "${is_syncs[@]}"
          do
            if [ $is_sync -eq 1 ] # Matrix is send syncrhonously
            then
51
              sbatch -p P1 -N $node_qty $dirCG/Exec/generalRun.sh $proc $dirM$matrix $proc_c $sm_type 1 $rm_type 1 $is_sync $qty
52
53
54
  	    else # Matrix is send asyncrhonously
              for ss_type in "${mss[@]}"
              do
55
                sbatch -p P1 -N $node_qty $dirCG/Exec/generalRun.sh $proc $dirM$matrix $proc_c $sm_type $ss_type $rm_type $ss_type $is_sync $qty
56
57
58
59
	      done
 	    fi
          done
        done
60
      done
61
    fi
62
63
64
65
  done
done

echo "End"