惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

B
Blog
Microsoft Security Blog
Microsoft Security Blog
Jina AI
Jina AI
博客园 - 叶小钗
J
Java Code Geeks
博客园 - 聂微东
博客园 - 司徒正美
大猫的无限游戏
大猫的无限游戏
阮一峰的网络日志
阮一峰的网络日志
V
V2EX
美团技术团队
WordPress大学
WordPress大学
M
MIT News - Artificial intelligence
雷峰网
雷峰网
酷 壳 – CoolShell
酷 壳 – CoolShell
GbyAI
GbyAI
罗磊的独立博客
T
The Blog of Author Tim Ferriss
aimingoo的专栏
aimingoo的专栏
T
Tailwind CSS Blog
The Cloudflare Blog
Stack Overflow Blog
Stack Overflow Blog
N
Netflix TechBlog - Medium
小众软件
小众软件

jdhao's digital space

Conversion between base64 and OpenCV or PIL Image 腾讯云对象存储博客图床开启 CDN 加速(不需要购买额外域名) Search and Replace in Multiple Files in Vim/Neovim Change Table Column Width in LaTeX Image or Table Side by Side in LaTeX LaTeX 并排显示图像或表格 Firenvim: Neovim inside Your Browser Content inside HTML tags missing in Latest Hugo? Creating Markdown Front Matter with Ultisnips Labelme JSON 标注格式转 voc XML 格式 Nifty Nvim Techniques That Make My Life Easier -- Series 6 macOS 下如何为视频制作字幕 Running Command Asynchronously inside Neovim Resolving Merge Conflict after Git Stash Pop Pylint: command not found? A Hands-on Experience with Neovim's Built-in LSP Support How to Convert PDF to Images with Imagemagick 互联网上常用缩略语集锦 File Backup in Neovim Converting PDF Pages to Images with Poppler Nifty Nvim Techniques That Make My Life Easier -- Series 5 Neovim Configuration for System-wide Use How to sort a list of tuple or list in Python -- lambda or itemgetter? Building A Vim Statusline from Scratch 人类第一颗原子弹爆炸始末 Distributed Training in PyTorch with Horovod Learning Expect Programming Essential Knowledge about SSH Nifty LaTeX Techniques -- Series 1 更改 Adsense 邮寄地址,重新寄送 PIN
What Is The Difference between pip, pip3 and pip3.6 Shipp...
2018-11-19 · via jdhao's digital space

On Windows system, if you install Python3 via Anaconda. Under Anaconda root directory, there is a directory named Scripts, in which pip.exe, pip3.exe and pip3.6.exe all exist. When we want to install a package, a natural question arises, is there any difference if I use pip install PACKAGE or pip3 install PACKAGE?

On Windows#

The three executables have exactly the same file size and file last-mod time:

If you show their version information, the output is also exactly the same. On my system, the output is:

pip 18.1 from d:\anaconda\lib\site-packages\pip (python 3.6)

So, on Windows, the three executables have no difference.

What about Linux?#

On Linux, the default python is usually Python 2. If you are a system administrator and install python2-pip package, you will see that pip and pip2 under /usr/bin are the same. If you also installed python3-pip, there will an executable named pip3 under /usr/bin. Under this situation, pip and pip2 is used for installing Python 2.X packages and pip3 is used for Python 3.

You can also verify this by using pip[3] --version. On my system (Ubuntu on Windows), the result of pip --version is:

pip 9.0.1 from /usr/lib/python2.7/dist-packages (python 2.7)

, while the output of pip3 --version is;

pip 9.0.1 from /usr/lib/python3/dist-packages (python 3.6)

It is clear that they are different.

References#