31 lines
730 B
Python
31 lines
730 B
Python
|
|
# Copyright (c) OpenMMLab. All rights reserved.
|
||
|
|
import os.path as osp
|
||
|
|
|
||
|
|
import mmengine.fileio as fileio
|
||
|
|
|
||
|
|
from mmseg.registry import DATASETS
|
||
|
|
from .basesegdataset import BaseSegDataset
|
||
|
|
|
||
|
|
|
||
|
|
@DATASETS.register_module()
|
||
|
|
class AerialDataset(BaseSegDataset):
|
||
|
|
"""Pascal VOC dataset.
|
||
|
|
|
||
|
|
Args:
|
||
|
|
split (str): Split txt file for Pascal VOC.
|
||
|
|
"""
|
||
|
|
METAINFO = dict(
|
||
|
|
classes=('background', 'building'),
|
||
|
|
PALETTE = [[0, 0, 0], [255, 255, 255]]
|
||
|
|
)
|
||
|
|
|
||
|
|
def __init__(self,
|
||
|
|
img_suffix='.png',
|
||
|
|
seg_map_suffix='.png',
|
||
|
|
**kwargs) -> None:
|
||
|
|
super().__init__(
|
||
|
|
img_suffix=img_suffix,
|
||
|
|
seg_map_suffix=seg_map_suffix,
|
||
|
|
**kwargs)
|
||
|
|
|