pytorch / pytorch/vision

Accounting for class_id in cityscapes dataset

Open
#1,064 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement help wanted module: datasets needs discussion
Dominant language
Python
Stars
17.9k
Forks
7.3k
Avg merge
1d 15h
Merged PRs (30d)
13

Description

Hi,

In the dataset class for Cityscapes, the classes with their meta-data is mentioned as a namedtuple. However, this information is not used anywhere. Especially for semantic segmenation, the train_id should be used to convert the pixel value (of the label image) to the training label.

Is this planned to be added anytime soon?

Edit: There seems to have been a commit that does something like this and that hasn't been merged.
https://github.com/pytorch/vision/pull/1025/commits/39a7a2fb6015792b6c32fd7ee3eeac9774f712a4

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Cityscapes dataset class and inspect how its namedtuple metadata is defined and consumed. Review the referenced commit for the proposed behavior, then verify that semantic-segmentation label images use each class's train_id as the training label; done means this conversion is implemented and covered by the relevant dataset behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
computer-vision
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.