Internal API#

This page shows already-implemented Uxarray internal API functions. You can also check the draft Uxarray API documentation to see the tentative whole API and let us know if you have any feedback!

Grid Methods#

grid.Grid.__init_ds_var_names__

Populates a dictionary for storing uxarray's internal representation of xarray object.

grid.Grid.__from_ds__

Loads a mesh dataset.

grid.Grid.__from_vert__

Create a grid with one face with vertices specified by the given argument.

grid.Grid.__init_grid_var_attrs__

Initialize attributes for directly accessing UGRID dimensions and variables.

Grid Helper Modules#

_exodus._read_exodus

Exodus file reader.

_exodus._encode_exodus

Encodes an Exodus file.

_exodus._get_element_type

Helper function to get exodus element type from number of nodes.

_ugrid._encode_ugrid

Encodes UGRID file.

_ugrid._read_ugrid

UGRID file reader.

_scrip._read_scrip

Function to reassign lat/lon variables to mesh2_node variables.

_scrip._encode_scrip

Function to reassign UGRID formatted variables to SCRIP formatted variables.

_scrip._to_ugrid

If input dataset (in_ds) file is an unstructured SCRIP file, function will reassign SCRIP variables to UGRID conventions in output file (out_ds).

helpers._is_ugrid

Check mesh topology and dimension.

helpers._convert_node_xyz_to_lonlat_rad

Calculate the latitude and longitude in radiance for a node represented in the [x, y, z] 3D Cartesian coordinates.

helpers._convert_node_lonlat_rad_to_xyz

Helper function to Convert the node coordinate from 2D longitude/latitude to normalized 3D xyz.

helpers._normalize_in_place

Helper function to project an arbitrary node in 3D coordinates [x, y, z] on the unit sphere.