Skip to content

Seemingly random test failure fitcknn.m #268

@svillemot

Description

@svillemot

Hi Andreas,

I uploaded version 1.7.6 to Debian and there are test failures on some architectures, with no clear pattern (so likely random). Here is the relevant part of the log file:

***** test
 x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1];
 y = ["a"; "a"; "b"; "b"];
 a = fitcknn (x, y, "NSMethod", "exhaustive", "CrossVal", "on");
 assert (class (a), "ClassificationPartitionedModel");
 assert ({a.X, a.Y, a.Trained{1}.NumNeighbors}, {x, y, 1})
 assert (a.ModelParameters.NSMethod, "exhaustive")
 assert (a.ModelParameters.Distance, "euclidean")
 assert ({a.Trained{1}.BucketSize}, {50})
warning: One or more of the unique class values in the stratification variable is not present in one or more folds.
warning: called from
    cvpartition at line 764 column 19
    crossval at line 1701 column 9
    fitcknn at line 354 column 7
    __test__ at line 5 column 2
    test at line 685 column 11
    /tmp/tmp.jyxrHtkgcj at line 782 column 2

!!!!! test failed
ClassificationKNN: not all 'ClassNames' are present in Y.

The complete test logs on all architectures are there: https://buildd.debian.org/status/package.php?p=octave-statistics

Any hint?

Thanks,

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions