Added template method design pattern for Facedetection