aws-sdk-rekognition 1.46.0 → 1.47.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 66b78988008c0edbda9ee92460d994deb4686bbd9410f9e2f5c870c2dda1c230
4
- data.tar.gz: f5d654701e2512093b5e93822612e5b9b27eb178309874f84a074de53c802208
3
+ metadata.gz: ad6aaee8f78cd8bc00a78a881ac3cabda0195f7a6d52e7bd7a21d4b0c526c1dd
4
+ data.tar.gz: 2570ed7935d0bd49c858ef133f06ed871debac1d85eda5bb954fca43e8b7d778
5
5
  SHA512:
6
- metadata.gz: e24de16aa4123cec0c8a627d163bc3a6213fed11c770c1725178bb04d1b6beeaf71de45304c8e40866d9556807e8550c7a4ef6726146d0859edb6c38cf66b77d
7
- data.tar.gz: 3c531c5f29c7e8f53d9fe808ed78788b8b6da9c2b4321149ee504a3233dc4603faa42186ae6ed80d20de8e5ead831322b5d7f35380efcc7c5165558795eff8f9
6
+ metadata.gz: 16870e7bba084bb9d788bf87c826fc045eb89d8f271424b679b78ca32bdd261b4c9778a34d3a8c3b419b34a37591cfb15d506a9eb0743ebd9f3bb4998241a93e
7
+ data.tar.gz: 5b6f1f1732e5e367d651e1311025f84450c0d9fc00edcc5e90ca1bde6d020c68787d0f0bf357c3d3134a9f7024bb7fd5aaf09720a60bbf209a46b99e8966d38b
@@ -49,6 +49,6 @@ require_relative 'aws-sdk-rekognition/customizations'
49
49
  # @!group service
50
50
  module Aws::Rekognition
51
51
 
52
- GEM_VERSION = '1.46.0'
52
+ GEM_VERSION = '1.47.0'
53
53
 
54
54
  end
@@ -1814,6 +1814,115 @@ module Aws::Rekognition
1814
1814
  req.send_request(options)
1815
1815
  end
1816
1816
 
1817
+ # Detects Personal Protective Equipment (PPE) worn by people detected in
1818
+ # an image. Amazon Rekognition can detect the following types of PPE.
1819
+ #
1820
+ # * Face cover
1821
+ #
1822
+ # * Hand cover
1823
+ #
1824
+ # * Head cover
1825
+ #
1826
+ # You pass the input image as base64-encoded image bytes or as a
1827
+ # reference to an image in an Amazon S3 bucket. The image must be either
1828
+ # a PNG or JPG formatted file.
1829
+ #
1830
+ # `DetectProtectiveEquipment` detects PPE worn by up to 15 persons
1831
+ # detected in an image.
1832
+ #
1833
+ # For each person detected in the image the API returns an array of body
1834
+ # parts (face, head, left-hand, right-hand). For each body part, an
1835
+ # array of detected items of PPE is returned, including an indicator of
1836
+ # whether or not the PPE covers the body part. The API returns the
1837
+ # confidence it has in each detection (person, PPE, body part and body
1838
+ # part coverage). It also returns a bounding box (BoundingBox) for each
1839
+ # detected person and each detected item of PPE.
1840
+ #
1841
+ # You can optionally request a summary of detected PPE items with the
1842
+ # `SummarizationAttributes` input parameter. The summary provides the
1843
+ # following information.
1844
+ #
1845
+ # * The persons detected as wearing all of the types of PPE that you
1846
+ # specify.
1847
+ #
1848
+ # * The persons detected as not wearing all of the types PPE that you
1849
+ # specify.
1850
+ #
1851
+ # * The persons detected where PPE adornment could not be determined.
1852
+ #
1853
+ # This is a stateless API operation. That is, the operation does not
1854
+ # persist any data.
1855
+ #
1856
+ # This operation requires permissions to perform the
1857
+ # `rekognition:DetectProtectiveEquipment` action.
1858
+ #
1859
+ # @option params [required, Types::Image] :image
1860
+ # The image in which you want to detect PPE on detected persons. The
1861
+ # image can be passed as image bytes or you can reference an image
1862
+ # stored in an Amazon S3 bucket.
1863
+ #
1864
+ # @option params [Types::ProtectiveEquipmentSummarizationAttributes] :summarization_attributes
1865
+ # An array of PPE types that you want to summarize.
1866
+ #
1867
+ # @return [Types::DetectProtectiveEquipmentResponse] Returns a {Seahorse::Client::Response response} object which responds to the following methods:
1868
+ #
1869
+ # * {Types::DetectProtectiveEquipmentResponse#protective_equipment_model_version #protective_equipment_model_version} => String
1870
+ # * {Types::DetectProtectiveEquipmentResponse#persons #persons} => Array<Types::ProtectiveEquipmentPerson>
1871
+ # * {Types::DetectProtectiveEquipmentResponse#summary #summary} => Types::ProtectiveEquipmentSummary
1872
+ #
1873
+ # @example Request syntax with placeholder values
1874
+ #
1875
+ # resp = client.detect_protective_equipment({
1876
+ # image: { # required
1877
+ # bytes: "data",
1878
+ # s3_object: {
1879
+ # bucket: "S3Bucket",
1880
+ # name: "S3ObjectName",
1881
+ # version: "S3ObjectVersion",
1882
+ # },
1883
+ # },
1884
+ # summarization_attributes: {
1885
+ # min_confidence: 1.0, # required
1886
+ # required_equipment_types: ["FACE_COVER"], # required, accepts FACE_COVER, HAND_COVER, HEAD_COVER
1887
+ # },
1888
+ # })
1889
+ #
1890
+ # @example Response structure
1891
+ #
1892
+ # resp.protective_equipment_model_version #=> String
1893
+ # resp.persons #=> Array
1894
+ # resp.persons[0].body_parts #=> Array
1895
+ # resp.persons[0].body_parts[0].name #=> String, one of "FACE", "HEAD", "LEFT_HAND", "RIGHT_HAND"
1896
+ # resp.persons[0].body_parts[0].confidence #=> Float
1897
+ # resp.persons[0].body_parts[0].equipment_detections #=> Array
1898
+ # resp.persons[0].body_parts[0].equipment_detections[0].bounding_box.width #=> Float
1899
+ # resp.persons[0].body_parts[0].equipment_detections[0].bounding_box.height #=> Float
1900
+ # resp.persons[0].body_parts[0].equipment_detections[0].bounding_box.left #=> Float
1901
+ # resp.persons[0].body_parts[0].equipment_detections[0].bounding_box.top #=> Float
1902
+ # resp.persons[0].body_parts[0].equipment_detections[0].confidence #=> Float
1903
+ # resp.persons[0].body_parts[0].equipment_detections[0].type #=> String, one of "FACE_COVER", "HAND_COVER", "HEAD_COVER"
1904
+ # resp.persons[0].body_parts[0].equipment_detections[0].covers_body_part.confidence #=> Float
1905
+ # resp.persons[0].body_parts[0].equipment_detections[0].covers_body_part.value #=> Boolean
1906
+ # resp.persons[0].bounding_box.width #=> Float
1907
+ # resp.persons[0].bounding_box.height #=> Float
1908
+ # resp.persons[0].bounding_box.left #=> Float
1909
+ # resp.persons[0].bounding_box.top #=> Float
1910
+ # resp.persons[0].confidence #=> Float
1911
+ # resp.persons[0].id #=> Integer
1912
+ # resp.summary.persons_with_required_equipment #=> Array
1913
+ # resp.summary.persons_with_required_equipment[0] #=> Integer
1914
+ # resp.summary.persons_without_required_equipment #=> Array
1915
+ # resp.summary.persons_without_required_equipment[0] #=> Integer
1916
+ # resp.summary.persons_indeterminate #=> Array
1917
+ # resp.summary.persons_indeterminate[0] #=> Integer
1918
+ #
1919
+ # @overload detect_protective_equipment(params = {})
1920
+ # @param [Hash] params ({})
1921
+ def detect_protective_equipment(params = {}, options = {})
1922
+ req = build_request(:detect_protective_equipment, params)
1923
+ req.send_request(options)
1924
+ end
1925
+
1817
1926
  # Detects text in the input image and converts it into machine-readable
1818
1927
  # text.
1819
1928
  #
@@ -4890,7 +4999,7 @@ module Aws::Rekognition
4890
4999
  params: params,
4891
5000
  config: config)
4892
5001
  context[:gem_name] = 'aws-sdk-rekognition'
4893
- context[:gem_version] = '1.46.0'
5002
+ context[:gem_version] = '1.47.0'
4894
5003
  Seahorse::Client::Request.new(handlers, context)
4895
5004
  end
4896
5005
 
@@ -22,6 +22,8 @@ module Aws::Rekognition
22
22
  AudioMetadata = Shapes::StructureShape.new(name: 'AudioMetadata')
23
23
  AudioMetadataList = Shapes::ListShape.new(name: 'AudioMetadataList')
24
24
  Beard = Shapes::StructureShape.new(name: 'Beard')
25
+ BodyPart = Shapes::StringShape.new(name: 'BodyPart')
26
+ BodyParts = Shapes::ListShape.new(name: 'BodyParts')
25
27
  Boolean = Shapes::BooleanShape.new(name: 'Boolean')
26
28
  BoundingBox = Shapes::StructureShape.new(name: 'BoundingBox')
27
29
  BoundingBoxHeight = Shapes::FloatShape.new(name: 'BoundingBoxHeight')
@@ -48,6 +50,7 @@ module Aws::Rekognition
48
50
  ContentModerationDetection = Shapes::StructureShape.new(name: 'ContentModerationDetection')
49
51
  ContentModerationDetections = Shapes::ListShape.new(name: 'ContentModerationDetections')
50
52
  ContentModerationSortBy = Shapes::StringShape.new(name: 'ContentModerationSortBy')
53
+ CoversBodyPart = Shapes::StructureShape.new(name: 'CoversBodyPart')
51
54
  CreateCollectionRequest = Shapes::StructureShape.new(name: 'CreateCollectionRequest')
52
55
  CreateCollectionResponse = Shapes::StructureShape.new(name: 'CreateCollectionResponse')
53
56
  CreateProjectRequest = Shapes::StructureShape.new(name: 'CreateProjectRequest')
@@ -86,6 +89,8 @@ module Aws::Rekognition
86
89
  DetectLabelsResponse = Shapes::StructureShape.new(name: 'DetectLabelsResponse')
87
90
  DetectModerationLabelsRequest = Shapes::StructureShape.new(name: 'DetectModerationLabelsRequest')
88
91
  DetectModerationLabelsResponse = Shapes::StructureShape.new(name: 'DetectModerationLabelsResponse')
92
+ DetectProtectiveEquipmentRequest = Shapes::StructureShape.new(name: 'DetectProtectiveEquipmentRequest')
93
+ DetectProtectiveEquipmentResponse = Shapes::StructureShape.new(name: 'DetectProtectiveEquipmentResponse')
89
94
  DetectTextFilters = Shapes::StructureShape.new(name: 'DetectTextFilters')
90
95
  DetectTextRequest = Shapes::StructureShape.new(name: 'DetectTextRequest')
91
96
  DetectTextResponse = Shapes::StructureShape.new(name: 'DetectTextResponse')
@@ -93,6 +98,8 @@ module Aws::Rekognition
93
98
  Emotion = Shapes::StructureShape.new(name: 'Emotion')
94
99
  EmotionName = Shapes::StringShape.new(name: 'EmotionName')
95
100
  Emotions = Shapes::ListShape.new(name: 'Emotions')
101
+ EquipmentDetection = Shapes::StructureShape.new(name: 'EquipmentDetection')
102
+ EquipmentDetections = Shapes::ListShape.new(name: 'EquipmentDetections')
96
103
  EvaluationResult = Shapes::StructureShape.new(name: 'EvaluationResult')
97
104
  ExtendedPaginationToken = Shapes::StringShape.new(name: 'ExtendedPaginationToken')
98
105
  ExternalImageId = Shapes::StringShape.new(name: 'ExternalImageId')
@@ -220,6 +227,14 @@ module Aws::Rekognition
220
227
  ProjectVersionStatus = Shapes::StringShape.new(name: 'ProjectVersionStatus')
221
228
  ProjectVersionsPageSize = Shapes::IntegerShape.new(name: 'ProjectVersionsPageSize')
222
229
  ProjectsPageSize = Shapes::IntegerShape.new(name: 'ProjectsPageSize')
230
+ ProtectiveEquipmentBodyPart = Shapes::StructureShape.new(name: 'ProtectiveEquipmentBodyPart')
231
+ ProtectiveEquipmentPerson = Shapes::StructureShape.new(name: 'ProtectiveEquipmentPerson')
232
+ ProtectiveEquipmentPersonIds = Shapes::ListShape.new(name: 'ProtectiveEquipmentPersonIds')
233
+ ProtectiveEquipmentPersons = Shapes::ListShape.new(name: 'ProtectiveEquipmentPersons')
234
+ ProtectiveEquipmentSummarizationAttributes = Shapes::StructureShape.new(name: 'ProtectiveEquipmentSummarizationAttributes')
235
+ ProtectiveEquipmentSummary = Shapes::StructureShape.new(name: 'ProtectiveEquipmentSummary')
236
+ ProtectiveEquipmentType = Shapes::StringShape.new(name: 'ProtectiveEquipmentType')
237
+ ProtectiveEquipmentTypes = Shapes::ListShape.new(name: 'ProtectiveEquipmentTypes')
223
238
  ProvisionedThroughputExceededException = Shapes::StructureShape.new(name: 'ProvisionedThroughputExceededException')
224
239
  QualityFilter = Shapes::StringShape.new(name: 'QualityFilter')
225
240
  Reason = Shapes::StringShape.new(name: 'Reason')
@@ -251,6 +266,7 @@ module Aws::Rekognition
251
266
  SegmentTypeInfo = Shapes::StructureShape.new(name: 'SegmentTypeInfo')
252
267
  SegmentTypes = Shapes::ListShape.new(name: 'SegmentTypes')
253
268
  SegmentTypesInfo = Shapes::ListShape.new(name: 'SegmentTypesInfo')
269
+ ServiceQuotaExceededException = Shapes::StructureShape.new(name: 'ServiceQuotaExceededException')
254
270
  ShotSegment = Shapes::StructureShape.new(name: 'ShotSegment')
255
271
  Smile = Shapes::StructureShape.new(name: 'Smile')
256
272
  StartCelebrityRecognitionRequest = Shapes::StructureShape.new(name: 'StartCelebrityRecognitionRequest')
@@ -347,6 +363,8 @@ module Aws::Rekognition
347
363
  Beard.add_member(:confidence, Shapes::ShapeRef.new(shape: Percent, location_name: "Confidence"))
348
364
  Beard.struct_class = Types::Beard
349
365
 
366
+ BodyParts.member = Shapes::ShapeRef.new(shape: ProtectiveEquipmentBodyPart)
367
+
350
368
  BoundingBox.add_member(:width, Shapes::ShapeRef.new(shape: Float, location_name: "Width"))
351
369
  BoundingBox.add_member(:height, Shapes::ShapeRef.new(shape: Float, location_name: "Height"))
352
370
  BoundingBox.add_member(:left, Shapes::ShapeRef.new(shape: Float, location_name: "Left"))
@@ -420,6 +438,10 @@ module Aws::Rekognition
420
438
 
421
439
  ContentModerationDetections.member = Shapes::ShapeRef.new(shape: ContentModerationDetection)
422
440
 
441
+ CoversBodyPart.add_member(:confidence, Shapes::ShapeRef.new(shape: Percent, location_name: "Confidence"))
442
+ CoversBodyPart.add_member(:value, Shapes::ShapeRef.new(shape: Boolean, location_name: "Value"))
443
+ CoversBodyPart.struct_class = Types::CoversBodyPart
444
+
423
445
  CreateCollectionRequest.add_member(:collection_id, Shapes::ShapeRef.new(shape: CollectionId, required: true, location_name: "CollectionId"))
424
446
  CreateCollectionRequest.struct_class = Types::CreateCollectionRequest
425
447
 
@@ -570,6 +592,15 @@ module Aws::Rekognition
570
592
  DetectModerationLabelsResponse.add_member(:human_loop_activation_output, Shapes::ShapeRef.new(shape: HumanLoopActivationOutput, location_name: "HumanLoopActivationOutput"))
571
593
  DetectModerationLabelsResponse.struct_class = Types::DetectModerationLabelsResponse
572
594
 
595
+ DetectProtectiveEquipmentRequest.add_member(:image, Shapes::ShapeRef.new(shape: Image, required: true, location_name: "Image"))
596
+ DetectProtectiveEquipmentRequest.add_member(:summarization_attributes, Shapes::ShapeRef.new(shape: ProtectiveEquipmentSummarizationAttributes, location_name: "SummarizationAttributes"))
597
+ DetectProtectiveEquipmentRequest.struct_class = Types::DetectProtectiveEquipmentRequest
598
+
599
+ DetectProtectiveEquipmentResponse.add_member(:protective_equipment_model_version, Shapes::ShapeRef.new(shape: String, location_name: "ProtectiveEquipmentModelVersion"))
600
+ DetectProtectiveEquipmentResponse.add_member(:persons, Shapes::ShapeRef.new(shape: ProtectiveEquipmentPersons, location_name: "Persons"))
601
+ DetectProtectiveEquipmentResponse.add_member(:summary, Shapes::ShapeRef.new(shape: ProtectiveEquipmentSummary, location_name: "Summary"))
602
+ DetectProtectiveEquipmentResponse.struct_class = Types::DetectProtectiveEquipmentResponse
603
+
573
604
  DetectTextFilters.add_member(:word_filter, Shapes::ShapeRef.new(shape: DetectionFilter, location_name: "WordFilter"))
574
605
  DetectTextFilters.add_member(:regions_of_interest, Shapes::ShapeRef.new(shape: RegionsOfInterest, location_name: "RegionsOfInterest"))
575
606
  DetectTextFilters.struct_class = Types::DetectTextFilters
@@ -593,6 +624,14 @@ module Aws::Rekognition
593
624
 
594
625
  Emotions.member = Shapes::ShapeRef.new(shape: Emotion)
595
626
 
627
+ EquipmentDetection.add_member(:bounding_box, Shapes::ShapeRef.new(shape: BoundingBox, location_name: "BoundingBox"))
628
+ EquipmentDetection.add_member(:confidence, Shapes::ShapeRef.new(shape: Percent, location_name: "Confidence"))
629
+ EquipmentDetection.add_member(:type, Shapes::ShapeRef.new(shape: ProtectiveEquipmentType, location_name: "Type"))
630
+ EquipmentDetection.add_member(:covers_body_part, Shapes::ShapeRef.new(shape: CoversBodyPart, location_name: "CoversBodyPart"))
631
+ EquipmentDetection.struct_class = Types::EquipmentDetection
632
+
633
+ EquipmentDetections.member = Shapes::ShapeRef.new(shape: EquipmentDetection)
634
+
596
635
  EvaluationResult.add_member(:f1_score, Shapes::ShapeRef.new(shape: Float, location_name: "F1Score"))
597
636
  EvaluationResult.add_member(:summary, Shapes::ShapeRef.new(shape: Summary, location_name: "Summary"))
598
637
  EvaluationResult.struct_class = Types::EvaluationResult
@@ -981,6 +1020,32 @@ module Aws::Rekognition
981
1020
 
982
1021
  ProjectVersionDescriptions.member = Shapes::ShapeRef.new(shape: ProjectVersionDescription)
983
1022
 
1023
+ ProtectiveEquipmentBodyPart.add_member(:name, Shapes::ShapeRef.new(shape: BodyPart, location_name: "Name"))
1024
+ ProtectiveEquipmentBodyPart.add_member(:confidence, Shapes::ShapeRef.new(shape: Percent, location_name: "Confidence"))
1025
+ ProtectiveEquipmentBodyPart.add_member(:equipment_detections, Shapes::ShapeRef.new(shape: EquipmentDetections, location_name: "EquipmentDetections"))
1026
+ ProtectiveEquipmentBodyPart.struct_class = Types::ProtectiveEquipmentBodyPart
1027
+
1028
+ ProtectiveEquipmentPerson.add_member(:body_parts, Shapes::ShapeRef.new(shape: BodyParts, location_name: "BodyParts"))
1029
+ ProtectiveEquipmentPerson.add_member(:bounding_box, Shapes::ShapeRef.new(shape: BoundingBox, location_name: "BoundingBox"))
1030
+ ProtectiveEquipmentPerson.add_member(:confidence, Shapes::ShapeRef.new(shape: Percent, location_name: "Confidence"))
1031
+ ProtectiveEquipmentPerson.add_member(:id, Shapes::ShapeRef.new(shape: UInteger, location_name: "Id"))
1032
+ ProtectiveEquipmentPerson.struct_class = Types::ProtectiveEquipmentPerson
1033
+
1034
+ ProtectiveEquipmentPersonIds.member = Shapes::ShapeRef.new(shape: UInteger)
1035
+
1036
+ ProtectiveEquipmentPersons.member = Shapes::ShapeRef.new(shape: ProtectiveEquipmentPerson)
1037
+
1038
+ ProtectiveEquipmentSummarizationAttributes.add_member(:min_confidence, Shapes::ShapeRef.new(shape: Percent, required: true, location_name: "MinConfidence"))
1039
+ ProtectiveEquipmentSummarizationAttributes.add_member(:required_equipment_types, Shapes::ShapeRef.new(shape: ProtectiveEquipmentTypes, required: true, location_name: "RequiredEquipmentTypes"))
1040
+ ProtectiveEquipmentSummarizationAttributes.struct_class = Types::ProtectiveEquipmentSummarizationAttributes
1041
+
1042
+ ProtectiveEquipmentSummary.add_member(:persons_with_required_equipment, Shapes::ShapeRef.new(shape: ProtectiveEquipmentPersonIds, location_name: "PersonsWithRequiredEquipment"))
1043
+ ProtectiveEquipmentSummary.add_member(:persons_without_required_equipment, Shapes::ShapeRef.new(shape: ProtectiveEquipmentPersonIds, location_name: "PersonsWithoutRequiredEquipment"))
1044
+ ProtectiveEquipmentSummary.add_member(:persons_indeterminate, Shapes::ShapeRef.new(shape: ProtectiveEquipmentPersonIds, location_name: "PersonsIndeterminate"))
1045
+ ProtectiveEquipmentSummary.struct_class = Types::ProtectiveEquipmentSummary
1046
+
1047
+ ProtectiveEquipmentTypes.member = Shapes::ShapeRef.new(shape: ProtectiveEquipmentType)
1048
+
984
1049
  ProvisionedThroughputExceededException.struct_class = Types::ProvisionedThroughputExceededException
985
1050
 
986
1051
  Reasons.member = Shapes::ShapeRef.new(shape: Reason)
@@ -1056,6 +1121,8 @@ module Aws::Rekognition
1056
1121
 
1057
1122
  SegmentTypesInfo.member = Shapes::ShapeRef.new(shape: SegmentTypeInfo)
1058
1123
 
1124
+ ServiceQuotaExceededException.struct_class = Types::ServiceQuotaExceededException
1125
+
1059
1126
  ShotSegment.add_member(:index, Shapes::ShapeRef.new(shape: ULong, location_name: "Index"))
1060
1127
  ShotSegment.add_member(:confidence, Shapes::ShapeRef.new(shape: SegmentConfidence, location_name: "Confidence"))
1061
1128
  ShotSegment.struct_class = Types::ShotSegment
@@ -1574,6 +1641,22 @@ module Aws::Rekognition
1574
1641
  o.errors << Shapes::ShapeRef.new(shape: HumanLoopQuotaExceededException)
1575
1642
  end)
1576
1643
 
1644
+ api.add_operation(:detect_protective_equipment, Seahorse::Model::Operation.new.tap do |o|
1645
+ o.name = "DetectProtectiveEquipment"
1646
+ o.http_method = "POST"
1647
+ o.http_request_uri = "/"
1648
+ o.input = Shapes::ShapeRef.new(shape: DetectProtectiveEquipmentRequest)
1649
+ o.output = Shapes::ShapeRef.new(shape: DetectProtectiveEquipmentResponse)
1650
+ o.errors << Shapes::ShapeRef.new(shape: InvalidS3ObjectException)
1651
+ o.errors << Shapes::ShapeRef.new(shape: InvalidParameterException)
1652
+ o.errors << Shapes::ShapeRef.new(shape: ImageTooLargeException)
1653
+ o.errors << Shapes::ShapeRef.new(shape: AccessDeniedException)
1654
+ o.errors << Shapes::ShapeRef.new(shape: InternalServerError)
1655
+ o.errors << Shapes::ShapeRef.new(shape: ThrottlingException)
1656
+ o.errors << Shapes::ShapeRef.new(shape: ProvisionedThroughputExceededException)
1657
+ o.errors << Shapes::ShapeRef.new(shape: InvalidImageFormatException)
1658
+ end)
1659
+
1577
1660
  api.add_operation(:detect_text, Seahorse::Model::Operation.new.tap do |o|
1578
1661
  o.name = "DetectText"
1579
1662
  o.http_method = "POST"
@@ -1787,6 +1870,7 @@ module Aws::Rekognition
1787
1870
  o.errors << Shapes::ShapeRef.new(shape: ProvisionedThroughputExceededException)
1788
1871
  o.errors << Shapes::ShapeRef.new(shape: ResourceNotFoundException)
1789
1872
  o.errors << Shapes::ShapeRef.new(shape: InvalidImageFormatException)
1873
+ o.errors << Shapes::ShapeRef.new(shape: ServiceQuotaExceededException)
1790
1874
  end)
1791
1875
 
1792
1876
  api.add_operation(:list_collections, Seahorse::Model::Operation.new.tap do |o|
@@ -42,6 +42,7 @@ module Aws::Rekognition
42
42
  # * {ResourceInUseException}
43
43
  # * {ResourceNotFoundException}
44
44
  # * {ResourceNotReadyException}
45
+ # * {ServiceQuotaExceededException}
45
46
  # * {ThrottlingException}
46
47
  # * {VideoTooLargeException}
47
48
  #
@@ -216,6 +217,16 @@ module Aws::Rekognition
216
217
  end
217
218
  end
218
219
 
220
+ class ServiceQuotaExceededException < ServiceError
221
+
222
+ # @param [Seahorse::Client::RequestContext] context
223
+ # @param [String] message
224
+ # @param [Aws::Rekognition::Types::ServiceQuotaExceededException] data
225
+ def initialize(context, message, data = Aws::EmptyStructure.new)
226
+ super(context, message, data)
227
+ end
228
+ end
229
+
219
230
  class ThrottlingException < ServiceError
220
231
 
221
232
  # @param [Seahorse::Client::RequestContext] context
@@ -111,10 +111,11 @@ module Aws::Rekognition
111
111
  include Aws::Structure
112
112
  end
113
113
 
114
- # Identifies the bounding box around the label, face, or text. The
115
- # `left` (x-coordinate) and `top` (y-coordinate) are coordinates
116
- # representing the top and left sides of the bounding box. Note that the
117
- # upper-left corner of the image is the origin (0,0).
114
+ # Identifies the bounding box around the label, face, text or personal
115
+ # protective equipment. The `left` (x-coordinate) and `top`
116
+ # (y-coordinate) are coordinates representing the top and left sides of
117
+ # the bounding box. Note that the upper-left corner of the image is the
118
+ # origin (0,0).
118
119
  #
119
120
  # The `top` and `left` values returned are ratios of the overall image
120
121
  # size. For example, if the input image is 700x200 pixels, and the
@@ -500,6 +501,25 @@ module Aws::Rekognition
500
501
  include Aws::Structure
501
502
  end
502
503
 
504
+ # Information about an item of Personal Protective Equipment covering a
505
+ # corresponding body part. For more information, see
506
+ # DetectProtectiveEquipment.
507
+ #
508
+ # @!attribute [rw] confidence
509
+ # The confidence that Amazon Rekognition has in the value of `Value`.
510
+ # @return [Float]
511
+ #
512
+ # @!attribute [rw] value
513
+ # True if the PPE covers the corresponding body part, otherwise false.
514
+ # @return [Boolean]
515
+ #
516
+ class CoversBodyPart < Struct.new(
517
+ :confidence,
518
+ :value)
519
+ SENSITIVE = []
520
+ include Aws::Structure
521
+ end
522
+
503
523
  # @note When making an API call, you may pass CreateCollectionRequest
504
524
  # data as a hash:
505
525
  #
@@ -1446,6 +1466,64 @@ module Aws::Rekognition
1446
1466
  include Aws::Structure
1447
1467
  end
1448
1468
 
1469
+ # @note When making an API call, you may pass DetectProtectiveEquipmentRequest
1470
+ # data as a hash:
1471
+ #
1472
+ # {
1473
+ # image: { # required
1474
+ # bytes: "data",
1475
+ # s3_object: {
1476
+ # bucket: "S3Bucket",
1477
+ # name: "S3ObjectName",
1478
+ # version: "S3ObjectVersion",
1479
+ # },
1480
+ # },
1481
+ # summarization_attributes: {
1482
+ # min_confidence: 1.0, # required
1483
+ # required_equipment_types: ["FACE_COVER"], # required, accepts FACE_COVER, HAND_COVER, HEAD_COVER
1484
+ # },
1485
+ # }
1486
+ #
1487
+ # @!attribute [rw] image
1488
+ # The image in which you want to detect PPE on detected persons. The
1489
+ # image can be passed as image bytes or you can reference an image
1490
+ # stored in an Amazon S3 bucket.
1491
+ # @return [Types::Image]
1492
+ #
1493
+ # @!attribute [rw] summarization_attributes
1494
+ # An array of PPE types that you want to summarize.
1495
+ # @return [Types::ProtectiveEquipmentSummarizationAttributes]
1496
+ #
1497
+ class DetectProtectiveEquipmentRequest < Struct.new(
1498
+ :image,
1499
+ :summarization_attributes)
1500
+ SENSITIVE = []
1501
+ include Aws::Structure
1502
+ end
1503
+
1504
+ # @!attribute [rw] protective_equipment_model_version
1505
+ # The version number of the PPE detection model used to detect PPE in
1506
+ # the image.
1507
+ # @return [String]
1508
+ #
1509
+ # @!attribute [rw] persons
1510
+ # An array of persons detected in the image (including persons not
1511
+ # wearing PPE).
1512
+ # @return [Array<Types::ProtectiveEquipmentPerson>]
1513
+ #
1514
+ # @!attribute [rw] summary
1515
+ # Summary information for the types of PPE specified in the
1516
+ # `SummarizationAttributes` input parameter.
1517
+ # @return [Types::ProtectiveEquipmentSummary]
1518
+ #
1519
+ class DetectProtectiveEquipmentResponse < Struct.new(
1520
+ :protective_equipment_model_version,
1521
+ :persons,
1522
+ :summary)
1523
+ SENSITIVE = []
1524
+ include Aws::Structure
1525
+ end
1526
+
1449
1527
  # A set of optional parameters that you can use to set the criteria that
1450
1528
  # the text must meet to be included in your response. `WordFilter` looks
1451
1529
  # at a word’s height, width, and minimum confidence. `RegionOfInterest`
@@ -1619,6 +1697,36 @@ module Aws::Rekognition
1619
1697
  include Aws::Structure
1620
1698
  end
1621
1699
 
1700
+ # Information about an item of Personal Protective Equipment (PPE)
1701
+ # detected by DetectProtectiveEquipment. For more information, see
1702
+ # DetectProtectiveEquipment.
1703
+ #
1704
+ # @!attribute [rw] bounding_box
1705
+ # A bounding box surrounding the item of detected PPE.
1706
+ # @return [Types::BoundingBox]
1707
+ #
1708
+ # @!attribute [rw] confidence
1709
+ # The confidence that Amazon Rekognition has that the bounding box
1710
+ # (`BoundingBox`) contains an item of PPE.
1711
+ # @return [Float]
1712
+ #
1713
+ # @!attribute [rw] type
1714
+ # The type of detected PPE.
1715
+ # @return [String]
1716
+ #
1717
+ # @!attribute [rw] covers_body_part
1718
+ # Information about the body part covered by the detected PPE.
1719
+ # @return [Types::CoversBodyPart]
1720
+ #
1721
+ class EquipmentDetection < Struct.new(
1722
+ :bounding_box,
1723
+ :confidence,
1724
+ :type,
1725
+ :covers_body_part)
1726
+ SENSITIVE = []
1727
+ include Aws::Structure
1728
+ end
1729
+
1622
1730
  # The evaluation results for the training of a model.
1623
1731
  #
1624
1732
  # @!attribute [rw] f1_score
@@ -3742,6 +3850,156 @@ module Aws::Rekognition
3742
3850
  include Aws::Structure
3743
3851
  end
3744
3852
 
3853
+ # Information about a body part detected by DetectProtectiveEquipment
3854
+ # that contains PPE. An array of `ProtectiveEquipmentBodyPart` objects
3855
+ # is returned for each person detected by `DetectProtectiveEquipment`.
3856
+ #
3857
+ # @!attribute [rw] name
3858
+ # The detected body part.
3859
+ # @return [String]
3860
+ #
3861
+ # @!attribute [rw] confidence
3862
+ # The confidence that Amazon Rekognition has in the detection accuracy
3863
+ # of the detected body part.
3864
+ # @return [Float]
3865
+ #
3866
+ # @!attribute [rw] equipment_detections
3867
+ # An array of Personal Protective Equipment items detected around a
3868
+ # body part.
3869
+ # @return [Array<Types::EquipmentDetection>]
3870
+ #
3871
+ class ProtectiveEquipmentBodyPart < Struct.new(
3872
+ :name,
3873
+ :confidence,
3874
+ :equipment_detections)
3875
+ SENSITIVE = []
3876
+ include Aws::Structure
3877
+ end
3878
+
3879
+ # A person detected by a call to DetectProtectiveEquipment. The API
3880
+ # returns all persons detected in the input image in an array of
3881
+ # `ProtectiveEquipmentPerson` objects.
3882
+ #
3883
+ # @!attribute [rw] body_parts
3884
+ # An array of body parts detected on a person's body (including body
3885
+ # parts without PPE).
3886
+ # @return [Array<Types::ProtectiveEquipmentBodyPart>]
3887
+ #
3888
+ # @!attribute [rw] bounding_box
3889
+ # A bounding box around the detected person.
3890
+ # @return [Types::BoundingBox]
3891
+ #
3892
+ # @!attribute [rw] confidence
3893
+ # The confidence that Amazon Rekognition has that the bounding box
3894
+ # contains a person.
3895
+ # @return [Float]
3896
+ #
3897
+ # @!attribute [rw] id
3898
+ # The identifier for the detected person. The identifier is only
3899
+ # unique for a single call to `DetectProtectiveEquipment`.
3900
+ # @return [Integer]
3901
+ #
3902
+ class ProtectiveEquipmentPerson < Struct.new(
3903
+ :body_parts,
3904
+ :bounding_box,
3905
+ :confidence,
3906
+ :id)
3907
+ SENSITIVE = []
3908
+ include Aws::Structure
3909
+ end
3910
+
3911
+ # Specifies summary attributes to return from a call to
3912
+ # DetectProtectiveEquipment. You can specify which types of PPE to
3913
+ # summarize. You can also specify a minimum confidence value for
3914
+ # detections. Summary information is returned in the `Summary`
3915
+ # (ProtectiveEquipmentSummary) field of the response from
3916
+ # `DetectProtectiveEquipment`. The summary includes which persons in an
3917
+ # image were detected wearing the requested types of person protective
3918
+ # equipment (PPE), which persons were detected as not wearing PPE, and
3919
+ # the persons in which a determination could not be made. For more
3920
+ # information, see ProtectiveEquipmentSummary.
3921
+ #
3922
+ # @note When making an API call, you may pass ProtectiveEquipmentSummarizationAttributes
3923
+ # data as a hash:
3924
+ #
3925
+ # {
3926
+ # min_confidence: 1.0, # required
3927
+ # required_equipment_types: ["FACE_COVER"], # required, accepts FACE_COVER, HAND_COVER, HEAD_COVER
3928
+ # }
3929
+ #
3930
+ # @!attribute [rw] min_confidence
3931
+ # The minimum confidence level for which you want summary information.
3932
+ # The confidence level applies to person detection, body part
3933
+ # detection, equipment detection, and body part coverage. Amazon
3934
+ # Rekognition doesn't return summary information with a confidence
3935
+ # than this specified value. There isn't a default value.
3936
+ #
3937
+ # Specify a `MinConfidence` value that is between 50-100% as
3938
+ # `DetectProtectiveEquipment` returns predictions only where the
3939
+ # detection confidence is between 50% - 100%. If you specify a value
3940
+ # that is less than 50%, the results are the same specifying a value
3941
+ # of 50%.
3942
+ # @return [Float]
3943
+ #
3944
+ # @!attribute [rw] required_equipment_types
3945
+ # An array of personal protective equipment types for which you want
3946
+ # summary information. If a person is detected wearing a required
3947
+ # requipment type, the person's ID is added to the
3948
+ # `PersonsWithRequiredEquipment` array field returned in
3949
+ # ProtectiveEquipmentSummary by `DetectProtectiveEquipment`.
3950
+ # @return [Array<String>]
3951
+ #
3952
+ class ProtectiveEquipmentSummarizationAttributes < Struct.new(
3953
+ :min_confidence,
3954
+ :required_equipment_types)
3955
+ SENSITIVE = []
3956
+ include Aws::Structure
3957
+ end
3958
+
3959
+ # Summary information for required items of personal protective
3960
+ # equipment (PPE) detected on persons by a call to
3961
+ # DetectProtectiveEquipment. You specify the required type of PPE in the
3962
+ # `SummarizationAttributes` (ProtectiveEquipmentSummarizationAttributes)
3963
+ # input parameter. The summary includes which persons were detected
3964
+ # wearing the required personal protective equipment
3965
+ # (`PersonsWithRequiredEquipment`), which persons were detected as not
3966
+ # wearing the required PPE (`PersonsWithoutRequiredEquipment`), and the
3967
+ # persons in which a determination could not be made
3968
+ # (`PersonsIndeterminate`).
3969
+ #
3970
+ # To get a total for each category, use the size of the field array. For
3971
+ # example, to find out how many people were detected as wearing the
3972
+ # specified PPE, use the size of the `PersonsWithRequiredEquipment`
3973
+ # array. If you want to find out more about a person, such as the
3974
+ # location (BoundingBox) of the person on the image, use the person ID
3975
+ # in each array element. Each person ID matches the ID field of a
3976
+ # ProtectiveEquipmentPerson object returned in the `Persons` array by
3977
+ # `DetectProtectiveEquipment`.
3978
+ #
3979
+ # @!attribute [rw] persons_with_required_equipment
3980
+ # An array of IDs for persons who are wearing detected personal
3981
+ # protective equipment.
3982
+ # @return [Array<Integer>]
3983
+ #
3984
+ # @!attribute [rw] persons_without_required_equipment
3985
+ # An array of IDs for persons who are not wearing all of the types of
3986
+ # PPE specified in the RequiredEquipmentTypes field of the detected
3987
+ # personal protective equipment.
3988
+ # @return [Array<Integer>]
3989
+ #
3990
+ # @!attribute [rw] persons_indeterminate
3991
+ # An array of IDs for persons where it was not possible to determine
3992
+ # if they are wearing personal protective equipment.
3993
+ # @return [Array<Integer>]
3994
+ #
3995
+ class ProtectiveEquipmentSummary < Struct.new(
3996
+ :persons_with_required_equipment,
3997
+ :persons_without_required_equipment,
3998
+ :persons_indeterminate)
3999
+ SENSITIVE = []
4000
+ include Aws::Structure
4001
+ end
4002
+
3745
4003
  # The number of requests exceeded your throughput limit. If you want to
3746
4004
  # increase this limit, contact Amazon Rekognition.
3747
4005
  #
@@ -4145,6 +4403,12 @@ module Aws::Rekognition
4145
4403
  include Aws::Structure
4146
4404
  end
4147
4405
 
4406
+ # The size of the collection exceeds the allowed limit. For more
4407
+ # information, see Limits in Amazon Rekognition in the Amazon
4408
+ # Rekognition Developer Guide.
4409
+ #
4410
+ class ServiceQuotaExceededException < Aws::EmptyStructure; end
4411
+
4148
4412
  # Information about a shot detection segment detected in a video. For
4149
4413
  # more information, see SegmentDetection.
4150
4414
  #
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws-sdk-rekognition
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.46.0
4
+ version: 1.47.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Amazon Web Services
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-10-08 00:00:00.000000000 Z
11
+ date: 2020-10-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aws-sdk-core