Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DirectML Exception 80070057 "The parameter is incorrect" #20575

Open
TBrenetNV opened this issue May 6, 2024 · 1 comment
Open

DirectML Exception 80070057 "The parameter is incorrect" #20575

TBrenetNV opened this issue May 6, 2024 · 1 comment
Labels
ep:DML issues related to the DirectML execution provider platform:windows issues related to the Windows platform

Comments

@TBrenetNV
Copy link

Describe the issue

I exported the following PyTorch model: https://pytorch.org/hub/pytorch_vision_googlenet using TorchDynamo (see result ONNX model attached in next section) and can run inference using ONNX Runtime 1.17.3 with the CPU and CUDA provider but it fails with the DirectML provider.
Full exception is the following:

C:\build\ort-1.17.3\onnxruntime\onnxruntime\core\providers\dml\DmlExecutionProvider\src\DmlGraphFusionHelper.cpp(451)\onnxruntime.dll!00007FFE11451461: (caller: 00007FFE114311D1) Exception(1) tid(ae54) 80070057 The parameter is incorrect. 

I enabled DirectML debug layers but it did not provide more insights:

C:\__w\1\s\SharedValidation\GraphDescValidator.h(34)\DirectML.dll!00007FFE0FB010A5: (caller: 00007FFE0FAD9CC5) Exception(1) tid(ae54) 80070057 The parameter is incorrect.
Exception thrown at 0x00007FFF5CE4AB89 in onnxruntime_perf_test.exe: Microsoft C++ exception: wil::ResultException at memory location 0x0000004F310FB920.
Exception thrown at 0x00007FFF5CE4AB89 in onnxruntime_perf_test.exe: Microsoft C++ exception: [rethrow] at memory location 0x0000000000000000.
C:\__w\1\s\Product\DmlDevice.cpp(782)\DirectML.dll!00007FFE0FD5069E: (caller: 00007FFE11450F65) ReturnHr(1) tid(ae54) 80070057 The parameter is incorrect.
    Msg:[C:\__w\1\s\SharedValidation\GraphDescValidator.h(34)\DirectML.dll!00007FFE0FB010A5: (caller: 00007FFE0FAD9CC5) Exception(1) tid(ae54) 80070057 The parameter is incorrect.

To reproduce

To reproduce:

  • Unzip the attached ONNX Model: gnet_dynamo.zip
  • Run the onnxruntime_perf_test binary (built from source from branch 1.17.3) with the following arguments: onnxruntime_perf_test.exe -e dml -m times -r 5 -p profile_gnet_dynamo_dml.json -I gnet_dynamo.onnx

Urgency

No response

Platform

Windows

OS Version

10

ONNX Runtime Installation

Built from Source

ONNX Runtime Version or Commit ID

1.17.3

ONNX Runtime API

C++

Architecture

X64

Execution Provider

Default CPU, CUDA, DirectML

Execution Provider Library Version

No response

@github-actions github-actions bot added ep:CUDA issues related to the CUDA execution provider ep:DML issues related to the DirectML execution provider platform:windows issues related to the Windows platform labels May 6, 2024
@whyb
Copy link

whyb commented May 9, 2024

I have the same problem on some old GPU devices(NVIDIA GeForce GTX 780).
But this problem is not encountered on some newer graphics cards than the NVIDIA GeForce GTX 980.

Error Code:

RUNTIME_EXCEPTION

Error Message:

Non-zero status code returned while running Mul node. Name:'/G/encoder_level1/encoder_level1.0/norm1/body/Mul' Status Message: 
D:\a\_work\1\s\onnxruntime\core\providers\dml\DmlExecutionProvider\src\MLOperatorAuthorImpl.cpp(2449)\onnxruntime.dll!00007FFA2C65ADD5: (caller: 00007FFA2C65A468) Exception(6) tid(4764) 80070057 The parameter is incorrect.

Problem GPU Device: NVIDIA GeForce GTX 780
Driver Version: 471.11 (2021.6.23)

Platform: Windows
OS Version: 10
ONNX Runtime Installation: Download from github release page
ONNX Runtime Version or Commit ID: 1.16.23.1119
ONNX Runtime API: C++
Architecture: X64
Execution Provider: Default CPU, DirectML
Execution Provider Library Version: DirectML.dll version: 1.13.1.0

@sophies927 sophies927 removed the ep:CUDA issues related to the CUDA execution provider label May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ep:DML issues related to the DirectML execution provider platform:windows issues related to the Windows platform
Projects
None yet
Development

No branches or pull requests

3 participants