You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "jorisvandenbossche (via GitHub)" <gi...@apache.org> on 2023/04/26 08:54:47 UTC

[GitHub] [arrow] jorisvandenbossche commented on issue #35289: [Python] Converting from NumPy to large_string or large_binary returns not implemented

jorisvandenbossche commented on issue #35289:
URL: https://github.com/apache/arrow/issues/35289#issuecomment-1523033043

   Yes, there is indeed no specific reason for this to not work (apart from someone implementing it). 
   
   Looking at the code, this is default fallback because the `NumPyConverter` only is implemented for the non-large StringType. We have this:
   
   https://github.com/apache/arrow/blob/c38c7788915652f5bdfaa07945809efc1188980c/python/pyarrow/src/arrow/python/numpy_to_arrow.cc#L661-L666
   
   But no equivalent `Visit(const LargeStringType& type)`. The implementation for StringType is based on `ChunkedStringBuilder`, which is a chunked version of `StringBuilder`. We already have `LargeStringBuilder`, so it should certainly be possible to add a `ChunkedLargeStringBuilder` as well, so we can template the `NumPyConverter` to work with both builders.


-- 
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.

To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org

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