Stats
Measure the difference between the values predicted by a neural network and the observed values.
Calculate the root mean square error:
Stats.rmse(
Iterator(
(List(0.0, 0.0, 1.0), List(0.0, 0.0, 1.0)),
(List(0.0, 0.0, 1.0), List(0.0, 1.0, 1.0))
)
)
Calculate the score of the classification accuracy:
Stats.score(
Iterator(
(List(0.0, 0.0, 1.0), List(0.0, 0.1, 0.9)),
(List(0.0, 1.0, 0.0), List(0.8, 0.2, 0.0)),
(List(1.0, 0.0, 0.0), List(0.7, 0.1, 0.2)),
(List(1.0, 0.0, 0.0), List(0.3, 0.3, 0.4)),
(List(0.0, 0.0, 1.0), List(0.2, 0.2, 0.6))
(List(0.0, 0.0, 1.0), List(0.0, 0.1, 0.9)),
(List(0.0, 1.0, 0.0), List(0.8, 0.2, 0.0)),
(List(1.0, 0.0, 0.0), List(0.7, 0.1, 0.2)),
(List(1.0, 0.0, 0.0), List(0.3, 0.3, 0.4)),
(List(0.0, 0.0, 1.0), List(0.2, 0.2, 0.6))
)
)
Value members
Concrete methods
Root Mean Square Error.
Root Mean Square Error.
RMSE is the standard deviation of the prediction errors.
- Value Params
- outputPairs
An iterator of pairs that contain the expected and predicted values.
- Returns
The value of the RMSE metric.
Classification Accuracy.
Classification Accuracy.
The ratio of number of correct predictions to the total number of provided pairs. For a prediction to be considered as correct, the index of its maximum expected value needs to be the same with the index of its maximum predicted value.
- Value Params
- outputPairs
An iterator of pairs that contain the expected and predicted values.
- Returns
The score of the classification accuracy.