![](https://secure.gravatar.com/avatar/e7ef0b6d7a8124d74d3b9184f8ec8a53.jpg?s=120&d=mm&r=g)
Thanks Britton, this is exactly what I needed. Cheers, JC On 08/03/12 12:36, Britton Smith wrote:
Hi JC,
You can always reshape the 3D data array to a 1D array. You can try something like numpy.reshape. Also, you should be able to just do grid['Density'] without doing get_data.
Britton
On Thu, Mar 8, 2012 at 10:25 AM, Jean-Claude Passy <jcpassy@gmail.com <mailto:jcpassy@gmail.com>> wrote:
Hi all,
As far as I understand, a:
------------------------------------
region = pf.h.region(...)
density = region["Density"]
------------------------------------
will return the density field without considering cells that have subcells. How can I access ALL the data stored in the hdf5 file? I have tried to use
------------------------------------
grid = pf.h.grids[i]
rhogrid = grid.get_data("Density")
------------------------------------
but I would like to get a 1D array. Thanks for you help,
JC
_______________________________________________ yt-users mailing list yt-users@lists.spacepope.org <mailto:yt-users@lists.spacepope.org> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org