2 获取pip
3 pip基本使用
3.2 查看具体安装文件
$ pip show --files SomePackage
Name: SomePackage
Version: 1.0
Location: /my/env/lib/pythonx.x/site-packages
Files:
../somepackage/__init__.py
[...]
4 pip简明手册
4.1 安装具体版本软件
$ pip install SomePackage # latest version
$ pip install SomePackage==1.0.4 # specific version
$ pip install 'SomePackage>=1.0.4' # minimum version
4.2 Requirements文件安装依赖软件
Requirements文件
一般记录的是依赖软件列表,通过pip可以一次性安装依赖软件包:
$ pip freeze > requirements.txt
$ pip install -r requirements.txt
4.4 查看软件包信息
$ pip show pip
---
Name: pip
Version: 1.4.1
Location: /Library/Python/2.7/site-packages/pip-1.4.1-py2.7.egg
Requires:
$ pip show pyopencl
---
Name: pyopencl
Version: 2014.1
Location: /Library/Python/2.7/site-packages
Requires: pytools, pytest, decorator
4.5 搜寻
$ pip search pycuda
pycuda - Python wrapper for Nvidia CUDA
pyfft - FFT library for PyCuda and PyOpenCL
cudatree - Random Forests for the GPU using PyCUDA
reikna - GPGPU algorithms for PyCUDA and PyOpenCL
compyte - A common set of compute primitives for PyCUDA and PyOpenCL (to be created)