Skip to content

Graph Based Segmentation Algorithms Aproach Details

vighneshbirodkar edited this page May 12, 2014 · 1 revision

The Approach

I will try to describe the approach I am going to follow for the task. I would like to divide the task of segmenting an image into 4 steps as described below

Pre-Segmentation

In this step the image is segmented using methods from skimage.segmentation. The purpose is to group local regions by over segmenting the image. Better segmentation will be performed later by merging these regions.

RAG Construction

The graph will be a numpy 2d array in the adjacency matrix form. There will be an undirected edge between every pair of adjacent regions. In my opinion it would be beneficial to implement the graph as a class. Along with the adjacency matrix it would also store the copy of the labeled image ,a mapping from the vertices in RAG to its corresponding label in the image and other statistics of regions ( like mean color, standard deviation and number of pixels ). This would also help to make necessary adjustments when regions are merged.

Assigning Weights to RAG

Weights in the graph will represent the similarity between two regions. This is an estimation of how similar are pixels of one region to the pixels of another region. Currently I have come across one such similarity measure[1], but I imagine that in future other measures might be implemented and used.

Merging Algorithms

This routine will merge regions based on a criteria. The idea is that similar enough local regions will be merged to completely segment out objects. Initially I would like to implement a simple thresholding logic on the RAG to merge. Then I can move on to implementing the merging predicates in [1] which involve computing a distance measure between adjacent as well as connected regions. The distance measure can be easily computed if mean color ans standard deviations of regions are known. And finally, the last part will involve merging regions using N-cut.

References

[1] Regions Adjacency Graph Applied To Color Image Segmentation (2000)