Class: Google::Cloud::Vision::Annotate
- Inherits:
-
Object
- Object
- Google::Cloud::Vision::Annotate
- Defined in:
- lib/google/cloud/vision/annotate.rb
Overview
Annotate
Accumulates configuration for an image annotation request. Users
describe the type of Google Cloud Vision API tasks to perform over
images by configuring features such as faces
, landmarks
, text
,
etc. This configuration captures the Cloud Vision API vertical to
operate on and the number of top-scoring results to return.
See Project#annotate.
Instance Method Summary collapse
-
#annotate(*images, faces: false, landmarks: false, logos: false, labels: false, text: false, safe_search: false, properties: false) ⇒ Annotation+
Performs detection of Cloud Vision features on the given images.
Instance Method Details
#annotate(*images, faces: false, landmarks: false, logos: false, labels: false, text: false, safe_search: false, properties: false) ⇒ Annotation+
Performs detection of Cloud Vision
features
on the given images. If no options for features are provided, all
image detection features will be performed, with a default of 100
results for faces, landmarks, logos, and labels. If any feature option
is provided, only the specified feature detections will be performed.
Please review Pricing
before use, as a separate charge is incurred for each feature
performed on an image.
Cloud Vision sets upper limits on file size as well as on the total combined size of all images in a request. Reducing your file size can significantly improve throughput; however, be careful not to reduce image quality in the process. See Best Practices - Image Sizing for current file size limits.
See Project#annotate for requests that do not involve multiple feature configurations.
139 140 141 142 143 144 |
# File 'lib/google/cloud/vision/annotate.rb', line 139 def annotate *images, faces: false, landmarks: false, logos: false, labels: false, text: false, safe_search: false, properties: false add_requests(images, faces, landmarks, logos, labels, text, safe_search, properties) end |