Guardia Serviços de Tecnologia Ltda.
This document is available in other languages:
Guardia Serviços de Tecnologia Ltda.
This document is available in other languages:
I hereby claim:
To claim this, I am signing this object:
| {"lastUpload":"2020-04-30T01:05:40.369Z","extensionVersion":"v3.4.3"} |
| # Starter pipeline | |
| # Start with a minimal pipeline that you can customize to build and deploy your code. | |
| # Add steps that build, run tests, deploy, and more: | |
| # https://aka.ms/yaml | |
| variables: | |
| BuildConfiguration: Release | |
| FORCE_PUSH_NUGET: ${{ eq(variables['Build.SourceBranch'], 'refs/heads/develop') }} | |
| trigger: |
| #!/bin/bash | |
| # Adicione um novo remote; pode chamá-lo de "upstream": | |
| git remote add upstream https://github.com/usuario/projeto.git | |
| # Obtenha todos os branches deste novo remote, | |
| # como o upstream/master por exemplo: | |
| git fetch upstream |
| public static object GetValue(AttributeValue value) => GetString(value); | |
| private static object GetString(AttributeValue value) => !string.IsNullOrEmpty(value.S) ? value.S : GetNumber(value); | |
| private static object GetNumber(AttributeValue value) => !string.IsNullOrEmpty(value.N) ? value.N : GetObject(value); | |
| private static object GetObject(AttributeValue value) | |
| { | |
| if (value?.M?.Count > 0) | |
| { |
| # Suppress: EC112 EC114 | |
| root = true | |
| [*] | |
| charset = utf-8 | |
| max_line_length = 120 | |
| end_of_line = crlf | |
| indent_size = 4 | |
| indent_style = space | |
| insert_final_newline = false |
| foreach(var faceDetail in response.FaceDetails) | |
| { | |
| foreach(var emotion in faceDetail.Emotions) | |
| { | |
| if(emotion.Confidence > confidence) { Console.WriteLine($"this person may feel {emotion.Type}"); } | |
| } | |
| } |
| const float CONFIDENCE_LEVEL = 90; | |
| var count = 0; | |
| using(var source = new MemoryStream(image)) | |
| { | |
| var request = new DetectFacesRequest { Image = new Image() { Bytes = source }, Attributes = new List<string> { "ALL" } }; | |
| var response = await amazonRekognitionClient.DetectFacesAsync(request); | |
| foreach(var faceDetail in response.FaceDetails) |
| var image1 = await File.ReadAllBytesAsync("path\\to\\source\\image"); | |
| var image2 = await File.ReadAllBytesAsync("path\\to\\target\\image"); | |
| const float SIMILARITY_THRESHOLD = 75; | |
| const float CONFIDENCE_LEVEL = 95; | |
| using(var source = new MemoryStream(image1)) | |
| using(var target = new MemoryStream(image2)) | |
| { | |
| var request = new CompareFacesRequest |