SciPy

scipy.sparse.csc_matrix.sorted_indices

csc_matrix.sorted_indices()[source]

Return a copy of this matrix with sorted indices