ubuntu-python2.7 Installing Scipy,numpy,matplotlib and Pip

Source: Internet
Author: User
Tags deprecated

First, 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 ()

Second, Pip

1, first say what is PIP
Pip is "A tool for installing and managing Python packages.", which means Pip is a Python software Installation tool
2, the following describes how to install PIP under Linux
Download Pip to/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
If prompted:-bash:wget:command not found
Then install wget and do the following:


To extract the installation pip
# TAR-XZVF Pip-1.5.4.tar.gz
# CD pip-1.5.4
# python setup.py Install

If the installation reports the following error:
Traceback (most recent):
File "setup.py", line 6, <module>
From Setuptools import Setup, find_packages
Importerror:no module named Setuptools

Then we need to install the Setuptools package first.
(1) Download Setuptools package
# wget http://pypi.python.org/packages/source/s/setuptools/setuptools-2.0.tar.gz
(2) Unzip the Setuptools bag
# tar ZXVF setuptools-2.0.tar.gz
# CD setuptools-2.0
(3) Compiling setuptools
# python setup.py Build
(4) Start to perform Setuptools installation
# python setup.py Install

After the installation completes the Setuptools package, re-executes:
# cd/usr/local/src/pip-1.5.4
# python setup.py Install
The PIP installation is now complete

3, the use of Linux pip parameters
# 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 are 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, which is only logs failures. This log was active by default At/root/.pip/pip.log.
--log <path> Path to a verbose appending log. This log was inactive by default.
--proxy <proxy> Specify a proxy in the form [User:[email protected]]proxy.server:port.
--timeout <sec> Set The socket timeout (default 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 Installing Scipy,numpy,matplotlib and Pip

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.