Utilities for uncertainty-aware regression and symbolic function helpers.
Project description
unc_tools
Utilities for uncertainty-aware regression and symbolic function helpers.
Python version: 3.10+
Install (uv)
uv venv
uv pip install -e .
Install (pip)
pip install unc_tools
Usage
from unc_tools import FunctionBase1D, Poly, UncRegression
# Symbolic expression with coefficients.
expr = FunctionBase1D("a*x + b")
# Polynomial helper.
poly = Poly(2)
# Regression with uncertainty propagation.
reg = UncRegression([0, 1, 2], [0, 1.1, 1.9], func=expr)
pred = reg.predict([0.5, 1.5])
Optional matplotlib and sympy patches
Importing unc_tools.patches monkey-patches matplotlib Axes.scatter/Axes.plot
and adds uncertainty-aware helpers for sympy substitution/lambdify. This is a
global side effect and should be enabled explicitly:
import unc_tools.patches # noqa: F401
Public API
UncRegression: regression with uncertainty propagation.FunctionBase1D,Poly,Hyper: symbolic helpers for 1D expressions.DataError,ExpressionError,InitialGuessError,ModelTypeError: custom exceptions.
License
This project is licensed under the MIT License.
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
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file uncertainty_tools-0.0.1.tar.gz.
File metadata
- Download URL: uncertainty_tools-0.0.1.tar.gz
- Upload date:
- Size: 15.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5c460cc606e244eb3c6bcba6b76a5e5ccdb65c44503e583a449c5488b1d66b6b
|
|
| MD5 |
c8c680c350341f1e85c71601cfd9db31
|
|
| BLAKE2b-256 |
286dd693a39b3c5a9b46307c1f198cf74253c4f64c20a75af51f4e9dcc7928f1
|
File details
Details for the file uncertainty_tools-0.0.1-py3-none-any.whl.
File metadata
- Download URL: uncertainty_tools-0.0.1-py3-none-any.whl
- Upload date:
- Size: 18.4 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8457e40c7ce06233e86aad7f3523c7875c319c49e7bf10bf18f74349ea15f82f
|
|
| MD5 |
891fab7206aa7e91d1c2599d4e100efe
|
|
| BLAKE2b-256 |
b446121fa6c089924170007a04ccf8af487eb6041184483aaf051f4d96ca6f12
|