Coral USB Accelerator

💻

In order to continue laying the ground work to merge my developing underwater sensor platform I’ve finally started up my new Google USB Coral Accelerator1 and have gone through Google’s available demos2 for it. In this post I’ll cover the process and any hurdles along the way to successfully running the Google Coral USB Accelerator1.

To test it, I used my Raspberry Pi 3 Model B+ and followed Google’s tutorial3.

Because my version of Raspbian was 4.9, I didn’t have a version of Python above 3.4.
The tutorial3 calls for Python 3.5 or higher, so I attempted to install Python 3.5, 3.6 and 3.7 using some well documented instructions4 5 6. Unfortunately I was met with Python related issues either at runtime7 of the tutorial’s3 model inference invocation or during the tutorial’s3 ./install.sh execution that involved what were likely $PATH issues.

After searching around, I stumbled across a few others who had successfully used the accelerator and found a commonality among them all; all successful projects using the accelerator used a fresh and current Raspbian install8.

So I backed up9 my PI’s SD card using my MacBook Pro, erased and then formatted the SD card using gparted10 on my linux machine (with boot flag set to true11 to avoid an annoying MBR related issue12) and then installed the latest Raspbian release using NOOBS13

If you erase the entire SD card and remove all partitions so that its completely unformatted and then attempt to reformat it using ‘gparted’, have the ‘boot’ flag set to true. Otherwise, the MBR partition will be missing and the PI won’t be able to boot from the SD card.

After my fresh Raspbian install, I was able to execute the accelerator’s tutorial3 along with its demos2 with no difficulty.

I noticed that the power consumption while running the classify_capture.py demo2 using the pi cam v214 with only a terminal open on the PI, peaks at about 61mA. Furthermore, the classification speed of the accelerator was approximately 11fps while running classify_capture.py, which meets my target fps for my underwater sensor platform.


  1. https://coral.withgoogle.com/products/accelerator ↩︎

  2. https://coral.withgoogle.com/docs/edgetpu/api-intro/ ↩︎

  3. https://coral.withgoogle.com/docs/accelerator/get-started/ ↩︎

  4. https://raspberrypi.stackexchange.com/questions/54365/how-to-download-and-install-python-3-5-in-raspbian ↩︎

  5. https://raspberrypi.stackexchange.com/questions/59381/how-do-i-update-my-rpi3-to-python-3-6 ↩︎

  6. https://www.alauda.ro/2019/01/how-to-install-python-3-7-on-raspberry-pi/ ↩︎

  7. https://github.com/f0cal/google-coral/issues/13 ↩︎

  8. https://www.pyimagesearch.com/2019/04/22/getting-started-with-google-corals-tpu-usb-accelerator/ ↩︎

  9. https://thepihut.com/blogs/raspberry-pi-tutorials/17789160-backing-up-and-restoring-your-raspberry-pis-sd-card ↩︎

  10. https://ubuntuforums.org/showthread.php?t=1894291 ↩︎

  11. http://qdosmsq.dunbar-it.co.uk/blog/2013/06/noobs-for-raspberry-pi/ ↩︎

  12. https://github.com/raspberrypi/noobs/issues/498 ↩︎

  13. https://www.raspberrypi.org/documentation/installation/noobs.md ↩︎

  14. https://www.raspberrypi.org/products/camera-module-v2/ ↩︎

Research Engineer

My interests lie at the intersection of perception and robotics.