Changeset 15064 for branches/EfficientGlobalOptimization/HeuristicLab.Algorithms.EGO/InfillCriteria/PluginExpectedImprovement.cs
- Timestamp:
- 06/26/17 09:10:56 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/EfficientGlobalOptimization/HeuristicLab.Algorithms.EGO/InfillCriteria/PluginExpectedImprovement.cs
r14818 r15064 20 20 #endregion 21 21 22 using System;23 22 using System.Linq; 24 23 using HeuristicLab.Common; 25 24 using HeuristicLab.Core; 25 using HeuristicLab.Encodings.RealVectorEncoding; 26 26 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable; 27 27 using HeuristicLab.Problems.DataAnalysis; … … 32 32 [StorableClass] 33 33 [Item("PluginExpectedImprovement", "Noisy InfillCriterion, Extension of the Expected Improvement by using the minimal prediction on the observed points\n rather than the minimal observed value as described in \n Global optimization based on noisy evaluations: An empirical study of two statistical approaches\r\nEmmanuel Vazqueza, Julien Villemonteixb, Maryan Sidorkiewiczb and Éric Walterc")] 34 public class PluginExpectedImprovement : ExpectedImprovement { 35 34 public class PluginExpectedImprovement : ExpectedImprovementBase { 36 35 37 36 #region HL-Constructors, Serialization and Cloning 38 37 [StorableConstructor] 39 pr ivatePluginExpectedImprovement(bool deserializing) : base(deserializing) { }40 pr ivatePluginExpectedImprovement(PluginExpectedImprovement original, Cloner cloner) : base(original, cloner) { }38 protected PluginExpectedImprovement(bool deserializing) : base(deserializing) { } 39 protected PluginExpectedImprovement(PluginExpectedImprovement original, Cloner cloner) : base(original, cloner) { } 41 40 public PluginExpectedImprovement() { } 42 41 public override IDeepCloneable Clone(Cloner cloner) { … … 45 44 #endregion 46 45 47 protected override void Initialize() { 48 if (ExpensiveMaximization) throw new NotImplementedException("PluginExpectedImprovement for maximization not yet implemented"); 49 var model = RegressionSolution.Model as IConfidenceRegressionModel; 50 if (model == null) throw new ArgumentException("can not calculate EI without confidence measure"); 51 YMin = RegressionSolution.EstimatedTrainingValues.Min(); 46 protected override double FindBestFitness(IConfidenceRegressionSolution solution) { 47 return ExpensiveMaximization ? RegressionSolution.EstimatedTrainingValues.Max() : RegressionSolution.EstimatedTrainingValues.Min(); 48 } 49 50 protected override double Evaluate(RealVector vector, double estimatedFitness, double estimatedStandardDeviation) { 51 return GetEstimatedImprovement(BestFitness, estimatedFitness, estimatedStandardDeviation, ExploitationWeight, ExpensiveMaximization); 52 52 } 53 53 }
Note: See TracChangeset
for help on using the changeset viewer.