[Feature Request] DirectML expose enumeration API #22108
Labels
api:CSharp
issues related to the C# API
ep:DML
issues related to the DirectML execution provider
feature request
request for unsupported feature or enhancement
Describe the feature request
When using DirectML, we have access to any DirectX 12 device and can run a model on that device provided it supports the required operators. However, there is no documentation for a way we can identify the available devices - namely, we can tell the DirectML EP to run on device ID 0, 1, ... but unless there's some mapping, how do we tell a priori which device we will use?
Describe scenario use case
This becomes especially important when I want to use DirectML for both GPU devices and NPU devices (when supported).
Suppose I am on a system with two GPUs (let's say Intel primary and NVIDIA gaming) and an NPU that is supported by DirectML. Technically, all three of these devices should be visible to DirectML. Suppose I'm writing an application that can hot-switch the model to another device based on the user choice (i.e. I should list all the directX devices) - I cannot do that right now and even if I took the time to write the C# wrapper for DXGI (or find one that is properly maintained as of 2024), I would still then need to connect those to the IDs in DirectML's options input.
The text was updated successfully, but these errors were encountered: