Re: Image Analysis: identifying objects with Mathematica 7.0

*To*: mathgroup at smc.vnet.net*Subject*: [mg98714] Re: Image Analysis: identifying objects with Mathematica 7.0*From*: dh <dh at metrohm.com>*Date*: Thu, 16 Apr 2009 04:20:09 -0400 (EDT)*References*: <grupo8$m7$1@smc.vnet.net>

Hi Gideon, if I understand correctly, you want to find where a "subpicture" occurs in a larger picture. If you consider the picture as a numerrical array, then the correlation is large at places ahere the subpicture appears. Here is a simple example where we place a subpicture in the middle of a larger array: m1 = SparseArray[{{10, 10} -> 1, {10, 11} -> 1, {11, 10} -> 1, {11, 11} -> 1}, {20, 20}]; m2 = {{1, 1}, {1, 1}}; ListCorrelate[m2, m1] // MatrixForm hope this helps, Daniel GidiL wrote: > Hi All! > > I would appreciate any input on the following problem: > > After scanning my samples with TEM, I get images (JPEG or TIFF) which > contain many dimmers, e.g. gold nanoparticles connected via some > other molecule. > Approximately half of the popoulation is that of dimmers, while the > other half contains trimmers, monomers, etc. I would like to run some > statistics on the samples. > I read Theodore Gray's post in the Wolfram Blog about the new > capabilities of image processing in Mathematica 7.0.1 and I would like > to ask if it is possible to do the following in Mathematica: > > Pick out a square that contains the dimmers, define that square as a > new image, and then let Mathematica search for such an image within > the original image. > > I know that Mathematica has a new function MorphologicalComponents > that is apparently the key to getting this done, but I don't really > understand how to use it. It is also supposed to return the > coordinates of the located images, but I don't know how to extract > this output from the function. > > Thanks, > > Gideon >