• Stars
    star
    123
  • Rank 288,507 (Top 6 %)
  • Language
    Python
  • Created almost 7 years ago
  • Updated almost 6 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

An interactive image segmentation tool for image segmentation labeling, which use GrabCut and implemented in OpenCV 3 and Python.

InteractiveImageSegmentation

An interactive image segmentation tool for pixel-wise labeling image dataset in segmentation task, which use GrabCut("โ€œGrabCutโ€: interactive foreground extraction using iterated graph cuts") and implemented in OpenCV 3 and Python. An OpenCV tutorial can be found here.

Quick Start

Go to this project dir and run 'python interactive_image_segmentation.py resouce/images/ resouce/labels'. You will see a UI window and you can start labelling. If you want to label your own images, collect them into a filefolder, modify the source_dir and save_dir.

How to use

  • CTRL+left mouse button: label certain background pixels
  • SHIFT+left mouse button: label certain foreground pixels
  • CTRL+right mouse button: label possible background pixels
  • SHIFT+right mouse button: label possible foreground pixels
  • 'a'/SPACE: run sengementation again
  • 's'/ENTER: save label and skip to next image
  • 'p': prev image
  • 'n': next image
  • 'q'/ESC: exit

There are some useful py scripts you can use to handle your own data. Usage:

  • 'interactive_image_segmentation.py image_dir save_dir' runs interactive image segmentation
  • 'batch_rename.py dir1 [dir2] ...' renames all images in folder with sequencial numbers.
  • 'img_cvt_format.py image_dir [suffix]' converts all images in folder to the same image format, such as '.png' '.jpg'...
  • 'video2img.py video_file save_dir [stride] [resize] [suffix]' converts a video file to a list of images.

License

This project is released under a MIT license.

More Repositories

1

minimum_snap_trajectory_generation

easy sample code for minimum snap trajectory planning in MATLAB
MATLAB
204
star
2

PnPL

Perspective n Point and Line for camera pose estimation.
C++
135
star
3

libicp

C++ Library for Iterative Closest Point fitting. http://www.cvlibs.net/software/libicp/ . Fix some mistake in point-to-plane icp implementation. Add a robust threshold to improve the precision.
C++
135
star
4

vio_evaluation

Compare state-of-the-art VO/VSLAM/VIO packages in EuRoC datasets. Algorithms include VINS, MSCKF, ORB-SLAM, SVO2 etc.
Python
124
star
5

viola

VIOLA(Vision-Imu-Odometry LibrAry) is a versatile C++ library for vision/robotics system. We try to build it as a common basic library for vision/robotics packages.
C++
74
star
6

PEAC

PEAC(Plane Extraction using Agglomerative Clustering) is a fast plane segmentation algorithm for organized point cloud. This is a fork of peac (http://www.merl.com/research/license)
C++
59
star
7

xviewer

XViewer is a easy tools for data visualization. You can use it to visualize a data file or a data dir such as EuROC, TUM VIO dataset.
13
star
8

svo2_noros

sample project to use SVO2.0 for mono/stereo visual odometry without ros
C++
10
star
9

openvins_mobile

C++
9
star
10

visionlib

This repository contains a lot of useful functions including data process, vision process, and so on.
C++
4
star
11

ros_sample_stereo_image_sync

Sample codes for synchronize left and right image message, and show how to use nodelet.
C++
4
star
12

face_recognition

Demo code for python face recognition package. A face attendance UI by pyqt5.
Python
1
star