[Yt-dev] Particles

Matthew Turk matthewturk at gmail.com
Wed Sep 9 19:47:33 PDT 2009


Hi guys,

I've noticed several of you making commits about particles.  (John,
Britton, looking at you guys.)  In recent versions of Enzo, I stuck in
a dataspace supplement that pre-computes dataspaces for different
particle types in each grid, which should makes things really cheap to
read *only* star particles, or particles of a different type.  I've
put in support for this in the yt-hg repo, but the biggest problem
with it was that I couldn't figure out the right way to address it --
so I'd like to put out there a question to you guys.

In an ideal world, if you have some data object:

data_obj

what is the best way to be able to address particles of different
types, and only get those particles?  (Let's pretend either that IO is
cheap, or we have the dataspace hack.)

For instance,

data_object.particles[type]["x"] # for instance

or maybe,

pf.h.particles[type].sphere(...)

or something?  What do you think?  Any off-the-wall ideas?

-Matt



More information about the yt-dev mailing list