Model Evaluation
Evaluating a Motion model
Read the evaluation results, test the model on your testing data, and try it live.
Try it in StudioOn this page
Goal
By the end of this page you will know how good your Motion model is, and where it makes mistakes.
Studio gives you three tools:
| Studio page | What it does |
|---|---|
| Evaluation | Shows the model's scores and confusion matrix |
| Model testing | Runs the model on every recording in your testing set |
| Live classification | Runs the model on new data from a connected device, or on one saved test recording |
Evaluation
- Open Evaluation.
- Use Model version: to choose which saved version to look at, for example Quantized (int8) or Unoptimized (float32). Scores are stored separately for each version, so you can compare them.
- Read the results:
| Result | Meaning |
|---|---|
| Training accuracy / Validation accuracy | How the model did on the data it trained on, and on the held-out validation recordings |
| Evaluation accuracy | How it did on the evaluation data |
| Per window / Per recording | Switch between scoring every window, or scoring whole recordings |
| Confusion matrix | Rows are the real labels, columns are the predicted labels |
| Prec., Recall, F1 | Per-label scores; see Evaluation metrics |
| Training graphs | Loss for training and validation over the training cycles |
Per window or per recording?
- Per window scores every window on its own.
- Per recording gives each whole recording the label most of its windows voted for, then scores the recordings. It is usually higher, because a few wrong windows are outvoted.
Reading the confusion matrix
Numbers on the diagonal are correct predictions. A large number off the diagonal shows two labels the model mixes up, for example wave predicted as circle. Record more, clearer examples of those two labels.
Regression models
For Regression, the results are MAE, RMSE and R², and the graphs show MAE. See Regression.
Model testing
- Open Model testing.
- Select Classify all. Studio runs the model on every recording in the testing set.
- Use the Per window / Per recording switch to change how results are counted.
- Look at Confidence charts: Confidence per window and Predicted classes.
- Select a recording to open the Recording inspector, which shows Expected, Predicted and Score.
Live classification
From a connected device
- Open Live classification.
- In Live session, choose the Device and select Start Session.
- Do the movements. Raw sensor stream shows the incoming data, Prediction timeline shows the prediction for each window, and Session verdict shows the majority vote over the whole session.
- Select Stop Session when done.
The device must be connected through Devices, as described in Recording from a device.
From a saved recording
Under Classify existing test sample, choose a Test sample and select Classify Sample. Studio shows the Expected and Predicted result.
What good results look like
- Per-recording accuracy close to per-window accuracy, and both high.
- No label that is mostly predicted as another label.
- INT8 scores close to Float32 scores, so the smaller version is safe to deploy.