Sparse/dense matrix inplace operations fail due to __numpy_ufunc__ #2938
Labels
defect
A clear bug or issue that prevents SciPy from being installed or used as expected
scipy.sparse
Milestone
With current Scipy master + Numpy master, the following fails:
This used to work via
csr_matrix.__radd__
, but the current behavior in Numpy master is to pass through the exception rather than return NotImplemented, so that__radd__
is never called.Two places to fix:
(i) The scipy.spmatrix should support the
out
array argument(ii) Numpy should be fixed so that
__radd__
gets called even if the__numpy_ufunc__
mechanism ends up with the conclusion that the operation is not supported.The text was updated successfully, but these errors were encountered: