OpenCV小项目与OpenCV一些非常有用的代码

上传者: q6115759 | 上传时间: 2021-08-11 20:24:58 | 文件大小: 3.06MB | 文件类型: ZIP
OpenCV小项目 这是一个个人在使用OpenCV过程中写的一些小项目,以及一些非常有用的OpenCV代码,有些代码是对某论文中的部分实现。 注意:代码是在Xcode里写的,如果要在win下测试,遇到问题自己修改。 opencv-rootsift-py 用python和OpenCV写的一个rootsift实现,其中RootSIFT部分的代码参照Implementing RootSIFT in Python and OpenCV这篇文章所写,通过这个你可以了解Three things everyone should know to improve object retrieval这篇文章中RootSIFT是怎么实现的。 sift(asift)-match-with-ransac-cpp 用C++和OpenCV写的一个图像匹配实现,里面包含了采用1NN匹配可视化、1NN匹配后经RANSAC剔除错配点可视化、1NN/2NN<0.8匹配可视化、1NN/2NN<0.8经 RANSAC剔除错配点可视化四个过程,其中1NN/2NN<0.8匹配过程是Lowe的Raw feature match,具体可以阅读Lowe的Distinctive image features from scale-invariant keypoints这篇文章。这个对图像检索重排非常有用。另外里面还有用OpenCV写的ASIFT,这部分来源于OPENCV ASIFT C++ IMPLEMENTATION,ASIFT还可以到官网页面下载,ASIFT提取的关键点 比SIFT要多得多,速度非常慢,不推荐在对要求实时性的应用中使用。 更多详细的分析可以阅读博文SIFT(ASIFT) Matching with RANSAC。 有用链接 OpenCV3.0文档 // 测试sparse unsigned int centersNum = 10; vector descrNums; descrNums.push_back(8); descrNums.push_back(12); //unsigned int T[] = {1, 2, 1, 3, 2, 5, 4, 3, 10, 5; 4, 2, 6, 5, 2, 5, 4, 6, 2, 4}; unsigned int T[] = {1, 2, 1, 3, 2, 5, 4, 3, 10, 5, 4, 2, 6, 5, 2, 5, 4, 6, 2, 4}; sp_mat Hist(descrNums.size(), centersNum); static long int count = 0; for (int i = 0; i < descrNums.size(); i++){ unsigned int* desrcElementsTmp = new unsigned int[descrNums[i]]; memcpy(desrcElementsTmp, T + count, descrNums[i] * sizeof(T[0])); //cout << desrcElementsTmp[0] << '\t' << desrcElementsTmp[1] << '\t' << desrcElementsTmp[2] << '\t' << desrcElementsTmp[3] << '\t' << desrcElementsTmp[4] << '\t' <

文件下载

资源详情

[{"title":"( 28 个子文件 3.06MB ) OpenCV小项目与OpenCV一些非常有用的代码","children":[{"title":"opencv-practical-code-master","children":[{"title":".gitignore <span style='color:#111;'> 2.58KB </span>","children":null,"spread":false},{"title":"README.md <span style='color:#111;'> 2.83KB </span>","children":null,"spread":false},{"title":"opencv-rootsift-py","children":[{"title":"ex002_opencvSurf.py <span style='color:#111;'> 634B </span>","children":null,"spread":false},{"title":"ex003_rootsift","children":[{"title":"rootsift.py <span style='color:#111;'> 792B </span>","children":null,"spread":false},{"title":"all_souls_000041.jpg <span style='color:#111;'> 466.71KB </span>","children":null,"spread":false},{"title":"example.png <span style='color:#111;'> 218.99KB </span>","children":null,"spread":false},{"title":"driver.py <span style='color:#111;'> 1.22KB </span>","children":null,"spread":false},{"title":"all_souls_000035.jpg <span style='color:#111;'> 504.09KB </span>","children":null,"spread":false},{"title":"sift_matching.py <span style='color:#111;'> 2.58KB </span>","children":null,"spread":false},{"title":"rootsift_test.py <span style='color:#111;'> 722B </span>","children":null,"spread":false},{"title":"rootsift.rar <span style='color:#111;'> 1.16MB </span>","children":null,"spread":false}],"spread":true},{"title":"ex001_opencvSift.py <span style='color:#111;'> 735B </span>","children":null,"spread":false}],"spread":true},{"title":"sift(asift)-match-with-ransac-cpp","children":[{"title":"main.cpp <span style='color:#111;'> 3.50KB </span>","children":null,"spread":false},{"title":"ASiftDetector.h <span style='color:#111;'> 805B </span>","children":null,"spread":false},{"title":"DSC_2624_resize.JPG <span style='color:#111;'> 170.65KB </span>","children":null,"spread":false},{"title":"utils.h <span style='color:#111;'> 904B </span>","children":null,"spread":false},{"title":"DSC_2625_resize.JPG <span style='color:#111;'> 171.98KB </span>","children":null,"spread":false},{"title":"ASiftDetector.cpp <span style='color:#111;'> 2.70KB </span>","children":null,"spread":false},{"title":"utils.cpp <span style='color:#111;'> 2.83KB </span>","children":null,"spread":false}],"spread":true},{"title":"geometric-verification-for-sift-match","children":[{"title":"matches_2nn1.txt <span style='color:#111;'> 1.97KB </span>","children":null,"spread":false},{"title":"frames11.txt <span style='color:#111;'> 32.91KB </span>","children":null,"spread":false},{"title":"utils.h <span style='color:#111;'> 1.58KB </span>","children":null,"spread":false},{"title":"img1.jpg <span style='color:#111;'> 207.15KB </span>","children":null,"spread":false},{"title":"visualindex.cpp <span style='color:#111;'> 7.55KB </span>","children":null,"spread":false},{"title":"img2.jpg <span style='color:#111;'> 196.87KB </span>","children":null,"spread":false},{"title":"frames22.txt <span style='color:#111;'> 30.94KB </span>","children":null,"spread":false},{"title":"geometricVerification.cpp <span style='color:#111;'> 1.55KB </span>","children":null,"spread":false},{"title":"utils.cpp <span style='color:#111;'> 11.62KB </span>","children":null,"spread":false}],"spread":true}],"spread":true}],"spread":true}]

评论信息

免责申明

【只为小站】的资源来自网友分享,仅供学习研究,请务必在下载后24小时内给予删除,不得用于其他任何用途,否则后果自负。基于互联网的特殊性,【只为小站】 无法对用户传输的作品、信息、内容的权属或合法性、合规性、真实性、科学性、完整权、有效性等进行实质审查;无论 【只为小站】 经营者是否已进行审查,用户均应自行承担因其传输的作品、信息、内容而可能或已经产生的侵权或权属纠纷等法律责任。
本站所有资源不代表本站的观点或立场,基于网友分享,根据中国法律《信息网络传播权保护条例》第二十二条之规定,若资源存在侵权或相关问题请联系本站客服人员,zhiweidada#qq.com,请把#换成@,本站将给予最大的支持与配合,做到及时反馈和处理。关于更多版权及免责申明参见 版权及免责申明