-
Notifications
You must be signed in to change notification settings - Fork 1
/
run_reshape.sh
executable file
·78 lines (66 loc) · 1.83 KB
/
run_reshape.sh
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
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
make reshape
#define code<k>, code<k>[<d>]
code1=(NA NA NA n7k1d3-x3z3dx3dz3-0 n15k1d4-x8z6dx4dz4-0 n25k1d5-x13z11dx5dz5-0)
code2=(NA NA NA n11k2d3-x4z5dx3dz3-1 n18k2d4-x8z8dx4dz4-1 n27k2d5-x13z12dx5dz5-1)
code3=(NA NA NA n11k3d3-x4z4dx3dz3-0 n19k3d4-x9z7dx4dz4-0 n29k3d5-x13z13dx5dz5-0)
echo "The seed codes used to construct SPC: code<k>[<d>]"
for i in {3..5}; do echo code1$i, ${code1[$i]}; done;
for i in {3..5}; do echo code2$i, ${code2[$i]}; done;
for i in {3..5}; do echo code3$i, ${code3[$i]}; done;
mode=2 #0 for check; 1 for steane; 2 for simulating from file
date
#i for codeA
#for i in {3..5}
for i in {3,5}
do
#j for codeB
for j in {3,5,}
do
# break
if [ $i -le $j ]
then
codeA=${code1[$i]}
codeB=${code1[$j]}
title=none #1${i}1${j}
# 3 3 get wrong title 2 2
echo codeA: ${codeA}, codeB: ${codeB}, mode: ${mode}
output=${codeA}_${codeB}
# echo ${output}
# continue
# srun --time=24:00:00 -n 1 --cpus-per-task=32 \
srun --time=2-00:00:00 -p mini -n 1 --cpus-per-task=16 --qos=normal \
./reshape.out \
note=${output} \
title=${title} \
codeA_prefix=../data/CSS-Codes/run2/${codeA} \
codeB_prefix=../data/CSS-Codes/run2/${codeB} \
output=result/two_cycles/${output}.json \
num_cores=16 \
e_try=1000000 \
debug=0 \
mode=${mode} &
# output=result/unchecked/${output}.json \
# wait
# exit
fi
done
done
wait
echo done
exit
echo after exit
mode=1
output=tmp
srun --time=6:00:00 -p small -n 1 --cpus-per-task=16 \
./reshape.out \
note=${output} \
codeA_prefix=../data/CSS-Codes/run2/${code2[3]} \
codeB_prefix=../data/CSS-Codes/run2/${code2[3]} \
output=result/tmp/${output}.json \
num_cores=16 \
e_try=10000 \
debug=1 \
mode=${mode}
date
# e_try=1,000,000 to get smooth curve
# e_try=10,000 for quick result