tensorflow-on-arm icon indicating copy to clipboard operation
tensorflow-on-arm copied to clipboard

Tensorflow-on-arm RP4 Python 3.7 64 bits

Open tadam98 opened this issue 5 years ago • 4 comments

Is there a 64 bit version complied with make -j4 for RP4 for Python 3.7 ? If not, how to do so ?

$ uname -a Linux raspberrypi 4.19.97-v7l+ #1294 SMP Thu Jan 30 13:21:14 GMT 2020 armv7l GNU/Linux

tadam98 avatar Mar 22 '20 06:03 tadam98

Raspbian (All versions) runs on 32-bit.

There is no such thing like '64-bit' program built for Raspberry Pi4.

The flag -j4 has the only purpose to accelerate the build, but at the end is meaningless for installation, I mean it doesn´t matter if the build takes 2 or 4 hours.

g30ba1 avatar Mar 28 '20 21:03 g30ba1

Hi,

Thanks, eventually I successfully installed TF 1.14.0. It was an adventure. See working procedure below.

I was installed in a folder my Python did not search. And, I had to comment out the wrong import of cloud.

Best, Mickey

$ wget https://github.com/lhelontra/tensorflow-on-arm/releases/download/v1.14.0-buster/tensorflow-1.14.0-cp37-none-linux_armv7l.whl

Tensor flow 1.14.0

$ sudo pip install wrapt --upgrade --ignore-installed # otherwise tensorflow will fail. $ sudo pip3 install --ignore-installed tensorflow-1.14.0-cp37-none-linux_armv7l.whl

The tensorlow install places everything in /usr/local/lib/python3.7/dist-packages

while python3.7 looks in /usr/local/lib/python3.7/site-packages

to solve this, we add dist-packages to python's sys.path

$ nano /etc/profile.d/local_python.sh PYTHONPATH="/usr/local/lib/python3.7/dist-packages/":"${PYTHONPATH}" export PYTHONPATH $ source /etc/profile.d/local_python.sh $ python -c 'import sys; print (sys.path)' # this checks the correction

Python3.7

import tensorflow as tf tf.version '1.14.0'

https://github.com/lhelontra/tensorflow-on-arm/issues/67

nano /usr/local/lib/python3.7/dist-packages/tensorflow/contrib/init.py and comment:

if os.name != "nt" and platform.machine() != "s390x":

from tensorflow.contrib import cloud

tadam98 avatar Mar 28 '20 21:03 tadam98

idk

On Sun, Mar 22, 2020, 07:23 tadam98 [email protected] wrote:

Is there a 64 bit version complied with make -j4 for RP4 ? If not, how to do so ?

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/lhelontra/tensorflow-on-arm/issues/85, or unsubscribe https://github.com/notifications/unsubscribe-auth/AORJRPVVVHNYB3WKUGVGFSDRIWVE3ANCNFSM4LRFZP2A .

JoessiSmithJoessi avatar Apr 05 '20 10:04 JoessiSmithJoessi

The 64-bit binary https://github.com/lhelontra/tensorflow-on-arm/releases/download/v2.3.0/tensorflow-2.3.0-cp37-none-linux_aarch64.whl works fine for me. This issue can probably be closed.

emojifreak avatar Aug 23 '20 07:08 emojifreak