windows-machine-learning

ML Image evaluation using Windows SDK 17763 accepts image of size 227 x 227


I have been using Windows.AI.MachineLearning.Preview, after switching to Windows.AI.MachineLearning and importing my .onnx model. I realised that I can now evaluate images that have the specific size of 227 by 227.

This doesn't work for my application as I don't know the size of the image and I can't crop or resize the image as it might change what it represents.


Solution

  • With Windows.AI.MachineLearning for build 17763 you have a couple of options:

    1. you can pass the model exactly what the model is expecting.
    2. you can apply resizing and cropping using your own application logic to ensure the proper thing gets done.
    3. you can pass in a larger image,and WindowsAI will automatically downscale and center crop, respecting aspect ratio

    Does that work for you ?