mpatacchiola / deepgaze

Computer Vision library for human-computer interaction. It implements Head Pose and Gaze Direction Estimation Using Convolutional Neural Networks, Skin Detection through Backprojection, Motion Detection and Tracking, Saliency Map.
MIT License
1.79k stars 478 forks source link

'MAJOR' is not defined Error #84

Closed m3m3-chan closed 5 years ago

m3m3-chan commented 5 years ago

Hello, I have installed gaze2.0 on my windows conda python 3.5 env. I want to do head position in realtime so I ran _ex_pnp_head_pose_estimationvideo.py from master branch I get the error below:

\lib\site-packages\deepgaze\haar_cascade.py", line 138, in _findFrontalFace
    if(MAJOR=='2'): flag = cv2.cv.CV_HAAR_SCALE_IMAGE
NameError: name 'MAJOR' is not defined
[ WARN:0] terminating async callback

is it possible the example is incompatible with ver2?

mpatacchiola commented 5 years ago

Hi @m3m3-chan

Thank you for pointing that out. I fixed the bug, there was a line missing at the beginning of the file. If you checkout again the library and install it should work.

m3m3-chan commented 5 years ago

@mpatacchiola Thanks for your prompt response!