From 217f4694daa761f8b696368b6074784a390b1a8c Mon Sep 17 00:00:00 2001 From: Omer Sarioglu Date: Mon, 4 Dec 2023 15:18:19 +0300 Subject: [PATCH] Fix broken `classes` attribute --- sliceguard/sliceguard.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sliceguard/sliceguard.py b/sliceguard/sliceguard.py index be2f066..92a3782 100644 --- a/sliceguard/sliceguard.py +++ b/sliceguard/sliceguard.py @@ -428,7 +428,7 @@ def report( df["sg_y_pred"] = self._generated_y_pred[selected_dataframe_rows] if hasattr(self, "_generated_y_probs") and hasattr(self, "classes"): - for class_idx, label in enumerate(self._classes): + for class_idx, label in enumerate(self.classes): df[f"sg_p_{label}"] = self._generated_y_probs[:, class_idx].tolist() spotlight_issue_list = np.array(data_issues)[data_issue_order].tolist()