Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Installing SciPy on Ubuntu

Tags:

python

ubuntu

I have Python 2.7 running and trying to install scipy by using easy_install which returns following errors:

Searching for scipy Reading http://pypi.python.org/simple/scipy/ Reading http://www.scipy.org Reading http://sourceforge.net/project/showfiles.php?group_id=27747&package_id=19531 Reading http://new.scipy.org/Wiki/Download Best match: scipy 0.11.0 Downloading http://pypi.python.org/packages/source/s/scipy/scipy-0.11.0.zip#md5=40b700ddde9ddab643b640fff7a9d753 Processing scipy-0.11.0.zip Running scipy-0.11.0/setup.py -q bdist_egg --dist-dir /tmp/easy_install-49BQSz/scipy-0.11.0/egg-dist-tmp-KMjwKy Running from scipy source directory. /usr/lib64/python2.7/site-packages/numpy/distutils/system_info.py:1425: UserWarning:      Atlas (http://math-atlas.sourceforge.net/) libraries not found.     Directories to search for the libraries can be specified in the     numpy/distutils/site.cfg file (section [atlas]) or by setting     the ATLAS environment variable.   warnings.warn(AtlasNotFoundError.__doc__) /usr/lib64/python2.7/site-packages/numpy/distutils/system_info.py:1434: UserWarning:      Blas (http://www.netlib.org/blas/) libraries not found.     Directories to search for the libraries can be specified in the     numpy/distutils/site.cfg file (section [blas]) or by setting     the BLAS environment variable.   warnings.warn(BlasNotFoundError.__doc__) /usr/lib64/python2.7/site-packages/numpy/distutils/system_info.py:1437: UserWarning:      Blas (http://www.netlib.org/blas/) sources not found.     Directories to search for the sources can be specified in the     numpy/distutils/site.cfg file (section [blas_src]) or by setting     the BLAS_SRC environment variable.   warnings.warn(BlasSrcNotFoundError.__doc__) error:      Blas (http://www.netlib.org/blas/) libraries not found.     Directories to search for the libraries can be specified in the     numpy/distutils/site.cfg file (section [blas]) or by setting     the BLAS environment variable. 

So I installed Blas and Atalas by executing

apt-get install blas apt-get install atlas 

However, the easy_install errors don't disappear.

Thanks!

like image 459
Jack Gibson Avatar asked Jan 18 '13 21:01

Jack Gibson


People also ask

How do I get SciPy on Ubuntu?

Install SciPy in Ubuntu We need to create a virtual environment in which we will install SciPy. Let's start to install Python virtualenv and pip3 package manager that can be used to install various libraries. Run the following command: sudo apt install python3-venv python3-pip.

Is SciPy a package in Python?

SciPy is a scientific computation library that uses NumPy underneath. SciPy stands for Scientific Python. It provides more utility functions for optimization, stats and signal processing. Like NumPy, SciPy is open source so we can use it freely.

How do I know if SciPy is installed?

Check scipy Version Windows To check which version of scipy is installed, use pip show scipy or pip3 show scipy in your Windows CMD, command line, or PowerShell.


1 Answers

What worked for me:

To actually install scipy from PIP, you need packages libatlas-base-dev (libraries etc. for ATLAS/BLAS) and gfortran (GNU Fortran compiler).

Once these packages are installed, the scipy installer should finish as expected.

like image 154
Carl Ekerot Avatar answered Sep 28 '22 05:09

Carl Ekerot