Changeset 13117
- Timestamp:
- 11/04/15 17:28:03 (9 years ago)
- Location:
- branches/ALPS/HeuristicLab.Algorithms.ALPS/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ALPS/HeuristicLab.Algorithms.ALPS/3.3/AlpsGeneticAlgorithm.cs
r13113 r13117 293 293 294 294 Parameters.Add(new ValueParameter<IntValue>("MatingPoolRange", "The range of layers used for creating a mating pool. (1 = current + previous layer)", new IntValue(1)) { Hidden = true }); 295 Parameters.Add(new ValueParameter<BoolValue>("ReduceToPopulationSize", "Reduce the LayerPopulationSize after elder migration to PopulationSize", new BoolValue(true)) { Hidden = true }); 295 296 296 297 Parameters.Add(new ValueParameter<MultiTerminator>("Terminator", "The termination criteria which sould be checked.", new MultiTerminator())); -
branches/ALPS/HeuristicLab.Algorithms.ALPS/3.3/AlpsGeneticAlgorithmMainLoop.cs
r13113 r13117 162 162 var mergingReducer = new MergingReducer(); 163 163 var subScopesCounter = new SubScopesCounter(); 164 var reduceToPopulationSizeBranch = new ConditionalBranch() { Name = "ReduceToPopulationSize?" }; 164 165 var countCalculator = new ExpressionCalculator() { Name = "LayerPopulationSize = Min(LayerPopulationSize, PopulationSize)" }; 165 166 var bestSelector = new BestSelector(); … … 180 181 subScopesCounter.ValueParameter.ActualName = "LayerPopulationSize"; 181 182 subScopesCounter.AccumulateParameter.Value = new BoolValue(false); 182 subScopesCounter.Successor = countCalculator; 183 subScopesCounter.Successor = reduceToPopulationSizeBranch; 184 185 reduceToPopulationSizeBranch.ConditionParameter.ActualName = "ReduceToPopulationSize"; 186 reduceToPopulationSizeBranch.TrueBranch = countCalculator; 183 187 184 188 countCalculator.CollectedValues.Add(new LookupParameter<IntValue>("PopulationSize"));
Note: See TracChangeset
for help on using the changeset viewer.