1

I am attempting to build tensorflow from source on Raspberry PI using docker following this tutorial: https://www.tensorflow.org/install/source_rpi

I have python 3.4 and 3.7 installed, and Docker version 18.06.3-ce. I get stuck on this step:

CI_DOCKER_EXTRA_PARAMS="-e CI_BUILD_PYTHON=python3 -e CROSSTOOL_PYTHON_INCLUDE_PATH=/usr/include/python3.4" \
tensorflow/tools/ci_build/ci_build.sh PI-PYTHON3 \
tensorflow/tools/ci_build/pi/build_raspberry_pi.sh

which at step 4 of the docker process fails:

...
Step 4/14 : RUN /install/install_bootstrap_deb_packages.sh
     ---> Running in d898ac94cbfe
    The command '/bin/sh -c /install/install_bootstrap_deb_packages.sh' returned a non-zero code: 139
    ERROR: docker build failed. Dockerfile is at /home/pi/tensorflow/tensorflow/tools/ci_build/Dockerfile.pi-python3

I am running raspian 8 (jessie) on a raspberry pi zero W. I have tried building multiple tensorflow versions, including the most stable release, and all have the same results. Any help would be greatly appreciated

1 Answer 1

1

Issue

The guide you are following references cross-compiling, which means they are building on a host machine, while you are trying to build on the Pi.

To build Tensorflow go on raspberry pi you have to have libtensorflow.so, which is clibrary for Tensorflow used by GoLang.

Check out this post for more info on the issue you are having.

Solution

If you wish to build Tensorflow on the Pi, follow this guide to walk you through building the required library, libtensorflow.so.

Sign up to request clarification or add additional context in comments.

2 Comments

Sorry I might not have made myself entirely clear, I am looking to use tensorflow with python, and I am pretty sure this compiles it to be used with C. Unless I read it wrong?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.