Python Forum
Can't install Numpy in Pycharm
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Can't install Numpy in Pycharm
#1
I have the latest Pycharm version on Windows 10

https://imgur.com/bXPM2ao

and when I try to install the library numpy through the Pycharm I get this error

https://imgur.com/992c5Mm

So I follow the instruction that Pycharm gives and I execute this line on my prompt command
pip install --user numpy

And I get this
https://imgur.com/NFR0odS

"Requirement already satisfied"

But every time I try to use numpy on pycharm I get this:

https://imgur.com/NFR0odS

What do I do?
Reply
#2
Make sure you are installing for the right version of python
When I install from shell I usually do python3.8 -m pip install numpy
I welcome all feedback.
The only dumb question, is one that doesn't get asked.
My Github
How to post code using bbtags


Reply
#3
This means that Numpy is already somehow installed in your PC. To be sure that this and if it is present this ll give you the path to the module
import numpy
path = numpy.path.abspath(numpy__module.__file__)
In case you are not able to pycharm use another editor.
And if you are not able to import on pycharm ,but able to import on another editor,in this case, you setup the environment properly
Reply
#4
Look at image 992c5Mm there you see that interpreter used now is Anaconda located at C:\..\Anaconda3\python.exe
Configure a Python interpreter PyCharm
Go in and choose your placement for python 3.8 interpreter,also this would be C:\python38\python.exe for you.
Then it will work.

Also a quick note on the error you get when try to install to Anaconda is because (base) environment in not active.
This mean that you need to this for any other shell than Anaconda prompt.
So here a active (base) then pip works for Anaconda,using cmder here
G:\
λ cd Anaconda3\

G:\Anaconda3
λ G:\Anaconda3\Scripts\activate.bat

# NumPy is of course pre-installed in Anaconda
(base) G:\Anaconda3
λ pip install numpy
Requirement already satisfied: numpy in g:\anaconda3\lib\site-packages (1.16.2)
Also note that there is conda that has same functionality as pip or a lot more,
but it's geared against Anaconda and is what should be used first when try to install to Anaconda.
Reply
#5
(Jun-26-2020, 08:08 AM)snippsat Wrote: Look at image 992c5Mm there you see that interpreter used now is Anaconda located at C:\..\Anaconda3\python.exe
Configure a Python interpreter PyCharm
Go in and choose your placement for python 3.8 interpreter,also this would be C:\python38\python.exe for you.
Then it will work.

Also a quick note on the error you get when try to install to Anaconda is because (base) environment in not active.
This mean that you need to this for any other shell than Anaconda prompt.
So here a active (base) then pip works for Anaconda,using cmder here
G:\
λ cd Anaconda3\

G:\Anaconda3
λ G:\Anaconda3\Scripts\activate.bat

# NumPy is of course pre-installed in Anaconda
(base) G:\Anaconda3
λ pip install numpy
Requirement already satisfied: numpy in g:\anaconda3\lib\site-packages (1.16.2)
Also note that there is conda that has same functionality as pip or a lot more,
but it's geared against Anaconda and is what should be used first when try to install to Anaconda.



That was precisely it. Thanks a lot.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Help for the shortest way to install a suitable version of Python, Numpy, and OpenCV. Ezzat 2 2,304 Dec-23-2021, 12:34 PM
Last Post: snippsat
  Cannot install tensorflow, numpy etc in Pycharm with Python 3.10 plumberpy 2 3,446 Oct-07-2021, 05:33 AM
Last Post: plumberpy
  What package to install to PyCharm... REGEX or RE? charlesauspicks 4 6,170 May-23-2020, 02:36 PM
Last Post: charlesauspicks
  REGEX Install Error in PyCharm charlesauspicks 1 2,776 May-14-2020, 08:10 PM
Last Post: buran
  Cannot successfully install NumPy aniketmone2017 3 7,363 Dec-29-2016, 02:14 PM
Last Post: sparkz_alot

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020