Tensorflow needs special versions of tools and libraries. Pip only cares about the Python version.
To deal with this on a professional level (that is, save time for me and others), you must establish a special environment for each software like this.
An advanced tool for this is conda.
I installed Tensorflow with these commands:
sudo apt install python3
sudo update alternatives --install / usr / bin / python python / usr / bin / python3 1
sudo apt install python3-pip
sudo apt-get install curl
curl https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh > Miniconda3-latest-Linux-x86_64.sh
bash Miniconda3-latest-Linux-x86_64.sh
Yes
source ~ / .bashrc
- installs his own phyton, etc.
nano .bashrc
- maybe insert your proxies here, etc.
conda create --name your_name python = 3
Konda activate your name
conda install -c conda-forge flow tensor
- check everything went well
python -c "import tensor stream as tf; tf.enable_eager_execution (); print (tf.reduce_sum (tf.random_normal ([1000, 1000])))"
PS: some commands that may be useful
https://www.tensorflow.org/install/pip
uses virtualenv. Konda is more capable. Minicond is enough; complete conda is not needed
source share