cv2.error: OpenCV(3.4.3) (-215:Assertion failed) !empty() in function
I think this may be due to the fact that XML file is missing or the path to it is incorrect. Could you please check that? Maybe you coul try with the full path for the haarcascade_frontalface_alt.xml file.