-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrun_simulation.sh
executable file
·59 lines (49 loc) · 1.23 KB
/
run_simulation.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
#!/bin/bash
declare -a eviction_algos=(
#"random"
"belady"
#"cremebrulee-oracle"
#"cremebrulee"
#"cremebrulee --oracle"
#"popularity"
#"loadtime"
#"recent"
)
RNG_SEED=0
POLICY="cremebrulee-oracle"
WORKER_MEMORY=1024
cd ../src-simulator
if true ; then
echo "Generating workload"
(
cd ../src-workload
python -u parse_azure.py \
--rng_seed $RNG_SEED \
--num_minutes 1 \
--max_quantile 0.95 \
--remove_one_hit_wonders \
--downsample_events 0.1 \
--input_models_file ../measurements/models.short.json \
--keep_real_models \
)
else
echo "Skipping workload generation"
fi
common_args="
--run_series $(git rev-parse --verify HEAD | head -c 7)${additional_tags}
--rng_seed $RNG_SEED
--workload_file ../workload/workload.txt
--model_description_file ../workload/models.json
--num_workers_to_add 1
--results_dir results
--cost_function cost-direct
--worker_memory ${WORKER_MEMORY}
"
echo "Policy under test: $POLICY $WORKER_MEMORY"
python simulation.py \
$common_args \
--model_eviction_algorithm $POLICY \
--run_identifier ${POLICY}.${WORKER_MEMORY}gb \
2>&1 #/dev/null"
echo "-----------------------"
exit 0