Please use the repo for my book, available here: https://github.com/shantnu/PyEng
Run the code like this:
python face_detect.py abba.png
If you want to understand how the code works, the details are here:
Update: Now supports OpenCV3. This change has been made by furetosan ( https://github.com/furetosan) and tested on Linux.
To run the OpenCV3 version, run facedetect_cv3.py.