Tutorial Overview - Tutorial Overview - 2026.1 English - XD100

Vitis Tutorials: AI Engine Development (XD100)

Document_ID
XD100
Release_Date
2026-07-20
Version
2026.1 English

In this application tutorial, the LeNet algorithm performs image classification on an input image. It uses five AI Engine-ML tiles and PL resources, including block RAM. The following figure shows a top-level block diagram. An image loads from DDR memory through the network on chip (NoC) to block RAM and then to the AI Engine-ML. The PL input pre-processing unit receives the input image and sends the output to the first AI Engine-ML tile to perform matrix multiplication. The output from the first AI Engine-ML tile goes to a PL unit to perform the first level of max pool and data rearrangement (M1R1). The output feeds into the second AI Engine-ML tile. The second AI Engine ML tile sends the output to the PL to perform the second level max pooling and data rearrangement (M2R2). The output is then sent to a fully connected layer (FC1) implemented in two AI Engine-ML tiles and uses the rectified linear unit layer (ReLu) as an activation function. The outputs from the two AI Engine-ML tiles are then fed into a second fully connected layer implemented in the core04 AI Engine-ML tile. The output is sent to a data conversion unit in the PL and then to the DDR memory through the NoC. Between the AI Engine-ML and PL units is a datamover module (refer to the LeNet Controller in the following figure) that contains the following kernels:

  • mm2s: a memory-mapped to stream kernel to feed data from DDR memory through the NoC to the AI Engine-ML Array.

  • s2mm: a stream to memory-mapped kernel to feed data from the AI Engine-ML Array through NoC to DDR memory.

Image of LeNet Block Diagram

In the design, there are two major PL kernels. The input pre-processing units, M1R1 and M2R2 are in the lenet_kernel RTL kernel, which is packaged as a Xilinx object .xo (XO) file. The datamover kernel dma_hls provides the interface between the AI Engine-ML and DDR memory. The five AI Engine-ML kernels all implement matrix multiplication. The matrix dimensions depend on the image dimension, weight dimension, and a number of features.

Directory Structure

Directory Structure

lenet
|____design......................contains AI Engine-ML kernel, HLS kernel source files, and input data files.
|    |___aie_src.................contains all the aie source files.
|    |___pl_src..................contains all the data mover source files.
|    |___host_app_src............contains host application source files.
|    |___directives..............contains directives for various vitis compilation stages .
|    |___exec_scripts............contains run commands.
|    |___profiling_configs.......contains xrt.ini file.
|    |___system_configs..........contains all system configuration files.
|    |___vivado_metrics_scripts..contains scripts to get vivado metric reports.
|____images......................contains images that appear in the README.md.
|____Makefile....................with recipes for each step of the design compilation.
|____description.json............for XOAH.
|____sample_env_setup.sh.........required to setup Vitis environment variables and Libraries.