[10072] | 1 | #region License Information
|
---|
| 2 | /* HeuristicLab
|
---|
[17226] | 3 | * Copyright (C) Heuristic and Evolutionary Algorithms Laboratory (HEAL)
|
---|
[10072] | 4 | *
|
---|
| 5 | * This file is part of HeuristicLab.
|
---|
| 6 | *
|
---|
| 7 | * HeuristicLab is free software: you can redistribute it and/or modify
|
---|
| 8 | * it under the terms of the GNU General Public License as published by
|
---|
| 9 | * the Free Software Foundation, either version 3 of the License, or
|
---|
| 10 | * (at your option) any later version.
|
---|
| 11 | *
|
---|
| 12 | * HeuristicLab is distributed in the hope that it will be useful,
|
---|
| 13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of
|
---|
| 14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
---|
| 15 | * GNU General Public License for more details.
|
---|
| 16 | *
|
---|
| 17 | * You should have received a copy of the GNU General Public License
|
---|
| 18 | * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
|
---|
[10968] | 19 | *
|
---|
| 20 | * Author: Sabine Winkler
|
---|
[10072] | 21 | */
|
---|
[10968] | 22 |
|
---|
[10072] | 23 | #endregion
|
---|
| 24 |
|
---|
| 25 | using System;
|
---|
| 26 | using System.Drawing;
|
---|
| 27 | using System.Linq;
|
---|
[17695] | 28 | using HEAL.Attic;
|
---|
[10072] | 29 | using HeuristicLab.Common;
|
---|
| 30 | using HeuristicLab.Common.Resources;
|
---|
| 31 | using HeuristicLab.Core;
|
---|
| 32 | using HeuristicLab.Data;
|
---|
[10073] | 33 | using HeuristicLab.Encodings.IntegerVectorEncoding;
|
---|
[10072] | 34 | using HeuristicLab.Encodings.SymbolicExpressionTreeEncoding;
|
---|
| 35 | using HeuristicLab.Optimization;
|
---|
| 36 | using HeuristicLab.Parameters;
|
---|
| 37 | using HeuristicLab.PluginInfrastructure;
|
---|
[10073] | 38 | using HeuristicLab.Problems.DataAnalysis;
|
---|
| 39 | using HeuristicLab.Problems.DataAnalysis.Symbolic;
|
---|
| 40 | using HeuristicLab.Problems.GrammaticalEvolution.Mappers;
|
---|
[10072] | 41 | using HeuristicLab.Problems.Instances;
|
---|
| 42 |
|
---|
[10073] | 43 | namespace HeuristicLab.Problems.GrammaticalEvolution {
|
---|
[16723] | 44 | [StorableType("E31AC1E8-590D-4D65-883F-3113544B6C91")]
|
---|
[17695] | 45 | public abstract class GESymbolicDataAnalysisProblem<T, U> : HeuristicOptimizationProblem<U>, IDataAnalysisProblem<T>,
|
---|
[10226] | 46 | IGESymbolicDataAnalysisProblem, IStorableContent,
|
---|
[10075] | 47 | IProblemInstanceConsumer<T>, IProblemInstanceExporter<T>
|
---|
[10072] | 48 | where T : class, IDataAnalysisProblemData
|
---|
[17695] | 49 | where U : class, IGESymbolicDataAnalysisEvaluator<T> {
|
---|
[10072] | 50 |
|
---|
| 51 | #region parameter names & descriptions
|
---|
| 52 | private const string ProblemDataParameterName = "ProblemData";
|
---|
| 53 | private const string SymbolicExpressionTreeGrammarParameterName = "SymbolicExpressionTreeGrammar";
|
---|
| 54 | private const string SymbolicExpressionTreeInterpreterParameterName = "SymbolicExpressionTreeInterpreter";
|
---|
| 55 | private const string MaximumSymbolicExpressionTreeLengthParameterName = "MaximumSymbolicExpressionTreeLength";
|
---|
| 56 | private const string RelativeNumberOfEvaluatedSamplesParameterName = "RelativeNumberOfEvaluatedSamples";
|
---|
| 57 | private const string FitnessCalculationPartitionParameterName = "FitnessCalculationPartition";
|
---|
| 58 | private const string ValidationPartitionParameterName = "ValidationPartition";
|
---|
| 59 | private const string ApplyLinearScalingParameterName = "ApplyLinearScaling";
|
---|
[10073] | 60 | private const string BoundsParameterName = "Bounds";
|
---|
| 61 | private const string GenotypeToPhenotypeMapperParameterName = "GenotypeToPhenotypeMapper";
|
---|
[10072] | 62 | private const string ProblemDataParameterDescription = "";
|
---|
| 63 | private const string SymbolicExpressionTreeGrammarParameterDescription = "The grammar that should be used for symbolic expression tree.";
|
---|
[10974] | 64 | private const string SymbolicExpressionTreeInterpreterParameterDescription = "The interpreter that should be used to evaluate the symbolic expression tree.";
|
---|
[10072] | 65 | private const string MaximumSymbolicExpressionTreeLengthParameterDescription = "Maximal length of the symbolic expression.";
|
---|
| 66 | private const string RelativeNumberOfEvaluatedSamplesParameterDescription = "The relative number of samples of the dataset partition, which should be randomly chosen for evaluation.";
|
---|
| 67 | private const string FitnessCalculationPartitionParameterDescription = "The partition of the problem data training partition, that should be used to calculate the fitness of an individual.";
|
---|
| 68 | private const string ValidationPartitionParameterDescription = "The partition of the problem data training partition, that should be used to select the best model from (optional).";
|
---|
| 69 | private const string ApplyLinearScalingParameterDescription = "Flag that indicates if the individual should be linearly scaled before evaluating.";
|
---|
[10073] | 70 | private const string BoundsParameterDescription = "The integer number range in which the single genomes of a genotype are created.";
|
---|
| 71 | private const string GenotypeToPhenotypeMapperParameterDescription = "Maps the genotype (an integer vector) to the phenotype (a symbolic expression tree).";
|
---|
[10072] | 72 | #endregion
|
---|
| 73 |
|
---|
| 74 | #region parameter properties
|
---|
| 75 | public IValueParameter<T> ProblemDataParameter {
|
---|
| 76 | get { return (IValueParameter<T>)Parameters[ProblemDataParameterName]; }
|
---|
| 77 | }
|
---|
[10974] | 78 | public IValueParameter<ISymbolicDataAnalysisGrammar> SymbolicExpressionTreeGrammarParameter {
|
---|
| 79 | get { return (IValueParameter<ISymbolicDataAnalysisGrammar>)Parameters[SymbolicExpressionTreeGrammarParameterName]; }
|
---|
[10072] | 80 | }
|
---|
| 81 | public IValueParameter<ISymbolicDataAnalysisExpressionTreeInterpreter> SymbolicExpressionTreeInterpreterParameter {
|
---|
| 82 | get { return (IValueParameter<ISymbolicDataAnalysisExpressionTreeInterpreter>)Parameters[SymbolicExpressionTreeInterpreterParameterName]; }
|
---|
| 83 | }
|
---|
| 84 | public IFixedValueParameter<IntValue> MaximumSymbolicExpressionTreeLengthParameter {
|
---|
| 85 | get { return (IFixedValueParameter<IntValue>)Parameters[MaximumSymbolicExpressionTreeLengthParameterName]; }
|
---|
| 86 | }
|
---|
| 87 | public IFixedValueParameter<PercentValue> RelativeNumberOfEvaluatedSamplesParameter {
|
---|
| 88 | get { return (IFixedValueParameter<PercentValue>)Parameters[RelativeNumberOfEvaluatedSamplesParameterName]; }
|
---|
| 89 | }
|
---|
| 90 | public IFixedValueParameter<IntRange> FitnessCalculationPartitionParameter {
|
---|
| 91 | get { return (IFixedValueParameter<IntRange>)Parameters[FitnessCalculationPartitionParameterName]; }
|
---|
| 92 | }
|
---|
| 93 | public IFixedValueParameter<IntRange> ValidationPartitionParameter {
|
---|
| 94 | get { return (IFixedValueParameter<IntRange>)Parameters[ValidationPartitionParameterName]; }
|
---|
| 95 | }
|
---|
| 96 | public IFixedValueParameter<BoolValue> ApplyLinearScalingParameter {
|
---|
| 97 | get { return (IFixedValueParameter<BoolValue>)Parameters[ApplyLinearScalingParameterName]; }
|
---|
| 98 | }
|
---|
[10073] | 99 | public IValueParameter<IntMatrix> BoundsParameter {
|
---|
| 100 | get { return (IValueParameter<IntMatrix>)Parameters[BoundsParameterName]; }
|
---|
| 101 | }
|
---|
| 102 | public IValueParameter<IGenotypeToPhenotypeMapper> GenotypeToPhenotypeMapperParameter {
|
---|
| 103 | get { return (IValueParameter<IGenotypeToPhenotypeMapper>)Parameters[GenotypeToPhenotypeMapperParameterName]; }
|
---|
| 104 | }
|
---|
[10072] | 105 | #endregion
|
---|
| 106 |
|
---|
| 107 | #region properties
|
---|
| 108 | public string Filename { get; set; }
|
---|
| 109 | public static new Image StaticItemImage { get { return VSImageLibrary.Type; } }
|
---|
| 110 |
|
---|
| 111 | IDataAnalysisProblemData IDataAnalysisProblem.ProblemData {
|
---|
| 112 | get { return ProblemData; }
|
---|
| 113 | }
|
---|
| 114 | public T ProblemData {
|
---|
| 115 | get { return ProblemDataParameter.Value; }
|
---|
| 116 | set { ProblemDataParameter.Value = value; }
|
---|
| 117 | }
|
---|
| 118 |
|
---|
[10974] | 119 | public ISymbolicDataAnalysisGrammar SymbolicExpressionTreeGrammar {
|
---|
[10072] | 120 | get { return SymbolicExpressionTreeGrammarParameter.Value; }
|
---|
| 121 | set { SymbolicExpressionTreeGrammarParameter.Value = value; }
|
---|
| 122 | }
|
---|
| 123 | public ISymbolicDataAnalysisExpressionTreeInterpreter SymbolicExpressionTreeInterpreter {
|
---|
| 124 | get { return SymbolicExpressionTreeInterpreterParameter.Value; }
|
---|
| 125 | set { SymbolicExpressionTreeInterpreterParameter.Value = value; }
|
---|
| 126 | }
|
---|
| 127 |
|
---|
| 128 | public IntValue MaximumSymbolicExpressionTreeLength {
|
---|
| 129 | get { return MaximumSymbolicExpressionTreeLengthParameter.Value; }
|
---|
| 130 | }
|
---|
[10276] | 131 |
|
---|
[10072] | 132 | public PercentValue RelativeNumberOfEvaluatedSamples {
|
---|
| 133 | get { return RelativeNumberOfEvaluatedSamplesParameter.Value; }
|
---|
| 134 | }
|
---|
| 135 |
|
---|
| 136 | public IntRange FitnessCalculationPartition {
|
---|
| 137 | get { return FitnessCalculationPartitionParameter.Value; }
|
---|
| 138 | }
|
---|
| 139 | public IntRange ValidationPartition {
|
---|
| 140 | get { return ValidationPartitionParameter.Value; }
|
---|
| 141 | }
|
---|
| 142 | public BoolValue ApplyLinearScaling {
|
---|
| 143 | get { return ApplyLinearScalingParameter.Value; }
|
---|
| 144 | }
|
---|
| 145 | #endregion
|
---|
| 146 |
|
---|
| 147 | [StorableConstructor]
|
---|
[16723] | 148 | protected GESymbolicDataAnalysisProblem(StorableConstructorFlag _) : base(_) { }
|
---|
[10072] | 149 | [StorableHook(HookType.AfterDeserialization)]
|
---|
| 150 | private void AfterDeserialization() {
|
---|
| 151 | RegisterEventHandlers();
|
---|
| 152 | }
|
---|
[17695] | 153 | protected GESymbolicDataAnalysisProblem(GESymbolicDataAnalysisProblem<T, U> original, Cloner cloner)
|
---|
[10072] | 154 | : base(original, cloner) {
|
---|
| 155 | RegisterEventHandlers();
|
---|
| 156 | }
|
---|
| 157 |
|
---|
[17695] | 158 | protected GESymbolicDataAnalysisProblem(T problemData, U evaluator)
|
---|
| 159 | : base(evaluator) {
|
---|
[10072] | 160 | Parameters.Add(new ValueParameter<T>(ProblemDataParameterName, ProblemDataParameterDescription, problemData));
|
---|
[10974] | 161 | Parameters.Add(new ValueParameter<ISymbolicDataAnalysisGrammar>(SymbolicExpressionTreeGrammarParameterName, SymbolicExpressionTreeGrammarParameterDescription));
|
---|
| 162 | Parameters.Add(new ValueParameter<ISymbolicDataAnalysisExpressionTreeInterpreter>(SymbolicExpressionTreeInterpreterParameterName, SymbolicExpressionTreeInterpreterParameterDescription));
|
---|
[10072] | 163 | Parameters.Add(new FixedValueParameter<IntValue>(MaximumSymbolicExpressionTreeLengthParameterName, MaximumSymbolicExpressionTreeLengthParameterDescription));
|
---|
| 164 | Parameters.Add(new FixedValueParameter<IntRange>(FitnessCalculationPartitionParameterName, FitnessCalculationPartitionParameterDescription));
|
---|
| 165 | Parameters.Add(new FixedValueParameter<IntRange>(ValidationPartitionParameterName, ValidationPartitionParameterDescription));
|
---|
| 166 | Parameters.Add(new FixedValueParameter<PercentValue>(RelativeNumberOfEvaluatedSamplesParameterName, RelativeNumberOfEvaluatedSamplesParameterDescription, new PercentValue(1)));
|
---|
| 167 | Parameters.Add(new FixedValueParameter<BoolValue>(ApplyLinearScalingParameterName, ApplyLinearScalingParameterDescription, new BoolValue(false)));
|
---|
[10073] | 168 | IntMatrix m = new IntMatrix(new int[,] { { 0, 100 } });
|
---|
| 169 | Parameters.Add(new ValueParameter<IntMatrix>(BoundsParameterName, BoundsParameterDescription, m));
|
---|
| 170 | Parameters.Add(new ValueParameter<IGenotypeToPhenotypeMapper>(GenotypeToPhenotypeMapperParameterName, GenotypeToPhenotypeMapperParameterDescription, new DepthFirstMapper()));
|
---|
[10072] | 171 |
|
---|
| 172 | SymbolicExpressionTreeInterpreterParameter.Hidden = true;
|
---|
| 173 | ApplyLinearScalingParameter.Hidden = true;
|
---|
| 174 |
|
---|
[16692] | 175 | if (problemData.AllowedInputVariables.Any(name => !problemData.Dataset.VariableHasType<double>(name))) throw new NotSupportedException("Categorical variables are not supported");
|
---|
[10268] | 176 | SymbolicExpressionTreeGrammar = new GESymbolicExpressionGrammar(problemData.AllowedInputVariables, problemData.AllowedInputVariables.Count() * 3);
|
---|
[10072] | 177 | SymbolicExpressionTreeInterpreter = new SymbolicDataAnalysisExpressionTreeLinearInterpreter();
|
---|
| 178 |
|
---|
| 179 | FitnessCalculationPartition.Start = ProblemData.TrainingPartition.Start;
|
---|
| 180 | FitnessCalculationPartition.End = ProblemData.TrainingPartition.End;
|
---|
| 181 |
|
---|
| 182 | InitializeOperators();
|
---|
| 183 |
|
---|
| 184 | UpdateGrammar();
|
---|
| 185 | RegisterEventHandlers();
|
---|
| 186 | }
|
---|
| 187 |
|
---|
[10268] | 188 | private void DeregisterGrammarHandler() {
|
---|
| 189 | SymbolicExpressionTreeGrammarParameter.ValueChanged -= SymbolicExpressionTreeGrammarParameter_ValueChanged;
|
---|
| 190 | }
|
---|
| 191 | private void RegisterGrammarHandler() {
|
---|
| 192 | SymbolicExpressionTreeGrammarParameter.ValueChanged += SymbolicExpressionTreeGrammarParameter_ValueChanged;
|
---|
| 193 | }
|
---|
| 194 |
|
---|
[10974] | 195 | private void UpdateGrammar() {
|
---|
[10268] | 196 | DeregisterGrammarHandler();
|
---|
| 197 | // create a new grammar instance with the correct allowed input variables
|
---|
| 198 | SymbolicExpressionTreeGrammarParameter.Value =
|
---|
| 199 | new GESymbolicExpressionGrammar(ProblemData.AllowedInputVariables, ProblemData.AllowedInputVariables.Count() * 3);
|
---|
| 200 | RegisterGrammarHandler();
|
---|
[10072] | 201 | }
|
---|
| 202 |
|
---|
| 203 | private void InitializeOperators() {
|
---|
[10974] | 204 | Operators.AddRange(ApplicationManager.Manager.GetInstances<IIntegerVectorOperator>());
|
---|
[10072] | 205 | Operators.Add(new SymbolicExpressionSymbolFrequencyAnalyzer());
|
---|
| 206 | Operators.Add(new SymbolicDataAnalysisVariableFrequencyAnalyzer());
|
---|
| 207 | Operators.Add(new MinAverageMaxSymbolicExpressionTreeLengthAnalyzer());
|
---|
| 208 | Operators.Add(new SymbolicExpressionTreeLengthAnalyzer());
|
---|
| 209 | ParameterizeOperators();
|
---|
| 210 | }
|
---|
| 211 |
|
---|
| 212 | #region events
|
---|
| 213 | private void RegisterEventHandlers() {
|
---|
| 214 | ProblemDataParameter.ValueChanged += new EventHandler(ProblemDataParameter_ValueChanged);
|
---|
| 215 | ProblemDataParameter.Value.Changed += (object sender, EventArgs e) => OnProblemDataChanged();
|
---|
| 216 |
|
---|
[10268] | 217 | RegisterGrammarHandler();
|
---|
[10072] | 218 | }
|
---|
| 219 |
|
---|
| 220 | private void ProblemDataParameter_ValueChanged(object sender, EventArgs e) {
|
---|
| 221 | ValidationPartition.Start = 0;
|
---|
| 222 | ValidationPartition.End = 0;
|
---|
| 223 | ProblemDataParameter.Value.Changed += (object s, EventArgs args) => OnProblemDataChanged();
|
---|
| 224 | OnProblemDataChanged();
|
---|
| 225 | }
|
---|
| 226 |
|
---|
| 227 | private void SymbolicExpressionTreeGrammarParameter_ValueChanged(object sender, EventArgs e) {
|
---|
| 228 | UpdateGrammar();
|
---|
| 229 | }
|
---|
| 230 |
|
---|
[10073] | 231 | protected override void OnEvaluatorChanged() {
|
---|
| 232 | base.OnEvaluatorChanged();
|
---|
| 233 | Evaluator.SymbolicExpressionTreeParameter.ActualNameChanged += new EventHandler(Evaluator_SymbolicExpressionTreeParameter_ActualNameChanged);
|
---|
[10072] | 234 | ParameterizeOperators();
|
---|
| 235 | }
|
---|
| 236 |
|
---|
[10073] | 237 | private void Evaluator_SymbolicExpressionTreeParameter_ActualNameChanged(object sender, EventArgs e) {
|
---|
[10072] | 238 | ParameterizeOperators();
|
---|
| 239 | }
|
---|
| 240 |
|
---|
| 241 | public event EventHandler ProblemDataChanged;
|
---|
| 242 | protected virtual void OnProblemDataChanged() {
|
---|
| 243 | FitnessCalculationPartition.Start = ProblemData.TrainingPartition.Start;
|
---|
| 244 | FitnessCalculationPartition.End = ProblemData.TrainingPartition.End;
|
---|
| 245 |
|
---|
| 246 | UpdateGrammar();
|
---|
| 247 | ParameterizeOperators();
|
---|
| 248 |
|
---|
| 249 | var handler = ProblemDataChanged;
|
---|
| 250 | if (handler != null) handler(this, EventArgs.Empty);
|
---|
| 251 |
|
---|
| 252 | OnReset();
|
---|
| 253 | }
|
---|
| 254 | #endregion
|
---|
| 255 |
|
---|
| 256 | protected virtual void ParameterizeOperators() {
|
---|
| 257 | var operators = Parameters.OfType<IValueParameter>().Select(p => p.Value).OfType<IOperator>().Union(Operators).ToList();
|
---|
| 258 |
|
---|
| 259 | foreach (var op in operators.OfType<ISymbolicExpressionTreeGrammarBasedOperator>()) {
|
---|
| 260 | op.SymbolicExpressionTreeGrammarParameter.ActualName = SymbolicExpressionTreeGrammarParameter.Name;
|
---|
| 261 | }
|
---|
[10073] | 262 | foreach (var op in operators.OfType<IGESymbolicDataAnalysisEvaluator<T>>()) {
|
---|
[10072] | 263 | op.ProblemDataParameter.ActualName = ProblemDataParameterName;
|
---|
[10073] | 264 | op.SymbolicExpressionTreeParameter.ActualName = Evaluator.SymbolicExpressionTreeParameter.ActualName;
|
---|
[10072] | 265 | op.EvaluationPartitionParameter.ActualName = FitnessCalculationPartitionParameter.Name;
|
---|
| 266 | op.RelativeNumberOfEvaluatedSamplesParameter.ActualName = RelativeNumberOfEvaluatedSamplesParameter.Name;
|
---|
| 267 | op.ApplyLinearScalingParameter.ActualName = ApplyLinearScalingParameter.Name;
|
---|
[17695] | 268 | //op.IntegerVectorParameter.ActualName = SolutionCreator.IntegerVectorParameter.Name;
|
---|
[10075] | 269 | op.GenotypeToPhenotypeMapperParameter.ActualName = GenotypeToPhenotypeMapperParameter.Name;
|
---|
| 270 | op.SymbolicExpressionTreeGrammarParameter.ActualName = SymbolicExpressionTreeGrammarParameter.Name;
|
---|
[10072] | 271 | }
|
---|
[10073] | 272 | foreach (var op in operators.OfType<IIntegerVectorCrossover>()) {
|
---|
[17695] | 273 | //op.ParentsParameter.ActualName = SolutionCreator.IntegerVectorParameter.ActualName;
|
---|
| 274 | //op.ChildParameter.ActualName = SolutionCreator.IntegerVectorParameter.ActualName;
|
---|
[10072] | 275 | }
|
---|
[10073] | 276 | foreach (var op in operators.OfType<IIntegerVectorManipulator>()) {
|
---|
[17695] | 277 | //op.IntegerVectorParameter.ActualName = SolutionCreator.IntegerVectorParameter.ActualName;
|
---|
[10072] | 278 | }
|
---|
[10073] | 279 | foreach (var op in operators.OfType<IIntegerVectorCreator>()) {
|
---|
| 280 | op.BoundsParameter.ActualName = BoundsParameter.Name;
|
---|
| 281 | op.LengthParameter.ActualName = MaximumSymbolicExpressionTreeLengthParameter.Name;
|
---|
| 282 | }
|
---|
[10072] | 283 | foreach (var op in operators.OfType<ISymbolicExpressionTreeAnalyzer>()) {
|
---|
[10073] | 284 | op.SymbolicExpressionTreeParameter.ActualName = Evaluator.SymbolicExpressionTreeParameter.ActualName;
|
---|
[10072] | 285 | }
|
---|
| 286 | foreach (var op in operators.OfType<ISymbolicDataAnalysisSingleObjectiveAnalyzer>()) {
|
---|
| 287 | op.ApplyLinearScalingParameter.ActualName = ApplyLinearScalingParameter.Name;
|
---|
| 288 | }
|
---|
| 289 | foreach (var op in operators.OfType<ISymbolicDataAnalysisMultiObjectiveAnalyzer>()) {
|
---|
| 290 | op.ApplyLinearScalingParameter.ActualName = ApplyLinearScalingParameter.Name;
|
---|
| 291 | }
|
---|
| 292 | foreach (var op in operators.OfType<ISymbolicDataAnalysisAnalyzer>()) {
|
---|
[10073] | 293 | op.SymbolicExpressionTreeParameter.ActualName = Evaluator.SymbolicExpressionTreeParameter.ActualName;
|
---|
[10072] | 294 | }
|
---|
[10073] | 295 | foreach (var op in operators.OfType<IGESymbolicDataAnalysisValidationAnalyzer<U, T>>()) {
|
---|
[10072] | 296 | op.RelativeNumberOfEvaluatedSamplesParameter.ActualName = RelativeNumberOfEvaluatedSamplesParameter.Name;
|
---|
| 297 | op.ValidationPartitionParameter.ActualName = ValidationPartitionParameter.Name;
|
---|
| 298 | }
|
---|
| 299 | foreach (var op in operators.OfType<ISymbolicDataAnalysisInterpreterOperator>()) {
|
---|
| 300 | op.SymbolicDataAnalysisTreeInterpreterParameter.ActualName = SymbolicExpressionTreeInterpreterParameter.Name;
|
---|
| 301 | }
|
---|
| 302 | }
|
---|
| 303 |
|
---|
| 304 | #region Import & Export
|
---|
| 305 | public virtual void Load(T data) {
|
---|
| 306 | Name = data.Name;
|
---|
| 307 | Description = data.Description;
|
---|
| 308 | ProblemData = data;
|
---|
| 309 | }
|
---|
| 310 |
|
---|
| 311 | public virtual T Export() {
|
---|
| 312 | return ProblemData;
|
---|
| 313 | }
|
---|
| 314 | #endregion
|
---|
| 315 | }
|
---|
| 316 | }
|
---|