An easy to use tensorflow image recognition api (still in development)
- Send a http multipart request with an image to tira
- Get a JSON response with the classified objects of the image
To improve further learning tira stores the images in folders based on the best classified result.
Send an image with to tira.
curl -i -F image=@blume.jpg http://localhost:8000/recognition/images
Response:
{"4": {"score": "0.0331435", "label": "snapdragon"}, "2": {"score": "0.139561", "label": "sweet william"}, "0": {"score": "0.507734", "label": "garden phlox"}
Tira works with a trained tensorflow model and simply uses the graph and labels files. So if you'd like to use your own trained model just overwrite the graph.pb and the labels.txt flies in the /tira/tira/apps/recognition/graph/ directory.
The easiest way to use tira is to pull the dockercontainer from dockerhub.
docker pull murthy10/tira
And finally run the container:
docker run -d -p 8000:8000 murthy10/tira:latest
To check if everything went okey navigate to http://localhost:8000
For further training of the neural network you can copy the images from tira to your local machine.
docker cp <containerId>:/tira/tira/media /host/path/target