Clusters computing with Raspberry Pi build your mainframe (almost) for free!

By on June 9, 2015
Pin It

An interesting experiment from Fabio Nelli, dedicated to all the software engineers who need to build or study a parallel computing system. The traditional ones are really expensive but, as you can read below, by using MPI library for python and at least a couple of Raspberry pies, you have a full performing system, almost for free!

Are you a developer and have you always wished to be able to implement code in parallel and try it on a cluster of processors? Well, now you can do it, cheaply and easily at your home. Thanks to the low cost of the Raspberry Pi boards, now you can realize a small cluster on which to practice and become familiar with parallel programming.

In this article, you’ll see how easy it is to make a small cluster consisting of two Raspberry Pi boars. As a programming language you will use Python and as for programming in parallel, you will see how easy you can be implemented parallel code thanks to the MPI library. A series of examples will then introduce you to the basic concepts of the parallel programming that will be useful for you to develop any project.

The “Message Passing” model for parallel computing is considered as one of the best performing, and it is based on a specific protocol called MPI (Message Passing Interface). It consists mainly of a portable and standardized system of message-passing, that currently has become the standard de facto for parallel communication within clusters. Since its first release the standard library MPI has become the most widespread.

The mpi4py module provides an object oriented approach to message passing to integrate the Python programming. This interface is designed according to the syntax and semantics of MPI defined by the MPI-2 C ++ bindings. You can go deep into this topic consulting a good documentation in this page, it is written by the author of mpi4py, Lisando Dalcin.

Here is a scheme reporting the performance improvement when using n=2 Raspberry in parallel. On X axis you have the concurrent requests while on Y axis there is the mean response time for each.

Check the full description and installation&configuration guide here: Clusters and parallel programming with MPI and Raspberry Pi | Meccanismo Complesso

About Staff

Leave a Reply

Your email address will not be published.