dotnet / dotnet/machinelearning-samples
Issues when running E2E ObjectDetection sample in Azure
- Dominant language
- PowerShell
- Stars
- 4.7k
- Forks
- 2.7k
- Avg merge
- 2d 22h
- Merged PRs (30d)
- 1
Description
When deploying the unmodified E2E sample https://github.com/dotnet/machinelearning-samples/tree/v1.2/samples/csharp/end-to-end-apps/DeepLearning_ObjectDetection_Onnx into an Azure AppService some issues occur.
I suppose that one of the purposes of the sample is to show how PrectionEnginePool may be used in the Azure so these issues should be resolved.
Azure AppService is a supported scenario according to: https://docs.microsoft.com/en-us/dotnet/machine-learning/how-to-guides/serve-model-web-api-ml-net
1. **the AppService does not even start in the default 32-bit mode.** The result is:
502 - Web server received an invalid response while acting as a gateway or proxy server.
I think this is something related with https://github.com/aspnet/AspNetCore/issues/6097 but I am not sure.
Setting 64-bit mode resolves this and the app starts.
2. You must **change the relative path to the images** because the folder structure in the Azure is little bit different than when running locally.
In the Get method in the ObjectDetectionController.cs the line in Azure must read:
` string imageFileRelativePath = @"assets" + url;`
Similarly other relative paths.
3. **Now click on any of the images. DivisionByZero is raised.** This is described also in the https://github.com/dotnet/machinelearning/issues/4171
Contributor guide
Assessment
This issue has not been assessed yet.