From 83a58ed5bf3635e1b5007c8457cea61254eef55c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Franz=20Kir=C3=A1ly?= Date: Sat, 27 Jul 2024 23:02:21 +0100 Subject: [PATCH] numpy2 pareto --- skpro/distributions/pareto.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/skpro/distributions/pareto.py b/skpro/distributions/pareto.py index 82274b54f..3c8bbc9d4 100644 --- a/skpro/distributions/pareto.py +++ b/skpro/distributions/pareto.py @@ -60,7 +60,7 @@ def _mean(self): """ alpha = self._bc_params["alpha"] scale = self._bc_params["scale"] - mean = np.where(alpha <= 1, np.infty, scale**alpha / (alpha - 1)) + mean = np.where(alpha <= 1, np.inf, scale**alpha / (alpha - 1)) return mean def _var(self): @@ -74,7 +74,7 @@ def _var(self): alpha = self._bc_params["alpha"] scale = self._bc_params["scale"] var = np.where( - alpha <= 2, np.infty, scale**2 * alpha / ((alpha - 2) * (alpha - 1) ** 2) + alpha <= 2, np.inf, scale**2 * alpha / ((alpha - 2) * (alpha - 1) ** 2) ) return var