opencv calib3d 模块 usac magsac Gamma 查表值验证

cpp 复制代码
void inflateGammaValues(
	std::vector<double>& gamma_complete_anchor,
	std::vector<double>& gamma_incomplete_anchor,
	std::vector<double>& gamma_anchor,
	double max_thr=7.5, double gamma_quantile = 3.04, double DOF=2,int number_of_anchor_points=50)
{
	//上不完全gamma
	gamma_complete_anchor= std::vector<double>(number_of_anchor_points),
	//下不完全gamma
	gamma_incomplete_anchor= std::vector<double>(number_of_anchor_points),
	//上不完全gamma
	gamma_anchor= std::vector<double>(number_of_anchor_points);

	const double step0 = max_thr / (number_of_anchor_points-1);
	const double step1 = max_thr* gamma_quantile / (number_of_anchor_points - 1);

	const double n_plus_1_div_2 = (DOF + 1.0) / 2.0;
	const double n_minus_1_div_2 = (DOF - 1.0) / 2.0;

	const double gamma_n_plus = boost::math::tgamma(n_plus_1_div_2);
	const double gamma_n_minus = boost::math::tgamma(n_minus_1_div_2);
	for (int i = 0; i < number_of_anchor_points; ++i)
	{
		gamma_complete_anchor[i]= boost::math::gamma_q(n_minus_1_div_2, step0 * i) * gamma_n_minus;
		gamma_incomplete_anchor[i] = boost::math::gamma_p(n_plus_1_div_2, step0 * i) * gamma_n_plus;
		gamma_anchor[i] = boost::math::gamma_q(n_minus_1_div_2, step1 * i) * gamma_n_minus;
	}
}
相关推荐
牧羊人.3331 天前
OCR 文本检测之PaddleOCR基础使用
计算机视觉·视觉检测·ocr·paddleocr·文本检测
硅谷秋水2 天前
面向精确到达任务的机器人-对齐3D高斯溅射方法——基于腕部-相机VLA策略
数码相机·机器学习·计算机视觉·3d·机器人
会飞锦鲤3 天前
基于 RT-DETR 的 PCB 缺陷检测
深度学习·目标检测·计算机视觉·pyqt5·rt-detr·工业质检·pcb缺陷检测
硅谷秋水8 天前
MorphMimic 方法分析
人工智能·机器学习·计算机视觉·机器人
jay神8 天前
基于 YOLOv8 的传送带异物检测系统(Web 版)
前端·人工智能·深度学习·yolo·计算机视觉·计算机毕业设计
Rattenking10 天前
OpenCV 轨迹栏操作和键盘响应操作
人工智能·opencv·计算机外设
jay神11 天前
基于 YOLOv8 的手势识别系统(Web 版)
前端·人工智能·python·深度学习·yolo·计算机视觉·计算机毕业设计
wangxiaoxuan21711 天前
TF2 的原理与使用:把坐标、运动和观测时间一起算清楚
计算机视觉·机器人·科沃斯八界
硅谷秋水11 天前
EgoHumanoid‑V2 方法分析
人工智能·机器学习·计算机视觉·语言模型·机器人
BYSJMG11 天前
计算机毕业设计选题推荐:【基于深度学习的车辆损坏严重程度评估方法研究】ResNet50 图像分类
人工智能·深度学习·目标检测·机器学习·计算机视觉·分类·课程设计