Changeset 17896 for branches/3073_IA_constraint_splitting_reintegration/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/ShapeConstraints.cs
- Timestamp:
- 03/16/21 11:08:18 (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3073_IA_constraint_splitting_reintegration/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/ShapeConstraints.cs
r17891 r17896 2 2 3 3 /* HeuristicLab 4 * Copyright (C) 2002-2019Heuristic and Evolutionary Algorithms Laboratory (HEAL)4 * Copyright (C) Heuristic and Evolutionary Algorithms Laboratory (HEAL) 5 5 * 6 6 * This file is part of HeuristicLab. … … 33 33 [Item("ShapeConstraints", "Represents shape constraints associated with a regression problem data e.g. monotonicity constraints.")] 34 34 public class ShapeConstraints : CheckedItemList<ShapeConstraint> { 35 // private static readonly string exampleInput = "# Example for a target variable constraint:" + Environment.NewLine +36 // "f in [0 .. 100]" + Environment.NewLine + Environment.NewLine +37 // "# Example for constraints on model parameters: " + Environment.NewLine +38 // "df/d'x' in [0 .. 10]" + Environment.NewLine +39 // "∂²f/∂'x'² in [-1 .. inf.]";40 //41 // [Storable]42 // private string input;43 44 // public string Input {45 // get => input;46 // set {47 // if (input == value) return;48 // input = value;49 // OnChanged();50 // }51 // }52 53 // [Storable]54 // private string infoText;55 56 // public string InfoText {57 // get => infoText;58 // set {59 // if (infoText == value) return;60 // infoText = value;61 // OnChanged();62 // }63 // }64 //65 // [Storable]66 // private Color infoColor;67 //68 // public Color InfoColor {69 // get => infoColor;70 // set {71 // if (infoColor == value) return;72 // infoColor = value;73 // OnChanged();74 // }75 // }76 77 // [Storable]78 // private IEnumerable<IntervalConstraint> constraints;79 80 // public IEnumerable<IntervalConstraint> Constraints {81 // get => constraints;82 // set {83 // if (constraints == value) return;84 // constraints = value.ToList();85 // OnChanged();86 // }87 // }88 89 35 public IEnumerable<ShapeConstraint> EnabledConstraints => base.CheckedItems.Select(checkedItem => checkedItem.Value); 90 36 … … 115 61 } 116 62 117 // [Storable]118 // public IRegressionProblemData ProblemData { get; private set; }119 120 63 [StorableConstructor] 121 64 protected ShapeConstraints(StorableConstructorFlag _) : base(_) { } … … 123 66 protected ShapeConstraints(ShapeConstraints original, Cloner cloner) 124 67 : base(original, cloner) { 125 // Input = original.Input;126 // InfoText = original.InfoText;127 // infoColor = original.InfoColor;128 // constraints = original.Constraints.Select(cloner.Clone).ToList();129 // ProblemData = cloner.Clone(original.ProblemData);130 68 } 131 69 … … 134 72 } 135 73 136 public ShapeConstraints() { 137 // Input = exampleInput; 138 // InfoText = ""; 139 // InfoColor = Color.DarkOrange; 140 // constraints = new List<IntervalConstraint>(); 141 // ProblemData = null; 74 public ShapeConstraints() : base() { 142 75 } 143 144 // public ShapeConstraints(IRegressionProblemData problemData) {145 // Input = exampleInput;146 // InfoText = infoText;147 // InfoColor = InfoColor;148 // constraints = new List<IntervalConstraint>();149 // ProblemData = problemData;150 // }151 76 152 77 public event EventHandler Changed;
Note: See TracChangeset
for help on using the changeset viewer.