data module
This section contains the Python API reference for the uncertainty_toolbox.data
module, which contains code for importing and generating data.
uncertainty_toolbox.data Module
Code for importing and generating data.
- uncertainty_toolbox.data.synthetic_arange_random(num_points=10)
Dataset of evenly spaced points and identity function (with some randomization).
This function returns predictions and predictive uncertainties (given as standard deviations) from some hypothetical uncertainty model, along with true input x and output y data points.
- Parameters
num_points (
int
) – The number of data points in the set.- Return type
Tuple
[ndarray
,ndarray
,ndarray
,ndarray
]- Returns
The y predictions given by a hypothetical predictive uncertainty model. These are the true values of y but with uniform noise added.
The standard deviations given by a hypothetical predictive uncertainty model. These are the errors between the predictions and the truth plus some unifom noise.
The true outputs y.
The true inputs x.
- uncertainty_toolbox.data.synthetic_sine_heteroscedastic(n_points=10)
Return samples from “synthetic sine” heteroscedastic noisy function.
This returns a synthetic dataset which can be used to train and assess a predictive uncertainty model.
- Parameters
n_points (
int
) – The number of data points in the set.- Return type
Tuple
[ndarray
,ndarray
,ndarray
,ndarray
]- Returns
Predicted output points y.
Predictive uncertainties, defined using standard deviation of added noise.
True output points y.
True input points x.