# heliaPROFILER

Find the bottleneck.Test the next idea.

heliaPROFILER (hpx) is a command-line toolkit for profiling AI models on Ambiq hardware. Measure inference latency, find costly layers, and compare engine and memory choices using saved results.

[Get started](https://ambiqai.github.io/helia-profiler/getting-started/)
[Explore examples](https://ambiqai.github.io/helia-profiler/examples/)
v

01 / Inference and layer timing
One complete inferenceConvolutionDepthwiseFully connected
Find where the time goes.
Measure the full inference, then use per-layer timings to decide what to optimize.

02 / CPU and NPU profiling
Hardware performance countersArm MVE / HeliumEthos-U NPUVector instructionsNPU countersMVE on supported targets · NPU FPGA support experimental
Inspect MVE and NPU execution.
Examine vector activity and NPU counters. Ethos-U profiling on Atomiq110 FPGA is experimental.

03 / Compare the next run
LiteRTheliaAOTLatency38.69 ms → 12.14 msTotal model memory89.7 KB → 40.4 KBheartKIT AFIB · Apollo510 · CPU / Helium, no NPU
3.2x faster, 55% less memory.
heartKIT AFIB on Apollo510, LiteRT → heliaAOT.

04 / Measure power and energy
Inference windowPower traceEnergy / inference
Measure energy per inference.
Measure the monitored supply with a supported Joulescope or INA228, alongside inference timing.

LiteRT
heliaRT
heliaAOT

Measure · Inspect · Compare
From setup to a side-by-side comparison.
Check your tools, find a debug probe and profile the heartKIT AFIB arrhythmia classifier. Compare LiteRT with heliaAOT to see the difference in latency and model memory.
Run your first profile →
Setup output shows an illustrative connected probe. Commands are illustrative excerpts, not a runnable recipe: afib.yml stands for your own configuration file. The tables show measured profiling results. Select a step to explore; click the active step to pause or resume.

ⓘ About this example

About this profiling example×
heartKIT arr-2-eff-sm (INT8). Apollo510 EVB, Cortex-M55 with Helium, 96 MHz low-power mode; no NPU. ATfE 22.1.0.
LiteRT: Ambiq TFLM with Arm CMSIS-NN. heliaAOT 0.23: ns-cmsis-nn 7.36.
Measured 2026-09-28: 5 warmups, 100 profiled iterations. Median latency from a clean window of 48 inferences.
Total model memory = activation arena + model storage. Arena means LiteRT’s actual usage or AOT’s static arena; storage means the LiteRT flatbuffer or AOT’s packed constants.

```text
$ hpx doctor

Toolchain Check
  ✓ CMake (>= 3.24)
  ✓ Ninja build system
  ✓ SEGGER J-Link commander
  ✓ neuralspotx Python package
  ✓ ARM GCC toolchain

  All required tools found.
```

```text
$ hpx probes list

  serial      product                   connection
  801000001   J-Link-OB-Apollo4-CortexM  USB
```

```text
$ hpx profile --config afib.yml --engine tflm \
  --output-dir results/litert-afib

  Engine    tflm
  Board     apollo510_evb
```

heartKIT arr-2-eff-sm · INT8 · LiteRT
Median latency38.69 msCycles3,714,336Activation RAM28.3 KBModel storage61.4 KBTotal model memory89.7 KB

```text
$ hpx profile --config afib.yml --engine helia-aot \
  --output-dir results/aot-afib

  Engine    helia-aot
  Board     apollo510_evb
```

heartKIT arr-2-eff-sm · INT8 · heliaAOT 0.23
Median latency12.14 msCycles1,164,960Activation RAM14.7 KBModel storage25.7 KBTotal model memory40.4 KB

```text
$ hpx compare results/litert-afib results/aot-afib

  Config
  Field    Baseline   Candidate   Status
  Engine   tflm       helia-aot   diff
```

Profiling example · heartKIT AFIB
MeasurementLiteRTheliaAOTChangeLatency38.69 ms12.14 ms3.2x fasterCycles3,714,3361,164,960-69%Activation RAM28.3 KB14.7 KB-48%Model storage61.4 KB25.7 KB-58%Total model memory89.7 KB40.4 KB-55%

Find the bottleneck
Understand the cost of inference.
Measure the model as a whole, then investigate the operations and hardware activity behind the result.

Measure the model. Locate the cost.Start with latency from a clean inference window, then inspect a separate instrumented pass to find the operators worth optimizing.heartKIT AFIB · heliaAOT12.14 msMedian latency · Apollo510 @ 96 MHzEstablish the baselineMeasure the complete inference without per-layer counter reads. Keep the model, clock and measurement settings with the result.Rank the expensive operatorsInspect cycles and each layer’s share of the instrumented total. Start with the layers that account for the most work.Test a targeted improvementTry another engine or memory placement, then compare the saved runs to see whether whole-model latency improved.Understand timing and measurement boundaries →
Investigate costly layersLook beyond cycle counts. On supported targets, inspect memory accesses, processor stalls and MVE activity alongside each operator.Use the counters to investigate whether memory placement or kernel execution deserves a closer look. Available counters depend on the target.Explore counters →
Include power and energyCapture the monitored supply with a supported Joulescope or INA228. Read power during the measurement window and energy per inference.Save the capture with the run, inspect its validity and compare energy alongside latency. Requires a configured power monitor.Set up power capture →

Compare your options
Put your next idea to the test.
Compare timing, memory and energy alongside the settings that produced them. hpx flags incompatible measurements and leaves out per-layer differences when operation sequences do not match.

Evaluate engines and compilersKeep the model and target fixed, then measure the effect of an engine or compiler change.Compare engines →
Explore memory placementTry supported placements for weights and working memory, then measure the effect on your target.Plan memory →
Inspect the model graphView captured layer measurements on the model graph. Use host-side model analysis to inspect operations and tensor sizes before connecting a board.Explore the graph →

Build a repeatable workflow
Keep runs reproducible and results reusable.
Each result bundle keeps measurements, configuration and source information together. Revisit a run, share it with a colleague or analyze its CSV and JSON reports.
Browse result files →

Repeat runs and check regressionsSave settings in YAML and define regression limits for automated comparisons.Compare and check runs →
Work in scripts and notebooksUse the Python Session API to run profiles and analyze results with the same configuration model as the CLI.Explore the Python API →

Get started
Choose a setup for your first run.
13 boards · 3 toolchains
Profile with LiteRT, heliaRT or heliaAOT. Apollo510 EVB and Apollo3P EVB are the 2 stable boards in the registry. Other targets are preview or experimental. Check the tested combinations for engine support and available measurements.

Install hpx →Install the CLI and required host tools.
Choose your target →Check tested board and engine combinations.
Set up a compiler →Configure the toolchain for your run.
Explore examples →Follow a complete profiling example.

Source on GitHub → · Release notes →
