tensorflow-on-raspberry-pi icon indicating copy to clipboard operation
tensorflow-on-raspberry-pi copied to clipboard

Latest Tensorflow for raspberry pi

Open naderafshari opened this issue 7 years ago • 8 comments

Tensorflow 1.1 installs an runs fine on raspberry pi - thank you! However. r1.1 does not have some of the useful functions and feature needed for 3d convolutional networks e.g Conv3DTranspose Has there been any attempts to build r1.8 for raspberry pi? I have tried a bunch of stuff but not been successful. For example, latest bazel with tensorflow master - no dice!

naderafshari avatar Jun 01 '18 12:06 naderafshari

Have you tried the nightly builds?

On Fri 1 Jun, 2018, 6:13 PM naderafshari, [email protected] wrote:

Tensorflow 1.1 installs an runs fine on raspberry pi - thank you! However. r1.1 does not have some of the useful functions and feature needed for 3d convolutional networks e.g Conv3DTranspose Has there been any attempts to build r1.8 for raspberry pi? I have tried a bunch of stuff but not been successful. For example, latest bazel with tensorflow master - no dice!

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/samjabrahams/tensorflow-on-raspberry-pi/issues/153, or mute the thread https://github.com/notifications/unsubscribe-auth/AUME5z_apbODxDvAHQdsQNv1qD1mWQ9Jks5t4TcLgaJpZM4UWo48 .

--

Thank you, Varun.

varun19299 avatar Jun 01 '18 13:06 varun19299

There are nightly builds?

naderafshari avatar Jun 01 '18 16:06 naderafshari

You can find them here:

http://ci.tensorflow.org/job/nightly-pi-python3/

The current stable build is tensorflow 1.8.

There are benchmark models too, but personally I've tested 1.6 back in March. The benchmarks ran fine. (MNIST, CIFAR on various models).

These are part of the Jenkins project, with rust cross compilation being used. I wonder if Sam (couldn't do a mention, sorry :() should append this to his readme.

varun19299 avatar Jun 02 '18 14:06 varun19299

I just found out about piwheels which when added as an extra pip source you can do a regular pip install tensorflow==1.8.0 on a pi.

MatthewScholefield avatar Jun 14 '18 23:06 MatthewScholefield

cool cool cool! pip install tensorflow==1.8.0 --index-url https://www.piwheels.org/simple I had to install a bunch of packages but after that it installed. Thank you so much...

import tensorflow as tf tf.version '1.8.0'

naderafshari avatar Jun 15 '18 00:06 naderafshari

it seems not working on the Raspbian 9. when using import tensorflow in python3, the system raises an error. Traceback (most recent call last): File "/home/pi/.local/lib/python3.5/site-packages/numpy/core/init.py", line 16, in from . import multiarray ImportError: libf77blas.so.3: cannot open shared object file: No such file or directory

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "", line 1, in File "/usr/local/lib/python3.5/dist-packages/tensorflow/init.py", line 24, in from tensorflow.python import pywrap_tensorflow # pylint: disable=unused-import File "/usr/local/lib/python3.5/dist-packages/tensorflow/python/init.py", line 47, in import numpy as np File "/home/pi/.local/lib/python3.5/site-packages/numpy/init.py", line 142, in from . import add_newdocs File "/home/pi/.local/lib/python3.5/site-packages/numpy/add_newdocs.py", line 13, in from numpy.lib import add_newdoc File "/home/pi/.local/lib/python3.5/site-packages/numpy/lib/init.py", line 8, in from .type_check import * File "/home/pi/.local/lib/python3.5/site-packages/numpy/lib/type_check.py", line 11, in import numpy.core.numeric as _nx File "/home/pi/.local/lib/python3.5/site-packages/numpy/core/init.py", line 26, in raise ImportError(msg) ImportError: Importing the multiarray numpy extension module failed. Most likely you are trying to import a failed build of numpy. If you're working with a numpy git repo, try git clean -xdf (removes all files not under version control). Otherwise reinstall numpy.

Original error was: libf77blas.so.3: cannot open shared object file: No such file or directory

julianhu1979 avatar Jun 28 '18 15:06 julianhu1979

Try running sudo apt-get install libatlas-base-dev first.

MatthewScholefield avatar Jun 28 '18 16:06 MatthewScholefield

you are right. I don't what happened, at the beginning, after apt update, I can not install libatlas-base-dev, couple minutes later, it works.

julianhu1979 avatar Jun 28 '18 23:06 julianhu1979