[SciPy-user] ATLAS install has no effect
I'm following the instructions at: http://www.scipy.org/Installing_SciPy/Linux#head-40c26a5b93b9afc7e3241e1d7fd... After following the instructions for installing ATLAS, I do get the expected files: % ls /usr/lib/atlas/sse2 libblas.so.3.0 liblapack.so.3.0 However, the instructions recommend squaring a 1000x1000 matrix with and without LD_LIBRARY_PATH set to use ATLAS to test whether the installation worked. I get no difference when setting LD_LIBRARY_PATH to use ATLAS. Also, this task takes less than a second in Matlab but is taking 10.3 seconds in numpy. Any ideas how to diagnose whether numpy is using ATLAS or if my installation of ATLAS is just slow? Thanks in advance. -- View this message in context: http://old.nabble.com/ATLAS-install-has-no-effect-tp27869293p27869293.html Sent from the Scipy-User mailing list archive at Nabble.com.
On 11-Mar-10, at 3:21 PM, stair314 wrote:
However, the instructions recommend squaring a 1000x1000 matrix with and without LD_LIBRARY_PATH set to use ATLAS to test whether the installation worked. I get no difference when setting LD_LIBRARY_PATH to use ATLAS. Also, this task takes less than a second in Matlab but is taking 10.3 seconds in numpy. Any ideas how to diagnose whether numpy is using ATLAS or if my installation of ATLAS is just slow?
Can you give us the output of numpy.show_config()? David
Sure, that's a good call to know about. It looks like it's not using the same setting for library_dirs as what's in my LD_LIBRARY_PATH.
numpy.show_config() blas_info: libraries = ['blas'] library_dirs = ['/usr/lib'] language = f77
lapack_info: libraries = ['lapack'] library_dirs = ['/usr/lib'] language = f77 atlas_threads_info: NOT AVAILABLE blas_opt_info: libraries = ['blas'] library_dirs = ['/usr/lib'] language = f77 define_macros = [('NO_ATLAS_INFO', 1)] atlas_blas_threads_info: NOT AVAILABLE lapack_opt_info: libraries = ['lapack', 'blas'] library_dirs = ['/usr/lib'] language = f77 define_macros = [('NO_ATLAS_INFO', 1)] atlas_info: NOT AVAILABLE lapack_mkl_info: NOT AVAILABLE blas_mkl_info: NOT AVAILABLE atlas_blas_info: NOT AVAILABLE mkl_info: NOT AVAILABLE
ia3n@gaussian:~/theano/2_atlas% echo $LD_LIBRARY_PATH /usr/lib/atlas/sse2
----- Original Message ----- From: "David Warde-Farley" <dwf@cs.toronto.edu> To: "SciPy Users List" <scipy-user@scipy.org> Sent: Thursday, March 11, 2010 1:06:46 PM GMT -08:00 US/Canada Pacific Subject: Re: [SciPy-User] [SciPy-user] ATLAS install has no effect On 11-Mar-10, at 3:21 PM, stair314 wrote:
However, the instructions recommend squaring a 1000x1000 matrix with and without LD_LIBRARY_PATH set to use ATLAS to test whether the installation worked. I get no difference when setting LD_LIBRARY_PATH to use ATLAS. Also, this task takes less than a second in Matlab but is taking 10.3 seconds in numpy. Any ideas how to diagnose whether numpy is using ATLAS or if my installation of ATLAS is just slow?
Can you give us the output of numpy.show_config()? David _______________________________________________ SciPy-User mailing list SciPy-User@scipy.org http://mail.scipy.org/mailman/listinfo/scipy-user
On 11-Mar-10, at 4:37 PM, Ian Goodfellow wrote:
Sure, that's a good call to know about. It looks like it's not using the same setting for library_dirs as what's in my LD_LIBRARY_PATH.
LD_LIBRARY_PATH would need to have been set at build time, not just at run time. AFAIK NumPy will only link ATLAS in statically (I could be wrong about this). At the very least it needs to know what BLAS you are using at compile time. A good bet is to use site.cfg to explicitly tell NumPy's build scripts where to look for these things. David
David Warde-Farley wrote:
On 11-Mar-10, at 4:37 PM, Ian Goodfellow wrote:
Sure, that's a good call to know about. It looks like it's not using the same setting for library_dirs as what's in my LD_LIBRARY_PATH.
LD_LIBRARY_PATH would need to have been set at build time, not just at run time.
Not exactly: LD_LIBRARY_PATH only change the loader path (that is which shared libraries are loaded when a process is started, as well as dlopen).
AFAIK NumPy will only link ATLAS in statically (I could be wrong about this).
Atlas may be linked dynamically as well. On debian, ATLAS is packaged such as it also contains a full blas/lapack library, that is -llapack -lblas will link against ATLAS library. In particular, you can linked against conventional, slow, blas/lapack when building, and switching to a faster, ATLAS-enabled one - but this is debian specific, and not supported out of the box by the ATLAS build system. You can of course emulate what debian does by yourself if you know what you are doing. cheers, David
Actually, David (Cournapeau), I started off by installing your rpms linked at the top of the "Fedora Core 8, openSUSE 10.2, RHEL/Centos 5" section, so you're probably the perfect person to answer this. Should your rpm installation work with ATLAS or do I need to build numpy from source? Are there any instructions for building atlas from the ashigabou repository and then building numpy to use it? Thanks, Ian On Mar 12, 2010, at 12:05 AM, David Cournapeau wrote:
David Warde-Farley wrote:
On 11-Mar-10, at 4:37 PM, Ian Goodfellow wrote:
Sure, that's a good call to know about. It looks like it's not using the same setting for library_dirs as what's in my LD_LIBRARY_PATH.
LD_LIBRARY_PATH would need to have been set at build time, not just at run time.
Not exactly: LD_LIBRARY_PATH only change the loader path (that is which shared libraries are loaded when a process is started, as well as dlopen).
AFAIK NumPy will only link ATLAS in statically (I could be wrong about this).
Atlas may be linked dynamically as well.
On debian, ATLAS is packaged such as it also contains a full blas/ lapack library, that is -llapack -lblas will link against ATLAS library. In particular, you can linked against conventional, slow, blas/lapack when building, and switching to a faster, ATLAS-enabled one - but this is debian specific, and not supported out of the box by the ATLAS build system. You can of course emulate what debian does by yourself if you know what you are doing.
cheers,
David _______________________________________________ SciPy-User mailing list SciPy-User@scipy.org http://mail.scipy.org/mailman/listinfo/scipy-user
On 12-Mar-10, at 3:05 AM, David Cournapeau wrote:
LD_LIBRARY_PATH would need to have been set at build time, not just at run time.
Not exactly: LD_LIBRARY_PATH only change the loader path (that is which shared libraries are loaded when a process is started, as well as dlopen).
Yep, but in order for the build to detect ATLAS he'd have to have the loader path set at build time too, right?
AFAIK NumPy will only link ATLAS in statically (I could be wrong about this).
Atlas may be linked dynamically as well.
Ah okay. Well, regardless, the build doesn't seem to be finding it, according to his show_config(). David
How should I set the path at build time? I don't see anything about it in the numpy INSTALL.txt or in the instructions on the website. I tried building numpy from source rather than using the rpm and it doesn't seem to have detected the presence of ATLAS. On Mar 12, 2010, at 10:54 AM, David Warde-Farley wrote:
On 12-Mar-10, at 3:05 AM, David Cournapeau wrote:
LD_LIBRARY_PATH would need to have been set at build time, not just at run time.
Not exactly: LD_LIBRARY_PATH only change the loader path (that is which shared libraries are loaded when a process is started, as well as dlopen).
Yep, but in order for the build to detect ATLAS he'd have to have the loader path set at build time too, right?
AFAIK NumPy will only link ATLAS in statically (I could be wrong about this).
Atlas may be linked dynamically as well.
Ah okay. Well, regardless, the build doesn't seem to be finding it, according to his show_config().
David _______________________________________________ SciPy-User mailing list SciPy-User@scipy.org http://mail.scipy.org/mailman/listinfo/scipy-user
participants (4)
-
David Cournapeau
-
David Warde-Farley
-
Ian Goodfellow
-
stair314