<meta http-equiv="Content-Type" content="text/html; charset=utf-8"><div dir="ltr"><div>It seems that the problem is in the evaluation of 'end', which gets set to 0. I don't know how the  ds.index._particle_indices container (which p_ind is set to) is supposed to look, but it's got an awful lot of zeros packed in front. In fact, of the 8017 elements, 5655 of them are exactly 0. <br><br></div><div>Looking at line 76 with the debugger, p_ind[<a href="http://g2.id">g2.id</a> - g2._id_offset + 1] = p_ind[1000 - 1 + 1] = p_ind[1000] = 0.<br></div><div><br>Is this normal? Doesn't make sense to me, since there are 9000+ particles in this time step. <br><br></div><div>Jason<br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 11, 2015 at 1:17 PM, Nathan Goldbaum <span dir="ltr"><<a href="mailto:nathan12343@gmail.com" target="_blank">nathan12343@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">If I had access to the dataset, I would put a breakpoint before line 76 in your traceback here:<div><br></div><div><div>/home/jeg/yt/yt/frontends/flash/io.pyc in _read_particle_coords(self, chunks, ptf)</div><div>     74                 start = p_ind[<a href="http://g1.id" target="_blank">g1.id</a> - g1._id_offset]</div><div>     75                 end = p_ind[<a href="http://g2.id" target="_blank">g2.id</a> - g2._id_offset + 1]</div><div>---> 76                 x = np.asarray(p_fields[start:end, px], dtype="=f8")</div><div>     77                 y = np.asarray(p_fields[start:end, py], dtype="=f8")</div><div>     78                 z = np.asarray(p_fields[start:end, pz], dtype="=f8")</div></div><div><br></div><div>I would try to print out start and end, as well as <a href="http://g1.id" target="_blank">g1.id</a>, g1._id_offset, <a href="http://g2.id" target="_blank">g2.id</a>,and g2._id_offset.</div><div><br></div><div>This is the last frame before we leave yt and enter h5py.  For some reason start = end here, and we'd need to look at how the dataset is being read in to figure out why.</div></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On Mon, May 11, 2015 at 6:38 AM, Jason Galyardt <span dir="ltr"><<a href="mailto:jason.galyardt@gmail.com" target="_blank">jason.galyardt@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div><div><div><div>Hi all,<br><br></div>Per Matt's suggestion, I've tried accessing the FLASH particles via ['all', 'particle_mass'], to no avail. The traceback can be found here:<br><br><a href="http://paste.yt-project.org/show/5541/" target="_blank">http://paste.yt-project.org/show/5541/</a><br><br></div><div>I get the same zero-length selection exception when I use ['io', 'particle_position_x'] or ['all', 'particle_position_x'], as Yuan suggests. <br></div><div><br></div>To further check the input particle file format, I used the low-level h5py interface. I was able to read both particle position and mass. This script doesn't know about the grid, however.<br><br></div>Any other ideas?<br><br></div>Thanks,<br></div>Jason<br></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, May 9, 2015 at 9:59 PM, Yuan Li <span dir="ltr"><<a href="mailto:bear0980@gmail.com" target="_blank">bear0980@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I tried ['io', 'particle_position_x'] on my Flash data, and it seemed to work just fine. I use the latest yt.<span><font color="#888888"><br><div><br></div><div>Yuan</div></font></span></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, May 9, 2015 at 7:51 PM, Nathan Goldbaum <span dir="ltr"><<a href="mailto:nathan12343@gmail.com" target="_blank">nathan12343@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">I'm not able to reproduce this using the Orbit dataset on <a href="http://yt-project.org/data" target="_blank">yt-project.org/data</a>. Unfortunately I don't think we have any other flash test datasets that use particles.<div><br></div><div>It would also help to see the full error traceback you're getting.</div></div><div><div><div class="gmail_extra"><br><div class="gmail_quote">On Sat, May 9, 2015 at 4:32 PM, Matthew Turk <span dir="ltr"><<a href="mailto:matthewturk@gmail.com" target="_blank">matthewturk@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi Jason,<br>
<br>
Don't worry about posting the data -- that's completely fine, and I<br>
think in general we should do all we can to reproduce without the<br>
dataset!  I'm wondering if perhaps there's something funny about the<br>
"io" particle field.  If you try "all" instead of "io", does it work<br>
any better?<br>
<br>
-Matt<br>
<span><br>
On Fri, May 8, 2015 at 1:01 PM, Jason Galyardt <<a href="mailto:jason.galyardt@gmail.com" target="_blank">jason.galyardt@gmail.com</a>> wrote:<br>
</span><div><div>> Hi all,<br>
><br>
> Has anyone had success accessing deposited particle data generated with<br>
> FLASH? It appears in the dataset derived field list, but when I go to access<br>
> it (via ds.all_data()['deposit', 'io_mass']), I get an error concerning<br>
> zero-length selection. I get the same error when I try to access the<br>
> 'standard' particle data (from ds.field_list), such as ds.all_data()['io',<br>
> 'particle_mass'].<br>
><br>
> Does this ring any bells? This very well could be user error, so please let<br>
> me know if that seems to be the case. I've pasted a basic script to<br>
> reproduce the error here:<br>
><br>
> <a href="http://paste.yt-project.org/show/5538/" target="_blank">http://paste.yt-project.org/show/5538/</a><br>
><br>
> I'd rather not post the dataset publicly, but I can send you a link, if<br>
> you're interested.<br>
><br>
> Cheers,<br>
> Jason Galyardt<br>
><br>
><br>
><br>
</div></div>> _______________________________________________<br>
> yt-users mailing list<br>
> <a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
> <a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
><br>
_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
</blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org" target="_blank">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>
</div></div><br>_______________________________________________<br>
yt-users mailing list<br>
<a href="mailto:yt-users@lists.spacepope.org">yt-users@lists.spacepope.org</a><br>
<a href="http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org" target="_blank">http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org</a><br>
<br></blockquote></div><br></div>