aim-uofa / AdelaiDepth

This repo contains the projects: 'Virtual Normal', 'DiverseDepth', and '3D Scene Shape'. They aim to solve the monocular depth estimation, 3D scene reconstruction from single image problems.
Creative Commons Zero v1.0 Universal
1.07k stars 144 forks source link

ValueError: not enough values to unpack (expected 2, got 1) #87

Open pengjianqiang opened 1 month ago

pengjianqiang commented 1 month ago

When I run the “test_depth.py” file, I encounter the following problem

processing (0000)-th image... /root/AdelaiDepth-main/LeReS/test_dataset/Patient_21_0019200.jpg Traceback (most recent call last): File "test_shape.py", line 131, in shift_model, focal_model) File "test_shape.py", line 75, in reconstruct3D_from_depth shift_1 = refine_shift(pred_depth_norm, shift_model, predicted_focal_1, cam_u0, cam_v0) File "/root/AdelaiDepth-main/LeReS/Minist_Test/lib/test_utils.py", line 125, in refine_shift shift = refine_shift_one_step(depth_wshift_tmp, model, focal, u0, v0) File "/root/AdelaiDepth-main/LeReS/Minist_Test/lib/test_utils.py", line 109, in refine_shift_one_step outputs = model(inputs) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl result = self.forward(*input, kwargs) File "/root/AdelaiDepth-main/LeReS/Minist_Test/lib/spvcnn_classsification.py", line 148, in forward x2 = self.stage2(x1) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl result = self.forward(*input, *kwargs) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/container.py", line 117, in forward input = module(input) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl result = self.forward(input, kwargs) File "/root/AdelaiDepth-main/LeReS/Minist_Test/lib/spvcnn_classsification.py", line 23, in forward out = self.net(x) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl result = self.forward(*input, *kwargs) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/container.py", line 117, in forward input = module(input) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torch/nn/modules/module.py", line 722, in _call_impl result = self.forward(input, **kwargs) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torchsparse/nn/modules/conv.py", line 78, in forward transpose=self.t) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torchsparse/nn/functional/conv.py", line 118, in conv3d idx_query = list(convert_neighbor_map_gpu(idx_query)) File "/root/miniconda3/envs/LeReS/lib/python3.7/site-packages/torchsparse/nn/functional/convert_neighbor_map.py", line 10, in forward idx_batch, idx_point = torch.where(neighbor_map != -1) ValueError: not enough values to unpack (expected 2, got 1)