[vtk-developers] The numpy dataset_adaptor and Python 3

David Gobbi david.gobbi at gmail.com
Fri Aug 7 19:11:05 EDT 2015


Never mind, I fixed the problem.  Python 3 was ignoring the metaclass hooks.

On Fri, Aug 7, 2015 at 9:21 AM, David Gobbi <david.gobbi at gmail.com> wrote:

> Right now all of the tests in Common/Core pass with Python 3 except for
> TestNumpyInteface:
>
> File
> "/Users/dgobbi/Work/Kitware/vtk-gitlab/Common/Core/Testing/Python/TestNumpyInterface.py",
> line 69, in <module>
>      assert algs.all(1 + randomVec - 1 - randomVec < 1E-4)
> TypeError: unsupported operand type(s) for +: 'int' and
> 'VTKCompositeDataArray'
>
> The problem lies with the VTKArray class in dataset_adapter.py.  The
> custom numeric operations work differently in Python 3, my guess is that
> some extra type coercion is needed.  Can someone take a look?
>
>  - David
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/vtk-developers/attachments/20150807/e7788123/attachment.html>


More information about the vtk-developers mailing list