Greeny is an application which uses Mask R-CNN TF2 the Tensorflow 2 version of Mask R-CNN originally meant for object detection and scene segmentation, to add a green screen to the background of people in any video. It supports multiple people and creates an exact cut-out of the people present in the video.
Original Image 1 | New Image 1 |
---|---|
Original Image 2 | New Image 2 |
:--: | :--: |
Demo 1 | Demo 1 Greened |
---|---|
- This project requires python version to be 3.8 >= (python versions) >=3.5.
- This project requires a gpu for faster process times.
- This project will not work with tensorflow 1.
Greeny doesn't require installation.
- You can download dependencies as follows using package manager pip.
pip install -r requirements.txt
- Download the pre-trained weights inside the root directory
mrcnn-greeny
. The weights can be downloaded from this link: https://github.com/matterport/Mask_RCNN/releases/download/v2.0/mask_rcnn_coco.h5 - Run the script
run.py
python3 run.py
- Enter video file name
Enter video filename: video.mp4
The directory tree of the project is as follows:
mrcnn:
helpers.py
requirements.txt
run.py
Google_Colab_notebook.ipynb
| MRCNN Greeny Google Colab Notebook
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.