From 0ebe8ddba6bcf3adecd20abde12638a21245482e Mon Sep 17 00:00:00 2001 From: Jeff Youel Date: Thu, 19 Dec 2024 11:20:51 -0800 Subject: [PATCH] Fix issue 288: use np.inf for numpy v2 --- pyrender/mesh.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyrender/mesh.py b/pyrender/mesh.py index 36833ea..8465391 100644 --- a/pyrender/mesh.py +++ b/pyrender/mesh.py @@ -84,8 +84,8 @@ def bounds(self): """(2,3) float : The axis-aligned bounds of the mesh. """ if self._bounds is None: - bounds = np.array([[np.infty, np.infty, np.infty], - [-np.infty, -np.infty, -np.infty]]) + bounds = np.array([[np.inf, np.inf, np.inf], + [-np.inf, -np.inf, -np.inf]]) for p in self.primitives: bounds[0] = np.minimum(bounds[0], p.bounds[0]) bounds[1] = np.maximum(bounds[1], p.bounds[1])