init
This commit is contained in:
30
{{cookiecutter.project_slug}}/Makefile
Normal file
30
{{cookiecutter.project_slug}}/Makefile
Normal file
@@ -0,0 +1,30 @@
|
||||
APP_NAME=ml_pipeline
|
||||
PYTHON=.venv/bin/python3
|
||||
INTERPRETER=/usr/bin/python3
|
||||
.PHONY: help test
|
||||
|
||||
|
||||
all: run
|
||||
|
||||
init: ## create a venv
|
||||
$(INTERPRETER) -m venv .venv
|
||||
|
||||
run: ## run the pipeline (train)
|
||||
$(PYTHON) -m $(APP_NAME) pipeline:train
|
||||
|
||||
data: ## download the mnist data
|
||||
$(PYTHON) -m $(APP_NAME) data:download
|
||||
# wget https://pjreddie.com/media/files/mnist_train.csv -O data/mnist_train.csv
|
||||
# wget https://pjreddie.com/media/files/mnist_test.csv -O data/mnist_test.csv
|
||||
|
||||
test:
|
||||
find . -iname "*.py" | entr -c pytest
|
||||
|
||||
serve:
|
||||
$(PYTHON) -m $(APP_NAME) app:serve
|
||||
|
||||
install:
|
||||
$(PYTHON) -m pip install -r requirements.txt
|
||||
|
||||
help: ## display this help message
|
||||
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
|
||||
Reference in New Issue
Block a user