This post talks on how to host your trained machine learning model as a REST API so that we can use the model for prediction. This post considers python Flask for building REST endpoint and docker for containerizing.
You need knowledge of the following:
Table of contents
Why we need REST API for ML model?
Create a Machine Learning model using SKLearn
Package the model in to pickle file
Create FLASK API
Create a docker image
Run the container locally
Use REST end-point for prediction
1. Why we need REST API for ML model?
Once we train our machine learning model, we want the model…