Home > Academics, iDea, Labs, Research, Reviews, Tutorials > Image Segmentation using Gaussian Mixture Model (GMM) and BIC

Image Segmentation using Gaussian Mixture Model (GMM) and BIC

A while ago, I was so amazed about the image segmentation results using Gaussian Mixture Models (GMMs) because GMM gives pretty good results on normal/natural images. There are some results on my previous post. Of course, GMM is not the best for this job, but hey look at its speed and easiness to implement–it’s pretty good in that sense. However, one problem with GMM is that we need to pick the number of components. In general, the more component numbers we assume, the better log-likelihood it would be for GMM. In that case, we would simply send the number of components to infinity, right? Well…but there is nothing good come out of that because the segment would not be so meaningful–in fact, we overfit the data, which is bad.

Therefore, Bayesian Information Criteria (BIC) is introduced as a cost function composing of 2 terms; 1) minus of log-likelihood and 2) model complexity. Please see my old post. You will see that BIC prefers model that gives good result while the complexity remains small. In other words, the model whose BIC is smallest is the winner. Simple as that. Here is the MATLAB code. Below are some results from sweeping the number of components from 2 to 10. Unfortunately, the results are not what I (and maybe other audiences) desire or expect. As a human, my attention just focuses on skier, snow, sky/cloud and perhaps in the worst case, the shadows, so the suitable number of components should be 3-4. Instead, the BIC assigns 9-component model the winner which is far from I expected. So, Can I say that the straightforward BIC might not be a good model for image segmentation, in particular, for human perception? Well…give GMM-BIC a break– I think this is too early to blame BIC because I haven’t use other more sophisticated features like texture, shape, color histogram which might improve results from using GMM-BIC. The question is what are the suitable features and the number of components that makes the segmentation results using GMM-BIC similar to human perception? MATLAB code is made available here.

original image

original image

Plot of BIC of model using 7-10 components

Plot of BIC of model using 7-10 components

Advertisements
  1. Adnan
    June 22, 2011 at 12:30 pm

    Hi
    Its a nice work, Could you send me the matlab code for GMM,my email is adnanatbit@gmail.com

  2. Héla
    November 6, 2011 at 11:33 pm

    Hi, great work , Can you send me please your source code for GMM segmentation, my email is hela21@hotmail.fr

    • November 7, 2011 at 12:38 am

      Thanks, Hela. I put the code in dropbox please refer to
      https://sites.google.com/site/kittipat/imgseggmmbic

      In fact, I have a better version of the code which is more organized and probably better results, but I’m extremely busy with my defense and fund-raising event these days, so I don’t have time to comment and post the code on the Internet yet. I think I will clean up all my codes and post it on the Internet after my defense in middle of Dec. Please come back to check again. Thanks for your interest and good luck on your work, Hela!

  1. No trackbacks yet.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: