Examples
Start with a model, then explore memory, precision, custom operators or hardware profiling. Every example includes a walkthrough, configuration and runnable script.
Choose an example
Section titled “Choose an example”Start with a model
Section titled “Start with a model”Start here
First model
One conversion, the emitted module tree, and the arena summary the converter prints
Configure and tune
Section titled “Configure and tune”Host conversion · CI checked
Memory placement
Per-role placement rules, staged constants, caller-supplied arenas, and residency-report comparisons
Host conversion · CI checked
Static schedule
module.schedule, generated dispatch code and callback availability
Host conversion · CI checked
Float and FP16
Float kernel selection, the FP16 platform gate, and the ns-cmsis-nn build switches a float module needs
State and extension
Section titled “State and extension”Host conversion · CI checked
Recurrent state
LiteRT variable tensors as persistent arenas, and what test.state_feedback is for
Host conversion · CI checked
Custom operator
RegistryContext, a LiteRT parser, an AotOperator subclass, and the Python-only path a custom operator takes
Hardware recipes
Section titled “Hardware recipes”Manual setup
Ethos-U
The Ethos-U operator, the driver dependency, and the platform gate
Manual setup
Profile with hpx
The two-config comparison recipe and how to read it
Before you start
Section titled “Before you start”These examples require access to the private heliaAOT repository. A package-only installation does not include the example checkout.
Use a repository checkout with Bash and Python 3.11 or newer. From the repository root, prepare and activate the project environment:
uv sync --frozen --group cisource .venv/bin/activateNo example downloads its model. An isolated CLI installation does not include the Python dependencies used by the model-building scripts.
Ethos-U needs a Vela-compiled model. Profiling needs a supported board and the profiler toolchain. Check the prerequisites on each example page before running it.
Run an example
Section titled “Run an example”From the repository root, after activating the environment:
cd examples/first-model./run.shThe script converts the example’s model and writes the module under out/. Read the example page before selecting another configuration or building the generated firmware.
Host conversion and compile checks
Section titled “Host conversion and compile checks”Six examples have CI conversion and host-compilation checks; these do not establish on-device numerical or timing qualification. Browse the source examples for their READMEs and scripts.
The canonical example overview documents examples/check.sh and its HELIA_CMSIS_NN_SOURCE_DIR dependency. This compiles individual translation units; it does not link or run target inference.
Model provenance
Section titled “Model provenance”first-model/kws_ref holds the MLPerf Tiny keyword-spotting model and its golden fixture: byte-identical to the mlcommons/tiny artifact, with the fixture from helia-model-zoo at a fixed commit, Apache-2.0. Its README records the source revisions and the SHA-256 of both files.
The synthetic float-fp16, custom-operator and recurrent-state recipes
build small fixtures locally.