Skip to content

In this project ,I created end-to-en object detection pipeline which takes image or video as a input and returns class names & object bounding box location and deployed using TF-serving & Flask

Notifications You must be signed in to change notification settings

saurabh241930/YOLO-Tensorflow_serving_Flask

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

YOLO-Tensorflow_serving_Flask

In this project ,I created end-to-en object detection pipeline which takes image or video as a input and returns class names & object bounding box location and deployed using TF-serving & Flask

Process / Steps

I converted weights file of keras darkflow tiny_yolo model into frozen pb format for tf serving and hosted in tf-serving docker and created external flask api backend which is using tf-serving REST api ,this backend takes base64 format of image and outputs a JSON output. (I’ve already converted weights & cfg file into using flow --model cfg/yolo.cfg --load bin/yolo.weights --savepb )

Setup :

First host a frozen model inside tf-serving docker

docker run -p 8501:8501 -v /home/sp/Documents/submission/built_graph/:/models/darkflow -e MODEL_NAME=darkflow -t tensorflow/serving

Install all required libraries

pip3 install -r requirements.txt

Then start Flask server

S:~/Documents/submission$ python3 app.py

Start sending the image as a client in base 64 format

S:~/Documents/submission$ python base64_request.py -i uploaded.jpg

API endpoint of this backend can be found at http://localhost:5000/yolo/predict/

Screenshot

Tensorflow Serving Docker

Starting flask server

Frontend Client

About

In this project ,I created end-to-en object detection pipeline which takes image or video as a input and returns class names & object bounding box location and deployed using TF-serving & Flask

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages