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

_com_error at memory location 0x0000006A74D6D680 when calling generator.ComputeLogits() #886

Open
tranlm opened this issue Sep 11, 2024 · 1 comment

Comments

@tranlm
Copy link

tranlm commented Sep 11, 2024

Describe the bug
I've tried to copy the HelloPhi example for loading and calling phi-3.5 in DirectML for my application. When I get to the generator.ComputeLogits() part, I get a ton (e.g. hundreds) of the following memory errors:

Exception thrown at 0x00007FFFF9ED6D9A in <MyApplicationsName>.exe: Microsoft C++ exception: _com_error at memory location 0x0000006A74D6D680.

After a few minutes, the inference engine starts generating the text.

To Reproduce
Steps to reproduce the behavior:

  1. Copy the DirectML version of the HelloPhi example as a new Blank App, Packaged with Windows Application Packing Project (WinUI 3 in Desktop) app with framework net8.0-windows10.0.19041.0 (n.b. I'm using WindowsSdkPackageVersion 10.0.19041.38).
  2. Download and convert phi-3.5 to DirectML (or rely on the onnx dml verison at microsoft/Phi-3-mini-128k-instruct-onnx on huggingface - I've tried both models).
  3. Run the app with the downloaded model (making sure to break when c++ exceptions are thrown.
  4. See error

Expected behavior
No memory errors to show and to start generating text immediately (rather than after 3-5 minutes of the memory exceptions).

Screenshots
image
image
image

Desktop (please complete the following information):

  • OS: Windows 11
@tranlm
Copy link
Author

tranlm commented Sep 11, 2024

Quick follow-up. I tried updating to the most recent Windows SDK (10.0.26100.0) and ran the app again. Now I'm getting a slightly different error (coming out of D3D12Core rather than KernelBase).

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant