gSLICr: Real-time super-pixel segmentation

Overview

gSLICr: SLIC superpixels at over 250Hz

sample

This is the software bundle "gSLICr", a library for real-time superpixel segmentation written in C++ and CUDA. The current version is maintained by:

Carl Yuheng Ren : [email protected]
Victor Adrian Prisacariu : [email protected]
Ian D Reid : [email protected]

For more information about gSLICr please visit the project website http://www.robots.ox.ac.uk/~victor/gslicr.

Other related projects can be found in the Oxford Active Vision Library http://www.oxvisionlib.org.

1. Updates from gSLIC

2. Building the System

2.1 Requirements

Several 3rd party libraries are needed for compiling gSLICr. The given version numbers are checked and working, but different versions might be fine as well. Some of the libraries are optional, and skipping them will reduce functionality.

2.2 Build Process

To compile the system, use the standard cmake approach:

  $ mkdir build
  $ cd build
  $ cmake /path/to/gSLICr
  $ make

To run demo:

  • plug in a webcam
  • use the standard cmake approach:
mkdir build
cd build
cmake ../
make
./demo
  • press s to save current segmentation result to current folder.

3. What to cite

If you use this code for your research, please kindly cite:

@article{gSLICr_2015,
	author = {{Ren}, C.~Y and {Prisacariu}, V.~A. and {Reid}, I.~D},
	title = "{gSLICr: SLIC superpixels at over 250Hz}",
	journal = {ArXiv e-prints},
	eprint = {1509.04232},
	year = 2015,
	month = sep
}

arxiv linke

Comments
  • Issue with different size of superpixel

    Issue with different size of superpixel

    Hello,

    I tried gSLICr by specifying different size of superpixel :

    • For spixel_size = 10, it results in a strange segmentation like on the picture [slic_size10] , with totally squared spixel. Is it supposed to work only with specific spixel_size?

    • For spixel_size = 50, there are still "orphan" superpixels as we can see on image [slic_size50]. Is the function "do_enforce_connectivity" not supposed to remove them?

      I have tried with other images and other machines but the problem seems recurrent.

    slic_size10 slic_size50

    opened by fderue 8
  • catkin integration

    catkin integration

    This add a catkin/colcon metainfo file and installation instructions to the CMake file such that this repo can be used in a catkin/colcon workspace. It does not add any new dependencies.

    opened by christian-rauch 2
  • How to access superpixel information

    How to access superpixel information

    Hey there,

    I can't figure out how to access the superpixel result correctly. I don't need the drawn output image itself but the actual superpixel information. I basically want to store the superpixel ID for each pixel as a 4th channel in the image. Is there no trivial way to do this, or am I just missing something? I also need a way to determine neighboring superpixels, if it's possible.

    Best, Alex

    opened by alexandru-lesi 2
  • why the demo gives three copies of image

    why the demo gives three copies of image

    In the demo, why the following code gives me a segmentation image with three copies??

    load_image(out_img, boundry_draw_frame);
    		imshow("segmentation", boundry_draw_frame);
    

    edge_0000

    And the following code can't save the image to pgm. It only gives a black image as following, is there something wrong?

    sprintf(out_name, "seg_%04i.pgm", save_count);	gSLICr_engine->Write_Seg_Res_To_PGM(out_name);
    
    opened by RyanCV 2
  • Fix broken headings in Markdown files

    Fix broken headings in Markdown files

    GitHub changed the way Markdown headings are parsed, so this change fixes it.

    See bryant1410/readmesfix for more information.

    Tackles bryant1410/readmesfix#1

    opened by bryant1410 0
  • There is an error in the VS2017 compiler. Can you help me

    There is an error in the VS2017 compiler. Can you help me

    gSLICr_core_engine.obj : error LNK2019: Unresolved external symbols "public: __cdecl gSLICr::engines::seg_engine_GPU::seg_engine_GPU(struct gSLICr::objects::settings const &)"

    opened by WsBai 0
  • installation instructions

    installation instructions

    This is the same as https://github.com/carlren/gSLICr/pull/26 with a different branch name. The previous PR was closed automatically after the branch was renamed.

    This adds a catkin/colcon metainfo file and installation instructions to the CMake file such that this repo can be used in a catkin/colcon workspace. It does not add any new dependencies.

    opened by christian-rauch 0
  • Build failing with error: ‘memcpy’ was not declared in this scope

    Build failing with error: ‘memcpy’ was not declared in this scope

    Ubuntu 16.04 build fails with the following output

    /usr/include/string.h: In function ‘void* __mempcpy_inline(void*, const void*, size_t)’: /usr/include/string.h:652:42: error: ‘memcpy’ was not declared in this scope return (char *) memcpy (__dest, __src, __n) + __n; ^ CMake Error at gSLICr_lib_generated_gSLICr_seg_engine_GPU.cu.o.cmake:266 (message): Error generating file /home/paperspace/gSLICr/build/CMakeFiles/gSLICr_lib.dir/gSLICr_Lib/engines/./gSLICr_lib_generated_gSLICr_seg_engine_GPU.cu.o

    CMakeFiles/gSLICr_lib.dir/build.make:265: recipe for target 'CMakeFiles/gSLICr_lib.dir/gSLICr_Lib/engines/gSLICr_lib_generated_gSLICr_seg_engine_GPU.cu.o' failed make[2]: *** [CMakeFiles/gSLICr_lib.dir/gSLICr_Lib/engines/gSLICr_lib_generated_gSLICr_seg_engine_GPU.cu.o] Error 1 CMakeFiles/Makefile2:104: recipe for target 'CMakeFiles/gSLICr_lib.dir/all' failed make[1]: *** [CMakeFiles/gSLICr_lib.dir/all] Error 2 Makefile:83: recipe for target 'all' failed make: *** [all] Error 2

    opened by travisoneill 1
  • Retrieve super pixels as cv::Contours

    Retrieve super pixels as cv::Contours

    how can you retreive the super pixels as cv::contours? or some data structure similar, so that you can then further process each super pixel individually

    opened by JadTawil-theonly 0
  • when local_id<32 , the code is different from local_id < 64;

    when local_id<32 , the code is different from local_id < 64;

    Each SM splits its own blocks into Warps (currently with a maximum size of 32 threads).

    All the threads in a warp executes concurrently on the resources of the SM ?

    __syncthreads();
    	if (should_add)
    	{
    		if (local_id < 128)
    		{
    			color_shared[local_id] += color_shared[local_id + 128];
    			xy_shared[local_id] += xy_shared[local_id + 128];
    			count_shared[local_id] += count_shared[local_id + 128];
    		}
    		__syncthreads();
    
    		if (local_id < 64)
    		{
    			color_shared[local_id] += color_shared[local_id + 64];
    			xy_shared[local_id] += xy_shared[local_id + 64];
    			count_shared[local_id] += count_shared[local_id + 64];
    		}
    		__syncthreads();
    
    		if (local_id < 32)
    		{
    			color_shared[local_id] += color_shared[local_id + 32];
    			color_shared[local_id] += color_shared[local_id + 16];
    			color_shared[local_id] += color_shared[local_id + 8];
    			color_shared[local_id] += color_shared[local_id + 4];
    			color_shared[local_id] += color_shared[local_id + 2];
    			color_shared[local_id] += color_shared[local_id + 1];
    
    			xy_shared[local_id] += xy_shared[local_id + 32];
    			xy_shared[local_id] += xy_shared[local_id + 16];
    			xy_shared[local_id] += xy_shared[local_id + 8];
    			xy_shared[local_id] += xy_shared[local_id + 4];
    			xy_shared[local_id] += xy_shared[local_id + 2];
    			xy_shared[local_id] += xy_shared[local_id + 1];
    
    			count_shared[local_id] += count_shared[local_id + 32];
    			count_shared[local_id] += count_shared[local_id + 16];
    			count_shared[local_id] += count_shared[local_id + 8];
    			count_shared[local_id] += count_shared[local_id + 4];
    			count_shared[local_id] += count_shared[local_id + 2];
    			count_shared[local_id] += count_shared[local_id + 1];
    		}
    	}
    __syncthreads();
    
    __syncthreads();
    		if (local_id < 32)
    		{
    			color_shared[local_id] += color_shared[local_id + 32];
    			xy_shared[local_id] += xy_shared[local_id + 32];
    			count_shared[local_id] += count_shared[local_id + 32];
    		}
    __syncthreads();
    if (local_id < 16)
    		{
    			color_shared[local_id] += color_shared[local_id + 16];
    			xy_shared[local_id] += xy_shared[local_id + 16];
    			count_shared[local_id] += count_shared[local_id + 16];
    		}
    __syncthreads();
    
    opened by IaGumiLukaRin 0
  • Can it be written compatibly with 64bit compilation?

    Can it be written compatibly with 64bit compilation?

    I am new to CUDA, and its version is 9.0 in my PC. My compilation process failed, and it says, "nvcc fatal : 32 bit compilation is only supported for Microsoft Visual Studio 2013 and earlier ", could you kindly tell me how to convert it to 64 bit version?

    opened by llk2why 1
Owner
Carl Yuheng Ren
Carl Yuheng Ren
Make It Pixel is a programming language to process images to look like pixel art.

Make images look like pixel art Make It Pixel is a programming language to process images to look like pixel art. Its interpreter is written in C++ an

null 21 Nov 24, 2022
⚡️Real-time portrait segmentation

ncnn-portrait-segmentation ⚡️ Real-time portrait segmentation This project provides real-time human segmentation based on CPU. Requirements ncnn openc

Youngsoo Lee 39 Dec 21, 2022
BAAF-Net - Semantic Segmentation for Real Point Cloud Scenes via Bilateral Augmentation and Adaptive Fusion (CVPR 2021)

Semantic Segmentation for Real Point Cloud Scenes via Bilateral Augmentation and Adaptive Fusion (CVPR 2021) This repository is for BAAF-Net introduce

null 90 Dec 29, 2022
Overlay Microsoft Flight Simulator (FS2020) aircraft data onto real airport charts in real-time

FLIGHTSIM CHARTS Introduction Overlay Microsoft Flight Simulator (FS2020) aircraft data onto real airport charts in real-time. Instantly teleport to a

Scott Vincent 3 May 31, 2022
Real time monaural source separation base on fully convolutional neural network operates on Time-frequency domain.

Real time monaural source separation base on fully convolutional neural network operates on Time-frequency domain.

James Fung 111 Jan 9, 2023
Updates the Wii's current system time with the real world time.

Fix Wii System Time This is a homebrew tool I made for the Wii a while ago. It updates the current system time with the real world time via worldtimea

Puzzle 2 Nov 9, 2022
Anomaly Detection on Dynamic (time-evolving) Graphs in Real-time and Streaming manner

Anomaly Detection on Dynamic (time-evolving) Graphs in Real-time and Streaming manner. Detecting intrusions (DoS and DDoS attacks), frauds, fake rating anomalies.

Stream-AD 696 Dec 18, 2022
SiriDB is a highly-scalable, robust and super fast time series database

SiriDB is a highly-scalable, robust and super fast time series database. Build from the ground up SiriDB uses a unique mechanism to operate without a global index and allows server resources to be added on the fly. SiriDB's unique query language includes dynamic grouping of time series for easy analysis over large amounts of time series.

SiriDB 471 Jan 9, 2023
A c++ trainable semantic segmentation library based on libtorch (pytorch c++). Backbone: ResNet, ResNext. Architecture: FPN, U-Net, PAN, LinkNet, PSPNet, DeepLab-V3, DeepLab-V3+ by now.

中文 C++ library with Neural Networks for Image Segmentation based on LibTorch. The main features of this library are: High level API (just a line to cr

null 310 Jan 3, 2023
Portrait segmentation in your web browser with ncnn and webassembly

ncnn-webassembly-portrait-segmentation open https://nihui.github.io/ncnn-webassembly-portrait-segmentation and enjoy build and deploy Install emscript

null 26 Dec 5, 2022
Android face detect and segmentation by ncnn

Android face detect and segmentation by ncnn

null 118 Dec 29, 2022
Android hair/human segmentation demo by ncnn

ncnn_Android_human Android hair/human segmentation demo by ncnn PS:performance maybe poor.it's just a demo:) Reference: 1.https://github.com/Tencent/n

null 23 May 23, 2022
Official page of "Patchwork: Concentric Zone-based Region-wise Ground Segmentation with Ground Likelihood Estimation Using a 3D LiDAR Sensor"

Patchwork Official page of "Patchwork: Concentric Zone-based Region-wise Ground Segmentation with Ground Likelihood Estimation Using a 3D LiDAR Sensor

Hyungtae Lim 252 Dec 21, 2022
segformer semantic segmentation infer by tengine

Segformer-tengine Segformer semantic segmentation infer by tengine 前言: 记录一下Segformer部署在tengine上的折腾过程 - 小飞飞的文章 - 知乎 https://zhuanlan.zhihu.com/p/397735

null 9 Jun 18, 2022
An implementation on Fast Ground Segmentation for 3D LiDAR Point Cloud Based on Jump-Convolution-Process.

An implementation on "Shen Z, Liang H, Lin L, Wang Z, Huang W, Yu J. Fast Ground Segmentation for 3D LiDAR Point Cloud Based on Jump-Convolution-Process. Remote Sensing. 2021; 13(16):3239. https://doi.org/10.3390/rs13163239"

Wangxu1996 59 Jan 5, 2023
A LiDAR point cloud cluster for panoptic segmentation

Divide-and-Merge-LiDAR-Panoptic-Cluster A demo video of our method with semantic prior: More information will be coming soon! As a PhD student, I don'

YimingZhao 65 Dec 22, 2022
Ground segmentation and point cloud clustering based on CVC(Curved Voxel Clustering)

my_detection Ground segmentation and point cloud clustering based on CVC(Curved Voxel Clustering) 本项目使用设置地面坡度阈值的方法,滤除地面点,使用三维弯曲体素聚类法完成点云的聚类,包围盒参数由Apol

null 9 Jul 15, 2022
A C++ Node.js module that helps gathering informations on segmentation fault

node-segfault-handler A C++ Node.js module that helps gathering informations on segmentation fault Supported Platforms Linux Linux Alpine Windows MacO

Shiranuit 12 Dec 14, 2022
Android human segmentation by ncnn

ncnn_Android_human_segmentation this project is a ncnn Android demo for RobustVideoMatting, it depends on ncnn library and opencv. https://github.com/

FeiGeChuanShu 111 Nov 30, 2022
A toolkit for pointcloud processing, including: filter, bounding box, ground segmentation, cluster

A toolkit for pointcloud processing, including: filter, bounding box, ground segmentation, cluster. And implemented by different algorithms(some with pcl wrapper). c++17 supported

Au1ong 8 Jun 23, 2022