[yt-users] Star particles error

Matthew Turk matthewturk at gmail.com
Tue Jan 3 19:18:07 PST 2012


Hi Fernando and Stephen,

I've pushed a change that I believe should fix this:

https://bitbucket.org/yt_analysis/yt/changeset/74e0a0d08c10

The issue is as Stephen noted -- to identify which fields are in a
file, yt will randomly sample the grids.  If during this random sample
it misses the grids that have particles, it won't know about all the
fields.  I believe that for the current generation of Enzo formats
(however, *not* for the provisional Enzo 3.0 format, which is still
under development) if you have star particles on, *all* grids with
star particles will have fields like creation_time and the other
attributes belonging to the particular star particle type that is
enabled.  So all we need to do is find a single grid that has
particles and make sure it participates in the random sampling.  So
that's what the patch does.

Fernando, if you are running on an installation you manage, running
"yt update" should bring you up to date with this change.  You *may*
have to wipe out existing .yt or .harrays files.  Let me know if it
does/doesn't work!

-Matt

On Tue, Jan 3, 2012 at 7:57 PM, Fernando Becerra
<becerrafernando at gmail.com> wrote:
> Thank you very much Stephen. I'll be waiting for Matt's reply.
> Also, thanks for solving the bug using SFR. Actually it was the next question I'll ask once I solve the "creation-time" problem.
>
> Regards,
> Fernando.
>
>
> On Jan 3, 2012, at 8:50 PM, Stephen Skory wrote:
>
>> Fernando and Matt,
>>
>> Fernando sent me one of his datasets and I think I know what's going
>> on. The dataset I'm looking at (g1e10s1e11dm1e12_0088) has 1449 grids,
>> but only 21 of them have (star) particles in them. Normally, when yt
>> first opens an enzo dataset and there is no .yt file in the directory,
>> it opens 20 semi-randomly chosen grids to see what fields exist in the
>> dataset. The assumption is that if these 20 grids are well-spaced
>> enough over all the levels, it should see all the fields in the
>> collective set of grids. From this, it builds a list of fields
>> (pf.h.field_list) and derived fields (pf.h.derived_field_list).
>>
>> If I force yt to check all the grids (by modifiying
>> yt/frontends/enzo/data_structures.py) for fields on Fernando's
>> dataset, the particle fields work, and I got Fernando's SFR script at
>> the very top to work (modulo a bug I discovered in the cylinder object
>> volume calculation. I just pushed a fix and it should be in the
>> development copy of yt soon. Perhaps the same time as a fix for this
>> field list issue is also made available).
>>
>> Matt - what do you think is the best solution for this? Add a ytcfg
>> parameter so users with datasets like this can simply tell yt to check
>> all grids for fields?
>>
>> --
>> Stephen Skory
>> s at skory.us
>> http://stephenskory.com/
>> 510.621.3687 (google voice)
>> _______________________________________________
>> yt-users mailing list
>> yt-users at lists.spacepope.org
>> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
>
> _______________________________________________
> yt-users mailing list
> yt-users at lists.spacepope.org
> http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org



More information about the yt-users mailing list