ansys-units
Pythonic interface for units, unit systems, and unit conversions.
Decision gist · record as of 2026-08-14
Yes. The package is actively maintained, has low install friction, carries no known vulnerabilities, and uses a permissive MIT license. It solves a real problem—dimensional consistency in numerical code—with a clean API. Install it if you work with physical quantities and want automatic unit tracking; skip it if your calculations never mix units or if you need a heavier symbolic math system.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.10 or later (supports up to 3.14).
- NumPy is optional but needed for array-based quantities.
- Low install friction with only two lightweight runtime dependencies (pyyaml and typing-extensions).
License · maintenance · safety
MIT (permissive) — MIT license permits unrestricted use, modification, and distribution in both open-source and commercial projects with minimal attribution requirements.
last release 2026-06-16 (59 days) · last repo commit 2026-08-07 · 6 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 94,246 downloads/mo, #13,337 on PyPI
Alternatives
Verify before relying
pip install ansys-units
import ansys.units as ansunits
from ansys.units.common import m, s
volume = 1 * m**3
print(volume.value, volume.units.name)
velocity = 10 * m / s
print(velocity.to(ansunits.UnitRegistry().km / ansunits.UnitRegistry().hour))- Whether NumPy integration is automatic or requires explicit installation beyond the listed runtime dependencies.
- Performance characteristics when working with large arrays or complex unit systems.
- Completeness of the bundled physical units and constants relative to domain-specific needs.
What it is and what it does
PyAnsys Units is a Python library for working with physical quantities—combinations of numerical values and units of measurement. It provides a Quantity class that wraps values with their units, enabling arithmetic operations (addition, subtraction, multiplication, division, exponentiation) while automatically tracking and validating dimensional consistency. The package includes a UnitRegistry for accessing predefined units, a UnitSystem abstraction for switching between measurement systems (SI, imperial, custom), and direct conversion between compatible units.
The library is designed for scientific and engineering workflows where dimensional analysis matters. It works with scalar values, lists, and NumPy arrays, and integrates with standard Python math functions. Its modular design allows extending the unit and constant definitions without modifying source code. With complete test coverage and support for Python 3.10 through 3.14, it targets researchers and engineers who need reliable unit handling in calculations.
Use it for
- Perform physics calculations with automatic dimensional checking to catch unit mismatches early.
- Convert between unit systems (e.g., SI to imperial) in scientific simulations or data pipelines.
- Work with NumPy arrays of measurements while preserving and validating their units throughout operations.
- Define custom unit systems for domain-specific engineering problems without modifying the library.
- Integrate unit-aware quantities into data analysis workflows that mix different measurement standards.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
The package is actively maintained, has low install friction, carries no known vulnerabilities, and uses a permissive MIT license. It solves a real problem—dimensional consistency in numerical code—with a clean API. Install it if you work with physical quantities and want automatic unit tracking; skip it if your calculations never mix units or if you need a heavier symbolic math system.
Install
ansys-units on PyPI
Before you install
Low install friction with only two lightweight runtime dependencies (pyyaml and typing-extensions). Active maintenance with a recent release 59 days ago and current commit activity.
Requires Python 3.10 or later (supports up to 3.14). NumPy is optional but needed for array-based quantities.
License in practice
MIT license permits unrestricted use, modification, and distribution in both open-source and commercial projects with minimal attribution requirements.
Quickstart
pip install ansys-units
import ansys.units as ansunits
from ansys.units.common import m, s
volume = 1 * m**3
print(volume.value, volume.units.name)
velocity = 10 * m / s
print(velocity.to(ansunits.UnitRegistry().km / ansunits.UnitRegistry().hour))
Verify before relying
- Whether NumPy integration is automatic or requires explicit installation beyond the listed runtime dependencies.
- Performance characteristics when working with large arrays or complex unit systems.
- Completeness of the bundled physical units and constants relative to domain-specific needs.
Package facts
| License | MIT permissive |
| Python support | Supports the current Python release <3.15,>=3.10 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 2 packagespyyamltyping-extensions |
| Maintenance | Actively maintained 59 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 94,246 / month, #13,337 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Development Status :: 4 - BetaIntended Audience :: Science/ResearchOperating System :: OS IndependentProgramming Language :: Python :: 3Topic :: Scientific/Engineering :: Information Analysis |
Evidence: ansys_units-0.12.1-py3-none-any.whl
Tags
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 › “unit arithmetic operations”
- ansys-unitsManages physical quantities with numerical values and units,…
- PintPint defines, operates on, and converts between physical…
- typedunitsImplements unit of measurement arithmetic with static type checking…
Give your agent the search over MCP, or paste the wish link into any chat.
More Information Analysis packages
A drop-in replacement for Python's standard `re` module that adds advanced regex features like nested sets, fuzzy matching, lookaround in conditionals, and full Unicode case-folding while maintaining backward compatibility.
pyarrow provides Python bindings to Apache Arrow's C++ libraries for efficient columnar data processing, serialization, and interoperability with pandas, NumPy, and other Python ecosystem tools.
NetworkX provides data structures and algorithms for creating, analyzing, and manipulating graphs and networks, supporting everything from simple undirected graphs to complex directed and weighted networks.
Connects Python applications to Snowflake data warehouses using the DB API 2.0 specification, enabling SQL queries, data transfers, and warehouse operations.
ContourPy calculates contours of 2D quadrilateral grids using C++11 algorithms wrapped in Python, offering serial and multithreaded implementations without requiring Matplotlib as a dependency.
Snowpark Python provides APIs to query and process data directly in Snowflake without moving data to your local system, with support for both native Snowpark and pandas-compatible interfaces.
Install it if you use Snowflake and want to process data without moving it to your application layer.
See also measurement · Pint · isqx · quantities · hepunits · Pint-Pandas · unyt · ansys-tools-common · binary · ucumvert