When I run exercise_31.py I get the following error.
What am I doing wrong?
Thanks
OpenCV Error: Assertion failed (!empty()) in detectMultiScale, file /tmp/binarydeb/ros-kinetic-opencv3-3.3.1/modules/objdetect/src/cascadedetect.cpp, line 1698
[ERROR] [1594801579.399566, 1879.135000]: bad callback: <bound method LoadFace.camera_callback of <main.LoadFace object at 0x7f4e0d88fbd0>>
Traceback (most recent call last):
File “/opt/ros/kinetic/lib/python2.7/dist-packages/rospy/topics.py”, line 750, in _invoke_callback
cb(msg)
File “/home/user/catkin_ws/src/unit3_exercises/src/exercise_31.py”, line 50, in camera_callback
face = face_cascade.detectMultiScale(gray, ScaleFactor, minNeighbors)
error: /tmp/binarydeb/ros-kinetic-opencv3-3.3.1/modules/objdetect/src/cascadedetect.cpp:1698: error: (-215) !empty() in function detectMultiScale