feat: add directml support (#1153)

This commit is contained in:
thewh1teagle
2024-07-22 18:50:48 +03:00
committed by GitHub
parent ea1d81bdfe
commit d32a46169f
6 changed files with 218 additions and 7 deletions

View File

@@ -95,7 +95,10 @@ function(download_onnxruntime)
include(onnxruntime-win-arm64)
else()
# for 64-bit windows (x64)
if(BUILD_SHARED_LIBS)
if(SHERPA_ONNX_ENABLE_DIRECTML)
message(STATUS "Use DirectML")
include(onnxruntime-win-x64-directml)
elseif(BUILD_SHARED_LIBS)
message(STATUS "Use dynamic onnxruntime libraries")
if(SHERPA_ONNX_ENABLE_GPU)
include(onnxruntime-win-x64-gpu)