-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathrun.py
56 lines (40 loc) · 1.5 KB
/
run.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
44
45
46
47
48
49
50
51
52
53
54
55
56
import sys
import json
import os
sys.path.insert(0, 'src')
from etl import load_data
from eda import main_eda
from utils import convert_notebook
from compare import view_results
from evaluate import runtime_performance_eval
def main(targets):
data_config = json.load(open('config/data-params.json'))
eda_config = json.load(open('config/eda-params.json'))
comparison_config = json.load(open('config/comparison-params.json'))
evaluate_config = json.load(open('config/evaluate-params.json'))
test_config = json.load(open('config/test-params.json'))
if 'data' in targets:
load_data(**data_config)
if 'eda' in targets:
main_eda(**eda_config)
# Execute notebook, convert to HTML
convert_notebook(**eda_config)
if 'comparison' in targets:
view_results(**comparison_config)
if 'evaluate' in targets:
runtime_performance_eval(**evaluate_config)
if 'test' in targets:
load_data(**test_config)
main_eda(**eda_config)
convert_notebook(**eda_config)
view_results(**comparison_config)
runtime_performance_eval(**evaluate_config)
if 'all' in targets:
load_data(**data_config)
main_eda(**eda_config)
convert_notebook(**eda_config)
view_results(**comparison_config)
runtime_performance_eval(**evaluate_config)
if __name__ == '__main__':
targets = sys.argv[1:]
main(targets)