用matlab对简单数字图像进行数字聚类处理代码,最好附上解释说明.谢个大神了.

来源:学生作业帮助网 编辑:作业帮 时间:2024/11/26 20:21:12
用matlab对简单数字图像进行数字聚类处理代码,最好附上解释说明.谢个大神了.
xW[oE+vN' ZZ5-YygVޤC+"U!EP&n¿e׻jh3;x%^I#ҟdW{L>{?~bVn~Ƀ[_{vw7&[{Oc=A'7: ]@kAkvh|Y=IR,9-8hfj<ǽjmUs3 2Kdf[Z7eM(Ww xS+0TE̞`WJ}T;e^BP-E$5a&sXdRr yUDl\|\Ą"@

用matlab对简单数字图像进行数字聚类处理代码,最好附上解释说明.谢个大神了.
用matlab对简单数字图像进行数字聚类处理代码,最好附上解释说明.谢个大神了.

用matlab对简单数字图像进行数字聚类处理代码,最好附上解释说明.谢个大神了.
wave2gray.m
function w = wave2gray(c,s,scale,border)
%WAVE2GRAY Display wavelet decomposition coefficients.
% W = WAVE2GRAY(C,S,SCALE,BORDER) displays and returns a
% wavelet coefficient image.
% EXAMPLES:
% wave2gray(c,s); Display w/defaults.
% foo = wave2gray(c,s); Display and return.
% foo = wave2gray(c,s,4); Magnify the details.
% foo = wave2gray(c,s,-4); Magnify absolute values.
% foo = wave2gray(c,s,1,'append'); Keep border values.
%
% INPUTS/OUTPUTS:
% [C,S] is a wavelet decomposition vector and bookkeeping
% matrix.
%
% SCALE Detail coefficient scaling
%--------------------------------------------------------------------
% 0 or 1 Maximum range (default)
% 2,3...Magnify default by the scale factor
% -1,-2...Magnify absolute values by abs(scale)
%
% BORDER Border between wavelet decompositions
%--------------------------------------------------------------------
% 'absorb' Border replaces image (default)
% 'append' Border increases width of image
%
% Image W:------- ------ -------------- -------------------
% | | | |
% | a(n) | h(n) | |
% | | | |
% ------- ------ h(n-1) |
% | | | |
% | v(n) | d(n) | | h(n-2)
% | | | |
% ------- ------ --------------
% | | |
% | v(n-1) | d(n-1) |
% | | |
% -------------- -------------- -------------------
% | |
% | v(n-2) | d(n-2)
% | |
%
% Here,n denotes the decomposition step scale and a,h,v,d are
% approximation,horizontal,vertical,and diagonal detail
% coefficients,respectively.
% Check input arguments for reasonableness.
error(nargchk(2,4,nargin));
if (ndims(c) = 2) | (size(c,1) = 1)
error('C must be a row vector.'); end
if (ndims(s) = 2) | isreal(s) | isnumeric(s) | (size(s,2) = 2)
error('S must be a real,numeric two-column array.'); end
elements = prod(s,2);
if (length(c) < elements(end)) | ...
(elements(1) + 3 * sum(elements(2:end - 1)) >= elements(end))
error(['[C S] must be a standard wavelet ' ...
'decomposition structure.']);
end
if (nargin > 2) & isreal(scale) | isnumeric(scale))
error('SCALE must be a real,numeric scalar.');
end
if (nargin > 3) & ischar(border))
error('BORDER must be character string.');
end
if nargin == 2
scale =1; % Default scale.
end
if nargin < 4
border = 'absorb'; % Default border.
end
% Scale coefficients and determine pad fill.
absflag = scale < 0;
scale = abs(scale);
if scale == 0
scale = 1;
end
[cd,w] = wavecut('a',c,s); w = mat2gray(w);
cdx = max(abs(cd(:))) / scale;
if absflag
cd = mat2gray(abs(cd),[0,cdx]); fill = 0;
else
cd = mat2gray(cd,[-cdx,cdx]); fill = 0.5;
end
% Build gray image one decomposition at a time.
for i = size(s,1) - 2:-1:1
ws = size(w);
h = wavecopy('h',cd,s,i);
pad = ws - size(h); frontporch = round(pad / 2);
h = padarray(h,frontporch,fill,'pre');
h = padarray(h,pad - frontporch,fill,'post');
v = wavecopy('v',cd,s,i);
pad = ws - size(v); frontporch = round(pad / 2);
v = padarray(v,frontporch,fill,'pre');
v = padarray(v,pad - frontporch,fill,'post');
d = wavecopy('d',cd,s,i);
pad = ws - size(d); frontporch = round(pad / 2);
d = padarray(d,frontporch,fill,'pre');
d = padarray(d,pad - frontporch,fill,'post');
% Add 1 pixel white border.
switch lower(border)
case 'append'
w = padarray(w,[1 1],1,'post');
h = padarray(h,[1 0],1,'post');
v = padarray(v,[0 1],1,'post');
case 'absorb'
w(:,end) = 1; w(end,:) = 1;
h(end,:) = 1; v(:,end) = 1;
otherwise
error('Unrecognized BORDER parameter.');
end
w = [w h; v d]; % Concatenate coefs.
end
if nargout == 0
imshow(w); % Display result.
end ...

用matlab对简单数字图像进行数字聚类处理代码,最好附上解释说明.谢个大神了. 哪位有Matlab进行数字图像处理的完整例子? 跪求用MATLAB编写的关于小波变换数字图像数字边缘提取的程序 写出一幅数字图像的矩阵表达式,并进行矩阵表达试,并进行简单说明 用MATLAB编程进行数字图像处理用MATLAB编程实现对一幅灰度图像的非线性对数变换,变换表达式为:g(i,j)=a+ln[f(i,j)+1]/(b*lnc).式中a,b,c用于调整曲线的位置和形状. 数字图像处理作业1)打开一个BMP文件2)将其局部区域的灰度值进行改变3)另存为一个新的BMP文件其中的第二条怎么办啊 我会对整个图像进行灰度值改变但是不会只改变局部的用的是matlab, 用C语言、VC++或matlab对简单的灰度图像进行离散傅里叶变换或沃尔什变换 MATLAB 图像处理《数字图像处理》作业不会做,谢哈!用MATLAB将一幅含有血管的医学图像进行处理,满足下面的要求:1.血管显示更加清晰;2.照亮血管的边缘. 求MATLAB数字图像特征提取的程序求一段用MATLAB编写的数字图像特征提取的程序这段程序看不懂,怎么用呢? 数字图像处理在matlab中怎么实现 如何用matlab做傅里叶反变换啊?现在需要用matlab编一个对任意数字波形进行傅里叶反变换的程序,本人matlab用的不好,请大家来帮忙解决下,谢谢! 用matlab实现bp算法,对样本进行训练 用Matlab程序对logistic人口模型进行拟合?matlab最小二乘曲线拟合对Logistic函数进行估计 matlab怎么对曲线进行平滑啊? matlab如何对函数进行采样 数字图像处理的滤波问题如果用一副原始图像减去低通滤波图像,所得到的结果与直接对原始图像进行高通滤波一样吗?为什么? 简单对论语进行评价 数字图像处理 MATLAB 为什么把图像类型转换为 double