File tree Expand file tree Collapse file tree 10 files changed +40
-40
lines changed
RecognizeDomainSpecificContent Expand file tree Collapse file tree 10 files changed +40
-40
lines changed Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.AnalyzeImage
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- AnalyzeImageSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 6000 ) ;
19+ await AnalyzeImageSample . RunAsync ( endpoint , subscriptionKey ) ;
2020 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2121 Console . ReadLine ( ) ;
2222 }
Original file line number Diff line number Diff line change @@ -12,12 +12,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.BatchReadFile
1212 public class Program
1313 {
1414 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
15- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
16- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
15+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
16+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1717
18- static void Main ( string [ ] args )
18+ static async Task Main ( string [ ] args )
1919 {
20- BatchReadFileSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
20+ await BatchReadFileSample . RunAsync ( endpoint , subscriptionKey ) ;
2121
2222 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2323 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.DescribeImage
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- DescribeImageSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await DescribeImageSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.DetectObjects
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- DetectObjectSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await DetectObjectSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.GetAreaOfInte
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- GetAreaOfInterestSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await GetAreaOfInterestSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.GetThumbnail
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- GetThumbnailSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await GetThumbnailSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.OCR
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- OCRSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await OCRSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -12,12 +12,12 @@ class Program
1212 {
1313
1414 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
15- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
16- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
15+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
16+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1717
18- static void Main ( string [ ] args )
18+ static async Task Main ( string [ ] args )
1919 {
20- RecognizeDomainSpecificContentSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
20+ await RecognizeDomainSpecificContentSample . RunAsync ( endpoint , subscriptionKey ) ;
2121
2222 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2323 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.RecognizeText
1111
1212 public class Program
1313 {
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- RecognizeTextSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await RecognizeTextSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
Original file line number Diff line number Diff line change @@ -11,12 +11,12 @@ namespace Microsoft.Azure.CognitiveServices.Samples.ComputerVision.TagImage
1111 class Program
1212 {
1313 // Add your Azure Computer Vision subscription key and endpoint to your environment variables
14- public const string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15- public const string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
14+ public static string subscriptionKey = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_SUBSCRIPTION_KEY" ) ;
15+ public static string endpoint = Environment . GetEnvironmentVariable ( "COMPUTER_VISION_ENDPOINT" ) ;
1616
17- static void Main ( string [ ] args )
17+ static async Task Main ( string [ ] args )
1818 {
19- TagImageSample . RunAsync ( endpoint , subscriptionKey ) . Wait ( 5000 ) ;
19+ await TagImageSample . RunAsync ( endpoint , subscriptionKey ) ;
2020
2121 Console . WriteLine ( "\n Press ENTER to exit." ) ;
2222 Console . ReadLine ( ) ;
You can’t perform that action at this time.
0 commit comments