Favicon of Detectron2

Detectron2

Open-source Python library for object detection and segmentation, with pretrained models and deployment exports. Licensed under Apache 2.0.

Detectron2 is an open-source Python library for developers and researchers building computer vision applications. It provides algorithms for locating objects in images and segmenting image regions, with support for training models and building research projects on top of the library. Facebook AI Research developed it as the successor to Detectron and maskrcnn-benchmark.

Its scope includes panoptic segmentation, Densepose and rotated bounding boxes. Supported approaches include Cascade R-CNN, PointRend and DeepLab, alongside ViTDet and MViTv2. That breadth makes it relevant to teams comparing detection and segmentation methods, as well as researchers who need a shared foundation for their own work.

The Model Zoo supplies downloadable trained models and baseline results. Developers can use those models as starting points, while researchers can use the published baselines to compare results. The library supports both computer vision research and production applications, including applications at Facebook.

For deployment, Detectron2 can export models to TorchScript or Caffe2 format. Those exports give developers a route from work in the library to a deployable model. The project uses the Apache 2.0 license.

Similar to Detectron2