DirectML Tutorials

Welcome to the DirectML tutorials! This section provides step-by-step guides to help you leverage the power of DirectML for hardware-accelerated machine learning on Windows.

Getting Started

Begin your journey with DirectML by setting up your development environment and understanding the core concepts.

Prerequisites:
  • A Windows 10/11 PC with a DirectX 12 compatible GPU.
  • Visual Studio 2022 or later.
  • Windows SDK version 10.0.19041.0 or later.

In this tutorial, you will learn:

Learn more in "Your First DirectML Application"

Basic Operations

Explore fundamental DirectML operations and how to implement them in your applications.

This section covers:

Example code snippet for element-wise addition:

// Assume tensorA and tensorB are already created and populated IDMLOperatorX32* addOperator; DML_OPERATOR_DESC addDesc = { DML_OPERATOR_ELEMENT_WISE_ADD, /* ... */ }; dmlDevice->CreateOperator(&addDesc, &addOperator); // ... execution code ...

Explore "Implementing Basic ML Kernels"

Convolutional Networks

Dive into implementing convolutional layers, a cornerstone of many deep learning models.

Topics include:

Mastering "Convolutional Layers with DirectML"

Tensor Operations

Deepen your understanding of tensor manipulation and data flow within DirectML.

Learn about:

Advanced "Tensor Management in DirectML"

Performance Optimization

Unlock the full potential of DirectML by optimizing your ML workloads for maximum performance.

Discover techniques for:

Tip: Always profile your application to identify areas for optimization.

"Optimizing DirectML Workloads"

Continue exploring the documentation for more in-depth guides and API references.