-
Notifications
You must be signed in to change notification settings - Fork 32
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
Regional Delaunay #1052
Regional Delaunay #1052
Conversation
@philipc2 got any suggestions on how I might store this information? I am not completely certain about a solid way to do so. |
Do these variables need to be cached, or can they be used once and then scrapped? Considering the computation of these variables will be pretty quick thanks to Numba, I lean towards not storing them directly as part of a |
Sorry, I think I miscommunication. I more meant, how should I return this information? Is using a dataset the best way, and constructing them all at once? Or should I have one function for each (node, face, edge) and return a np array? |
I see! I'd lean towards not having a |
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
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.
Can you test the behavior if the points are along the antemeridian? If you want to use data from the usage example, you could try the following.
uxgrid_regional.subset.bounding_circle((-180, 0), 10)
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.
@philipc2 This projection technique (sterographic) can't handle south pole points, or rather any points along the z=1 axis. I was thinking maybe using a gnomonic projection would work better and be more accurate (as this one seems to not work very well for point in polygon either, the projection is distorted and gives incorrect results when the point is close to the edge). The gnomonic projection might have the same issue at the poles though, not certain. Thoughts? Do you think gnomonic projection would give more accurate results? |
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.
can you do something like norm = np.linalg.norm(points, axis=1)
to calculate all norm at once?
also, is might faster to use set operation for filtering.
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.
Notebook changes are looking great!
One small comment below.
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.
Great work @aaronzedwick
Closes #1049 #1050 #1051
Overview
Adds
Grid.to_planar
which takes a grid and projects it to a plane, using_point_to_plane
which converts a point on the sphere to the plane. Also adds_point_to_sphere
which converts a point on a plane back to the sphere.Expected Usage
PR Checklist
General
Testing
Documentation
_
) and have been added todocs/internal_api/index.rst
docs/user_api/index.rst
Examples
docs/examples/
folderdocs/examples.rst
toctreedocs/gallery.yml
with appropriate thumbnail photo indocs/_static/thumbnails/