def _test_save_and_load(self, source_dataset, converter, test_dir, target_dataset=None, importer_args=None): converter(source_dataset, test_dir) if importer_args is None: importer_args = {} parsed_dataset = CocoImporter()(test_dir, **importer_args).make_dataset() if target_dataset is None: target_dataset = source_dataset compare_datasets(self, expected=target_dataset, actual=parsed_dataset)
def test_can_detect(self): self.assertTrue( CocoImporter.detect(osp.join(DUMMY_DATASET_DIR, 'coco_instances')))
def test_can_detect(self): with TestDir() as test_dir: self.COCO_dataset_generate(test_dir) self.assertTrue(CocoImporter.detect(test_dir))
def test_can_detect(self): self.assertTrue(CocoImporter.detect(DUMMY_DATASET_DIR))