hrastnik / face_detect_n_track

Fast and robust face detection and tracking
MIT License
506 stars 159 forks source link

run code error #15

Open cploveflower opened 5 years ago

cploveflower commented 5 years ago

Hello@hrastnik: when I run your code,it have a problem, I have change the video path,but it don't show anything just tell me that face_detect_n_tracker.cpp has stopped the work, I don't know why,can you help me,Thank you!

cploveflower commented 5 years ago

I debug the error in this: cv::Rect biggestFace(std::vector &faces_arr) { int biggest = 0; for (int i = 0; i < faces_arr.size(); i++) { if (faces_arr[i].area() > faces_arr[biggest].area()) { biggest = i; } } return faces_arr[biggest]; } and the debug answer like this: 0x00007FF6B0067FC0 处有未经处理的异常(在 face_detect_n_track.exe 中): 0xC0000005: 读取位置 0x000001EF3BB4F008 时发生访问冲突。 can you help me?Thank you very much

hrastnik commented 5 years ago

I haven't really touched this code for a long time. Perhaps the faces vector of faces is empty.

cploveflower commented 5 years ago

your mean is that the face detector maybe haven't detect the face?isn't it?

cploveflower commented 5 years ago

Hello@hrastnik: I want to know that if the faces vector of faces is empty, what should I do or what need to change?I'm very sorry to disturb you,but I really want to solve my problem, Thank you very much