You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 19, 2020. It is now read-only.
In v2.15, when you have 2 inputs that are exactly the same but for some reason have different outputs, you get an unhandled exception:
double[][]inputs=newdouble[][]{newdouble[]{0},newdouble[]{0}};int[]outputs=newint[]{1,0};DecisionVariable[]variables={newDecisionVariable("x",DecisionVariableKind.Continuous)};DecisionTreedecisionTree=newDecisionTree(variables,2);C45Learningc45Learning=newC45Learning(decisionTree);c45Learning.Run(inputs,outputs);// System.AggregateException thrown here
A first chance exception of type 'System.AggregateException' occurred in mscorlib.dll
at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)
at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)
at System.Threading.Tasks.Task.Wait()
at System.Threading.Tasks.Parallel.ForWorker[TLocal](Int32 fromInclusive, Int32 toExclusive, ParallelOptions parallelOptions, Action`1 body, Action`2 bodyWithState, Func`4 bodyWithLocal, Func`1 localInit, Action`1 localFinally)
at System.Threading.Tasks.Parallel.For(Int32 fromInclusive, Int32 toExclusive, Action`1 body)
at Accord.MachineLearning.DecisionTrees.Learning.C45Learning.split(DecisionNode root, Double[][] input, Int32[] output, Int32 height)
at Accord.MachineLearning.DecisionTrees.Learning.C45Learning.Run(Double[][] inputs, Int32[] outputs)
It also happens with more than 2 inputs (for example, you can make the DecisionTree sample app crash by changing examples.xls).
ID3 algorithm isn't affected.