Cusom vision confusion

Eduardo Gomez 3,416 Reputation points
2022-08-24T19:58:10.707+00:00

I am trying to figure out, how to insert my key correctly in order to use Custom Vision.

What I have to do is to upload my pictures via c#, I already went to the documentation, but the part of the keys is confusing

The Doc says

// You can obtain these values from the Keys and Endpoint page for your Custom Vision resource in the Azure Portal.  
private static string trainingEndpoint = "PASTE_YOUR_CUSTOM_VISION_TRAINING_ENDPOINT_HERE";  
private static string trainingKey = "PASTE_YOUR_CUSTOM_VISION_TRAINING_SUBSCRIPTION_KEY_HERE";  
// You can obtain these values from the Keys and Endpoint page for your Custom Vision Prediction resource in the Azure Portal.  
private static string predictionEndpoint = "PASTE_YOUR_CUSTOM_VISION_PREDICTION_ENDPOINT_HERE";  
private static string predictionKey = "PASTE_YOUR_CUSTOM_VISION_PREDICTION_SUBSCRIPTION_KEY_HERE";  
// You can obtain this value from the Properties page for your Custom Vision Prediction resource in the Azure Portal. See the "Resource ID" field. This typically has a value such as:  
// /subscriptions/<your subscription ID>/resourceGroups/<your resource group>/providers/Microsoft.CognitiveServices/accounts/<your Custom Vision prediction resource name>  
private static string predictionResourceId = "PASTE_YOUR_CUSTOM_VISION_PREDICTION_RESOURCE_ID_HERE";  
  

What is confusing for me, is that I have the azure portal, and I can go to keys.

234654-image.png

and I have the custom vision portal, and I can get another key

234694-image.png

Azure AI Custom Vision
Azure AI Custom Vision
An Azure artificial intelligence service and end-to-end platform for applying computer vision to specific domains.
208 questions
0 comments No comments
{count} votes

Accepted answer
  1. romungi-MSFT 41,861 Reputation points Microsoft Employee
    2022-08-25T08:32:33.097+00:00

    @Eduardo Gomez I see you are referring to the same resource from both the screens. The keys in this case will be same, that is, your training resource keys are the ones mentioned above. Please substitute the keys and endpoint for training resource in your file.

    For prediction, you will have to create another resource. Just navigate to your custom vision portal home screen and choose the settings icon from the top right corner and hit the "Create New" button. This will enable to pick the kind of resource required in your subscription. Choose "CustomVision.Prediction". This creates a new resource that you can look up in azure portal where you can copy the keys and its endpoint. The prediction resource id would be available from the properties tab of this resource.

    I hope this helps!!

    If an answer is helpful, please click on 130616-image.png or upvote 130671-image.png which might help other community members reading this thread.


0 additional answers

Sort by: Most helpful