LinuxQuestions.org
Visit Jeremy's Blog.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 10-24-2009, 02:50 PM   #1
statguy
Member
 
Registered: Sep 2004
Location: Ontario, Canada
Distribution: Slackware 14.2, current
Posts: 416

Rep: Reputation: 36
Confused about LAPACK, ATLAS and BLAS


A piece of software I want to compile requires LAPACK. Fine, I go to SlackBuilds.org and under the lapack page is the following:

Quote:
Install an optimized BLAS instead of the reference BLAS from Netlib if you
wish to improve LAPACK's performance. Otherwise, use the BLAS build script
provided at Slackbuilds.org. You may also build your own tuned lapack library
with ATLAS.
The BLAS library on SlackBuilds is not optimized, so I checked out ATLAS. In its install directions, I find the following:

Quote:
ATLAS natively provides only a relative handful of the routines which comprise LAPACK. However, ATLAS is designed so that its routines can easily be added to Netlib's standard LAPACK in order to get a full LAPACK library.
It then gives some instructions on compiling ATLAS with LAPACK installed and later it tells how to add LAPACK when ATLAS is already installed.

The quote from SlackBuilds suggests that ATLAS can build my tuned LAPACK, while ATLAS says it on does a handful of routines.

So, can anyone advise me on how best to proceed with installing these libraries?

Thanks.
 
Old 10-24-2009, 03:18 PM   #2
easuter
Member
 
Registered: Dec 2005
Location: Portugal
Distribution: Slackware64 13.0, Slackware64 13.1
Posts: 538

Rep: Reputation: 62
Hi,

Yes that package description should explicitly say that ATLAS only provides a subset of LAPACK (although the ATLAS documentation does explain how to build a full LAPACK into the package).

LAPACK uses the BLAS to perform vector-vector, matrix-vector and matrix-matrix operations, so swapping out the reference BLAS on slackbuilds.org for one tuned to your processor (Intel MKL or AMD ACML) should allow some of LAPACK's operations to run faster.
I didn't package ATLAS because it is fairly complex to build, though making a SlackBuild for it is on my to-do list.

The reference BLAS and LAPACK were a quick-and-dirty way to get SciPy installed on my computer, and for most small projects they work just fine.
When you need to process large amounts of data or are doing tons of matrix-matrix operations then having a fast BLAS and LAPACK are really necessary.

Also, what software are you trying to install? Perhaps we can help.

Last edited by easuter; 10-24-2009 at 03:20 PM.
 
Old 10-24-2009, 03:45 PM   #3
statguy
Member
 
Registered: Sep 2004
Location: Ontario, Canada
Distribution: Slackware 14.2, current
Posts: 416

Original Poster
Rep: Reputation: 36
Quote:
Originally Posted by easuter View Post
Also, what software are you trying to install? Perhaps we can help.
The software is called JAGS (Just Another Gibbs Sampler).

http://www-fis.iarc.fr/~martyn/software/jags/

So, can I use the SlackBuilds LAPACK with an ATLAS build, or should I go the route of building all from source?
 
Old 10-24-2009, 04:39 PM   #4
easuter
Member
 
Registered: Dec 2005
Location: Portugal
Distribution: Slackware64 13.0, Slackware64 13.1
Posts: 538

Rep: Reputation: 62
For now, you can just install BLAS and LAPACK from SlackBuilds, and if it turns out that you need extra performance, then give ATLAS a try.
 
Old 10-24-2009, 11:33 PM   #5
rworkman
Slackware Contributor
 
Registered: Oct 2004
Location: Tuscaloosa, Alabama (USA)
Distribution: Slackware
Posts: 2,559

Rep: Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351Reputation: 1351
For what it's worth (especially coming from someone who isn't really familiar with the software involved), I'd like to see an option within the lapack build script which allows you to install the atlas portions with it. In other words, if the user gets the atlas stuff separately and tells the build script that it's present, then the atlas stuff will be part of the resulting package.

Perhaps that's a horrible idea for whatever reason, and if so, LART is accepted. :-)

Last edited by rworkman; 10-26-2009 at 09:05 AM. Reason: s/blas/lapack/
 
Old 10-25-2009, 06:52 AM   #6
plasmonics
Member
 
Registered: Jan 2009
Distribution: Fedora, Gentoo, LFS
Posts: 224

Rep: Reputation: 69
I have experience with both BLAS and LAPACK and have used them along with ARPACK for eigensystem analysis. I have always used the free ones from http://www.netlib.org. The slackbuilds also compile and work fine.

However, if you want machine optimized versions, you need to purchase them from a vendor. Intel sells MKL. There are vendors that sell ACML.

I used MKL only briefly. If I remember correctly, I had to also use it in conjunction with the Intel compiler. I have not used ACML.
 
Old 10-25-2009, 07:09 AM   #7
easuter
Member
 
Registered: Dec 2005
Location: Portugal
Distribution: Slackware64 13.0, Slackware64 13.1
Posts: 538

Rep: Reputation: 62
BTW statguy, please post back and tell us if you managed to get JAGS working.
If there are problems building software using the BLAS and LAPACK from SlackBuilds I'd like to know so I can fix them.
 
Old 10-25-2009, 07:26 AM   #8
easuter
Member
 
Registered: Dec 2005
Location: Portugal
Distribution: Slackware64 13.0, Slackware64 13.1
Posts: 538

Rep: Reputation: 62
Quote:
Originally Posted by plasmonics View Post
I have experience with both BLAS and LAPACK and have used them along with ARPACK for eigensystem analysis. I have always used the free ones from http://www.netlib.org. The slackbuilds also compile and work fine.

However, if you want machine optimized versions, you need to purchase them from a vendor. Intel sells MKL. There are vendors that sell ACML.

I used MKL only briefly. If I remember correctly, I had to also use it in conjunction with the Intel compiler. I have not used ACML.
I also had MKL installed for a short period, but never had to pay for it. I think there is a license that allows you to use MKL for free as long as it is for personal or academic use, but even then it is very restricted

Goto BLAS also has a fairly strict license and isn't really free software per se, but at least they give you the source code and you can do almost anything with it as long as it isn't for commercial use.
 
Old 10-25-2009, 09:48 AM   #9
statguy
Member
 
Registered: Sep 2004
Location: Ontario, Canada
Distribution: Slackware 14.2, current
Posts: 416

Original Poster
Rep: Reputation: 36
Quote:
Originally Posted by easuter View Post
BTW statguy, please post back and tell us if you managed to get JAGS working.
If there are problems building software using the BLAS and LAPACK from SlackBuilds I'd like to know so I can fix them.
Yes, JAGS successfully compiled with the BLAS and LAPACK SlackBuilds. I ran a test suite, which took awhile, but completed without error and in agreement to the benchmark values.

Thanks.
 
Old 10-26-2009, 08:11 AM   #10
easuter
Member
 
Registered: Dec 2005
Location: Portugal
Distribution: Slackware64 13.0, Slackware64 13.1
Posts: 538

Rep: Reputation: 62
Quote:
Originally Posted by statguy View Post
Yes, JAGS successfully compiled with the BLAS and LAPACK SlackBuilds. I ran a test suite, which took awhile, but completed without error and in agreement to the benchmark values.

Thanks.
Thanks for the feedback.
I have a lot on my plate right now, but once I have some spare time I will try to make an ATLAS SlackBuild and post back here with details
 
Old 01-28-2014, 03:08 AM   #11
s09
Member
 
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84

Rep: Reputation: Disabled
Quote:
Originally Posted by statguy View Post
Yes, JAGS successfully compiled with the BLAS and LAPACK SlackBuilds. I ran a test suite, which took awhile, but completed without error and in agreement to the benchmark values.
I also need to build JAGS, but wasn't able to find a slackBuild for it so far. Could you help?
 
Old 01-28-2014, 03:19 AM   #12
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,512

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 11 .

Please do not use (old) LQ threads for off topic questions ..
http://www.linuxquestions.org/linux/rules.html


`jags.slackbuild' : https://www.google.com/webhp?hl=all#...ags.slackbuild
EDIT : See post #14

-

Last edited by knudfl; 01-28-2014 at 06:32 AM.
 
Old 01-28-2014, 03:35 AM   #13
s09
Member
 
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84

Rep: Reputation: Disabled
Quote:
Originally Posted by knudfl View Post
Please do not use (old) LQ threads for off topic questions ..
I hoped for an answer (possibly) from statguy.

I know about the slackBuild from slacky.eu that appears in google-searches, but it is not for the MCMC-sampler, but rather for some utility to browse SAMBA-shares.

Sorry if I have broken some rules -- still new here...
 
Old 01-28-2014, 06:30 AM   #14
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen DK
Distribution: PCLinuxOS2023 Fedora38 + 50+ other Linux OS, for test only.
Posts: 17,512

Rep: Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641Reputation: 3641
# 13 .

OK, you can build a Slackware package with 'src2pkg'.
http://distro.ibiblio.org/amigolinux/download/src2pkg/ → src2pkg-2.91-noarch-1.txz

... from JAGS-3.4.0.tar.gz http://sourceforge.net/projects/mcmc...GS/3.x/Source/

-
 
1 members found this post helpful.
Old 01-29-2014, 02:53 AM   #15
s09
Member
 
Registered: Jan 2014
Distribution: Slackware 14.1 (MLED 32-bit)
Posts: 84

Rep: Reputation: Disabled
Thanks, that sounds promising.
 
  


Reply

Tags
jags



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
blas library and yum soltanloo Linux - Software 3 10-05-2009 12:40 PM
blas library doesn't link lies Linux - Software 2 09-16-2007 11:58 AM
problem about blas ztdep Linux - Software 1 11-10-2006 12:39 PM
some problem about LAPACK and BLAS ztdep Linux - Software 8 08-03-2005 05:32 AM
Atlas for linux? vincebs Linux - Software 2 12-13-2003 02:21 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 01:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration