Mask2Former is a unified segmentation architecture that handles semantic, instance, and panoptic segmentation with one model and one training recipe. Its core idea is to cast segmentation as mask classification: a transformer decoder predicts a set of mask queries, each with an associated class score, eliminating the need for task-specific heads. A pixel decoder fuses multi-scale features and feeds masked attention in the transformer so each query focuses computation on its current spatial support. This leads to accurate masks with sharp boundaries and strong small-object performance while remaining efficient on high-resolution inputs. The project provides extensive configurations and pretrained models across popular benchmarks like COCO, ADE20K, and Cityscapes. Built on top of Detectron2, it includes training scripts, inference tools, and visualization utilities that make experimentation straightforward.

Features

  • Single architecture for semantic, instance, and panoptic segmentation
  • Mask-classification formulation with a transformer decoder over queries
  • Pixel decoder plus masked attention for focused, efficient computation
  • Multi-scale feature fusion for robust small-object and boundary accuracy
  • Comprehensive configs and pretrained models on standard datasets
  • Detectron2-based training, inference, and visualization tools

Project Samples

Project Activity

See All Activity >

Categories

AI Models

License

MIT License

Follow Mask2Former

Mask2Former Web Site

Other Useful Business Software
Full-stack observability with actually useful AI | Grafana Cloud Icon
Full-stack observability with actually useful AI | Grafana Cloud

Our generous forever free tier includes the full platform, including the AI Assistant, for 3 users with 10k metrics, 50GB logs, and 50GB traces.

Built on open standards like Prometheus and OpenTelemetry, Grafana Cloud includes Kubernetes Monitoring, Application Observability, Incident Response, plus the AI-powered Grafana Assistant. Get started with our generous free tier today.
Create free account
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of Mask2Former!

Additional Project Details

Programming Language

Python

Related Categories

Python AI Models

Registered

2025-10-07