diff --git a/docs/GETTING_STARTED.md b/docs/GETTING_STARTED.md index 46b90c2a0..d1e160965 100644 --- a/docs/GETTING_STARTED.md +++ b/docs/GETTING_STARTED.md @@ -108,7 +108,9 @@ OpenPCDet │ ├── lyft │ │ │── ImageSets │ │ │── trainval -│ │ │ │── data & maps & images & lidar & train_lidar +│ │ │ │── data & maps(train_maps) & images(train_images) & lidar(train_lidar) & train_lidar +│ │ │── test +│ │ │ │── data & maps(test_maps) & test_images & test_lidar ├── pcdet ├── tools ``` @@ -118,11 +120,16 @@ OpenPCDet pip install -U lyft_dataset_sdk==0.0.8 ``` -* Generate the data infos by running the following command (it may take several hours): +* Generate the training & validation data infos by running the following command (it may take several hours): ```python python -m pcdet.datasets.lyft.lyft_dataset --func create_lyft_infos \ --cfg_file tools/cfgs/dataset_configs/lyft_dataset.yaml ``` +* Generate the test data infos by running the following command: +```python +python -m pcdet.datasets.lyft.lyft_dataset --func create_lyft_infos \ + --cfg_file tools/cfgs/dataset_configs/lyft_dataset.yaml --version test +``` * You need to check carefully since we don't provide a benchmark for it. diff --git a/pcdet/datasets/lyft/lyft_dataset.py b/pcdet/datasets/lyft/lyft_dataset.py index efa577afb..a042eb56f 100644 --- a/pcdet/datasets/lyft/lyft_dataset.py +++ b/pcdet/datasets/lyft/lyft_dataset.py @@ -276,7 +276,7 @@ def create_lyft_info(version, data_path, save_path, split, max_sweeps=10): raise NotImplementedError train_scenes = [x.strip() for x in open(train_split_path).readlines()] if train_split_path.exists() else [] - val_scenes = [x.strip() for x in open(val_split_path).readlines()] if val_split_path.exists() else [] + val_scenes = [x.strip() for x in open(val_split_path).readlines()] if val_split_path is not None and val_split_path.exists() else [] lyft = LyftDataset(json_path=data_path / 'data', data_path=data_path, verbose=True) @@ -342,4 +342,6 @@ def create_lyft_info(version, data_path, save_path, split, max_sweeps=10): root_path=ROOT_DIR / 'data' / 'lyft', logger=common_utils.create_logger(), training=True ) - lyft_dataset.create_groundtruth_database(max_sweeps=dataset_cfg.MAX_SWEEPS) + + if args.version != 'test': + lyft_dataset.create_groundtruth_database(max_sweeps=dataset_cfg.MAX_SWEEPS)