GeoNRW#
- class torchgeo.datasets.GeoNRW(root='data', split='train', transforms=None, download=False, checksum=False)[source]#
Bases:
NonGeoDatasetGeoNRW dataset.
This datasets contains RGB, DEM and segmentation label data from North Rhine-Westphalia, Germany.
Dataset features:
7298 training and 485 test samples
RGB images, 1000x1000px normalized to [0, 1]
DEM images, unnormalized
segmentation labels
Dataset format:
RGB images are three-channel jp2
DEM images are single-channel tif
segmentation labels are single-channel tif
Dataset classes:
background
forest
water
agricultural
residential,commercial,industrial
grassland,swamp,shrubbery
railway,trainstation
highway,squares
airport,shipyard
roads
buildings
Additional information about the dataset can be found on this site.
If you use this dataset in your research, please cite the following paper:
Added in version 0.6.
- __init__(root='data', split='train', transforms=None, download=False, checksum=False)[source]#
Initialize the GeoNRW dataset.
- Parameters:
root (str | PathLike[str]) – root directory where dataset can be found
split (str) – one of “train”, or “test”
transforms (Callable[[dict[str, Any]], dict[str, Any]] | None) – a function/transform that takes input sample and its target as entry and returns a transformed version
download (bool) – if True, download dataset and store it in the root directory
checksum (bool) – if True, check the MD5 of the downloaded files (may be slow)
- Raises:
AssertionError – if
splitargument is invalidDatasetNotFoundError – If dataset is not found and download is False.
- __len__()[source]#
Return the number of data points in the dataset.
- Returns:
length of the dataset
- Return type:
- __annotate_func__()#
The type of the None singleton.