Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
03/24/16 11:01:41 (8 years ago)
Author:
pkuelzer
Message:

#2558
maxLayer default = 10000 instead of 100000 to avoid overflow
layer creator now wipes evaluated Layersolutions
evaluated Solution data reducer assigns the value instead of summing it
changed default age gap to 20
start on generation 1 to avoid immediate reseeding
fixes also done in islandosAlps

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/IslandALPS/IslandALPS/3.3/Offspring Selection/IslandAlpsOffspringSelectionAlgorithmMainLoop.cs

    r13686 r13723  
    294294      #endregion
    295295
    296       globalVariableCreator.CollectedValues.Add(new ValueParameter<IntValue>(GenerationsParametername, new IntValue(0)));
     296      globalVariableCreator.CollectedValues.Add(new ValueParameter<IntValue>(GenerationsParametername, new IntValue(1)));
    297297      globalVariableCreator.CollectedValues.Add(new ValueParameter<IntValue>(MigrationsParametername, new IntValue(0)));
    298298
     
    322322      incrementEvaluatedSolutionDr.TargetParameter.ActualName = EvaluatedSolutions.Name;
    323323      incrementEvaluatedSolutionDr.ReductionOperation.Value = new ReductionOperation(ReductionOperations.Sum);
    324       incrementEvaluatedSolutionDr.TargetOperation.Value = new ReductionOperation(ReductionOperations.Sum);
     324      incrementEvaluatedSolutionDr.TargetOperation.Value = new ReductionOperation(ReductionOperations.Assign);
    325325
    326326      setIslandEvaluatedSolutions.ParameterToReduce.ActualName = LayerEvaluatedSolutionsParameter.Name;
     
    577577      var updateLayerNumber = new Assigner {Name = "Layer = OpenLayers"};
    578578      var historyWiper = new ResultsHistoryWiper {Name = "Clear History in Results"};
     579      var evaluatedSolutionsWiper = new Assigner() { Name = "Clear evaluated Solutions" };
    579580      var createChildrenViaCrossover = new AlpsOffspringSelectionGeneticAlgorithmMainOperator();
    580581      var incrEvaluatedSolutionsForNewLayer = new SubScopesCounter {Name = "Update EvaluatedSolutions"};
     
    612613
    613614      historyWiper.ResultsParameter.ActualName = "LayerResults";
    614       historyWiper.Successor = createChildrenViaCrossover;
     615      historyWiper.Successor = evaluatedSolutionsWiper;
     616      evaluatedSolutionsWiper.LeftSideParameter.ActualName = LayerEvaluatedSolutionsParameterName;
     617      evaluatedSolutionsWiper.RightSideParameter.Value = new IntValue(0);
     618      evaluatedSolutionsWiper.Successor = createChildrenViaCrossover;
    615619
    616620      // Maybe use only crossover and no elitism instead of "default operator"
Note: See TracChangeset for help on using the changeset viewer.