pip的簡介
pip 是 Python 包管理工具,該工具提供了對Python 包的查找、下載下傳、安裝、解除安裝的功能。目前如果你在 python.org 下載下傳最新版本的安裝包,則是已經自帶了該工具。 Python 3.4+ 以上版本都自帶 pip 工具。pip這個工具,可以很友善的線上安裝依賴庫,并且,pip還有很多參數都可以幫我們去查詢一些庫資訊
pip官網:
https://pypi.org/project/pip/pip的安裝
1、Linux之Ubuntu系統安裝pip3
sudo apt install python3-pip
pip的使用方法
相關文章
Python語言學習:python常用自帶方法、頭部代碼、python調式、pip指令集合、常見概念詳細攻略(解決問題為導向)
pip:成功解決pip下載下傳時速度超慢的幾種方法
1、Find pre-release and development versions, in addition to stable versions. By default, pip only finds stable versions.
$ pip install --pre SomePackage
2、超級權限下載下傳或更新庫
pip install --upgrade scipy --use
1、pip指令集合
Usage:
pip <command> [options]
Commands:
install Install packages.
download Download packages.
uninstall Uninstall packages.
freeze Output installed packages in requirements format.
list List installed packages.
show Show information about installed packages.
check Verify installed packages have compatible dependencies.
config Manage local and global configuration.
search Search PyPI for packages.
wheel Build wheels from your requirements.
hash Compute hashes of package archives.
completion A helper command used for command completion.
help Show help for commands.
General Options:
-h, --help Show help.
--isolated Run pip in an isolated mode, ignoring environment variables and user configuration.
-v, --verbose Give more output. Option is additive, and can be used up to 3 times.
-V, --version Show version and exit.
-q, --quiet Give less output. Option is additive, and can be used up to 3 times (corresponding to
WARNING, ERROR, and CRITICAL logging levels).
--log <path> Path to a verbose appending log.
--proxy <proxy> Specify a proxy in the form [user:passwd@]proxy.server:port.
--retries <retries> Maximum number of retries each connection should attempt (default 5 times).
--timeout <sec> Set the socket timeout (default 15 seconds).
--exists-action <action> Default action when a path already exists: (s)witch, (i)gnore, (w)ipe, (b)ackup,
(a)bort).
--trusted-host <hostname> Mark this host as trusted, even though it does not have valid or any HTTPS.
--cert <path> Path to alternate CA bundle.
--client-cert <path> Path to SSL client certificate, a single file containing the private key and the
certificate in PEM format.
--cache-dir <dir> Store the cache data in <dir>.
--no-cache-dir Disable the cache.
--disable-pip-version-check
Don't periodically check PyPI to determine whether a new version of pip is available for
download. Implied with --no-index.
--no-color Suppress colored output