{"id":20826726,"url":"https://github.com/cedrickchee/realtime-detectron","last_synced_at":"2025-08-21T01:13:40.355Z","repository":{"id":138118662,"uuid":"120708160","full_name":"cedrickchee/realtime-detectron","owner":"cedrickchee","description":"Real-time Detectron using webcam.","archived":false,"fork":false,"pushed_at":"2018-09-06T07:52:21.000Z","size":11,"stargazers_count":40,"open_issues_count":3,"forks_count":8,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-05-07T20:38:43.408Z","etag":null,"topics":["deeplearning","demo","detectron","mask-rcnn","object-detection","object-segmentation","real-time","webcam"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cedrickchee.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2018-02-08T03:55:38.000Z","updated_at":"2025-02-21T15:50:05.000Z","dependencies_parsed_at":"2024-03-26T12:15:27.193Z","dependency_job_id":null,"html_url":"https://github.com/cedrickchee/realtime-detectron","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cedrickchee/realtime-detectron","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedrickchee%2Frealtime-detectron","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedrickchee%2Frealtime-detectron/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedrickchee%2Frealtime-detectron/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedrickchee%2Frealtime-detectron/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cedrickchee","download_url":"https://codeload.github.com/cedrickchee/realtime-detectron/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cedrickchee%2Frealtime-detectron/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271411623,"owners_count":24754971,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-20T02:00:09.606Z","response_time":69,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["deeplearning","demo","detectron","mask-rcnn","object-detection","object-segmentation","real-time","webcam"],"created_at":"2024-11-17T23:09:51.417Z","updated_at":"2025-08-21T01:13:40.349Z","avatar_url":"https://github.com/cedrickchee.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Real-time Detectron\n\nThis is a demo project of a real-time Mask R-CNN using [Detectron](https://github.com/facebookresearch/Detectron). We will be using consumer grade webcam for capturing the video stream.\n\nHere's an [example of demo](https://www.reddit.com/r/MachineLearning/comments/7vuqvc/p_realtime_mask_rcnn_using_facebook_detectron/) created by reddit's user `_sshin_`.\n\n**Project Status:** Early release. Still in heavy development. What this means is, things might be moved around quickly and things will break.\n\n## Introduction\n\nDetectron is Facebook AI Research (FAIR)'s research platform for object detection research, implementing popular algorithms like Mask R-CNN and RetinaNet.\n\nIn this project, we have implemented a simple solution to run Detectron Mask R-CNN algorithm with webcam. We are using Mask R-CNN for object detection and instance segmentation.\n\n## Installation\n\nRuntime requirements:\n* Python 2.7\n    * Note: [Python 3 is not supported by Detectron yet](https://github.com/facebookresearch/Detectron/issues/85)\n* Ubuntu Linux\n    * Tested in Ubuntu 16.04 LTS.\n* CUDA 8 and above\n    * Tested with CUDA 8 and CUDA 9.\n* cuDNN 6 and above\n* OpenCV 3.4\n* Python dependencies\n    * Detectron\n    * Caffe2 (Detectron is powered by the [Caffe2](https://github.com/caffe2/caffe2) deep learning framework)\n\n### Installing Detectron\n\nHow to install Detectron and its dependencies (including Caffe2). Please refer to this [guide](https://github.com/facebookresearch/Detectron/blob/master/INSTALL.md).\n\n## Quick Start: Using Detectron\n\nAfter installation, please see the following for brief instructions covering inference with Detectron.\n\n## Inference with Pretrained Models\n\n#### Directory of Image Files\nTo run inference on a directory of image files (`demo/*.jpg` in this example), you can use the `inference.py` tool. In this example, we're using an end-to-end trained Mask R-CNN model with a ResNet-101-FPN backbone from the model zoo:\n\nFirst, place `inference.py` file in Detectron `tools` directory and `visualize.py` file in Detectron `lib/utils` directory. Then, run the following command:\n\n```\npython2 tools/infererence.py \\\n    --cfg configs/12_2017_baselines/e2e_mask_rcnn_R-101-FPN_2x.yaml \\\n    --output-dir /tmp/detectron-visualizations \\\n    --image-ext jpg \\\n    --wts https://s3-us-west-2.amazonaws.com/detectron/35861858/12_2017_baselines/e2e_mask_rcnn_R-101-FPN_2x.yaml.02_32_51.SgT4y1cO/output/train/coco_2014_train:coco_2014_valminusminival/generalized_rcnn/model_final.pkl \\\n    demo\n```\n\nDetectron should automatically download the model from the URL specified by the `--wts` argument. This tool will output visualizations of the detections in the directory specified by `--output-dir`.\n\n**Notes:**\n\nThe code used for this demo in `inference.py` is the same as the one mentioned in [Detectron documentation](https://github.com/facebookresearch/Detectron/blob/master/GETTING_STARTED.md#1-directory-of-image-files) except with a few modifications to support webcam as input.\n\n## Credits\n\nReferenced these implementations:\n\n1. [Demo with Mask R-CNN in Google Colab with GPU acceleration](https://github.com/OSSDC/OSSDC-VisionBasedACC/blob/master/image-segmentation/ossdc_matterport_Mask_RCNN_colaboratory.ipynb)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedrickchee%2Frealtime-detectron","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcedrickchee%2Frealtime-detectron","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcedrickchee%2Frealtime-detectron/lists"}