Cloud Vision V1 Client - Class GroupedResult (1.8.0)

Reference documentation and code samples for the Cloud Vision V1 Client class GroupedResult.

Information about the products similar to a single product in a query image.

Generated from protobuf message google.cloud.vision.v1.ProductSearchResults.GroupedResult

Namespace

Google \ Cloud \ Vision \ V1 \ ProductSearchResults

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ bounding_poly Google\Cloud\Vision\V1\BoundingPoly

The bounding polygon around the product detected in the query image.

↳ results array<Google\Cloud\Vision\V1\ProductSearchResults\Result>

List of results, one for each product match.

↳ object_annotations array<Google\Cloud\Vision\V1\ProductSearchResults\ObjectAnnotation>

List of generic predictions for the object in the bounding box.

getBoundingPoly

The bounding polygon around the product detected in the query image.

Returns
TypeDescription
Google\Cloud\Vision\V1\BoundingPoly|null

hasBoundingPoly

clearBoundingPoly

setBoundingPoly

The bounding polygon around the product detected in the query image.

Parameter
NameDescription
var Google\Cloud\Vision\V1\BoundingPoly
Returns
TypeDescription
$this

getResults

List of results, one for each product match.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setResults

List of results, one for each product match.

Parameter
NameDescription
var array<Google\Cloud\Vision\V1\ProductSearchResults\Result>
Returns
TypeDescription
$this

getObjectAnnotations

List of generic predictions for the object in the bounding box.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setObjectAnnotations

List of generic predictions for the object in the bounding box.

Parameter
NameDescription
var array<Google\Cloud\Vision\V1\ProductSearchResults\ObjectAnnotation>
Returns
TypeDescription
$this