You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/cognitive-services/Face/QuickStarts/go-sdk.md
+11-11Lines changed: 11 additions & 11 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -101,7 +101,7 @@ Your workspace will contain three folders:
101
101
102
102
***src** - This directory will contain source code and packages. Any packages installed with the `go get` command will go here.
103
103
***pkg** - This directory will contain the compiled Go package objects. These files all have a `.a` extension.
104
-
***bin** - This directory will contains the binary executable files that are created when you run `go install`.
104
+
***bin** - This directory will contain the binary executable files that are created when you run `go install`.
105
105
106
106
> [!TIP]
107
107
> To learn more about the structure of a Go workspace, see the [Go language documentation](https://golang.org/doc/code.html#Workspaces). This guide includes information for setting `$GOPATH` and `$GOROOT`.
@@ -172,13 +172,13 @@ Create a **main** function and add the following code to it to instantiate a cli
172
172
173
173
## Detect faces in an image
174
174
175
-
Add the following code in your **main** method. This defines a remote sample image and specifies which face features to extract from the image. It also specifies which AI model to use to extract data from the detected face(s). See [Specify a recognition model](../Face-API-How-to-Topics/specify-recognition-model.md) for information on these options. Finally, the **[DetectWithURL](https://godoc.org/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/face#Client.DetectWithURL)** method performs the face detection operation on the image and saves the results in program memory.
175
+
Add the following code in your **main** method. This code defines a remote sample image and specifies which face features to extract from the image. It also specifies which AI model to use to extract data from the detected face(s). See [Specify a recognition model](../Face-API-How-to-Topics/specify-recognition-model.md) for information on these options. Finally, the **[DetectWithURL](https://godoc.org/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/face#Client.DetectWithURL)** method does the face detection operation on the image and saves the results in program memory.
The next block of code takes the first element in the array of [DetectedFace](https://godoc.org/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/face#DetectedFace) objects and prints its attributes to the console. If you used an image with multiple faces, you should iterate through teh array instead.
181
+
The next block of code takes the first element in the array of [DetectedFace](https://godoc.org/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/face#DetectedFace) objects and prints its attributes to the console. If you used an image with multiple faces, you should iterate through the array instead.
@@ -223,7 +223,7 @@ Once you've downloaded your images, add the following code to the bottom of your
223
223
224
224
### Create PersonGroup Persons
225
225
226
-
The next block of code authenticates a **[PersonGroupPersonClient](https://godoc.org/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/face#PersonGroupPersonClient)** and uses it to define three new **PersonGroup Person** objects. These each represent a single person in the set of images.
226
+
The next block of code authenticates a **[PersonGroupPersonClient](https://godoc.org/github.com/Azure/azure-sdk-for-go/services/cognitiveservices/v1.0/face#PersonGroupPersonClient)** and uses it to define three new **PersonGroup Person** objects. These objects each represent a single person in the set of images.
@@ -235,7 +235,7 @@ The following code sorts the images by their prefix, detects faces, and assigns
235
235
236
236
### Train PersonGroup
237
237
238
-
Once you've assigned faces, you must train the **PersonGroup** so that it can identify the visual features associated with each of its **Person** objects. The following code calls the asynchronous **train** method and polls the result, printing the status to the console.
238
+
Once you've assigned faces, you train the **PersonGroup** so it can identify the visual features associated with each of its **Person** objects. The following code calls the asynchronous **train** method and polls the result, printing the status to the console.
@@ -298,15 +298,15 @@ The following code compares each of the source images to the target image and pr
298
298
299
299
## Take a snapshot for data migration
300
300
301
-
The Snapshots feature lets you move your saved face data, such as a trained **PersonGroup**, to a different Azure Cognitive Services Face subscription. You may want to use this feature if, for example, you've created a **PersonGroup** object using a free trial subscription and now want to migrate it to a paid subscription. See the [Migrate your face data](../Face-API-How-to-Topics/how-to-migrate-face-data.md) for a broad overview of the Snapshots feature.
301
+
The Snapshots feature lets you move your saved face data, such as a trained **PersonGroup**, to a different Azure Cognitive Services Face subscription. You might use this feature if, for example, you've created a **PersonGroup** object using a free trial subscription and now want to migrate it to a paid subscription. See the [Migrate your face data](../Face-API-How-to-Topics/how-to-migrate-face-data.md) for a broad overview of the Snapshots feature.
302
302
303
-
In this example, you will migrate the **PersonGroup** you created in [Create and train a person group](#create-and-train-a-person-group). You can either complete that section first, or use your own Face data construct(s).
303
+
In this example, you'll migrate the **PersonGroup** you created in [Create and train a person group](#create-and-train-a-person-group). You can either complete that section first, or use your own Face data construct(s).
304
304
305
305
### Set up target subscription
306
306
307
307
First, you must have a second Azure subscription with a Face resource; you can do this by repeating the steps in the [Setting up](#setting-up) section.
308
308
309
-
Then, create the following variables near the top of your **main** method. You'll also need to create new environment variables for the subscription ID of your Azure account, as well as the key, endpoint, and subscription ID of your new (target) account.
309
+
Then, create the following variables near the top of your **main** method. You'll also need to create new environment variables for the subscription ID of your Azure account, as well as the key, endpoint, and subscription ID of your new (target) account.
0 commit comments