Closed developervariety closed 5 years ago
I should also include I am using a custom model exported from Custom Vision (Azure).
Package versions: all latest
Can you share the model location to try once from my end
Yes, @prathyusha12345.
Here's a Google Drive link. https://drive.google.com/open?id=11Cvdku7IybhOA2vAqfcE86UcQeqhoEme
I have tried the custom model you have provided. While prediction, The model is not able to predict any label. The imageLabelPredictions value after executing below statement is null. Not sure why model is not able to predict.
imageLabelPredictions = _predictionFunction.Predict(imageInputData).PredictedLabels;
I have created an issue in MachinLearning Repo here https://github.com/dotnet/machinelearning/issues/3751
iirc this works on ML v0.7
My project requires the latest version otherwise I would use v0.7, but thank you for your help.
Switched to ML v0.7 for testing, and it's "working" but it has one issue. It continues giving me the same model.
Used the example from @CESARDELATORRE's web API, same model.
We’ll look into this. Btw, the model trained with Custom Vision from the WebAPI sample was able to just classify between two kinds of chairs. It was lacking a “null” or not applicable object, though, which should be implemented when training with Custom Vision.
I used my own model with your example since it's the only example that helped and explained the most.
ML.NET is ONLY reporting the model on the second line of labels.txt
with my custom model. I tested your custom model and it worked just fine..
I have about ~1k images for each tag in that model (3 tags). I'll make a new model and check results.
Update with the new model
Same result, returns the same model when it shouldn't be. If anyone would like me to provide some images to test with that model just let me know.
The model works fine on Azure Prediction API, but when I export it to TensorFlow and use it on ML v0.7 it doesn't do the expected outcome.
GIF of it in action: https://i.imgur.com/Vm5zpQz.gifv
EDIT: I tested Cesar's Web API to check if it was my code and got the same result.. I believe Custom Vision updated something causing incompatibility with ML.NET
@developervariety, please set addBatchDimensionInput: false
because this model has input with fully specified shape [?, 224, 224, 3] which is against inception model which does not have fully specified shape for the input.
@developervariety - Right, I tested the sample using the TensorFlow model generated with Cognitive Service Custom Vision and it works good by setting to addBatchDimensionInput: false
Closing this issue. Thanks for raising it up! 👍
This is my class.
Part of the exception