-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
98 lines (84 loc) · 3.04 KB
/
Makefile
File metadata and controls
98 lines (84 loc) · 3.04 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
97
98
.PHONY: all clean scratch cl build stop up run
all:
make reports/iris_report.html
clean:
rm -f reports/results/figures/*.png
rm -f reports/results/metrics/*.csv
rm -f reports/results/models/*.pkl
rm -f data/raw/*.data
rm -f data/processed/*.csv
rm -f reports/*.pdf
rm -f reports/*.html
rm -rf reports/iris_report_files
@echo "All files deleted."
scratch:
make clean
python scripts/01data_import.py \
--url="https://archive.ics.uci.edu/static/public/53/iris.zip" \
--write_to=data/raw
python scripts/02validation_splitting.py \
--raw_data=data/raw/iris.data \
--data_to=data/processed
python scripts/03eda_plots.py \
--processed_training_data=data/processed \
--plot_to=reports/results/figures
python scripts/model.py \
--training_data=data/processed \
--model_to=reports/results/models
python scripts/05metrics.py \
--test_data=data/processed \
--model_from=reports/results/models \
--metrics_to=reports/results/metrics \
--plot_to=reports/results/figures
quarto render reports/iris_report.qmd
@echo "Output available at reports/"
reports/iris_report.html: reports/iris_report.qmd \
reports/results/metrics/metrics_summary.csv \
reports/results/figures/pairplot.png \
reports/results/figures/corr.png \
reports/results/figures/histplot.png \
reports/results/figures/confusion_matrix.png
quarto render reports/iris_report.qmd
@echo "Output available at reports/"
reports/results/metrics/metrics_summary.csv reports/results/figures/confusion_matrix.png: scripts/05metrics.py \
reports/results/models/tree_model.pkl \
data/processed/X_test.csv \
data/processed/y_test.csv
python scripts/05metrics.py \
--test_data=data/processed \
--model_from=reports/results/models \
--metrics_to=reports/results/metrics \
--plot_to=reports/results/figures
reports/results/models/tree_model.pkl: scripts/model.py \
data/processed/X_train.csv \
data/processed/y_train.csv
python scripts/model.py \
--training_data=data/processed \
--model_to=reports/results/models
reports/results/figures/pairplot.png reports/results/figures/corr.png reports/results/figures/histplot.png: scripts/03eda_plots.py \
data/processed/iris_train.csv
python scripts/03eda_plots.py \
--processed_training_data=data/processed \
--plot_to=reports/results/figures
data/processed/X_train.csv data/processed/y_train.csv data/processed/X_test.csv data/processed/y_test.csv: scripts/02validation_splitting.py \
data/raw/iris.data
python scripts/02validation_splitting.py \
--raw_data=data/raw/iris.data \
--data_to=data/processed
data/raw/iris.data: scripts/01data_import.py
python scripts/01data_import.py \
--url="https://archive.ics.uci.edu/static/public/53/iris.zip" \
--write_to=data/raw
cl:
conda-lock lock \
--file environment.yml \
-p linux-64 -p osx-64 -p osx-arm64 -p win-64 -p linux-aarch64
build:
docker build -t esteki/iris-ml-predictor:2.0.0 --file Dockerfile .
stop:
docker-compose stop
up:
make stop
docker-compose up
run:
make up