facebookresearch

    facebookresearch/detectron2

    #327 this week

    Detectron2 is a platform for object detection, segmentation and other visual recognition tasks.

    computer-vision
    Python
    Apache-2.0
    34.7K stars
    7.9K forks
    34.7K GitHub watchers
    Updated 9/9/2026
    View on GitHub

    Build with Backblaze B2

    SDKs, agent skills, IDE extensions, and reference pipelines from Backblaze Labs. All open source.

    Explore Backblaze Labs

    Loading star history...

    Use Cases & Benefits

    • Provides a modular platform for state-of-the-art object detection, segmentation, and visual recognition tasks using deep learning.
    • Offers fast training and supports exporting models to TorchScript and Caffe2 for efficient deployment.
    • Use for developing advanced computer vision research projects requiring panoptic segmentation or rotated bounding boxes.
    • Use for building production applications that need scalable and accurate object detection and instance segmentation.
    • Use for experimenting with novel architectures like Cascade R-CNN, PointRend, and ViTDet in Python-based workflows.

    About detectron2

    Detectron2 is Facebook AI Research's next generation library that provides state-of-the-art detection and segmentation algorithms. It is the successor of Detectron and maskrcnn-benchmark. It supports a number of computer vision research projects and production applications in Facebook.


    Learn More about Detectron2

    • Includes new capabilities such as panoptic segmentation, Densepose, Cascade R-CNN, rotated bounding boxes, PointRend, DeepLab, ViTDet, MViTv2 etc.
    • Used as a library to support building research projects on top of it.
    • Models can be exported to TorchScript format or Caffe2 format for deployment.
    • It trains much faster.

    See our blog post to see more demos. See this interview to learn more about the stories behind detectron2.

    Installation

    See installation instructions.

    Getting Started

    See Getting Started with Detectron2, and the Colab Notebook to learn about basic usage.

    Learn more at our documentation. And see projects/ for some projects that are built on top of detectron2.

    Model Zoo and Baselines

    We provide a large set of baseline results and trained models available for download in the Detectron2 Model Zoo.

    License

    Detectron2 is released under the Apache 2.0 license.

    Citing Detectron2

    If you use Detectron2 in your research or wish to refer to the baseline results published in the Model Zoo, please use the following BibTeX entry.

    @misc{wu2019detectron2,
      author =       {Yuxin Wu and Alexander Kirillov and Francisco Massa and
                      Wan-Yen Lo and Ross Girshick},
      title =        {Detectron2},
      howpublished = {\url{https://github.com/facebookresearch/detectron2}},
      year =         {2019}
    }
    

    Discover Repositories

    Search across tracked repositories by name or description