In this project, I operationalized a pre-trained, sklearn
model, served out of a Python flask appapp.py
, that has been trained to predict housing prices in Boston according to features such as average rooms in a home, data about highway access, and teacher-to-pupil ratios.
I built, tested, deployed, and monitored the Machine Learning Microservice API through all phases of ML Ops pipeline. From
- Containerizing and deploying the Docker image by writing the Makefile and Dockerfile
- Running, testing, and debugging the application on a virtualized local machine
- Improving the log statements and uploading the image to DockerHub
- Configuring a local Kubernetes cluster and deploying it on minikube
- Setting up CICD pipeline with automated building, caching, and linting processes.
The project reinforced my knowledge cloud DevOps operation, and its files could be readily extended for use to other pre-trained machine learning deployment, such as those for image recognition and data labeling.
- Create a virtualenv and activate it
- Run
make install
to install the necessary dependencies
- Standalone:
python app.py
- Run in Docker:
./run_docker.sh
- Run in Kubernetes:
./run_kubernetes.sh
- Setup and Configure Docker locally
- Setup and Configure Kubernetes locally
- Create Flask app in Container
- Run via kubectl