ARROW-4223: [Python] Support scipy.sparse integration#4779
ARROW-4223: [Python] Support scipy.sparse integration#4779rok wants to merge 16 commits intoapache:masterfrom
Conversation
jorisvandenbossche
left a comment
There was a problem hiding this comment.
@rok I know the PR is still indicated as draft, so all comments I made you probably were still going to do, but while looking at the diff, thought to at once comment
5b7472b to
eca7a70
Compare
ff60f58 to
75097f7
Compare
|
I think this is ready for review. |
081032b to
2ca9ed7
Compare
15b973e to
ebbbdf2
Compare
d812904 to
54ad5ad
Compare
|
@ursabot build |
There was a problem hiding this comment.
What is the purpose of the astype() calls here?
There was a problem hiding this comment.
This is a workaround for scipy bug (or lack of feature) see this issue.
There was a problem hiding this comment.
But you have if dtype_str != 'f2' above.
There was a problem hiding this comment.
Oh, yeah.. this probably should have failed. That's odd. I'll look into it tonight.
python/pyarrow/tensor.pxi
Outdated
There was a problem hiding this comment.
Could check here that the passed object is actually a scipy.sparse.coo_matrix ?
(right now the user will probably get an attribute error if you pass a different scipy matrix type)
(and the same for the other from_scipy below)
…or roundtrip test.
|
The R download failure on AppVeyor is unrelated, merging. |
|
Thanks @pitrou @mrkn and @jorisvandenbossche! :) |
This is to resolve [ARROW-4224](https://issues.apache.org/jira/browse/ARROW-4224). Please note this requires #4779 to be reviewed and merged first. Closes #4990 from rok/ARROW-4224 and squashes the following commits: d99d52d <Rok> Implementing review feedback. 4efdd35 <Rok> Adding type check to from_pydata_sparse. 759e0b3 <Rok> Adding from_pydata_sparse and to_pydata_sparse. Authored-by: Rok <rok@mihevc.org> Signed-off-by: Antoine Pitrou <antoine@python.org>
This is to resolve ARROW-4223.