How to compare 2 images for similarity?

The task I have to compare 2 images and say whether they are similar. To begin, I find the histogram of each image and compare their similarity measure. Next, the resulting distance and compare with a certain threshold if it is less than the threshold, then performing the counting of AKAZE descriptor, filtered by Hamming distance and the RANSAC filter. next, check that after filtering ssaza left more than 6, more if we say that images are similar. how do you like my approach? is it right?
March 23rd 20 at 19:38
3 answers
March 23rd 20 at 19:40
Can a neural network? And the histogram may be the same, not similar images.
March 23rd 20 at 19:42
https://github.com/JohannesBuchner/imagehash - the source is in Python, but is described in some detail, can be moved to another PL if desired.
Verifies that visual similarity between images - is quite accurate..
phash is already implemented - Kamille.Hartmann commented on March 23rd 20 at 19:45
March 23rd 20 at 19:44
Know a JS only solution https://github.com/mapbox/pixelmatch
will not go. there I realized pixel by pixel comparison - Kamille.Hartmann commented on March 23rd 20 at 19:47

Find more questions by tags OpenCVJava