资源简介
可以计算两个三维图像的互信息值,用于配准
代码片段和文件信息
function fx=PV_MI(AABBx);
[rowAAcolumnAAhighAA]=size(AA);
[rowBBcolumnBBhighBB]=size(BB);
AA=AA+1;
BB=BB+1;%全部加1,避免为0时,作为下标时出错
Numab=zeros(256256);
Numa=zeros(1256);
Numb=zeros(1256);
count=0;
for vi=1:highBB
for vj=1:columnBB
for vk=1:rowBB
vkm=vk*2.590723;
vjm=vj*2.590723;
vim=vi*8.000000;
[xxmyymzzm]=transformation(vkmvjmvimx);
xx=xxm/1.250000;
yy=yym/1.250000;
zz=zzm/4.000000;
if xx>1&xx1&yy1&vk count=count+1;
end
grayvaluex=BB(vkvjvi);
if xx<1|xx>rowAA|yy<1|yy>columnAA|zz<1|zz>highAA
%if ptA(vivj)<1&ptB(vivj)<1 %出界点处理
%Numab(FBB(11))=Numab(FBB(11))+1;
%elseif ptA(vivj)<1&ptB(vivj)>columnBB
%Numab(FBB(1columnBB))=Numab(FBB(1columnBB))+1;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%出界处理一
% Numab(grayvaluex1)=Numab(grayvaluex1)+1;
%Numa(grayvaluex)=Numa(grayvaluex)+1;
%Numb(1)=Numb(1)+1;
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%出界处理二
%1xx xia chu jie
if xx<1&yy>=1&yy<=columnAA&zz>=1&zz<=highAA
grayvaluey=AA(1round(yy)round(zz));
Numab(grayvaluexgrayvaluey)=Numab(grayvaluexgrayvaluey)+1;
Numa(grayvaluex)=Numa(grayvaluex)+1;
Numb(grayvaluey)=Numb(grayvaluey)+1;
end
%2xx shang chu jie
if xx>rowAA&yy>=1&yy<=columnAA&zz>=1&zz<=highAA
grayvaluey=AA(rowAAround(yy)round(zz));
Numab(grayvaluexgrayvaluey)=Numab(grayvaluexgrayvaluey)+1;
Numa(grayvaluex)=Numa(grayvaluex)+1;
Numb(grayvaluey)=Numb(grayvaluey)+1;
end
%3yy xia chu jie
if yy<1&xx>=1&xx<=rowAA&zz>=1&zz<=highAA
grayvaluey=AA(round(xx)1round(zz));
Numab(grayvaluexgrayvaluey)=Numab(grayvaluexgrayvaluey)+1;
Numa(grayvaluex)=Numa(grayvaluex)+1;
Numb(grayvaluey)=Numb(grayvaluey)+1;
end
%4yy shang chu jie
if yy>columnAA&xx>=1&xx<=rowAA&zz>=1&zz<=highAA
grayvaluey=AA(round(xx)columnAAround(zz));
Numab(grayvaluexgrayvaluey)=Numab(grayvaluexgrayvaluey)+1;
Numa(grayvaluex)=Numa(grayvaluex)+1;
Numb(grayvaluey)=Numb(grayvaluey)+1;
end
%5zz xia chu jie
if xx>=1&xx<=rowAA&yy>=1&yy<=columnAA&zz<1
grayvaluey=AA(round(xx)round(yy
- 上一篇:MATLAB遗传算法215695
- 下一篇:RVM相关向量机实现代码matlab源码
相关资源
- matlab图像互信息计算
- 有效地亚像素配准方法matlab
- 傅里叶梅林FourierMellin实现图像配准
- 基于SIFT特征的图像配准Matlab源代码
- 改进后的互信息法
- 相位相关图像配准Matlab
- 基于特征匹配和RANSAC的三维点云拼接
- 模板匹配,使用matlab语言实现图像匹
- B样条弹性配准matlab
- 二进制对称信道互信息
- 基于harris角点特征的图像配准程序M
- sift特征点检测及图像拼接
- matlab连续计算图像间的互信息值
- 求两幅图像的互信息熵
- 点云配准的ICP算法代码
- MATLAB版代码红外与可见光图像配准算
- 互信息法计算延迟时间
- K近邻互信息计算程序
- 互信息近邻法估计
- 信息熵·互信息代码
- matlab互信息法求延迟时间
- MATLAB实现Harris角点检测与图像配准
- FDKFDK 三维图像重建算法
- SSDA图像匹配算法
- 两幅图像的互信息的matlab代码
- 三维点云的配准和融合
- matlab几种计算互信息的方法
- matlab实现图像的配准,手动选点
- 计算互信息的matlab程序
- FFT的图像配准
评论
共有 条评论