Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
03/16/21 11:08:18 (3 years ago)
Author:
gkronber
Message:

#3073: refactoring to prepare for trunk integration

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3073_IA_constraint_splitting_reintegration/HeuristicLab.Problems.DataAnalysis/3.4/Implementation/Regression/ShapeConstraints.cs

    r17891 r17896  
    22
    33/* HeuristicLab
    4  * Copyright (C) 2002-2019 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     4 * Copyright (C) Heuristic and Evolutionary Algorithms Laboratory (HEAL)
    55 *
    66 * This file is part of HeuristicLab.
     
    3333  [Item("ShapeConstraints", "Represents shape constraints associated with a regression problem data e.g. monotonicity constraints.")]
    3434  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 
    8935    public IEnumerable<ShapeConstraint> EnabledConstraints => base.CheckedItems.Select(checkedItem => checkedItem.Value);
    9036
     
    11561    }
    11662
    117     // [Storable]
    118     // public IRegressionProblemData ProblemData { get; private set; }
    119 
    12063    [StorableConstructor]
    12164    protected ShapeConstraints(StorableConstructorFlag _) : base(_) { }
     
    12366    protected ShapeConstraints(ShapeConstraints original, Cloner cloner)
    12467      : 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);
    13068    }
    13169
     
    13472    }
    13573
    136     public ShapeConstraints() {
    137       // Input = exampleInput;
    138       // InfoText = "";
    139       // InfoColor = Color.DarkOrange;
    140       // constraints = new List<IntervalConstraint>();
    141       // ProblemData = null;
     74    public ShapeConstraints() : base() {
    14275    }
    143 
    144     // public ShapeConstraints(IRegressionProblemData problemData) {
    145     //   Input = exampleInput;
    146     //   InfoText = infoText;
    147     //   InfoColor = InfoColor;
    148     //   constraints = new List<IntervalConstraint>();
    149     //   ProblemData = problemData;
    150     // }
    15176
    15277    public event EventHandler Changed;
Note: See TracChangeset for help on using the changeset viewer.