PIL ImageChops.difference not working correctly(?)

J

Jon Reyes

I have two images generated from ImageMagick that I need to compare throughPIL but when I compare them it says that the two images aren't identical. I tried viewing the supposed "difference" but all I see is a black image which means the two image are identical. ImageChops even returns the region where the supposed non - identical marks are, but there's nothing there. Anythoughts?

I just do this to compare if the two images are identical:
diff = ImageChops.difference(img1, img2)
if diff.getbbox() == None:
#then the images must be the same
 
J

Jon Reyes

Wow, what the heck, I just learned that using beyond compare if I compare the two images then I'll see a different section under tolerance mode. Anyone an expert on images? The two images have whites on that same image but they're different according to BeyondCompare. What's more, if I do a binary comparison the two images are the same. Guess I'll just find a way to compare images through binary in Python.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,565
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top