Skip to content
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

Cookbook Revisions #23

Merged
merged 55 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
55 commits
Select commit Hold shift + click to select a range
96eacf4
start revisions
philipc2 Nov 4, 2024
7f47cd8
update outline
philipc2 Nov 4, 2024
e7fdfff
update notebook title
philipc2 Nov 4, 2024
7092188
work on grid notebook
philipc2 Nov 4, 2024
47ee68f
update notebooks
philipc2 Nov 4, 2024
ea90465
work on notebooks
philipc2 Dec 15, 2024
3210d8b
update the start of each notebook
philipc2 Dec 16, 2024
1b64648
AMS Revisions - Foundations: Populate its all the notebooks. Also upd…
erogluorhan Dec 17, 2024
f0cb12e
add recipie notebooks, work on 03
philipc2 Dec 18, 2024
ee2327a
updates to section 02
philipc2 Dec 18, 2024
4467a74
add 30km grid, work on notebooks
philipc2 Dec 19, 2024
71d356b
update 03
philipc2 Dec 20, 2024
23f8e1c
Populate the Intro-to-UXarray Notebooks (#25)
erogluorhan Jan 3, 2025
9ec84f6
try gifs for interactive notebook
philipc2 Jan 5, 2025
bf0ddc4
Merge branch 'ams-revisions' of https://github.com/ProjectPythia/unst…
philipc2 Jan 5, 2025
a58a7bc
add gifs to interactive section
philipc2 Jan 5, 2025
e0072f7
static notebooks (1)
philipc2 Jan 5, 2025
5b3bb83
data-viz, high-res, notebooks
philipc2 Jan 6, 2025
a5b0d39
update 03 notebooks, add xarray notebook
philipc2 Jan 6, 2025
03790f3
try rendered high-res notebook (2)
philipc2 Jan 6, 2025
5a2c236
try rendered high-res notebook (2)
philipc2 Jan 6, 2025
0110b50
use rendered notebook
philipc2 Jan 6, 2025
fdce96a
use rendered notebook
philipc2 Jan 6, 2025
ea1e225
update high-res notebook
philipc2 Jan 6, 2025
5a3b2d0
update notebook markdown
philipc2 Jan 6, 2025
8754d8c
update notebook markdown
philipc2 Jan 6, 2025
18d56a8
update time to learn formatting
philipc2 Jan 7, 2025
f29b22d
clean selection notebook
philipc2 Jan 7, 2025
3ad4ecd
update notebooks
philipc2 Jan 8, 2025
43ddc07
update notebooks, add e3sm data
philipc2 Jan 8, 2025
b15f61e
remove large ds
philipc2 Jan 8, 2025
26bbca6
clean up data & grid viz markdown
philipc2 Jan 8, 2025
3565d29
wrap up markdown for grid & data viz notebooks
philipc2 Jan 8, 2025
ab43def
clean up markdown for geo and high-res
philipc2 Jan 8, 2025
547abdd
update markdown in mpas-atmo and mpas-ocean
philipc2 Jan 8, 2025
b864a96
update customization and data viz markdown
philipc2 Jan 8, 2025
f3bbb21
re-add high-res notebook to config and pre-commit
philipc2 Jan 8, 2025
866e367
update markdown, update toc
philipc2 Jan 8, 2025
d16fb14
small markdown correction in mpas-atmo
philipc2 Jan 8, 2025
c09e966
Fix typos 'recipies' to 'recipes'
erogluorhan Jan 8, 2025
3c75653
Simple grammatical corrections
erogluorhan Jan 9, 2025
2f4d3fd
Rename folder 'recipies' to 'recipes' to help with typo fix
erogluorhan Jan 9, 2025
8d73ae2
run pre-commit
philipc2 Jan 9, 2025
706f7eb
delete old folders
philipc2 Jan 9, 2025
a7f0f7d
put atmo before ocean
philipc2 Jan 9, 2025
8e45ea8
add markdown for mpas-ocean
philipc2 Jan 9, 2025
9ba77b3
slightly modify mpas-ocean bullet points
philipc2 Jan 9, 2025
bda455c
add very minimal subset of e3sm data for radiative feedback
philipc2 Jan 9, 2025
40c49b1
add e3sm notebook
philipc2 Jan 9, 2025
ac3c035
small markdown correction to high-res
philipc2 Jan 9, 2025
b365aca
minor readme update
philipc2 Jan 9, 2025
7f49951
Update _toc.yml to get compare-xarray to show up
erogluorhan Jan 9, 2025
ca0fd44
update e3sm and mpas ocean notebooks
philipc2 Jan 9, 2025
a99d6f0
Merge branch 'ams-revisions' of https://github.com/ProjectPythia/unst…
philipc2 Jan 9, 2025
183c58c
small typo
philipc2 Jan 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,5 @@ repos:
additional_dependencies: [black]
- id: nbqa-pyupgrade
additional_dependencies: [pyupgrade]
exclude: foundations/quickstart.ipynb
- id: nbqa-isort
additional_dependencies: [isort]
50 changes: 33 additions & 17 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,25 +9,28 @@
[![Binder](https://binder.projectpythia.org/badge_logo.svg)](https://binder.projectpythia.org/v2/gh/ProjectPythia/unstructured-grid-viz-cookbook.git/main?labpath=notebooks)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.10403389.svg)](https://doi.org/10.5281/zenodo.10403389)

This Cookbook is a comprehensive showcase of workflows & techniques for visualizing Unstructured Grids using [UXarray](https://uxarray.readthedocs.io/).
This Cookbook is a comprehensive showcase of workflows & techniques for visualizing Unstructured Grids using [UXarray](https://uxarray.readthedocs.io/),
also providing foundational information on unstructured grids.

## Motivation

The ability to natively visualize unstructured grids is a much-needed ability within the Scientific Python Ecosystem,
The ability to natively visualize unstructured grids is much needed within the Scientific Python Ecosystem,
which poses multiple challenges and needs to:

- Not regrid the source unstructured grid to structure
- Not regrid the source unstructured grid to structured grid
- Take advantage of grid information, such as connectivity variables
- Limit the amount of pre-processing needed to prepare the data for Python visualization tools

UXarray enables such visualization methods that operate directly on unstructured grid data,
providing Xarray-styled functionality to better read in
and use unstructured grid datasets that follow standard conventions.
UXarray supports a variety of unstructured grid formats including UGRID, MPAS, SCRIP, and Exodus,
and is extendable for other formats.
UXarray enables such visualization methods that operate directly on unstructured grid data, providing
Xarray-styled functionality to better read in and use unstructured grid datasets that follow standard
conventions.

This cookbook covers an introduction to unstructured grids and UXarray,
provides an overview of the visualization methods and libraries, and showcases several UXarray visualization functions.
UXarray supports a variety of unstructured grid formats and file types including UGRID, MPAS, ICON, CAM-SE,
SCRIP, Exodus, ESMF, GEOS, and FESOM2, and is extensible for other formats.

This cookbook covers an introduction to unstructured grids and UXarray from a visualization standpoint,
providing foundational information about unstructured grids, visualization methods and libraries, and
introducing UXarray, and showcasing several UXarray visualization functions and workflows.

## Authors

Expand All @@ -47,19 +50,32 @@ provides an overview of the visualization methods and libraries, and showcases s

## Structure

This cookbook is split up into a few chapters that provide a detailed overview of how to use UXarray to work with and visualize unstructured grid datasets:
This cookbook is split up into several chapters to communicate the content efffectively with different
levels of readers:

**1. Foundations**

Here, we cover overview of the foundational topics necessary to understand the content in this cookbook,
e.g. what unstructured grids are and how they are different than structured grids, what plotting libraries
and visualization techniques exist that can be helpful for unstructured grid visualization, and we briefly
mention how UXarray is related to these.

**1. Introduction to UXarray & Unstructured Grids**
**2. Introduction to UXarray**

Here we cover what unstructured grids are and how they are different than structured grids as well as whay UXarray could play a significant role in unstructured grid visualization.
In this chapter, we provide an overview of UXarray: An Xarray-extension for unstructured grid-formatted
climate and global weather data analysis and visualization.

**2. Methods & Libraries for Unstructured Grid Visualization**
**3. Plotting with UXarray**

In this chapter, we briefly introduce plotting libraries and their specific technologies as well as rendering techniques that could be used for unstructured grid plotting and are used as part of UXarray.
We provide an overview of the UXarray plotting API along with several visualization functionality, and cases
and examples that can be realized using such UXarray functionality; Grid visualization, Data visualization,
Geographic projections and features, to name a few. Also in this section, customization and interactivaity
with UXarray plotting and considerations with high-resolution plotting are also provided.

**3. UXarray Visualization**
**4. Visualization Recipies**

Several visualization cases and examples that can be realized using UXarray are provided in this chapter; grid topology plots, polygons, points, to name a few. Also in this section, the usage of UXarray plotting API and a discussion of visualization at scale are also provided.
In this last chapter, we offer to the interested readers a set of focused workflows that can be realized
with UXarray, including visualizations of MPAS and E3SM model output.

## Running the Notebooks

Expand Down
2 changes: 1 addition & 1 deletion _config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ title: Unstructured Grids Visualization Cookbook
description: Comprehensive showcase of workflows and techniques for visualizing Unstructured Grids using UXarray
author: the <a href="https://projectpythia.org/">Project Pythia</a> Community
logo: notebooks/images/logos/pythia_logo-white-rtext.svg
copyright: "2024"
copyright: "2025"

execute:
# To execute notebooks via a Binder instead, replace 'cache' with 'binder'
Expand Down
4 changes: 2 additions & 2 deletions _static/custom.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
.bd-main .bd-content .bd-article-container {
max-width: 100%; /* default is 60em */
max-width: 100%; /* default is 60em */
}
.bd-page-width {
max-width: 100%; /* default is 88rem */
max-width: 100%; /* default is 88rem */
}
Binary file added _static/images/grids.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _static/images/uxarray-design.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
50 changes: 25 additions & 25 deletions _templates/footer-extra.html
Original file line number Diff line number Diff line change
@@ -1,27 +1,27 @@
<div class="container-fluid footer-extra">
<div class="container">
<center>
Theme by <a href="https://projectpythia.org">Project Pythia</a>. All code
in Pythia Cookbooks is licensed under
<a href="https://opensource.org/license/apache-2-0">Apache 2.0</a>. All
other non-code content is licensed under
<a href="https://creativecommons.org/licenses/by/4.0/">
Creative Commons BY 4.0 (CC BY 4.0)</a
>.
</center>
<br /><br />
<div class="row">
<p class="m-0">
<img
src="{{ pathto('_static/footer-logo-nsf.png', 1) }}"
style="float: left; width: 60px; height: 60px; margin-right: 1rem"
/>
This material is based upon work supported by the National Science
Foundation under Grant Nos. 2026863 and 2026899. Any opinions, findings,
and conclusions or recommendations expressed in this material are those
of the author(s) and do not necessarily reflect the views of the
National Science Foundation.
</p>
</div>
<div class="container">
<center>
Theme by <a href="https://projectpythia.org">Project Pythia</a>. All code
in Pythia Cookbooks is licensed under
<a href="https://opensource.org/license/apache-2-0">Apache 2.0</a>. All
other non-code content is licensed under
<a href="https://creativecommons.org/licenses/by/4.0/">
Creative Commons BY 4.0 (CC BY 4.0)</a
>.
</center>
<br /><br />
<div class="row">
<p class="m-0">
<img
src="{{ pathto('_static/footer-logo-nsf.png', 1) }}"
style="float: left; width: 60px; height: 60px; margin-right: 1rem"
/>
This material is based upon work supported by the National Science
Foundation under Grant Nos. 2026863 and 2026899. Any opinions, findings,
and conclusions or recommendations expressed in this material are those
of the author(s) and do not necessarily reflect the views of the
National Science Foundation.
</p>
</div>
</div>
</div>
</div>
44 changes: 29 additions & 15 deletions _toc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,23 +4,37 @@ parts:
- caption: Preamble
chapters:
- file: notebooks/how-to-cite
- caption: Introduction to UXarray & Unstructured Grids

- caption: Foundations
chapters:
- file: notebooks/01-foundations/unstructured-grids
- file: notebooks/01-foundations/plotting-libs
- file: notebooks/01-foundations/rendering-techniques

- caption: Introduction to UXarray
chapters:
- file: notebooks/01-intro/01-unstructured-grid-overview
- file: notebooks/01-intro/02-data-structures
- file: notebooks/01-intro/03-data-mapping
- file: notebooks/02-intro-to-uxarray/overview
- file: notebooks/02-intro-to-uxarray/grid
- file: notebooks/02-intro-to-uxarray/uxds-uxda
- file: notebooks/02-intro-to-uxarray/selection

- caption: Methods & Libraries for Unstructured Grid Visualization
- caption: Plotting with UXarray
chapters:
- file: notebooks/02-methods/01-plotting-libraries
- file: notebooks/02-methods/02-rendering-techniques
- file: notebooks/03-plotting-with-uxarray/grid-viz
- file: notebooks/03-plotting-with-uxarray/data-viz
- file: notebooks/03-plotting-with-uxarray/geo
- file: notebooks/03-plotting-with-uxarray/customization
- file: notebooks/03-plotting-with-uxarray/high-res
- file: notebooks/03-plotting-with-uxarray/compare-xarray

- caption: UXarray Visualization
- caption: Visualization Recipes
chapters:
- file: notebooks/03-uxarray-vis/01-plot-api
- file: notebooks/03-uxarray-vis/002-xarray-to-uxarray
- file: notebooks/03-uxarray-vis/02-grid-topology
- file: notebooks/03-uxarray-vis/03-polygons
- file: notebooks/03-uxarray-vis/04-points
- file: notebooks/03-uxarray-vis/07-animations
- file: notebooks/03-uxarray-vis/06-performance
- file: notebooks/04-recipes/mpas-atmo
- file: notebooks/04-recipes/mpas-ocean
# - file: notebooks/04-recipes/mpas-regional
- file: notebooks/04-recipes/e3sm
# - caption: Compatibility with Visualization Packages
# chapters:
# - file: notebooks/05-viz-packages/matplotlib
# - file: notebooks/05-viz-packages/datashader
# - file: notebooks/05-viz-packages/lonboard
Binary file added meshfiles/hex.data.nc
Binary file not shown.
Binary file added meshfiles/hex.grid.nc
Binary file not shown.
Binary file added meshfiles/hex.node.data.nc
Binary file not shown.
Binary file added meshfiles/ne30pg2.data.nc
Binary file not shown.
Binary file added meshfiles/ne30pg2.grid.nc
Binary file not shown.
Binary file added meshfiles/x1.655362.data.nc
Binary file not shown.
Binary file added meshfiles/x1.655362.grid.nc
Binary file not shown.
Loading
Loading