xtensor-sparse icon indicating copy to clipboard operation
xtensor-sparse copied to clipboard

Wrap scipy.sparse ?

Open tdegeus opened this issue 3 years ago • 2 comments

It's been a while that I followed this. I wonder, it there a support to wrap scipy sparse matrices, like there is in Eigen : https://pybind11-jagerman.readthedocs.io/en/stable/advanced.html#transparent-conversion-of-dense-and-sparse-eigen-data-types ?

tdegeus avatar Apr 18 '22 09:04 tdegeus

I believe from the docs, a copy is required in these cases - but I think this is also happening for dense numpy arrays with xtensor-python, and, it's a start if nothing else. I think acceptable if it's a known caveat that's highlighted.

stellarpower avatar Feb 12 '23 17:02 stellarpower

I think this is also happening for dense numpy arrays with xtensor-python

No, xtensor-python can operate on numpy arrays in place. The idea of this repo is not to depend on a python library (although an upstream package could provide bindings to python), and is not limited to 2D.

JohanMabille avatar Feb 13 '23 08:02 JohanMabille