Invalid instruction: 4 when importing tensor flow in python 3.6

I installed Tensorflow on macOS with Virtualenv. Everything went well ("Successfully installed Six-1.11.0 tensorflow-1.6.0" is the last terminal output as soon as I run the command pip3 install --upgrade tensorflow). So, when activating virtualenv, I typed: python3and then import tensorflow as tf but it throws an error Illegal instruction: 4and exits with python.

I looked around to find out if anyone else had the same problem, but I did not find much other than this issue, which does not provide a solution. I read this answer explaining what the illegal instruction means, the fact is that I'm on the latest version of macOS High Sierra:

enter image description here

I don’t understand what the answer means?

, ? , , , .

.

+4
2

, , uninstalled tensorflow 1.6.

pip install -Iv tensorflow==1.5
pip install -Iv numpy==1.13

, , , tensorflow 1.6.

+3

1.15 , @dfresh22, :

pip3 uninstall tensorflow
pip3 install -Iv tensorflow==1.5
+2

Source: https://habr.com/ru/post/1694402/


All Articles