drprojects / DeepViewAgg

[CVPR'22 Best Paper Finalist] Official PyTorch implementation of the method presented in "Learning Multi-View Aggregation In the Wild for Large-Scale 3D Semantic Segmentation"
Other
222 stars 24 forks source link

Batch.from_data_list for S3DIS dataset #12

Closed ruomingzhai closed 2 years ago

ruomingzhai commented 2 years ago

Hi ROBERT! I am trying to train the S3DIS dataset and it broke down because of the batch class in the torch-geometric library. Traceback (most recent call last): File "/root/.local/conda/envs/py38cu102/lib/python3.8/runpy.py", line 194, in _run_module_as_main return _run_code(code, main_globals, None, File "/root/.local/conda/envs/py38cu102/lib/python3.8/runpy.py", line 87, in _run_code exec(code, run_globals) File "/root/.local/share/code-server/extensions/ms-python.python-2021.8.1159798656/pythonFiles/lib/python/debugpy/__main__.py", line 45, in <module> cli.main() File "/root/.local/share/code-server/extensions/ms-python.python-2021.8.1159798656/pythonFiles/lib/python/debugpy/../debugpy/server/cli.py", line 444, in main run() File "/root/.local/share/code-server/extensions/ms-python.python-2021.8.1159798656/pythonFiles/lib/python/debugpy/../debugpy/server/cli.py", line 285, in run_file runpy.run_path(target_as_str, run_name=compat.force_str("__main__")) File "/root/.local/conda/envs/py38cu102/lib/python3.8/runpy.py", line 265, in run_path return _run_module_code(code, init_globals, run_name, File "/root/.local/conda/envs/py38cu102/lib/python3.8/runpy.py", line 97, in _run_module_code _run_code(code, mod_globals, init_globals, File "/root/.local/conda/envs/py38cu102/lib/python3.8/runpy.py", line 87, in _run_code exec(code, run_globals) File "/root/share/code/DeepViewAgg/s3dis_preprocess.py", line 120, in <module> initial_trainer() File "/root/share/code/DeepViewAgg/s3dis_preprocess.py", line 95, in initial_trainer trainer.train() File "/root/share/code/DeepViewAgg/torch_points3d/trainer.py", line 147, in train self._train_epoch(epoch) File "/root/share/code/DeepViewAgg/torch_points3d/trainer.py", line 198, in _train_epoch for i, data in enumerate(tq_train_loader): File "/root/.local/lib/python3.8/site-packages/tqdm/std.py", line 1195, in __iter__ for obj in iterable: File "/root/.local/lib/python3.8/site-packages/torch/utils/data/dataloader.py", line 435, in __next__ data = self._next_data() File "/root/.local/lib/python3.8/site-packages/torch/utils/data/dataloader.py", line 475, in _next_data data = self._dataset_fetcher.fetch(index) # may raise StopIteration File "/root/.local/lib/python3.8/site-packages/torch/utils/data/_utils/fetch.py", line 47, in fetch return self.collate_fn(data) File "/root/share/code/DeepViewAgg/torch_points3d/datasets/base_dataset.py", line 172, in _collate_fn return collate_fn(batch) File "/root/share/code/DeepViewAgg/torch_points3d/core/multimodal/data.py", line 189, in from_mm_data_list data = Batch.from_data_list( File "/root/.local/lib/python3.8/site-packages/torch_geometric/data/batch.py", line 50, in from_data_list assert 'batch' not in keys and 'ptr' not in keys

pytorch_geometric/3389 It is mentioned in pytorch_geometric GitHub and it is fixed in the newer version. I use torch-geometric 1.7.2 as you recommended. The MMData does not have the 'batch' keys.

捕获

I wonder if this ever happens to you?

drprojects commented 2 years ago

Hi @ruomingzhai, I am not certain it is related but I looked at the version of torch-geometric on all my machines and I have 1.6.3 and not 1.7. This may be an error on my part.

Could you please try installing torch-geometric==1.6.3 and check if it solves this error ? If so, I will update install.sh accordingly.

drprojects commented 2 years ago

Hi @ruomingzhai can you please let me know if the above message solved your issue ?

ruomingzhai commented 2 years ago

Hi @ruomingzhai can you please let me know if the above message solved your issue?

Sorry for the delayed reply! It works when I decreased the version from 1.7.4 to 1.6.3. Thanks a lot!!!