machinelearning-samples icon indicating copy to clipboard operation
machinelearning-samples copied to clipboard

Unable to run/debug application OnnxObjectDetectionWeb

Open rfeiten opened this issue 3 years ago • 3 comments

Hi all - I have cloned the app, followed the instructions in the readme file, but I'm unable to run the Web App OnnxObjectDetectionWeb. I'm using Visual Studio 2019 Pro and I have enabled the "Preview Features" as recommended in the guide.

I'm receiving the following error

System.AccessViolationException: 'Attempted to read or write protected memory. This is often an indication that other memory is corrupt.'

Issue happens in line 25, file OnnxModelConfigurator.cs

            var pipeline = mlContext.Transforms.ResizeImages(resizing: ImageResizingEstimator.ResizingKind.Fill, outputColumnName: onnxModel.ModelInput, imageWidth: ImageSettings.imageWidth, imageHeight: ImageSettings.imageHeight, inputColumnName: nameof(ImageInputData.Image))
                            .Append(mlContext.Transforms.ExtractPixels(outputColumnName: onnxModel.ModelInput))
                            .Append(mlContext.Transforms.ApplyOnnxModel(modelFile: onnxModel.ModelPath, outputColumnName: onnxModel.ModelOutput, inputColumnName: onnxModel.ModelInput));

Any ideas how to fix it?

rfeiten avatar Mar 01 '21 19:03 rfeiten

identical...

sergiomaciel avatar Mar 09 '21 12:03 sergiomaciel

same here

diegogarber avatar May 30 '21 22:05 diegogarber

Please check this issue to see it help or not if it still happened > https://github.com/dotnet/machinelearning-samples/issues/920

sanme98 avatar Aug 12 '21 03:08 sanme98