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
Copy file name to clipboardExpand all lines: README.md
+8-1Lines changed: 8 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
1
# tensorflow-lite-rest-server
2
-
Expose tensorflow-lite models via a rest API, and currently object detection is supported. Can be hosted on any of the common platforms including RPi, linux desktop, Mac and Windows.
2
+
Expose tensorflow-lite models via a rest API, and currently object, face & scene detection is supported. Can be hosted on any of the common platforms including RPi, linux desktop, Mac and Windows.
3
3
4
4
## Setup
5
5
In this process we create a virtual environment (venv), then install tensorflow-lite [as per these instructions](https://www.tensorflow.org/lite/guide/python) which is platform specific, and finally install the remaining requirements. Note on an RPi (only) it is necessary to manually install pip3, numpy, pillow.
@@ -58,6 +58,13 @@ To detect faces:
58
58
curl -X POST -F image=@tests/faces.jpg 'http://localhost:5000/v1/vision/face'
59
59
```
60
60
61
+
To run the scene:
62
+
```
63
+
curl -X POST -F image=@tests/cat.jpg 'http://localhost:5000/v1/vision/scene'
64
+
or
65
+
curl -X POST -F image=@tests/dog.jpg 'http://localhost:5000/v1/vision/scene'
66
+
```
67
+
61
68
## Deepstack, Home Assistant & UI
62
69
This API can be used as a drop in replacement for [deepstack object detection](https://github.com/robmarkcole/HASS-Deepstack-object) and [deepstack face detection](https://github.com/robmarkcole/HASS-Deepstack-face) (configuring `detect_only: True`) in Home Assistant. I also created a UI for viewing the predictions of the object detection model [here](https://github.com/robmarkcole/deepstack-ui).
0 commit comments