pytorch / pytorch/vision

Improved functionality for Oxford IIIT Pet data loader

Open
#8,364 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Python
Stars
17.9k
Forks
7.3k
Avg merge
1d 15h
Merged PRs (30d)
13

Description

🚀 The feature

Add the following functionality to the Oxford IIIT Pet data loader

  1. Support binary classification of cat vs dog
  2. With the segmentation target type, produce trimaps with class/background/don't care regions instead of target/background/don't care when the output is a tensor
  3. Support detection as a target type
Motivation, pitch

The Oxford IIIT Pet dataset is a fun dataset for trying out new things and for new practitioners to use to learn. These capabilities allow users to more easily use this dataset with detection and segmentation target types and to use the existing annotation for animal species (rather than breed) as a simpler problem to get started. I have created these capabilities on my local copy of torchvision, and I'm up for creating a PR if the community likes the enhancements. The individual proposed enhancements can be found in the links:
Binary cat v dog
Class labeled segmentation
Detection target type
All 3 enhancements

Alternatives

I thought a lot about the ability to write transforms to use with a dataset loader to accomplish this, but it was unclear to me how I could access some of the class members of the dataset loaders that were necessary.

Additional context

Demonstration of the new features can be found in the following notebooks:
Class-labeled segmentation maps and binary species classification training Deeplab V3
Detection target type training resnet 50 faster RCNN

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 by reviewing the linked implementations in pet_dataloader_bin/oxford_iiit_pet.py, pet_dataloader_seg/oxford_iiit_pet.py, pet_dataloader_detect/oxford_iiit_pet.py, and petbuild/oxford_iiit_pet.py, then compare them with the current Oxford IIIT Pet loader. Use the linked notebooks to understand the intended classification, segmentation, and detection outputs; done means the three target types work with appropriate tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
computer-vision, machine-learning
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.