Tutorial – Deploying a pretrained model using Flask
In the previous example of creating a Flask application, we saw how we can make use of the application in conjunction with a predictive model to deploy a solution to our end users. However, the model that we deployed was an out-of-the-box solution and not a model we developed ourselves. In this section, we will once again deploy a model within a Flask application; however, we use a model based on the cancer dataset we saw in Chapter 5, Understanding Machine Learning.
If you recall, the main idea behind this model was to take in a number of measurements for a given tumor, and based on those measurements, determine what the diagnosis will likely be, resulting in either Malignant
or Benign
. Within this application, we will enable users to interact with a trained model and enter measurements that the model will use to make a prediction. With this in mind, let's get started!
In the same way as before, go ahead and add...