I developed an application for face detection using OpenCVs HAAR cascade face detection. The algorithm works fine, however every once in a while It finds patterns on the wal
Not a direct answer to your question, but this may help in reducing false detection.
You can get less false detection by tweaking MinNeibhbours, CV_HAAR_FIND_BIGGEST_OBJECT, and Size values.
int MinNeighbours = 7;
face_cascade.detectMultiScale( frame_gray, faces, 1.1, MinNeighbours, CV_HAAR_FIND_BIGGEST_OBJECT, Size(60, 60) );