mean_absolute_error()¶
- audmetric.mean_absolute_error(truth, prediction)[source]¶
Mean absolute error.
- Parameters
truth (
Sequence
[float
]) – ground truth valuesprediction (
Sequence
[float
]) – predicted values
- Return type
float
- Returns
mean absolute error
- Raises
ValueError – if
truth
andprediction
differ in length
Examples
>>> mean_absolute_error([0, 0], [0, 1]) 0.5