dotnet / dotnet/machinelearning-samples

System.AccessViolationException: 'Attempted to read or write protected memory

Open
#956 3 comments 4 reactions 0 assignees View on GitHub
Dominant language
PowerShell
Stars
4.7k
Forks
2.7k
Avg merge
2d 22h
Merged PRs (30d)
1

Description

System
Windows 10
VS 2022

Download samples and tried to run the program:
OnnxObjectDetection

Complies correctly and when I run the program an unhandled exception is thrown on line 25 var pipeline.

"An unhandled exception of type 'System.AccessViolationException' occurred in Microsoft.ML.OnnxRuntime.dll
Attempted to read or write protected memory. This is often an indication that other memory is corrupt.

The program '[19772] OnnxObjectDetectionApp.exe' has exited with code 3221225477 (0xc0000005) 'Access violation'."

Tried running VS 2022 as administrator and same issue. Tried changing to x64, x86, and Any CPU and same issue. Even rebooted same issue. Stuck.

Other samples such as DeepLearning_ObjectDetection_Onnx work fine, no issues.

Thank you.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.