[yt-users] Star Projections
Stephen Skory
s at skory.us
Tue Dec 4 13:10:56 PST 2012
Hi Munier,
> File
> "/share/home/01686/msalem/yt-x86_64/src/yt-hg/yt/data_objects/field_info_container.py",
> line 412, in __call__
> raise NeedsDataField(doesnt_have)
> yt.data_objects.field_info_container.NeedsDataField: (['creation_time'])
>
> Is anyone aware of what the issue may be? I'm wondering if enzo itself
> is not printing something yt needs here.
This last bit of your error message says what's going on - yt is
trying to access the 'creation_time' particle field and can't find it.
There are a few reasons for this - either the snapshot you're using
has no stars, has only a few stars in a few grids and yt isn't finding
it automatically, or perhaps the snapshot has a grid with no particles
at all. All are easy to test with this simple example script:
pf = load('snapshot')
all_fields = set(pf.h.derived_field_list + pf.h.field_list)
if 'creation_time' not in all_fields:
print "creation_time is probably not in this simulation"
ct_yes = 0
ct_no = 0
for g in pf.h.grids:
try:
ct = g['creation_time']
ct_yes+=1
except:
ct_no += 1
print "From %d grids, %d have stars, and %d have no particles." %
(ct_yes + ct_no, ct_yes, ct_no)
Can you run this script (modified for your situation) and report back, please?
Good luck!
--
Stephen Skory
s at skory.us
http://stephenskory.com/
510.621.3687 (google voice)
More information about the yt-users
mailing list