Skip to main content

Select Your Virtual Environment to be Used Using Pycharm

Pycharm is my favorite python IDE.
One of the reason is because I can select which virtual environment I want to use easily.

You can download it from here, https://www.jetbrains.com/pycharm/download/.
I am using Community version.

To select you virtual environment, go to File > Settings












Project > Project Interpreter > Select 'Show All'

Choose you python.exe file in your virtual environment. Check my post on How to Create Virtual Environment if you don't know how to get it.

Done.

Comments

Popular posts from this blog

How to Create Virtual Environment?

So, what is virtual environment actually? The main purpose of Python virtual environments is to create an isolated environment for Python projects. This means that each project can have its own dependencies, regardless of what dependencies every other project has. For example, I create a virtual environment(v.env) named env_1 . Inside this env_1, I install python 3.5 and tensorflow 1.8. Then I can create another v.env named env_2 . In env_2, I install python 3.6 and tensorflow 1.10. Using Virtual Environment If I want to use python 3.6 and tensorflow 1.10, I can use python.exe file in env_2 to run my python script. If I wish to use python 3.5 and tensorflow 1.8, I can use python.exe file in env_2 to run my python script. Without Virtual Environment I install python 3.6 and tensorflow 1.10 in the system, and I wish to use tensorflow 1.8, I have to uninstall tensorflow 1.10 and install tensorflow 1.8 in order to use tensorflow 1.8 library. Can you note the difference?