You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/12/07 23:08:48 UTC

[GitHub] [arrow] nealrichardson edited a comment on pull request #8650: ARROW-10530: [R] Use Converter API to convert SEXP to Array/ChunkedArray

nealrichardson edited a comment on pull request #8650:
URL: https://github.com/apache/arrow/pull/8650#issuecomment-740235400


   > > It all feels a bit weird to operate in terms of single values, i.e. via the `Append()` methods, since R does not have such concept, this has to resort to many casting.
   > 
   > This converter API was designed to operate on list-like collections of generic objects one-by-one. We have different code paths for more efficient conversion from numpy/pandas, see [here](https://github.com/apache/arrow/blob/master/cpp/src/arrow/python/numpy_to_arrow.cc).
   > 
   
   I'll observe that the PR that added the new converter API made only a [cosmetic change](https://github.com/apache/arrow/commit/87dd7e9894b2beb6310e634764177ab83eac3009#diff-af12e4188d427011f334afe5c1ad8b2aae91270eb7507c92e5318b943d1f0147) to numpy_to_arrow.cc, so maybe the new API is not so relevant for R after all?
   
   Row-based conversion might make sense when converting an R list-type object, but otherwise you'd expect something vectorized to be better. For better or worse, now that all of this row-based conversion has been implemented here, we can benchmark both ways and compare.
   
   
   
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org