資源簡(jiǎn)介
運(yùn)行在Matlab2012下,帶有GUI,可對(duì)彩色圖像進(jìn)行Kmeans和meanshift進(jìn)行聚類分析,生成最后的聚類圖像以及聚類中心的迭代軌跡

代碼片段和文件信息
function?Image_output=imshowResult(datarowdatacolumnkinddata)
Image_output=zeros(datarowdatacolumn3);
for?i=1:datarow
??for?j=1:datacolumn??????????%????????????????R???????????????????G?????????????????????B????
?????if(kinddata(ij)==1)??????Image_output(ij1)=255;Image_output(ij2)=255;?Image_output(ij3)=255;
?????elseif(kinddata(ij)==2)??Image_output(ij1)=255;Image_output(ij2)=0;?Image_output(ij3)=0;
?????elseif(kinddata(ij)==3)??Image_output(ij1)=0;Image_output(ij2)=0;?Image_output(ij3)=255;???
?????end
??end
end
Image_output=uint8(Image_output);?%??????????
?屬性????????????大小?????日期????時(shí)間???名稱
-----------?---------??----------?-----??----
?????文件?????????645??2015-05-11?11:13??imshowResult.m
?????文件????????2389??2015-05-07?13:54??K_meanCluster.m
?????文件???????18383??2015-05-11?12:14??MeanShift.fig
?????文件???????20595??2015-05-12?16:28??MeanShift.m
?????文件????????5192??2015-05-11?12:47??MeanShiftCluster.m
?????文件?????????253??2015-05-20?01:30??README.txt
?????文件?????????447??2015-05-09?06:11??SegImgMeanShift.m
?????文件?????????889??2015-05-09?06:46??WaterShed.m
評(píng)論
共有 條評(píng)論