当前位置:编程学习 > Matlab >>

怎样用matlab保存多张图像?就是要把下面的a中的图像在另外一个文件夹里保存,格式与I相同

clc clear; allsamples=[];%所有训练图像 nump=10; nots=5; for i=1:nump for j=1:nots I=imread(strcat('D:\rawdata\s',num2str(i),'\',num2str(j),'.pgm')); I2=imcrop(I,[0 20 95 100]); a=imresize(I2,0.35); figure(1),imshow(I2) figure(2),imshow(a) end end
CopyRight © 2012 站长网 编程知识问答 www.zzzyk.com All Rights Reserved
部份技术文章来自网络,