uxarray

raw JSON →
2026.4.1 verified Fri May 01 auth: no python

UXarray is an Xarray extension for working with unstructured grid climate and global weather data, providing grid-aware analysis operations such as remapping, averaging, and visualization. Current version: 2026.4.1. Released approximately monthly.

pip install uxarray
error ModuleNotFoundError: No module named 'uxarray'
cause uxarray is not installed.
fix
Run 'pip install uxarray' or 'conda install -c conda-forge uxarray'.
error ImportError: cannot import name 'open_dataset' from 'uxarray'
cause Using an old version that does not export 'open_dataset' at the top level.
fix
Upgrade uxarray: 'pip install --upgrade uxarray'.
error ValueError: Grid type not recognized or unsupported format
cause The file does not contain a recognized unstructured grid format or has missing attributes.
fix
Check that the file is a supported format (UGRID, MPAS, etc.) and contains required grid topology variables. Use 'uxarray.Grid.from_file()' for more control.
breaking Requires Python >= 3.10. Older Python versions are not supported.
fix Upgrade to Python 3.10 or higher.
breaking UXarray v2026.4.0+ is not compatible with xarray < 2026.4.0. Breaking changes in xarray 2026.4.0 required updates.
fix Update xarray to version 2026.4.0 or later: pip install 'xarray>=2026.4.0'.
gotcha When opening datasets, the grid topology must be present in the file. Opening a standard structured grid file (e.g., regular lat/lon) will fail or produce unexpected results.
fix Ensure your file is an unstructured grid format (e.g., UGRID, MPAS, SCRIP, ESMF). For structured data, use xarray directly.
gotcha Grid parsing can be strict. Files with missing or non-standard metadata may not load. For example, the ICON reader checks for required attributes.
fix Verify your file conforms to the expected conventions. Refer to the grid parsing documentation.
conda install -c conda-forge uxarray

Open an unstructured grid dataset and perform basic operations.

import uxarray as ux

# Open an unstructured grid dataset
ds = ux.open_dataset("https://raw.githubusercontent.com/UXARRAY/uxarray/main/test/meshfiles/geoflow-small.nc")

# Print the grid
print(ds.uxgrid)

# Compute the mean of a variable (if present)
if 'var' in ds:
    print(ds['var'].mean())

# Visualize the grid
ds.uxgrid.plot.mesh()