-
Notifications
You must be signed in to change notification settings - Fork 0
/
exps.fish
executable file
·57 lines (40 loc) · 1.13 KB
/
exps.fish
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
#!/usr/bin/env fish
# Setup
# =====
set timeLimit 600
set timeGiven 610
set killTime 620
#set -l queries 10 11 12 13 14 15 16 17 20 21 22 23 24 25 30 31 32 # All queries
set -l queries 10 11 12 13 14 20 22 23 24 30 32 # Selected queries
set -l poolSizes 1 10 20 40
#set -l poolSizes 1
set -l algorithms "AStar" "Dijkstra" "DFS"
#set -l algorithms "AStar"
set -l weights 1
# Run experiments
# ===============
# Move old data in bench/last/ to bench/old/
echo mkdir -p bench/old
mkdir -p bench/old
mv bench/last/* bench/old/
set benchDir "bench/"(hostname)"-"(date -Iseconds)
for p in $poolSizes
for q in $queries
for w in $weights
for a in $algorithms
notify-send -t 2000 "Running q$q k=$p $a"
timeout --kill-after $killTime $timeGiven ./run.py --time $timeLimit --alg=$a -w $w -q $q --pool-size $p $argv
end
end
end
end
# Move all the output to the new directory
mv bench/last/ $benchDir
# Run analysis
# ============
if xset -q > /dev/null ^ /dev/null; and ./analyze.fish $benchDir
echo "Graphs ready"
xdg-open "$benchDir"
else
echo "Please run ./analyze.fish $benchDir/*/*/*"
end