dotnet / machinelearning

ML.NET is an open source and cross-platform machine learning framework for .NET.
https://dot.net/ml
MIT License
9.01k stars 1.88k forks source link

Is it possible to use ML.NET for image processing (such as remove background)? #7148

Closed winscripter closed 1 month ago

winscripter commented 4 months ago

Hello,

Does ML.NET support image processing, such as removing background or making a specific item different color, using a set of images? If so, is there a documented example for image processing with ML.NET?

Thanks.

luisquintanilla commented 1 month ago

Hi @winscripter,

You should be able to use ML.NET for this scenario.

What you might consider using is an ONNX model for segmentation.

Once you have the items segmented, you can apply transformations using the image library of your choice.

Although there isn't a documented example, you might consider this object detection tutorial which is a different but related task using ONNX models.

https://learn.microsoft.com/dotnet/machine-learning/tutorials/object-detection-onnx