Skynet w/ Raspberry Pi: Pi Install

This is the third entry in my 8 part series on adding some object detection to my Raspberry Pi.

Part 1: Introduction
Part 2: SD Card Setup
Part 3: Pi Install
Part 4: Software
Part 5: Raspberry Pi Camera
Part 6: Installing TensorFlow
Part 7: MobileNetV2
Part 8: Conclusion

Introduction

In this section I am going to get the Raspberry Pi set up and ready to work. To do that I will be following this guide.

Starting Up

Following the Raspberry Pi guide I am going to fire this up for the first time.

First, I dig out one of my MANY extra keyboards and mice and connect those through the usb ports.
Second, I no longer have an extra monitor so I had to steal my second monitor. Another stroke of luck, I had an unopened Amazon Basics HDMI cord.
Third, on first start up I select the ‘Raspbian FULL’ option.
Finally, after some reboots and some options my Pi was ready to run

Remote Connection

In order to keep me from having to connect to my second monitor (as well as getting out my extra keyboard and mouse) I am going to enable SSH and Remote Desktop.

SSH

To enable SSH, go to the Raspberry menu -> Preferences -> Raspberry Pi Configuration. On that screen go to Interfaces and enabled SSH.

On my machine I didn’t have to install anything because OpenSSH client was already installed. If you don’t have it installed it is under ‘Optional Features’ under the Apps setting screen.

Remote Desktop

To enable SSH, go to the Raspberry menu -> Preferences -> Raspberry Pi Configuration. On that screen go to Interfaces and enabled VNC.

Now, on my main computer I need to download and install RealVNC

Conclusion

One of the awesome things about the Raspberry Pi is how easy it is to setup. It really is a 15 minute setup.

Code: https://github.com/ehennis/Blog/tree/master/ImageDetection

Skynet w/ Raspberry Pi: SD Setup

This is the second entry in my 8 part series on adding some object detection to my Raspberry Pi.

Part 1: Introduction
Part 2: SD Card Setup
Part 3: Pi Install
Part 4: Software
Part 5: Raspberry Pi Camera
Part 6: Installing TensorFlow
Part 7: MobileNetV2
Part 8: Conclusion

Introduction

In this section I am going to get the Raspberry Pi set up and ready to work. To do that I will be following this guide.

SD Card

I am going to set up the SD card using NOOBS to install Raspbian. I am on Windows so I will need to follow those instructions.

64GB Card

One thing to note, I had an 8GB card but with the NOOBS install and full Raspbian it wouldn’t work. Luckily, I had an unopened 64GB card. Unfortunately, this is an issue as anything over 32GB is an SDXC card and needs to be installed using exFAT. The Pi bootloader only recognizes FAT filesystems.

This requires me to partition my card into 2 32GB chunks.

This was a nightmare.

I don’t know if it was Windows or what but each card I used was listed as write-protected. I did some searches trying to undo this and found How To Recover that listed multiple ways to resolve my issue. was sent to download HDD LLF Low Level Format Tool. This took quite a while to complete and it didn’t work. I then had the idea to format using a camera hoping that it was a Windows things. Turns out, the plastic holder for the SD card had the write-protect slide set. Yikes.

Once that was done I was able to partition using FAT32.

Step 1: Download NOOBS. Since I last set up a Pi 3+ years ago I need to install this again. [Link]
Step 2: Download the SD Formatter for Windows [Link] and install it
Step 3: Run the application and format the SD card
Step 4: Copy all of the extracted NOOBS files onto the SD card

Conclusion

That is all we have to do with the SD card to start. The next post will be getting the Raspberry Pi set up and ready to run.

Code: https://github.com/ehennis/Blog/tree/master/ImageDetection

Skynet w/ Raspberry Pi

This is the first in a multiple part series on adding some object detection to my Raspberry Pi.

Part 1: Introduction
Part 2: SD Card Setup
Part 3: Pi Install
Part 4: Software
Part 5: Raspberry Pi Camera
Part 6: Installing TensorFlow
Part 7: MobileNetV2
Part 8: Conclusion

Introduction

I am going to recreate a really cool object detection project I found by Leigh Johnson (also a fellow ML GDE). Her project is called Portable Computer Vision: TensorFlow 2.0 on a Raspberry Pi. Now, she went WAY above and beyond what I am planning to do but we will see how it all works out.

Hardware

I am going to use a version 3 and a camera that I had from a few years ago. I used it to create a baby monitor when my youngest was a baby. I created a python script that would take an image every 60 seconds and post it to a network drive. This drive would then feed an internal web site I created.

Model

I am going to skip the process of training my own model and use an existing model (MobileNetV2).

I will take the existing model and use “transfer learning” and retrain with a custom classifier. I think I might even get frisky and have it do something special when it sees me!

Libraries

As is standard practice with me, I will be using TensorFlow and Keras with the pretrained model. I will then convert the model to TensorFlow Lite.

Next Steps

In my next post I will work through getting the Raspberry Pi set up.

Code: https://github.com/ehennis/Blog/tree/master/ImageDetection

Life

It has been some time since I have written on here because life sometimes gets in the way. Mainly, I have a 3 year old that is very attached and needs me to be with her to sleep. This really cuts into my nightly computer work that I have gotten used to during grad school.

But, I do plan to get some time carved out to continue getting content out into the world to keep my GDE.

My first goal is to recreate a great project I found by Leigh Johnson (also a fellow ML GDE). Her project is called Portable Computer Vision: TensorFlow 2.0 on a Raspberry Pi.

Now, she went WAY above and beyond what I am planning to do but we will see how it all works out. I am hoping to get something going this month with a few weekly check-ins and then turn it all into a YouTube series and potentially a talk I can give throughout 2020.