Skip to content

Commit 60e2647

Browse files
committed
doc: changelog v220 and restructure
Added changelog and known issues placeholder Applied changes based on the customer's feedback. Quick start and setup sections have been merged Signed-off-by: Anna Wojdylo <anna.wojdylo@nordicsemi.no>
1 parent 3ae339d commit 60e2647

13 files changed

Lines changed: 347 additions & 212 deletions

doc/index.rst

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,6 @@ See the following documentation:
4444

4545
overview.rst
4646
quick_start.rst
47-
setting_up_environment.rst
4847
applications.rst
4948
samples.rst
5049
integrations.rst

doc/known_issues.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ A known issue can list one or both of the following entries:
2121
Sometimes, they are discovered later and added over time.
2222

2323

24+
List of known issues for v2.2.0 release
25+
***************************************
26+
27+
TBA
28+
2429
List of known issues for v2.1.0 release
2530
***************************************
2631

doc/quick_start.rst

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.. _quick_start:
2+
.. _setting_up_environment:
23

34
Quick start guide
45
#################
@@ -7,15 +8,22 @@ Quick start guide
78
:local:
89
:depth: 2
910

10-
11-
This section includes quick start guides for running machine learning workloads on Nordic Semiconductor devices using nRF Edge AI.
11+
This section includes quick start guides for setting up your environment and running machine learning workloads on Nordic Semiconductor devices using nRF Edge AI.
1212
These pages cover common development paths, from simplified end‑to‑end solutions to lower‑level integrations with direct hardware control.
1313

1414
Select the guide that best matches your required level of control, tooling preferences, and target hardware.
1515
Each guide walks through the required setup steps and shows how to deploy and run an edge AI application.
1616

1717
If you are unsure which approach fits your use case, see the :ref:`solution_comparison` page for a comparison of features, performance characteristics, and supported workflows.
1818

19+
Before you follow any of the guides in this section, complete :ref:`setup_sdk` to install |NCS| and the development toolchain.
20+
21+
.. toctree::
22+
:maxdepth: 1
23+
:hidden:
24+
25+
quick_start/sdk_setup
26+
1927
Basic setup variants
2028
********************
2129

doc/quick_start/axon_driver.rst

Lines changed: 102 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.. _quick_start_axon_driver:
2+
.. _setup_axon:
23

34
Axon driver
45
###########
@@ -7,29 +8,118 @@ Axon driver
78
:local:
89
:depth: 2
910

10-
The following guide explains how to use the Axon NPU driver API to run TensorFlow Lite models directly on the Axon NPU.
11-
It is ideal if you require low‑level control over inference execution, memory usage, and system integration.
11+
The following guide outlines the requirements that you need to fulfill before you start working with the Axon NPU using Axon API directly, without the abstraction layer of |EAILib| API.
12+
It also explains how to use the Axon NPU driver API to run TensorFlow Lite models directly on the Axon NPU.
13+
This solution is ideal if you require low‑level control over inference execution, memory usage, and system integration.
1214

1315
To follow this guide, you should be familiar with embedded systems development and C‑based APIs.
1416
Compared to higher‑level frameworks such as |EAILib|, using the driver API requires more manual setup but enables finer control over performance and resource utilization.
1517

1618
After completing this guide, you will have compiled a TensorFlow Lite model for the Axon NPU and deployed a custom application that performs inference using the Axon driver API.
1719

18-
.. _quick_start_axon_driver_model_compilation:
20+
.. _axon_requirements_hardware:
1921

20-
Model compilation
21-
*****************
22+
Hardware requirements
23+
*********************
2224

23-
Before you can deploy to the Axon NPU, you need a TensorFlow Lite model compiled specifically for Axon hardware.
24-
The :ref:`axon_npu_tflite_compiler` transforms your TFLite model into an optimized format that leverages the NPU's specialized hardware.
25+
Axon NPU library is included as part of the :ref:`nrf_edgeai_lib` and provided as compiled binaries for Cortex-M33F architectures.
26+
Axon NPU is currently available on the `nRF54LM20B`_ device.
2527

26-
.. rst-class:: numbered-step
28+
.. _axon_requirements_software:
2729

28-
Set up the compiler
29-
===================
30+
Software requirements
31+
*********************
32+
33+
To start working with the Axon NPU, complete the setup based on your use case:
34+
35+
* If you want to deploy models on the device, you just need to complete :ref:`setup_sdk` to install |NCS|, toolchain, and |EAILib|.
36+
* If you want to prepare models for deployment, you only need to set up a Python environment to run the :ref:`axon_npu_tflite_compiler`.
37+
Follow instructions in :ref:`axon_setup_compiler` to set up the environment.
38+
39+
.. _axon_setup_compiler:
40+
41+
Setting up Axon TFlite Compiler
42+
===============================
43+
44+
Before you can run the :ref:`axon_npu_tflite_compiler`, you need to set up a Python environment with the required dependencies.
45+
The executor of the compiler is compatible with Python ``3.11``.
46+
47+
You can set up the Python environment using one of the methods below.
48+
49+
.. tabs::
50+
51+
.. group-tab:: Python virtual environment
52+
53+
Using a virtual environment is strongly recommended to isolate dependencies.
54+
You can use any virtual environment tool you prefer.
55+
This section shows one example using Miniforge (Conda):
56+
57+
1. Install `Miniforge`_
58+
59+
#. Ensure the Conda :file:`scripts` directory is added to your system ``PATH``, for example, :file:`C:/Users/<user>/AppData/Local/miniforge3/Scripts`.
60+
61+
#. Create a new environment with the supported Python version:
62+
63+
.. code-block:: console
64+
65+
conda create -n <env_name> python=3.11
66+
67+
#. Activate the environment.
68+
All installation and execution commands must be run from the activated environment:
69+
70+
.. code-block:: console
71+
72+
conda activate <env_name>
73+
74+
#. Install the required Python packages using the :file:`requirements.txt` file:
75+
76+
.. code-block:: console
77+
78+
cd tools/axon/compiler/scripts
79+
pip install -r requirements.txt
80+
81+
.. note::
82+
83+
On macOS, you may encounter the ``ERROR: No matching distribution found for tensorflow==2.15.1`` error.
84+
To fix it, install TensorFlow using Conda instead:
85+
86+
.. code-block:: console
87+
88+
conda install -c conda-forge tensorflow=2.15.1
89+
90+
Once you complete the setup, you can try running the compiler by following instructions in :ref:`axon_npu_tflite_compiler`.
91+
92+
.. group-tab:: Docker
93+
94+
Docker provides a fully isolated way to run the compiler without installing dependencies locally.
95+
96+
Before using Docker with the compiler, you must install it on the system.
97+
You should also verify that Docker is working correctly by building and running a simple Docker container.
98+
99+
The following links provide introductory material and best-practice guidance for Docker:
100+
101+
* `A beginner's guide to Docker`_
102+
* `Creating the Dockerfile`_
103+
* `Intro Guide to Dockerfile Best Practices`_
104+
105+
Once you have installed and verified Docker, you can follow :ref:`axon_npu_tflite_compiler_docker` to build and run a Docker container for the Python compiler executor.
106+
107+
.. group-tab:: Podman
108+
109+
Podman is a daemonless alternative to Docker.
110+
Follow the steps below to set up Podman and run the compiler in a Podman container:
111+
112+
1. Install Podman by following the `Podman installation guide`_.
113+
#. Set up and run a `simple container with Podman <Setting up Podman container_>`_
114+
115+
Once you have installed and verified Podman, you can follow :ref:`axon_npu_tflite_compiler_podman` to build and run a Podman container for the Python compiler executor.
116+
117+
.. _quick_start_axon_driver_model_compilation:
118+
119+
Model compilation
120+
*****************
30121

31-
First, set up the Axon compiler's environment on your development system.
32-
Follow the :ref:`Executor and compiler setup <axon_setup_compiler>` instructions to install the necessary tools.
122+
With the compiler environment ready, you can transform your TensorFlow Lite model into Axon-optimized code and verify that inference produces correct results.
33123

34124
.. rst-class:: numbered-step
35125

doc/quick_start/edge_impulse.rst

Lines changed: 167 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
.. _quick_start_edge_impulse:
2+
.. _setup_edge_impulse:
23

34
Edge Impulse
45
############
@@ -19,6 +20,172 @@ The guide covers the steps required to collect data, train a model using |EI| to
1920

2021
After completing this guide, you will have a machine learning application running on a Nordic Semiconductor device using |EI|.
2122

23+
Get the nRF Edge AI Add-on code
24+
*******************************
25+
26+
The |EAI| is distributed as a Git repository, and is managed through its own west manifest.
27+
The compatible |NCS| version is specified in the :file:`west.yml` file.
28+
To get the |EAI| code, you can either:
29+
30+
* Use the `nRF Connect for Visual Studio Code`_ extension, which provides a convenient way to clone the Add-on and compatible |NCS| version.
31+
* Clone the Add-on repository and initialize west with the local manifest.
32+
* Extend your west manifest with Add-on as a project.
33+
* Clone the Add-on repository and add the Add-on as a Zephyr module through CMake or environment variable.
34+
35+
.. tabs::
36+
37+
.. group-tab:: nRF Connect for Visual Studio Code
38+
39+
.. note::
40+
41+
Use this method when you wish to specifically evaluate Edge AI capabilities, but do not have the |NCS| setup yet.
42+
43+
Clone the |EAI| code, together with the compatible |NCS|:
44+
45+
1. Ensure you have installed `Visual Studio Code`_ and the `nRF Connect for Visual Studio Code`_ extension.
46+
#. Follow the `nRF Connect SDK installation guide`_ to install |NCS| prerequisites and toolchain |toolchain_ncs_id|.
47+
48+
.. note::
49+
50+
The compatible version of the |NCS| will be cloned with the |EAI| repository in the following steps.
51+
The version of |NCS| is fixed to the version of |EAI| and is hard-coded in the :file:`west.yml` file of the |EAI|.
52+
53+
#. Open the nRF Connect extension in Visual Studio Code by clicking its icon in the :guilabel:`Activity Bar`.
54+
#. In the extension's :guilabel:`Welcome View`, click on :guilabel:`Create a new application`.
55+
The list of actions appears in the Visual Studio Code's quick pick.
56+
#. Click :guilabel:`Browse nRF Connect SDK Add-on Index`.
57+
The list of available nRF Connect SDK Add-ons appears in the Visual Studio Code's quick pick.
58+
#. Select :guilabel:`Edge AI Add-on`.
59+
#. Select the Add-on version to install.
60+
Depending on the speed of your internet connection, the update might take some time.
61+
62+
.. group-tab:: Command line for local manifest
63+
64+
.. note::
65+
66+
Use this method when you wish to specifically evaluate Edge AI capabilities, but do not have the |NCS| setup yet.
67+
68+
1. Follow the `nRF Connect SDK installation guide`_ to install |NCS| prerequisites and toolchain |toolchain_ncs_id|.
69+
70+
.. note::
71+
72+
The compatible version of the |NCS| will be cloned with the |EAI| repository in the following steps.
73+
The version of |NCS| is fixed to the version of |EAI| and is hard-coded in the :file:`west.yml` file of the |EAI|.
74+
75+
#. Launch installed toolchain:
76+
77+
.. tabs::
78+
79+
.. group-tab:: Windows
80+
81+
.. code-block:: console
82+
83+
nrfutil sdk-manager toolchain launch --ncs-version |toolchain_ncs_id| --terminal
84+
85+
.. group-tab:: Linux
86+
87+
.. code-block:: console
88+
89+
nrfutil sdk-manager toolchain launch --ncs-version |toolchain_ncs_id| --shell
90+
91+
.. group-tab:: MacOS
92+
93+
.. code-block:: console
94+
95+
nrfutil sdk-manager toolchain launch --ncs-version |toolchain_ncs_id| --shell
96+
97+
#. Initialize the nRF Edge AI repository, using one of the following methods:
98+
99+
.. tabs::
100+
101+
.. tab:: Direct initialization (Recommended)
102+
103+
a. Initialize west with the remote manifest.
104+
105+
.. code-block:: console
106+
107+
west init --manifest-rev v|release_version| --manifest-url https://github.com/nrfconnect/sdk-edge-ai
108+
109+
.. tab:: Manual cloning and initialization
110+
111+
a. Clone the nRF Edge AI repository into the :file:`sdk-edge-ai` directory.
112+
113+
.. code-block:: console
114+
115+
git clone --branch v|release_version| https://github.com/nrfconnect/sdk-edge-ai.git sdk-edge-ai
116+
117+
#. Initialize west with local manifest.
118+
119+
.. code-block:: console
120+
121+
west init --local sdk-edge-ai
122+
123+
#. Update all repositories, by running the following command:
124+
125+
.. code-block:: console
126+
127+
west update
128+
129+
Depending on the speed of your Internet connection, the update might take some time.
130+
131+
.. group-tab:: Add-on as a manifest project
132+
133+
.. note::
134+
135+
Use this method when running a `Workspace application`_ or if you prefer to use a modification of the |NCS| manifest.
136+
137+
1. Add Add-on repository as a project in west manifest by including the following lines in your :file:`west.yml` under the ``projects`` key:
138+
139+
.. code-block:: yaml
140+
141+
- name: edge-ai
142+
url: https://github.com/nrfconnect/sdk-edge-ai
143+
revision: v|release_version|
144+
import: true
145+
146+
If you have already included the |NCS| in your west manifest, remove it or replace the above ``import`` key with the mapping:
147+
148+
.. code-block:: yaml
149+
150+
import:
151+
name-blocklist:
152+
- nrf
153+
154+
Your west manifest must specify compatible versions of |NCS| and Add-on.
155+
156+
#. Perform ``west update`` to pull the Add-on repository.
157+
158+
.. group-tab:: Add-on as an extra Zephyr module
159+
160+
.. note::
161+
162+
Use this method if you have a prior installation of the |NCS| and would like to evaluate or use the |EAI| with that installation.
163+
This method will allow you to keep the |NCS| manifest unmodified.
164+
165+
Before using this approach, ensure that a compatible version of the |NCS| is installed.
166+
To identify the compatible |NCS| version, check the :file:`west.yml` file of the |EAI|.
167+
Since west does not manage the Add-on in this setup, you are responsible for keeping the versions synchronized.
168+
169+
1. Clone the Add-on repository:
170+
171+
.. code-block:: console
172+
173+
git clone --branch v|release_version| https://github.com/nrfconnect/sdk-edge-ai
174+
175+
#. Set the CMake or environment variable ``EXTRA_ZEPHYR_MODULES`` to the Add-on code path.
176+
Use absolute path to ensure proper path resolution.
177+
Check the `Environment Variables`_ documentation for different ways of setting environment variables in Zephyr.
178+
179+
.. note::
180+
181+
If you wish to:
182+
183+
* Use |EI| in Zephyr library deployment.
184+
* Use |EI| samples from Add-on.
185+
186+
Repeat the steps above for `edge-impulse-sdk-zephyr`_.
187+
The ``EXTRA_ZEPHYR_MODULES`` variable should be set to ``<path to Add-on>;<path to Edge Impulse SDK>``.
188+
22189
Model training
23190
***************
24191

0 commit comments

Comments
 (0)