-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlaunch_benchmarks.sh
More file actions
executable file
·96 lines (86 loc) · 3.43 KB
/
launch_benchmarks.sh
File metadata and controls
executable file
·96 lines (86 loc) · 3.43 KB
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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
##################################################
# file: launch_benchmarks.sh
# author: Gael Marcadet <gael.marcadet@etu.univ-orleans.fr>
# description: Launch protocol experiment with configurations.
##################################################
# ================================================
# Set up parameters
# ================================================
CPU=8
REWARDS_NB_ITER=150
BENCHMARKS_NB_ITER=50
OUTPUT_DIRECTORY='output'
PLOTS_OUTPUT_DIRECTORY="$OUTPUT_DIRECTORY/plots/"
JESTER_REWARDS_OUTPUT_DIRECTORY="$OUTPUT_DIRECTORY/rewards/jester"
JESTER_BENCHMARKS_OUTPUT_DIRECTORY="$OUTPUT_DIRECTORY/benchmarks/jester"
MOVIE_LENS_REWARDS_OUTPUT_DIRECTORY="$OUTPUT_DIRECTORY/rewards/movie-lens"
MOVIE_LENS_BENCHMARKS_OUTPUT_DIRECTORY="$OUTPUT_DIRECTORY/benchmarks/movie-lens"
REWARDS_CONFIGS='configs/rewards_configs.csv'
BENCHMARKS_CONFIG='configs/benchmarks_configs.csv'
MOVIE_LENS_DATA="data/MovieLens.txt"
JESTER_DATA="data/JesterLarge.txt"
MOVIE_LENS_PARAMS="parameters/MovieLens.csv"
JESTER_PARAMS="parameters/JesterLarge.csv"
# ================================================
# Runs benchmarks on MovieLens
# ================================================
# Execute experiments with arguments
# note the -u command used to do not awaiting to write in stdin, stdout and stderr
python3 -u bench.py \
--output $MOVIE_LENS_BENCHMARKS_OUTPUT_DIRECTORY\
--data $MOVIE_LENS_DATA\
--configs $BENCHMARKS_CONFIG\
--nb_iterations $BENCHMARKS_NB_ITER\
--parameters $MOVIE_LENS_PARAMS\
--cpu $CPU\
--run
# ================================================
# Runs benchmarks on Jester
# ================================================
# Execute experiments with arguments
# note the -u command used to do not awaiting to write in stdin, stdout and stderr
python3 -u bench.py \
--output $JESTER_BENCHMARKS_OUTPUT_DIRECTORY\
--data $JESTER_DATA\
--configs $BENCHMARKS_CONFIG\
--nb_iterations $BENCHMARKS_NB_ITER\
--parameters $JESTER_PARAMS\
--cpu $CPU\
--run
# ================================================
# Runs rewards on MovieLens
# ================================================
# Execute experiments with arguments
# note the -u command used to do not awaiting to write in stdin, stdout and stderr
python3 -u bench.py\
--output $MOVIE_LENS_REWARDS_OUTPUT_DIRECTORY\
--data $MOVIE_LENS_DATA\
--configs $REWARDS_CONFIGS\
--nb_iterations $REWARDS_NB_ITER\
--parameters $MOVIE_LENS_PARAMS\
--standards_only\
--cpu $CPU\
--run
# ================================================
# Runs rewards on Jester
# ================================================
# Execute experiments with arguments
# note the -u command used to do not awaiting to write in stdin, stdout and stderr
python3 -u bench.py\
--output $JESTER_REWARDS_OUTPUT_DIRECTORY\
--data $JESTER_DATA\
--configs $REWARDS_CONFIGS\
--nb_iterations $REWARDS_NB_ITER\
--parameters $JESTER_PARAMS\
--standards_only\
--cpu $CPU\
--run
# ================================================
# Plots
# ================================================
python3 plot_bench.py \
--movie-lens-rewards $MOVIE_LENS_REWARDS_OUTPUT_DIRECTORY\
--movie-lens-benchmarks $MOVIE_LENS_BENCHMARKS_OUTPUT_DIRECTORY\
--jester-rewards $JESTER_REWARDS_OUTPUT_DIRECTORY\
--jester-benchmarks $JESTER_BENCHMARKS_OUTPUT_DIRECTORY\
--output $PLOTS_OUTPUT_DIRECTORY