On Thu, 06 Jun 2019 10:40:47 -0000
"Amitoz AZAD" <rteja...@gmail.com> wrote:

> Merci Jerome,
> 
> So my understanding is that you extracted the row , column indices and the 
> data from the sparse matrix and then passed it as the normal numpy vectors?
> lut (3 tuple) the variable is your sparse matrix ?

Hi Amitoz,

Yes, this "LUT" is a 3-tuple containing the CSR representation of the sparse 
matrix. 
You can use scipy.sparse.csr_matrix to generate the sparse
represenation and retrieve those "data", "indices" and "indptr" vectors
which are compatible with my code.

Another way to do this is to use a sparsifyer on the the device, but
this requires the full matrix fits into the device's memory.
https://github.com/silx-kit/silx/pull/2625
This is ongoing work !

The most usual way is neverthless to build those vector directly when
the sparse matrix is too large to fit into memory.

Cheers,

Jerome
_______________________________________________
PyOpenCL mailing list -- pyopencl@tiker.net
To unsubscribe send an email to pyopencl-le...@tiker.net

Reply via email to