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/activateFetched-model examples also need curl and sha256sum or shasum. 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 fetches or builds its model and writes the converted 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. No model binaries are committed.
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”The examples that use a model from
helia-model-zoo use
audio/mlperf-tiny/kws_ref. The checked-in run scripts define the expected
model and golden SHA-256 values. Consult the upstream model card for its
provenance; this example does not establish the current contents of the entire
zoo or its manifest.
The downloader uses fixed SHA-256 values but fetches from the zoo’s main
branch. A changed artifact fails the hash check; do not replace the expected
hash just to make a download succeed. Record the model hash and the source
revision with your conversion.
These examples do not establish redistribution rights for the downloaded
model. Check the upstream model card and applicable terms for your use; a
model-family name or this repository’s software licence does not establish
the model’s licence. The synthetic float-fp16, custom-operator and
recurrent-state recipes build small fixtures locally and make no claim about
what other models the current zoo contains.