-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathmake_simulated_data.sh
More file actions
49 lines (42 loc) · 1005 Bytes
/
make_simulated_data.sh
File metadata and controls
49 lines (42 loc) · 1005 Bytes
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
#!/bin/bash
set -euo pipefail
PROTDIR=~/work/pearsim
INDIR=/tmp
PARALLEL=40
function make_simulated_data {
mkdir -p $INDIR
for K in 3 10 30 100; do
for S in 1 3 10 30 100; do
for T in 50 200 1000; do
for M_per_cluster in 10 20 100; do
for G_frac in 0 0.01 0.1 1; do
for run in $(seq 1); do
M=$(echo "$K * $M_per_cluster" | bc)
G=$(echo "(($G_frac * $M) + 0.5) / 1" | bc)
jobname="sim_K${K}_S${S}_T${T}_M${M}_G${G}_run${run}"
(
echo "python3 $PROTDIR/make_simulated_data.py" \
"--write-clusters" \
"--write-numpy $INDIR/$jobname.truth.npz" \
"-K $K" \
"-S $S" \
"-T $T" \
"-M $M" \
"-G $G" \
"$INDIR/$jobname.truth.pickle" \
"$INDIR/$jobname.params.json" \
"$INDIR/$jobname.ssm" \
"> $INDIR/$jobname.stdout" \
"2>$INDIR/$jobname.stderr" \
)
done
done
done
done
done
done #| parallel -j$PARALLEL --halt 1
}
function main {
make_simulated_data
}
main