wzzheng / TPVFormer

[CVPR 2023] An academic alternative to Tesla's occupancy network for autonomous driving.
https://wzzheng.net/TPVFormer/
Apache License 2.0
1.19k stars 107 forks source link

FileNotFoundError: [Errno 2] No such file or directory: 'data/nuscenes/v1.0-trainval/attribute.json' #35

Closed Thecats-Jfm closed 1 year ago

Thecats-Jfm commented 1 year ago

I followed the installation instructions in the README, but I encountered some issues during the dataset installation step.

I downloaded the dataset from the nuScenes website, but I wasn't sure which files I needed to download. I made an educated guess and downloaded the following:

nuimages-v1.0-all-samples.tgz nuimages-v1.0-all-sweeps-cam-back-left.tgz nuimages-v1.0-all-sweeps-cam-back-right.tgz nuimages-v1.0-all-sweeps-cam-back.tgz nuimages-v1.0-all-sweeps-cam-front-left.tgz nuimages-v1.0-all-sweeps-cam-front-right.tgz nuimages-v1.0-all-sweeps-cam-front.tgz nuplan-maps-v1.0.zip nuScenes-lidarseg-all-v1.0.tar

I extracted these datasets to the specified directory.

However, when I tried to run either the train or eval.py scripts, I encountered the following issue:

Namespace(gpus=8, py_config='config/tpv04_occupancy.py', resume_from='', work_dir='out/tpv_occupancy') tcp://127.0.0.1:20506 tcp://127.0.0.1:20506 tcp://127.0.0.1:20506 tcp://127.0.0.1:20506 tcp://127.0.0.1:20506 tcp://127.0.0.1:20506 tcp://127.0.0.1:20506 tcp://127.0.0.1:20506

..................

2023-04-21 00:11:26,596 - mmseg - INFO - Config: 2023-04-21 00:13:02,052 - mmseg - INFO - initialize FPN with init_cfg {'type': 'Xavier', 'layer': 'Conv2d', 'distribution': 'uniform'} 2023-04-21 00:13:03,511 - mmseg - INFO - Number of params: 62465552 done ddp model

Loading NuScenes tables for version v1.0-trainval... Traceback (most recent call last): File "train.py", line 401, in torch.multiprocessing.spawn(main, args=(args,), nprocs=args.gpus) File "/root/miniconda3/envs/cat_TPV/lib/python3.8/site-packages/torch/multiprocessing/spawn.py", line 230, in spawn return start_processes(fn, args, nprocs, join, daemon, start_method='spawn') File "/root/miniconda3/envs/cat_TPV/lib/python3.8/site-packages/torch/multiprocessing/spawn.py", line 188, in start_processes while not context.join(): File "/root/miniconda3/envs/cat_TPV/lib/python3.8/site-packages/torch/multiprocessing/spawn.py", line 150, in join raise ProcessRaisedException(msg, error_index, failed_process.pid) torch.multiprocessing.spawn.ProcessRaisedException:

Process 6 terminated with the following error: Traceback (most recent call last): File "/root/miniconda3/envs/cat_TPV/lib/python3.8/site-packages/torch/multiprocessing/spawn.py", line 59, in _wrap fn(i, *args) File "/root/data01/zzy/TPVFormer/train.py", line 99, in main data_builder.build( File "/root/data01/zzy/TPVFormer/builder/data_builder.py", line 20, in build nusc = NuScenes(version=version, dataroot=data_path, verbose=True) File "/root/miniconda3/envs/cat_TPV/lib/python3.8/site-packages/nuscenes/nuscenes.py", line 70, in init self.attribute = self.load_table__('attribute') File "/root/miniconda3/envs/cat_TPV/lib/python3.8/site-packages/nuscenes/nuscenes.py", line 136, in load_table__ with open(osp.join(self.table_root, '{}.json'.format(table_name))) as f: FileNotFoundError: [Errno 2] No such file or directory: 'data/nuscenes/v1.0-trainval/attribute.json'

Since I am not entirely certain if I downloaded the correct dataset, I would like to ask if what I did was correct.

Thecats-Jfm commented 1 year ago

ok,I sloved it! Thanks anyway.

lijain commented 1 year ago

I also have the same problem, may I ask why?