CoolFace
Datasetpublic

tanganke/cityscapes

CityScapes Dataset (HuggingFace Format) Dataset Description This is a processed version of the CityScapes dataset converted to HuggingFace datasets format. The dataset contains urban street scenes with corresponding semantic segmentation labels and depth maps, commonly used for autonomous driving research and computer vision tasks. Dataset Summary Total samples: 3,475 images Training samples: 2,975 images Validation samples: 500 images Image… See the full description on the dataset page: https://huggingface.co/datasets/tanganke/cityscapes.

sourceHugging Faceupdated 1y agoView on Hugging Face
1likes241downloads
Dataset Card

CityScapes Dataset (HuggingFace Format)

Dataset Description

This is a processed version of the CityScapes dataset converted to HuggingFace datasets format. The dataset contains urban street scenes with corresponding semantic segmentation labels and depth maps, commonly used for autonomous driving research and computer vision tasks.

Dataset Summary

  • —Total samples: 3,475 images
  • —Training samples: 2,975 images
  • —Validation samples: 500 images
  • —Image resolution: 128×256 pixels
  • —Channels: 3 (RGB)

Dataset Structure

Data Fields

  • —`image`: RGB image tensor of shape (3, 128, 256) (channels, height, width)
  • —`segmentation`: 7-class semantic segmentation labels of shape (128, 256)
  • —`segmentation_2`: 2-class semantic segmentation labels of shape (128, 256)
  • —`segmentation_19`: 19-class semantic segmentation labels of shape (128, 256)
  • —`depth`: Depth map of shape (1, 128, 256) (1 channel depth information)

Data Splits

SplitSamples
Train2,975
Validation500
Total3,475

Usage

Loading the Dataset

python
from datasets import load_dataset
import numpy as np

# Load the dataset
dataset = load_dataset("tanganke/cityscapes")

# Access training data
train_dataset = dataset["train"]
test_dataset = dataset["validation"]

# Get a sample
sample = train_dataset[0]
image = np.array(sample["image"])  # Shape: (3, 128, 256)
segmentation = np.array(sample["segmentation"])  # Shape: (128, 256)
depth = np.array(sample["depth"])  # Shape: (1, 128, 256)

Original Dataset

The Cityscapes dataset [[1]](#1) is an urban scene understanding dataset. It contains 2975 and 500 images with ground-truths for training and validation, respectively.

We use the pre-processed Cityscapes dataset described in [[2]](#2), which can be downloaded here. Each input image has been resized to $3 \times 128 \times 256$ and has labels for two tasks: 7-class semantic segmentation and depth estimation.

References

<a id="1">[1]</a> Marius Cordts, Mohamed Omran, Sebastian Ramos, Timo Rehfeld, Markus Enzweiler, Rodrigo Benenson, Uwe Franke, Stefan Roth, and Bernt Schiele. The Cityscapes Dataset for Semantic Urban Scene Understanding. In IEEE Conference on Computer Vision and Pattern Recognition, 2016.

<a id="2">[2]</a> Shikun Liu, Edward Johns, and Andrew J. Davison. End-to-End Multi-Task Learning with Attention. In IEEE Conference on Computer Vision and Pattern Recognition, 2019.