Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
I need help with my images processing ..

Subject: I need help with my images processing ..

From: john john

Date: 23 Jan, 2013 11:17:08

Message: 1 of 3

Hi guys I'm currently doing egg counter, if eggs are just close to each other and no top on other eggs my code can count how many eggs just like this photo.
<<http://i648.photobucket.com/albums/uu201/myjonas13/29_zps61ba495f.jpg>>

and now my problem if some of the eggs is at the top my code can't recognize how many eggs are there just like this photo.
<<http://i648.photobucket.com/albums/uu201/myjonas13/soclose1_zps0ae323e7.jpg>>
<<http://i648.photobucket.com/albums/uu201/myjonas13/soclose2_zps2c041938.jpg>>

anyone can help or suggest me a better algorithm to do it? thanks in advance guys =) this is the code i used

  B = im2bw(imfilter(img2, fspecial('gaussian', sigma*3, sigma), 'replicate'), thres);
  Bl = bwlabel(B);
  Neggs = max(Bl(:))

Subject: I need help with my images processing ..

From: Martin Trauth

Date: 23 Jan, 2013 16:02:09

Message: 2 of 3

Hi John,

Maybe try this one:

http://blogs.mathworks.com/pick/2008/05/23/detecting-circles-in-an-image/

It seems to work well for overlapping objects.

Kind regards, Martin

Subject: I need help with my images processing ..

From: john john

Date: 23 Jan, 2013 17:04:09

Message: 3 of 3

Hi sir thanks, I have tried that code my problem the eggs are not exactly being in circled, can you give me an idea how to trace those eggs and form a circle?

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us