Image comparison - fast algorithm

后端 未结 9 1537
谎友^
谎友^ 2020-11-21 15:02

I\'m looking to create a base table of images and then compare any new images against that to determine if the new image is an exact (or close) duplicate of the base.

<
9条回答
  •  故里飘歌
    2020-11-21 15:47

    Picking 100 random points could mean that similar (or occasionally even dissimilar) images would be marked as the same, which I assume is not what you want. MD5 hashes wouldn't work if the images were different formats (png, jpeg, etc), had different sizes, or had different metadata. Reducing all images to a smaller size is a good bet, doing a pixel-for- pixel comparison shouldn't take too long as long as you're using a good image library / fast language, and the size is small enough.

    You could try making them tiny, then if they are the same perform another comparison on a larger size - could be a good combination of speed and accuracy...

提交回复
热议问题