3

I'm using RHEL6, Python 2.6.6, and trying to install SciPy through pip.

[user@server ~]$ sudo pip install scipy
<snip>
atlas_blas_threads_info:
Setting PTATLAS=ATLAS
  libraries ptf77blas,ptcblas,atlas not found in ['/usr/local/lib64', '/usr/local/lib', '/usr/lib64/atlas']
  NOT AVAILABLE
<snip>

Yet, when I list the files in /usr/lib64/atlas:

[user@server ~]$ ls /usr/lib64/atlas
libcblas.so.3    libclapack.so.3.0  liblapack.so.3     libptcblas.so.3.0
libatlas.so.3    libcblas.so.3.0    libf77blas.so.3    liblapack.so.3.0  libptf77blas.so.3
libatlas.so.3.0  libclapack.so.3    libf77blas.so.3.0  libptcblas.so.3   libptf77blas.so.3.0

Any ideas?

  • You probably ped out the error message which says why. and besides, SciPy is already included in RHEL. – Michael Hampton Jul 12 '13 at 19:26
  • 1
    Very possible Michael. I'm unfortunately not a Python user, so thought I was posting the relevant portion. The full pip.log is located at: https://dl.dropboxusercontent.com/u/7514404/pip.log – Erik Iveson Jul 12 '13 at 19:36
  • 1
    Why don't you just install the existing package? – Michael Hampton Jul 12 '13 at 19:40
  • 1
    Mostly because the version is rather old (0.7.2) and I had already installed a package called 'pandas' that required an updated version of numpy, so was not using the rhel version of numpy. User just confirmed that the version of numpy now installed via scipy broke his pandas code. May do this: http://blog.byronjsmith.com/scipy-on-rhel.html – Erik Iveson Jul 12 '13 at 19:51
  • I wouldn't use bare bones `pip install` outside a `virtualenv` on Python, exactly for the fear of breaking things. Usually, rolling an RPM is preferred. – Deer Hunter Jul 14 '13 at 08:32

1 Answers1

2

Numpy and Scipy are strange beasts. The big annoyance is the Fortran ABI mismatch, among other things. From the installation page:

If your blas/lapack/atlas is built with g77, you must use g77 when building numpy and scipy;

If your atlas is built with gfortran, you must build numpy/scipy with gfortran.

Run ldd on the version of Atlas you have.

If libg2c.so is a dependency, g77 was used and you'll need to pass these options when building:

python setup.py build --fcompiler=gnu

Alternatively, if libgfortran.so is a dependency, it was built with gfortran and you'll need to set the proper fortran compiler:

python setup.py build --fcompiler=gnu95

As a side note, if the processors your machine is running on include SIMD support I highly suggest installing the optimized versions of atlas (e.g. atlas3-sse).

Kyle Kelley
  • 236
  • 2
  • 6