Skip to main content

UHI: Universal Histogram Interface

Actions Status Documentation Status pre-commit.ci Status Code style: black

PyPI version Conda-forge version PyPI platforms

GitHub Discussion Gitter Zenodo Scikit-HEP SPEC 4 — Using and Creating Nightly Wheels

This is a package meant primarily for documenting histogram indexing and the PlottableHistogram Protocol and any future cross-library standards. It also contains the code for the PlottableHistogram Protocol, to be used in type checking libraries wanting to conform to the protocol, and uhi.testing, a set of tools for testing conformance to UHI indexing. It is not usually a runtime dependency, but only a type checking, testing, and/or docs dependency in support of other libraries (such as boost-histogram 0.13+, hist 2.1+, mplhep 0.2.15+, uproot 4+, and histoprint 2+). There are a few useful runtime usable components (listed below). Older versions are available for Python 3.6+. See what's new.

To assist plotting libraries in accepting Histograms from classic sources, see uhi.numpy_plottable.ensure_plottable_histogram, which will adapt NumPy style tuples into a simple PlottableHistogram.

The uhi.io module can read and write histograms in JSON, ZIP, HDF5, and ROOT (with uproot or PyROOT), and uhi.io.ops.add sums histograms bin-by-bin. The uhi add command does the same for files, like ROOT's hadd. The uhi validate command checks files against the schema (needs the schema extra).

The Protocols provided do support runtime checking, so isinstance(h, uhi.typing.plottable.PlottableHistogram) is valid at runtime and might be simpler than manually checking for the expected methods.

Metadata

Release files for uhi 1.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for uhi 1.2.1
File Size Uploaded
uhi-1.2.1.tar.gz 80.3 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for uhi 1.2.1
File Interpreter ABI Platform
uhi-1.2.1-py3-none-any.whl Python 3 none any Details

Total release size: 119.5 kB

Release files / uhi-1.2.1.tar.gz

Download URL uhi-1.2.1.tar.gz
Size 80.3 kB
Tags Source
SHA-256 checksum
How to use checksums
fc6ee5b2457af544d89804ef5f5530ca5fc948a52e3168cd5c4539b03a742dce
BLAKE2b-256 checksum
How to use checksums
cb063a8ad05bbaea453129bafaf6d0271fabf59e53b7757cdc8cd58144b684f1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.

Transparency log

Release files / uhi-1.2.1-py3-none-any.whl

Download URL uhi-1.2.1-py3-none-any.whl
Size 39.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
063c36d9383d6e1e33ecc0c8b17a01be271012b9c86f11d21afcb8290c23e804
BLAKE2b-256 checksum
How to use checksums
4dedf2df559229b8da8aef6adc554e2fd3a0906593d382cfb2b95aec235ddda4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Oct 7, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

1.2.1 This release

2 release files

1.2.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

0.5.0

2 release files

0.4.0

2 release files

0.3.3

2 release files

0.3.2

2 release files

0.3.1

2 release files

0.3.0

2 release files

0.2.1

2 release files

0.2.0

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page