Commit 90e3b50e authored by liyinhao's avatar liyinhao
Browse files

delete keys

parent 72350b2d
......@@ -15,7 +15,6 @@ class IndoorBaseDataset(torch_data.Dataset):
root_path,
ann_file,
pipeline=None,
training=False,
classes=None,
test_mode=False,
with_label=True):
......@@ -23,8 +22,6 @@ class IndoorBaseDataset(torch_data.Dataset):
self.root_path = root_path
self.CLASSES = classes if classes else self.CLASSES
self.test_mode = test_mode
self.training = training
self.mode = 'TRAIN' if self.training else 'TEST'
self.label2cat = {i: cat_id for i, cat_id in enumerate(self.CLASSES)}
mmcv.check_file_exist(ann_file)
self.data_infos = mmcv.load(ann_file)
......
......@@ -18,12 +18,11 @@ class ScannetBaseDataset(IndoorBaseDataset):
root_path,
ann_file,
pipeline=None,
training=False,
classes=None,
test_mode=False,
with_label=True):
super().__init__(root_path, ann_file, pipeline, training, classes,
test_mode, with_label)
super().__init__(root_path, ann_file, pipeline, classes, test_mode,
with_label)
self.data_path = osp.join(root_path, 'scannet_train_instance_data')
......
......@@ -16,12 +16,11 @@ class SunrgbdBaseDataset(IndoorBaseDataset):
root_path,
ann_file,
pipeline=None,
training=False,
classes=None,
test_mode=False,
with_label=True):
super().__init__(root_path, ann_file, pipeline, training, classes,
test_mode, with_label)
super().__init__(root_path, ann_file, pipeline, classes, test_mode,
with_label)
self.data_path = osp.join(root_path, 'sunrgbd_trainval')
def _get_pts_filename(self, sample_idx):
......
......@@ -36,7 +36,7 @@ def test_getitem():
]),
]
scannet_dataset = ScannetBaseDataset(root_path, ann_file, pipelines, True)
scannet_dataset = ScannetBaseDataset(root_path, ann_file, pipelines)
data = scannet_dataset[0]
points = data['points']._data
gt_bboxes_3d = data['gt_bboxes_3d']._data
......
......@@ -28,7 +28,7 @@ def test_getitem():
dict(type='Collect3D', keys=['points', 'gt_bboxes_3d', 'gt_labels']),
]
sunrgbd_dataset = SunrgbdBaseDataset(root_path, ann_file, pipelines, True)
sunrgbd_dataset = SunrgbdBaseDataset(root_path, ann_file, pipelines)
data = sunrgbd_dataset[0]
points = data['points']._data
gt_bboxes_3d = data['gt_bboxes_3d']._data
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment