Lightning-AI / Lightning-AI/torchmetrics

Support for semantic segmentation

Open
#1,663 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement waiting on author
Dominant language
Python
Stars
2.5k
Forks
526
Avg merge
6d 11h
Merged PRs (30d)
5

Description

I saw that torchmetrics.detection.mean_ap.MeanAveragePrecision supports segmentation masks in iou_type . It's nice but I'm trying to compute metrics for semantic segmentation (it doesn't cover pixel accuracy or mean iou for example, only precision and recall).

Also, when trying to use MeanAveragePrecision for iou_type='segm' it stills forces me to include scores and labels which is an information already in my masks (the mask index is the label, and the scores are included in the masks). It doesn't seem very intuitive to me!

Unless I've missed something, it would be nice to have to have support for semantic segmentation 😄

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 reading torchmetrics.detection.mean_ap.MeanAveragePrecision and its existing iou_type='segm' input requirements. Define the semantic-segmentation metric scope, including pixel accuracy and mean IoU, and determine how mask-provided labels and scores should be handled; the issue names no specific tests or additional files.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, pytorch
Domain
machine-learning
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.