Is it possible to detect damage by comparing two images

<< Hi. Is it possible to find surface damage of an object by comparing images of damaged and reference images. i mean i have two images of an object. On one image object undamaged and on other is damaged, is it possible to find damaged area (surround damaged area in some boundary box or line) by comparing images of damaged and undamaged objects? There is some example images. Two objects have same sizes.

5 Comments

Why don't you attach both the images? So that we can get some idea.
Without having experience any real experience in image processing, I would start out with transforming/rotating the image(s) so that they're both in the same position. Then something like comparing pixel intensity by taking the absolute difference between them, set a threshold manually and make a binary mask. You should end up with a black-and-white image that displays the damage done the object. But if your images are not taken in the same position (like the example above), it's most likely that the final output will differ from the actual damage.
Firstly thanks, i am too not very experienced with image processing, just started learn it for my project. By comparing pixel intensity you mean to subtract one image from another?
You also need to correct for the lighting differences. Those two pictures have different lighting intensity and different angles of lighting.

Sign in to comment.

 Accepted Answer

Florian Morsch
Florian Morsch on 24 Apr 2018
Edited: Florian Morsch on 24 Apr 2018
One other thing you could do in the case of those two images: make binary images out of them, with a threshhold set so you will have a white area within the undamaged object and when its damaged its black in the binary image because its also darker in the RGB. First take a picture of the background, then a picture of the undamaged and then of the damaged object, best would be if they are nearly in the same position. Then substract the background, so you only see your object. After that you can find the threshhold and make the binary images, in which the damaged one will be black, the undamaged should be mostly white.
I would recommend to use images from the same side (undamaged and damaged object) and also under the same conditions (lightning, backround, width, height).
This method would only allow to see if the object is damaged or not, you cant get really a indicate on how much damaged it is.

More Answers (0)

Community Treasure Hunt

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

Start Hunting!