# Cloud Vision V1 API - Class Google::Cloud::Vision::V1::ReferenceImage (v1.7.0)

1.7.0 (latest) 1.6.0 1.5.1 1.4.0 1.3.1 1.2.1 1.1.0 1.0.1 0.15.0 0.14.0 0.13.2 0.12.0 0.11.1 0.10.0 0.9.0 0.8.0 0.7.0 0.6.4 Reference documentation and code samples for the Cloud Vision V1 API class Google::Cloud::Vision::V1::ReferenceImage.

A `ReferenceImage` represents a product image and its associated metadata,
such as bounding boxes.

## Inherits

- Object

## Extended By

- Google::Protobuf::MessageExts::ClassMethods

## Includes

- Google::Protobuf::MessageExts

## Methods

### #bounding_polys

    def bounding_polys() -> ::Array<::Google::Cloud::Vision::V1::BoundingPoly>

**Returns**

- (::Array\<[::Google::Cloud::Vision::V1::BoundingPoly](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest/Google-Cloud-Vision-V1-BoundingPoly)\>) --- Optional. Bounding polygons around the areas of interest in the reference image. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used.


  The provided shape is converted into a non-rotated rectangle. Once
  converted, the small edge of the rectangle must be greater than or equal
  to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5
  is not).

### #bounding_polys=

    def bounding_polys=(value) -> ::Array<::Google::Cloud::Vision::V1::BoundingPoly>

**Parameter**

- **value** (::Array\<[::Google::Cloud::Vision::V1::BoundingPoly](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest/Google-Cloud-Vision-V1-BoundingPoly)\>) --- Optional. Bounding polygons around the areas of interest in the reference image. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used.


  The provided shape is converted into a non-rotated rectangle. Once
  converted, the small edge of the rectangle must be greater than or equal
  to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5
  is not).
**Returns**

- (::Array\<[::Google::Cloud::Vision::V1::BoundingPoly](https://docs.cloud.google.com/ruby/docs/reference/google-cloud-vision-v1/latest/Google-Cloud-Vision-V1-BoundingPoly)\>) --- Optional. Bounding polygons around the areas of interest in the reference image. If this field is empty, the system will try to detect regions of interest. At most 10 bounding polygons will be used.


  The provided shape is converted into a non-rotated rectangle. Once
  converted, the small edge of the rectangle must be greater than or equal
  to 300 pixels. The aspect ratio must be 1:4 or less (i.e. 1:3 is ok; 1:5
  is not).

### #name

    def name() -> ::String

**Returns**

- (::String) --- The resource name of the reference image.

  Format is:
  `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`.

  This field is ignored when creating a reference image.

### #name=

    def name=(value) -> ::String

**Parameter**

- **value** (::String) --- The resource name of the reference image.


  Format is:
  `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`.

  This field is ignored when creating a reference image.
**Returns**

- (::String) --- The resource name of the reference image.

  Format is:
  `projects/PROJECT_ID/locations/LOC_ID/products/PRODUCT_ID/referenceImages/IMAGE_ID`.

  This field is ignored when creating a reference image.

### #uri

    def uri() -> ::String

**Returns**

- (::String) --- Required. The Google Cloud Storage URI of the reference image.

  The URI must start with `gs://`.

### #uri=

    def uri=(value) -> ::String

**Parameter**

- **value** (::String) --- Required. The Google Cloud Storage URI of the reference image.


  The URI must start with `gs://`.
**Returns**

- (::String) --- Required. The Google Cloud Storage URI of the reference image.

  The URI must start with `gs://`.