Changeset 11081 for trunk/sources
- Timestamp:
- 07/03/14 14:05:56 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/sources/HeuristicLab.Problems.ParameterOptimization/3.3/BestSolutionsAnalyzer.cs
r11077 r11081 121 121 var bestSolutions = (ItemSet<DoubleArray>)results[BestSolutionsResultName].Value; 122 122 //clear best solutions if new found quality is better than the existing one 123 if (max && bestQuality > previousBestQuality 124 || !max && bestQuality < previousBestQuality) 123 if (max && bestQuality > previousBestQuality || !max && bestQuality < previousBestQuality) 125 124 bestSolutions.Clear(); 126 125 … … 134 133 } 135 134 } 136 PreviousBestQualityParameter.ActualValue = (DoubleValue)BestQualityParameter.ActualValue.Clone();137 135 136 //update best quality 137 if (max && bestQuality >= BestQualityParameter.ActualValue.Value 138 || !max && bestQuality <= BestQualityParameter.ActualValue.Value) { 139 BestQualityParameter.ActualValue.Value = bestQuality; 140 } 138 141 //update best known quality 139 142 if (bestKnownQuality == null || max && bestQuality > bestKnownQuality.Value … … 141 144 BestKnownQualityParameter.ActualValue = new DoubleValue(bestQuality); 142 145 } 146 PreviousBestQualityParameter.ActualValue = (DoubleValue)BestQualityParameter.ActualValue.Clone(); 143 147 144 148 return base.Apply();
Note: See TracChangeset
for help on using the changeset viewer.