def test_pascal_voc_detection():
if not osp.isdir(osp.expanduser("~/.mxnet/datasets/voc")):
return
train = data.VOCDetection(splits=((2007, "trainval"), (2012, "trainval")))
name = str(train)
val = data.VOCDetection(splits=((2007, "test"), ))
name = str(val)
assert train.classes == val.classes
for _ in range(10):
index = np.random.randint(0, len(train))
_ = train[index]
for _ in range(10):
index = np.random.randint(0, len(val))
_ = val[index]
def test_coco_detection():
After Change
def test_pascal_voc_detection():
train = VOCDetectionTiny()
name = str(train)
val = VOCDetectionTiny(splits=(("tiny_motorbike", "test"), ))
name = str(val)
assert train.classes == val.classes
for _ in range(10):
index = np.random.randint(0, len(train))
_ = train[index]
for _ in range(10):
index = np.random.randint(0, len(val))
_ = val[index]
def test_coco_detection():