[Numpy-discussion] Numpy array from ctypes pointer object?

Travis Oliphant oliphant.travis at ieee.org
Wed Jul 12 12:47:50 CDT 2006

Mark Heslep wrote:
> I don't see a clean way to create a numpy array from a ctypes pointer object. Is the __array_interface_ in ctypes the thing thats missing needed to make this happen?  I've followed Albert's  Scipy cookbook on ctypes here
> On the C side the PyArray_SimpleNewFromData( ..dimensions, ...data ptr) C API does the job nicely.  Is there a ctypes paradigm for SimpleNew...?
Can you somehow call this function using ctypes?


More information about the Numpy-discussion mailing list