May 2020
Intermediate to advanced
404 pages
10h 52m
English
In the preceding example, we will extend the flask import statement to import an additional method, request, which will allow us how to handle the POST requests made to the server. The line then looks as follows:
from flask import Flask, request
We then import the modules necessary for the reading and storing of the images. Also, the numpy module is imported as in the following code snippet:
from scipy.misc import imread, imresizeimport numpy as np
Finally, we import the model_from_json() method of the Keras module to load the saved model files. We then import tensorflow, as Keras is dependent on it to execute:
from keras.models import model_from_jsonimport tensorflow as tf
Next, we load data into the script ...
Read now
Unlock full access