issues with bbox filtering

Hi All,
I'm playing around with filtering out particles from an SPH data set using the bounding box. I have a (somewhat lengthy but not complicated) notebook that highlights some of the capabilities (and an issue that I've found) here:
http://nbviewer.ipython.org/gist/dnarayanan/517b736c9bb0cd72a6fa
The notebook does 3 things:
1. It first loads a snapshot from a cosmological simulation, and does a projection plot.
2. It then sets a smaller bounding box, and attempts to zoom in on that region (centered on the max density). This works great.
3. Perplexingly, though, when I try basically the exact same code (the section after the second image) but with a different snapshot in the same simulation, I get a particle out of bounds error.
One relevant clue is that this error only comes when trying to access smoothed quantities (i.e. the snippets where I try to access [as an example] the SFR gives no problems). Probably obvious, but this is the bleeding edge yt (most recent update).
Any thoughts would definitely be welcome.
thanks, desika

Desika,
Is it possible that the bounds that you're providing to yt are in absolute units (not in comoving), and that in the different dataset, those bounds are no longer valid (e.g. if it were an early dataset at higher z so the volume is smaller in absolute coordinates)? Just an idea.
Also, when you get this working, it might be a good notebook to include in the cookbook of the documentation for how to explore an SPH dataset.
Cameron
On Mon, Jun 23, 2014 at 7:57 AM, Desika Narayanan dnarayan@haverford.edu wrote:
Hi All,
I'm playing around with filtering out particles from an SPH data set using the bounding box. I have a (somewhat lengthy but not complicated) notebook that highlights some of the capabilities (and an issue that I've found) here:
http://nbviewer.ipython.org/gist/dnarayanan/517b736c9bb0cd72a6fa
The notebook does 3 things:
- It first loads a snapshot from a cosmological simulation, and does a
projection plot.
- It then sets a smaller bounding box, and attempts to zoom in on that
region (centered on the max density). This works great.
- Perplexingly, though, when I try basically the exact same code (the
section after the second image) but with a different snapshot in the same simulation, I get a particle out of bounds error.
One relevant clue is that this error only comes when trying to access smoothed quantities (i.e. the snippets where I try to access [as an example] the SFR gives no problems). Probably obvious, but this is the bleeding edge yt (most recent update).
Any thoughts would definitely be welcome.
thanks, desika
yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org

Hey Cameron,
Thanks for checking in!
I had originally wondered about this too, and you're right that the snaps considered in the notebook are slightly different z (z=1.3 vs 1.5). You're also right that reducing the size of the filtered bbox for the second snap (the one that throws currently) fixes the problem.
The part of this train of thought that stumped me is that all of the bounds of the filtered bbox are within the edges of the first domain that I construct - i.e. when I first load the snapshot with some huge boxsize (1e5 kpc), then even with the re-centering the new smaller bbox that I'm using for filtering lies within the ds1.domain_left_edge, right_edge etc. It could be that I'm understanding how the bbox filtering works incorrectly though.
thanks -d
On Tue, Jun 24, 2014 at 8:11 PM, Cameron Hummels chummels@gmail.com wrote:
Desika,
Is it possible that the bounds that you're providing to yt are in absolute units (not in comoving), and that in the different dataset, those bounds are no longer valid (e.g. if it were an early dataset at higher z so the volume is smaller in absolute coordinates)? Just an idea.
Also, when you get this working, it might be a good notebook to include in the cookbook of the documentation for how to explore an SPH dataset.
Cameron
On Mon, Jun 23, 2014 at 7:57 AM, Desika Narayanan dnarayan@haverford.edu wrote:
Hi All,
I'm playing around with filtering out particles from an SPH data set using the bounding box. I have a (somewhat lengthy but not complicated) notebook that highlights some of the capabilities (and an issue that I've found) here:
http://nbviewer.ipython.org/gist/dnarayanan/517b736c9bb0cd72a6fa
The notebook does 3 things:
- It first loads a snapshot from a cosmological simulation, and does a
projection plot.
- It then sets a smaller bounding box, and attempts to zoom in on that
region (centered on the max density). This works great.
- Perplexingly, though, when I try basically the exact same code (the
section after the second image) but with a different snapshot in the same simulation, I get a particle out of bounds error.
One relevant clue is that this error only comes when trying to access smoothed quantities (i.e. the snippets where I try to access [as an example] the SFR gives no problems). Probably obvious, but this is the bleeding edge yt (most recent update).
Any thoughts would definitely be welcome.
thanks, desika
yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- Cameron Hummels Postdoctoral Researcher Steward Observatory University of Arizona http://chummels.org
yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org

Hmm. This may have something to do with a lagrangian code too. Perhaps someone who has more experience with SPH in yt should weigh in on this one. Sorry I don't have the answer!
Cameron
On Wed, Jun 25, 2014 at 5:52 AM, Desika Narayanan dnarayan@haverford.edu wrote:
Hey Cameron,
Thanks for checking in!
I had originally wondered about this too, and you're right that the snaps considered in the notebook are slightly different z (z=1.3 vs 1.5). You're also right that reducing the size of the filtered bbox for the second snap (the one that throws currently) fixes the problem.
The part of this train of thought that stumped me is that all of the bounds of the filtered bbox are within the edges of the first domain that I construct - i.e. when I first load the snapshot with some huge boxsize (1e5 kpc), then even with the re-centering the new smaller bbox that I'm using for filtering lies within the ds1.domain_left_edge, right_edge etc. It could be that I'm understanding how the bbox filtering works incorrectly though.
thanks -d
On Tue, Jun 24, 2014 at 8:11 PM, Cameron Hummels chummels@gmail.com wrote:
Desika,
Is it possible that the bounds that you're providing to yt are in absolute units (not in comoving), and that in the different dataset, those bounds are no longer valid (e.g. if it were an early dataset at higher z so the volume is smaller in absolute coordinates)? Just an idea.
Also, when you get this working, it might be a good notebook to include in the cookbook of the documentation for how to explore an SPH dataset.
Cameron
On Mon, Jun 23, 2014 at 7:57 AM, Desika Narayanan <dnarayan@haverford.edu
wrote:
Hi All,
I'm playing around with filtering out particles from an SPH data set using the bounding box. I have a (somewhat lengthy but not complicated) notebook that highlights some of the capabilities (and an issue that I've found) here:
http://nbviewer.ipython.org/gist/dnarayanan/517b736c9bb0cd72a6fa
The notebook does 3 things:
- It first loads a snapshot from a cosmological simulation, and does a
projection plot.
- It then sets a smaller bounding box, and attempts to zoom in on that
region (centered on the max density). This works great.
- Perplexingly, though, when I try basically the exact same code (the
section after the second image) but with a different snapshot in the same simulation, I get a particle out of bounds error.
One relevant clue is that this error only comes when trying to access smoothed quantities (i.e. the snippets where I try to access [as an example] the SFR gives no problems). Probably obvious, but this is the bleeding edge yt (most recent update).
Any thoughts would definitely be welcome.
thanks, desika
yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
-- Cameron Hummels Postdoctoral Researcher Steward Observatory University of Arizona http://chummels.org
yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org
participants (2)
-
Cameron Hummels
-
Desika Narayanan