From 1da8f8e062bbe0197fb49ea817298c14a54016d0 Mon Sep 17 00:00:00 2001 From: Aaron Markham Date: Tue, 19 Feb 2019 07:08:39 -0800 Subject: [PATCH] update raspberry pi install instructions (#14172) --- docs/install/index.md | 50 ++++++++++++++++++++++++++++++---- docs/install/raspbian_setup.md | 4 +-- 2 files changed, 47 insertions(+), 7 deletions(-) diff --git a/docs/install/index.md b/docs/install/index.md index 76f22e744075..2b7e0457e2b4 100644 --- a/docs/install/index.md +++ b/docs/install/index.md @@ -1188,7 +1188,7 @@ MXNet should work on any cloud provider's CPU-only instances. Follow the Python
-MXNet supports the Debian based Raspbian ARM based operating system so you can run MXNet on Raspberry Pi Devices. +MXNet supports the Debian based Raspbian ARM based operating system so you can run MXNet on Raspberry Pi 3B devices. These instructions will walk through how to build MXNet for the Raspberry Pi and install the Python bindings for the library. @@ -1196,6 +1196,9 @@ You can do a dockerized cross compilation build on your local machine or a nativ The complete MXNet library and its requirements can take almost 200MB of RAM, and loading large models with the library can take over 1GB of RAM. Because of this, we recommend running MXNet on the Raspberry Pi 3 or an equivalent device that has more than 1 GB of RAM and a Secure Digital (SD) card that has at least 4 GB of free memory. +## Quick installation +You can use this [pre-built Python wheel](wget https://mxnet-public.s3.amazonaws.com/install/raspbian/mxnet-1.5.0-py2.py3-none-any.whl) on a Raspberry Pi 3B with Stretch. You will likely need to install several dependencies to get MXNet to work. Refer to the following **Build** section for details. + **Cross compilation build (Experimental)** ## Docker installation @@ -1222,11 +1225,48 @@ ci/build.py -p armv7 ## Install -Create a virtualenv and install the package we created previously. +Your Pi will need several dependencies. + +Install MXNet dependencies with the following: +``` +sudo apt-get update +sudo apt-get install -y \ + apt-transport-https \ + build-essential \ + ca-certificates \ + cmake \ + curl \ + git \ + libatlas-base-dev \ + libcurl4-openssl-dev \ + libjemalloc-dev \ + liblapack-dev \ + libopenblas-dev \ + libopencv-dev \ + libzmq3-dev \ + ninja-build \ + python-dev \ + software-properties-common \ + sudo \ + unzip \ + virtualenv \ + wget +``` +Install virtualenv with: +``` +sudo pip install virtualenv +``` +Create a Python 2.7 environment for MXNet with: +``` +virtualenv -p `which python` mxnet_py27 +``` +You may use Python 3, however the [wine bottle detection example](https://mxnet.incubator.apache.org/versions/master/tutorials/embedded/wine_detector.html) for the Pi with camera requires Python 2.7. + +Create a virtualenv and install the wheel we created previously, or the wheel that you downloaded. ``` -virtualenv -p `which python3` mxnet_py3 -source mxnet_py3/bin/activate +virtualenv -p `which python3` mxnet_py27 +source mxnet_py27/bin/activate pip install mxnet-x.x.x-py2.py3-none-any.whl ``` @@ -1257,7 +1297,7 @@ Install these dependencies using the following commands in any directory: ``` sudo apt-get update - sudo apt-get -y install git cmake ninja-build build-essential g++-4.9 c++-4.9 liblapack* libblas* libopencv* libopenblas* python3-dev virtualenv + sudo apt-get -y install git cmake ninja-build build-essential g++-4.9 c++-4.9 liblapack* libblas* libopencv* libopenblas* python3-dev python-dev virtualenv ``` Clone the MXNet source code repository using the following `git` command in your home directory: diff --git a/docs/install/raspbian_setup.md b/docs/install/raspbian_setup.md index a432d4815662..896d4721370b 100644 --- a/docs/install/raspbian_setup.md +++ b/docs/install/raspbian_setup.md @@ -17,9 +17,9 @@ - +

- + This content is moved to a new MXNet install page. Redirecting...