Class HyperparameterOptimizationResult<T>
Contains the results of a hyperparameter optimization process.
public class HyperparameterOptimizationResult<T>
Type Parameters
TThe numeric data type used for calculations.
- Inheritance
-
HyperparameterOptimizationResult<T>
- Inherited Members
Remarks
For Beginners: This stores everything about a hyperparameter search, including the best hyperparameters found and all the trials that were run.
Constructors
HyperparameterOptimizationResult()
Initializes a new instance of the HyperparameterOptimizationResult class.
public HyperparameterOptimizationResult()
Properties
AllTrials
Gets or sets all trials performed.
public List<HyperparameterTrial<T>> AllTrials { get; set; }
Property Value
BestObjectiveValue
Gets or sets the best objective value achieved.
public T? BestObjectiveValue { get; set; }
Property Value
- T
BestParameters
Gets or sets the best hyperparameter values.
public Dictionary<string, object> BestParameters { get; set; }
Property Value
BestTrial
Gets or sets the best trial found during optimization.
public HyperparameterTrial<T>? BestTrial { get; set; }
Property Value
CompletedTrials
Gets or sets the number of completed trials.
public int CompletedTrials { get; set; }
Property Value
EndTime
Gets or sets the end time of optimization.
public DateTime EndTime { get; set; }
Property Value
FailedTrials
Gets or sets the number of failed trials.
public int FailedTrials { get; set; }
Property Value
PrunedTrials
Gets or sets the number of pruned trials.
public int PrunedTrials { get; set; }
Property Value
SearchSpace
Gets or sets the search space that was used.
public HyperparameterSearchSpace SearchSpace { get; set; }
Property Value
StartTime
Gets or sets the start time of optimization.
public DateTime StartTime { get; set; }
Property Value
TotalTime
Gets or sets the total optimization time.
public TimeSpan TotalTime { get; set; }
Property Value
TotalTrials
Gets or sets the total number of trials run.
public int TotalTrials { get; set; }
Property Value
Methods
GetOptimizationHistory()
Gets the optimization history as a list of (trial number, objective value) pairs.
public List<(int TrialNumber, T ObjectiveValue)> GetOptimizationHistory()
Returns
- List<(int TrialNumber, T ObjectiveValue)>
GetTopTrials(int, bool)
Gets the top N trials by objective value.
public List<HyperparameterTrial<T>> GetTopTrials(int n, bool maximize = true)