I use the Azure Custom Vision SDK ImageRegionCreateEntry Class in Object Detection mode to set the region of each image to be the full image and the method shows success in the code (in full):
string dir = "G:\\folderLocation";
string[] files = Directory.GetFiles(dir);
if (files[i].ToLower().Contains(tagList[y].Name.ToLower()))
{
using (var stream = new MemoryStream(File.ReadAllBytes(files[i])))
{
var createImage = trainingApi.CreateImagesFromData(CV_Project_Guid, stream, new List<Guid>() { thisTag.Id });
//set the region for an image that is 300x400
ImageRegionCreateEntry thisImgEntry = new ImageRegionCreateEntry(createImage.Images[0].Image.Id, createImage.Images[0].Image.Tags[0].TagId, 0, 150, 150, 150);
I check each image in the portal and it does not show the Box of the region limits:
whilst if I set the region manually in the portal and revisit the image it shows the boxed region:
I find missleading when setting the region with the sdk that the tree is gray as if the tree has been identified when the "Region Shown" toggle is On.
Also, if I set the region with the SDK for each image using the full boundries of the image in pixels, the training fails. If I set the region manually, the training succeeds.
Therefore I think the region is not set correctly by the sdk. Can someone please confirm whether when using the SDK and if ImageRegionCreateEntry succeeds, revisiting each image in the portal would show the bounding box?