migueldeicaza / TensorFlowSharp

TensorFlow API for .NET languages
MIT License
3.14k stars 578 forks source link

How to Detect Object in Xamarin Forms? #364

Closed mosinms7711 closed 5 years ago

mosinms7711 commented 5 years ago

I am working on one project where i need to click image and detect it using tensor flow api but i am confused how to use this API and is it Supported in Xamarin forms application.

migueldeicaza commented 5 years ago

Generally, TensorFlowSharp does not ship the payloads for mobile, so you will likely run into that problem first. Second, you would need to use a model, load and run it, but those are not related to Forms.

For mobile applications, you are much better off using Cognitive Services to create a custom model, and export it to a mobile-friendly model (TensorFlowLite, or CoreML).

migueldeicaza commented 5 years ago

My bad, start here:

https://www.customvision.ai/

Then download your native model for use with CoreML on iOS (part of the Xamarin APIs) or TensorFlow.Lite on Android (you need to add this NuGet package: https://www.nuget.org/packages/Xamarin.TensorFlow.Lite/)