Compression Ratio of an image using matlab
5 ビュー (過去 30 日間)
古いコメントを表示
I was trying to calculate the CR(compressing ratio) of an image that I compressed and decompressed using FFT in matlab. I have read a similar post here about CR calculation but I did not get the method he was using to process the image. That post was saying that : CR = numel(X)/numel(Y) What I understood is that X is my image before FFT and Y is after.
But this results in CR =1 which I do not think that is the correct answer. Can someone explain to me what am I missing?
0 件のコメント
回答 (2 件)
Walter Roberson
2015 年 11 月 24 日
fft is not in itself an image compression technique.
However, you can do fft and you can check to see which positions of the result have the greatest absolute magnitude. Then you can construct a list of the most important coefficients together with their positions, selecting only some of them. If the storage required for the coefficients plus the storage required for the position information is less than the storage required for the original coefficients, then you get compression.
0 件のコメント
Image Analyst
2015 年 11 月 24 日
You need to look at the size on disk. Use the dir() function. Once they're read back in and decompressed into a rows x columns 2-D uint8 image, both will be the same size in memory so that's why you got a Cr of 1 and that's why you need to look at the size on disk.
0 件のコメント
参考
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!