-
Notifications
You must be signed in to change notification settings - Fork 279
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[yt-4.0] check for bbox before reverting to all_data #2634
Conversation
Thanks for the help with thinking this through @munkm |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This absolutely makes sense. Great catch. I believe this is the only place this gets checked, and everything else just looks at is_all_data
.
That's great news! So now this example,
outputs:
(I should note this is the second time I ran this after deleting the The only other things I'm unsure about is- the |
Hm, I'm not sure. If anything I'd expect it to go the opposite way -- because regions will select particles whose smoothing length intrudes. But in this case, your bbox should filter those out. |
I'm actually only selecting
but, with the bounding_box it returns too many (but it does return all of the ones we expected),
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
AHhhhh great catch. I'm glad you added the inline comment too; it's helpful here.
Aha! I know why the bbox leads to a different number of particles. It's something to do with the periodicity. If I set I'm not entirely convinced that the periodicity works when a bounding box is applied.... edit: I'm pretty confident it doesn't! |
Assuming the tests pass I think this is good to go. I am still concerned about periodicity and bounding boxes but that might be better in a separate PR. |
PR Summary
Prior to this PR the code says if the edges of the selected region are equal to the domain edges then we need to return every particle stored on disk.
This is not true if a bounding box has been applied. I've added a check for a
_domain_override
This fixes the example I posted in #2612
PR Checklist