Ubuntu-Python2.7安装 scipy,numpy,matplotlib 和pip
一、 scipy,numpy,matplotlib
sudo apt-get install python-scipy
sudo apt-get install python-numpy
sudo apt-get install python-matplotlib
python
import scipy
import numpy
import pylab
scipy.test()
numpy.test()
pylab.test()
二、pip
1、先说一下什么是pip
pip 是“A tool for installing and managing Python packages.”,也就是说pip是python的软件安装工具
2、下面介绍怎么在linux下安装pip
下载pip到/usr/local/src
# cd /usr/local/src
# wget "https://pypi.python.org/packages/source/p/pip/pip-1.5.4.tar.gz#md5=834b2904f92d46aaa333267fb1c922bb" --no-check-certificate
如果提示:-bash: wget: command not found
那么安装wget,执行如下:
# yum -y install wget 解夺安装pip
# tar -xzvf pip-1.5.4.tar.gz
# cd pip-1.5.4
# python setup.py install
如果安装报下面的错:
Traceback (most recent call last):
File "setup.py", line 6, in <module>
from setuptools import setup, find_packages
ImportError: No module named setuptools 那么就要先安装setuptools包
(1)下载setuptools包
# wget http://pypi.python.org/packages/source/s/setuptools/setuptools-2.0.tar.gz
(2)解压setuptools包
# tar zxvf setuptools-2.0.tar.gz
# cd setuptools-2.0
(3)编译setuptools
# python setup.py build
(4)开始执行setuptools安装
# python setup.py install 安装完成setuptools包后,在重新执行:
# cd /usr/local/src/pip-1.5.4
# python setup.py install
至此pip安装完成 3、linux下pip使用参数
# pip --help Usage:
pip <command> [options] Commands:
install Install packages.
uninstall Uninstall packages.
freeze Output installed packages in requirements format.
list List installed packages.
show Show information about installed packages.
search Search PyPI for packages.
wheel Build wheels from your requirements.
zip DEPRECATED. Zip individual packages.
unzip DEPRECATED. Unzip individual packages.
bundle DEPRECATED. Create pybundles.
help Show help for commands. General Options:
-h, --help Show help.
-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.
--log-file <path> Path to a verbose non-appending log, that only logs failures. This log is active by default at /root/.pip/pip.log.
--log <path> Path to a verbose appending log. This log is inactive by default.
--proxy <proxy> Specify a proxy in the form [user:passwd@]proxy.server:port.
--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.
--cert <path> Path to alternate CA bundle.
Ubuntu-Python2.7安装 scipy,numpy,matplotlib 和pip的更多相关文章
- Ubuntu-Python2.7安装 scipy,numpy,matplotlib
sudo apt-get install python-scipy sudo apt-get install python-numpy sudo apt-get install python-matp ...
- Ubuntu-Python2.7安装 scipy,numpy,matplotlib (转)
sudo apt-get install python-scipy sudo apt-get install python-numpy sudo apt-get install python-matp ...
- python2.7 安装 Scipy
Numpy.scikit-learn可以直接 pip install xxx 但Scipy不能,在官网找到了安装方法: python -m pip install --user numpy scipy ...
- 安装 SciPy 和 scikit-learn 升级pip 及pip基本命令表
安装Scipy和scikit-learn出错,出错记录及当时最终解决办法 问题: 一.使用pip直接安装 直接pip install scipy C:\Users\Plain>pip insta ...
- win7 + python2.7 安装scipy
问题: 直接pip install scipy将不能正确安装,缺少文件 方法: 下载 "scipy‑0.19.0‑cp27‑cp27m‑win_amd64.whl"[90多M] ...
- ubuntu Python2.7 安装PIL问题
$sudo easy_install PIL WARNING: '' not a valid package name; please use only.-separated package name ...
- Numpy、SciPy、MatPlotLib在Python2.7.9下的安装与配置
前言: Python安装完Numpy,SciPy和MatplotLib后,可以成为非常犀利的科研利器.网上关于这三个库的安装都写得非常不错,但是大部分人遇到的问题并不是如何安装,而是安装好后因为配置不 ...
- windows下python2.7版本numpy,Scipy,matplotlib,sklearn安装
系统是windows32位,安装了python2.7.13. 安装顺序就是numpy,Scipy,matplotlib,sklearn. 首先是更新一下pip (确保pip能使用) 然后将setupt ...
- Windows系统在Python2.7环境下安装numpy, matplotlib, scipy - Lichanghao Blog
numpy, matplotlib, scipy三个包是科学计算和绘图的利器.安装它们既可以在网上下载exe安装包,也可以用python内置的包管理工具来下载安装,后者较为方便. 这几天做美赛要用到, ...
随机推荐
- sublime text怎样安装ctags来定位函数
sublime确实是一款非常不错的开发软件.用起来非常爽,里面集成了非常多插件.仅仅要安装就可以, 下来来介绍下sublime中ctags插件的安装,安装这个插件之后就能够高速定位某函数了,很方便. ...
- debian系在线安装软件apt-get命令族
一.背景 apt-get install/remove在线安装/卸载文件真是方便极了. 但是有时候安装/卸载文件不清楚文件在服务器上的实际命名,例如想安装sndfile.应该执行下面哪个命令呢? ap ...
- (三)RocketMq入门之独立线程处理业务
一.示例代码 这段代码实现了一个独立线程监听在一个特殊的消息队列上,一旦收到消息就处理并发送给MQ,然后推送给所有的消费者. import com.alibaba.rocketmq.client.ex ...
- 小半斤拔凉 支付Java 相关参考
http://git.oschina.net/littleCrazy/dianshangpingtai-zhifu http://git.oschina.net/52itstyle/springMvc ...
- SpringMVC中异常处理详解
Spring MVC处理异常最基本的就是HandlerExceptionResolver这个接口,先看张图 分析上图可以轻松总结出,spring mvc里有三种异常处理方法: 1.使用官方提供的简单异 ...
- Regression Analysis Using Excel
Regression Analysis Using Excel Setup By default, data analysis add-in is not enabled. Follow the st ...
- db papers
http://www.redbook.io/ http://db.cs.berkeley.edu/papers/ https://github.com/rxin/db-readings http:// ...
- pairRDD中算子reduceByKeyLocally
原型: def reduceByKeyLocally(func: (V, V) => V): Map[K, V] 该函数将RDD[K,V]中每个K对应的V值根据映射函数来运算,运算结果映射到一个 ...
- Ubuntu 12.04下jdk的安装与配置
由于要开始在linux下学习jsp的开发,所以就准备自己动手配置一下jdk和tomcat jdk 下载地址: http://www.oracle.com/technetwork/java/javase ...
- SQL语句的一些基本使用以及一些技巧
#SELECT 列名1, 列名2, from 表明 #SELECT id,title,content,type from news 效率相对较高#SELECT * from news *代表所有字段, ...