From e52e9acdc19231bd95ec928ea9048c5405cb9f1c Mon Sep 17 00:00:00 2001 From: Rabah Khalek Date: Mon, 19 Aug 2024 14:12:34 +0200 Subject: [PATCH] fixed nan edge-case in report api --- giskard_vision/landmark_detection/tests/report.py | 1 + 1 file changed, 1 insertion(+) diff --git a/giskard_vision/landmark_detection/tests/report.py b/giskard_vision/landmark_detection/tests/report.py index ff843e51..cdfe12aa 100644 --- a/giskard_vision/landmark_detection/tests/report.py +++ b/giskard_vision/landmark_detection/tests/report.py @@ -69,6 +69,7 @@ def to_dataframe(self, summary: Optional[bool] = False): raise GiskardImportError(["pandas"]) from e df = pd.DataFrame(self.results) + df.dropna(inplace=True) # in case the model failed to predict for instance for col in ["metric_value", "prediction_time", "prediction_fail_rate"]: col_name = f"Best({col})"