DEV Community

Cover image for Python pip, what's installed?
petercour
petercour

Posted on

4

Python pip, what's installed?

You probably use pip thousands of time if you are programming Python. pip is the package installer for Python. You can use pip to install packages from the Python Package Index and other indexes.

When creating a Python project, you do so in a virtual environment (or maybe you don't?).

pip install your_module
Enter fullscreen mode Exit fullscreen mode

Then you install packages for your project. So how do you know what all the installed modules are?

Easy, there's a command

pip list
Enter fullscreen mode Exit fullscreen mode

So if you want to know which version of a module you have, combine with grep.

ฮป  ~  pip list | grep 'tensorflow'
tensorflow (1.14.0)
tensorflow-estimator (1.14.0)
Enter fullscreen mode Exit fullscreen mode

If you are using Ubuntu Linux or similar, you may have the odd situation in which you have both pip, pip3, python and python3 installed. Did the Ubuntu creators have some evil plan?

In that case, just add 3 after the pip command. For other operating systems, you can just use Python and pip.

Related links:

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

๐Ÿ‘‹ Kindness is contagious

Please leave a โค๏ธ or a friendly comment on this post if you found it helpful!

Okay