
May 3, 2000
7:52 a.m.
Yes, you can create the array, point a pointer to "result->data" and fill it in. Internally, when the array is created an equivalent malloc is performed. I've changed your code below to eliminate the unecessary copying.
result = (PyArrayObject *)PyArray_FromDims(2,dimensions,PyArray_CDOUBLE);
Welcome to the wonderful world of NumPy. -Travis
9085
Age (days ago)
9086
Last active (days ago)
1 comments
2 participants
participants (2)
-
Travis Oliphant
-
Vanroose Wim