scipy.sparse.csr_matrix.

sign#

csr_matrix.sign()[source]#

Element-wise sign. See numpy.sign for more information.

Returns:
signsparse array / matrix

Result of applying numpy.sign to the data of this sparse matrix.