Sparse reductions
Submitted by Desire NUENTSA
Assigned to Desire NUENTSA
Link to original bugzilla bug (#576)
Description
Created attachment 321
Support for the sparse reduction
We are thinking about adding support for the reductions in the sparse modules. See a beginning in the attached patch.
However, most of them have a very ambiguous meaning on sparse matrices : should we consider or not the implicit zero elements ?
If yes, mincoeff() or prod() should always return 0. maxcoeff() as well if the matrix is negative. Should mean() take only the nonzeros counts ?
If we work only the nonzero elements (or explicitly stored zero), then we might consider adding a proxy to let the user know that he is working only on nonzero elements. something like spmat.nonzeroCoeffs().minCoeff().
What do you think about this ?
Thanks
Patch 321, "Support for the sparse reduction":
sparse_redux