Ignore:
Timestamp:
11/05/15 07:46:38 (7 years ago)
Author:
gkronber
Message:

#2497: added hidden parameter to turn on/off scaling of input variables in Gaussian process models

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Algorithms.DataAnalysis/3.4/GaussianProcess/GaussianProcessBase.cs

    r12797 r13118  
    5151    protected const string HyperparameterGradientsParameterName = "HyperparameterGradients";
    5252    protected const string SolutionCreatorParameterName = "GaussianProcessSolutionCreator";
     53    protected const string ScaleInputValuesParameterName = "ScaleInputValues";
    5354
    5455    public new IDataAnalysisProblem Problem {
     
    7273    public IValueParameter<BoolValue> SetSeedRandomlyParameter {
    7374      get { return (IValueParameter<BoolValue>)Parameters[SetSeedRandomlyParameterName]; }
     75    }
     76    public IFixedValueParameter<BoolValue> ScaleInputValuesParameter {
     77      get { return (IFixedValueParameter<BoolValue>)Parameters[ScaleInputValuesParameterName]; }
    7478    }
    7579    #endregion
     
    8993    public int Seed { get { return SeedParameter.Value.Value; } set { SeedParameter.Value.Value = value; } }
    9094    public bool SetSeedRandomly { get { return SetSeedRandomlyParameter.Value.Value; } set { SetSeedRandomlyParameter.Value.Value = value; } }
     95
     96    public bool ScaleInputValues {
     97      get { return ScaleInputValuesParameter.Value.Value; }
     98      set { ScaleInputValuesParameter.Value.Value = value; }
     99    }
    91100    #endregion
    92101
     
    107116      Parameters.Add(new ValueParameter<BoolValue>(ApproximateGradientsParameterName, "Indicates that gradients should not be approximated (necessary for LM-BFGS).", new BoolValue(false)));
    108117      Parameters[ApproximateGradientsParameterName].Hidden = true; // should not be changed
     118
     119      Parameters.Add(new FixedValueParameter<BoolValue>(ScaleInputValuesParameterName,
     120        "Determines if the input variable values are scaled to the range [0..1] for training.", new BoolValue(true)));
     121      Parameters[ScaleInputValuesParameterName].Hidden = true;
    109122
    110123      // necessary for BFGS
     
    191204        Parameters["Maximization"].Hidden = true;
    192205      }
     206
     207      if (!Parameters.ContainsKey(ScaleInputValuesParameterName)) {
     208        Parameters.Add(new FixedValueParameter<BoolValue>(ScaleInputValuesParameterName,
     209          "Determines if the input variable values are scaled to the range [0..1] for training.", new BoolValue(true)));
     210        Parameters[ScaleInputValuesParameterName].Hidden = true;
     211      }
    193212      #endregion
    194213    }
Note: See TracChangeset for help on using the changeset viewer.