呕心总结,原版,严禁转载。
做人脸检测定位很长时间了,发现doppia代码对于人脸的定位效果不错,于是就对其进行研究,简单总结如下:
1.在参数配置中eccv2014_face_detection_pascal.config.ini
num_scales不可以太小,否则得到的效果很不好;
如果值太大,运行的时间会非常长,得到的效果并不一定非常高。
通过多次测试,取num_scales=10。
2.将代码转到windows上后,发现如果是将cuda_stuff_library和cpp_stuff_library生成为动态库,会出现Lnk2019错误,但是如果是静态库就没这个问题。
3.检测器有23个,两个尺度,一个是1(11个检测器),一个是2(12个检测器),共有2000个stages
代码中使用的是12(find_nearest_scale_detector_model),即12*10=120个检测结果,然后使用非极大值抑制的方法得到相应的检测结果得分。
80*80 和160 *160两个模板窗口
尺寸:
0.30 0.41 。。。
4.通过一些测试数据发现:
图片中人脸非常大,占据整幅图像得到的检测结果不会很好,这主要是“min_scale = 0.33,max_scale = 5”造成的,可以通过改变这两个参数得到较好的结果。
5.
detection_cascade_per_scale.reserve(num_scales);
detector_cascade_relative_scale_per_scale.reserve(num_scales);
detection_window_size_per_scale.reserve(num_scales);
original_detection_window_scales.reserve(num_scales);
6.在计算特定尺寸上的检测模板时,使用V1用时要比V0少很多,且效果差别不大。
compute score cost 0ms
compute detection cost 4ms
(// compute the detections, and keep the results on the gpu memory
boost::apply_visitor(visitor, gpu_detection_variant_cascade_per_scale);)
4*120 = 480ms,即在找到人脸检测位置需要480ms。
// create the integral channels computer
integral_channels_computer_p.reset(new GpuIntegralChannelsForPedestrians());

本文探讨了Doppia代码在人脸检测中的应用与优化,关键在于调整num_scales参数,处理动态库编译错误,及优化检测器规模与模板窗口尺寸。通过参数调优,实现了更高效的人脸定位。

6181

被折叠的 条评论
为什么被折叠?



