1

Whenever I try to install package with pip (using wheel or just regular pip install numpy ->e.g), pip installs new package to location where Anaconda holds its site-packages. How do I remove that? That started happening since I installed Anaconda which I use for some tasks as python interpreter, but now I need my regular python installation.

danchy
  • 447
  • 2
  • 7
  • 18

2 Answers2

1

If you have Python 3 installed but you see that which pip points to your Anaconda installation, try using pip3 instead - if it is available then you will see that which pip3 points to your Pythons installation path instead of your Anaconda path. Same with which python3.

PHPirate
  • 7,023
  • 7
  • 48
  • 84
  • but what if pip3 directs to "/c/ProgramData/Anaconda3/Scripts/pip3" ? – David Muñoz Tord Jun 21 '23 at 14:37
  • @DavidMuñozTord If you really want to have both installations available in the command prompt (not something I would recommend), I would probably try creating an alias using the full path to the correct executable: https://stackoverflow.com/a/21040825/4126843 – PHPirate Jun 22 '23 at 07:44
0

Instead of just writing pip instal ... in the command line, which apparently points to your Anaconda installation, you can navigate (using the cd command) to your Python installation and invoke the pip.exe file located somewhere there.

I guess you could try renaming one of pip.exe files (the one in Anaconda or the one in Python) to something else (e.g. pipanadonda.exe), and then you will be able to call them separately from the command line.

jmd_dk
  • 12,125
  • 9
  • 63
  • 94
  • I think it is bad advice to recommend renaming an exectuable like that - what if pip is updated? Then you're back in the same situation as before. Better advice is to fully specify the path to the appropriate pip that you want to use, e.g., `C:\Python36\Scripts\pip.exe install 3to2` FWIW, this is also probably easier than using `cd` to navigate to the directory every time too. – darthbith Dec 28 '16 at 21:45
  • Agreed, renaming the file is not good practice, and should properly not be used as a final solution. However, trying it out could help OP understand what actually happens when typing a command into CMD. – jmd_dk Dec 28 '16 at 21:51