$npx skillfedfor your agent

pint-xarray

Physical units interface to xarray using Pint

Worth itPyPI Scientific/EngineeringReleased Mar 2026113.3K downloads / moApache-2.0Pure Python

Decision gist · record as of 2026-08-14

pure-Python wheel — pint_xarray-0.6.1-py3-none-any.whl
v0.6.1 · released 2026-03-23 · Python >=3.11 · 3 runtime deps: xarray, numpy, pint

Yes. The package is actively maintained, has no known vulnerabilities, installs with low friction, and fills a genuine gap for scientists and engineers working with xarray who need physical units. The Apache-2.0 license is permissive. Start with it if you're already using xarray and need dimensional tracking; the API is straightforward and the dependency footprint is small.AI-flagged interpretation of the facts on this page — verify before relying

Before you install

  • Requires Python 3.11 or later.
  • Low friction installation with a pure-Python wheel.
  • Actively maintained as of 2026-08-14 with recent releases; depends on three well-established packages (xarray, numpy, pint) that are standard in scientific Python.

License · maintenance · safety

Apache-2.0 (permissive) — Apache-2.0 permissive license allows commercial and private use with minimal restrictions, making it safe for most projects.

last release 2026-03-23 (144 days) · last repo commit 2026-08-14 · 119 stars

0 known vulnerabilities (OSV.dev, 2026-08-14) · 113,278 downloads/mo, #12,347 on PyPI

Verify before relying

pip install pint-xarray

import pint_xarray
import xarray as xr

ds = xr.Dataset({"a": ("x", [0, 1, 2]), "b": ("y", [-3, 5, 1], {"units": "m"})})
q = ds.pint.quantify(a="s")
c = q.pint.to({"a": "ms", "b": "km"})
  • Whether unit-aware operations preserve xarray's lazy evaluation and chunking (Dask integration).
  • Performance impact of unit tracking on large multidimensional arrays.
  • Compatibility with xarray's groupby, resample, and other high-level operations when units are attached.
Same gist for agents: .md · .json

What it is and what it does

pint-xarray bridges Pint's physical units library with xarray's labeled multidimensional arrays, letting you attach and track units on dataset variables and perform unit-aware arithmetic and conversions. It works by registering accessor methods on xarray objects, so you call `.pint.quantify()` to add units, `.pint.to()` to convert between units, and `.pint.dequantify()` to strip units back off.

The package is designed for scientific and engineering workflows where dimensional consistency matters—tracking whether a measurement is in meters or kilometers, seconds or milliseconds—and catching unit mismatches before they propagate through calculations. It integrates directly with xarray's data model, so units stay attached to variables as you slice, combine, or transform datasets.

Use it for

  • Attach units to climate or weather model output and convert between unit systems for analysis.
  • Track physical dimensions through geophysical data processing pipelines to catch unit errors early.
  • Perform dimensional analysis on scientific datasets to ensure unit consistency across operations.
  • Convert measurement data from one unit system to another while preserving xarray's labeled structure.
  • Build unit-aware data pipelines for physics or engineering simulations using xarray as the data container.

Worth the install?

AI-flagged interpretation of the facts on this page. Verify before relying on it.

Worth it

Yes.

The package is actively maintained, has no known vulnerabilities, installs with low friction, and fills a genuine gap for scientists and engineers working with xarray who need physical units. The Apache-2.0 license is permissive. Start with it if you're already using xarray and need dimensional tracking; the API is straightforward and the dependency footprint is small.

Install

pint-xarray on PyPI

Before you install

Low friction installation with a pure-Python wheel. Actively maintained as of 2026-08-14 with recent releases; depends on three well-established packages (xarray, numpy, pint) that are standard in scientific Python.

Requires Python 3.11 or later.

License in practice

Apache-2.0 permissive license allows commercial and private use with minimal restrictions, making it safe for most projects.

Quickstart

pip install pint-xarray

import pint_xarray
import xarray as xr

ds = xr.Dataset({"a": ("x", [0, 1, 2]), "b": ("y", [-3, 5, 1], {"units": "m"})})
q = ds.pint.quantify(a="s")
c = q.pint.to({"a": "ms", "b": "km"})

Verify before relying

  • Whether unit-aware operations preserve xarray's lazy evaluation and chunking (Dask integration).
  • Performance impact of unit tracking on large multidimensional arrays.
  • Compatibility with xarray's groupby, resample, and other high-level operations when units are attached.

Package facts

LicenseApache-2.0 permissive
Python supportSupports the current Python release >=3.11
Install frictionLow. Pure-Python wheel
Runtime dependencies
3 packages
xarraynumpypint
MaintenanceActively maintained 144 days since the last release
Last repo commit
First released
Downloads113,278 / month, #12,347 on PyPI 30-day window, as of 2026-08-14
Known vulnerabilitiesNone known OSV.dev, checked 2026-08-14
Classifiers
Development Status :: 3 - AlphaEnvironment :: ConsoleIntended Audience :: Science/ResearchOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3.11Programming Language :: Python :: 3.12Programming Language :: Python :: 3.13Programming Language :: Python :: 3.14Topic :: Scientific/Engineering

Evidence: pint_xarray-0.6.1-py3-none-any.whl

Tags

Capabilities
xarray unitspint xarray integrationphysical units for arraysunit conversion xarraydimensional analysis xarrayquantity arraysscientific data units
Topics
units-and-quantitiesscientific-computingdata-validation

Let your AI agent find packages like this

Example. Real query, live index.

You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.

wish › “xarray units”

  • pint-xarrayAdds physical units support to xarray datasets and data variables…
  • spatial_imagespatial-image provides an N-dimensional spatial image data structure…
  • xprojXProj is an Xarray extension that provides tools for managing…

Give your agent the search over MCP, or paste the wish link into any chat.

More Scientific/Engineering packages

numpy Worth it
PyPI · Software Development · released Aug 2026

NumPy provides an N-dimensional array object and a comprehensive suite of mathematical, linear algebra, Fourier transform, and random number functions for scientific computing in Python.

BSD-3-Clause AND 0BSD AND MIT AND Zlib AND CC0-1.0compiled wheel · 3.12+
1.1Bdownloads / mo
pandas Worth it
PyPI · Scientific/Engineering · released Jul 2026

pandas provides fast, flexible data structures (Series and DataFrame) for loading, cleaning, transforming, and analyzing labeled or relational data in Python.

BSD-3-Clausecompiled wheel · 3.11+
769.1Mdownloads / mo
scipy Worth it
PyPI · Libraries · released Jun 2026

scipy provides numerical algorithms for mathematics, science, and engineering—including optimization, integration, linear algebra, Fourier transforms, signal and image processing, and ODE solvers—built on numpy arrays.

BSD-3-Clausecompiled wheel · 3.12+
449.0Mdownloads / mo
scikit-learn Worth it
PyPI · Software Development · released Jun 2026

scikit-learn provides a comprehensive Python library for supervised and unsupervised machine learning, including classification, regression, clustering, dimensionality reduction, and model evaluation tools built on NumPy and SciPy.

Install it if you need to train, evaluate, or deploy supervised or unsupervised learning models.

BSD-3-Clausecompiled wheel · 3.11+
235.5Mdownloads / mo
dill Worth it
PyPI · Software Development · released Jan 2026

dill extends Python's pickle module to serialize and deserialize a much wider range of Python objects, including functions, lambdas, classes, and interpreter sessions, to byte streams for storage or network transmission.

BSD-3-Clausepure Python · 3.9+
208.1Mdownloads / mo
multiprocess Worth it
PyPI · Software Development · released Jan 2026

Multiprocess is an enhanced fork of Python's standard multiprocessing library that uses dill for better serialization, allowing you to spawn processes with a threading-like API and share complex objects between them.

Install it if you use multiprocessing and encounter pickle serialization limits with lambdas or complex objects.

BSD-3-Clausepure Python · 3.9+
202.7Mdownloads / mo

See also Pint · unyt · xarray-dataclass · Pint-Pandas · ucumvert · typedunits · xarray · hepunits · quantities · spatial_image