mosaic.Descriptor

mosaic.Descriptor#

class mosaic.Descriptor(ds, projection=None, transform=None, use_latlon=False)#

Class describing unstructured MPAS meshes in order to support plotting within matplotlib. The class contains various methods to create matplotlib.collections.PolyCollection objects for variables defined at cell centers, vertices, and edges.

Attributes#

latlonboolean

Whethere to use the lat/lon coordinates in patch construction

NOTE: I don’t think this is needed if the projection arg is

properly used at initilaization

projection : cartopy.crs.CRS

transform : cartopy.crs.CRS

cell_patches : numpy.ndarray

edge_patches : numpy.ndarray

vertex_patches : numpy.ndarray

__init__(ds, projection=None, transform=None, use_latlon=False)#

Methods

__init__(ds[, projection, transform, use_latlon])

create_minimal_dataset(ds)

Create a xarray.Dataset that contains the minimal subset of coordinate / connectivity arrays needed to create pathces for plotting

transform_patches(patches, projection, transform)

Attributes

cell_patches

edge_patches

vertex_patches