Minor changes
This commit is contained in:
@@ -2,26 +2,27 @@
|
|||||||
|
|
||||||
VENV_NAME?=env
|
VENV_NAME?=env
|
||||||
PYTHON=${VENV_NAME}/bin/python3
|
PYTHON=${VENV_NAME}/bin/python3
|
||||||
|
FILES=linear_regression.py prepare_train_model.py test_model.py
|
||||||
|
|
||||||
.DEFAULT: help
|
.DEFAULT: help
|
||||||
help:
|
help:
|
||||||
@echo "make env"
|
@echo "make env"
|
||||||
@echo " create and prepares the environment"
|
@echo " creates and prepares the environment"
|
||||||
@echo "make clean"
|
@echo "make clean"
|
||||||
@echo " clean the development environment"
|
@echo " clean the development environment"
|
||||||
@echo "make data"
|
@echo "make data"
|
||||||
@echo " download and unpack the data"
|
@echo " downloads and unpacks the data"
|
||||||
@echo "make lint"
|
@echo "make lint"
|
||||||
@echo " run pylint and mpy"
|
@echo " runs pylint and mpy"
|
||||||
|
|
||||||
data: images
|
data: images
|
||||||
images:
|
images:
|
||||||
wget https://s3.us-east-2.amazonaws.com/naturalimages02/images.tar.gz
|
wget https://s3.us-east-2.amazonaws.com/naturalimages02/images.tar.gz
|
||||||
tar -xzf images.tar.gz
|
tar -xzf images.tar.gz
|
||||||
|
|
||||||
env: $(VENV_NAME)/bin/activate images
|
env: $(VENV_NAME)/bin/activate data
|
||||||
$(VENV_NAME)/bin/activate:
|
$(VENV_NAME)/bin/activate:
|
||||||
test -d $(VENV_NAME) || python3 -m venv $(VENV_NAME)
|
test -d $(VENV_NAME) || python3 -m venv $(VENV_NAME)
|
||||||
${PYTHON} -m pip install -U pip
|
${PYTHON} -m pip install -U pip
|
||||||
${PYTHON} -m pip install --upgrade tensorflow
|
${PYTHON} -m pip install --upgrade tensorflow
|
||||||
${PYTHON} -m pip install keras
|
${PYTHON} -m pip install keras
|
||||||
@@ -31,11 +32,12 @@ $(VENV_NAME)/bin/activate:
|
|||||||
${PYTHON} -m pip install mypy
|
${PYTHON} -m pip install mypy
|
||||||
touch $(VENV_NAME)/bin/activate
|
touch $(VENV_NAME)/bin/activate
|
||||||
|
|
||||||
lint:
|
lint: env
|
||||||
${PYTHON} -m pylint --ignored-modules=tensorflow.keras linear_regression.py
|
${PYTHON} -m pylint --rcfile=pylintrc $(FILES)
|
||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -rf $(VENV_NAME)
|
rm -rf $(VENV_NAME)
|
||||||
|
rm -f data.csv
|
||||||
rm -rf images
|
rm -rf images
|
||||||
rm -f images.tar.gz
|
rm -f images.tar.gz
|
||||||
rm -f fine_tune.h5
|
rm -f fine_tune.h5
|
||||||
|
|||||||
Reference in New Issue
Block a user