Installation#
This page consolidates all requirements and installation steps for running Windows ML on Ryzen AI PCs.
Prerequisites#
Requirement |
Version or Notes |
|---|---|
Windows |
Windows 11 24H2 (build 26100) or greater |
Ryzen AI NPU |
Supported processor with NPU. See supported configurations in the release notes. |
Visual Studio (for C++) |
Visual Studio 2022, latest version. Ensure Desktop Development with C++ is installed. |
Visual Studio Code (optional) |
For model conversion using AI Toolkit extension |
Python (for Python examples) |
3.10 to 3.12 |
C++ (for C++ examples) |
C++20 or later |
For the complete list of supported Windows versions, refer to Windows App SDK support.
Installation#
Follow these steps in order:
Install NPU drivers: Follow the RAI installation instructions. Download and install the NPU driver (version 32.0.203.280 or newer) from the AMD Ryzen AI driver page.
Install Windows App SDK: Windows ML is included as part of the Windows App SDK. Install the version required by your branch/sample from Windows App SDK downloads.
Verify installation: For Python, ensure the
wasdk-microsoft-windows-ai-machinelearningpackage is installed (e.g., viapip install) and matches the Windows App SDK version used by your sample branch. Runconda list | findstr wasdkto verify.
Key Features of Windows ML#
Dynamically downloads latest EPs: Compatible execution providers are downloaded from the Microsoft Store on demand
Shared Windows-wide ONNX Runtime: Reduces application size; no need to bundle ORT
Smaller downloads and installs: EPs are shared across applications
Broad hardware support: Works across CPUs, GPUs, and NPUs from different vendors via ONNX Runtime
Windows ML setup verification#
Install the required Python packages in the conda environment winml_env
conda create -n winml_env python==3.11
conda activate winml_env
git clone https://github.com/amd/RyzenAI-SW.git
cd <RyzenAI-SW>\WinML\CNN\ResNet
pip install --pre -r .\requirements.txt
Check the installed wasdk Python version and install same version of Windows App SDK:
conda list | findstr wasdk
Download the Windows App SDK corresponding to the wasdk version (e.g., 2.0.0.dev4) or latest and install it to ensure the Windows ML execution providers work correctly.
curl -L -o windowsappruntimeinstall-x86.exe "https://aka.ms/windowsappsdk/2.0/2.0.0-experimental4/windowsappruntimeinstall-x86.exe"
windowsappruntimeinstall-x86.exe --quiet
After completing the installation, run the check_winml_setup.py script from the RyzenAI-SW repository to verify the Windows ML installation. The script is available at: amd/RyzenAI-SW
cd <RyzenAI-SW>\WinML
python check_winml_setup.py
The script will produce output similar to the following:
============================================================
WinML Setup Checker
============================================================
Python: 3.11.0 (<path_to_python_installation>\python.exe)
WASDK Python Packages:
----------------------------------------
[✓] wasdk-ML: 2.0.0.dev4
[✓] wasdk-Bootstrap: 2.0.0.dev4
Windows App SDK Runtime:
----------------------------------------
[✓] Windows App SDK: 2.0-experimental5 (internal: 0.770.2319.0)
Installed runtimes (newest first):
* 2.0-experimental5 (internal: 0.770.2319.0)
- 2.0-experimental4 (internal: 0.738.2207.0)
- 1.8 (internal: 8000.642.119.0)
- 1.8 (internal: 8000.675.1142.0)
- 1.8-experimental (internal: 8000.589.1529.0)
- 1.8-preview (internal: 8000.591.1127.0)
* Active runtime used by this checker
Expected SDK: 2.0.0-experimental4
============================================================
Status: All components installed. Please, ensure matching Windows App SDK version is Installed.
Windows App SDK version should match the wasdk Python package version. If there is a mismatch, install the correct Windows App SDK version. After installation, re-run the setup checker to verify that the correct version of Windows App SDK is installed and active.
Getting Started Examples#
The following examples provide step-by-step instructions to help you get started with Windows ML on AMD Ryzen AI PCs. These examples cover CNN, Transformer, and LLM model deployment using both C++ and Python APIs.
Getting Started Example for Windows ML using ResNet model:
Optional Model conversion to QDQ quantized ONNX model using VS Code AI Toolkit
Deployment using Windows ML APIs and ONNX Runtime using C++ and Python
Additional examples:
For more details about model deployment using Windows ML, see the Model Deployment using Windows ML documentation.