Skip to content

Commit af7f443

Browse files
committed
Merge branch 'comvis-updates' of https://github.com/PatrickFarley/azure-docs-pr into comvis-updates
2 parents 926bb61 + 2f5dd2e commit af7f443

File tree

4 files changed

+11
-11
lines changed

4 files changed

+11
-11
lines changed

articles/ai-services/computer-vision/includes/how-to-guides/analyze-image-40-csharp.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ To authenticate against the Image Analysis service, you need a Computer Vision k
2424
2525
Start by creating a **ImageAnalysisClient** object. For example:
2626

27-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_client)]
27+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_client)]
2828

2929

3030
## Select the image to analyze
@@ -35,14 +35,14 @@ You can select an image by providing a publicly accessible image URL, or by pass
3535

3636
Create a **Uri** object for the image you want to analyze.
3737

38-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_url)]
38+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_url)]
3939

4040

4141
### Image buffer
4242

4343
Alternatively, you can pass the image data to the SDK through a **BinaryData** object. For example, read from a local image file you want to analyze.
4444

45-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_file)]
45+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_file)]
4646

4747

4848

@@ -56,7 +56,7 @@ The Analysis 4.0 API gives you access to all of the service's image analysis fea
5656
5757

5858

59-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_features)]
59+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_features)]
6060

6161
<!--
6262
### Set model name when using a custom model
@@ -79,24 +79,24 @@ Use an **ImageAnalysisOptions** object to specify various options for the Analyz
7979
- **Crop aspect ratio**: An aspect ratio is calculated by dividing the target crop width by the height. Supported values are from 0.75 to 1.8 (inclusive). Setting this property is only relevant when **VisualFeatures.SmartCrops** was selected as part the visual feature list. If you select **VisualFeatures.SmartCrops** but don't specify aspect ratios, the service returns one crop suggestion with an aspect ratio it sees fit. In this case, the aspect ratio is between 0.5 and 2.0 (inclusive).
8080

8181

82-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_options)]
82+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_options)]
8383

8484
## Call the Analyze API
8585

8686
This section shows you how to make an analysis call to the service.
8787

8888
Call the **Analyze** method on the **ImageAnalysisClient** object, as shown here. The call is synchronous, and will block until the service returns the results or an error occurred. Alternatively, you can call the non-blocking **AnalyzeAsync** method.
8989

90-
Use the input objects created in the above sections. To analyze from an image buffer instead of URL, replace `imageURL` in the method call with the `imageStream` variable.
90+
Use the input objects created in the above sections. To analyze from an image buffer instead of URL, replace `imageURL` in the method call with the `imageData` variable.
9191

92-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_call)]
92+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_call)]
9393

9494

9595
## Get results from the service
9696

9797
The following code shows you how to parse the results of the various Analyze operations.
9898

99-
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-quickstart/HowTo.cs?name=snippet_results)]
99+
[!code-csharp[](~/cognitive-services-quickstart-code/dotnet/ComputerVision/4-0/image-analysis-how-to/Program.cs?name=snippet_results)]
100100

101101
<!--
102102
### Get results using custom model

articles/ai-services/computer-vision/includes/how-to-guides/analyze-image-40-java.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ This section shows you how to make an analysis call to the service.
8787

8888
Call the **analyze** method on the **ImageAnalysisClient** object, as shown here. The call is synchronous, and will block until the service returns the results or an error occurred. Alternatively, you can use a **ImageAnalysisAsyncClient** object instead, and call its **analyze** method which is non-blocking.
8989

90-
Use the input objects created in the above sections. To analyze from an image buffer instead of URL, replace `imageURL` in the method call with `imageBuffer`.
90+
Use the input objects created in the above sections. To analyze from an image buffer instead of URL, replace `imageURL` in the method call with `imageData`.
9191

9292
[!code-java[](~/cognitive-services-quickstart-code/java/ComputerVision/4-0/ImageAnalysisHowTo.java?name=snippet_call)]
9393

articles/ai-services/computer-vision/includes/how-to-guides/analyze-image-40-js.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ The Analysis 4.0 API gives you access to all of the service's image analysis fea
5151

5252
## Call the Analyze API with options
5353

54-
The following code calls the Analyze API with the features you selected above and additional options, defined below. To analyze from an image buffer instead of URL, replace `imageURL` in the method call with `imageBuffer`.
54+
The following code calls the Analyze API with the features you selected above and additional options, defined below. To analyze from an image buffer instead of URL, replace `imageURL` in the method call with `imageData`.
5555

5656
[!code-javascript[](~/cognitive-services-quickstart-code/javascript/ComputerVision/4-0/how-to.js?name=snippet_call)]
5757

articles/ai-services/computer-vision/includes/quickstarts-sdk/image-analysis-java-sdk-40.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ Open a console window and create a new folder for your quickstart application.
7474

7575
Open a text editor and copy the following content to a new file. Save the file as `ImageAnalysis.java`
7676

77-
[!code-java[](~/cognitive-services-quickstart-code/java/ComputerVision/4-0/ImageAnalysis.java?name=snippet_single)]
77+
[!code-java[](~/cognitive-services-quickstart-code/java/ComputerVision/4-0/ImageAnalysisQuickStart.java?name=snippet_single)]
7878

7979
> [!TIP]
8080
> The code analyzes an image from a URL. You can also analyze an image from the program memory buffer. For more information, see the [Analyze Image how-to guide](../../how-to/call-analyze-image-40.md).

0 commit comments

Comments
 (0)