2

enter image description here

When I was trying to install tensorflow from PyCharm than, I got above error. I also tried in terminal

pip3 install tensorflow

Error:Defaulting to user installation because normal site-packages is not writeable ERROR: Could not find a version that satisfies the requirement tensorflow ERROR: No matching distribution found for tensorflow

Default version: enter image description here

I just changed it by this answer

I thought the question is belongs to SO But, I changed my mind by reading the question

2 Answers2

5

TensorFlow only provides packages for Python 3.6, Python 3.7 and Python 3.8: https://pypi.org/project/tensorflow/#files (at the moment, this lists files for Python versions cp36, cp37, cp38). You are using Python 3.9, for which no TensorFlow package is available.

In addition, https://www.tensorflow.org/install says

TensorFlow is tested and supported on the following 64-bit systems:

Python 3.6–3.8
Wieland
  • 6,353
  • 3
  • 28
  • 31
  • I got the [solution](https://unix.stackexchange.com/a/640366/449077) –  Mar 21 '21 at 16:24
0

As Wieland said in earlier answer, there's no TensorFlow package in Python 3.9.

So, I felt awkward little bit. If there's no tensorflow package than how can I deal with data science and machine learning. I searched on DuckDuckGo little bit. I found a question similar to this(completely same). There's an answer which said tf-nightly(tf=TensorFlow) works in python3.9. He said also. So, I tried

pip3 install tf-nightly

Hopefully, tensorflow is working now....

  • Is it working? I mean, it's great to post this as an answer so people know it's an option, but it would be even better to confirm in the answer if it actually worked for you. – David Z Mar 21 '21 at 22:12
  • Also, as I am sure you are aware, you could use Python 3.8 and be able to do data science just fine. – SethMMorton Mar 21 '21 at 22:57
  • @SethMMorton Yes! I could. But, newer version works better than older ones. So, I chose Python 3.9.2 completely new one... –  Mar 22 '21 at 05:14
  • @DavidZ ~You can accept your own answer tomorrow~ this is what I am getting that's why I didn't mark it as an answer... –  Mar 22 '21 at 05:15
  • Newer may mean new features, but I strongly disagree that newer means a software works better. People continued to use Windows XP longer than they should just to avoid “upgrading” to the hot mess of Windows Vista. – SethMMorton Mar 22 '21 at 05:37
  • @Istiak sure but that's separate from what my comment was talking about. Your answer ends with "Hopefully, tensorflow is working now...." and I'm suggesting you replace that with a confirmation of whether it is or isn't actually working. – David Z Mar 22 '21 at 18:05
  • @DavidZ Oh! Yes It's working.... –  Mar 23 '21 at 04:57