From 56996dd758629a77dd5128a68c5d41c46a322f64 Mon Sep 17 00:00:00 2001 From: SachaDee Date: Fri, 28 Jun 2024 19:47:24 -0300 Subject: [PATCH 1/2] Update gaze_estimator.py Np.float to float --- ptgaze/gaze_estimator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ptgaze/gaze_estimator.py b/ptgaze/gaze_estimator.py index 8edef12..0f0560d 100644 --- a/ptgaze/gaze_estimator.py +++ b/ptgaze/gaze_estimator.py @@ -79,7 +79,7 @@ def _run_mpiigaze_model(self, face: Face) -> None: images.append(image) head_poses.append(normalized_head_pose) images = torch.stack(images) - head_poses = np.array(head_poses).astype(np.float32) + head_poses = np.array(head_poses).astype(float32) head_poses = torch.from_numpy(head_poses) device = torch.device(self._config.device) From b6640308783adb45088f147d2e8b45b4cf25888d Mon Sep 17 00:00:00 2001 From: SachaDee Date: Fri, 28 Jun 2024 21:07:08 -0300 Subject: [PATCH 2/2] Update gaze_estimator.py as type 'float32' --- ptgaze/gaze_estimator.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ptgaze/gaze_estimator.py b/ptgaze/gaze_estimator.py index 0f0560d..6ed968a 100644 --- a/ptgaze/gaze_estimator.py +++ b/ptgaze/gaze_estimator.py @@ -79,7 +79,7 @@ def _run_mpiigaze_model(self, face: Face) -> None: images.append(image) head_poses.append(normalized_head_pose) images = torch.stack(images) - head_poses = np.array(head_poses).astype(float32) + head_poses = np.array(head_poses).astype('float32') head_poses = torch.from_numpy(head_poses) device = torch.device(self._config.device)