I have read some articles about image hashing, and I would like to know if we could apply this technique for general purpose images classification tasks.

Especially I would like to know which could be the drawbacks in using image hashing for this kind of tasks.

  • 1
    $\begingroup$ So you want to learn the hash that maps the raw features to its class? You can think of the usual way of classification in that light if you want: take your model's output, and set the class with the highest output to 1, and the others to 0. That's a hash. You can do the same thing in the multi-class case. Hashing is usually a consideration in retrieval, not classification; e.g., finding similar images. $\endgroup$
    – Emre
    Mar 12, 2018 at 16:39

1 Answer 1


You could, but it won't be very effective.

Image hashing is aimed at detecting two instances of almost the same image. So, if your training set contains an image of a dog, and the test set contains an almost-identical image, then using image hashing you could use that to learn the label of the test set image. But in practice that doesn't provide much generalization power. In practice, we want to take hundreds of different images of dogs, and use that to learn to recognize new images of docs, so that if in the test set we are given a totally new image of a dog, we can still classify it as a dog. Image hashing won't help with that.

In other words, image hashing isn't designed for this sort of thing and will work poorly.


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.