class RegressionResults(BaseEvaluationResults): (source)
Constructor: RegressionResults(samples, config, eval_key, ytrue, ...)
Class that stores the results of a regression evaluation.
Parameters | |
samples | the fiftyone.core.collections.SampleCollection used |
config | the RegressionEvaluationConfig used |
eval | the evaluation key |
ytrue | a list of ground truth values |
ypred | a list of predicted values |
confs | an optional list of confidences for the predictions |
eval | the evaluation key of the evaluation |
gt | the name of the ground truth field |
pred | the name of the predictions field |
ids | a list of sample or frame IDs corresponding to the regressions |
missing | a missing value. Any None-valued regressions are given this value for results purposes |
custom | an optional dict of custom metrics |
backend | a RegressionEvaluation backend |
Method | __init__ |
Undocumented |
Method | metrics |
Computes various popular regression metrics for the results. |
Method | plot |
Plots the regression results. |
Method | print |
Prints the metrics computed via metrics . |
Instance Variable | confs |
Undocumented |
Instance Variable | ids |
Undocumented |
Instance Variable | missing |
Undocumented |
Instance Variable | ypred |
Undocumented |
Instance Variable | ytrue |
Undocumented |
Class Method | _from |
Subclass implementation of from_dict . |
Inherited from BaseEvaluationResults
:
Method | _get |
Undocumented |
Method | _print |
Undocumented |
Inherited from BaseRunResults
(via BaseEvaluationResults
, EvaluationResults
):
Class Method | from |
Builds a BaseRunResults from a JSON dict representation of it. |
Static Method | base |
Returns the results class for the given run type. |
Method | attributes |
Returns the list of class attributes that will be serialized by serialize . |
Method | save |
Saves the results to the database. |
Method | save |
Saves these results config to the database. |
Property | cls |
The fully-qualified name of this BaseRunResults class. |
Property | config |
The BaseRunConfig for these results. |
Property | key |
The run key for these results. |
Property | samples |
The fiftyone.core.collections.SampleCollection associated with these results. |
Instance Variable | _backend |
Undocumented |
Instance Variable | _config |
Undocumented |
Instance Variable | _key |
Undocumented |
Instance Variable | _samples |
Undocumented |
Undocumented
Computes various popular regression metrics for the results.
The computed metrics are:
- Mean squared error:
sklearn:sklearn.metrics.mean_squared_error
- Root mean squared error:
sklearn:sklearn.metrics.mean_squared_error
- Mean absolute error:
sklearn:sklearn.metrics.mean_absolute_error
- Median absolute error:
sklearn:sklearn.metrics.median_absolute_error
- R^2 score:
sklearn:sklearn.metrics.r2_score
- Explained variance score:
sklearn:sklearn.metrics.explained_variance_score
- Max error:
sklearn:sklearn.metrics.max_error
- Support: the number of examples
Also includes any custom metrics from custom_metrics
.
Parameters | |
weights:None | an optional list of weights for each example |
Returns | |
a dict |
Plots the regression results.
You can use the labels parameters to define a coloring for the points, and you can use the sizes parameter to scale the sizes of the points.
You can attach plots generated by this method to an App session via its
fiftyone.core.session.Session.plots
attribute, which will
automatically sync the session's view with the currently selected
points in the plot.
Parameters | |
labels:None | data to use to color the points. Can be any of the following:
|
sizes:None | data to use to scale the sizes of the points. Can be any of the following:
|
backend:"plotly" | the plotting backend to use. Supported values are ("plotly", "matplotlib") |
**kwargs | keyword arguments for the backend plotting method:
|
Returns | |
an fiftyone.core.plots.base.InteractivePlot |
Subclass implementation of from_dict
.
Parameters | |
d | a JSON dict |
samples | the fiftyone.core.collections.SampleCollection
for the run |
config | the BaseRunConfig for the run |
eval | Undocumented |
key | the run key |
**kwargs | Undocumented |
Returns | |
a BaseRunResults |