UXARRAY / uxarray

Xarray extension for unstructured climate and global weather data analysis and visualization.
https://uxarray.readthedocs.io/
Apache License 2.0
148 stars 31 forks source link

Topological Aggregations: (Node to Edge) and (Node to Face) #711

Closed philipc2 closed 2 months ago

philipc2 commented 6 months ago

Closes #719 #718 #713 #712

Overview

philipc2 commented 4 months ago

@erogluorhan

I'm going to pick this PR back up and address the changes that we've discussed in #724

Below are the following changes I'm going to make

This would look like the following in our API

# assume some uxds with a `vorticity_200hPa` variable (node-centered)
uxds = ...

# standard xarray mean
uxds['vorticity_200hPa'].mean()

# topological (i.e. grid informed) mean, average of nodes stored on each face
uxds['vorticity_200hPa'].topological_mean(destination='face')

# topological (i.e. grid informed) mean, average of the nodes composed each edge.
uxds['vorticity_200hPa'].topological_mean(destination='edge')

What do you think? I'd like to really move forward with this functionality and get the performance improvements in.

erogluorhan commented 4 months ago

Yes, all sounds good!

review-notebook-app[bot] commented 3 months ago

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

philipc2 commented 3 months ago

I'd really appreciate some help proof reading and checking for any typos in the new functions that I added, especially in the docstrings.

While reviewing, I also suggest looking over the user guide section I made for topological reductions. I'm really happy with how it turned out, and hope we can start making these sections for all of our functionality.

https://uxarray--711.org.readthedocs.build/en/711/user-guide/topological-aggregations.html

philipc2 commented 2 months ago

@rytam2

This is the pull request we briefly discussed last Monday. Whenever you wrap up with some of the other internship tasks, you can get started with reviewing this one!

philipc2 commented 2 months ago

Looks good! Any reason why we aren't supporting face and edge centered data variables yet though?

Thanks for the review! @rytam2 will be helping get support for those two methods this summer.