Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Differences between .dlls in NuGet and Python versions of DirectML provider#24867

Unanswered
Levyks asked this question inEP Q&A
Discussion options

I'm trying to write a C++ application that uses the DirectML Execution Provider, I was using theonnxruntime.dll andonnxruntime_providers_shared.dll from the NuGet C# packageMicrosoft.ML.OnnxRuntime.DirectML and everything worked fine for the first 2 models I tried to run, but later, when trying to run a YOLO one, it didn't ran on DML, only in CUDA or CPU.

After a lot of debugging, I tried running it on python and everything worked fine, out of curiosity, I tried copying the python dlls fromPython313\Lib\site-packages\onnxruntime\capi to my own C++ project, and voala, it worked!

I noticed that the Python version has 1 extra dll,DirectML.dll, that the C# one does not.

Also, Python'sonnxruntime.dll has 19-ish KB, while the one from C# has 16-ish KB

What's the reason for this difference? Shouldn't both packages just be thin wrappers around the same lib?

The error I was getting was

←[1;31m2025-05-26 17:36:02.1363987 [E:onnxruntime:, inference_session.cc:2281 onnxruntime::InferenceSession::Initialize::<lambda_5767435f92a738c7a221df2e7c461c0f>::operator ()] Exception during initialization: D:\a\_work\1\s\onnxruntime\core\providers\dml\DmlExecutionProvider\src\AbiCustomRegistry.cpp(519)\onnxruntime.dll!00007FFDB396E372: (caller: 00007FFDB38DDB99) Exception(3) tid(7150) 80070057 ParFailed to create segmenter: Exception during initialization: D:\a\_work\1\s\onnxruntime\core\providers\dml\DmlExecutionProvider\src\AbiCustomRegistry.cpp(519)\onnxruntime.dll!00007FFDB396E372: (caller: 00007FFDB38DDB99) Exception(3) tid(7150) 80070057 Incorrect parameter.
You must be logged in to vote

Replies: 0 comments

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Category
EP Q&A
Labels
None yet
1 participant
@Levyks

[8]ページ先頭

©2009-2025 Movatter.jp