Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
04/09/21 20:14:14 (4 years ago)
Author:
gkronber
Message:

#3117: fixed build fail

Location:
trunk/HeuristicLab.Algorithms.DataAnalysis/3.4
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/HeuristicLab.Algorithms.DataAnalysis/3.4/GAM/Spline1dModel.cs

    r17889 r17934  
    5555    private Spline1dModel(Spline1dModel orig, Cloner cloner) : base(orig, cloner) {
    5656      this.inputVariable = orig.inputVariable;
    57       this.interpolant = (alglib.spline1d.spline1dinterpolant)orig.interpolant.make_copy();
     57      if(orig.interpolant != null) this.interpolant = (alglib.spline1d.spline1dinterpolant)orig.interpolant.make_copy();
    5858    }
    5959    public Spline1dModel(alglib.spline1d.spline1dinterpolant interpolant, string targetVar, string inputVar)
    6060      : base(targetVar, $"Spline model ({inputVar})") {
    6161      this.interpolant = (alglib.spline1d.spline1dinterpolant)interpolant.make_copy();
    62       this.inputVariable = inputVar;     
     62      this.inputVariable = inputVar;
    6363    }
    6464
     
    7373    }
    7474
    75     public double GetEstimatedValue(double x) => alglib.spline1d.spline1dcalc(interpolant, x);
     75    public double GetEstimatedValue(double x) => alglib.spline1d.spline1dcalc(interpolant, x, null);
    7676
    7777    public override IEnumerable<double> GetEstimatedValues(IDataset dataset, IEnumerable<int> rows) {
  • trunk/HeuristicLab.Algorithms.DataAnalysis/3.4/Nca/NcaModel.cs

    r17931 r17934  
    6666      var ds = ReduceDataset(dataset, rows);
    6767      // the new implementation of kNN uses selfmatch=true by default
    68       nnModel = new NearestNeighbourModelAlglib_3_7(ds, Enumerable.Range(0, ds.Rows), k, selfMatch: false, ds.VariableNames.Last(), ds.VariableNames.Take(transformationMatrix.GetLength(1)), classValues: classValues);
     68      nnModel = new NearestNeighbourModelAlglib_3_7(ds, Enumerable.Range(0, ds.Rows), k, false, ds.VariableNames.Last(), ds.VariableNames.Take(transformationMatrix.GetLength(1)), classValues: classValues);
    6969    }
    7070
  • trunk/HeuristicLab.Algorithms.DataAnalysis/3.4/NearestNeighbour/NearestNeighbourModel.cs

    r17931 r17934  
    128128        alglib.knnbuildersetdatasetcls(knnbuilder, inputMatrix, nRows, nFeatures, classValues.Length);
    129129      }
    130       alglib.knnbuilderbuildknnmodel(knnbuilder, k, eps: 0.0, out model, out var report); // eps=0 (exact k-nn search is performed)
     130      alglib.knnbuilderbuildknnmodel(knnbuilder, k, 0.0, out model, out var report); // eps=0 (exact k-nn search is performed)
    131131
    132132    }
  • trunk/HeuristicLab.Algorithms.DataAnalysis/3.4/NeuralNetwork/NeuralNetworkRegression.cs

    r17931 r17934  
    192192      alglib.multilayerperceptron multiLayerPerceptron = null;
    193193      if (nLayers == 0) {
    194         alglib.mlpcreate0(allowedInputVariables.Count(), nout: 1, out multiLayerPerceptron);
     194        alglib.mlpcreate0(allowedInputVariables.Count(), 1, out multiLayerPerceptron);
    195195      } else if (nLayers == 1) {
    196         alglib.mlpcreate1(allowedInputVariables.Count(), nHiddenNodes1, nout: 1, out multiLayerPerceptron);
     196        alglib.mlpcreate1(allowedInputVariables.Count(), nHiddenNodes1, 1, out multiLayerPerceptron);
    197197      } else if (nLayers == 2) {
    198         alglib.mlpcreate2(allowedInputVariables.Count(), nHiddenNodes1, nHiddenNodes2, nout: 1, out multiLayerPerceptron);
     198        alglib.mlpcreate2(allowedInputVariables.Count(), nHiddenNodes1, nHiddenNodes2, 1, out multiLayerPerceptron);
    199199      } else throw new ArgumentException("Number of layers must be zero, one, or two.", "nLayers");
    200200
Note: See TracChangeset for help on using the changeset viewer.