From: filc e. <eka...@gm...> - 2008-09-26 00:05:50
|
I have a numpy flavor Array in an HDF5 file. I would like to access an ndarray object representing the array and do something like, x[1,2] = 3, and have that change reflected in the file. I want to use the ndarray methods to get numpy to reinterpret the format of the data before I access it. I am not sure how to do it. I can use Array.read() to get an ndarray object, but it appears that is a copy of the data, and does not provide me direct access to bytes in the file. I want to be able to access large (gigabytes) arrays of bytes, so I do not want to read the whole thing, then write the whole thing back. I realize of course that the Array class provides __getitem__ and __setitem__ style access, but I need to tell the ndarray object the layout of the data. |