Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/15/12 16:47:25 (11 years ago)
Author:
mkommend
Message:

#1763: merged changes from trunk into the tree simplifier branch.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/HeuristicLab.TreeSimplifier/HeuristicLab.Problems.DataAnalysis.Symbolic/3.4/Analyzers/SymbolicDataAnalysisMultiObjectiveAnalyzer.cs

    r7259 r8915  
    2020#endregion
    2121
    22 using System.Collections.Generic;
    23 using System.Linq;
    2422using HeuristicLab.Common;
    2523using HeuristicLab.Core;
    2624using HeuristicLab.Data;
    27 using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding;
    28 using HeuristicLab.Operators;
    2925using HeuristicLab.Parameters;
    3026using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    31 using HeuristicLab.Optimization;
    3227
    3328namespace HeuristicLab.Problems.DataAnalysis.Symbolic {
     
    3934    private const string QualitiesParameterName = "Qualities";
    4035    private const string MaximizationParameterName = "Maximization";
     36    private const string ApplyLinearScalingParameterName = "ApplyLinearScaling";
    4137    #region parameter properties
    4238    public IScopeTreeLookupParameter<DoubleArray> QualitiesParameter {
     
    4541    public ILookupParameter<BoolArray> MaximizationParameter {
    4642      get { return (ILookupParameter<BoolArray>)Parameters[MaximizationParameterName]; }
     43    }
     44    public ILookupParameter<BoolValue> ApplyLinearScalingParameter {
     45      get { return (ILookupParameter<BoolValue>)Parameters[ApplyLinearScalingParameterName]; }
    4746    }
    4847    #endregion
     
    6463      Parameters.Add(new ScopeTreeLookupParameter<DoubleArray>(QualitiesParameterName, "The qualities of the trees that should be analyzed."));
    6564      Parameters.Add(new LookupParameter<BoolArray>(MaximizationParameterName, "The directions of optimization for each dimension."));
     65      Parameters.Add(new LookupParameter<BoolValue>(ApplyLinearScalingParameterName, "Flag that indicates if the individual should be linearly scaled before evaluating."));
     66    }
     67
     68    [StorableHook(HookType.AfterDeserialization)]
     69    private void AfterDeserialization() {
     70      if (Parameters.ContainsKey(ApplyLinearScalingParameterName) && Parameters[ApplyLinearScalingParameterName] is LookupParameter<BoolValue>)
     71        Parameters.Remove(ApplyLinearScalingParameterName);
     72      if (!Parameters.ContainsKey(ApplyLinearScalingParameterName))
     73        Parameters.Add(new LookupParameter<BoolValue>(ApplyLinearScalingParameterName, "Flag that indicates if the individual should be linearly scaled before evaluating."));
    6674    }
    6775  }
Note: See TracChangeset for help on using the changeset viewer.