Skip to content

Error: Algorithm should either be a classifier to be used with response_method=predict_proba or the response_method should be 'predict' #638

Description

@yiannis-gkoufas

Hi!

Recently I started getting this error (or warning?) with binary classification.
Minimal code to reproduce the problem:

from supervised import AutoML

if __name__ == '__main__':
    from sklearn.datasets import make_classification
    X, y = make_classification(n_samples=100000, n_features=20, n_redundant=2)
    from sklearn.model_selection import train_test_split
    X_train, X_test, y_train, y_test = train_test_split( X, y, test_size=0.3)
    automl = AutoML(eval_metric="accuracy")
    automl.fit(X_train, y_train)
    automl.report()

I get multiple messages:

DecisionTreeAlgorithm should either be a classifier to be used with response_method=predict_proba or the response_method should be 'predict'. Got a regressor with response_method=predict_proba instead.
Problem during computing permutation importance. Skipping ...

Is it a new bug or we can just ignore it?
Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions