cancel
Showing results for 
Search instead for 
Did you mean: 

Introduction to edge AI on STM32N6

Artur IWANICKI
ST Employee

This set of videos offers comprehensive know-how regarding the usage of STM32N6 within AI embedded applications. 

As a result of following them, you’ll be able to develop a computer vision STM32N6 use case from scratch and deploy on a target board. This is assuming that another supported use case development pipeline is similar using STM32 model zoo services.

What you'll learn 

  • What the STM32N6 Neural Processing Unit (NPU) and NPU compiler is
  • STM32N6-AI ecosystem: ST EdgeAI, X-CUBE-AI, model zoo
  • How to compile a model for the STM32N6 NPU
  • How to validate and profile model execution on the STM32N6 NPU (object detection use case)

Prerequisites

  1. STM32N6 development board STM32N6570-DK
  2. A computer running the 64-bit version of Windows® 10 or 11, with administrator rights for software and driver installation, USB Type-C® port,
  3. USB Type-C® – USB Type-C® cable (low resistance due to STM32N6570-DK board current consumption).
  4. The following software installed:

More details are found in the preparation video:

"STM32N6 STEdgeAI-Core command-line development pipeline - Preparation"

Ready to get started?

The videos are available at our YouTube playlist at the URL:

MOOC - STM32N6 STEdgeAI-Core command-line development pipeline (two videos, 1h)

Join the discussion

Share your thoughts, ask questions, and engage with fellow developers. Our experts are active in this post and they are excited to hear your feedback.

Additional resources

  • Command-line development pipeline step by step (1-8)
cd C:\ST\stm32ai-modelzoo-services-main\application_code\object_detection\STM32N6\Model
$Env:PATH += ";C:\ST\STEdgeAI\2.2\Utilities\windows\"
$Env:PYTHONPATH += ";C:\ST\STEdgeAI\2.2\scripts\ai_runner\"
$Env:PATH += ";C:\ST\STM32CubeIDE_1.18.0\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.gnu-tools-for-stm32.13.3.rel1.win32_1.0.0.202411081344\tools\bin\"

$Env:PATH += ";C:\ST\STM32CubeIDE_1.18.0\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.make.win32_2.2.0.202409170845\tools\bin\"

stedgeai generate -m quantized_tiny_yolo_v2_224_.tflite --target stm32n6 --st-neural-art default@user_neuralart_STM32N6570-DK.json

python "C:\ST\STEdgeAI\2.2\scripts\N6_scripts\n6_loader.py" --project-path "C:\ST\STEdgeAI\2.2\Projects\STM32N6570-DK\Applications\NPU_Validation\" --network-file st_ai_output\network.c

stedgeai validate --model quantized_tiny_yolo_v2_224_.tflite --target stm32 --mode target -d serial:921600

python "C:\ST\STEdgeAI\2.2\scripts\ai_runner\examples\npu_profiler.py" --cfile st_ai_ws\neural_art__network

# Optional -> create network data hex file

arm-none-eabi-objcopy -I binary st_ai_output/network_atonbuf.xSPI2.raw --change-addresses 0x70380000 -O ihex  st_ai_output/network_data.hex