xinge008 / Cylinder3D

Rank 1st in the leaderboard of SemanticKITTI semantic segmentation (both single-scan and multi-scan) (Nov. 2020) (CVPR2021 Oral)
Apache License 2.0
858 stars 180 forks source link

Mismatch in shape when running the demo #149

Open WEIJIARONG99 opened 2 years ago

WEIJIARONG99 commented 2 years ago

python demo_folder.py --demo-folder model_load_dir --save-folder results demo_folder.py --demo-folder model_load_dir --save-folder results Namespace(config_path='config/semantickitti.yaml', demo_folder='model_load_dir', demo_label_folder='', save_folder='results') [480 360 32] matched parameter sets: 226, and no matched: 48 Traceback (most recent call last): File "demo_folder.py", line 151, in main(args) File "demo_folder.py", line 103, in main demo_dataset_loader): File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 530, in next data = self._next_data() File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 1224, in _next_data return self._process_data(data) File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/utils/data/dataloader.py", line 1250, in _process_data data.reraise() File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/_utils.py", line 457, in reraise raise exception ValueError: Caught ValueError in DataLoader worker process 0. Original Traceback (most recent call last): File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/utils/data/_utils/worker.py", line 287, in _worker_loop data = fetcher.fetch(index) File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 49, in fetch data = [self.dataset[idx] for idx in possibly_batched_index] File "/home/weijiarong/anaconda3/envs/master_thesis/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 49, in data = [self.dataset[idx] for idx in possibly_batched_index] File "/home/weijiarong/Desktop/Cylinder3D/dataloader/dataset_semantickitti.py", line 192, in getitem data = self.point_cloud_dataset[index] File "/home/weijiarong/Desktop/Cylinder3D/dataloader/pc_dataset.py", line 50, in getitem raw_data = np.fromfile(self.im_idx[index], dtype=np.float32).reshape((-1, 4)) ValueError: cannot reshape array of size 55885386 into shape (4)

Anyone met the similar error?

ZixuanChen613 commented 2 years ago

I met the same error... waiting for an answer

ValueError: Caught ValueError in DataLoader worker process 0. Original Traceback (most recent call last): File "/opt/conda/envs/4dplsca/lib/python3.7/site-packages/torch/utils/data/_utils/worker.py", line 287, in _worker_loop data = fetcher.fetch(index) File "/opt/conda/envs/4dplsca/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 49, in fetch data = [self.dataset[idx] for idx in possibly_batched_index] File "/opt/conda/envs/4dplsca/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 49, in data = [self.dataset[idx] for idx in possibly_batched_index] File "/workspace/code/Cylinder3D/dataloader/dataset_semantickitti.py", line 192, in getitem data = self.point_cloud_dataset[index] File "/workspace/code/Cylinder3D/dataloader/pc_dataset.py", line 52, in getitem raw_data = np.fromfile(self.im_idx[index], dtype=np.float32).reshape((-1, 4)) ValueError: cannot reshape array of size 293 into shape (4)

WEIJIARONG99 commented 2 years ago

Hey man which version of spconv did you use? I use spconv2.0+, then this error appeared; I also want to try spconv1.2.1 as they recommended, but I failed to compile that. Did you meet the same situation?

获取 Outlook for iOShttps://aka.ms/o0ukef


发件人: ZixuanChen613 @.> 发送时间: Friday, June 24, 2022 4:27:49 PM 收件人: xinge008/Cylinder3D @.> 抄送: Tony-WJR @.>; Author @.> 主题: Re: [xinge008/Cylinder3D] Mismatch in shape when running the demo (Issue #149)

I met the same error... waiting for an answer

ValueError: Caught ValueError in DataLoader worker process 0. Original Traceback (most recent call last): File "/opt/conda/envs/4dplsca/lib/python3.7/site-packages/torch/utils/data/_utils/worker.py", line 287, in _worker_loop data = fetcher.fetch(index) File "/opt/conda/envs/4dplsca/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 49, in fetch data = [self.dataset[idx] for idx in possibly_batched_index] File "/opt/conda/envs/4dplsca/lib/python3.7/site-packages/torch/utils/data/_utils/fetch.py", line 49, in data = [self.dataset[idx] for idx in possibly_batched_index] File "/workspace/code/Cylinder3D/dataloader/dataset_semantickitti.py", line 192, in getitem data = self.point_cloud_dataset[index] File "/workspace/code/Cylinder3D/dataloader/pc_dataset.py", line 52, in getitem raw_data = np.fromfile(self.im_idx[index], dtype=np.float32).reshape((-1, 4)) ValueError: cannot reshape array of size 293 into shape (4)

― Reply to this email directly, view it on GitHubhttps://github.com/xinge008/Cylinder3D/issues/149#issuecomment-1165630675, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AWE4MIL42KB22Y6EOAYAPHDVQXAWLANCNFSM5ZVWSLPA. You are receiving this because you authored the thread.Message ID: @.***>

ZhouYC-X commented 2 years ago

I encountered similar problem and solved it by "python demo_folder.py --demo-folder /mnt/data/datasets/kitti/sequences/00/velodyne/ --save-folder ./results/". Good luck.

christophTUM commented 1 year ago

Does anyone else still has this problem?