1
$\begingroup$

I have two images which are similar. I would like to highlight the pixels in the difference image (e.g. in red) if the values are not exactly 0.

How can I do that? I know I can get the image data with ImageData[image,...] and then I can caluclate the differences. But how do I find the non equal pixels and colorize them?

img1 enter image description here

img2 enter image description here

$\endgroup$
1
  • 3
    $\begingroup$ The two images are exactly same. $\endgroup$ Feb 21, 2020 at 18:07

2 Answers 2

3
$\begingroup$

Try Binarize[ImageDifference[img1, img2], 0].

$\endgroup$
0
$\begingroup$

Or you can try:

ImageDifference[img1, img2] // ImageAdjust
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.