Changeset 8660 for branches/GP-MoveOperators/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4/SingleObjective/SymbolicClassificationSingleObjectiveTrainingBestSolutionAnalyzer.cs
- Timestamp:
- 09/14/12 18:58:15 (12 years ago)
- Location:
- branches/GP-MoveOperators
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/GP-MoveOperators
- Property svn:ignore
-
old new 21 21 protoc.exe 22 22 _ReSharper.HeuristicLab 3.3 Tests 23 Google.ProtocolBuffers-2.4.1.473.dll
-
- Property svn:mergeinfo changed
- Property svn:ignore
-
branches/GP-MoveOperators/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification
-
Property
svn:mergeinfo
set to
(toggle deleted branches)
/branches/HeuristicLab.TreeSimplifier/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification merged eligible /trunk/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification merged eligible /branches/Algorithms.GradientDescent/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5516-5520 /branches/Benchmarking/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 6917-7005 /branches/CloningRefactoring/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 4656-4721 /branches/DataAnalysis Refactoring/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5471-5808 /branches/DataAnalysis SolutionEnsembles/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5815-6180 /branches/DataAnalysis/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 4458-4459,4462,4464 /branches/GP.Grammar.Editor/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 6284-6795 /branches/GP.Symbols (TimeLag, Diff, Integral)/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5060 /branches/NET40/sources/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5138-5162 /branches/ParallelEngine/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5175-5192 /branches/ProblemInstancesRegressionAndClassification/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 7568-7810 /branches/QAPAlgorithms/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 6350-6627 /branches/Restructure trunk solution/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 6828 /branches/ScatterSearch (trunk integration)/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 7787-8333 /branches/SuccessProgressAnalysis/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5370-5682 /branches/Trunk/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 6829-6865 /branches/VNS/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5594-5752 /branches/histogram/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification 5959-6341
-
Property
svn:mergeinfo
set to
(toggle deleted branches)
-
branches/GP-MoveOperators/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4
- Property svn:ignore
-
old new 1 *.user 2 Plugin.cs 1 3 bin 2 *.user3 HeuristicLabProblemsDataAnalysisSymbolicClassificationPlugin.cs4 4 obj 5 *.vs10x6 Plugin.cs
-
- Property svn:ignore
-
branches/GP-MoveOperators/HeuristicLab.Problems.DataAnalysis.Symbolic.Classification/3.4/SingleObjective/SymbolicClassificationSingleObjectiveTrainingBestSolutionAnalyzer.cs
r7259 r8660 34 34 [StorableClass] 35 35 public sealed class SymbolicClassificationSingleObjectiveTrainingBestSolutionAnalyzer : SymbolicDataAnalysisSingleObjectiveTrainingBestSolutionAnalyzer<ISymbolicClassificationSolution>, 36 ISymbolicDataAnalysisInterpreterOperator, ISymbolicDataAnalysisBoundedOperator {36 ISymbolicDataAnalysisInterpreterOperator, ISymbolicDataAnalysisBoundedOperator, ISymbolicClassificationModelCreatorOperator { 37 37 private const string ProblemDataParameterName = "ProblemData"; 38 private const string ModelCreatorParameterName = "ModelCreator"; 38 39 private const string SymbolicDataAnalysisTreeInterpreterParameterName = "SymbolicDataAnalysisTreeInterpreter"; 39 40 private const string EstimationLimitsParameterName = "UpperEstimationLimit"; … … 42 43 public ILookupParameter<IClassificationProblemData> ProblemDataParameter { 43 44 get { return (ILookupParameter<IClassificationProblemData>)Parameters[ProblemDataParameterName]; } 45 } 46 public IValueLookupParameter<ISymbolicClassificationModelCreator> ModelCreatorParameter { 47 get { return (IValueLookupParameter<ISymbolicClassificationModelCreator>)Parameters[ModelCreatorParameterName]; } 48 } 49 ILookupParameter<ISymbolicClassificationModelCreator> ISymbolicClassificationModelCreatorOperator.ModelCreatorParameter { 50 get { return ModelCreatorParameter; } 44 51 } 45 52 public ILookupParameter<ISymbolicDataAnalysisExpressionTreeInterpreter> SymbolicDataAnalysisTreeInterpreterParameter { … … 65 72 : base() { 66 73 Parameters.Add(new LookupParameter<IClassificationProblemData>(ProblemDataParameterName, "The problem data for the symbolic classification solution.")); 74 Parameters.Add(new ValueLookupParameter<ISymbolicClassificationModelCreator>(ModelCreatorParameterName, "")); 67 75 Parameters.Add(new LookupParameter<ISymbolicDataAnalysisExpressionTreeInterpreter>(SymbolicDataAnalysisTreeInterpreterParameterName, "The symbolic data analysis tree interpreter for the symbolic expression tree.")); 68 76 Parameters.Add(new ValueLookupParameter<DoubleLimit>(EstimationLimitsParameterName, "The lower and upper limit for the estimated values produced by the symbolic classification model.")); 69 77 Parameters.Add(new ValueParameter<BoolValue>(ApplyLinearScalingParameterName, "Flag that indicates if the produced symbolic classification solution should be linearly scaled.", new BoolValue(false))); 70 78 } 79 71 80 public override IDeepCloneable Clone(Cloner cloner) { 72 81 return new SymbolicClassificationSingleObjectiveTrainingBestSolutionAnalyzer(this, cloner); 73 82 } 83 [StorableHook(HookType.AfterDeserialization)] 84 private void AfterDeserialization() { 85 if (!Parameters.ContainsKey(ModelCreatorParameterName)) 86 Parameters.Add(new ValueLookupParameter<ISymbolicClassificationModelCreator>(ModelCreatorParameterName, "")); 87 } 74 88 75 89 protected override ISymbolicClassificationSolution CreateSolution(ISymbolicExpressionTree bestTree, double bestQuality) { 76 var model = new SymbolicDiscriminantFunctionClassificationModel((ISymbolicExpressionTree)bestTree.Clone(), SymbolicDataAnalysisTreeInterpreterParameter.ActualValue, EstimationLimitsParameter.ActualValue.Lower, EstimationLimitsParameter.ActualValue.Upper);77 if (ApplyLinearScaling.Value) {78 SymbolicDiscriminantFunctionClassificationModel.Scale(model, ProblemDataParameter.ActualValue); 79 }80 return new SymbolicDiscriminantFunctionClassificationSolution(model,(IClassificationProblemData)ProblemDataParameter.ActualValue.Clone());90 var model = ModelCreatorParameter.ActualValue.CreateSymbolicClassificationModel((ISymbolicExpressionTree)bestTree.Clone(), SymbolicDataAnalysisTreeInterpreterParameter.ActualValue, EstimationLimitsParameter.ActualValue.Lower, EstimationLimitsParameter.ActualValue.Upper); 91 if (ApplyLinearScaling.Value) SymbolicClassificationModel.Scale(model, ProblemDataParameter.ActualValue); 92 93 model.RecalculateModelParameters(ProblemDataParameter.ActualValue, ProblemDataParameter.ActualValue.TrainingIndices); 94 return model.CreateClassificationSolution((IClassificationProblemData)ProblemDataParameter.ActualValue.Clone()); 81 95 } 82 96 }
Note: See TracChangeset
for help on using the changeset viewer.