google-cloud-vision-v1p3beta1 0.1.2 → 0.2.1
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 +4 -4
- data/AUTHENTICATION.md +6 -6
- data/README.md +48 -1
- data/lib/google-cloud-vision-v1p3beta1.rb +21 -1
- data/lib/google/cloud/vision/v1p3beta1.rb +16 -0
- data/lib/google/cloud/vision/v1p3beta1/image_annotator.rb +33 -2
- data/lib/google/cloud/vision/v1p3beta1/image_annotator/client.rb +101 -97
- data/lib/google/cloud/vision/v1p3beta1/image_annotator/credentials.rb +1 -1
- data/lib/google/cloud/vision/v1p3beta1/image_annotator/operations.rb +139 -127
- data/lib/google/cloud/vision/v1p3beta1/image_annotator/paths.rb +3 -3
- data/lib/google/cloud/vision/v1p3beta1/product_search.rb +44 -2
- data/lib/google/cloud/vision/v1p3beta1/product_search/client.rb +500 -508
- data/lib/google/cloud/vision/v1p3beta1/product_search/credentials.rb +1 -1
- data/lib/google/cloud/vision/v1p3beta1/product_search/operations.rb +139 -127
- data/lib/google/cloud/vision/v1p3beta1/product_search/paths.rb +12 -12
- data/lib/google/cloud/vision/v1p3beta1/version.rb +1 -1
- data/proto_docs/google/api/resource.rb +12 -12
- data/proto_docs/google/cloud/vision/v1p3beta1/geometry.rb +20 -20
- data/proto_docs/google/cloud/vision/v1p3beta1/image_annotator.rb +172 -172
- data/proto_docs/google/cloud/vision/v1p3beta1/product_search.rb +29 -29
- data/proto_docs/google/cloud/vision/v1p3beta1/product_search_service.rb +133 -133
- data/proto_docs/google/cloud/vision/v1p3beta1/text_annotation.rb +49 -49
- data/proto_docs/google/cloud/vision/v1p3beta1/web_detection.rb +28 -28
- data/proto_docs/google/longrunning/operations.rb +30 -30
- data/proto_docs/google/protobuf/any.rb +4 -4
- data/proto_docs/google/protobuf/empty.rb +2 -2
- data/proto_docs/google/protobuf/field_mask.rb +3 -3
- data/proto_docs/google/protobuf/timestamp.rb +4 -4
- data/proto_docs/google/protobuf/wrappers.rb +27 -27
- data/proto_docs/google/rpc/status.rb +6 -6
- data/proto_docs/google/type/color.rb +6 -6
- data/proto_docs/google/type/latlng.rb +4 -4
- metadata +32 -5
- data/lib/google/cloud/common_resources_pb.rb +0 -15
|
@@ -34,9 +34,9 @@ module Google
|
|
|
34
34
|
# @param project [String]
|
|
35
35
|
# @param location [String]
|
|
36
36
|
#
|
|
37
|
-
# @return [String]
|
|
37
|
+
# @return [::String]
|
|
38
38
|
def location_path project:, location:
|
|
39
|
-
raise ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
39
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
40
40
|
|
|
41
41
|
"projects/#{project}/locations/#{location}"
|
|
42
42
|
end
|
|
@@ -52,10 +52,10 @@ module Google
|
|
|
52
52
|
# @param location [String]
|
|
53
53
|
# @param product [String]
|
|
54
54
|
#
|
|
55
|
-
# @return [String]
|
|
55
|
+
# @return [::String]
|
|
56
56
|
def product_path project:, location:, product:
|
|
57
|
-
raise ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
58
|
-
raise ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
57
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
58
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
59
59
|
|
|
60
60
|
"projects/#{project}/locations/#{location}/products/#{product}"
|
|
61
61
|
end
|
|
@@ -71,10 +71,10 @@ module Google
|
|
|
71
71
|
# @param location [String]
|
|
72
72
|
# @param product_set [String]
|
|
73
73
|
#
|
|
74
|
-
# @return [String]
|
|
74
|
+
# @return [::String]
|
|
75
75
|
def product_set_path project:, location:, product_set:
|
|
76
|
-
raise ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
77
|
-
raise ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
76
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
77
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
78
78
|
|
|
79
79
|
"projects/#{project}/locations/#{location}/productSets/#{product_set}"
|
|
80
80
|
end
|
|
@@ -91,11 +91,11 @@ module Google
|
|
|
91
91
|
# @param product [String]
|
|
92
92
|
# @param reference_image [String]
|
|
93
93
|
#
|
|
94
|
-
# @return [String]
|
|
94
|
+
# @return [::String]
|
|
95
95
|
def reference_image_path project:, location:, product:, reference_image:
|
|
96
|
-
raise ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
97
|
-
raise ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
98
|
-
raise ArgumentError, "product cannot contain /" if product.to_s.include? "/"
|
|
96
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
|
97
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
|
98
|
+
raise ::ArgumentError, "product cannot contain /" if product.to_s.include? "/"
|
|
99
99
|
|
|
100
100
|
"projects/#{project}/locations/#{location}/products/#{product}/referenceImages/#{reference_image}"
|
|
101
101
|
end
|
|
@@ -128,7 +128,7 @@ module Google
|
|
|
128
128
|
# - pattern: "shelves/{shelf}"
|
|
129
129
|
# parent_type: "cloudresourcemanager.googleapis.com/Folder"
|
|
130
130
|
# @!attribute [rw] type
|
|
131
|
-
# @return [String]
|
|
131
|
+
# @return [::String]
|
|
132
132
|
# The resource type. It must be in the format of
|
|
133
133
|
# \\{service_name}/\\{resource_type_kind}. The `resource_type_kind` must be
|
|
134
134
|
# singular and must not include version numbers.
|
|
@@ -140,7 +140,7 @@ module Google
|
|
|
140
140
|
# should use PascalCase (UpperCamelCase). The maximum number of
|
|
141
141
|
# characters allowed for the `resource_type_kind` is 100.
|
|
142
142
|
# @!attribute [rw] pattern
|
|
143
|
-
# @return [Array
|
|
143
|
+
# @return [::Array<::String>]
|
|
144
144
|
# Optional. The relative resource name pattern associated with this resource
|
|
145
145
|
# type. The DNS prefix of the full resource name shouldn't be specified here.
|
|
146
146
|
#
|
|
@@ -161,11 +161,11 @@ module Google
|
|
|
161
161
|
# the same component name (e.g. "project") refers to IDs of the same
|
|
162
162
|
# type of resource.
|
|
163
163
|
# @!attribute [rw] name_field
|
|
164
|
-
# @return [String]
|
|
164
|
+
# @return [::String]
|
|
165
165
|
# Optional. The field on the resource that designates the resource name
|
|
166
166
|
# field. If omitted, this is assumed to be "name".
|
|
167
167
|
# @!attribute [rw] history
|
|
168
|
-
# @return [Google::Api::ResourceDescriptor::History]
|
|
168
|
+
# @return [::Google::Api::ResourceDescriptor::History]
|
|
169
169
|
# Optional. The historical or future-looking state of the resource pattern.
|
|
170
170
|
#
|
|
171
171
|
# Example:
|
|
@@ -182,19 +182,19 @@ module Google
|
|
|
182
182
|
# };
|
|
183
183
|
# }
|
|
184
184
|
# @!attribute [rw] plural
|
|
185
|
-
# @return [String]
|
|
185
|
+
# @return [::String]
|
|
186
186
|
# The plural name used in the resource name, such as 'projects' for
|
|
187
187
|
# the name of 'projects/\\{project}'. It is the same concept of the `plural`
|
|
188
188
|
# field in k8s CRD spec
|
|
189
189
|
# https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/
|
|
190
190
|
# @!attribute [rw] singular
|
|
191
|
-
# @return [String]
|
|
191
|
+
# @return [::String]
|
|
192
192
|
# The same concept of the `singular` field in k8s CRD spec
|
|
193
193
|
# https://kubernetes.io/docs/tasks/access-kubernetes-api/custom-resources/custom-resource-definitions/
|
|
194
194
|
# Such as "project" for the `resourcemanager.googleapis.com/Project` type.
|
|
195
195
|
class ResourceDescriptor
|
|
196
|
-
include Google::Protobuf::MessageExts
|
|
197
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
196
|
+
include ::Google::Protobuf::MessageExts
|
|
197
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
198
198
|
|
|
199
199
|
# A description of the historical or future-looking state of the
|
|
200
200
|
# resource pattern.
|
|
@@ -216,7 +216,7 @@ module Google
|
|
|
216
216
|
# Defines a proto annotation that describes a string field that refers to
|
|
217
217
|
# an API resource.
|
|
218
218
|
# @!attribute [rw] type
|
|
219
|
-
# @return [String]
|
|
219
|
+
# @return [::String]
|
|
220
220
|
# The resource type that the annotated field references.
|
|
221
221
|
#
|
|
222
222
|
# Example:
|
|
@@ -227,7 +227,7 @@ module Google
|
|
|
227
227
|
# }];
|
|
228
228
|
# }
|
|
229
229
|
# @!attribute [rw] child_type
|
|
230
|
-
# @return [String]
|
|
230
|
+
# @return [::String]
|
|
231
231
|
# The resource type of a child collection that the annotated field
|
|
232
232
|
# references. This is useful for annotating the `parent` field that
|
|
233
233
|
# doesn't have a fixed resource type.
|
|
@@ -240,8 +240,8 @@ module Google
|
|
|
240
240
|
# };
|
|
241
241
|
# }
|
|
242
242
|
class ResourceReference
|
|
243
|
-
include Google::Protobuf::MessageExts
|
|
244
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
243
|
+
include ::Google::Protobuf::MessageExts
|
|
244
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
245
245
|
end
|
|
246
246
|
end
|
|
247
247
|
end
|
|
@@ -24,66 +24,66 @@ module Google
|
|
|
24
24
|
# A vertex represents a 2D point in the image.
|
|
25
25
|
# NOTE: the vertex coordinates are in the same scale as the original image.
|
|
26
26
|
# @!attribute [rw] x
|
|
27
|
-
# @return [Integer]
|
|
27
|
+
# @return [::Integer]
|
|
28
28
|
# X coordinate.
|
|
29
29
|
# @!attribute [rw] y
|
|
30
|
-
# @return [Integer]
|
|
30
|
+
# @return [::Integer]
|
|
31
31
|
# Y coordinate.
|
|
32
32
|
class Vertex
|
|
33
|
-
include Google::Protobuf::MessageExts
|
|
34
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
33
|
+
include ::Google::Protobuf::MessageExts
|
|
34
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
35
35
|
end
|
|
36
36
|
|
|
37
37
|
# A vertex represents a 2D point in the image.
|
|
38
38
|
# NOTE: the normalized vertex coordinates are relative to the original image
|
|
39
39
|
# and range from 0 to 1.
|
|
40
40
|
# @!attribute [rw] x
|
|
41
|
-
# @return [Float]
|
|
41
|
+
# @return [::Float]
|
|
42
42
|
# X coordinate.
|
|
43
43
|
# @!attribute [rw] y
|
|
44
|
-
# @return [Float]
|
|
44
|
+
# @return [::Float]
|
|
45
45
|
# Y coordinate.
|
|
46
46
|
class NormalizedVertex
|
|
47
|
-
include Google::Protobuf::MessageExts
|
|
48
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
47
|
+
include ::Google::Protobuf::MessageExts
|
|
48
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
49
49
|
end
|
|
50
50
|
|
|
51
51
|
# A bounding polygon for the detected image annotation.
|
|
52
52
|
# @!attribute [rw] vertices
|
|
53
|
-
# @return [Array
|
|
53
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::Vertex>]
|
|
54
54
|
# The bounding polygon vertices.
|
|
55
55
|
# @!attribute [rw] normalized_vertices
|
|
56
|
-
# @return [Array
|
|
56
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::NormalizedVertex>]
|
|
57
57
|
# The bounding polygon normalized vertices.
|
|
58
58
|
class BoundingPoly
|
|
59
|
-
include Google::Protobuf::MessageExts
|
|
60
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
59
|
+
include ::Google::Protobuf::MessageExts
|
|
60
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
61
61
|
end
|
|
62
62
|
|
|
63
63
|
# A normalized bounding polygon around a portion of an image.
|
|
64
64
|
# @!attribute [rw] vertices
|
|
65
|
-
# @return [Array
|
|
65
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::NormalizedVertex>]
|
|
66
66
|
# Normalized vertices of the bounding polygon.
|
|
67
67
|
class NormalizedBoundingPoly
|
|
68
|
-
include Google::Protobuf::MessageExts
|
|
69
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
68
|
+
include ::Google::Protobuf::MessageExts
|
|
69
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
70
70
|
end
|
|
71
71
|
|
|
72
72
|
# A 3D position in the image, used primarily for Face detection landmarks.
|
|
73
73
|
# A valid Position must have both x and y coordinates.
|
|
74
74
|
# The position coordinates are in the same scale as the original image.
|
|
75
75
|
# @!attribute [rw] x
|
|
76
|
-
# @return [Float]
|
|
76
|
+
# @return [::Float]
|
|
77
77
|
# X coordinate.
|
|
78
78
|
# @!attribute [rw] y
|
|
79
|
-
# @return [Float]
|
|
79
|
+
# @return [::Float]
|
|
80
80
|
# Y coordinate.
|
|
81
81
|
# @!attribute [rw] z
|
|
82
|
-
# @return [Float]
|
|
82
|
+
# @return [::Float]
|
|
83
83
|
# Z coordinate (or depth).
|
|
84
84
|
class Position
|
|
85
|
-
include Google::Protobuf::MessageExts
|
|
86
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
85
|
+
include ::Google::Protobuf::MessageExts
|
|
86
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
87
87
|
end
|
|
88
88
|
end
|
|
89
89
|
end
|
|
@@ -25,20 +25,20 @@ module Google
|
|
|
25
25
|
# number of results to return for that type. Multiple `Feature` objects can
|
|
26
26
|
# be specified in the `features` list.
|
|
27
27
|
# @!attribute [rw] type
|
|
28
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Feature::Type]
|
|
28
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Feature::Type]
|
|
29
29
|
# The feature type.
|
|
30
30
|
# @!attribute [rw] max_results
|
|
31
|
-
# @return [Integer]
|
|
31
|
+
# @return [::Integer]
|
|
32
32
|
# Maximum number of results of this type. Does not apply to
|
|
33
33
|
# `TEXT_DETECTION`, `DOCUMENT_TEXT_DETECTION`, or `CROP_HINTS`.
|
|
34
34
|
# @!attribute [rw] model
|
|
35
|
-
# @return [String]
|
|
35
|
+
# @return [::String]
|
|
36
36
|
# Model to use for the feature.
|
|
37
37
|
# Supported values: "builtin/stable" (the default if unset) and
|
|
38
38
|
# "builtin/latest".
|
|
39
39
|
class Feature
|
|
40
|
-
include Google::Protobuf::MessageExts
|
|
41
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
40
|
+
include ::Google::Protobuf::MessageExts
|
|
41
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
42
42
|
|
|
43
43
|
# Type of Google Cloud Vision API feature to be extracted.
|
|
44
44
|
module Type
|
|
@@ -90,7 +90,7 @@ module Google
|
|
|
90
90
|
|
|
91
91
|
# External image source (Google Cloud Storage or web URL image location).
|
|
92
92
|
# @!attribute [rw] gcs_image_uri
|
|
93
|
-
# @return [String]
|
|
93
|
+
# @return [::String]
|
|
94
94
|
# **Use `image_uri` instead.**
|
|
95
95
|
#
|
|
96
96
|
# The Google Cloud Storage URI of the form
|
|
@@ -98,7 +98,7 @@ module Google
|
|
|
98
98
|
# [Google Cloud Storage Request
|
|
99
99
|
# URIs](https://cloud.google.com/storage/docs/reference-uris) for more info.
|
|
100
100
|
# @!attribute [rw] image_uri
|
|
101
|
-
# @return [String]
|
|
101
|
+
# @return [::String]
|
|
102
102
|
# The URI of the source image. Can be either:
|
|
103
103
|
#
|
|
104
104
|
# 1. A Google Cloud Storage URI of the form
|
|
@@ -117,29 +117,29 @@ module Google
|
|
|
117
117
|
# When both `gcs_image_uri` and `image_uri` are specified, `image_uri` takes
|
|
118
118
|
# precedence.
|
|
119
119
|
class ImageSource
|
|
120
|
-
include Google::Protobuf::MessageExts
|
|
121
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
120
|
+
include ::Google::Protobuf::MessageExts
|
|
121
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
122
122
|
end
|
|
123
123
|
|
|
124
124
|
# Client image to perform Google Cloud Vision API tasks over.
|
|
125
125
|
# @!attribute [rw] content
|
|
126
|
-
# @return [String]
|
|
126
|
+
# @return [::String]
|
|
127
127
|
# Image content, represented as a stream of bytes.
|
|
128
128
|
# Note: As with all `bytes` fields, protobuffers use a pure binary
|
|
129
129
|
# representation, whereas JSON representations use base64.
|
|
130
130
|
# @!attribute [rw] source
|
|
131
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ImageSource]
|
|
131
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ImageSource]
|
|
132
132
|
# Google Cloud Storage image location, or publicly-accessible image
|
|
133
133
|
# URL. If both `content` and `source` are provided for an image, `content`
|
|
134
134
|
# takes precedence and is used to perform the image annotation request.
|
|
135
135
|
class Image
|
|
136
|
-
include Google::Protobuf::MessageExts
|
|
137
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
136
|
+
include ::Google::Protobuf::MessageExts
|
|
137
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
138
138
|
end
|
|
139
139
|
|
|
140
140
|
# A face annotation object contains the results of face detection.
|
|
141
141
|
# @!attribute [rw] bounding_poly
|
|
142
|
-
# @return [Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
142
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
143
143
|
# The bounding polygon around the face. The coordinates of the bounding box
|
|
144
144
|
# are in the original image's scale, as returned in `ImageParams`.
|
|
145
145
|
# The bounding box is computed to "frame" the face in accordance with human
|
|
@@ -148,7 +148,7 @@ module Google
|
|
|
148
148
|
# `BoundingPoly` (the polygon will be unbounded) if only a partial face
|
|
149
149
|
# appears in the image to be annotated.
|
|
150
150
|
# @!attribute [rw] fd_bounding_poly
|
|
151
|
-
# @return [Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
151
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
152
152
|
# The `fd_bounding_poly` bounding polygon is tighter than the
|
|
153
153
|
# `boundingPoly`, and encloses only the skin part of the face. Typically, it
|
|
154
154
|
# is used to eliminate the face from any image analysis that detects the
|
|
@@ -156,63 +156,63 @@ module Google
|
|
|
156
156
|
# landmarker results, only on the initial face detection, hence
|
|
157
157
|
# the <code>fd</code> (face detection) prefix.
|
|
158
158
|
# @!attribute [rw] landmarks
|
|
159
|
-
# @return [Array
|
|
159
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::FaceAnnotation::Landmark>]
|
|
160
160
|
# Detected face landmarks.
|
|
161
161
|
# @!attribute [rw] roll_angle
|
|
162
|
-
# @return [Float]
|
|
162
|
+
# @return [::Float]
|
|
163
163
|
# Roll angle, which indicates the amount of clockwise/anti-clockwise rotation
|
|
164
164
|
# of the face relative to the image vertical about the axis perpendicular to
|
|
165
165
|
# the face. Range [-180,180].
|
|
166
166
|
# @!attribute [rw] pan_angle
|
|
167
|
-
# @return [Float]
|
|
167
|
+
# @return [::Float]
|
|
168
168
|
# Yaw angle, which indicates the leftward/rightward angle that the face is
|
|
169
169
|
# pointing relative to the vertical plane perpendicular to the image. Range
|
|
170
170
|
# [-180,180].
|
|
171
171
|
# @!attribute [rw] tilt_angle
|
|
172
|
-
# @return [Float]
|
|
172
|
+
# @return [::Float]
|
|
173
173
|
# Pitch angle, which indicates the upwards/downwards angle that the face is
|
|
174
174
|
# pointing relative to the image's horizontal plane. Range [-180,180].
|
|
175
175
|
# @!attribute [rw] detection_confidence
|
|
176
|
-
# @return [Float]
|
|
176
|
+
# @return [::Float]
|
|
177
177
|
# Detection confidence. Range [0, 1].
|
|
178
178
|
# @!attribute [rw] landmarking_confidence
|
|
179
|
-
# @return [Float]
|
|
179
|
+
# @return [::Float]
|
|
180
180
|
# Face landmarking confidence. Range [0, 1].
|
|
181
181
|
# @!attribute [rw] joy_likelihood
|
|
182
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
182
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
183
183
|
# Joy likelihood.
|
|
184
184
|
# @!attribute [rw] sorrow_likelihood
|
|
185
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
185
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
186
186
|
# Sorrow likelihood.
|
|
187
187
|
# @!attribute [rw] anger_likelihood
|
|
188
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
188
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
189
189
|
# Anger likelihood.
|
|
190
190
|
# @!attribute [rw] surprise_likelihood
|
|
191
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
191
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
192
192
|
# Surprise likelihood.
|
|
193
193
|
# @!attribute [rw] under_exposed_likelihood
|
|
194
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
194
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
195
195
|
# Under-exposed likelihood.
|
|
196
196
|
# @!attribute [rw] blurred_likelihood
|
|
197
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
197
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
198
198
|
# Blurred likelihood.
|
|
199
199
|
# @!attribute [rw] headwear_likelihood
|
|
200
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
200
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
201
201
|
# Headwear likelihood.
|
|
202
202
|
class FaceAnnotation
|
|
203
|
-
include Google::Protobuf::MessageExts
|
|
204
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
203
|
+
include ::Google::Protobuf::MessageExts
|
|
204
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
205
205
|
|
|
206
206
|
# A face-specific landmark (for example, a face feature).
|
|
207
207
|
# @!attribute [rw] type
|
|
208
|
-
# @return [Google::Cloud::Vision::V1p3beta1::FaceAnnotation::Landmark::Type]
|
|
208
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::FaceAnnotation::Landmark::Type]
|
|
209
209
|
# Face landmark type.
|
|
210
210
|
# @!attribute [rw] position
|
|
211
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Position]
|
|
211
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Position]
|
|
212
212
|
# Face landmark position.
|
|
213
213
|
class Landmark
|
|
214
|
-
include Google::Protobuf::MessageExts
|
|
215
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
214
|
+
include ::Google::Protobuf::MessageExts
|
|
215
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
216
216
|
|
|
217
217
|
# Face landmark (feature) type.
|
|
218
218
|
# Left and right are defined from the vantage of the viewer of the image
|
|
@@ -329,207 +329,207 @@ module Google
|
|
|
329
329
|
|
|
330
330
|
# Detected entity location information.
|
|
331
331
|
# @!attribute [rw] lat_lng
|
|
332
|
-
# @return [Google::Type::LatLng]
|
|
332
|
+
# @return [::Google::Type::LatLng]
|
|
333
333
|
# lat/long location coordinates.
|
|
334
334
|
class LocationInfo
|
|
335
|
-
include Google::Protobuf::MessageExts
|
|
336
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
335
|
+
include ::Google::Protobuf::MessageExts
|
|
336
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
337
337
|
end
|
|
338
338
|
|
|
339
339
|
# A `Property` consists of a user-supplied name/value pair.
|
|
340
340
|
# @!attribute [rw] name
|
|
341
|
-
# @return [String]
|
|
341
|
+
# @return [::String]
|
|
342
342
|
# Name of the property.
|
|
343
343
|
# @!attribute [rw] value
|
|
344
|
-
# @return [String]
|
|
344
|
+
# @return [::String]
|
|
345
345
|
# Value of the property.
|
|
346
346
|
# @!attribute [rw] uint64_value
|
|
347
|
-
# @return [Integer]
|
|
347
|
+
# @return [::Integer]
|
|
348
348
|
# Value of numeric properties.
|
|
349
349
|
class Property
|
|
350
|
-
include Google::Protobuf::MessageExts
|
|
351
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
350
|
+
include ::Google::Protobuf::MessageExts
|
|
351
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
352
352
|
end
|
|
353
353
|
|
|
354
354
|
# Set of detected entity features.
|
|
355
355
|
# @!attribute [rw] mid
|
|
356
|
-
# @return [String]
|
|
356
|
+
# @return [::String]
|
|
357
357
|
# Opaque entity ID. Some IDs may be available in
|
|
358
358
|
# [Google Knowledge Graph Search
|
|
359
359
|
# API](https://developers.google.com/knowledge-graph/).
|
|
360
360
|
# @!attribute [rw] locale
|
|
361
|
-
# @return [String]
|
|
361
|
+
# @return [::String]
|
|
362
362
|
# The language code for the locale in which the entity textual
|
|
363
363
|
# `description` is expressed.
|
|
364
364
|
# @!attribute [rw] description
|
|
365
|
-
# @return [String]
|
|
365
|
+
# @return [::String]
|
|
366
366
|
# Entity textual description, expressed in its `locale` language.
|
|
367
367
|
# @!attribute [rw] score
|
|
368
|
-
# @return [Float]
|
|
368
|
+
# @return [::Float]
|
|
369
369
|
# Overall score of the result. Range [0, 1].
|
|
370
370
|
# @!attribute [rw] confidence
|
|
371
|
-
# @return [Float]
|
|
371
|
+
# @return [::Float]
|
|
372
372
|
# **Deprecated. Use `score` instead.**
|
|
373
373
|
# The accuracy of the entity detection in an image.
|
|
374
374
|
# For example, for an image in which the "Eiffel Tower" entity is detected,
|
|
375
375
|
# this field represents the confidence that there is a tower in the query
|
|
376
376
|
# image. Range [0, 1].
|
|
377
377
|
# @!attribute [rw] topicality
|
|
378
|
-
# @return [Float]
|
|
378
|
+
# @return [::Float]
|
|
379
379
|
# The relevancy of the ICA (Image Content Annotation) label to the
|
|
380
380
|
# image. For example, the relevancy of "tower" is likely higher to an image
|
|
381
381
|
# containing the detected "Eiffel Tower" than to an image containing a
|
|
382
382
|
# detected distant towering building, even though the confidence that
|
|
383
383
|
# there is a tower in each image may be the same. Range [0, 1].
|
|
384
384
|
# @!attribute [rw] bounding_poly
|
|
385
|
-
# @return [Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
385
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
386
386
|
# Image region to which this entity belongs. Not produced
|
|
387
387
|
# for `LABEL_DETECTION` features.
|
|
388
388
|
# @!attribute [rw] locations
|
|
389
|
-
# @return [Array
|
|
389
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::LocationInfo>]
|
|
390
390
|
# The location information for the detected entity. Multiple
|
|
391
391
|
# `LocationInfo` elements can be present because one location may
|
|
392
392
|
# indicate the location of the scene in the image, and another location
|
|
393
393
|
# may indicate the location of the place where the image was taken.
|
|
394
394
|
# Location information is usually present for landmarks.
|
|
395
395
|
# @!attribute [rw] properties
|
|
396
|
-
# @return [Array
|
|
396
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::Property>]
|
|
397
397
|
# Some entities may have optional user-supplied `Property` (name/value)
|
|
398
398
|
# fields, such a score or string that qualifies the entity.
|
|
399
399
|
class EntityAnnotation
|
|
400
|
-
include Google::Protobuf::MessageExts
|
|
401
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
400
|
+
include ::Google::Protobuf::MessageExts
|
|
401
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
402
402
|
end
|
|
403
403
|
|
|
404
404
|
# Set of detected objects with bounding boxes.
|
|
405
405
|
# @!attribute [rw] mid
|
|
406
|
-
# @return [String]
|
|
406
|
+
# @return [::String]
|
|
407
407
|
# Object ID that should align with EntityAnnotation mid.
|
|
408
408
|
# @!attribute [rw] language_code
|
|
409
|
-
# @return [String]
|
|
409
|
+
# @return [::String]
|
|
410
410
|
# The BCP-47 language code, such as "en-US" or "sr-Latn". For more
|
|
411
411
|
# information, see
|
|
412
412
|
# http://www.unicode.org/reports/tr35/#Unicode_locale_identifier.
|
|
413
413
|
# @!attribute [rw] name
|
|
414
|
-
# @return [String]
|
|
414
|
+
# @return [::String]
|
|
415
415
|
# Object name, expressed in its `language_code` language.
|
|
416
416
|
# @!attribute [rw] score
|
|
417
|
-
# @return [Float]
|
|
417
|
+
# @return [::Float]
|
|
418
418
|
# Score of the result. Range [0, 1].
|
|
419
419
|
# @!attribute [rw] bounding_poly
|
|
420
|
-
# @return [Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
420
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
421
421
|
# Image region to which this object belongs. This must be populated.
|
|
422
422
|
class LocalizedObjectAnnotation
|
|
423
|
-
include Google::Protobuf::MessageExts
|
|
424
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
423
|
+
include ::Google::Protobuf::MessageExts
|
|
424
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
425
425
|
end
|
|
426
426
|
|
|
427
427
|
# Set of features pertaining to the image, computed by computer vision
|
|
428
428
|
# methods over safe-search verticals (for example, adult, spoof, medical,
|
|
429
429
|
# violence).
|
|
430
430
|
# @!attribute [rw] adult
|
|
431
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
431
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
432
432
|
# Represents the adult content likelihood for the image. Adult content may
|
|
433
433
|
# contain elements such as nudity, pornographic images or cartoons, or
|
|
434
434
|
# sexual activities.
|
|
435
435
|
# @!attribute [rw] spoof
|
|
436
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
436
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
437
437
|
# Spoof likelihood. The likelihood that an modification
|
|
438
438
|
# was made to the image's canonical version to make it appear
|
|
439
439
|
# funny or offensive.
|
|
440
440
|
# @!attribute [rw] medical
|
|
441
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
441
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
442
442
|
# Likelihood that this is a medical image.
|
|
443
443
|
# @!attribute [rw] violence
|
|
444
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
444
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
445
445
|
# Likelihood that this image contains violent content.
|
|
446
446
|
# @!attribute [rw] racy
|
|
447
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
447
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Likelihood]
|
|
448
448
|
# Likelihood that the request image contains racy content. Racy content may
|
|
449
449
|
# include (but is not limited to) skimpy or sheer clothing, strategically
|
|
450
450
|
# covered nudity, lewd or provocative poses, or close-ups of sensitive
|
|
451
451
|
# body areas.
|
|
452
452
|
class SafeSearchAnnotation
|
|
453
|
-
include Google::Protobuf::MessageExts
|
|
454
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
453
|
+
include ::Google::Protobuf::MessageExts
|
|
454
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
455
455
|
end
|
|
456
456
|
|
|
457
457
|
# Rectangle determined by min and max `LatLng` pairs.
|
|
458
458
|
# @!attribute [rw] min_lat_lng
|
|
459
|
-
# @return [Google::Type::LatLng]
|
|
459
|
+
# @return [::Google::Type::LatLng]
|
|
460
460
|
# Min lat/long pair.
|
|
461
461
|
# @!attribute [rw] max_lat_lng
|
|
462
|
-
# @return [Google::Type::LatLng]
|
|
462
|
+
# @return [::Google::Type::LatLng]
|
|
463
463
|
# Max lat/long pair.
|
|
464
464
|
class LatLongRect
|
|
465
|
-
include Google::Protobuf::MessageExts
|
|
466
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
465
|
+
include ::Google::Protobuf::MessageExts
|
|
466
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
467
467
|
end
|
|
468
468
|
|
|
469
469
|
# Color information consists of RGB channels, score, and the fraction of
|
|
470
470
|
# the image that the color occupies in the image.
|
|
471
471
|
# @!attribute [rw] color
|
|
472
|
-
# @return [Google::Type::Color]
|
|
472
|
+
# @return [::Google::Type::Color]
|
|
473
473
|
# RGB components of the color.
|
|
474
474
|
# @!attribute [rw] score
|
|
475
|
-
# @return [Float]
|
|
475
|
+
# @return [::Float]
|
|
476
476
|
# Image-specific score for this color. Value in range [0, 1].
|
|
477
477
|
# @!attribute [rw] pixel_fraction
|
|
478
|
-
# @return [Float]
|
|
478
|
+
# @return [::Float]
|
|
479
479
|
# The fraction of pixels the color occupies in the image.
|
|
480
480
|
# Value in range [0, 1].
|
|
481
481
|
class ColorInfo
|
|
482
|
-
include Google::Protobuf::MessageExts
|
|
483
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
482
|
+
include ::Google::Protobuf::MessageExts
|
|
483
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
484
484
|
end
|
|
485
485
|
|
|
486
486
|
# Set of dominant colors and their corresponding scores.
|
|
487
487
|
# @!attribute [rw] colors
|
|
488
|
-
# @return [Array
|
|
488
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::ColorInfo>]
|
|
489
489
|
# RGB color values with their score and pixel fraction.
|
|
490
490
|
class DominantColorsAnnotation
|
|
491
|
-
include Google::Protobuf::MessageExts
|
|
492
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
491
|
+
include ::Google::Protobuf::MessageExts
|
|
492
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
493
493
|
end
|
|
494
494
|
|
|
495
495
|
# Stores image properties, such as dominant colors.
|
|
496
496
|
# @!attribute [rw] dominant_colors
|
|
497
|
-
# @return [Google::Cloud::Vision::V1p3beta1::DominantColorsAnnotation]
|
|
497
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::DominantColorsAnnotation]
|
|
498
498
|
# If present, dominant colors completed successfully.
|
|
499
499
|
class ImageProperties
|
|
500
|
-
include Google::Protobuf::MessageExts
|
|
501
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
500
|
+
include ::Google::Protobuf::MessageExts
|
|
501
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
502
502
|
end
|
|
503
503
|
|
|
504
504
|
# Single crop hint that is used to generate a new crop when serving an image.
|
|
505
505
|
# @!attribute [rw] bounding_poly
|
|
506
|
-
# @return [Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
506
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::BoundingPoly]
|
|
507
507
|
# The bounding polygon for the crop region. The coordinates of the bounding
|
|
508
508
|
# box are in the original image's scale, as returned in `ImageParams`.
|
|
509
509
|
# @!attribute [rw] confidence
|
|
510
|
-
# @return [Float]
|
|
510
|
+
# @return [::Float]
|
|
511
511
|
# Confidence of this being a salient region. Range [0, 1].
|
|
512
512
|
# @!attribute [rw] importance_fraction
|
|
513
|
-
# @return [Float]
|
|
513
|
+
# @return [::Float]
|
|
514
514
|
# Fraction of importance of this salient region with respect to the original
|
|
515
515
|
# image.
|
|
516
516
|
class CropHint
|
|
517
|
-
include Google::Protobuf::MessageExts
|
|
518
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
517
|
+
include ::Google::Protobuf::MessageExts
|
|
518
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
519
519
|
end
|
|
520
520
|
|
|
521
521
|
# Set of crop hints that are used to generate new crops when serving images.
|
|
522
522
|
# @!attribute [rw] crop_hints
|
|
523
|
-
# @return [Array
|
|
523
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::CropHint>]
|
|
524
524
|
# Crop hint results.
|
|
525
525
|
class CropHintsAnnotation
|
|
526
|
-
include Google::Protobuf::MessageExts
|
|
527
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
526
|
+
include ::Google::Protobuf::MessageExts
|
|
527
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
528
528
|
end
|
|
529
529
|
|
|
530
530
|
# Parameters for crop hints annotation request.
|
|
531
531
|
# @!attribute [rw] aspect_ratios
|
|
532
|
-
# @return [Array
|
|
532
|
+
# @return [::Array<::Float>]
|
|
533
533
|
# Aspect ratios in floats, representing the ratio of the width to the height
|
|
534
534
|
# of the image. For example, if the desired aspect ratio is 4/3, the
|
|
535
535
|
# corresponding float value should be 1.33333. If not specified, the
|
|
@@ -537,25 +537,25 @@ module Google
|
|
|
537
537
|
# limited to a maximum of 16; any aspect ratios provided after the 16th are
|
|
538
538
|
# ignored.
|
|
539
539
|
class CropHintsParams
|
|
540
|
-
include Google::Protobuf::MessageExts
|
|
541
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
540
|
+
include ::Google::Protobuf::MessageExts
|
|
541
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
542
542
|
end
|
|
543
543
|
|
|
544
544
|
# Parameters for web detection request.
|
|
545
545
|
# @!attribute [rw] include_geo_results
|
|
546
|
-
# @return [Boolean]
|
|
546
|
+
# @return [::Boolean]
|
|
547
547
|
# Whether to include results derived from the geo information in the image.
|
|
548
548
|
class WebDetectionParams
|
|
549
|
-
include Google::Protobuf::MessageExts
|
|
550
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
549
|
+
include ::Google::Protobuf::MessageExts
|
|
550
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
551
551
|
end
|
|
552
552
|
|
|
553
553
|
# Image context and/or feature-specific parameters.
|
|
554
554
|
# @!attribute [rw] lat_long_rect
|
|
555
|
-
# @return [Google::Cloud::Vision::V1p3beta1::LatLongRect]
|
|
555
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::LatLongRect]
|
|
556
556
|
# Not used.
|
|
557
557
|
# @!attribute [rw] language_hints
|
|
558
|
-
# @return [Array
|
|
558
|
+
# @return [::Array<::String>]
|
|
559
559
|
# List of languages to use for TEXT_DETECTION. In most cases, an empty value
|
|
560
560
|
# yields the best results since it enables automatic language detection. For
|
|
561
561
|
# languages based on the Latin alphabet, setting `language_hints` is not
|
|
@@ -565,201 +565,201 @@ module Google
|
|
|
565
565
|
# error if one or more of the specified languages is not one of the
|
|
566
566
|
# [supported languages](https://cloud.google.com/vision/docs/languages).
|
|
567
567
|
# @!attribute [rw] crop_hints_params
|
|
568
|
-
# @return [Google::Cloud::Vision::V1p3beta1::CropHintsParams]
|
|
568
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::CropHintsParams]
|
|
569
569
|
# Parameters for crop hints annotation request.
|
|
570
570
|
# @!attribute [rw] product_search_params
|
|
571
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ProductSearchParams]
|
|
571
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ProductSearchParams]
|
|
572
572
|
# Parameters for product search.
|
|
573
573
|
# @!attribute [rw] web_detection_params
|
|
574
|
-
# @return [Google::Cloud::Vision::V1p3beta1::WebDetectionParams]
|
|
574
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::WebDetectionParams]
|
|
575
575
|
# Parameters for web detection.
|
|
576
576
|
class ImageContext
|
|
577
|
-
include Google::Protobuf::MessageExts
|
|
578
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
577
|
+
include ::Google::Protobuf::MessageExts
|
|
578
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
579
579
|
end
|
|
580
580
|
|
|
581
581
|
# Request for performing Google Cloud Vision API tasks over a user-provided
|
|
582
582
|
# image, with user-requested features.
|
|
583
583
|
# @!attribute [rw] image
|
|
584
|
-
# @return [Google::Cloud::Vision::V1p3beta1::Image]
|
|
584
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::Image]
|
|
585
585
|
# The image to be processed.
|
|
586
586
|
# @!attribute [rw] features
|
|
587
|
-
# @return [Array
|
|
587
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::Feature>]
|
|
588
588
|
# Requested features.
|
|
589
589
|
# @!attribute [rw] image_context
|
|
590
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ImageContext]
|
|
590
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ImageContext]
|
|
591
591
|
# Additional context that may accompany the image.
|
|
592
592
|
class AnnotateImageRequest
|
|
593
|
-
include Google::Protobuf::MessageExts
|
|
594
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
593
|
+
include ::Google::Protobuf::MessageExts
|
|
594
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
595
595
|
end
|
|
596
596
|
|
|
597
597
|
# If an image was produced from a file (e.g. a PDF), this message gives
|
|
598
598
|
# information about the source of that image.
|
|
599
599
|
# @!attribute [rw] uri
|
|
600
|
-
# @return [String]
|
|
600
|
+
# @return [::String]
|
|
601
601
|
# The URI of the file used to produce the image.
|
|
602
602
|
# @!attribute [rw] page_number
|
|
603
|
-
# @return [Integer]
|
|
603
|
+
# @return [::Integer]
|
|
604
604
|
# If the file was a PDF or TIFF, this field gives the page number within
|
|
605
605
|
# the file used to produce the image.
|
|
606
606
|
class ImageAnnotationContext
|
|
607
|
-
include Google::Protobuf::MessageExts
|
|
608
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
607
|
+
include ::Google::Protobuf::MessageExts
|
|
608
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
609
609
|
end
|
|
610
610
|
|
|
611
611
|
# Response to an image annotation request.
|
|
612
612
|
# @!attribute [rw] face_annotations
|
|
613
|
-
# @return [Array
|
|
613
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::FaceAnnotation>]
|
|
614
614
|
# If present, face detection has completed successfully.
|
|
615
615
|
# @!attribute [rw] landmark_annotations
|
|
616
|
-
# @return [Array
|
|
616
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::EntityAnnotation>]
|
|
617
617
|
# If present, landmark detection has completed successfully.
|
|
618
618
|
# @!attribute [rw] logo_annotations
|
|
619
|
-
# @return [Array
|
|
619
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::EntityAnnotation>]
|
|
620
620
|
# If present, logo detection has completed successfully.
|
|
621
621
|
# @!attribute [rw] label_annotations
|
|
622
|
-
# @return [Array
|
|
622
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::EntityAnnotation>]
|
|
623
623
|
# If present, label detection has completed successfully.
|
|
624
624
|
# @!attribute [rw] localized_object_annotations
|
|
625
|
-
# @return [Array
|
|
625
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::LocalizedObjectAnnotation>]
|
|
626
626
|
# If present, localized object detection has completed successfully.
|
|
627
627
|
# This will be sorted descending by confidence score.
|
|
628
628
|
# @!attribute [rw] text_annotations
|
|
629
|
-
# @return [Array
|
|
629
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::EntityAnnotation>]
|
|
630
630
|
# If present, text (OCR) detection has completed successfully.
|
|
631
631
|
# @!attribute [rw] full_text_annotation
|
|
632
|
-
# @return [Google::Cloud::Vision::V1p3beta1::TextAnnotation]
|
|
632
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::TextAnnotation]
|
|
633
633
|
# If present, text (OCR) detection or document (OCR) text detection has
|
|
634
634
|
# completed successfully.
|
|
635
635
|
# This annotation provides the structural hierarchy for the OCR detected
|
|
636
636
|
# text.
|
|
637
637
|
# @!attribute [rw] safe_search_annotation
|
|
638
|
-
# @return [Google::Cloud::Vision::V1p3beta1::SafeSearchAnnotation]
|
|
638
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::SafeSearchAnnotation]
|
|
639
639
|
# If present, safe-search annotation has completed successfully.
|
|
640
640
|
# @!attribute [rw] image_properties_annotation
|
|
641
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ImageProperties]
|
|
641
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ImageProperties]
|
|
642
642
|
# If present, image properties were extracted successfully.
|
|
643
643
|
# @!attribute [rw] crop_hints_annotation
|
|
644
|
-
# @return [Google::Cloud::Vision::V1p3beta1::CropHintsAnnotation]
|
|
644
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::CropHintsAnnotation]
|
|
645
645
|
# If present, crop hints have completed successfully.
|
|
646
646
|
# @!attribute [rw] web_detection
|
|
647
|
-
# @return [Google::Cloud::Vision::V1p3beta1::WebDetection]
|
|
647
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::WebDetection]
|
|
648
648
|
# If present, web detection has completed successfully.
|
|
649
649
|
# @!attribute [rw] product_search_results
|
|
650
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ProductSearchResults]
|
|
650
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ProductSearchResults]
|
|
651
651
|
# If present, product search has completed successfully.
|
|
652
652
|
# @!attribute [rw] error
|
|
653
|
-
# @return [Google::Rpc::Status]
|
|
653
|
+
# @return [::Google::Rpc::Status]
|
|
654
654
|
# If set, represents the error message for the operation.
|
|
655
655
|
# Note that filled-in image annotations are guaranteed to be
|
|
656
656
|
# correct, even when `error` is set.
|
|
657
657
|
# @!attribute [rw] context
|
|
658
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ImageAnnotationContext]
|
|
658
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ImageAnnotationContext]
|
|
659
659
|
# If present, contextual information is needed to understand where this image
|
|
660
660
|
# comes from.
|
|
661
661
|
class AnnotateImageResponse
|
|
662
|
-
include Google::Protobuf::MessageExts
|
|
663
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
662
|
+
include ::Google::Protobuf::MessageExts
|
|
663
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
664
664
|
end
|
|
665
665
|
|
|
666
666
|
# Response to a single file annotation request. A file may contain one or more
|
|
667
667
|
# images, which individually have their own responses.
|
|
668
668
|
# @!attribute [rw] input_config
|
|
669
|
-
# @return [Google::Cloud::Vision::V1p3beta1::InputConfig]
|
|
669
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::InputConfig]
|
|
670
670
|
# Information about the file for which this response is generated.
|
|
671
671
|
# @!attribute [rw] responses
|
|
672
|
-
# @return [Array
|
|
672
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::AnnotateImageResponse>]
|
|
673
673
|
# Individual responses to images found within the file.
|
|
674
674
|
class AnnotateFileResponse
|
|
675
|
-
include Google::Protobuf::MessageExts
|
|
676
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
675
|
+
include ::Google::Protobuf::MessageExts
|
|
676
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
677
677
|
end
|
|
678
678
|
|
|
679
679
|
# Multiple image annotation requests are batched into a single service call.
|
|
680
680
|
# @!attribute [rw] requests
|
|
681
|
-
# @return [Array
|
|
681
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::AnnotateImageRequest>]
|
|
682
682
|
# Individual image annotation requests for this batch.
|
|
683
683
|
class BatchAnnotateImagesRequest
|
|
684
|
-
include Google::Protobuf::MessageExts
|
|
685
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
684
|
+
include ::Google::Protobuf::MessageExts
|
|
685
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
686
686
|
end
|
|
687
687
|
|
|
688
688
|
# Response to a batch image annotation request.
|
|
689
689
|
# @!attribute [rw] responses
|
|
690
|
-
# @return [Array
|
|
690
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::AnnotateImageResponse>]
|
|
691
691
|
# Individual responses to image annotation requests within the batch.
|
|
692
692
|
class BatchAnnotateImagesResponse
|
|
693
|
-
include Google::Protobuf::MessageExts
|
|
694
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
693
|
+
include ::Google::Protobuf::MessageExts
|
|
694
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
695
695
|
end
|
|
696
696
|
|
|
697
697
|
# An offline file annotation request.
|
|
698
698
|
# @!attribute [rw] input_config
|
|
699
|
-
# @return [Google::Cloud::Vision::V1p3beta1::InputConfig]
|
|
699
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::InputConfig]
|
|
700
700
|
# Required. Information about the input file.
|
|
701
701
|
# @!attribute [rw] features
|
|
702
|
-
# @return [Array
|
|
702
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::Feature>]
|
|
703
703
|
# Required. Requested features.
|
|
704
704
|
# @!attribute [rw] image_context
|
|
705
|
-
# @return [Google::Cloud::Vision::V1p3beta1::ImageContext]
|
|
705
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::ImageContext]
|
|
706
706
|
# Additional context that may accompany the image(s) in the file.
|
|
707
707
|
# @!attribute [rw] output_config
|
|
708
|
-
# @return [Google::Cloud::Vision::V1p3beta1::OutputConfig]
|
|
708
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::OutputConfig]
|
|
709
709
|
# Required. The desired output location and metadata (e.g. format).
|
|
710
710
|
class AsyncAnnotateFileRequest
|
|
711
|
-
include Google::Protobuf::MessageExts
|
|
712
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
711
|
+
include ::Google::Protobuf::MessageExts
|
|
712
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
713
713
|
end
|
|
714
714
|
|
|
715
715
|
# The response for a single offline file annotation request.
|
|
716
716
|
# @!attribute [rw] output_config
|
|
717
|
-
# @return [Google::Cloud::Vision::V1p3beta1::OutputConfig]
|
|
717
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::OutputConfig]
|
|
718
718
|
# The output location and metadata from AsyncAnnotateFileRequest.
|
|
719
719
|
class AsyncAnnotateFileResponse
|
|
720
|
-
include Google::Protobuf::MessageExts
|
|
721
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
720
|
+
include ::Google::Protobuf::MessageExts
|
|
721
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
722
722
|
end
|
|
723
723
|
|
|
724
724
|
# Multiple async file annotation requests are batched into a single service
|
|
725
725
|
# call.
|
|
726
726
|
# @!attribute [rw] requests
|
|
727
|
-
# @return [Array
|
|
727
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::AsyncAnnotateFileRequest>]
|
|
728
728
|
# Required. Individual async file annotation requests for this batch.
|
|
729
729
|
class AsyncBatchAnnotateFilesRequest
|
|
730
|
-
include Google::Protobuf::MessageExts
|
|
731
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
730
|
+
include ::Google::Protobuf::MessageExts
|
|
731
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
732
732
|
end
|
|
733
733
|
|
|
734
734
|
# Response to an async batch file annotation request.
|
|
735
735
|
# @!attribute [rw] responses
|
|
736
|
-
# @return [Array
|
|
736
|
+
# @return [::Array<::Google::Cloud::Vision::V1p3beta1::AsyncAnnotateFileResponse>]
|
|
737
737
|
# The list of file annotation responses, one for each request in
|
|
738
738
|
# AsyncBatchAnnotateFilesRequest.
|
|
739
739
|
class AsyncBatchAnnotateFilesResponse
|
|
740
|
-
include Google::Protobuf::MessageExts
|
|
741
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
740
|
+
include ::Google::Protobuf::MessageExts
|
|
741
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
742
742
|
end
|
|
743
743
|
|
|
744
744
|
# The desired input location and metadata.
|
|
745
745
|
# @!attribute [rw] gcs_source
|
|
746
|
-
# @return [Google::Cloud::Vision::V1p3beta1::GcsSource]
|
|
746
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::GcsSource]
|
|
747
747
|
# The Google Cloud Storage location to read the input from.
|
|
748
748
|
# @!attribute [rw] mime_type
|
|
749
|
-
# @return [String]
|
|
749
|
+
# @return [::String]
|
|
750
750
|
# The type of the file. Currently only "application/pdf" and "image/tiff"
|
|
751
751
|
# are supported. Wildcards are not supported.
|
|
752
752
|
class InputConfig
|
|
753
|
-
include Google::Protobuf::MessageExts
|
|
754
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
753
|
+
include ::Google::Protobuf::MessageExts
|
|
754
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
755
755
|
end
|
|
756
756
|
|
|
757
757
|
# The desired output location and metadata.
|
|
758
758
|
# @!attribute [rw] gcs_destination
|
|
759
|
-
# @return [Google::Cloud::Vision::V1p3beta1::GcsDestination]
|
|
759
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::GcsDestination]
|
|
760
760
|
# The Google Cloud Storage location to write the output(s) to.
|
|
761
761
|
# @!attribute [rw] batch_size
|
|
762
|
-
# @return [Integer]
|
|
762
|
+
# @return [::Integer]
|
|
763
763
|
# The max number of response protos to put into each output JSON file on
|
|
764
764
|
# Google Cloud Storage.
|
|
765
765
|
# The valid range is [1, 100]. If not specified, the default value is 20.
|
|
@@ -772,23 +772,23 @@ module Google
|
|
|
772
772
|
# Currently, batch_size only applies to GcsDestination, with potential future
|
|
773
773
|
# support for other output configurations.
|
|
774
774
|
class OutputConfig
|
|
775
|
-
include Google::Protobuf::MessageExts
|
|
776
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
775
|
+
include ::Google::Protobuf::MessageExts
|
|
776
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
777
777
|
end
|
|
778
778
|
|
|
779
779
|
# The Google Cloud Storage location where the input will be read from.
|
|
780
780
|
# @!attribute [rw] uri
|
|
781
|
-
# @return [String]
|
|
781
|
+
# @return [::String]
|
|
782
782
|
# Google Cloud Storage URI for the input file. This must only be a
|
|
783
783
|
# Google Cloud Storage object. Wildcards are not currently supported.
|
|
784
784
|
class GcsSource
|
|
785
|
-
include Google::Protobuf::MessageExts
|
|
786
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
785
|
+
include ::Google::Protobuf::MessageExts
|
|
786
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
787
787
|
end
|
|
788
788
|
|
|
789
789
|
# The Google Cloud Storage location where the output will be written to.
|
|
790
790
|
# @!attribute [rw] uri
|
|
791
|
-
# @return [String]
|
|
791
|
+
# @return [::String]
|
|
792
792
|
# Google Cloud Storage URI where the results will be stored. Results will
|
|
793
793
|
# be in JSON format and preceded by its corresponding input URI. This field
|
|
794
794
|
# can either represent a single file, or a prefix for multiple outputs.
|
|
@@ -805,23 +805,23 @@ module Google
|
|
|
805
805
|
# Multiple outputs can happen if, for example, the output JSON is too large
|
|
806
806
|
# and overflows into multiple sharded files.
|
|
807
807
|
class GcsDestination
|
|
808
|
-
include Google::Protobuf::MessageExts
|
|
809
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
808
|
+
include ::Google::Protobuf::MessageExts
|
|
809
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
810
810
|
end
|
|
811
811
|
|
|
812
812
|
# Contains metadata for the BatchAnnotateImages operation.
|
|
813
813
|
# @!attribute [rw] state
|
|
814
|
-
# @return [Google::Cloud::Vision::V1p3beta1::OperationMetadata::State]
|
|
814
|
+
# @return [::Google::Cloud::Vision::V1p3beta1::OperationMetadata::State]
|
|
815
815
|
# Current state of the batch operation.
|
|
816
816
|
# @!attribute [rw] create_time
|
|
817
|
-
# @return [Google::Protobuf::Timestamp]
|
|
817
|
+
# @return [::Google::Protobuf::Timestamp]
|
|
818
818
|
# The time when the batch request was received.
|
|
819
819
|
# @!attribute [rw] update_time
|
|
820
|
-
# @return [Google::Protobuf::Timestamp]
|
|
820
|
+
# @return [::Google::Protobuf::Timestamp]
|
|
821
821
|
# The time when the operation result was last updated.
|
|
822
822
|
class OperationMetadata
|
|
823
|
-
include Google::Protobuf::MessageExts
|
|
824
|
-
extend Google::Protobuf::MessageExts::ClassMethods
|
|
823
|
+
include ::Google::Protobuf::MessageExts
|
|
824
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
|
825
825
|
|
|
826
826
|
# Batch operation states.
|
|
827
827
|
module State
|