jorisvandenbossche commented on code in PR #37533:
URL: https://github.com/apache/arrow/pull/37533#discussion_r1482903166
##########
python/pyarrow/array.pxi:
##########
@@ -3570,11 +3570,14 @@ cdef class FixedShapeTensorArray(ExtensionArray):
def to_numpy_ndarray(self):
"""
- Convert fixed shape tensor extension array to a numpy.ndarray with
zero copy.
- First dimension of ndarray will be the length of the fixed shape
tensor array
+ Convert fixed shape tensor extension array to a multi-dimensional
numpy.ndarray.
+
+ The resulting ndarray will have (ndim + 1) dimensions.
+ The size of the first dimension will be the length of the fixed shape
tensor array
and the rest of the dimensions will match the permuted shape of the
fixed
shape tensor.
+ The conversion is zero-copy.
Review Comment:
Small nit: this is only if the conversion to numpy is zero-copy (i.e.
primitive numeric data without nulls)
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]