- Timestamp:
- 07/03/12 16:46:35 (12 years ago)
- Location:
- branches/GP-MoveOperators
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/GP-MoveOperators
- Property svn:mergeinfo changed
/trunk/sources merged: 8084,8088-8090,8092-8100,8102-8113,8115,8117-8132,8134-8146,8148-8156,8158-8160,8163-8170,8173-8176,8178-8190,8192-8205
- Property svn:mergeinfo changed
-
branches/GP-MoveOperators/HeuristicLab.Algorithms.DataAnalysis/3.4/NeuralNetwork/NeuralNetworkClassification.cs
r7259 r8206 53 53 get { return (IFixedValueParameter<DoubleValue>)Parameters[DecayParameterName]; } 54 54 } 55 public ConstrainedValueParameter<IntValue> HiddenLayersParameter {56 get { return ( ConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; }55 public IConstrainedValueParameter<IntValue> HiddenLayersParameter { 56 get { return (IConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; } 57 57 } 58 58 public IFixedValueParameter<IntValue> NodesInFirstHiddenLayerParameter { … … 185 185 string targetVariable = problemData.TargetVariable; 186 186 IEnumerable<string> allowedInputVariables = problemData.AllowedInputVariables; 187 IEnumerable<int> rows = problemData.TrainingIndi zes;187 IEnumerable<int> rows = problemData.TrainingIndices; 188 188 double[,] inputMatrix = AlglibUtil.PrepareInputMatrix(dataset, allowedInputVariables.Concat(new string[] { targetVariable }), rows); 189 189 if (inputMatrix.Cast<double>().Any(x => double.IsNaN(x) || double.IsInfinity(x))) … … 195 195 int nClasses = classValues.Count(); 196 196 // map original class values to values [0..nClasses-1] 197 Dictionary<double, double> classIndi zes = new Dictionary<double, double>();197 Dictionary<double, double> classIndices = new Dictionary<double, double>(); 198 198 for (int i = 0; i < nClasses; i++) { 199 classIndi zes[classValues[i]] = i;199 classIndices[classValues[i]] = i; 200 200 } 201 201 for (int row = 0; row < nRows; row++) { 202 inputMatrix[row, nFeatures] = classIndi zes[inputMatrix[row, nFeatures]];202 inputMatrix[row, nFeatures] = classIndices[inputMatrix[row, nFeatures]]; 203 203 } 204 204 -
branches/GP-MoveOperators/HeuristicLab.Algorithms.DataAnalysis/3.4/NeuralNetwork/NeuralNetworkEnsembleClassification.cs
r7259 r8206 57 57 get { return (IFixedValueParameter<DoubleValue>)Parameters[DecayParameterName]; } 58 58 } 59 public ConstrainedValueParameter<IntValue> HiddenLayersParameter {60 get { return ( ConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; }59 public IConstrainedValueParameter<IntValue> HiddenLayersParameter { 60 get { return (IConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; } 61 61 } 62 62 public IFixedValueParameter<IntValue> NodesInFirstHiddenLayerParameter { … … 171 171 string targetVariable = problemData.TargetVariable; 172 172 IEnumerable<string> allowedInputVariables = problemData.AllowedInputVariables; 173 IEnumerable<int> rows = problemData.TrainingIndi zes;173 IEnumerable<int> rows = problemData.TrainingIndices; 174 174 double[,] inputMatrix = AlglibUtil.PrepareInputMatrix(dataset, allowedInputVariables.Concat(new string[] { targetVariable }), rows); 175 175 if (inputMatrix.Cast<double>().Any(x => double.IsNaN(x) || double.IsInfinity(x))) … … 181 181 int nClasses = classValues.Count(); 182 182 // map original class values to values [0..nClasses-1] 183 Dictionary<double, double> classIndi zes = new Dictionary<double, double>();183 Dictionary<double, double> classIndices = new Dictionary<double, double>(); 184 184 for (int i = 0; i < nClasses; i++) { 185 classIndi zes[classValues[i]] = i;185 classIndices[classValues[i]] = i; 186 186 } 187 187 for (int row = 0; row < nRows; row++) { 188 inputMatrix[row, nFeatures] = classIndi zes[inputMatrix[row, nFeatures]];188 inputMatrix[row, nFeatures] = classIndices[inputMatrix[row, nFeatures]]; 189 189 } 190 190 -
branches/GP-MoveOperators/HeuristicLab.Algorithms.DataAnalysis/3.4/NeuralNetwork/NeuralNetworkEnsembleRegression.cs
r7259 r8206 57 57 get { return (IFixedValueParameter<DoubleValue>)Parameters[DecayParameterName]; } 58 58 } 59 public ConstrainedValueParameter<IntValue> HiddenLayersParameter {60 get { return ( ConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; }59 public IConstrainedValueParameter<IntValue> HiddenLayersParameter { 60 get { return (IConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; } 61 61 } 62 62 public IFixedValueParameter<IntValue> NodesInFirstHiddenLayerParameter { … … 170 170 string targetVariable = problemData.TargetVariable; 171 171 IEnumerable<string> allowedInputVariables = problemData.AllowedInputVariables; 172 IEnumerable<int> rows = problemData.TrainingIndi zes;172 IEnumerable<int> rows = problemData.TrainingIndices; 173 173 double[,] inputMatrix = AlglibUtil.PrepareInputMatrix(dataset, allowedInputVariables.Concat(new string[] { targetVariable }), rows); 174 174 if (inputMatrix.Cast<double>().Any(x => double.IsNaN(x) || double.IsInfinity(x))) -
branches/GP-MoveOperators/HeuristicLab.Algorithms.DataAnalysis/3.4/NeuralNetwork/NeuralNetworkRegression.cs
r7259 r8206 53 53 get { return (IFixedValueParameter<DoubleValue>)Parameters[DecayParameterName]; } 54 54 } 55 public ConstrainedValueParameter<IntValue> HiddenLayersParameter {56 get { return ( ConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; }55 public IConstrainedValueParameter<IntValue> HiddenLayersParameter { 56 get { return (IConstrainedValueParameter<IntValue>)Parameters[HiddenLayersParameterName]; } 57 57 } 58 58 public IFixedValueParameter<IntValue> NodesInFirstHiddenLayerParameter { … … 186 186 string targetVariable = problemData.TargetVariable; 187 187 IEnumerable<string> allowedInputVariables = problemData.AllowedInputVariables; 188 IEnumerable<int> rows = problemData.TrainingIndi zes;188 IEnumerable<int> rows = problemData.TrainingIndices; 189 189 double[,] inputMatrix = AlglibUtil.PrepareInputMatrix(dataset, allowedInputVariables.Concat(new string[] { targetVariable }), rows); 190 190 if (inputMatrix.Cast<double>().Any(x => double.IsNaN(x) || double.IsInfinity(x)))
Note: See TracChangeset
for help on using the changeset viewer.