3

I'm trying to install tensorflow on my PC but I keep getting errors.

I have seen multiple posts about tensorflow installing errors online but all I found was solutions saying that the version of python was not compatible. However, I am using python 3.8 and I am using the URL for python 3.8 provided on tensorflow's website, so I don't see how that could be the issue.

The command I'm using:

python -m pip install --upgrade https://storage.googleapis.com/tensorflow/windows/cpu/tensorflow_cpu-2.2.0-cp38-cp38-win_amd64.whl

The error I'm getting:

ERROR: tensorflow_cpu-2.2.0-cp38-cp38-win_amd64.whl is not a supported wheel on this platform.

I'm using python 3.8, pip 20.1.1 and my PC is running 64 bit Windows 10.

From tensorflow's website, the requirements are :

  • Python 3.5-3.8
  • pip 19.0 or later
  • Windows 7 or later

Which are all satisfied.

Why am I getting this error?

EDIT: using only pip install tensorflow gets me the following errors:

ERROR: Could not find a version that satisfies the requirement tensorflow (from versions: none)
ERROR: No matching distribution found for tensorflow
Thibaut B.
  • 172
  • 1
  • 12
  • 1
    Could you check whether your version of python is 64bit? You can check by opening the interpreter and looking for either 32bit or amd64 – Axiumin_ Jun 04 '20 at 15:57
  • why no `pip install tensorflow`? – Viewed Jun 04 '20 at 15:58
  • @viewed: Before tensorflow was in PyPI, it had to be included via url, this could be a reason. This question could be duplicate to https://stackoverflow.com/q/38896424/4575793 - especially consider answers such as https://stackoverflow.com/a/41084963/4575793 – Cadoiz Jul 11 '20 at 23:06

1 Answers1

3

It's likely you're using the 32bit version of python 3.8 instead of the 64bit version. You can check by opening the interpreter and looking at the first line. If it has 32 bit (Intel) or something similar, then it would be the 32 bit version. To get the 64bit edition, scroll down to Files on this link https://www.python.org/downloads/release/python-380/ and pick up the x86-64 version.

Axiumin_
  • 2,107
  • 2
  • 15
  • 24
  • Another possibility (if you're on a system that uses multiple versions of python, like me) is that the version you're installing for needs to be the default python version. Even if you install with `pip3.8` you still need to change the default python version. – DavisDude Apr 08 '21 at 03:23