Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TensorFlow library was compiled to use SSE4.1 instructions, but these aren't available on your machine. Aborted (core dumped)

I have installed tensorflow following the https://www.tensorflow.org/install/pip steps. I installed it through Anaconda.

I also tried using a virtual environment without using anaconda as this page provided (please check image). It also gave the same error.

enter image description here

Following images shows the versions I have installed and its given error.

I am using,

  • Ubuntu 18.04.1 LTS

  • x86_64

  • Processor: Intel(R) Core(TM) 2 Duo CPU T5870 @ 2.00 GHz 2.00 GHz

  • Installed memory (RAM): 2.00 GB

enter image description here

Version: enter image description here

Error: enter image description here

I tried to overcome this but, I couldn't find a solution. I am new to tensorflow and trying to install and learn it. Please help me to solve this.

like image 380
Emalka Avatar asked Dec 27 '18 19:12

Emalka


3 Answers

Thanks for the earlier answers. I was facing the exact problem for SSE4.2 instruction. I installed tensorflow 1.5 instead of 1.12 and it is working.

Error message on my system

The TensorFlow library was compiled to use SSE4.2 instructions, but these aren't available on your machine.
Aborted (core dumped)

Solution

Here is what I did:

Please run these inside virtual environment:

pip uninstall tensorflow

pip install tensorflow==1.5

You can replace 1.5 with any version that suits your machine.

Try importing it again it should run now

like image 113
abstract Avatar answered Sep 22 '22 15:09

abstract


Your CPU is too old for running TensorFlow as it lacks the required Instruction set. Starting with TensorFlow 1.6, binaries use AVX instructions which may not run on older CPUs. - According to Tensorflow.

You have 2 possible solutions:

  1. Using cloud/web based solution, e.g. Google Colab
  2. Upgrade your Machine to a modern build
like image 22
Dreamer Avatar answered Sep 22 '22 15:09

Dreamer


I have the same error on the laptop HP ProBook 4720s:

python3
Python 3.6.7 (default, Oct 22 2018, 11:32:17) 
[GCC 8.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
2019-04-16 17:50:25.829023: F tensorflow/core/platform/cpu_feature_guard.cc:37] The TensorFlow library was compiled to use AVX instructions, but these aren't available on your machine.
Aborted (core dumped)

But I installed TensorFlow via Anaconda conda installation:

conda install tensorflow  # install TensorFlow for CPU
conda activate DL3  # activate virtual environment DL3

python
Python 3.7.3 (default, Mar 27 2019, 22:11:17) 
[GCC 7.3.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
>>> print(tf.__version__)
1.13.1
>>> exit()
like image 24
FooBar167 Avatar answered Sep 21 '22 15:09

FooBar167