Matlab-vision包学习-Image Registration and Geometric Transformation
来源:互联网 发布:appium python client 编辑:程序博客网 时间:2024/06/18 11:42
在这一篇中,我们将介绍一个新的函数:estimateGeometricTransform,其它的函数都在之前介绍学习过了。
函数/Functions
函数名称:estimateGeometricTransform
功能:利用匹配的特征点对估计几何变换(Similarity,affine,projective transformations)
语法:tform = estimateGeometricTransform(matchedPoints1, matchedPoints2,transformType);
[tform,inlierpoints1,inlierpoints2] = estimateGeometricTransform(matchedPoints1, matchedPoints2,transformType);
[_,status] = estimateGeometricTransform(matchedPoints1, matchedPoints2,transformType);
[ _ ] = estimateGeometricTransform(matchedPoints1, matchedPoints2,transformType,Name,Value);
其中,matchedPoints1和matchedPoints2分别表示两个图像匹配的对应点;tform是几何变换对象(affine2d object/projective2d object);transformType是可以取值为’similarity'/'affine'/'projective',即几何变换的类型;status为返回状态,具体取值如下表;inlierpoints1和inlierpoints2分别为两个图像对应的内点;Name为用一对单引号包含的字符串,Value为对应Name的值。
举例:
close all; clear all; clc; % 原图像original = imread('cameraman.tif'); imshow(original); title('Base image'); % 退化图像distorted = imresize(original,0.7); distorted = imrotate(distorted,31); figure; imshow(distorted); title('Transformed image'); % 提取SURF特征点ptsOriginal = detectSURFFeatures(original); ptsDistorted = detectSURFFeatures(distorted); % 获取描述子[featuresOriginal,validPtsOriginal] = extractFeatures(original,ptsOriginal); [featuresDistorted,validPtsDistorted] = extractFeatures(distorted,ptsDistorted);% 描述子匹配index_pairs = matchFeatures(featuresOriginal,featuresDistorted); % 匹配的特征点matchedPtsOriginal = validPtsOriginal(index_pairs(:,1)); matchedPtsDistorted = validPtsDistorted(index_pairs(:,2)); %显示匹配结果figure;showMatchedFeatures(original,distorted,matchedPtsOriginal,matchedPtsDistorted);title('Matched SURF points, including outliers'); %估计几何变换矩阵[tform,inlierPtsDistorted,inlierPtsOriginal] = estimateGeometricTransform(matchedPtsDistorted,matchedPtsOriginal,'similarity'); figure;showMatchedFeatures(original,distorted,inlierPtsOriginal,inlierPtsDistorted); title('Matched inlier points'); %反变换图像 outputView = imref2d(size(original)); Ir = imwarp(distorted,tform,'OutputView',outputView); figure; imshow(Ir); title('Recovered image');
- Matlab-vision包学习-Image Registration and Geometric Transformation
- Matlab-vision包学习-Feature Detection,Extraction and Matching-匹配
- Conclusion:Image Registration and Fusion with Matlab GUI
- MATLAB and Octave Functions for Computer Vision and Image Processing
- MATLAB Functions for Computer Vision and Image Analysis
- Matlab-vision包学习-Feature Detection,Extraction and Matching-BRISK角点检测
- Matlab-vision包学习-Feature Detection,Extraction and Matching-FAST角点检测
- Matlab-vision包学习-Feature Detection,Extraction and Matching-Harris角点检测
- Matlab-vision包学习-Feature Detection,Extraction and Matching-最小特征值角点检测
- Matlab-vision包学习-Feature Detection,Extraction and Matching-MSER特征提取
- Matlab-vision包学习-Feature Detection,Extraction and Matching-SURF检测blob
- Matlab-vision包学习-Feature Detection,Extraction and Matching-提取描述子
- Matlab-vision包学习-Feature Detection,Extraction and Matching-提取HOG描述子
- Matlab-vision包学习-Feature Detection,Extraction and Matching-显示匹配结果的函数
- Matlab-vision包学习-Object Detection and Recognition-ocr函数字符识别
- Matlab-vision包学习-Object Detection and Recognition-物体识别方法中级联分类器训练
- Matlab-vision包学习-Object Detection and Recognition-标记正例
- Matlab-vision包学习-Tracking and Motion Estimation-创建Kalman滤波器
- 百度地图KEY的申请
- 拓展Object添加html标签的方法
- gcc一些有用的命令
- 杭电acm2212
- C#文件操作之FileMode
- Matlab-vision包学习-Image Registration and Geometric Transformation
- LightOJ 1341Aladdin and the Flying Carpet
- 数据密集、计算密集、IO密集
- 将DataGridView转换为DataTable
- R语言-数字、字符与向量
- java反射机制及简单工厂模式
- HDU-5119-Happy Matt Friends
- Codeforces Round #323 C GCD Table
- UITableView