5
我想知道是否有人成功地使用了潜在支持向量机探测器(http://docs.opencv.org/modules/objdetect/doc/latent_svm.html)的OpenCV实现。有一个示例代码展示了如何利用库,但问题是示例代码使用了使用MatLab生成的现成检测器模型。有人能指导我完成如何生成我自己的探测器模型的步骤吗?OpenCV和潜伏支持向量机探测器
我想知道是否有人成功地使用了潜在支持向量机探测器(http://docs.opencv.org/modules/objdetect/doc/latent_svm.html)的OpenCV实现。有一个示例代码展示了如何利用库,但问题是示例代码使用了使用MatLab生成的现成检测器模型。有人能指导我完成如何生成我自己的探测器模型的步骤吗?OpenCV和潜伏支持向量机探测器
本文作者的MATLAB实现LatSVM有一个名为pascal
的训练脚本。有一个与压缩包,解释其用途的自述:
Using the learning code ======================= 1. Download and install the 2006-2011 PASCAL VOC devkit and dataset. (you should set VOCopts.testset='test' in VOCinit.m) 2. Modify 'voc_config.m' according to your configuration. 3. Start matlab. 4. Run the 'compile' function to compile the helper functions. (you may need to edit compile.m to use a different convolution routine depending on your system) 5. Use the 'pascal' script to train and evaluate a model. example: >> pascal('bicycle', 3); % train and evaluate a 6 component bicycle model The learning code saves a number of intermediate models in a model cache directory defined in 'voc_config.m'.
欲了解更多信息,请访问authors website。该页面还包含这种方法的论文。
根据您打算做的事情,您可能会发现在OpenCV(机器学习库)中更通用的SVM实现效果更好。例如,对于简单的HoG,只需创建一个SVM对象,计算HoG并使用'SVM :: train_auto()' – Bee 2012-11-21 22:43:04
@Yamaneko将其输入到SVM中我已经使用您提到的MATLAB代码训练了许多模型,但是Cann找不到将这些模型转换为.xml格式的方法,以便我可以将它们与OpenCV代码一起使用。 – 3yanlis1bos 2014-10-27 08:13:11