-
Notifications
You must be signed in to change notification settings - Fork 4
/
make_plots.py
43 lines (33 loc) · 987 Bytes
/
make_plots.py
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
"""generate all plots"""
import argparse
from utils.plots import *
def parse_args():
parser = argparse.ArgumentParser(description=__doc__)
parser.add_argument(
'--logs_dir',
help='directory containing the logs files',
type=str,
required=True
)
parser.add_argument(
'--history_dir',
help='directory containing the clients sampler history files',
type=str,
required=True
)
parser.add_argument(
'--save_dir',
help='directory to save all the plots',
type=str,
required=True
)
return parser.parse_args()
if __name__ == "__main__":
args = parse_args()
plot_all_logs(logs_dir=args.logs_dir, save_dir=args.save_dir)
plot_all_history(history_dir=args.history_dir, save_dir=args.save_dir)
plot_participation_heatmap(
history_dir=args.history_dir,
save_dir=args.save_dir
)
print(f"results are saved to {args.save_dir}")