MiniConda on Raspberry Pi for Machine Learning

Contents

¡Hola geeks! In this article, let's learn how to use raspberry pi for Machine Learning. Raspberry pi is cheap and quite interesting to work with. We will talk about Data Science applications. Data science is receiving a lot of attention day by day and this technology is growing very fast. Then, let's get started… ..😉

Introduction

As we all know, machine learning is improving people's lives. Machine learning is helping entrepreneurs to be a common person. Tech enthusiasts are always racing to find something new in the world of data science and machine learning., work on various algorithms to produce the most efficient model. In the same way, they also work on the hardware to improve its performance and meet user requirements. The hardware we are working on is Raspberry Pi. First, we will configure the raspbian operating system on the raspberry pi 3 and then we will set the miniconda on it, we have explained it in more detail in the article below.

Raspberry pi

Raspberry pi is a small-sized computer. It is very cheap and reliable hardware, raspberry pi has all the components that a fully functioning computer would have, as RAM, CPU, HDMI, USB, Ethernet and many more.

Raspberry pi provides various hardware versions that you can use according to your requirements. For intensive users, raspberry pi even has 8 GB of RAM, which surely shows the power of pi. Some of the Raspberry Pi models are listed below.

  • Raspberry Pi 1 Model B
  • Raspberry Pi 1 Model A
  • Raspberry Pi 1 Model B +
  • Raspberry Pi 3 Model B
  • Raspberry Pi Zero W

Raspberry pi is very famous in school and university projects due to its vast area of ​​implementation. Can be used as a personal desk or play station, raspberry pi retro pirociona games. Some early penetration testers also use raspberry pi as a hacking and testing lab when installing Kali Linux on it.

MiniConda

What is it, similarity in anaconda and miniconda

Before jumping directly to miniconda we must know what is conda? Then, conda is a management tool or system. Conda performs two types of systems management; one is environmental system management and the other is package system management.

Miniconda is just a minimal version of conda for various hardware according to the requirements. The high performance version of conda is Anaconda, which comes with various machine learning tools like Jupyter notebook, spyder and many more.

Miniconda comes with minimal support like python, conda and some dependent modules. If you have conda, which means you can easily perform various events like create, save, switch between environments in the system.

Steps involved

Now we are going to do the activity. The process is well documented step by step. Then, you can also follow me.

Paso 1

First, we have to write the raspbian operating system to the microSD card using some tool. Thereafter, we will start with more settings.

To download the raspbian click here. There are several options for the raspberry pi, we will choose the desktop version with full support. You can also use NOOBS and raspbian Lite for this.

97660screenshot2096-1270570

The operating system is approximately 3 GB, so please be patient while downloading. After download, we will need one more tool called ether, to download etcher click here.

After so much download, we will connect the microSD card and start the ether software. Then we have selected the downloaded ISO file and the microSD card. Ether UI is very simple and easy. Now click on Flash and it will automatically install raspbian OS on it.

44330screenshot2097-6289712

Once the flash is complete, insert the microSD card into the raspberry pi. Now, start the pi by giving power using a USB cable and connect the raspberry pi to the monitor using the HDMI or VGA port.

Paso 2

Now, the raspbian operating system will start in the login window, the default login credentials are pi (Username) y raspberry (password). Login to the desktop with these credentials.

50928screenshot2098-4821873

Now, open terminal and update package manager, also check if there is any python version installed on pi.

Use the following command to update.

sudo apt update

Use the following command to update.

sudo apt upgrade

Now check the Python version.

python --version

Paso 3

– Download miniconda and configure it.

wget http://repo.continuum.io/miniconda/Miniconda3-latest-Linux-armv7l.sh

Enter the following command and change the default directory to / home / pi / miniconda3

sudo /bin/bash Miniconda3-latest-Linux-armv7l.sh

Add directory to path variable and file “.bashrc”. Open the file “.bashrc” from the following command.

sudo nano /home/pi/.bashrc

Now add these lines in the file “.bashrc” and save it.

export PATH="/home/pi/miniconda3/bin:$PATH"

Now restart the raspberry pi.

sudo reboot

Paso 4

Now install Jupyter Notebook.

pip install jupyter-notebook

Run Jupyter Notebook on Raspberry pi.

jupyter-notebook

Data Science Applications and Raspberry Pi

There are several platforms and modules for data science, which can be used in raspberry pi in various ways. Some of those assets are listed below.

Tensorflow

Tensorflow is a library provided and maintained by Google, is open source, which means that anyone can use it. Google has a group of researchers working on machine learning and deep learning using this open source library. We could use this library on raspberry pi and do various projects like object detection from video (pi also has a camera slot for picam) or check the parking site. You could even code a self-driving car with TensorFlow.

Google AIY Kit

With the help of Google's AIY kit, you can create your own language processor that can be connected to google assistant. Google AIY stands for Google Artificial Intelligence Yourself. Google's AIY kit also provides vision and voice-enabled components that can be used in various ways to produce some nice projects..

Jenkins automation

You could even install Jenkins server on raspberry pi. As we all know, Jenkins is such a powerful tool in the world of automation. With this Jenkins we can automate our machine learning models, that produce more accurate models. A single raspberry can control many Jenkins slave nodes.

I hope you have learned something new from this article or it could inspire you to build something very interesting. If you have any questions or suggestions please comment.

The media shown in this article about MiniConda on Raspberry Pi is not the property of DataPeaker and is used at the Author's discretion.

Subscribe to our Newsletter

We will not send you SPAM mail. We hate it as much as you.