difference in compression ratio for same wname..
显示 更早的评论
when i used this code
image2=('C:\Users\hp\Desktop\data\1 (2).JPG');
wavemngr('del','josh');
WAVEMNGR('add','shivjoshi','josh',1,'','newwavelet.m')
OUT1 = WAVEMNGR('read')
[C,S] = wavedec2(image2,2,'josh');
thr=1.0000;
[Xcomp,CXC,LXC,PERF0,PERFL2] =wdencmp('gbl',C,S,'josh',2,thr,'h',1);
and put the value in function 'newwavelet' same as value of 'db4',i.e. [-0.0106 0.0329 0.0308 -0.1870 -0.0280 0.6309 0.7148 0.2304] i am getting different results. e.g. in this code, m getting
The compression ratio is 58.8000
Retained Energy is 99.9999
PSNR value of decompressed image is 91.1471
and when i used the code
image=rgb2gray(imread('C:\Users\hp\Desktop\data\1 (2).jpg'));
K=image;
% wavelet decomposition
[C,S] = wavedec2(image,3,'db4');
thr=1.0000;
[Xcomp,CXC,LXC,PERF0,PERFL2] =wdencmp('gbl',C,S,'db4',2,thr,'h',1);
, m getting
The compression ratio is 55.0297
Retained Energy is 99.9997
PSNR value of decompressed image is 117.8089
why the results are varying??
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Denoising and Compression 的更多信息
产品
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!