dotnet / dotnet/machinelearning

Is it possible to use the same model with different size images?

Open
#5,902 1 comment 0 reactions 0 assignees View on GitHub
area-ONNX question
Dominant language
C#
Stars
9.4k
Forks
2k
Avg merge
2d 20h
Merged PRs (30d)
11

Description

In our project our team has been using a custom pre-trained YOLOv4 model. Inferencing is done using Emgu CV, a C# wrapper for OpenCV with the DNN(Deep Neural Networks) module. We've found a way to change the model's input based on image size and it works quite well. (Our model is trained on 416x416 images, but it can properly find objects in 3000x3000 images without dividing the image into parts).

**Q: Is there a way to use ONNX models in ML.NET dynamically by using different sized images?**

From my understanding ONNX models do support dynamic/custom inputs: [https://github.com/onnx/onnx/issues/3627](https://github.com/onnx/onnx/issues/3627)

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.