I've been trying to use OpenCV for face detection (using haar classifiers cascades). I've found out that for some pictures a face is not recognized, but if you put the same image into another one the face will be detected. Moreover, If you resize the Image (I do it one pixel after another of the image's width) openCV sometimes find the image.
I have tried to find out if there is anything common to all of these images (I have hundreds of jpeg images that has this problem) but could not find a clue. My guess is that it has something to do with the way OpenCV "walks over" the image but I don't really have any way to prove it.
I am attaching two images for you to try one will be detected and the other will not