pip installing package in weird location - python

I'm trying to install imgui with pip with anaconda3 All of my packages are in anaconda3\Lib\site-packages but when I install imgui, it installs it in another folder on C:\Python39
Which location should I keep imgui in?

If you are installing with pip, it seems like you are installing the package from the main python installation, instead of using the virtual environment. Be sure to have your virtual environment selected when launching the command. You could usually check that if at the beginning of the line in your terminal you have the name of the virtual environment between brackets, like (anaconda3) C:\Users\...

Related

Where to Install Python Package from Source for Virtual Environment

When trying to install pycURL using pip on Windows, I kept running into errors, so I decided to try to install it from the source on github. I'm using a virtual environment through anaconda3, and I'm wondering which folder/directory I need to clone into in order to get the installation to work?
Here's a photo of the virtual environment's directory.

How to uninstall Python packages installed globally on Mac?

While writing Python code in PyCharm on Mac I installed some Python Packages not in the virtual Environment but globally. How can I check those installed Packages and delete them?
To check whether a package is installed, run
pip freeze
to get a list of all packages, then search for the package.
To uninstall a package, run
pip uninstall [package name]
Of course you have to run these commands globally (and not inside your virtual environment)
I wish you much luck 🍀
You can use pip freeze command to get all your globally installed packages and delete them

How do I automatically run on an environment with Spyder?

Sorry if I am unclear/this is a lame question, still very new to setting up my computer.
So I installed Python using Anaconda for work, and at work there are specific packages that are used internally. I used Anaconda Prompt to install these packages by creating an environment and installing internally used packages. I then check to see if the package is there.
In the Anaconda Prompt...
conda create --name environment_name python = 3.4
activate environment_name
pip install <internal package> --upgrade
pip list
However, when I try to import a package on Spyder, it does not recognize the package. Is there a way for Spyder to run code on an environment that I specify? I would like the environment to run automatically on any file that I run using Spyder, being able to pull the packages that I installed on Anaconda Prompt

Virtual Environment not working on windows - Django

After installing Virtual Environment and activating it (Scripts\activate), I ran pip freeze to show global installed modules. When I try to install any of the packages, it says they are already installed.
I tried installing virtual environment using --no-site-packages, but it didn't help either. It still shows all globally installed packages.
I installed virtualenvwrapper, but it didn't help either.
If I remove C:\Python27\Lib\site-packages from PYTHONPATH and run pip freeze, it does not show any global packages, and it does not install any packages either. There is no response, it just freezes on "Downloading package".

Installing a package in Python virtualenv still causes it to be installed globally

I installed virtualenv and created a virtual environment called ENV1.
Then I activated the environment by running 'source bin/activate'. I am sure the virtual environment is activated because the command prompt has changed, reflecting the new environment.
Then from that command prompt, I ran 'pip install lpthw.web'. I would have thought this package will get installed somewhere in the ENV1 directory, but instead it got installed in /usr/local/lib/python2.6/dist-packages/
Is this the correct behavior? Could someone please point out if I am doing something wrong.
Check which pip you are actually running (which pip), also try running pip -E path-to-your-env install ....

Categories

Resources