Concepts | Importance | Notes |
---|---|---|
Python | Necessary | This notebook does not contain any Python code, but understanding those libraries comprehensively would require Python programming |
Time to learn: 10 minutes
In this section, we will introduce two visualization libraries/technologies and their features and functionality that can be useful for unstructured grids visualization before diving deep into plotting unstructured grids with UXarray in the next chapter.
HoloViz is a stack of tools (such as Holoviews, Datashader, Geoviews, SpatialPandas, hvPlot etc.) that provide high-level functionality to visualize even the very large datasets efficiently in Python. HoloViz packages are well-suited for unstructured grid visualization because:
Let us look at the particular HoloViz packages that can be useful for scalable visualization of unstructured grids.
Datashader is the graphics pipeline system of the HoloViz tool stack for creating meaningful representations of large datasets quickly and flexibly. Datashader's rasterization methods, transfer functions, and other shading operators can be utilized for rasterized polygon plotting.
GeoViews provides features and functionality to visualize geographical, meteorological, and oceanographic datasets and features.
Spatialpandas is a package that provides Pandas extension arrays for spatial/geometric operations. This package has an element called GeoDataFrame
, which can be used directly by packages from the HoloViz stack such as hvPlot, Datashader, Holoviews, and Geoviews. Conversions from unstructured grids to GeoDataFrame
can allow to perform visualizations directly in HoloViz packages.
Matplotlib is the workhorse of Python visualization needs, for both general and geoscientific purposes. However, when it comes to visualizing unstructured grids, Matplotlib's:
Matplotlib can still serve as a visualization backend for unstriuctured grid visualization, especially for the end-user who is familiar with Matplotlib and would like to create publication-quality outputs.
Moreover, just like conversion to Spatialpandas.GeoDataFrame
, conversions to Matplotlib data structures such as Collections
can be utilized for unstructrued grid plotting directly with the Matplotlib interface.
Cartopy is originally a Python library for cartographic visualizations with Matplotlib; however, they provide a number of features such as crs
, i.e. Coordinate Reference Systems (a.k.a. projections), that are significant for cartographic visualizations.
The next section will provide an overview of the rendering techniques that can be used for visualizing unstructrued grids.