Record Class BayesianOptimization.Result

java.lang.Object
java.lang.Record
smile.hpo.BayesianOptimization.Result
Record Components:
bestParameters - the best hyperparameter configuration found.
bestValue - the best objective function value achieved.
trials - the full history of evaluated trials.
All Implemented Interfaces:
Serializable
Enclosing class:
BayesianOptimization

public static record BayesianOptimization.Result(Properties bestParameters, double bestValue, List<BayesianOptimization.Trial> trials) extends Record implements Serializable
Result of Bayesian hyperparameter optimization.
See Also:
  • Constructor Details

    • Result

      public Result(Properties bestParameters, double bestValue, List<BayesianOptimization.Trial> trials)
      Creates an instance of a Result record class.
      Parameters:
      bestParameters - the value for the bestParameters record component
      bestValue - the value for the bestValue record component
      trials - the value for the trials record component
  • Method Details

    • best

      public Properties best()
      Returns the best hyperparameter configuration.
      Returns:
      the best hyperparameter configuration.
    • value

      public double value()
      Returns the best objective function value.
      Returns:
      the best objective function value.
    • toString

      public String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared with Objects::equals(Object,Object); primitive components are compared with the compare method from their corresponding wrapper classes.
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • bestParameters

      public Properties bestParameters()
      Returns the value of the bestParameters record component.
      Returns:
      the value of the bestParameters record component
    • bestValue

      public double bestValue()
      Returns the value of the bestValue record component.
      Returns:
      the value of the bestValue record component
    • trials

      public List<BayesianOptimization.Trial> trials()
      Returns the value of the trials record component.
      Returns:
      the value of the trials record component