iput-memerr
Asymmetric uncertainty estimates for memory consumption measurements of virtual machines.
Русская версия: README.ru.md. Documentation: docs/en, docs/ru.
What it does
The library takes a number or a vector of memory readings (bytes) and returns, for each reading, a left and a right half-width of its uncertainty. The left and right parts can differ. Seven components of the measurement uncertainty are modelled separately, each with its justification in the docs:
| Component | Source of error | Shape of the bound |
|---|---|---|
instrument |
accuracy of the measuring system (reader of the counter) | symmetric, relative |
storage |
granularity of the stored counter (memory pages) | symmetric, absolute |
time |
clock jitter and read latency, times the local slope | symmetric, depends on slope |
sampling |
the sample may miss a peak or a trough of the series | asymmetric, from neighbours |
rounding |
rounding of the value at writing | symmetric, absolute |
float |
floating-point representation (float16, float32, float64) | symmetric, relative |
definition |
shared pages counted in the value but not owned by the VM | one-sided |
Parameters choose the components to include (components) and the rule that combines them (formula): linear (sum of bounds), rss (root of sum of squares) and gum (root of sum of standard uncertainties, JCGM 100), with gum_shift as the variant that moves the centre by the one-sided definition component. Components can be switched on and off one by one to study their contribution.
Installation
pip install iput-memerr
Requires Python 3.11 to 3.14 and NumPy 2.0 or newer.
Quick start
import numpy as np
from iput_memerr import MemoryUncertainty
values = np.array([512e6, 530e6, 498e6]) # bytes
times = np.array([0.0, 1.0, 2.0]) # seconds
model = MemoryUncertainty(components=("instrument", "sampling", "float"), formula="rss")
res = model.evaluate(values, timestamp=times)
print(res.lower, res.upper) # bounds per point
print(res.symmetric) # False where left != right
A scalar works the same way; the sampling component then needs the neighbours of the reading:
res = MemoryUncertainty(components=("sampling",)).evaluate(512e6, neighbours=(500e6, 520e6))
Development
uv sync --group dev
uv run pytest
uv run ruff check .
The package has no continuous integration. Tests were run locally on Python 3.11 to 3.14.
Citation
See CITATION.cff. Changes are listed in CHANGELOG.md.
Authors
- Oleg D. Kazakov, Bryansk State University of Engineering and Technology (author).
- Andrey O. Ferubko, Bryansk State University of Engineering and Technology (contributor).
License
MIT, see LICENSE.
Metadata
Release files for iput-memerr 0.0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| iput_memerr-0.0.1.tar.gz | 35.0 kB | Without provenance | Details for iput_memerr-0.0.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| iput_memerr-0.0.1-py3-none-any.whl | Python 3 | none | any | Details for iput_memerr-0.0.1-py3-none-any.whl |
Total release size: 44.9 kB
Release files / iput_memerr-0.0.1.tar.gz
| Download URL | iput_memerr-0.0.1.tar.gz |
|---|---|
| Size | 35.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
80605db28541a5cd74091758138c3179f8e7d774e51c8c3986c5562a6e9533d0
|
|
BLAKE2b-256 checksum How to use checksums |
c89add645f5b8ecad4f581c47469cea00cd5c9b8440bcaa6d34f6c47620b1b92
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.9 {"installer":{"name":"uv","version":"0.11.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / iput_memerr-0.0.1-py3-none-any.whl
| Download URL | iput_memerr-0.0.1-py3-none-any.whl |
|---|---|
| Size | 10.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
6f538f0938951bbbddc16bfd21dd08c4b7efce823fc9430873550a07db20bc08
|
|
BLAKE2b-256 checksum How to use checksums |
a899e9f1a42d30b049fa5a021ebf3b3a1561ed0cacafae0ca7ae50164b0f2dec
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.11.9 {"installer":{"name":"uv","version":"0.11.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for iput-memerr 0.0.1
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.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.