Class: Google::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1NearestNeighborsNeighbor

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/aiplatform_v1beta1/classes.rb,
lib/google/apis/aiplatform_v1beta1/representations.rb,
lib/google/apis/aiplatform_v1beta1/representations.rb

Overview

A neighbor of the query vector.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ GoogleCloudAiplatformV1beta1NearestNeighborsNeighbor

Returns a new instance of GoogleCloudAiplatformV1beta1NearestNeighborsNeighbor.



21313
21314
21315
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 21313

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#distanceFloat

The distance between the neighbor and the query vector. Corresponds to the JSON property distance

Returns:

  • (Float)


21301
21302
21303
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 21301

def distance
  @distance
end

#entity_idString

The id of the similar entity. Corresponds to the JSON property entityId

Returns:

  • (String)


21306
21307
21308
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 21306

def entity_id
  @entity_id
end

#entity_key_valuesGoogle::Apis::AiplatformV1beta1::GoogleCloudAiplatformV1beta1FetchFeatureValuesResponse

Response message for FeatureOnlineStoreService.FetchFeatureValues Corresponds to the JSON property entityKeyValues



21311
21312
21313
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 21311

def entity_key_values
  @entity_key_values
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



21318
21319
21320
21321
21322
# File 'lib/google/apis/aiplatform_v1beta1/classes.rb', line 21318

def update!(**args)
  @distance = args[:distance] if args.key?(:distance)
  @entity_id = args[:entity_id] if args.key?(:entity_id)
  @entity_key_values = args[:entity_key_values] if args.key?(:entity_key_values)
end