Code Examples
Complete, runnable examples from the Voyager SDK. Each example is a standalone script you can use as a starting point for your own applications.
Python Examples
| Example | Description |
|---|---|
| Basic Application | Minimal detection loop with display — the "hello world" of Voyager |
| Extended Application | Hardware caps, frame rate control, temperature monitoring |
| Tensor Access | Direct tensor output for custom postprocessing |
| Classification | Image classification with generator-based input |
| Multiple Pipelines | Running several models concurrently |
| Cross-Line Counter | Vehicle counting using tracker metadata |
| Remote Monitor | TCP broadcast server for remote cross-line monitoring |
C++ Examples (AxInferenceNet)
| Example | Description |
|---|---|
| Basic Inference | C++ detection loop using AxInferenceNet API |
| Cascaded Pipeline | Multi-model C++ pipeline (detect → classify) |
| Tensor Access | Raw tensor output in C++ for custom processing |
Running the examples
All examples are included in the SDK under examples/. To run a Python example:
cd $AXELERA_FRAMEWORK
python examples/application.py
To build and run the C++ examples:
cd $AXELERA_FRAMEWORK
make examples
./build/examples/axinferencenet/axinferencenet_example
See also
- First Inference — guided walkthrough of your first model run
- Run Inference in Python — deeper dive into the Python API
- Video Sources — configuring cameras, RTSP streams, and files