A pure MLP (four Linear layers, ReLU) on 76 hand-crafted statistical and spectral features of a 3-axis smartwatch accelerometer window (20 Hz, 128 samples = 6.4 s). It recognises five locomotion activities and runs entirely on the DLA as Gemm layers; features are computed on the host/MCU. Accuracy is subject-independent (test subjects unseen in training).
Compiled with ECS-Compiler in ECS-Studio 1.140.0 and verified on a physical ECS-DoT EVB.
This repository is a ready-to-use model folder for ECS-Compiler, the AI pipeline of ECS-Studio. It holds the ONNX model and its calibration and evaluation data. The verified result was built with the default ECS-Compiler settings; keep them unchanged to reproduce it.
Download the model folder, either from the Files tab of this page or with the Hugging Face CLI:
hf download emass-ai/wisdm_locomotion_mlp_watch --local-dir wisdm_locomotion_mlp_watch
In ECS-Studio (1.140.0 or later), open a project for the ECS-DoT EVB, open the ECS-Compiler panel and
choose wisdm_locomotion_mlp_watch.onnx as the model file. The panel loads wisdm_locomotion_mlp_watch_train.npz (calibration) and wisdm_locomotion_mlp_watch_test.npz
(evaluation) from the same folder automatically.
Click Start Pipeline, then Build and Upload to run the model on the board. The ECS-Compiler User Guide describes each step.
| Model type | activity_classification |
| Architecture | input [1,76] -> Linear(76->128) ReLU -> Linear(128->64) ReLU -> Linear(64->32) ReLU -> Linear(32->5) |
| Input | input [1, 76] float32 (76 normalised window features) |
| Preprocessing | Window of 128 samples of watch accelerometer x,y,z (m/s^2) at 20 Hz. Signals S=[x,y,z,magnitude]. Features, in order (each group lists the 4 signals x,y,z,mag in that order unless stated): mean, std, min, max, median, mean absolute deviation about the mean, 25th percentile, 75th percentile (32); zero crossings of the mean-removed signal (4); mean |
| Output | output [1, 5] float32 |
| Labels | walking, jogging, stairs, sitting, standing |
| Model size (float) | 80.4 KB |
| Parameters | 20,357 |
| Model | Precision | Board | Inference Time | Library Size | Compute Unit |
|---|---|---|---|---|---|
| wisdm_locomotion_mlp_watch | int8 | ECS-DoT EVB | 1.06 ms | 45.1 KB | DLA |
Inference time is the measured time of one dla_infer() call on the board (median of 204 runs, ECS-DoT at 50 MHz). Library size is the compiled model library libdla.a (7 layers on the DLA, 0 on the CPU).
On-board verification: Run on 3 real samples. The board's output matched the compiler's expected output exactly, and its prediction matched ONNX Runtime on every sample (cosine similarity 0.9993 or higher). On the 200-sample evaluation set the board (int8) scored 79.00% against 79.50% for the float model on the same samples, and agreed with ONNX Runtime on 199 of 200 samples.
83.43% top-1 accuracy on WISDM Smartphone and Smartwatch Activity and Biometrics Dataset (watch accelerometer), subject-independent: subjects 1600-1638 (39) train, 1639-1650 (12) test; activity codes A,B,C,D,E; full test = 6680 windows (20456 train) (6,680 samples, CC BY 4.0), measured with ONNX Runtime on the float model.
| File | Contents | Download |
|---|---|---|
wisdm_locomotion_mlp_watch.onnx |
The ONNX model | Download |
wisdm_locomotion_mlp_watch_train.npz |
Calibration set the board build quantizes with | Download |
wisdm_locomotion_mlp_watch_test.npz |
Evaluation set | Download |
sample_input.npz |
The real samples run on the board (x, with labels y) |
Download |
LICENSE |
License | Download |
README.md |
This model card | Download |
apache-2.0; see LICENSE. The training data keeps its own licence (see Training Data).e77aa59935a7.wisdm_locomotion_mlp_watch.onnx 82.3 kBwisdm_locomotion_mlp_watch_test.npz 62.9 kBwisdm_locomotion_mlp_watch_train.npz 40.4 kBsample_input.npz 1.4 kB