Emotion-Recognition-DOF icon indicating copy to clipboard operation
Emotion-Recognition-DOF copied to clipboard

closed

Open joshuaangeles28 opened this issue 9 years ago • 4 comments

joshuaangeles28 avatar Sep 09 '16 15:09 joshuaangeles28

So it seems that there is a problem when cv2.cvtColor() is called in emotion-program.py, which is considered odd since it is a standard function in OpenCV

What version of OpenCV are you running? I suspect that since your path says "opencv-2.4.8", you are probably running an old version of OpenCV. This program was tested with OpenCV 3 or above, try installing OpenCV 3.0 or above and tell us if you still receive the same issue.

vanstorm9 avatar Sep 10 '16 16:09 vanstorm9

I already tried installing OpenCV 3.0, and the issue still persists. I have attached an image below for your reference

screen shot 2016-09-13 at 9 12 16 pm

Edit: I looked up the error "OpenCV Error: Assertion failed (scn == 3 || scn == 4) in cvtColor", and it looks like it has something to do with the code(?).

joshuaangeles28 avatar Sep 13 '16 13:09 joshuaangeles28

It is possible that the problem is variable "frame_f" could be null.

Right before line 54 (prev_gray = cv2.cvtColor(frame_f, cv2.COLOR_BGR2GRAY)), can you insert this code and tell me what prints out:


cv2.imshow("Test frame", frame_f) cv2.waitKey(0)


If frame_f is not null, then a picture show pop up.

vanstorm9 avatar Sep 20 '16 20:09 vanstorm9

Hi i'm getting fx,fy = flow[y,x].T IndexError: arrays used as indices must be of integer (or boolean) type error while running the emotion-program.py

Please help me with this

iammrj avatar Oct 17 '17 14:10 iammrj