Net-informations.com

Python PIP

Python is shipped with some basic built in modules like the "math module" for extra mathematical operators and the re module for executing regex (regular expressions). These are pre-included as they are considered useful and will be used a lot. However, more obscure or larger modules such as numpy (C based arrays) and others are not included - this is where "PIP" comes in.


Python PIP packages

In Python, PIP is a recursive acronym for "Preferred Installer Program" or "PIP Installs Packages" . It is a command-line tool that installs, reinstalls, or uninstalls PyPI packages with one simple command: "pip". A Python package contains all the files you need for a module and modules are Python code libraries you can include in your project. Most distributions of Python come with pip preinstalled . The result of this is that Python remains small, but there are immediately millions of free packages available for use if desired. It's a replacement for easy_install .

Python 2.7.9 and later (on the python2 series), and Python 3.4 and later include pip (pip3 for Python 3) by default. It defaults to installing Python packages to a system directory (such as /usr/local/lib/python3.x). This requires root access . The Python installer installs pip, so it should be ready for you to use, unless you installed an old version of Python. If you do not have PIP installed , you can download and install it from this page:

https://pypi.org/project/pip/

Install a Package using pip

Open the command line interface and tell PIP to install the package you want. In order to install the package, navigate your command line to the location of Python's script directory, and type the following:

Commonly used pip commands

pip uninstall

Use the uninstall command to remove a package:

pip --version

You can verify that pip is available by running the following command in your console:


How get the pip version in python

pip freeze

The pip freeze will output a list of installed packages and their versions. It is most useful when we want to use the same set of packages on different platforms or environments .

pip list

This command will List installed packages , including editables also these are listed in a case-insensitive sorted order.










net-informations.com (C) 2020    Founded by raps mk
All Rights Reserved. All other trademarks are property of their respective owners.
SiteMap  | Terms  | About