Page 1 of 1

possible bug compare -metric AE for IM 6.9.7.7 Q16 Mac OSX

Posted: 2017-02-08T23:06:15-07:00
by fmw42
I have these two images from the link at the discussion at viewtopic.php?f=1&t=31374#p142609


Image

Image

If I use MAE for the search, it works fine and I get

Code: Select all

compare -metric MAE -subimage-search f81dM.png FSDKC.png diffimage.png
1994.08 (0.0304277) @ 5,0
Image

But if I use AE, I get an error message even with -dissimilarity-threshold 1. That seems to be a bug, since setting -dissimilarity-threshold 1 should permit any dissimilarity. Is that not correct?

Code: Select all

compare -metric AE -subimage-search -dissimilarity-threshold 1 f81dM.png FSDKC.png diffimage.png
compare: images too dissimilar `f81dM.png' @ error/compare.c/CompareImageCommand/986.

Re: possible bug compare -metric AE for IM 6.9.7.7 Q16 Mac OSX

Posted: 2017-02-09T04:27:19-07:00
by magick
Most metrics are normalized, AE is not. The dissimilarity threshold is relative to your metric. For AE and this sequence, use -dissimilarity-threshold 120000.

Re: possible bug compare -metric AE for IM 6.9.7.7 Q16 Mac OSX

Posted: 2017-02-09T11:20:31-07:00
by fmw42
Thanks. Is the dissimilarity-threshold needed for AE in raw values or normalized values. If I want to compute the worst possible value, then would it be total pixels in the image times 1 or times quantumvalue?