how to obtain compressed image after neural network training ; in this code i want to display compressed image
1 次查看(过去 30 天)
显示 更早的评论
clc; clear all; close all; I=imread('jay.png'); size(I); image(I); in1=I(1:256,1:256); r=4; figure(1); imshow(in1); in2=blkM2vc(in1,[r r]); size(in2); in3=(in2/255); in4=in3; net_c=newff(minmax(in3),[4 16],{'tansig','purelin'},'trainlm'); net.trainparam.show=5; net.trainparam.epochs=300; net.trainparam.goal=1e-5; [net_s,tr]=train(net_c,in3,in4); a=sim(net_s,in3); figure(2); imshow(a); imwrite(a,'c.png'); fr=vc2blkM(a,r,256); asc=fr*255; az=uint8(asc); figure(3); imshow(az); imwrite(az,'dc.png'); disp('training is achieved');
0 个评论
回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Deep Learning Toolbox 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!