class EntityAnnotation extends Message

Set of detected entity features.

Protobuf type Google\Cloud\Vision\V1\EntityAnnotation

Methods

__construct()

No description

string
getMid()

Opaque entity ID. Some IDs may be available in Google Knowledge Graph Search API.

setMid(string $var)

Opaque entity ID. Some IDs may be available in Google Knowledge Graph Search API.

string
getLocale()

The language code for the locale in which the entity textual description is expressed.

setLocale(string $var)

The language code for the locale in which the entity textual description is expressed.

string
getDescription()

Entity textual description, expressed in its locale language.

setDescription(string $var)

Entity textual description, expressed in its locale language.

float
getScore()

Overall score of the result. Range [0, 1].

setScore(float $var)

Overall score of the result. Range [0, 1].

float
getConfidence()

The accuracy of the entity detection in an image.

setConfidence(float $var)

The accuracy of the entity detection in an image.

float
getTopicality()

The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1].

setTopicality(float $var)

The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1].

getBoundingPoly()

Image region to which this entity belongs. Currently not produced for LABEL_DETECTION features. For TEXT_DETECTION (OCR), boundingPolys are produced for the entire text detected in an image region, followed by boundingPolys for each word within the detected text.

setBoundingPoly(BoundingPoly $var)

Image region to which this entity belongs. Currently not produced for LABEL_DETECTION features. For TEXT_DETECTION (OCR), boundingPolys are produced for the entire text detected in an image region, followed by boundingPolys for each word within the detected text.

RepeatedField
getLocations()

The location information for the detected entity. Multiple LocationInfo elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken.

setLocations(array|RepeatedField $var)

The location information for the detected entity. Multiple LocationInfo elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken.

RepeatedField
getProperties()

Some entities may have optional user-supplied Property (name/value) fields, such a score or string that qualifies the entity.

setProperties(array|RepeatedField $var)

Some entities may have optional user-supplied Property (name/value) fields, such a score or string that qualifies the entity.

Details

at line 90
__construct()

at line 102
string getMid()

Opaque entity ID. Some IDs may be available in Google Knowledge Graph Search API.

Generated from protobuf field string mid = 1;

Return Value

string

at line 114
setMid(string $var)

Opaque entity ID. Some IDs may be available in Google Knowledge Graph Search API.

Generated from protobuf field string mid = 1;

Parameters

string $var

at line 127
string getLocale()

The language code for the locale in which the entity textual description is expressed.

Generated from protobuf field string locale = 2;

Return Value

string

at line 139
setLocale(string $var)

The language code for the locale in which the entity textual description is expressed.

Generated from protobuf field string locale = 2;

Parameters

string $var

at line 151
string getDescription()

Entity textual description, expressed in its locale language.

Generated from protobuf field string description = 3;

Return Value

string

at line 162
setDescription(string $var)

Entity textual description, expressed in its locale language.

Generated from protobuf field string description = 3;

Parameters

string $var

at line 174
float getScore()

Overall score of the result. Range [0, 1].

Generated from protobuf field float score = 4;

Return Value

float

at line 185
setScore(float $var)

Overall score of the result. Range [0, 1].

Generated from protobuf field float score = 4;

Parameters

float $var

at line 200
float getConfidence()

The accuracy of the entity detection in an image.

For example, for an image in which the "Eiffel Tower" entity is detected, this field represents the confidence that there is a tower in the query image. Range [0, 1].

Generated from protobuf field float confidence = 5;

Return Value

float

at line 214
setConfidence(float $var)

The accuracy of the entity detection in an image.

For example, for an image in which the "Eiffel Tower" entity is detected, this field represents the confidence that there is a tower in the query image. Range [0, 1].

Generated from protobuf field float confidence = 5;

Parameters

float $var

at line 230
float getTopicality()

The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1].

Generated from protobuf field float topicality = 6;

Return Value

float

at line 245
setTopicality(float $var)

The relevancy of the ICA (Image Content Annotation) label to the image. For example, the relevancy of "tower" is likely higher to an image containing the detected "Eiffel Tower" than to an image containing a detected distant towering building, even though the confidence that there is a tower in each image may be the same. Range [0, 1].

Generated from protobuf field float topicality = 6;

Parameters

float $var

at line 260
BoundingPoly getBoundingPoly()

Image region to which this entity belongs. Currently not produced for LABEL_DETECTION features. For TEXT_DETECTION (OCR), boundingPolys are produced for the entire text detected in an image region, followed by boundingPolys for each word within the detected text.

Generated from protobuf field .google.cloud.vision.v1.BoundingPoly bounding_poly = 7;

Return Value

BoundingPoly

at line 274
setBoundingPoly(BoundingPoly $var)

Image region to which this entity belongs. Currently not produced for LABEL_DETECTION features. For TEXT_DETECTION (OCR), boundingPolys are produced for the entire text detected in an image region, followed by boundingPolys for each word within the detected text.

Generated from protobuf field .google.cloud.vision.v1.BoundingPoly bounding_poly = 7;

Parameters

BoundingPoly $var

at line 290
RepeatedField getLocations()

The location information for the detected entity. Multiple LocationInfo elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken.

Location information is usually present for landmarks.

Generated from protobuf field repeated .google.cloud.vision.v1.LocationInfo locations = 8;

Return Value

RepeatedField

at line 305
setLocations(array|RepeatedField $var)

The location information for the detected entity. Multiple LocationInfo elements can be present because one location may indicate the location of the scene in the image, and another location may indicate the location of the place where the image was taken.

Location information is usually present for landmarks.

Generated from protobuf field repeated .google.cloud.vision.v1.LocationInfo locations = 8;

Parameters

array|RepeatedField $var

at line 318
RepeatedField getProperties()

Some entities may have optional user-supplied Property (name/value) fields, such a score or string that qualifies the entity.

Generated from protobuf field repeated .google.cloud.vision.v1.Property properties = 9;

Return Value

RepeatedField

at line 330
setProperties(array|RepeatedField $var)

Some entities may have optional user-supplied Property (name/value) fields, such a score or string that qualifies the entity.

Generated from protobuf field repeated .google.cloud.vision.v1.Property properties = 9;

Parameters

array|RepeatedField $var