You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: content/learning-paths/mobile-graphics-and-gaming/ai-camera-pipelines/1-prerequisites.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -8,7 +8,7 @@ layout: learningpathall
8
8
9
9
## Host machine requirements
10
10
11
-
This Learning Path demonstrates how to improve the performance of camera pipelines using KleidiAI and KleidiCV on Arm. You’ll need an Arm64 machine, preferably running an Ubuntu-based distribution. The instructions have been tested on Ubuntu 24.04.
11
+
This Learning Path demonstrates how to improve the performance of camera pipelines using SME2 on Arm. You’ll need an Arm64 machine with SME2 support, preferably running an Ubuntu-based distribution. The instructions have been tested on Ubuntu 24.04.
Copy file name to clipboardExpand all lines: content/learning-paths/mobile-graphics-and-gaming/ai-camera-pipelines/2-overview.md
+21-2Lines changed: 21 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,13 +6,32 @@ weight: 4
6
6
layout: learningpathall
7
7
---
8
8
9
-
## KleidiAI
9
+
## About SME/SME2
10
+
11
+
Arm Scalable Matrix Extension (SME) is an architecture extension that provides enhanced support for matrix operations. SME builds on the Scalable Vector Extensions (SVE and SVE2), adding new capabilities to efficiently process matrices.
12
+
13
+
Key features include:
14
+
- Outer product between two vectors
15
+
- Matrix tile storage
16
+
- Load, store, insert, and extract of tile vectors, including on-the-fly transposition
17
+
- Streaming SVE mode
18
+
19
+
SME defines the following new features:
20
+
- A new architectural state capable of holding two-dimensional matrix tiles.
21
+
- Streaming SVE mode which supports execution of SVE2 instructions with a vector length that matches the tile width.
22
+
- New instructions that accumulate the outer product of two vectors into a tile.
23
+
- New load, store, and move instructions that transfer a vector to or from a tile row or column.
24
+
- Like SVE2, SME is a scalable vector length extension which enables Vector Length Agnostic (VLA), per-lane predication, predicate-driven loop control and management features.
25
+
26
+
This makes SME and SME2 particularly fit for image processing. In this learning path, you will use SME2 instructions thru the KleidiAI and KleidiCV libraries:
27
+
28
+
### KleidiAI
10
29
11
30
[KleidiAI](https://gitlab.arm.com/kleidi/kleidiai) is an open-source library of optimized, performance-critical routines (micro-kernels) for AI workloads on Arm CPUs. These routines are tuned for specific Arm microarchitectures to maximize performance and are designed for straightforward integration into C/C++ ML and AI frameworks.
12
31
13
32
Several popular AI frameworks already take advantage of KleidiAI to improve performance on Arm platforms.
14
33
15
-
## KleidiCV
34
+
###KleidiCV
16
35
17
36
[KleidiCV](https://gitlab.arm.com/kleidi/kleidicv) is an open-source library that provides high-performance image-processing functions for AArch64. It is lightweight and simple to integrate, and computer-vision frameworks such as OpenCV can leverage KleidiCV to accelerate image processing on Arm devices.
|`ENABLE_SME2=$ENABLE_SME2`| SME2 (Scalable Matrix Extension 2) is disabled in this build with `ENABLE_SME2=0`. |
81
-
|`ARMNN_TFLITE_PARSER=0`| Configures the `ai-camera-pipelines` repository to use LiteRT with XNNPack instead of ArmNN. |
82
-
|`ENABLE_KLEIDICV:BOOL=ON`| Enables KleidiCV for optimized image processing. |
83
-
|`XNNPACK_ENABLE_KLEIDIAI:BOOL=ON`| Enables KleidiAI acceleration for LiteRT workloads via XNNPack. |
75
+
{{% notice Note %}}
76
+
In the above `cmake` command line, you'll note that the pipelines are build with SME2 (`-DENABLE_SME2=$ENABLE_SME2`), but that this could be disabled as well. We will use this feature later when benchmarking the performance improvements brought by SME2.
Run the background Blur pipeline, using `resources/test_input.png` as the input image and write the transformed image to `test_output.png`:
24
+
Run the background Blur pipeline, using `resources/test_input.png` as the input image and write the transformed image to `test_output_cinematic_mode.png`:

33
33
34
34
## Low-Light Enhancement
35
35
36
-
Run the Low-Light Enhancement pipeline, using `resources/test_input.png` as the input image and write the transformed image to `test_output2_lime.png`:
36
+
Run the Low-Light Enhancement pipeline, using `resources/test_input.png` as the input image and write the transformed image to `test_output_lime.png`:
To measure the performances without the benefits of SME2, set `ENABLE_SME2=0` and recompile the pipelines as shown in the [build](/learning-paths/mobile-graphics-and-gaming/ai-camera-pipelines/3-build/) page.
84
77
85
-
```output
86
-
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
Copy file name to clipboardExpand all lines: content/learning-paths/mobile-graphics-and-gaming/ai-camera-pipelines/_index.md
+18-2Lines changed: 18 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,13 +1,13 @@
1
1
---
2
-
title: Accelerate Denoising, Background Blur and Low-Light Camera Effects with KleidiAI and KleidiCV
2
+
title: Accelerate Denoising, Background Blur and Low-Light Camera Effects with SME2
3
3
4
4
minutes_to_complete: 30
5
5
6
6
who_is_this_for: This introductory topic is for mobile and computer-vision developers, camera pipeline engineers, and performance-minded practitioners who want to optimize real-time camera effects on Arm using KleidiAI and KleidiCV.
7
7
8
8
learning_objectives:
9
9
- Build and run AI-powered camera pipeline applications
10
-
- Use KleidiCV and KleidiAI to improve the performance of real-time camera pipelines
10
+
- Use SME2 to improve the performance of real-time camera pipelines
11
11
12
12
prerequisites:
13
13
- A computer running Arm Linux or macOS with Docker installed
0 commit comments