You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A simple web service classifying MNIST digits from HTTP POST requests built using Flask, TensorFlow and TensorLayer
The API uses HTTP POST operations to classify images of handwritten MNIST digits that is sent in the request. The single POST request available is /mnist/classify.
The API uses JSON for both requests and responses, see below for a detailed specification of the JSON data format.
Currently the API only supports 28 by 28 grayscale images and only handles a set maximum batch size of images in each
request (the max batch size is currently set as a constant in server_application.py).
JSON request format
The HTTP POST request /mnist/classify expects a JSON request. Example JSON data for the request:
For convinience pretrained model parameters for the convolutional neural network
is supplied in the model/ directory. However, the model can also be retrained by
running the train_model.py script in the model directory.
$python3 python3 train_model.py
About
A simple webservice API for classifying MNIST digits from HTTP POST requests built using Flask and TensorFlow/Layer