Docs: https://documenter.getpostman.com/view/989374/2s935hS7qK
This is a library for .NET core 7. Please note that the .NET Framework version is still in development.
using D8nObjectDetection;
string api_key = Environment.GetEnvironmentVariable("d8n_api_key");
DocumentClient client = new DocumentClient(api_key);
var result = await client.RunAnalysis("./test.jpg");
var status = await client.GetStatus(result);
System.Console.WriteLine(status);
await Task.Delay(5000);
status = await client.GetStatus(result);
System.Console.WriteLine(status);
var objects = await client.GetCompleted(result);
System.Console.WriteLine(objects.Count());
foreach(var value in objects){
Console.WriteLine(value.Class + " " + value.X1 + " " + value.Y1); // etc. etc..
}
Object now contains extracted info. For the full properties of what we can extract see this:
If you pass 1-st image to RunAnalysis(), you can get the second and third images