You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "raulcd (via GitHub)" <gi...@apache.org> on 2025/01/10 11:06:14 UTC

Re: [I] [C++][Python] Implement pc.equal for List arguments [arrow]

raulcd commented on issue #45167:
URL: https://github.com/apache/arrow/issues/45167#issuecomment-2582443605

   It would be interesting to do the same for other nested types like structs too:
   ```python
   >>> ty = pa.struct([pa.field('a', pa.int8()), pa.field('b', pa.float32())])
   >>> arr = pa.array([(1, 2.5), (3, 4.5), (5, 6.5)], type=ty)
   >>> arr2 = pa.array([(1, 2.5), (3, 4.5), (5, 6.5)], type=ty)
   >>> arr3 = pa.array([(1, 2.5), (3, 4.5), (5, 6.3)], type=ty)
   >>> pc.equal(arr, arr2)
   Traceback (most recent call last):
     File "<stdin>", line 1, in <module>
     File "/home/raulcd/code/arrow/python/pyarrow/compute.py", line 247, in wrapper
       return func.call(args, None, memory_pool)
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
     File "pyarrow/_compute.pyx", line 393, in pyarrow._compute.Function.call
       result = GetResultValue(
     File "pyarrow/error.pxi", line 155, in pyarrow.lib.pyarrow_internal_check_status
       return check_status(status)
     File "pyarrow/error.pxi", line 92, in pyarrow.lib.check_status
       raise convert_status(status)
   pyarrow.lib.ArrowNotImplementedError: Function 'equal' has no kernel matching input types (struct<a: int8, b: float>, struct<a: int8, b: float>)
   /home/raulcd/code/arrow/cpp/src/arrow/compute/function.cc:329  DispatchBest(&inputs)
   /home/raulcd/code/arrow/cpp/src/arrow/compute/function.cc:341  func.GetBestExecutor(inputs)
   ```


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