Unified Histogram Interface: tools to help library authors work with histograms
Project description
UHI: Universal Histogram Interface
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. Eventually, it might gain a set of tools for testing conformance to UHI indexing, as well. 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). It requires 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 Protocols provided do support runtime checking, so
isinstance(h, uhi.typing.plotting.PlottableHistogram)
is valid at runtime and
might be simpler than manually checking for the expected methods.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file uhi-0.3.1.tar.gz
.
File metadata
- Download URL: uhi-0.3.1.tar.gz
- Upload date:
- Size: 11.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6f1ebcadd1d0628337a30b012184325618047abc01c3539538b1655c69101d91 |
|
MD5 | bbbbe815a0b24e0226ff4fbe5aaa5bb4 |
|
BLAKE2b-256 | 50ab105e1b10e7bece0e90b52674da777799f85275fc75b2fb140cd4f4f74665 |
File details
Details for the file uhi-0.3.1-py3-none-any.whl
.
File metadata
- Download URL: uhi-0.3.1-py3-none-any.whl
- Upload date:
- Size: 9.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.7.1 importlib_metadata/4.10.0 pkginfo/1.8.2 requests/2.27.1 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.9.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5c2f7ceceacd349f906104a7776859812e0926936273667eadf56762133d6d5e |
|
MD5 | c63f11e8ec02993e711e25eb98081d38 |
|
BLAKE2b-256 | 6703b2731129bba0ed39f3dbb5e5cea557491efb82f34cf2d7a9fbaee2be4a83 |