geovista


Namegeovista JSON
Version 0.4.1 PyPI version JSON
download
home_page
SummaryCartographic rendering and mesh analytics powered by PyVista
upload_time2024-01-10 15:38:52
maintainer
docs_urlNone
author
requires_python>=3.9
licenseBSD 3-Clause License Copyright (c) 2021-2023, Bill Little All rights reserved. Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
keywords cartography curvilinear earth-science grid mesh python pyvista rectilinear ugrid unstructured vtk
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            <h1 align="center">
  <a href="https://github.com/bjlittle/geovista#--------">
    <img src="https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/branding/logo/primary/geovistalogo.svg"
         alt="GeoVista"
         width="200"></a>
</h1>

<h3 align="center">
  Cartographic rendering and mesh analytics powered by <a href="https://docs.pyvista.org/index.html">PyVista</a>
</h3>

<!---
fix docs pythreejs/panel
| ๐Ÿ“š Docs | [![documentation](https://readthedocs.org/projects/geovista/badge/?version=latest)](https://readthedocs.org/projects/geovista/)
-->

|              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |
|--------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| โš™๏ธ CI        | [![ci-citation](https://github.com/bjlittle/geovista/actions/workflows/ci-citation.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-citation.yml) [![ci-locks](https://github.com/bjlittle/geovista/actions/workflows/ci-locks.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-locks.yml) [![ci-manifest](https://github.com/bjlittle/geovista/actions/workflows/ci-manifest.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-manifest.yml) [![ci-tests](https://github.com/bjlittle/geovista/actions/workflows/ci-tests.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-tests.yml) [![ci-wheels](https://github.com/bjlittle/geovista/actions/workflows/ci-wheels.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-wheels.yml) [![pre-commit](https://results.pre-commit.ci/badge/github/bjlittle/geovista/main.svg)](https://results.pre-commit.ci/latest/github/bjlittle/geovista/main) |
| ๐Ÿ’ฌ Community | [![Contributor Covenant](https://img.shields.io/badge/contributor%20covenant-2.1-4baaaa.svg)](https://github.com/bjlittle/geovista/blob/main/CODE_OF_CONDUCT.md) [![GH Discussions](https://img.shields.io/badge/github-discussions%20%F0%9F%92%AC-yellow?logo=github&logoColor=lightgrey)](https://github.com/bjlittle/geovista/discussions)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |
| ๐Ÿ“ˆ Health    | [![codecov](https://codecov.io/gh/bjlittle/geovista/branch/main/graph/badge.svg?token=RVVXGP1SD3)](https://codecov.io/gh/bjlittle/geovista)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |
| โœจ Meta       | [![geovista](https://img.shields.io/badge/%F0%9F%8C%8D-GeoVista-4051b5)](https://github.com/bjlittle/geovista) [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v1.json)](https://github.com/charliermarsh/ruff) [![code style - black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black) [![NEP29](https://raster.shields.io/badge/follows-NEP29-orange.png)](https://numpy.org/neps/nep-0029-deprecation_policy.html) [![license - bds-3-clause](https://img.shields.io/github/license/bjlittle/geovista)](https://github.com/bjlittle/geovista/blob/main/LICENSE) [![conda platform](https://img.shields.io/conda/pn/conda-forge/geovista.svg)](https://anaconda.org/conda-forge/geovista)                                                                                                                                                                                                                 |
| ๐Ÿ“ฆ Package   | [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.7608302.svg)](https://doi.org/10.5281/zenodo.7608302) [![conda-forge](https://img.shields.io/conda/vn/conda-forge/geovista?color=orange&label=conda-forge&logo=conda-forge&logoColor=white)](https://anaconda.org/conda-forge/geovista) [![pypi](https://img.shields.io/pypi/v/geovista?color=orange&label=pypi&logo=python&logoColor=white)](https://pypi.org/project/geovista/) [![pypi - python version](https://img.shields.io/pypi/pyversions/geovista.svg?color=orange&logo=python&label=python&logoColor=white)](https://pypi.org/project/geovista/)                                                                                                                                                                                                                                                                                                                                                                                                           |
| ๐Ÿงฐ Repo      | [![commits-since](https://img.shields.io/github/commits-since/bjlittle/geovista/latest.svg)](https://github.com/bjlittle/geovista/commits/main) [![contributors](https://img.shields.io/github/contributors/bjlittle/geovista)](https://github.com/bjlittle/geovista/graphs/contributors) [![release](https://img.shields.io/github/v/release/bjlittle/geovista)](https://github.com/bjlittle/geovista/releases)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| ๐Ÿ›ก๏ธ Status   | [![scitools](https://img.shields.io/badge/scitools-ownership%20pending-yellow)](https://github.com/bjlittle/geovista/issues/167)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
|              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |


## Motivation

The goal of GeoVista is simple; to complement [PyVista](https://docs.pyvista.org/index.html) with a convenient
cartographic capability.

In this regard, from a design perspective we aim to keep GeoVista as **pure** to PyVista as possible i.e.,
**minimise specialisation** as far as practically possible in order to **maximise native compatibility** within the
PyVista and [VTK](https://vtk.org/) ecosystems.

We intend GeoVista to be a cartographic gateway into the powerful world of PyVista, and all that it offers.

GeoVista is intentionally agnostic to packages such as [geopandas](https://geopandas.org/en/stable/),
[iris](https://scitools-iris.readthedocs.io/en/latest/?badge=latest), [xarray](https://docs.xarray.dev/en/stable/)
et al, which specialise in preparing your spatial data for visualisation. Rather, we delegate that responsibility and
choice of tool to you the user, as we want GeoVista to remain as flexible and open-ended as possible to the entire
Scientific Python community.

Simply put, "*GeoVista is to PyVista*", as "*Cartopy is to Matplotlib*". Well, that's the aspiration.

## Installation

GeoVista is available on both [conda-forge](https://anaconda.org/conda-forge/geovista) and [PyPI](https://pypi.org/project/geovista/).

We recommend using [mamba](https://github.com/mamba-org/mamba) to install GeoVista ๐Ÿ‘

### Mamba

GeoVista is available on [conda-forge](https://anaconda.org/conda-forge/geovista), and can be easily installed with
[mamba](https://github.com/mamba-org/mamba):
```shell
mamba install -c conda-forge geovista
```
or alternatively with [conda](https://docs.conda.io/projects/conda/en/latest/index.html):
```shell
conda install -c conda-forge geovista
```
For more information see our [conda-forge feedstock](https://github.com/conda-forge/geovista-feedstock) and
[prefix.dev dashboard](https://prefix.dev/channels/conda-forge/packages/geovista).

### Pip

GeoVista is also available on [PyPI](https://pypi.org/project/geovista/):

```shell
pip install geovista
```

Checkout out our [PyPI Download Stats](https://pypistats.org/packages/geovista), if you like that kinda thing.

### Developer

If you simply can't wait for the next release to play with the latest hot features, then you can easily
install the `main` development branch from GitHub:
```shell
pip install git+https://github.com/bjlittle/geovista@main
```

Alternatively, to configure a full developer environment, first clone the GeoVista GitHub repository:
```shell
git clone git@github.com:bjlittle/geovista.git
```
Change to the root directory:
```shell
cd geovista
```
Create the `geovista-dev` conda development environment:
```shell
mamba env create --file requirements/geovista.yml
```
Now activate the environment and install the `main` development branch of GeoVista:
```shell
conda activate geovista-dev
pip install --no-deps --editable .
```
Finally, you're good to roll ๐Ÿฅณ

And for extra credit, install our developer `pre-commit` git-hooks:
```shell
pre-commit install
```

## Quick Start

GeoVista comes with various pre-canned resources to help get you started on your visualisation journey.

### Resources

GeoVista makes use of various resources, such as rasters, VTK meshes,
[Natural Earth](https://www.naturalearthdata.com/features/) features, and sample model data.

If you want to download and cache all registered GeoVista resources to make them available offline, simply:
```shell
geovista download --all
```
Alternatively, just leave GeoVista to download resources on-the-fly, as and when she needs them.

To view the list of registered resources, simply:
```shell
geovista download --list
```

Want to know more?
```shell
geovista download --help
```

### Plotting Examples

Let's explore a sample of various oceanographic and atmospheric model data using GeoVista.

#### WAVEWATCH III

First, let's render a [WAVEWATCH III](https://github.com/NOAA-EMC/WW3) (WW3) **unstructured** triangular mesh, with
[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/), a
[1:50m Natural Earth Cross-Blended Hypsometric Tints](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-cross-blend-hypso/)
base layer, and the gorgeous perceptually uniform [cmocean balance](https://matplotlib.org/cmocean/#balance) diverging
colormap.

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import ww3_global_tri
import geovista.theme

# Load the sample data.
sample = ww3_global_tri()

# Create the mesh from the sample data.
mesh = gv.Transform.from_unstructured(
    sample.lons, sample.lats, connectivity=sample.connectivity, data=sample.data
)

# Plot the mesh.
plotter = gv.GeoPlotter()
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(
    mesh, show_edges=True, scalar_bar_args=sargs
)
plotter.add_base_layer(texture=gv.natural_earth_hypsometric())
plotter.add_coastlines(resolution="10m")
plotter.add_graticule()
plotter.view_xy(negative=True)
plotter.add_axes()
plotter.show()
```
</details>

![ww3-tri](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/ww3-tri.png)

#### Finite Volume Community Ocean Model

Now, let's visualise the bathymetry of the
[Plymouth Sound and Tamar River](https://www.google.com/maps/place/Plymouth+Sound/@50.3337382,-4.2215988,12z/data=!4m5!3m4!1s0x486c93516bbce307:0xded7654eaf4f8f83!8m2!3d50.3638359!4d-4.1441365)
from an [FVCOM](http://fvcom.smast.umassd.edu/fvcom/) **unstructured** mesh, as kindly provided by the
[Plymouth Marine Laboratory](https://pml.ac.uk/) using the lush [cmocean deep](https://matplotlib.org/cmocean/#deep) colormap.

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import fvcom_tamar
import geovista.theme

# Load the sample data.
sample = fvcom_tamar()

# Create the mesh from the sample data.
mesh = gv.Transform.from_unstructured(
    sample.lons,
    sample.lats,
    connectivity=sample.connectivity,
    data=sample.face,
    name="face",
)

# Warp the mesh nodes by the bathymetry.
mesh.point_data["node"] = sample.node
mesh.compute_normals(cell_normals=False, point_normals=True, inplace=True)
mesh.warp_by_scalar(scalars="node", inplace=True, factor=2e-5)

# Plot the mesh.
plotter = gv.GeoPlotter()
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(mesh, cmap="deep", scalar_bar_args=sargs)
plotter.add_axes()
plotter.show()
```
</details>

![tamar](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/tamar.png)

#### CF UGRID

##### Local Area Model

Initial projection support is available within GeoVista for **Cylindrical** and **Pseudo-Cylindrical** projections. As
GeoVista matures and stabilises, we'll aim to complement this capability with other classes of projections, such as
**Azimuthal** and **Conic**.

In the meantime, let's showcase our basic projection support with some high-resolution **unstructured** Local Area Model
(LAM) data reprojected to [Mollweide](https://proj.org/operations/projections/moll.html) using a
[PROJ](https://proj.org/index.html) string, with
[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a
[1:50m Natural Earth Cross-Blended Hypsometric Tints](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-cross-blend-hypso/)
base layer.

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import lam_pacific
import geovista.theme

# Load the sample data.
sample = lam_pacific()

# Create the mesh from the sample data.
mesh = gv.Transform.from_unstructured(
    sample.lons,
    sample.lats,
    connectivity=sample.connectivity,
    data=sample.data,
)

# Plot the mesh on a mollweide projection using a Proj string.
plotter = gv.GeoPlotter(crs="+proj=moll")
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(mesh, scalar_bar_args=sargs)
plotter.add_coastlines()
plotter.add_base_layer(texture=gv.natural_earth_hypsometric())
plotter.add_graticule()
plotter.add_axes()
plotter.view_xy()
plotter.show()
```
</details>

![lam-mollweide](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/lam-moll.png)

Using the same **unstructured** LAM data, reproject to
[Equidistant Cylindrical](https://proj.org/operations/projections/eqc.html) but this time using a
[Cartopy Plate Carrรฉe CRS](https://scitools.org.uk/cartopy/docs/latest/reference/projections.html#cartopy.crs.PlateCarree),
also with [10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/)
and a
[1:50m Natural Earth Cross-Blended Hypsometric Tints](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-cross-blend-hypso/)
base layer.

<details>
<summary>๐Ÿ—’ </summary>

```python
import cartopy.crs as ccrs

import geovista as gv
from geovista.pantry import lam_pacific
import geovista.theme

# Load the sample data.
sample = lam_pacific()

# Create the mesh from the sample data.
mesh = gv.Transform.from_unstructured(
    sample.lons,
    sample.lats,
    connectivity=sample.connectivity,
    data=sample.data,
)

# Plot the mesh on a Plate Carrรฉe projection using a cartopy CRS.
plotter = gv.GeoPlotter(crs=ccrs.PlateCarree(central_longitude=180))
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(mesh, scalar_bar_args=sargs)
plotter.add_coastlines()
plotter.add_base_layer(texture=gv.natural_earth_hypsometric())
plotter.add_graticule()
plotter.add_axes()
plotter.view_xy()
plotter.show()
```
</details>

![lam-mollweide](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/lam-eqc.png)

#### LFRic Cube-Sphere

Now render a [Met Office LFRic](https://www.metoffice.gov.uk/research/approach/modelling-systems/lfric) C48 cube-sphere
**unstructured** mesh of Sea Surface Temperature data on a
[Robinson](https://proj.org/operations/projections/robin.html) projection using an ESRI SRID, with
[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a
[cmocean thermal](https://matplotlib.org/cmocean/#thermal) colormap.

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import lfric_sst
import geovista.theme

# Load the sample data.
sample = lfric_sst()

# Create the mesh from the sample data.
mesh = gv.Transform.from_unstructured(
    sample.lons,
    sample.lats,
    connectivity=sample.connectivity,
    data=sample.data,
)

# Plot the mesh on a Robinson projection using an ESRI spatial reference identifier.
plotter = gv.GeoPlotter(crs="ESRI:54030")
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(mesh, cmap="thermal", show_edges=True, scalar_bar_args=sargs)
plotter.add_coastlines()
plotter.view_xy()
plotter.add_axes()
plotter.show()
```
</details>

![lam-mollweide](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/lfric-robin.png)

#### UM ORCA2

So far we've demonstrated GeoVista's ability to cope with **unstructured** data. Now let's plot a **curvilinear** mesh
using Met Office Unified Model (UM) ORCA2 Sea Water Potential Temperature data, with
[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a
[1:50m Natural Earth I](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-natural-earth-1/) base layer.

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import um_orca2
import geovista.theme

# Load sample data.
sample = um_orca2()

# Create the mesh from the sample data.
mesh = gv.Transform.from_2d(sample.lons, sample.lats, data=sample.data)

# Remove cells from the mesh with NaN values.
mesh = mesh.threshold()

# Plot the mesh.
plotter = gv.GeoPlotter()
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(
    mesh, show_edges=True, scalar_bar_args=sargs
)
plotter.add_base_layer(texture=gv.natural_earth_1())
plotter.add_coastlines(resolution="10m")
plotter.view_xy()
plotter.add_axes()
plotter.show()
```
</details>

![um-orca](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/um-orca.png)

#### OISST AVHRR

Now let's render a [NOAA/NCEI Optimum Interpolation SST](https://www.ncei.noaa.gov/products/optimum-interpolation-sst)
(OISST) Advanced Very High Resolution Radiometer (AVHRR) **rectilinear** mesh, with
[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a
[NASA Blue Marble](https://visibleearth.nasa.gov/collection/1484/blue-marble) base layer.

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import oisst_avhrr_sst
import geovista.theme

# Load sample data.
sample = oisst_avhrr_sst()

# Create the mesh from the sample data.
mesh = gv.Transform.from_1d(sample.lons, sample.lats, data=sample.data)

# Remove cells from the mesh with NaN values.
mesh = mesh.threshold()

# Plot the mesh.
plotter = gv.GeoPlotter()
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(mesh, scalar_bar_args=sargs)
plotter.add_base_layer(texture=gv.blue_marble())
plotter.add_coastlines()
plotter.view_xz()
plotter.add_axes()
plotter.show()
```
</details>

![oisst-avhrr](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/oisst-avhrr.png)

#### DYNAMICO Icosahedral

Finally, to demonstrate support for non-traditional cell geometries i.e., not triangles or quadrilaterals, we plot
the **unstructured** icosahedral mesh from the [DYNAMICO](https://gitlab.in2p3.fr/ipsl/projets/dynamico/dynamico)
project. This model uses hexagonal cells and is a new dynamical core for
[LMD-Z](https://www.lmd.ipsl.fr/en/modelisations/lmdz-en/), the atmospheric General Circulation Model (GCM) part of the
[IPSL-CM](https://cmc.ipsl.fr/ipsl-climate-models/) Earth System Model. The render also contains
[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/).

<details>
<summary>๐Ÿ—’ </summary>

```python
import geovista as gv
from geovista.pantry import icosahedral
import geovista.theme

# Load sample data.
sample = icosahedral()

# Create the mesh from the sample data.
mesh = gv.Transform.from_unstructured(sample.lons, sample.lats, data=sample.data)

# Plot the mesh.
plotter = gv.GeoPlotter()
sargs = {"title": f"{sample.name} / {sample.units}"}
plotter.add_mesh(mesh, scalar_bar_args=sargs)
plotter.add_coastlines()
plotter.add_axes()
plotter.show()
```
</details>

![dynamico-icosahedral](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/dynamico-icosahedral.png)

## Unreal Reels

GeoVista is built on the shoulders of giants, namely [PyVista](https://docs.pyvista.org/version/stable/) and
[VTK](https://vtk.org/documentation/), thus allowing it to easily leverage the power of the GPU.

As a result, it offers a paradigm shift in rendering performance and interactive user experience, as demonstrated by
this realtime, time-series animation of WAVEWATCH IIIยฎ third-generation wave model (**WAVE**-height, **WAT**er depth
and **C**urrent **H**indcasting), developed at [NOAA](https://www.noaa.gov/)/[NCEP](https://www.weather.gov/ncep/),
quasi-unstructured Spherical Multi-Cell (SMC) grid data of Sea Surface Wave Significant Height located on cell faces.

[๐ŸŽฅ WW3 SMC time-series](https://github.com/bjlittle/geovista/assets/2051656/876d877e-a6fa-42ff-8153-08c41ff8a19e)

## Further Examples

<p align="center">
"<em>Please, sir, I want some more</em>", Charles Dickens, Oliver Twist, 1838.
</p>

Certainly, our pleasure! From the command line, simply:

```bash
geovista examples --run all --verbose
```

Want to know more?
```shell
geovista examples --help
```

<!---
## Documentation

The [documentation](https://geovista.readthedocs.io/en/latest/) is built by [Sphinx](https://www.sphinx-doc.org/en/master/) and hosted on [Read the Docs](https://docs.readthedocs.io/en/stable/).
-->

## Ecosystem

Whilst you're here, why not hop on over to the [pyvista-xarray](https://github.com/pyvista/pyvista-xarray) project and
check it out!

It's aiming to provide `xarray DataArray accessors for PyVista to visualize datasets in 3D` for the
[xarray](https://github.com/pydata/xarray) community, and will be building on top of GeoVista ๐ŸŽ‰

## Support

Need help? ๐Ÿ˜ข

Why not check out our [existing GitHub issues](https://github.com/bjlittle/geovista/issues). See something similar?
Well, give it a ๐Ÿ‘ to raise its priority and feel free to chip in on the conversation. Otherwise, don't hesitate to
create a [new GitHub issue](https://github.com/bjlittle/geovista/issues/new/choose) instead.

However, if you'd rather have a natter, then head on over to our
[GitHub Discussions](https://github.com/bjlittle/geovista/discussions). That's definitely the place to wax lyrical all
things GeoVista!


## License

GeoVista is distributed under the terms of the [BSD-3-Clause](https://spdx.org/licenses/BSD-3-Clause.html) license.

## [#ShowYourStripes](https://showyourstripes.info/s/globe)

<h4 align="center">
  <a href="https://showyourstripes.info/s/globe">
    <img src="https://raw.githubusercontent.com/ed-hawkins/show-your-stripes/master/2022/GLOBE---1850-2022-MO.png"
         height="50" width="800"
         alt="#showyourstripes Global 1850-2022"></a>
</h4>

**Graphics and Lead Scientist**: [Ed Hawkins](http://www.met.reading.ac.uk/~ed/home/index.php), National Centre for Atmospheric Science, University of Reading.

**Data**: Berkeley Earth, NOAA, UK Met Office, MeteoSwiss, DWD, SMHI, UoR, Meteo France & ZAMG.

<p>
<a href="https://showyourstripes.info/s/globe">#ShowYourStripes</a> is distributed under a
<a href="https://creativecommons.org/licenses/by/4.0/">Creative Commons Attribution 4.0 International License</a>
<a href="https://creativecommons.org/licenses/by/4.0/">
  <img src="https://i.creativecommons.org/l/by/4.0/80x15.png" alt="creative-commons-by" style="border-width:0"></a>
</p>

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "geovista",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": "",
    "keywords": "cartography,curvilinear,earth-science,grid,mesh,python,pyvista,rectilinear,ugrid,unstructured,vtk",
    "author": "",
    "author_email": "GeoVista Contributors <geovista.pub@gmail.com>",
    "download_url": "https://files.pythonhosted.org/packages/53/14/b140d5cfac861b88b0213f229f12c1e8af047f5351d4fd6a92521aee325c/geovista-0.4.1.tar.gz",
    "platform": null,
    "description": "<h1 align=\"center\">\n  <a href=\"https://github.com/bjlittle/geovista#--------\">\n    <img src=\"https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/branding/logo/primary/geovistalogo.svg\"\n         alt=\"GeoVista\"\n         width=\"200\"></a>\n</h1>\n\n<h3 align=\"center\">\n  Cartographic rendering and mesh analytics powered by <a href=\"https://docs.pyvista.org/index.html\">PyVista</a>\n</h3>\n\n<!---\nfix docs pythreejs/panel\n| \ud83d\udcda Docs | [![documentation](https://readthedocs.org/projects/geovista/badge/?version=latest)](https://readthedocs.org/projects/geovista/)\n-->\n\n|              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |\n|--------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| \u2699\ufe0f CI        | [![ci-citation](https://github.com/bjlittle/geovista/actions/workflows/ci-citation.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-citation.yml) [![ci-locks](https://github.com/bjlittle/geovista/actions/workflows/ci-locks.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-locks.yml) [![ci-manifest](https://github.com/bjlittle/geovista/actions/workflows/ci-manifest.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-manifest.yml) [![ci-tests](https://github.com/bjlittle/geovista/actions/workflows/ci-tests.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-tests.yml) [![ci-wheels](https://github.com/bjlittle/geovista/actions/workflows/ci-wheels.yml/badge.svg)](https://github.com/bjlittle/geovista/actions/workflows/ci-wheels.yml) [![pre-commit](https://results.pre-commit.ci/badge/github/bjlittle/geovista/main.svg)](https://results.pre-commit.ci/latest/github/bjlittle/geovista/main) |\n| \ud83d\udcac Community | [![Contributor Covenant](https://img.shields.io/badge/contributor%20covenant-2.1-4baaaa.svg)](https://github.com/bjlittle/geovista/blob/main/CODE_OF_CONDUCT.md) [![GH Discussions](https://img.shields.io/badge/github-discussions%20%F0%9F%92%AC-yellow?logo=github&logoColor=lightgrey)](https://github.com/bjlittle/geovista/discussions)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                             |\n| \ud83d\udcc8 Health    | [![codecov](https://codecov.io/gh/bjlittle/geovista/branch/main/graph/badge.svg?token=RVVXGP1SD3)](https://codecov.io/gh/bjlittle/geovista)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               |\n| \u2728 Meta       | [![geovista](https://img.shields.io/badge/%F0%9F%8C%8D-GeoVista-4051b5)](https://github.com/bjlittle/geovista) [![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/charliermarsh/ruff/main/assets/badge/v1.json)](https://github.com/charliermarsh/ruff) [![code style - black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black) [![NEP29](https://raster.shields.io/badge/follows-NEP29-orange.png)](https://numpy.org/neps/nep-0029-deprecation_policy.html) [![license - bds-3-clause](https://img.shields.io/github/license/bjlittle/geovista)](https://github.com/bjlittle/geovista/blob/main/LICENSE) [![conda platform](https://img.shields.io/conda/pn/conda-forge/geovista.svg)](https://anaconda.org/conda-forge/geovista)                                                                                                                                                                                                                 |\n| \ud83d\udce6 Package   | [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.7608302.svg)](https://doi.org/10.5281/zenodo.7608302) [![conda-forge](https://img.shields.io/conda/vn/conda-forge/geovista?color=orange&label=conda-forge&logo=conda-forge&logoColor=white)](https://anaconda.org/conda-forge/geovista) [![pypi](https://img.shields.io/pypi/v/geovista?color=orange&label=pypi&logo=python&logoColor=white)](https://pypi.org/project/geovista/) [![pypi - python version](https://img.shields.io/pypi/pyversions/geovista.svg?color=orange&logo=python&label=python&logoColor=white)](https://pypi.org/project/geovista/)                                                                                                                                                                                                                                                                                                                                                                                                           |\n| \ud83e\uddf0 Repo      | [![commits-since](https://img.shields.io/github/commits-since/bjlittle/geovista/latest.svg)](https://github.com/bjlittle/geovista/commits/main) [![contributors](https://img.shields.io/github/contributors/bjlittle/geovista)](https://github.com/bjlittle/geovista/graphs/contributors) [![release](https://img.shields.io/github/v/release/bjlittle/geovista)](https://github.com/bjlittle/geovista/releases)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |\n| \ud83d\udee1\ufe0f Status   | [![scitools](https://img.shields.io/badge/scitools-ownership%20pending-yellow)](https://github.com/bjlittle/geovista/issues/167)                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |\n|              |                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           |\n\n\n## Motivation\n\nThe goal of GeoVista is simple; to complement [PyVista](https://docs.pyvista.org/index.html) with a convenient\ncartographic capability.\n\nIn this regard, from a design perspective we aim to keep GeoVista as **pure** to PyVista as possible i.e.,\n**minimise specialisation** as far as practically possible in order to **maximise native compatibility** within the\nPyVista and [VTK](https://vtk.org/) ecosystems.\n\nWe intend GeoVista to be a cartographic gateway into the powerful world of PyVista, and all that it offers.\n\nGeoVista is intentionally agnostic to packages such as [geopandas](https://geopandas.org/en/stable/),\n[iris](https://scitools-iris.readthedocs.io/en/latest/?badge=latest), [xarray](https://docs.xarray.dev/en/stable/)\net al, which specialise in preparing your spatial data for visualisation. Rather, we delegate that responsibility and\nchoice of tool to you the user, as we want GeoVista to remain as flexible and open-ended as possible to the entire\nScientific Python community.\n\nSimply put, \"*GeoVista is to PyVista*\", as \"*Cartopy is to Matplotlib*\". Well, that's the aspiration.\n\n## Installation\n\nGeoVista is available on both [conda-forge](https://anaconda.org/conda-forge/geovista) and [PyPI](https://pypi.org/project/geovista/).\n\nWe recommend using [mamba](https://github.com/mamba-org/mamba) to install GeoVista \ud83d\udc4d\n\n### Mamba\n\nGeoVista is available on [conda-forge](https://anaconda.org/conda-forge/geovista), and can be easily installed with\n[mamba](https://github.com/mamba-org/mamba):\n```shell\nmamba install -c conda-forge geovista\n```\nor alternatively with [conda](https://docs.conda.io/projects/conda/en/latest/index.html):\n```shell\nconda install -c conda-forge geovista\n```\nFor more information see our [conda-forge feedstock](https://github.com/conda-forge/geovista-feedstock) and\n[prefix.dev dashboard](https://prefix.dev/channels/conda-forge/packages/geovista).\n\n### Pip\n\nGeoVista is also available on [PyPI](https://pypi.org/project/geovista/):\n\n```shell\npip install geovista\n```\n\nCheckout out our [PyPI Download Stats](https://pypistats.org/packages/geovista), if you like that kinda thing.\n\n### Developer\n\nIf you simply can't wait for the next release to play with the latest hot features, then you can easily\ninstall the `main` development branch from GitHub:\n```shell\npip install git+https://github.com/bjlittle/geovista@main\n```\n\nAlternatively, to configure a full developer environment, first clone the GeoVista GitHub repository:\n```shell\ngit clone git@github.com:bjlittle/geovista.git\n```\nChange to the root directory:\n```shell\ncd geovista\n```\nCreate the `geovista-dev` conda development environment:\n```shell\nmamba env create --file requirements/geovista.yml\n```\nNow activate the environment and install the `main` development branch of GeoVista:\n```shell\nconda activate geovista-dev\npip install --no-deps --editable .\n```\nFinally, you're good to roll \ud83e\udd73\n\nAnd for extra credit, install our developer `pre-commit` git-hooks:\n```shell\npre-commit install\n```\n\n## Quick Start\n\nGeoVista comes with various pre-canned resources to help get you started on your visualisation journey.\n\n### Resources\n\nGeoVista makes use of various resources, such as rasters, VTK meshes,\n[Natural Earth](https://www.naturalearthdata.com/features/) features, and sample model data.\n\nIf you want to download and cache all registered GeoVista resources to make them available offline, simply:\n```shell\ngeovista download --all\n```\nAlternatively, just leave GeoVista to download resources on-the-fly, as and when she needs them.\n\nTo view the list of registered resources, simply:\n```shell\ngeovista download --list\n```\n\nWant to know more?\n```shell\ngeovista download --help\n```\n\n### Plotting Examples\n\nLet's explore a sample of various oceanographic and atmospheric model data using GeoVista.\n\n#### WAVEWATCH III\n\nFirst, let's render a [WAVEWATCH III](https://github.com/NOAA-EMC/WW3) (WW3) **unstructured** triangular mesh, with\n[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/), a\n[1:50m Natural Earth Cross-Blended Hypsometric Tints](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-cross-blend-hypso/)\nbase layer, and the gorgeous perceptually uniform [cmocean balance](https://matplotlib.org/cmocean/#balance) diverging\ncolormap.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import ww3_global_tri\nimport geovista.theme\n\n# Load the sample data.\nsample = ww3_global_tri()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_unstructured(\n    sample.lons, sample.lats, connectivity=sample.connectivity, data=sample.data\n)\n\n# Plot the mesh.\nplotter = gv.GeoPlotter()\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(\n    mesh, show_edges=True, scalar_bar_args=sargs\n)\nplotter.add_base_layer(texture=gv.natural_earth_hypsometric())\nplotter.add_coastlines(resolution=\"10m\")\nplotter.add_graticule()\nplotter.view_xy(negative=True)\nplotter.add_axes()\nplotter.show()\n```\n</details>\n\n![ww3-tri](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/ww3-tri.png)\n\n#### Finite Volume Community Ocean Model\n\nNow, let's visualise the bathymetry of the\n[Plymouth Sound and Tamar River](https://www.google.com/maps/place/Plymouth+Sound/@50.3337382,-4.2215988,12z/data=!4m5!3m4!1s0x486c93516bbce307:0xded7654eaf4f8f83!8m2!3d50.3638359!4d-4.1441365)\nfrom an [FVCOM](http://fvcom.smast.umassd.edu/fvcom/) **unstructured** mesh, as kindly provided by the\n[Plymouth Marine Laboratory](https://pml.ac.uk/) using the lush [cmocean deep](https://matplotlib.org/cmocean/#deep) colormap.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import fvcom_tamar\nimport geovista.theme\n\n# Load the sample data.\nsample = fvcom_tamar()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_unstructured(\n    sample.lons,\n    sample.lats,\n    connectivity=sample.connectivity,\n    data=sample.face,\n    name=\"face\",\n)\n\n# Warp the mesh nodes by the bathymetry.\nmesh.point_data[\"node\"] = sample.node\nmesh.compute_normals(cell_normals=False, point_normals=True, inplace=True)\nmesh.warp_by_scalar(scalars=\"node\", inplace=True, factor=2e-5)\n\n# Plot the mesh.\nplotter = gv.GeoPlotter()\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(mesh, cmap=\"deep\", scalar_bar_args=sargs)\nplotter.add_axes()\nplotter.show()\n```\n</details>\n\n![tamar](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/tamar.png)\n\n#### CF UGRID\n\n##### Local Area Model\n\nInitial projection support is available within GeoVista for **Cylindrical** and **Pseudo-Cylindrical** projections. As\nGeoVista matures and stabilises, we'll aim to complement this capability with other classes of projections, such as\n**Azimuthal** and **Conic**.\n\nIn the meantime, let's showcase our basic projection support with some high-resolution **unstructured** Local Area Model\n(LAM) data reprojected to [Mollweide](https://proj.org/operations/projections/moll.html) using a\n[PROJ](https://proj.org/index.html) string, with\n[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a\n[1:50m Natural Earth Cross-Blended Hypsometric Tints](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-cross-blend-hypso/)\nbase layer.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import lam_pacific\nimport geovista.theme\n\n# Load the sample data.\nsample = lam_pacific()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_unstructured(\n    sample.lons,\n    sample.lats,\n    connectivity=sample.connectivity,\n    data=sample.data,\n)\n\n# Plot the mesh on a mollweide projection using a Proj string.\nplotter = gv.GeoPlotter(crs=\"+proj=moll\")\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(mesh, scalar_bar_args=sargs)\nplotter.add_coastlines()\nplotter.add_base_layer(texture=gv.natural_earth_hypsometric())\nplotter.add_graticule()\nplotter.add_axes()\nplotter.view_xy()\nplotter.show()\n```\n</details>\n\n![lam-mollweide](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/lam-moll.png)\n\nUsing the same **unstructured** LAM data, reproject to\n[Equidistant Cylindrical](https://proj.org/operations/projections/eqc.html) but this time using a\n[Cartopy Plate Carr\u00e9e CRS](https://scitools.org.uk/cartopy/docs/latest/reference/projections.html#cartopy.crs.PlateCarree),\nalso with [10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/)\nand a\n[1:50m Natural Earth Cross-Blended Hypsometric Tints](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-cross-blend-hypso/)\nbase layer.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport cartopy.crs as ccrs\n\nimport geovista as gv\nfrom geovista.pantry import lam_pacific\nimport geovista.theme\n\n# Load the sample data.\nsample = lam_pacific()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_unstructured(\n    sample.lons,\n    sample.lats,\n    connectivity=sample.connectivity,\n    data=sample.data,\n)\n\n# Plot the mesh on a Plate Carr\u00e9e projection using a cartopy CRS.\nplotter = gv.GeoPlotter(crs=ccrs.PlateCarree(central_longitude=180))\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(mesh, scalar_bar_args=sargs)\nplotter.add_coastlines()\nplotter.add_base_layer(texture=gv.natural_earth_hypsometric())\nplotter.add_graticule()\nplotter.add_axes()\nplotter.view_xy()\nplotter.show()\n```\n</details>\n\n![lam-mollweide](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/lam-eqc.png)\n\n#### LFRic Cube-Sphere\n\nNow render a [Met Office LFRic](https://www.metoffice.gov.uk/research/approach/modelling-systems/lfric) C48 cube-sphere\n**unstructured** mesh of Sea Surface Temperature data on a\n[Robinson](https://proj.org/operations/projections/robin.html) projection using an ESRI SRID, with\n[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a\n[cmocean thermal](https://matplotlib.org/cmocean/#thermal) colormap.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import lfric_sst\nimport geovista.theme\n\n# Load the sample data.\nsample = lfric_sst()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_unstructured(\n    sample.lons,\n    sample.lats,\n    connectivity=sample.connectivity,\n    data=sample.data,\n)\n\n# Plot the mesh on a Robinson projection using an ESRI spatial reference identifier.\nplotter = gv.GeoPlotter(crs=\"ESRI:54030\")\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(mesh, cmap=\"thermal\", show_edges=True, scalar_bar_args=sargs)\nplotter.add_coastlines()\nplotter.view_xy()\nplotter.add_axes()\nplotter.show()\n```\n</details>\n\n![lam-mollweide](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/lfric-robin.png)\n\n#### UM ORCA2\n\nSo far we've demonstrated GeoVista's ability to cope with **unstructured** data. Now let's plot a **curvilinear** mesh\nusing Met Office Unified Model (UM) ORCA2 Sea Water Potential Temperature data, with\n[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a\n[1:50m Natural Earth I](https://www.naturalearthdata.com/downloads/50m-raster-data/50m-natural-earth-1/) base layer.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import um_orca2\nimport geovista.theme\n\n# Load sample data.\nsample = um_orca2()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_2d(sample.lons, sample.lats, data=sample.data)\n\n# Remove cells from the mesh with NaN values.\nmesh = mesh.threshold()\n\n# Plot the mesh.\nplotter = gv.GeoPlotter()\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(\n    mesh, show_edges=True, scalar_bar_args=sargs\n)\nplotter.add_base_layer(texture=gv.natural_earth_1())\nplotter.add_coastlines(resolution=\"10m\")\nplotter.view_xy()\nplotter.add_axes()\nplotter.show()\n```\n</details>\n\n![um-orca](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/um-orca.png)\n\n#### OISST AVHRR\n\nNow let's render a [NOAA/NCEI Optimum Interpolation SST](https://www.ncei.noaa.gov/products/optimum-interpolation-sst)\n(OISST) Advanced Very High Resolution Radiometer (AVHRR) **rectilinear** mesh, with\n[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/) and a\n[NASA Blue Marble](https://visibleearth.nasa.gov/collection/1484/blue-marble) base layer.\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import oisst_avhrr_sst\nimport geovista.theme\n\n# Load sample data.\nsample = oisst_avhrr_sst()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_1d(sample.lons, sample.lats, data=sample.data)\n\n# Remove cells from the mesh with NaN values.\nmesh = mesh.threshold()\n\n# Plot the mesh.\nplotter = gv.GeoPlotter()\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(mesh, scalar_bar_args=sargs)\nplotter.add_base_layer(texture=gv.blue_marble())\nplotter.add_coastlines()\nplotter.view_xz()\nplotter.add_axes()\nplotter.show()\n```\n</details>\n\n![oisst-avhrr](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/oisst-avhrr.png)\n\n#### DYNAMICO Icosahedral\n\nFinally, to demonstrate support for non-traditional cell geometries i.e., not triangles or quadrilaterals, we plot\nthe **unstructured** icosahedral mesh from the [DYNAMICO](https://gitlab.in2p3.fr/ipsl/projets/dynamico/dynamico)\nproject. This model uses hexagonal cells and is a new dynamical core for\n[LMD-Z](https://www.lmd.ipsl.fr/en/modelisations/lmdz-en/), the atmospheric General Circulation Model (GCM) part of the\n[IPSL-CM](https://cmc.ipsl.fr/ipsl-climate-models/) Earth System Model. The render also contains\n[10m Natural Earth coastlines](https://www.naturalearthdata.com/downloads/10m-physical-vectors/10m-coastline/).\n\n<details>\n<summary>\ud83d\uddd2 </summary>\n\n```python\nimport geovista as gv\nfrom geovista.pantry import icosahedral\nimport geovista.theme\n\n# Load sample data.\nsample = icosahedral()\n\n# Create the mesh from the sample data.\nmesh = gv.Transform.from_unstructured(sample.lons, sample.lats, data=sample.data)\n\n# Plot the mesh.\nplotter = gv.GeoPlotter()\nsargs = {\"title\": f\"{sample.name} / {sample.units}\"}\nplotter.add_mesh(mesh, scalar_bar_args=sargs)\nplotter.add_coastlines()\nplotter.add_axes()\nplotter.show()\n```\n</details>\n\n![dynamico-icosahedral](https://raw.githubusercontent.com/bjlittle/geovista-media/2023.09.1/media/readme/dynamico-icosahedral.png)\n\n## Unreal Reels\n\nGeoVista is built on the shoulders of giants, namely [PyVista](https://docs.pyvista.org/version/stable/) and\n[VTK](https://vtk.org/documentation/), thus allowing it to easily leverage the power of the GPU.\n\nAs a result, it offers a paradigm shift in rendering performance and interactive user experience, as demonstrated by\nthis realtime, time-series animation of WAVEWATCH III\u00ae third-generation wave model (**WAVE**-height, **WAT**er depth\nand **C**urrent **H**indcasting), developed at [NOAA](https://www.noaa.gov/)/[NCEP](https://www.weather.gov/ncep/),\nquasi-unstructured Spherical Multi-Cell (SMC) grid data of Sea Surface Wave Significant Height located on cell faces.\n\n[\ud83c\udfa5 WW3 SMC time-series](https://github.com/bjlittle/geovista/assets/2051656/876d877e-a6fa-42ff-8153-08c41ff8a19e)\n\n## Further Examples\n\n<p align=\"center\">\n\"<em>Please, sir, I want some more</em>\", Charles Dickens, Oliver Twist, 1838.\n</p>\n\nCertainly, our pleasure! From the command line, simply:\n\n```bash\ngeovista examples --run all --verbose\n```\n\nWant to know more?\n```shell\ngeovista examples --help\n```\n\n<!---\n## Documentation\n\nThe [documentation](https://geovista.readthedocs.io/en/latest/) is built by [Sphinx](https://www.sphinx-doc.org/en/master/) and hosted on [Read the Docs](https://docs.readthedocs.io/en/stable/).\n-->\n\n## Ecosystem\n\nWhilst you're here, why not hop on over to the [pyvista-xarray](https://github.com/pyvista/pyvista-xarray) project and\ncheck it out!\n\nIt's aiming to provide `xarray DataArray accessors for PyVista to visualize datasets in 3D` for the\n[xarray](https://github.com/pydata/xarray) community, and will be building on top of GeoVista \ud83c\udf89\n\n## Support\n\nNeed help? \ud83d\ude22\n\nWhy not check out our [existing GitHub issues](https://github.com/bjlittle/geovista/issues). See something similar?\nWell, give it a \ud83d\udc4d to raise its priority and feel free to chip in on the conversation. Otherwise, don't hesitate to\ncreate a [new GitHub issue](https://github.com/bjlittle/geovista/issues/new/choose) instead.\n\nHowever, if you'd rather have a natter, then head on over to our\n[GitHub Discussions](https://github.com/bjlittle/geovista/discussions). That's definitely the place to wax lyrical all\nthings GeoVista!\n\n\n## License\n\nGeoVista is distributed under the terms of the [BSD-3-Clause](https://spdx.org/licenses/BSD-3-Clause.html) license.\n\n## [#ShowYourStripes](https://showyourstripes.info/s/globe)\n\n<h4 align=\"center\">\n  <a href=\"https://showyourstripes.info/s/globe\">\n    <img src=\"https://raw.githubusercontent.com/ed-hawkins/show-your-stripes/master/2022/GLOBE---1850-2022-MO.png\"\n         height=\"50\" width=\"800\"\n         alt=\"#showyourstripes Global 1850-2022\"></a>\n</h4>\n\n**Graphics and Lead Scientist**: [Ed Hawkins](http://www.met.reading.ac.uk/~ed/home/index.php), National Centre for Atmospheric Science, University of Reading.\n\n**Data**: Berkeley Earth, NOAA, UK Met Office, MeteoSwiss, DWD, SMHI, UoR, Meteo France & ZAMG.\n\n<p>\n<a href=\"https://showyourstripes.info/s/globe\">#ShowYourStripes</a> is distributed under a\n<a href=\"https://creativecommons.org/licenses/by/4.0/\">Creative Commons Attribution 4.0 International License</a>\n<a href=\"https://creativecommons.org/licenses/by/4.0/\">\n  <img src=\"https://i.creativecommons.org/l/by/4.0/80x15.png\" alt=\"creative-commons-by\" style=\"border-width:0\"></a>\n</p>\n",
    "bugtrack_url": null,
    "license": "BSD 3-Clause License  Copyright (c) 2021-2023, Bill Little All rights reserved.  Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.  3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. ",
    "summary": "Cartographic rendering and mesh analytics powered by PyVista",
    "version": "0.4.1",
    "project_urls": {
        "Code": "https://github.com/bjlittle/geovista",
        "Discussions": "https://github.com/bjlittle/geovista/discussions",
        "Issues": "https://github.com/bjlittle/geovista/issues"
    },
    "split_keywords": [
        "cartography",
        "curvilinear",
        "earth-science",
        "grid",
        "mesh",
        "python",
        "pyvista",
        "rectilinear",
        "ugrid",
        "unstructured",
        "vtk"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "c6ffa803f57b36f81585431b3008bf70c297766a373b958fd10b5f7e36599258",
                "md5": "171908a110206a2ead0d7e48b0d2ce6d",
                "sha256": "fd499465b235d5500bb98618a74448b9bcb613cff7686b13adda836f7baef740"
            },
            "downloads": -1,
            "filename": "geovista-0.4.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "171908a110206a2ead0d7e48b0d2ce6d",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 124483,
            "upload_time": "2024-01-10T15:38:51",
            "upload_time_iso_8601": "2024-01-10T15:38:51.222959Z",
            "url": "https://files.pythonhosted.org/packages/c6/ff/a803f57b36f81585431b3008bf70c297766a373b958fd10b5f7e36599258/geovista-0.4.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "5314b140d5cfac861b88b0213f229f12c1e8af047f5351d4fd6a92521aee325c",
                "md5": "7359a5860fb30c06e023c71a759c48a9",
                "sha256": "bf9087fa5b1917c612d0d60cc3a6dbc6e5fa2ce106b3fe294fbdad0d2a2925b5"
            },
            "downloads": -1,
            "filename": "geovista-0.4.1.tar.gz",
            "has_sig": false,
            "md5_digest": "7359a5860fb30c06e023c71a759c48a9",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 94303,
            "upload_time": "2024-01-10T15:38:52",
            "upload_time_iso_8601": "2024-01-10T15:38:52.704404Z",
            "url": "https://files.pythonhosted.org/packages/53/14/b140d5cfac861b88b0213f229f12c1e8af047f5351d4fd6a92521aee325c/geovista-0.4.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-01-10 15:38:52",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "bjlittle",
    "github_project": "geovista",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "tox": true,
    "lcname": "geovista"
}
        
Elapsed time: 0.20140s