-
Notifications
You must be signed in to change notification settings - Fork 9
OpenFaaS based on raspbian
This wiki explains how to deploy a serverless function for TensorFlow Object Detection API with the SSD MobileNet v1 model, using OpenFaaS and starting from the schachr/raspbian-stretch Docker image.
https://hub.docker.com/r/schachr/raspbian-stretch/
Previously, I tried with resin/rpi-raspbian Docker image. This image is part of the base image series for IoT devices by https://resin.io/?ref=dockerhub
Follow the installation instructions in https://github.com/salekd/rpizero_smart_camera3/wiki/First-serverless-Python-function-with-OpenFaaS
Build a Docker image for the serverless function.
cp faas-mobilenet/Dockerfile.rpi faas-mobilenet/Dockerfile
cp faas-mobilenet/function/requirements.txt.rpi faas-mobilenet/function/requirements.txt
sudo docker build -t faas-mobilenet-rpi faas-mobilenet
export DOCKER_ID_USER="salekd"
sudo docker login
sudo docker tag faas-mobilenet-rpi $DOCKER_ID_USER/faas-mobilenet-rpi:1.0.0
sudo docker push $DOCKER_ID_USER/faas-mobilenet-rpi:1.0.0
This Dockerfile compiles protobuf and installs TensorFlow. I followed the example from https://github.com/EdjeElectronics/TensorFlow-Object-Detection-on-the-Raspberry-Pi
The image for Raspberry Pi 3 B+ is available here: https://hub.docker.com/r/salekd/faas-mobilenet-rpi/