Windows 下 Python easy_install 的安装
下载安装python安装工具
下载地址:http://pypi.python.org/pypi/setuptools 可以找到正确的版本进行下载。win7 32位可以下载setuptools-0.6c11.win32-py2.7.exe 。
注意:win7 64位必须使用ez_setup.py进行安装。方法是下载ez_setup.py后,在cmd下执行 python ez_setup.py,即可自动安装setuptools。目前没有直接的exe安装版本。
下载完成后双击执行安装文件,即可在D:\Program Files\python2.7\scripts下安装easy_install。包含一个easy_install.exe,然后进行环境变量设置,在系统环境变量中做如下设置:(也就是将D:\Program Files\python2.7\scripts添加到环境变量中)


此时可以在控制台看easy_install 是否安装上了。 Microsoft Windows [版本 6.1.7600]
版权所有 (c) 2009 Microsoft Corporation。保留所有权利。
C:\Users\zhuyupeng>easy_install
error: No urls, filenames, or requirements specified (see --help)
上面这种方式不正确,需要使用下面的方式:
C:\Users\zhuyupeng>easy_install virtualenv
Searching for virtualenv
Best match: virtualenv 1.7.2
Processing virtualenv-1.7.2-py2.7.egg
virtualenv 1.7.2 is already the active version in easy-install.pth
Installing virtualenv-script.py script to D:\Program Files\Python2.7\Scripts
Installing virtualenv.exe script to D:\Program Files\Python2.7\Scripts
Installing virtualenv.exe.manifest script to D:\Program Files\Python2.7\Scripts
Installing virtualenv-2.7-script.py script to D:\Program Files\Python2.7\Scripts
Installing virtualenv-2.7.exe script to D:\Program Files\Python2.7\Scripts
Installing virtualenv-2.7.exe.manifest script to D:\Program Files\Python2.7\Scri
pts
Using d:\program files\python2.7\lib\site-packages\virtualenv-1.7.2-py2.7.egg
Processing dependencies for virtualenv
Finished processing dependencies for virtualenv
安装lxml:
C:\Users\zhuyupeng> 如果直接使用:easy_install lxml
C:\Users\zhuyupeng> easy_install lxml 则会出现下面问题:make sure the developing packages of libxml2 and libxslt are installed windows 可以使用安装.egg 文件的方式来安装:到网站上下载对应的lxml .egg 文件
C:\Users\zhuyupeng> easy_install D:\Program Files\Python2.7\lxml-2.3.py2.7.win32.egg 注:对于*.exe 文件这样也可以安装 通过这样的方式就可以安装成功了:可以通过在控制台输入:easy_install lxml 来查看: Microsoft Windows [版本 6.1.7600]
版权所有 (c) 2009 Microsoft Corporation。保留所有权利。
C:\Users\zhuyupeng>easy_install lxml
Searching for lxml
Best match: lxml 2.3.4
Adding lxml 2.3.4 to easy-install.pth file
Using d:\program files\python2.7\lib\site-packages
Processing dependencies for lxml
Finished processing dependencies for lxml
安装了easy_install 之后安装python的库就很简单了,以后需要安装python的库的话则直接在命令行使用easy_install + libname 比如:
C:\Users\zhuyupeng>easy_install numpy
Searching for numpy
...
Processing dependencies for numpy
Finished processing dependencies for numpy
这是下载下来再安装的:
C:\Users\zhuyupeng>easy_install "D:\Program Files\Python2.7\matplotlib-1.1.0.win
32-py2.7.exe"
...
Processing dependencies for matplotlib==1.1.0
Finished processing dependencies for matplotlib==1.1.0
C:\Users\zhuyupeng>
附一个画爱心的程序:
"""
'17*x^2 - 16*|x|*y + 17*y^2 = 225'
""" import numpy as np
import matplotlib.pyplot as plt X = np.arange(-5.0, 5.0, 0.1)
Y = np.arange(-5.0, 5.0, 0.1) x, y = np.meshgrid(X, Y)
f = 17 * x ** 2 - 16 * np.abs(x) * y + 17 * y ** 2 - 225 fig = plt.figure()
cs = plt.contour(x, y, f, 0, colors = 'r')
plt.show()


Windows 下 Python easy_install 的安装的更多相关文章
- python学习:Windows 下 Python easy_install 的安装
Windows 下 Python easy_install 的安装 下载安装python安装工具下载地址:http://pypi.python.org/pypi/setuptools 可以找到 ...
- Windows下Python 3.6 安装BeautifulSoup库
- - 下载安装 安装方法如下: 到 - PIP安装 如果上一种方法安装不成功,可以用第二种方法,记住,Python3.6下是pip3. 安装方法如下: pip3 install beautifuls ...
- windows下python虚拟环境virtualenv安装和使用
前面介绍了python在ubuntu16.04环境下,python的虚拟环境virtualenv的安装,下面介绍在windows环境下的安装和使用. 环境信息 操作系统:windows10 pytho ...
- windows下Python三步安装pip
pip是用来方便地管理Python的第三方包的,由于此前玩Python仅仅是浅尝辄止,用的是python(x,y),但是这里并不代表你想用什么包都能从里面找到的,所以我把python(x,y)卸了,然 ...
- windows下python和pycharm安装及其使用
1.python安装及环境变量配置 1.1 python安装 1.1.1 python下载 官网下载:https://www.python.org/ Downloads-Windows(Mac os ...
- Windows下Python中pip安装Pillow报错总结(转载)
遇到的俩种错误1.ValueError: zlib is required unless explicitly disabled using --disable-zlib, aborting 问题原因 ...
- Windows下python环境的安装
1.下载安装包 https://www.python.org/downloads/ 2.安装 默认安装路径:C:\python27 3.配置环境变量 [右键计算机]-->[属性]-->[高 ...
- Window下Python+CUDA+PyTorch安装
1 概述 Windows下Python+CUDA+PyTorch安装,步骤都很详细,特此记录下来,帮助读者少走弯路. 2 Python Python的安装还是比较简单的,从官网下载exe安装包即可: ...
- Windows下Python安装numpy+mkl,Scipy和statsmodels
最近做时间序列分析需要用到Python中的statsmodels,但是安装过程中遇到很头疼的问题,Google.Stackover各种都没有找到合适的解决办法,而且貌似还有很多同学也在吐槽Window ...
随机推荐
- html5 乒乓球(碰撞检测)
演示地址 http://koking.8u.hanmandarin.com/html5/1.html 简单介绍 小球可以在方框内部自由运动 可以通过方向键控制黑色砖块上下左右移动去与小球发生碰撞 代码 ...
- JQuery中html()方法的注意事项
.html方法当不传参数时用来获取元素的html内容, return this[0] && this[0].nodeType === 1 ? this[0].innerHTML.rep ...
- RadioButtonList选择事件onclick
<asp:RadioButtonList ID="rbtnFInvoiceType" runat="server" onclick="check ...
- css系列教程--css文件的创建
css文件的创建:1.外部样式表:<link rel="stylesheet" type="text/css" href="mystyle.cs ...
- MAVEN项目,Eclipse启动报错:java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
由于是maven项目,tomcat在发布项目的时候没有同时发布maven依赖所添加的jar包,所以报此错误: 解决办法: 项目右键 —> 属性 -> Deployment Assembly ...
- EventBus通信
需求: 1.ActivityA打开ActivityB 2.在B中执行某操作后,同时执行A中的方法 lib下载:eventbus-2.4.0.jar jmmy 1.在EventBusTestActiv ...
- 关于css3的背景切割(background-clip)、背景原点(background-origin)的使用
一.背景切割 background-clip :border-box | padding-box | content-box 作用:为将背景图片做适当的裁剪,以适应需要. 默认格式 bac ...
- 在HTML中使用JavaScript需要注意的问题
1. 通过<script>元素的src属性可以包含来自外部域的js文件,这一点与<img>元素一样,但这让<script>元素倍显强大的同时又受争议,访问外部域js ...
- 四条命令搞定mysql主从
一 . 环境准备 先上拓扑图
- Flink Program Guide (7) -- 容错 Fault Tolerance(DataStream API编程指导 -- For Java)
false false false false EN-US ZH-CN X-NONE /* Style Definitions */ table.MsoNormalTable {mso-style-n ...