TensorFlow Lite - 人物侦测
材料准备
AmebaD [AMB21 / AMB22 / AMB23 / BW16] x 1
Arducam Mini 2MP Plus OV2640 SPI 摄像机模组 x 1
LED x 3
范例说明
流程
从以下网址下载TensorFlow Lite for Microcontrollers的Ameba版本 https://github.com/ambiot/ambd_arduino/tree/master/Arduino_zip_libraries。
请按照以下说明进行安装操作 https://docs.arduino.cc/software/ide-v1/tutorials/installing-libraries。
确保在以下位置找到patch文件并安装 https://github.com/ambiot/ambd_arduino/tree/master/Ameba_misc/。
还需要安装TensorFlow Lite库与Ameba_ArduCAM库。
在Arduino IDE中,安装JPEGDecoder库。此范例已经通过测试1.8.0版的JPEGDecoder库。
安装库后,您需要对其进行配置,以禁用一些与RTL8722DM不兼容的可选组件。打开以下文件:
Arduino/libraries/JPEGDecoder/src/User_Config.h
#define LOAD_SD_LIBRARY 和 #define LOAD_SDFAT_LIBRARY 都注释掉,如该文件摘录所示://#define LOAD_SD_LIBRARY // Default SD Card library
//#define LOAD_SDFAT_LIBRARY // Use SdFat library instead, so SD Card SPI can be bit bashed
打开范例,“Files” -> “Examples” -> “TensorFlowLite_Ameba” -> “person_detection”。
程式码说明
有关TensorFlow Lite for Microcontrollers的更多信息,请参考以下网址: https://www.tensorflow.org/lite/microcontrollers




