0

希望你安然无恙。我在 C++ 中在线找到了 ASIFT 的实现(http://www.mattsheckells.com/opencv-asift-c-implementation/)。但由于某种原因,我在运行时遇到错误。我已经在 32 位版本上使用较旧的 opencv(2.4.9) 进行了尝试和测试,它运行良好,但速度很慢。现在我想在新的 opencv 版本(3x,4x)上测试它,但到目前为止还没有成功。我正在使用 VS 2019 并在 Windows 中使用 cmake 编译 opencv。为了让 Opencv 3.x 访问 sift 库,我使用相同版本的 opencv_contrib 并一起编译。但没有确凿的结果。我希望你能在这方面指导我。我可以让你知道我如何在进一步的编辑中进行设置。调试失败和错误的确切步骤已在此处发布。

//cv::xfeatures2d::SiftFeatureDetector detector;
Ptr<cv::xfeatures2d::SiftFeatureDetector> detector = makePtr<cv::xfeatures2d::SiftFeatureDetector>();
//Ptr<cv::xfeatures2d::SiftFeatureDetector> detector = cv::xfeatures2d::SiftFeatureDetector::create();
//detector.detect(timg, kps, mask);
detector->detect(timg, kps, mask);---- the program stops debugging error due to a memory error
"Unhandled exception at 0x00007FFDEC899709 in Project1_asift.exe: Microsoft C++ exception: cv::Exception at memory location 0x000000E5A319DDB8."

我在控制台上打印了这个:

"OpenCV(3.4.2) Error: The function/feature is not implemented () in cv::Feature2D::detectAndCompute, file c:\build\3_4_winpack-build-win64-vc15\opencv\modules\features2d\src\feature2d.cpp, line 154"

希望能得到积极的回应。

在此处输入图像描述

4

0 回答 0