필터 지우기
필터 지우기

Info

이 질문은 마감되었습니다. 편집하거나 답변을 올리려면 질문을 다시 여십시오.

Why imwrite compressed same size mat with different entropy to the same size (16bits)

조회 수: 1 (최근 30일)
TIAN FENG
TIAN FENG 2016년 1월 29일
마감: MATLAB Answer Bot 2021년 8월 20일
For example there are two matrix which are the same size, but one are all zeros another isn't, when i try to compress them use imwrite with jp2, the result file size are the same. some times The mattrix are 16bit int.
  댓글 수: 1
Walter Roberson
Walter Roberson 2016년 1월 29일
"An interesting point to make about the very high experimental compression rates of 25:1 and above, was that output file sizes were essentially homogeneous across all the images, where as at 10:1 and lower, file sizes ranged from 1.5 Mb to 11.5 Mb."
What compression ratio were you requesting?

답변 (1개)

Vidya Viswanathan
Vidya Viswanathan 2016년 2월 5일
I was unable to reproduce the behavior you described. I used the following code snippet to generate two images and save it in "jp2" format.
I=zeros([640 480]);
I2=rand([640 480]);
imwrite(I,'fig1.jp2');
imwrite(I2,'fig2.jp2');
This uses a default compression ratio of 1. The resultant images had significantly different sizes. The first one was just 1KB whereas "fig2" was of size 326 KB. Hence, I believe that this behavior is not consistent. Could you share the data for which you are observing this behavior?

이 질문은 마감되었습니다.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by