Annotation tool using GrabCut() of OpenCV

Annotation tool using GrabCut() of OpenCV.

It can be used to create datasets for semantic segmentation.

* Due to GrabCut’s algorithm, it is suitable for annotation of data with clear boundaries.

  • opencv-python 4.5.2.54 or later
  • Pillow 7.2.0 or later
  • PySimpleGUI 4.32.1 or later

│  app.py │  config.json │ ├─core │  │  gui.py │  └─util.py │ ├─input │ └─output ├─image └─annotation

app.py, core/gui.py, core/util.py

Source code.

input

Image files are stored in this directory.

output

Directory to save annotation results.

  • image:The resized image is stored here
  • annotation:Annotation result is stored her
    * Saved in PNG format in palette mode

Start it with the following command.

python app.py

The following options can be specified.

  • –input

    Input image storage path

    Default:input

  • –output_image

    Storage path of annotation result (image)

    Default:output/image

  • –output_annotation

    Storage path of annotation result (segmentation image)

    Default:output/annotation

  • –config

    Configuration file to be loaded

    Default:config.json

File select

You

 

 

 

To finish reading, please visit source site