T
- the type of the optionspublic class HpCategorical<T> extends Hyperparameter<T>
Hyperparameter
which is one of a fixed number of options (similar to an enum).name
Constructor and Description |
---|
HpCategorical(java.lang.String name,
java.util.List<T> categories)
Constructs a
HpCategorical . |
Modifier and Type | Method and Description |
---|---|
T |
random()
Returns a random value for the hyperparameter for a range of a fixed value if it is a
HpVal . |
java.lang.String |
toString() |
getName
public HpCategorical(java.lang.String name, java.util.List<T> categories)
HpCategorical
.name
- the name of the hyperparameterscategories
- the valid values for the hyperparameterpublic T random()
HpVal
.random
in class Hyperparameter<T>
HpVal
public java.lang.String toString()
toString
in class java.lang.Object