Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/07/21 15:16:07 (4 years ago)
Author:
gkronber
Message:

#3117: allow infinity inputs for random forest

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/HeuristicLab.Algorithms.DataAnalysis/3.4/RandomForest/RandomForestUtil.cs

    r17942 r17979  
    9797
    9898    public static void AssertInputMatrix(double[,] inputMatrix) {
    99       if (inputMatrix.ContainsNanOrInfinity())
    100         throw new NotSupportedException("Random forest modeling does not support NaN or infinity values in the input dataset.");
     99      foreach(var val in inputMatrix) if(double.IsNaN(val))
     100        throw new NotSupportedException("Random forest modeling does not support NaN values in the input dataset.");
    101101    }
    102102
Note: See TracChangeset for help on using the changeset viewer.