Class: Google::Apis::PredictionV1_5::Output::OutputMulti

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ OutputMulti

Returns a new instance of OutputMulti



490
491
492
# File 'generated/google/apis/prediction_v1_5/classes.rb', line 490

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

Instance Attribute Details

#labelString

The class label. Corresponds to the JSON property label

Returns:

  • (String)


483
484
485
# File 'generated/google/apis/prediction_v1_5/classes.rb', line 483

def label
  @label
end

#scoreFloat

The probability of the class label. Corresponds to the JSON property score

Returns:

  • (Float)


488
489
490
# File 'generated/google/apis/prediction_v1_5/classes.rb', line 488

def score
  @score
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



495
496
497
498
# File 'generated/google/apis/prediction_v1_5/classes.rb', line 495

def update!(**args)
  @label = args[:label] if args.key?(:label)
  @score = args[:score] if args.key?(:score)
end