tensorflow-on-raspberry-pi
tensorflow-on-raspberry-pi copied to clipboard
Import error after compiling from source
Describe the Issue
After installing Tensorflow from source I try to import it by typing: "python3" and then "import tensorflow as tf" which results in an error.
Steps to Reproduce
Followed the step-by-step guide by building from source. In the configure file I changed to python3 and library path 3.4. As well as using Bazel 0.8.
Hardware/Software Info
- Raspberry Pi model: Pi 2 Model B v1.1
- Operating System used: Raspian GNU/Linux version 8 (jessie)
- Version of Python used: 3.4.2
- SD card memory size: 16GB
- Size of USB/other device used as swap (if building from source): 16GB
- TensorFlow git commit hash (if building from source): 56422034fe039d7e8a57392957ed0c8b4b4efe56
Relevant Console Output/Logs
Python 3.4.2 (default, Oct 19 2014, 13:31:11)
[GCC 4.9.1] on linux
Type "help", "copyright", "credits" or "license" for more information.
--- import tensorflow as tf
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/tensorflow/python/pywrap_tensorflow.py", line 58, in
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "
#133 same issue
Same here.
The fix for me was to compile TF r1.4 instead. It’s working perfectly fine.
The fix for me was to compile TF r1.4 instead. It’s working perfectly fine.
How do you do that?
The same problem here (RPi 3 with Ubuntu MATE). Happens with both tensorflow 1.7 and 1.6 for both Python 2.7 and 3.5. I'll keep trying with lower versions of TF - 1.5 and 1.4.
EDIT: Tensorflow 1.5 with Python 3.5.2 works! Finally successful import.
I found that put libtensorflow_framework.so in your LD_LIBRARY_PATH can solve this problem.
I found that put libtensorflow_framework.so in your LD_LIBRARY_PATH can solve this problem.
Hello, I tried the same but no luck