[Numpy-discussion] correct sizeof for ndarray
nevion at gmail.com
Tue Oct 20 00:05:51 EDT 2015
I noticed an unexpected behavior of itemsize for structures with offsets
that are larger than that of a packed structure in memory. This matters
when parsing in memory structures from C and some others (recently and
HDF5/h5py detail got me for a bit).
So what is the correct way to get "sizeof" a structure? AFAIK this is the
size of the last item + it's offset. If this doesn't exist... shouldn't it?
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the NumPy-Discussion