Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/13/15 20:51:23 (8 years ago)
Author:
gkronber
Message:

#2497: merged r13118:13119 from trunk to stable

Location:
stable
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • stable

  • stable/HeuristicLab.Algorithms.DataAnalysis

  • stable/HeuristicLab.Algorithms.DataAnalysis/3.4/GaussianProcess/GaussianProcessBase.cs

    r13053 r13147  
    2121#endregion
    2222
    23 using System;
    24 using System.Linq;
    2523using HeuristicLab.Algorithms.GradientDescent;
    2624using HeuristicLab.Common;
     
    3129using HeuristicLab.Parameters;
    3230using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    33 using HeuristicLab.PluginInfrastructure;
    3431using HeuristicLab.Problems.DataAnalysis;
    3532
     
    5148    protected const string HyperparameterGradientsParameterName = "HyperparameterGradients";
    5249    protected const string SolutionCreatorParameterName = "GaussianProcessSolutionCreator";
     50    protected const string ScaleInputValuesParameterName = "ScaleInputValues";
    5351
    5452    public new IDataAnalysisProblem Problem {
     
    7270    public IValueParameter<BoolValue> SetSeedRandomlyParameter {
    7371      get { return (IValueParameter<BoolValue>)Parameters[SetSeedRandomlyParameterName]; }
     72    }
     73    public IFixedValueParameter<BoolValue> ScaleInputValuesParameter {
     74      get { return (IFixedValueParameter<BoolValue>)Parameters[ScaleInputValuesParameterName]; }
    7475    }
    7576    #endregion
     
    8990    public int Seed { get { return SeedParameter.Value.Value; } set { SeedParameter.Value.Value = value; } }
    9091    public bool SetSeedRandomly { get { return SetSeedRandomlyParameter.Value.Value; } set { SetSeedRandomlyParameter.Value.Value = value; } }
     92
     93    public bool ScaleInputValues {
     94      get { return ScaleInputValuesParameter.Value.Value; }
     95      set { ScaleInputValuesParameter.Value.Value = value; }
     96    }
    9197    #endregion
    9298
     
    107113      Parameters.Add(new ValueParameter<BoolValue>(ApproximateGradientsParameterName, "Indicates that gradients should not be approximated (necessary for LM-BFGS).", new BoolValue(false)));
    108114      Parameters[ApproximateGradientsParameterName].Hidden = true; // should not be changed
     115
     116      Parameters.Add(new FixedValueParameter<BoolValue>(ScaleInputValuesParameterName,
     117        "Determines if the input variable values are scaled to the range [0..1] for training.", new BoolValue(true)));
     118      Parameters[ScaleInputValuesParameterName].Hidden = true;
    109119
    110120      // necessary for BFGS
     
    191201        Parameters["Maximization"].Hidden = true;
    192202      }
     203
     204      if (!Parameters.ContainsKey(ScaleInputValuesParameterName)) {
     205        Parameters.Add(new FixedValueParameter<BoolValue>(ScaleInputValuesParameterName,
     206          "Determines if the input variable values are scaled to the range [0..1] for training.", new BoolValue(true)));
     207        Parameters[ScaleInputValuesParameterName].Hidden = true;
     208      }
    193209      #endregion
    194210    }
Note: See TracChangeset for help on using the changeset viewer.