/Mask-Cascade-RCNN

A simple Mask-Cascade-RCNN implementation.

Primary LanguageJupyter Notebook

Mask-Cascade-RCNN

A simple Mask-Cascade-RCNN implementation. Not perfect, only for learning and reference.

Paper:

Mask RCNN
Cascade RCNN

Motivation

The purpose of implementing this code is to comb the knowledge system of Mask-RCNN and Cascade-RCNN, and make the code readable and easy for others to learn.

Most implementations of Mask-RCNN are very complex and hard to read, and this repo, without the need for compilation and complex installation, is very handy. The code structure was a reference to Detectron2, and it was very easy to run on WINDOWS and LINUX.

How to use

  • If you want to train this model, you can easily start by modifying config.pyand using python train.py.
  • If you want to use trained weights, here is a checkpoint with only a simple train without tuning, but it's a little bit bigger (1.1gb, ResNet-101 as backbone). Note the modification of the checkpoint file path in the demo code.
  • Refer to demo.py for the test.

If you want to train your custom dataset, please refer here to write your own dataset code.

Environment

torch>=1.4
torchvision>=0.4
opencv-python==4.1.2.30
albumentations
pillow
timm
tensorboardX
easydict
fvcore

Dataset

The dataset currently used is WGISD.

This is a small dataset, which is convenient for experiments.

Experiments and results

The train curve

curve

Result visualization

sample

result