From 4e3e3418d31c04f54b1a90dc2a151ae77a7a1d97 Mon Sep 17 00:00:00 2001 From: PARTHDESHMUKH2005 Date: Sun, 15 Feb 2026 22:34:53 +0530 Subject: [PATCH] Adjust classwise predictions shape for scoring --- modAL/multilabel.py | 1 + 1 file changed, 1 insertion(+) diff --git a/modAL/multilabel.py b/modAL/multilabel.py index c908674..485f72c 100644 --- a/modAL/multilabel.py +++ b/modAL/multilabel.py @@ -223,6 +223,7 @@ def max_score(classifier: OneVsRestClassifier, X_pool: modALinput, classwise_confidence = classifier.predict_proba(X_pool) classwise_predictions = classifier.predict(X_pool) + classwise_predictions = classwise_predictions[:,None,:] classwise_scores = classwise_confidence*(classwise_predictions - 1/2) classwise_max = np.max(classwise_scores, axis=1)