[Numpy-discussion] tiny patch + Playing with strings and my own array descr (PyArray_STRING, PyArray_OBJECT).
benjamin at decideur.info
Mon Jun 19 06:46:38 CDT 2006
Le Vendredi 16 Juin 2006 20:01, Matthieu Perrot a écrit :
> I need to handle strings shaped by a numpy array whose data own to a C
> a new array descr based on PyArray_OBJECT and change its getitem/setitem
> Matthieu Perrot Tel: +33 1 69 86 78 21
> CEA - SHFJ Fax: +33 1 69 86 77 86
> 4, place du General Leclerc
> 91401 Orsay Cedex France
Seems i had the similar problem when i tried to use numpy to map STL's C++
vector (which are contiguous structures). I actually tried to overload the
getitem() field of my own dtype to build python wrappers at runtime around
the allocated C objects array (ie. NOT an array of Python Object).
Actually your suggested modification seems to work for me, i dunno if it's the
right solution, still.
Is there any plans to update the trunk which something similar ?
More information about the Numpy-discussion