Complex dense matrix inversion using CUSP

67 views
Skip to first unread message

nicolar...@gmail.com

unread,
Jul 12, 2016, 5:07:51 PM7/12/16
to cusp-users
Hello,

I'm a new CUSP user and I'm wondering if there's a way to evaluate the inverse of a dense complex valued matrix (by means of LU decomposition or other methods) on device. 
If there is one, can you provide some guidance on how to proceed?
Thank you.
Nicola

Steven Dalton

unread,
Jul 12, 2016, 5:17:03 PM7/12/16
to cusp-...@googlegroups.com
Hello Nicola,

  There are no methods in CUSP to efficiently invert dense matrices on the GPU. There are some interface routines to compute the LU of a batch of matrices directly from cublas[1] but I think that method works best on a collection of relatively small matrices and not one large matrix. Magma has some simple interfaces for computing factorizations on GPUs[2]. You can also take a look at cuSolver[3] since it has some new solvers for dense matrices. I can't recommend any particular library since I haven't tried them out.

Steve


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

nicolar...@gmail.com

unread,
Jul 13, 2016, 5:20:53 AM7/13/16
to cusp-users
Hello Steve,

Thank you very much for your help. Are the cusp::lapack functions only available for host computations?
If I were to use one of those libraries you mentioned for the computation, can you use the cusp::array2d containers in some fashion?
I would still like to use cusp for some sparse operations, but in my application there are also dense operations to be computed. 
Thank you.
Nicola

Shiyin Kang

unread,
Jul 13, 2016, 8:40:01 AM7/13/16
to cusp-...@googlegroups.com
For large dense matrix inversion, you could use getrf + getrs from cuSolver.

This question and answer may help.

Steven Dalton

unread,
Jul 13, 2016, 10:39:37 AM7/13/16
to cusp-...@googlegroups.com
Yes the cusp::lapack namespace is thin wrapper around traditional host/cpu routines in the Lapacke interface.
You can definitely connect cusp::array2d containers to any external libraries you find useful. It's a bit low level but you can see how cusp interacts with external routines by looking at functions defined in the cusp::lapack namespace[1]. Generally you need to make sure the layout of the array2d is consistent with the external library and then pass the data and leading dimensions.

Steve


--
Reply all
Reply to author
Forward
0 new messages