How to use openBLAS for Windows 7 and Visual Studio 2013

2,694 views
Skip to first unread message

James

unread,
Apr 29, 2015, 3:17:49 PM4/29/15
to openbla...@googlegroups.com
Hi,
I'm trying to replace BLAS with openBLAS. My OS is Windows 7, and I'm using Visual Studio 2013.
I've downloaded the binary packages, and there were .dll files and .a files.
Actually, when I used the BLAS, there were .dll files and .lib files, but I don't know how to use .a files for open BLAS.
I know this might be a silly question, but could you give an easy explanation?
 
Thanks

Zhang Xianyi

unread,
Apr 29, 2015, 4:25:45 PM4/29/15
to James, openbla...@googlegroups.com
Hi James,

The lib/libopenblas.a is the static library for Mingw (gcc) on Windows. The lib/libopenblas.dll.a is the import library for Visual Studio, as same as .lib in your case.

The bin/libopenblas.dll is the shared library (dll) for mingw and Visual Studio.

Xianyi

--
You received this message because you are subscribed to the Google Groups "OpenBLAS-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to openblas-user...@googlegroups.com.
To post to this group, send email to openbla...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Message has been deleted

Zhang Xianyi

unread,
Apr 29, 2015, 4:46:38 PM4/29/15
to James, openbla...@googlegroups.com


2015-04-29 15:39 GMT-05:00 James <pur...@gmail.com>:
Thanks for your reply.
Then, is it ok to use libopenbls.dll.a in the same way as the .lib without chaning .a to .lib?

I think you can change or not change .dll.a to .lib.
 

2015년 4월 29일 수요일 오후 3시 25분 45초 UTC-5, Zhang Xianyi 님의 말:

James

unread,
Apr 29, 2015, 4:47:51 PM4/29/15
to openbla...@googlegroups.com
Thanks for your reply.
Then is it ok to use libopenblas.dll.a in the same way as the .lib without changing .a to .lib?
 
If I use binary packages, is it ok to follow the instructions from the step 'Use OpenBLAS .dll library in Visual Studio' on the webpage on 'How to use OpenBLAS in Microsoft Visual Studio' (https://github.com/xianyi/OpenBLAS/wiki/How-to-use-OpenBLAS-in-Microsoft-Visual-Studio#use-openblas-dll-library-in-visual-studio)? Do I still need to install MinGW when I use binary packages?
 
I know these questions are so basic. Please understand me. Thanks!
 
 
 

2015년 4월 29일 수요일 오후 3시 25분 45초 UTC-5, Zhang Xianyi 님의 말:
Hi James,

Zhang Xianyi

unread,
Apr 29, 2015, 4:56:13 PM4/29/15
to James, openbla...@googlegroups.com
2015-04-29 15:47 GMT-05:00 James <pur...@gmail.com>:
Thanks for your reply.
Then is it ok to use libopenblas.dll.a in the same way as the .lib without changing .a to .lib?
 
If I use binary packages, is it ok to follow the instructions from the step 'Use OpenBLAS .dll library in Visual Studio' on the webpage on 'How to use OpenBLAS in Microsoft Visual Studio' (https://github.com/xianyi/OpenBLAS/wiki/How-to-use-OpenBLAS-in-Microsoft-Visual-Studio#use-openblas-dll-library-in-visual-studio)? Do I still need to install MinGW when I use binary packages?


You can follow the FAQ. I think you need the dll from MinGW.  However, you don't need install MinGW by yourself. We already uploaded the necessary dlls to sf.net (https://sourceforge.net/projects/openblas/files/v0.2.14/), e.g. mingw32_dll.zip for 32-bit, mingw64_dll.zip for 64-bit. 

Please download the right the dll zip and put the dlls with libopenblas.dll.


Xianyi

James

unread,
Apr 29, 2015, 5:26:17 PM4/29/15
to openbla...@googlegroups.com, pur...@gmail.com
I resolved the problem. Thanks!
 
But I still have a question.
I'm using openBLAS since I heard that it is faster than BLAS in dealing with matrices in Armadillo.
But after replacing BLAS with openBLAS, the calculation of pinv() became slower than before.
Do you know any possible reasons?
 
Thanks again!
 

2015년 4월 29일 수요일 오후 3시 56분 13초 UTC-5, Zhang Xianyi 님의 말:

Zhang Xianyi

unread,
Apr 29, 2015, 5:29:56 PM4/29/15
to James, openbla...@googlegroups.com
What's your BLAS? Is it netlib reference BLAS implementation? What's the matrix size by calling pinv()?

James

unread,
Apr 29, 2015, 5:39:43 PM4/29/15
to openbla...@googlegroups.com, pur...@gmail.com
Yes. It's from netlib. The matrix size is about 2500 x 2500.
I runned my program several times, and the speed for openBLAS was almost same as the BLAS.
 
Thanks

2015년 4월 29일 수요일 오후 4시 29분 56초 UTC-5, Zhang Xianyi 님의 말:

Zhang Xianyi

unread,
Apr 30, 2015, 12:32:50 AM4/30/15
to James, openbla...@googlegroups.com
Which LAPACK function did it call? gesdd?

James

unread,
Apr 30, 2015, 9:12:21 AM4/30/15
to openbla...@googlegroups.com, pur...@gmail.com
I didn't include LAPACK library. Do I still need to includ LAPCAK when I use openBLAS?
I though that if I use openBLAS, I don't need to include BLAS and LAPACK libraries.
 
2015년 4월 29일 수요일 오후 11시 32분 50초 UTC-5, Zhang Xianyi 님의 말:
Reply all
Reply to author
Forward
0 new messages