Improve error message when running GPU models on a VM without GPU #184
Unanswered
elsewhat
asked this question in
Feature requests
Replies: 1 comment
-
|
There's no good way to detect a lack of GPU on a VM from managed code currently. We have some new features coming soon that do that at the native level so we can avoid this issue and not even attempt to load a model that is not supported. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Have tested Foundry CLI based the installer FoundryLocal-windows-installer-x64-v0.2.9224.msix in a Virtual Machine.
Using Hyper-V with a Windows 11 Enterprise (version 10.0.26100 Build 26100) image
As far as I know, this setup with default settingsdoes not share GPU resource from the host with the virtual machine.
The CPU model
Phi-4-mini-cpu-int4-rtn-block-32-acc-level-4-onnxwork well with this setupThe GPU model
Phi-4-mini-gpu-int4-rtn-block-32fails with message Status: 500 (Internal Server Error).Think it's ok it fails, but the error message should be more informative.
Client log :
Details
Service log:
Details
Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[0] 03:21:55.38 0 OpenAIService for type:OpenAIServiceProviderOnnx Information: Microsoft.Neutron.Rpc.Service.JsonRpcService[0] 03:21:55.38 0 json-rpc-service running Information: Microsoft.Neutron.Rpc.Service.JsonRpcService[2305] 03:21:55.38 accept_pipe_connections Accepting pipe connections pipeName:inference_agent Information: Microsoft.Hosting.Lifetime[14] 03:21:55.39 ListeningOnAddress Now listening on: http://localhost:5272 Information: Microsoft.Hosting.Lifetime[0] 03:21:55.39 0 Application started. Press Ctrl+C to shut down. Information: Microsoft.Hosting.Lifetime[0] 03:21:55.39 0 Hosting environment: Production Information: Microsoft.Hosting.Lifetime[0] 03:21:55.39 0 Content root path: C:\Program Files\WindowsApps\Microsoft.FoundryLocal_0.2.9224.7622_x64__8wekyb3d8bbwe\ Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[1400] 03:21:57.45 load_model_started Loading model:Phi-4-mini-gpu-int4-rtn-block-32 Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[1401] 03:22:01.69 load_model_finished Finish loading model:Phi-4-mini-gpu-int4-rtn-block-32 elapsed time:00:00:04.2437755 Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[0] 03:22:03.52 0 HandleChatCompletionAsStreamRequest -> model:Phi-4-mini-gpu-int4-rtn-block-32 MaxCompletionTokens:2048 maxTokens:(null) temperature:(null) topP:(null) Error: Microsoft.AspNetCore.Server.Kestrel[13] 03:22:03.75 ApplicationError Connection id "0HNC1GU1FFBT0", Request id "0HNC1GU1FFBT0:00000001": An unhandled exception was thrown by the application. message:D:\a\_work\1\s\onnxruntime\core\providers\webgpu\buffer_manager.cc:321 onnxruntime::webgpu::BufferManager::Download::::operator () status == wgpu::MapAsyncStatus::Success was false. Failed to download data from buffer: [Device] is lost. stack: at Microsoft.ML.OnnxRuntimeGenAI.Result.VerifySuccess(IntPtr) + 0x54 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.OnnxChatGenerator..ctor(OnnxLoadedModel, GeneratorParams, Sequences) + 0x63 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__21.MoveNext() + 0xed7 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__14.MoveNext() + 0xb8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderBase`1.d__34.MoveNext() + 0x352 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.ThrowForFailedGetResult() + 0x13 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.GetResult(Int16) + 0x2c at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x2cb --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x3ec --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Http.Generated.F16C589DE9EC82483AA705851D2FE201CB4CB4AAF6561E8DE71B6A1891AD8D67F__GeneratedRouteBuilderExtensionsCore.<>c__DisplayClass11_0.<g__RequestHandler|4>d.MoveNext() + 0x4f8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.d__238`1.MoveNext() + 0x404 Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[0] 03:22:03.76 0 HandleChatCompletionAsStreamRequest -> model:Phi-4-mini-gpu-int4-rtn-block-32 MaxCompletionTokens:2048 maxTokens:(null) temperature:(null) topP:(null) Error: Microsoft.AspNetCore.Server.Kestrel[13] 03:22:03.77 ApplicationError Connection id "0HNC1GU1FFBT0", Request id "0HNC1GU1FFBT0:00000002": An unhandled exception was thrown by the application. message:D:\a\_work\1\s\onnxruntime\core\providers\webgpu\buffer_manager.cc:321 onnxruntime::webgpu::BufferManager::Download::::operator () status == wgpu::MapAsyncStatus::Success was false. Failed to download data from buffer: [Device] is lost. stack: at Microsoft.ML.OnnxRuntimeGenAI.Result.VerifySuccess(IntPtr) + 0x54 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.OnnxChatGenerator..ctor(OnnxLoadedModel, GeneratorParams, Sequences) + 0x63 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__21.MoveNext() + 0xed7 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__14.MoveNext() + 0xb8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderBase`1.d__34.MoveNext() + 0x352 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.ThrowForFailedGetResult() + 0x13 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.GetResult(Int16) + 0x2c at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x2cb --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x3ec --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Http.Generated.F16C589DE9EC82483AA705851D2FE201CB4CB4AAF6561E8DE71B6A1891AD8D67F__GeneratedRouteBuilderExtensionsCore.<>c__DisplayClass11_0.<g__RequestHandler|4>d.MoveNext() + 0x4f8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.d__238`1.MoveNext() + 0x404 Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[0] 03:22:03.77 0 HandleChatCompletionAsStreamRequest -> model:Phi-4-mini-gpu-int4-rtn-block-32 MaxCompletionTokens:2048 maxTokens:(null) temperature:(null) topP:(null) Error: Microsoft.AspNetCore.Server.Kestrel[13] 03:22:03.78 ApplicationError Connection id "0HNC1GU1FFBT0", Request id "0HNC1GU1FFBT0:00000003": An unhandled exception was thrown by the application. message:D:\a\_work\1\s\onnxruntime\core\providers\webgpu\buffer_manager.cc:321 onnxruntime::webgpu::BufferManager::Download::::operator () status == wgpu::MapAsyncStatus::Success was false. Failed to download data from buffer: [Device] is lost. stack: at Microsoft.ML.OnnxRuntimeGenAI.Result.VerifySuccess(IntPtr) + 0x54 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.OnnxChatGenerator..ctor(OnnxLoadedModel, GeneratorParams, Sequences) + 0x63 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__21.MoveNext() + 0xed7 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__14.MoveNext() + 0xb8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderBase`1.d__34.MoveNext() + 0x352 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.ThrowForFailedGetResult() + 0x13 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.GetResult(Int16) + 0x2c at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x2cb --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x3ec --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Http.Generated.F16C589DE9EC82483AA705851D2FE201CB4CB4AAF6561E8DE71B6A1891AD8D67F__GeneratedRouteBuilderExtensionsCore.<>c__DisplayClass11_0.<g__RequestHandler|4>d.MoveNext() + 0x4f8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.d__238`1.MoveNext() + 0x404 Information: Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx[0] 03:22:03.78 0 HandleChatCompletionAsStreamRequest -> model:Phi-4-mini-gpu-int4-rtn-block-32 MaxCompletionTokens:2048 maxTokens:(null) temperature:(null) topP:(null) Error: Microsoft.AspNetCore.Server.Kestrel[13] 03:22:03.79 ApplicationError Connection id "0HNC1GU1FFBT0", Request id "0HNC1GU1FFBT0:00000004": An unhandled exception was thrown by the application. message:D:\a\_work\1\s\onnxruntime\core\providers\webgpu\buffer_manager.cc:321 onnxruntime::webgpu::BufferManager::Download::::operator () status == wgpu::MapAsyncStatus::Success was false. Failed to download data from buffer: [Device] is lost. stack: at Microsoft.ML.OnnxRuntimeGenAI.Result.VerifySuccess(IntPtr) + 0x54 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.OnnxChatGenerator..ctor(OnnxLoadedModel, GeneratorParams, Sequences) + 0x63 at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__21.MoveNext() + 0xed7 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderOnnx.d__14.MoveNext() + 0xb8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.Neutron.OpenAI.Provider.OpenAIServiceProviderBase`1.d__34.MoveNext() + 0x352 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.ThrowForFailedGetResult() + 0x13 at System.Threading.Tasks.Sources.ManualResetValueTaskSourceCore`1.GetResult(Int16) + 0x2c at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x2cb --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at Microsoft.Neutron.OpenAI.OpenAIServiceWebApiExtensions.<>c__DisplayClass2_0.<b__0>d.MoveNext() + 0x3ec --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Http.Generated.F16C589DE9EC82483AA705851D2FE201CB4CB4AAF6561E8DE71B6A1891AD8D67F__GeneratedRouteBuilderExtensionsCore.<>c__DisplayClass11_0.<g__RequestHandler|4>d.MoveNext() + 0x4f8 --- End of stack trace from previous location --- at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() + 0x20 at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task) + 0xb2 at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task, ConfigureAwaitOptions) + 0x4b at Microsoft.AspNetCore.Server.Kestrel.Core.Internal.Http.HttpProtocol.d__238`1.MoveNext() + 0x404 ```Beta Was this translation helpful? Give feedback.
All reactions