Matlab code for matching two images

4 visualizaciones (últimos 30 días)
Karan Ratnaparkhi
Karan Ratnaparkhi el 24 de Abr. de 2011
Comentada: Image Analyst el 15 de Nov. de 2019
Hey guys I need a matlab code to check if two images are matching or not? I tried correlation but it is nt working. Please help me with the code or tell me if there is any such kind function in matlab!!
  1 comentario
David Young
David Young el 24 de Abr. de 2011
When do two images match? Do they have to be identical, or can there be some differences? In what way does correlation not work - do you get an error message, or is it that you are defining "matching" to mean something other than "highly correlated"?

Iniciar sesión para comentar.

Respuestas (3)

Image Analyst
Image Analyst el 21 de Ag. de 2014
Editada: Image Analyst el 21 de Ag. de 2014
matches = A == B;
percentMatch = 100 * sum(matches(:)) / numel(matches);
This is for grayscale images. If it's a color image, the formula needs to be modified slightly.

Mangesh
Mangesh el 21 de Ag. de 2014
the question states that, if i have images i.e A and B,and if i convert these two images in matrix form, then the matrix will match or not? if matches, then ok. if not then in what percent A matches with B????? I have the same que.

Chandrika yadav
Chandrika yadav el 15 de Nov. de 2019
matches = A == B;
percentMatch = 100 * sum(matches(:)) / numel(matches);
  1 comentario
Image Analyst
Image Analyst el 15 de Nov. de 2019
Yes, this is exactly my answer. Are you having trouble with it?

Iniciar sesión para comentar.

Categorías

Más información sobre Matrix Indexing en Help Center y File Exchange.

Productos

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by