Better way of "binary image multiplication"

3 views (last 30 days)
Hello, Question title may be unclear, but I dont know "how to ask" this question in better way.
Long story short - I am doing Landsat image change detection. At the moment, I used two years - 1990 and 2013. In year 1990 I have 3 images, in year 2013 - one.
I did my thing and got 3 binary images, representing locations, where change has happened. The Idea - i combine these 3 binary images, and I would get one clean binary difference image - I would eliminate things like clouds in one or another image. What I did now -
totalDifferences = diff1 .* diff2 .* diff3;
But there might be a flaw. Imagine regions like these:
diff1 diff2
[0, 0, 0, 1; [ 0, 0, 0, 1;
0, 0, 0, 1; 0, 0, 0, 1;
0, 1, 1, 1; 0, 1, 1, 0;
0, 1, 1, 1]; 0, 1, 0, 0];
This would produce totalDifferences the same as diff2, cause of multiplying with 0. And with 3 real images, it would shrink my valid mask even more, maybe because of shadows, or something like that.
My thought was - keep those regions (not plain pixels), which intersects, but eliminate total outliers. Any ideas, if this is do-able and maybe how?

Accepted Answer

Image Analyst
Image Analyst on 19 May 2014
You need to first and the images using the & operator. Then you need to use imreconstruct(). See my attached demos.

More Answers (0)

Tags

Community Treasure Hunt

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

Start Hunting!