整个工程已经上传到Github上了
https://github.com/xyc2690/Raspberry_ObjectDetection_Camera
环境准备:摄像头,OpenCV
首先在树莓派上安装最新的TensorFlow
https://github.com/lhelontra/tensorflow-on-arm/releases
下载SSDmobile模型
http://download.tensorflow.org/models/object_detection/ssdlite_mobilenet_v2_coco_2018_05_09.tar.gz
安装OpenCV,
只用python的话可以直接 pip install opencv-python
或者下载最新完整的OpenCV手动编译。
然后直接测试摄像头
python opencv_camera.py
修改参数,尝试tensorflow提供的ObjectDetectionAPI吧
TEST_CAM_ONLY = False