user3798938
user3798938

Reputation: 17

pip install scipy on virtualenv error RHEL6.5

I have already consulted these among other non stack overflow sources: Install line 'pip install scipy' fails

Installing SciPy with pip

install scipy using pip in virtualenv on ubuntu 12.04

Installing SciPy on Red Hat

RHEL6.5 distro comes with python2.6 I have installed virtualenv and python2.7. Installing packages (within my virtualenv i.e. after activating it with source MyEnvs/myEnv1/bin/activate) with: pip install {package name} and can verify, using yolk -l that my environment has the the packages I want. All was find until I tried pip install scipy I get the following error:

[~]# pip install scipy Downloading/unpacking scipy Downloading scipy-0.14.0.tar.gz (10.2MB): 10.2MB downloaded Running setup.py (path:/root/PythonVirtualEnvs/env1/build/scipy/setup.py) egg_info for package scipy

warning: no previously-included files matching '*_subr_*.f' found under directory 'scipy/linalg/src/id_dist/src'
no previously-included directories found matching 'scipy/special/tests/data/boost'
no previously-included directories found matching 'scipy/special/tests/data/gsl'
no previously-included directories found matching 'doc/build'
no previously-included directories found matching 'doc/source/generated'
no previously-included directories found matching '*/__pycache__'
warning: no previously-included files matching '*~' found anywhere in distribution
warning: no previously-included files matching '*.bak' found anywhere in distribution
warning: no previously-included files matching '*.swp' found anywhere in distribution
warning: no previously-included files matching '*.pyo' found anywhere in distribution

Installing collected packages: scipy Running setup.py install for scipy blas_opt_info: blas_mkl_info: libraries mkl,vml,guide not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64', '/usr/lib'] NOT AVAILABLE

openblas_info:
  libraries  not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64', '/usr/lib']
  NOT AVAILABLE

atlas_blas_threads_info:
Setting PTATLAS=ATLAS
  libraries ptf77blas,ptcblas,atlas not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64/atlas', '/usr/lib64/sse2', '/usr/lib64', '/usr/lib']
  NOT AVAILABLE

atlas_blas_info:
  libraries f77blas,cblas,atlas not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64/atlas', '/usr/lib64/sse2', '/usr/lib64', '/usr/lib']
  NOT AVAILABLE

/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py:1521: 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__)
blas_info:
  libraries blas not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64', '/usr/lib']
  NOT AVAILABLE

/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py:1530: 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__)
blas_src_info:
  NOT AVAILABLE

/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py:1533: 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__)
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/root/PythonVirtualEnvs/env1/build/scipy/setup.py", line 237, in <module>
    setup_package()
  File "/root/PythonVirtualEnvs/env1/build/scipy/setup.py", line 234, in setup_package
    setup(**metadata)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/core.py", line 135, in setup
    config = configuration()
  File "/root/PythonVirtualEnvs/env1/build/scipy/setup.py", line 173, in configuration
    config.add_subpackage('scipy')
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 966, in add_subpackage
    caller_level = 2)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 935, in get_subpackage
    caller_level = caller_level + 1)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 872, in _get_configuration_from_setup_py
    config = setup_module.configuration(*args)
  File "scipy/setup.py", line 12, in configuration
    config.add_subpackage('integrate')
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 966, in add_subpackage
    caller_level = 2)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 935, in get_subpackage
    caller_level = caller_level + 1)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 872, in _get_configuration_from_setup_py
    config = setup_module.configuration(*args)
  File "scipy/integrate/setup.py", line 12, in configuration
    blas_opt = get_info('blas_opt',notfound_action=2)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py", line 350, in get_info
    return cl().get_info(notfound_action)
  File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py", line 509, in get_info
    raise self.notfounderror(self.notfounderror.__doc__)
numpy.distutils.system_info.BlasNotFoundError:
    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.
Complete output from command /root/PythonVirtualEnvs/env1/bin/python2.7 -c "import setuptools, tokenize;__file__='/root/PythonVirtualEnvs/env1/build/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-mun5c1-record/install-record.txt --single-version-externally-managed --compile --install-headers /root/PythonVirtualEnvs/env1/include/site/python2.7:
blas_opt_info:

blas_mkl_info:

libraries mkl,vml,guide not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64', '/usr/lib']

NOT AVAILABLE

openblas_info:

libraries not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64', '/usr/lib']

NOT AVAILABLE

atlas_blas_threads_info:

Setting PTATLAS=ATLAS

libraries ptf77blas,ptcblas,atlas not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64/atlas', '/usr/lib64/sse2', '/usr/lib64', '/usr/lib']

NOT AVAILABLE

atlas_blas_info:

libraries f77blas,cblas,atlas not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64/atlas', '/usr/lib64/sse2', '/usr/lib64', '/usr/lib']

NOT AVAILABLE

/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py:1521: 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)

blas_info:

libraries blas not found in ['/root/PythonVirtualEnvs/env1/lib', '/usr/local/lib64', '/usr/local/lib', '/usr/lib64', '/usr/lib']

NOT AVAILABLE

/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py:1530: 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)

blas_src_info:

NOT AVAILABLE

/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py:1533: 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)

Traceback (most recent call last):

File "", line 1, in

File "/root/PythonVirtualEnvs/env1/build/scipy/setup.py", line 237, in

setup_package()

File "/root/PythonVirtualEnvs/env1/build/scipy/setup.py", line 234, in setup_package

setup(**metadata)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/core.py", line 135, in setup

config = configuration()

File "/root/PythonVirtualEnvs/env1/build/scipy/setup.py", line 173, in configuration

config.add_subpackage('scipy')

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 966, in add_subpackage

caller_level = 2)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 935, in get_subpackage

caller_level = caller_level + 1)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 872, in _get_configuration_from_setup_py

config = setup_module.configuration(*args)

File "scipy/setup.py", line 12, in configuration

config.add_subpackage('integrate')

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 966, in add_subpackage

caller_level = 2)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 935, in get_subpackage

caller_level = caller_level + 1)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/misc_util.py", line 872, in _get_configuration_from_setup_py

config = setup_module.configuration(*args)

File "scipy/integrate/setup.py", line 12, in configuration

blas_opt = get_info('blas_opt',notfound_action=2)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py", line 350, in get_info

return cl().get_info(notfound_action)

File "/root/PythonVirtualEnvs/env1/lib/python2.7/site-packages/numpy/distutils/system_info.py", line 509, in get_info

raise self.notfounderror(self.notfounderror.__doc__)

numpy.distutils.system_info.BlasNotFoundError:

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.

Cleaning up... Command /root/PythonVirtualEnvs/env1/bin/python2.7 -c "import setuptools, tokenize;file='/root/PythonVirtualEnvs/env1/build/scipy/setup.py';exec(compile(getattr(tokenize, 'open', open)(file).read().replace('\r\n', '\n'), file, 'exec'))" install --record /tmp/pip-mun5c1-record/install-record.txt --single-version-externally-managed --compile --install-headers /root/PythonVirtualEnvs/env1/include/site/python2.7 failed with error code 1 in /root/PythonVirtualEnvs/env1/build/scipy Storing debug log for failure in /root/.pip/pip.log

I verified that scipy, atlas, blas have been installed through yum. I am not sure where to go from here, I would like to find a solution that uses pip, i.e. I don't want to do easy_install scipy Please let me know if you have any suggestions.

Upvotes: 2

Views: 1057

Answers (1)

Sreedhar
Sreedhar

Reputation: 397

I have solved this problem by installing following packages:

  1. sudo apt-get install python-pip python-dev build-essential
  2. sudo apt-get install libatlas-base-dev gfortran

then install numpy or scipy and any other tools via

pip install <package--name> inside your virtualenv 

Upvotes: 0

Related Questions