From b25b0d75528c2dd2d19aac17d84a9d461d63b987 Mon Sep 17 00:00:00 2001 From: Radionic Date: Tue, 26 Sep 2023 16:37:24 +0800 Subject: [PATCH] fix: output image type --- blender/mesh_utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blender/mesh_utils.py b/blender/mesh_utils.py index e2f848b..9b76e56 100644 --- a/blender/mesh_utils.py +++ b/blender/mesh_utils.py @@ -67,7 +67,7 @@ def genreate_mesh_from_texture(bpy, image): cv2.drawContours(image, contours, -1, (0, 255, 0), 3) # Convert image back to tensor - image = [torch.from_numpy(image)] + image = torch.from_numpy(np.expand_dims(image, axis=0)) return (image, meshes[0])