Changeset 9090 for branches/LearningClassifierSystems/HeuristicLab.Algorithms.LearningClassifierSystems
- Timestamp:
- 12/29/12 20:15:48 (12 years ago)
- Location:
- branches/LearningClassifierSystems/HeuristicLab.Algorithms.LearningClassifierSystems/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/LearningClassifierSystems/HeuristicLab.Algorithms.LearningClassifierSystems/3.3
- Property svn:ignore
-
old new 1 1 *.user 2 2 Plugin.cs 3 obj
-
- Property svn:ignore
-
branches/LearningClassifierSystems/HeuristicLab.Algorithms.LearningClassifierSystems/3.3/LearningClassifierSystemMainLoop.cs
r9089 r9090 54 54 #region private properties 55 55 private SolutionsCreator initialSolutionsCreator; 56 private SolutionsCreator coveringMechanism;57 56 private MatchConditionOperator matchConditionOperator; 58 57 private PredictionArrayCalculator predictionArrayCalculator; 59 58 private ActionSelector actionSelector; 59 private CoveringOperator covering; 60 60 61 61 private Placeholder evaluator; … … 100 100 ConditionalSelector conditionMatchSelector = new ConditionalSelector(); 101 101 ConditionalSelector actionMatchSelector = new ConditionalSelector(); 102 SubScopesProcessor coveringSubScopesProcessor = new SubScopesProcessor(); 103 SubScopesCounter matchsetCounter = new SubScopesCounter(); 104 Comparator comparator = new Comparator(); 105 ConditionalBranch coveringConditionalBranch = new ConditionalBranch(); 102 SubScopesProcessor matchSetSubScopesProcessor = new SubScopesProcessor(); 103 CountNumberOfUniqueActions countNumberOfUniqueActions = new CountNumberOfUniqueActions(); 104 covering = new CoveringOperator(); 106 105 MergingReducer mergingReducer = new MergingReducer(); 107 106 MergingReducer mergingReducerWithSuccessor = new MergingReducer(); 108 coveringMechanism = new SolutionsCreator();109 107 evaluator = new Placeholder(); 110 108 SubScopesProcessor actionSetSubScopesProcessor = new SubScopesProcessor(); … … 137 135 conditionMatchSelector.ConditionParameter.ActualName = "MatchCondition"; 138 136 139 matchsetCounter.Name = "Count number of rules in match set"; 140 matchsetCounter.AccumulateParameter.Value = new BoolValue(false); 141 matchsetCounter.ValueParameter.ActualName = "MatchSetCount"; 142 143 comparator.Comparison = new Comparison(ComparisonType.LessOrEqual); 144 comparator.LeftSideParameter.ActualName = matchsetCounter.ValueParameter.ActualName; 145 comparator.ResultParameter.ActualName = "Covering"; 146 //more than zero solutions have to be selected 147 comparator.RightSideParameter.ActualName = "ZeroIntValue"; 148 149 coveringConditionalBranch.Name = "Covering Branch"; 150 coveringConditionalBranch.ConditionParameter.ActualName = "Covering"; 137 countNumberOfUniqueActions.ClassifiersParameter.ActualName = "CombinedIntegerVector"; 138 139 covering.ActionsInMatchSetParameter.ActualName = countNumberOfUniqueActions.UniqueActionsParameter.ActualName; 140 covering.ParallelParameter.Value.Value = true; 141 covering.RandomParameter.ActualName = "Random"; 151 142 152 143 matchActionSubScopesProcessor.Operator = matchActionOperator; … … 154 145 matchActionOperator.MatchParameter.ActualName = "CombinedIntegerVector"; 155 146 matchActionOperator.TargetMatchParameter.ActualName = actionSelector.SelectedActionParameter.ActualName; 156 157 coveringMechanism.NumberOfSolutionsParameter.ActualName = "OneIntValue";158 147 159 148 predictionArrayCalculator.MatchParameter.ActualName = "CombinedIntegerVector"; … … 211 200 //adaptedGeneticAlgorithmMainLoop.Successor = conditionMatchSelector; 212 201 213 conditionMatchSelector.Successor = coveringSubScopesProcessor; 214 coveringSubScopesProcessor.Operators.Add(new EmptyOperator()); 215 coveringSubScopesProcessor.Operators.Add(matchsetCounter); 216 coveringSubScopesProcessor.Successor = mergingReducerWithSuccessor; 217 matchsetCounter.Successor = comparator; 218 comparator.Successor = coveringConditionalBranch; 219 coveringConditionalBranch.TrueBranch = coveringMechanism; 220 coveringConditionalBranch.FalseBranch = new EmptyOperator(); 221 coveringConditionalBranch.Successor = predictionArrayCalculator; 202 conditionMatchSelector.Successor = matchSetSubScopesProcessor; 203 matchSetSubScopesProcessor.Operators.Add(new EmptyOperator()); 204 matchSetSubScopesProcessor.Operators.Add(countNumberOfUniqueActions); 205 matchSetSubScopesProcessor.Successor = mergingReducerWithSuccessor; 206 countNumberOfUniqueActions.Successor = covering; 207 covering.Successor = predictionArrayCalculator; 222 208 predictionArrayCalculator.Successor = actionSelector; 223 209 actionSelector.Successor = matchActionSubScopesProcessor; … … 253 239 initialSolutionsCreator.EvaluatorParameter.ActualName = problem.EvaluatorParameter.Name; 254 240 255 coveringMechanism.SolutionCreatorParameter.ActualName = problem.SolutionCreatorParameter.Name;256 coveringMechanism.EvaluatorParameter.ActualName = problem.EvaluatorParameter.Name;257 258 241 problem.ActionExecuter.SelectedActionParameter.ActualName = actionSelector.SelectedActionParameter.ActualName; 259 242 … … 266 249 actionExecuter.OperatorParameter.ActualName = problem.ActionExecuterParameter.Name; 267 250 268 matchConditionOperator.TargetMatchParameter.ActualName = problem.ClassifierFetcher.CurrentClassifierToMatchParameter.Name; 251 matchConditionOperator.TargetMatchParameter.ActualName = problem.ClassifierFetcher.CurrentClassifierToMatchParameter.ActualName; 252 253 covering.SolutionCreatorParameter.ActualName = problem.CoveringSolutionCreatorParameter.Name; 254 covering.EvaluatorParameter.ActualName = problem.EvaluatorParameter.Name; 255 covering.MinimalNumberOfUniqueActionsParameter.ActualName = problem.ThetaMinimalNumberOfActionsParameter.Name; 256 covering.PossibleActionsParameter.ActualName = problem.PossibleActionsParameter.Name; 269 257 270 258 predictionArrayCalculator.PredictionParameter.ActualName = problem.Evaluator.PredictionParameter.ActualName;
Note: See TracChangeset
for help on using the changeset viewer.