From 6ac71eebe8cc0dba3e9cc4652fd8dda731aa349e Mon Sep 17 00:00:00 2001 From: erogluorhan Date: Wed, 8 Nov 2023 20:36:17 -0700 Subject: [PATCH 1/4] Remove pyviz channel --- environment.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/environment.yml b/environment.yml index 84e464ba..5a59bcc4 100644 --- a/environment.yml +++ b/environment.yml @@ -1,7 +1,6 @@ name: unstructured-grid-viz-cookbook-dev channels: - conda-forge - - pyviz dependencies: - jupyter-book - jupyterlab From 954f0c8cc0f1464b3b46f353fcc59856f9c99bce Mon Sep 17 00:00:00 2001 From: erogluorhan Date: Wed, 8 Nov 2023 21:37:08 -0700 Subject: [PATCH 2/4] Refactor directory structure to combine some captions --- _toc.yml | 33 +++--- ...nb => 01-unstructured-grid-overview.ipynb} | 0 ...uctures.ipynb => 02-data-structures.ipynb} | 0 .../{plot-api.ipynb => 03-plot-api.ipynb} | 0 .../{template.ipynb => 01-data-mapping.ipynb} | 0 .../02-plotting-libraries.ipynb} | 8 +- .../03-rendering-techniques.ipynb} | 8 +- .../01-grid-topology.ipynb} | 44 ++++++-- .../02-data-variable.ipynb} | 14 +-- .../03-polygons.ipynb} | 17 +-- .../04-triangles.ipynb} | 17 +-- .../05-point-raster.ipynb} | 17 +-- .../template.ipynb | 0 notebooks/04-topology/template.ipynb | 105 ------------------ 14 files changed, 70 insertions(+), 193 deletions(-) rename notebooks/01-intro/{unstructured-grid-overview.ipynb => 01-unstructured-grid-overview.ipynb} (100%) rename notebooks/01-intro/{data-structures.ipynb => 02-data-structures.ipynb} (100%) rename notebooks/01-intro/{plot-api.ipynb => 03-plot-api.ipynb} (100%) rename notebooks/02-methods/{template.ipynb => 01-data-mapping.ipynb} (100%) rename notebooks/{05-data-vars/template.ipynb => 02-methods/02-plotting-libraries.ipynb} (99%) rename notebooks/{06-considerations/template.ipynb => 02-methods/03-rendering-techniques.ipynb} (99%) rename notebooks/{04-topology/nodes.ipynb => 03-uxarray-vis/01-grid-topology.ipynb} (63%) rename notebooks/{04-topology/edges.ipynb => 03-uxarray-vis/02-data-variable.ipynb} (87%) rename notebooks/{05-data-vars/polygons.ipynb => 03-uxarray-vis/03-polygons.ipynb} (88%) rename notebooks/{05-data-vars/triangles.ipynb => 03-uxarray-vis/04-triangles.ipynb} (88%) rename notebooks/{05-data-vars/point-raster.ipynb => 03-uxarray-vis/05-point-raster.ipynb} (86%) rename notebooks/{03-libraries => 04-considerations}/template.ipynb (100%) delete mode 100644 notebooks/04-topology/template.ipynb diff --git a/_toc.yml b/_toc.yml index 002a55ab..03204a20 100644 --- a/_toc.yml +++ b/_toc.yml @@ -6,29 +6,24 @@ parts: - file: notebooks/how-to-cite - caption: Introduction to UXarray & Unstructured Grids chapters: - - file: notebooks/01-intro/unstructured-grid-overview - - file: notebooks/01-intro/data-structures - - file: notebooks/01-intro/plot-api + - file: notebooks/01-intro/01-unstructured-grid-overview + - file: notebooks/01-intro/02-data-structures + - file: notebooks/01-intro/03-plot-api - - caption: Methods for Unstructured Grid Visualization + - caption: Methods & Libraries for Unstructured Grid Visualization chapters: - - file: notebooks/02-methods/template + - file: notebooks/02-methods/01-data-mapping + - file: notebooks/02-methods/02-plotting-libraries + - file: notebooks/02-methods/03-rendering-techniques - - caption: Visualization Libraries & Rendering Techniques + - caption: UXarray Visualization chapters: - - file: notebooks/03-libraries/template - - - caption: Grid Topology Visualization - chapters: - - file: notebooks/04-topology/nodes - - file: notebooks/04-topology/edges - - - caption: Data Variable Visualization - chapters: - - file: notebooks/05-data-vars/polygons - - file: notebooks/05-data-vars/triangles - - file: notebooks/05-data-vars/point-raster + - file: notebooks/03-uxarray-vis/01-grid-topology + - file: notebooks/03-uxarray-vis/02-data-variable + - file: notebooks/03-uxarray-vis/03-polygons + - file: notebooks/03-uxarray-vis/04-triangles + - file: notebooks/03-uxarray-vis/05-point-raster - caption: Performance & Data Fidelity Considerations chapters: - - file: notebooks/06-considerations/template + - file: notebooks/04-considerations/template diff --git a/notebooks/01-intro/unstructured-grid-overview.ipynb b/notebooks/01-intro/01-unstructured-grid-overview.ipynb similarity index 100% rename from notebooks/01-intro/unstructured-grid-overview.ipynb rename to notebooks/01-intro/01-unstructured-grid-overview.ipynb diff --git a/notebooks/01-intro/data-structures.ipynb b/notebooks/01-intro/02-data-structures.ipynb similarity index 100% rename from notebooks/01-intro/data-structures.ipynb rename to notebooks/01-intro/02-data-structures.ipynb diff --git a/notebooks/01-intro/plot-api.ipynb b/notebooks/01-intro/03-plot-api.ipynb similarity index 100% rename from notebooks/01-intro/plot-api.ipynb rename to notebooks/01-intro/03-plot-api.ipynb diff --git a/notebooks/02-methods/template.ipynb b/notebooks/02-methods/01-data-mapping.ipynb similarity index 100% rename from notebooks/02-methods/template.ipynb rename to notebooks/02-methods/01-data-mapping.ipynb diff --git a/notebooks/05-data-vars/template.ipynb b/notebooks/02-methods/02-plotting-libraries.ipynb similarity index 99% rename from notebooks/05-data-vars/template.ipynb rename to notebooks/02-methods/02-plotting-libraries.ipynb index deaf2e7c..07391c2d 100644 --- a/notebooks/05-data-vars/template.ipynb +++ b/notebooks/02-methods/02-plotting-libraries.ipynb @@ -17,13 +17,13 @@ { "cell_type": "code", "execution_count": null, + "metadata": { + "collapsed": false + }, "outputs": [], "source": [ "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + ] } ], "metadata": { diff --git a/notebooks/06-considerations/template.ipynb b/notebooks/02-methods/03-rendering-techniques.ipynb similarity index 99% rename from notebooks/06-considerations/template.ipynb rename to notebooks/02-methods/03-rendering-techniques.ipynb index deaf2e7c..07391c2d 100644 --- a/notebooks/06-considerations/template.ipynb +++ b/notebooks/02-methods/03-rendering-techniques.ipynb @@ -17,13 +17,13 @@ { "cell_type": "code", "execution_count": null, + "metadata": { + "collapsed": false + }, "outputs": [], "source": [ "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + ] } ], "metadata": { diff --git a/notebooks/04-topology/nodes.ipynb b/notebooks/03-uxarray-vis/01-grid-topology.ipynb similarity index 63% rename from notebooks/04-topology/nodes.ipynb rename to notebooks/03-uxarray-vis/01-grid-topology.ipynb index 2c18d1ac..c898dcd1 100644 --- a/notebooks/04-topology/nodes.ipynb +++ b/notebooks/03-uxarray-vis/01-grid-topology.ipynb @@ -4,26 +4,52 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Nodes" + "# Visualizing Grid Topology" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ - "---" + "It can always be useful to visualize the geometric elements of an unstructured grid (nodes, edges) without any data mapped to them for understanding the mesh topology and perform diagnostics (e.g. analyzing the mesh of a dynamical core prior to running a simulation).\n", + "\n", + "UXarray provides convenient functions to visualize these elements of the `Grid` object." + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Plot Nodes" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Placeholder for a brief paragraph" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "# Plot Edges" + ] + }, + { + "cell_type": "markdown", + "metadata": {}, + "source": [ + "Placeholder for a brief paragraph" ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], - "source": [ - "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + "source": [] } ], "metadata": { @@ -42,7 +68,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.10.11" + "version": "3.11.6" }, "nbdime-conflicts": { "local_diff": [ diff --git a/notebooks/04-topology/edges.ipynb b/notebooks/03-uxarray-vis/02-data-variable.ipynb similarity index 87% rename from notebooks/04-topology/edges.ipynb rename to notebooks/03-uxarray-vis/02-data-variable.ipynb index ef746bfb..c58b909f 100644 --- a/notebooks/04-topology/edges.ipynb +++ b/notebooks/03-uxarray-vis/02-data-variable.ipynb @@ -4,26 +4,22 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Edges" + "# Visualizing Data Variables" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ - "---" + "Placeholder for intriduction and overview of the visualization of data that is associated with an unstructured grid" ] }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], - "source": [ - "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + "source": [] } ], "metadata": { @@ -42,7 +38,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.10.11" + "version": "3.11.6" }, "nbdime-conflicts": { "local_diff": [ diff --git a/notebooks/05-data-vars/polygons.ipynb b/notebooks/03-uxarray-vis/03-polygons.ipynb similarity index 88% rename from notebooks/05-data-vars/polygons.ipynb rename to notebooks/03-uxarray-vis/03-polygons.ipynb index c0d2ab4c..2a947837 100644 --- a/notebooks/05-data-vars/polygons.ipynb +++ b/notebooks/03-uxarray-vis/03-polygons.ipynb @@ -7,23 +7,12 @@ "# Polygons" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "---" - ] - }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], - "source": [ - "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + "source": [] } ], "metadata": { @@ -42,7 +31,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.10.11" + "version": "3.11.6" }, "nbdime-conflicts": { "local_diff": [ diff --git a/notebooks/05-data-vars/triangles.ipynb b/notebooks/03-uxarray-vis/04-triangles.ipynb similarity index 88% rename from notebooks/05-data-vars/triangles.ipynb rename to notebooks/03-uxarray-vis/04-triangles.ipynb index 71622b8e..7112163c 100644 --- a/notebooks/05-data-vars/triangles.ipynb +++ b/notebooks/03-uxarray-vis/04-triangles.ipynb @@ -7,23 +7,12 @@ "# Triangles" ] }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "---" - ] - }, { "cell_type": "code", "execution_count": null, + "metadata": {}, "outputs": [], - "source": [ - "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + "source": [] } ], "metadata": { @@ -42,7 +31,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.10.11" + "version": "3.11.6" }, "nbdime-conflicts": { "local_diff": [ diff --git a/notebooks/05-data-vars/point-raster.ipynb b/notebooks/03-uxarray-vis/05-point-raster.ipynb similarity index 86% rename from notebooks/05-data-vars/point-raster.ipynb rename to notebooks/03-uxarray-vis/05-point-raster.ipynb index a9d31f69..57aa77c0 100644 --- a/notebooks/05-data-vars/point-raster.ipynb +++ b/notebooks/03-uxarray-vis/05-point-raster.ipynb @@ -10,20 +10,7 @@ { "cell_type": "markdown", "metadata": {}, - "source": [ - "---" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "outputs": [], - "source": [ - "# code and content goes here" - ], - "metadata": { - "collapsed": false - } + "source": [] } ], "metadata": { @@ -42,7 +29,7 @@ "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", - "version": "3.10.11" + "version": "3.11.6" }, "nbdime-conflicts": { "local_diff": [ diff --git a/notebooks/03-libraries/template.ipynb b/notebooks/04-considerations/template.ipynb similarity index 100% rename from notebooks/03-libraries/template.ipynb rename to notebooks/04-considerations/template.ipynb diff --git a/notebooks/04-topology/template.ipynb b/notebooks/04-topology/template.ipynb deleted file mode 100644 index deaf2e7c..00000000 --- a/notebooks/04-topology/template.ipynb +++ /dev/null @@ -1,105 +0,0 @@ -{ - "cells": [ - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "# Notebook Title" - ] - }, - { - "cell_type": "markdown", - "metadata": {}, - "source": [ - "---" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "outputs": [], - "source": [ - "# code and content goes here" - ], - "metadata": { - "collapsed": false - } - } - ], - "metadata": { - "kernelspec": { - "display_name": "Python 3 (ipykernel)", - "language": "python", - "name": "python3" - }, - "language_info": { - "codemirror_mode": { - "name": "ipython", - "version": 3 - }, - "file_extension": ".py", - "mimetype": "text/x-python", - "name": "python", - "nbconvert_exporter": "python", - "pygments_lexer": "ipython3", - "version": "3.10.11" - }, - "nbdime-conflicts": { - "local_diff": [ - { - "diff": [ - { - "diff": [ - { - "key": 0, - "op": "addrange", - "valuelist": [ - "Python 3" - ] - }, - { - "key": 0, - "length": 1, - "op": "removerange" - } - ], - "key": "display_name", - "op": "patch" - } - ], - "key": "kernelspec", - "op": "patch" - } - ], - "remote_diff": [ - { - "diff": [ - { - "diff": [ - { - "key": 0, - "op": "addrange", - "valuelist": [ - "Python3" - ] - }, - { - "key": 0, - "length": 1, - "op": "removerange" - } - ], - "key": "display_name", - "op": "patch" - } - ], - "key": "kernelspec", - "op": "patch" - } - ] - }, - "toc-autonumbering": false - }, - "nbformat": 4, - "nbformat_minor": 4 -} From b6ff0541cf57230ecd60bf2c09365a70661fbba0 Mon Sep 17 00:00:00 2001 From: erogluorhan Date: Wed, 8 Nov 2023 21:47:00 -0700 Subject: [PATCH 3/4] Fix broken link and add titles to a few NBs --- README.md | 2 +- notebooks/02-methods/01-data-mapping.ipynb | 2 +- notebooks/02-methods/02-plotting-libraries.ipynb | 2 +- notebooks/02-methods/03-rendering-techniques.ipynb | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index a3a45216..5e8be48b 100644 --- a/README.md +++ b/README.md @@ -10,7 +10,7 @@ This Cookbook showcases how to visualize Unstructured Grids using UXarray paired with community tool sets such as HoloViz and Matplotlib. It was put together as part of Project Raijin's NCAR Summer Internships in Parallel Computational Science (SIParCS) project, which is titled "Python Data Analysis and Visualization for Unstructured Grid Data." This cookbook is currently being adapted from -our 2023 intern Ian's notebook which can be found [here](https://github.com/NCAR/geocat-scratch/blob/ifranda/viz-notebook/SIParCS2023/Visualization_Notebook.ipynb). +our 2023 intern Ian's notebook which can be found [here](https://github.com/NCAR/geocat-scratch/blob/main/uxarray/SIParCS2023/Visualization_Notebook.ipynb). ## Authors diff --git a/notebooks/02-methods/01-data-mapping.ipynb b/notebooks/02-methods/01-data-mapping.ipynb index deaf2e7c..cd910768 100644 --- a/notebooks/02-methods/01-data-mapping.ipynb +++ b/notebooks/02-methods/01-data-mapping.ipynb @@ -4,7 +4,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Notebook Title" + "# Data mapping" ] }, { diff --git a/notebooks/02-methods/02-plotting-libraries.ipynb b/notebooks/02-methods/02-plotting-libraries.ipynb index 07391c2d..37e2471e 100644 --- a/notebooks/02-methods/02-plotting-libraries.ipynb +++ b/notebooks/02-methods/02-plotting-libraries.ipynb @@ -4,7 +4,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Notebook Title" + "# Plotting Libraries" ] }, { diff --git a/notebooks/02-methods/03-rendering-techniques.ipynb b/notebooks/02-methods/03-rendering-techniques.ipynb index 07391c2d..e88c5201 100644 --- a/notebooks/02-methods/03-rendering-techniques.ipynb +++ b/notebooks/02-methods/03-rendering-techniques.ipynb @@ -4,7 +4,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Notebook Title" + "# Rendering Techniques" ] }, { From 4bc8d783c393bfc64a0c174e45cffac3e0b7b8bf Mon Sep 17 00:00:00 2001 From: erogluorhan Date: Thu, 9 Nov 2023 13:00:35 -0700 Subject: [PATCH 4/4] Address Philip's reviews --- README.md | 10 +++------- notebooks/02-methods/01-data-mapping.ipynb | 2 +- notebooks/03-uxarray-vis/01-grid-topology.ipynb | 2 +- notebooks/03-uxarray-vis/02-data-variable.ipynb | 2 +- 4 files changed, 6 insertions(+), 10 deletions(-) diff --git a/README.md b/README.md index 5e8be48b..230aa37a 100644 --- a/README.md +++ b/README.md @@ -34,15 +34,11 @@ This cookbook is split up into six chapters which provide a comprehensive overvi #### 1. Introduction to UXarray & Unstructured Grids -#### 2. Methods for Unstructured Grid Visualization +#### 2. Methods & Libraries for Unstructured Grid Visualization -#### 3. Visualization Libraries & Rendering Techniques +#### 3. UXarray Visualization -#### 4. Grid Topology Visualization - -#### 5. Data Variable Visualization - -#### 6. Performance & Data Fidelity Considerations +#### 4. Performance & Data Fidelity Considerations ## Running the Notebooks diff --git a/notebooks/02-methods/01-data-mapping.ipynb b/notebooks/02-methods/01-data-mapping.ipynb index cd910768..66ae1b47 100644 --- a/notebooks/02-methods/01-data-mapping.ipynb +++ b/notebooks/02-methods/01-data-mapping.ipynb @@ -4,7 +4,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Data mapping" + "# Data Mapping" ] }, { diff --git a/notebooks/03-uxarray-vis/01-grid-topology.ipynb b/notebooks/03-uxarray-vis/01-grid-topology.ipynb index c898dcd1..a2f73adb 100644 --- a/notebooks/03-uxarray-vis/01-grid-topology.ipynb +++ b/notebooks/03-uxarray-vis/01-grid-topology.ipynb @@ -4,7 +4,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Visualizing Grid Topology" + "# Grid Topology" ] }, { diff --git a/notebooks/03-uxarray-vis/02-data-variable.ipynb b/notebooks/03-uxarray-vis/02-data-variable.ipynb index c58b909f..1d147107 100644 --- a/notebooks/03-uxarray-vis/02-data-variable.ipynb +++ b/notebooks/03-uxarray-vis/02-data-variable.ipynb @@ -4,7 +4,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "# Visualizing Data Variables" + "# Data Variables" ] }, {