[Numpy-discussion] Numeric array's actual data address?

Ray S rays at blue-cove.com
Mon Jan 31 16:58:29 CST 2005

If I have an array N:

 >>> N = Numeric.zeros((1000,), Numeric.Float)
 >>> repr(N.__copy__)
'<built-in method __copy__ of array object at 0x00809F00>'

What is the actual address of the first element? Or, as an offset from the 

numarray gives us that:
 >>> N = numarray.zeros((1000,), numarray.Float)
 >>> N.info()
class: <class 'numarray.numarraycore.NumArray'>
shape: (1000,)
strides: (8,)
byteoffset: 0
bytestride: 8
itemsize: 8
aligned: 1
contiguous: 1
data: <memory at 009d67b8 with size:8000 held by object 009d6798 aliasing 
object  00000000>
byteorder: little
byteswap: 0
type: Float64

In numarray, the offset appears to be 20.
If I try to use memmove() to fill a Numeric array it faults when using an 
offset of 20...


More information about the Numpy-discussion mailing list