Skip to content

Commit

Permalink
fix summary for classifiers
Browse files Browse the repository at this point in the history
  • Loading branch information
thierrymoudiki committed Jul 14, 2024
1 parent 8e7eac7 commit f6ebcd1
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion learningmachine/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ def score(self, X, y, scoring=None, **kwargs):
return scoring_options[scoring](y, preds, **kwargs)

def summary(self, X,
class_index,
class_index = None,
y = None,
cl = None,
show_progress = True):
Expand All @@ -222,6 +222,8 @@ def summary(self, X,

if self.type == "classification":

assert class_index is not None, "For classifiers, 'class_index' must be provided"

assert y is not None, "the response 'y' must be provided for classifiers"

return self.obj["summary"](X = r.matrix(FloatVector(X.ravel()),
Expand Down

0 comments on commit f6ebcd1

Please sign in to comment.