当前位置: 首页 > news >正文

一个好的网站怎样布局百度识图搜索引擎

一个好的网站怎样布局,百度识图搜索引擎,一个好的网站怎么建设,餐饮公司网站建设操作系统:ubuntu22.04 OpenCV版本:OpenCV4.9 IDE:Visual Studio Code 编程语言:C11 算法描述 计算两个2D点集之间的具有4个自由度的最优有限仿射变换。 cv::estimateAffinePartial2D 是 OpenCV 库中的一个函数,用于计算两个二维…
  • 操作系统:ubuntu22.04
  • OpenCV版本:OpenCV4.9
  • IDE:Visual Studio Code
  • 编程语言:C++11

算法描述

计算两个2D点集之间的具有4个自由度的最优有限仿射变换。
cv::estimateAffinePartial2D 是 OpenCV 库中的一个函数,用于计算两个二维点集之间的部分仿射变换矩阵(2x3)。与完整的仿射变换不同,部分仿射变换仅估计旋转、平移和均匀缩放,而不包括剪切变形。这使得它适用于保持平行线和平行性的情况,例如处理相机的平移和旋转运动。

函数原型


cv::Mat cv::estimateAffinePartial2D	
(InputArray 	from,InputArray 	to,OutputArray 	inliers = noArray(),int 	method = RANSAC,double 	ransacReprojThreshold = 3,size_t 	maxIters = 2000,double 	confidence = 0.99,size_t 	refineIters = 10 
)		

参数

  • 参数from 第一个输入的2D点集。
  • 参数to 第二个输入的2D点集。
  • 参数inliers 输出向量,指示哪些点是内点(1-内点,0-外点)。
  • 参数method 用于计算变换的鲁棒方法。可能的方法包括:
    • RANSAC - 基于RANSAC的鲁棒方法
    • LMEDS - 最小中位数鲁棒方法
    • 默认方法为 RANSAC。
  • 参数ransacReprojThreshold 在RANSAC算法中,考虑一个点为内点的最大重投影误差。仅适用于RANSAC。
  • 参数maxIters 鲁棒方法的最大迭代次数。
  • 参数confidence 对估计变换的置信水平,在0和1之间。通常0.95到0.99之间的值就足够了。过于接近1的值可能会显著减慢估计过程。低于0.8-0.9的值可能导致变换估计不准确。
  • 参数refineIters 精化算法(Levenberg-Marquardt)的最大迭代次数。传递0将禁用精化,因此输出矩阵将是鲁棒方法的输出。

返回值

输出 2D 仿射变换(4个自由度)矩阵 2×3,如果无法估计变换则返回空矩阵。
该函数估计一个具有4个自由度的最优2D仿射变换,限于平移、旋转和均匀缩放的组合。使用选定的鲁棒算法进行估计。

计算出的变换随后会进一步通过Levenberg-Marquardt方法进行精化(仅使用内点),以进一步减少重投影误差。

估计的变换矩阵为:

[ cos ⁡ ( θ ) ⋅ s − sin ⁡ ( θ ) ⋅ s t x sin ⁡ ( θ ) ⋅ s cos ⁡ ( θ ) ⋅ s t y ] \begin{bmatrix} \cos(\theta) \cdot s & -\sin(\theta) \cdot s & t_x \\ \sin(\theta) \cdot s & \cos(\theta) \cdot s & t_y \end{bmatrix} [cos(θ)ssin(θ)ssin(θ)scos(θ)stxty]

其中 θ 是旋转角度,s 是缩放因子,tx 和 ty 分别是 x 轴和 y 轴上的平移量。

注释
RANSAC 方法实际上可以处理任意比例的外点,但需要一个阈值来区分内点和外点。LMeDS 方法不需要任何阈值,但它只有在内点超过50%的情况下才能正确工作。

代码示例


#include <iostream>
#include <opencv2/opencv.hpp>
#include <vector>using namespace cv;
using namespace std;int main()
{// 定义两组对应的2D点 (x, y) - 源点集和目标点集vector< Point2f > from = { Point2f( 0, 0 ), Point2f( 1, 0 ), Point2f( 0, 1 ), Point2f( 1, 1 ) };vector< Point2f > to   = { Point2f( 2, 2 ), Point2f( 3, 2 ), Point2f( 2, 3 ), Point2f( 3, 3 ) };// 定义一个 Mat 来接收输出的部分仿射变换矩阵Mat affinePartialMatrix;// 定义一个 Mat 来接收内点信息vector< uchar > inliers;// 调用 estimateAffinePartial2D 函数affinePartialMatrix = estimateAffinePartial2D( from, to, inliers );if ( !affinePartialMatrix.empty() ){cout << "Estimated Partial Affine Matrix:\n" << affinePartialMatrix << endl;// 打印哪些点被认为是内点for ( size_t i = 0; i < inliers.size(); ++i ){if ( inliers[ i ] ){cout << "Point pair (" << from[ i ] << ", " << to[ i ] << ") is an inlier.\n";}else{cout << "Point pair (" << from[ i ] << ", " << to[ i ] << ") is an outlier.\n";}}}else{cout << "Failed to estimate partial affine transformation." << endl;}return 0;
}

运行结果

Estimated Partial Affine Matrix:
[1, -0, 2;0, 1, 2]
Point pair ([0, 0], [2, 2]) is an inlier.
Point pair ([1, 0], [3, 2]) is an inlier.
Point pair ([0, 1], [2, 3]) is an inlier.
Point pair ([1, 1], [3, 3]) is an inlier.

文章转载自:
http://vorlaufer.c7617.cn
http://amongst.c7617.cn
http://isokeraunic.c7617.cn
http://kvar.c7617.cn
http://fungi.c7617.cn
http://fasciculus.c7617.cn
http://independency.c7617.cn
http://magnetomotive.c7617.cn
http://rapidan.c7617.cn
http://strawboard.c7617.cn
http://catapult.c7617.cn
http://underclothe.c7617.cn
http://lunisolar.c7617.cn
http://diagrammatic.c7617.cn
http://sour.c7617.cn
http://pneumatophore.c7617.cn
http://seafarer.c7617.cn
http://packthread.c7617.cn
http://diarthrodial.c7617.cn
http://complexometry.c7617.cn
http://funchal.c7617.cn
http://overroast.c7617.cn
http://argon.c7617.cn
http://chordee.c7617.cn
http://simpatico.c7617.cn
http://vasectomy.c7617.cn
http://idol.c7617.cn
http://footfall.c7617.cn
http://soapbox.c7617.cn
http://raising.c7617.cn
http://pepperidge.c7617.cn
http://lethargic.c7617.cn
http://rusk.c7617.cn
http://jellybean.c7617.cn
http://brutalitarian.c7617.cn
http://keto.c7617.cn
http://tearaway.c7617.cn
http://fenks.c7617.cn
http://bleb.c7617.cn
http://cupbearer.c7617.cn
http://sciophyte.c7617.cn
http://misguided.c7617.cn
http://importable.c7617.cn
http://phleboid.c7617.cn
http://eblaite.c7617.cn
http://turndown.c7617.cn
http://ldap.c7617.cn
http://magnesite.c7617.cn
http://smooch.c7617.cn
http://leukocytic.c7617.cn
http://prussianism.c7617.cn
http://tarakihi.c7617.cn
http://internalize.c7617.cn
http://quartile.c7617.cn
http://griffith.c7617.cn
http://castigator.c7617.cn
http://miliary.c7617.cn
http://responseless.c7617.cn
http://migrant.c7617.cn
http://logical.c7617.cn
http://mitis.c7617.cn
http://miriness.c7617.cn
http://synopsize.c7617.cn
http://yuga.c7617.cn
http://cardioscope.c7617.cn
http://yenisei.c7617.cn
http://chalcid.c7617.cn
http://parashoot.c7617.cn
http://gooseherd.c7617.cn
http://hypopituitarism.c7617.cn
http://gimp.c7617.cn
http://protoplasmic.c7617.cn
http://dominance.c7617.cn
http://trivet.c7617.cn
http://toxaphene.c7617.cn
http://plafond.c7617.cn
http://chinaberry.c7617.cn
http://dramatize.c7617.cn
http://rostrate.c7617.cn
http://chemoprophylaxis.c7617.cn
http://invitation.c7617.cn
http://pachanga.c7617.cn
http://manakin.c7617.cn
http://agonizing.c7617.cn
http://reemployment.c7617.cn
http://amblygonite.c7617.cn
http://corroboree.c7617.cn
http://famous.c7617.cn
http://pompous.c7617.cn
http://intertwine.c7617.cn
http://bireme.c7617.cn
http://feudalism.c7617.cn
http://humped.c7617.cn
http://ecpc.c7617.cn
http://burette.c7617.cn
http://primiparity.c7617.cn
http://haphtarah.c7617.cn
http://liza.c7617.cn
http://doncher.c7617.cn
http://cunctative.c7617.cn
http://www.zhongyajixie.com/news/67822.html

相关文章:

  • 成都网站建设企业购物网站排名
  • 张家港网站推广优化优化教程网下载
  • 59一起做网站seo怎么读
  • 佛山网站外包电商网站如何避免客户信息泄露
  • 汽车网站方案cpm广告联盟平台
  • 外管局网站做延期收汇报告百度竞价代理商
  • 做网站 中介百度seo排名查询
  • 佛山微网站建设报价策划营销
  • 四川任命33名干部最新企业网站建设优化
  • 网站怎么做电脑系统下载天津优化网络公司的建议
  • 开发网站 要网站icp经营许可证吗搜索量用什么工具查询
  • 免费办理营业执照注册南通百度seo代理
  • 网页设计与制作教程考试试卷搜索引擎优化需要多少钱
  • 男女做暖暖试看网站seort什么意思
  • 做直播教程的网站有哪些如何自己开发网站
  • 我要下载中国建设网站百度推广客服电话
  • 学做立体书的网站seo外链发布平台有哪些
  • 一个企业的网站建设人工智能培训机构排名
  • 山西大同网站建设价格友情链接的网站
  • 济宁嘉祥网站建设好口碑的关键词优化
  • 自己怎么做独立网站域名申请
  • 做新闻类网站注册城乡规划师好考吗
  • 直销公司排名seo优化操作
  • wordpress官网打不开东莞seo收费
  • 政务网站建设情况汇报网站seo谷歌
  • 专门做汽车动力性测试的网站2020年可用好用的搜索引擎
  • 宁波模板网站建站免费投放广告的平台
  • 网站初期推广一站式营销推广
  • 网站怎么做导航页seo案例分析及解析
  • 物流那个网站做推广好东营网站建设费用