Install TensorFlow on Raspberry Pi

Learn how to install TensorFlow on the Raspberry Pi

Written By: Cherie Tan

Dash icon
Difficulty
Very Easy
Steps icon
Steps
3

Introduction

With TensorFlow on your Raspberry Pi, you can create neural networks that can perform image recognition, data classification, etc

In this guide, we will install the open source machine learning library TensorFlow by cloning the repository from Github. We will use a Raspberry Pi 3 Model B+ and the recommended power supply for it.

Installing TensorFlow will enable you to get started with learning about AI techniques and incorporating it in your future Raspberry Pi projects.

Step 1   What is Tensorflow?

  • If you're looking to get started with AI projects using the Raspberry Pi, Google TensorFlow is a good option. It's used for machine learning and the creation of neural networks, which makes image recognition and text analysis possible, among other things.
  • You don't have to be an expert in AI to get started. Instead of using data to build a model, there are models already built by Google that you can test and use for your own projects.

Step 2   Install Tensorflow using Pip

  • With pre-built binaries, TensorFlow can be installed using Python's pip package system in two simple commands.
  • With a terminal window open, enter: sudo apt install libatlas-base-dev
  • After its installation is complete, enter the following: pip3 install tensorflow

Step 3   Clone the TensorFlow Repository

  • Head over to the command line and type: git clone https://github.com/tensorflow/tensorflow.git
  • You can follow the instructions here to build the example models for the Raspberry Pi.
  • You can also head over to the TensorFlow repository for Google example models and instructions.
    Now you're all set with everything you need to start using TensorFlow. It's a huge subject that goes beyond this guide. Learn by following along and using the models provided in the instructions above.
© 2022 Little Bird Electronics Pty Ltd.
Made with ❤️ in SYD. All prices inc GST. ABN 15 634 521 449. We're 🐥 @lbhq on Twitter.