Sponsored Content
Special Forums UNIX and Linux Applications Compression (gzip) for image analysis Post 302591600 by rudigarude on Friday 20th of January 2012 04:07:39 AM
Old 01-20-2012
Hi Corona688,

The whole idea of compression for image retrieval is that it is a measure of entropy. If the data is completely random, then S(12) should be result in pretty much the same file size as S(1) and S(2), therefore D_comp -> 0 (i.e. D_comp converges to zero).

Your comments about a one DN value difference in a pixel may as well be a 255 difference is touched upon in the paper.

The paper does specifically describe the method in that it uses gzip 1.2.4 and that it uses the LZ77 lossless compression. It also states that the images are raw images, it doesn't elaborate further. I have taken that to mean that they are header-less images, so RGB images with 8bit colour depth converted using image magick.

I agree that cat isn't appropriate, however as a quick test I thought it would still work. It mentions that the images are combined 'as juxtaposition of pixel arrays I1 and I2'. I have taken this to mean appending the two images side by side. So I have tried this, and also one image followed by another.

Since there are lots of papers on this technique, unfortunately most referring back to this one for how it is implemented, I am sure the theory is sound. Of course I am aiming to test that for a few other situations, hence the research. I just think that I am missing some implementation subtly that isn't discussed in the paper. I am still convinced that it is the header.

If someone could explain why two files compressed individually would have a total file size less than if both of them were compressed together, then that would be great. As far as I am aware, that should not happen, even if they are completely random pieces of data.

Thank you
 

8 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Move with compression

How can I move a file and compress it at the same time? (8 Replies)
Discussion started by: truma1
8 Replies

2. UNIX for Advanced & Expert Users

Create an Ignite image on tape from Online IgniteUX image

Hi, (HP-UX 11.11) I need to create a tape image of an igniteUX image created on our igniteUX server. That is to say. I have a "Online" image of the igniteUX of the targeted system but I now need to copy it to a useable TAPE (igniteUX) image so i can build an other server from it that is not... (3 Replies)
Discussion started by: Andrek
3 Replies

3. AIX

Tape compression

Hello everyone I want to use compression in my tape when I backup some file. For example I have several files that use 50gb. If I backup this I need to use two cartridge because without compression I can backup 36gb. My question is with flag I need to use to compress and I can use 72gb in... (2 Replies)
Discussion started by: lo-lp-kl
2 Replies

4. UNIX for Advanced & Expert Users

gzip vs pipe gzip: produce different file size

Hi All, I have a random test file: test.txt, size: 146 $ ll test.txt $ 146 test.txt Take 1: $ cat test.txt | gzip > test.txt.gz $ ll test.txt.gz $ 124 test.txt.gz Take 2: $ gzip test.txt $ ll test.txt.gz $ 133 test.txt.gz As you can see, gzipping a file and piping into gzip... (1 Reply)
Discussion started by: hanfresco
1 Replies

5. Shell Programming and Scripting

Adding gzip compression to a connection using nc

Hello everyone, As the title suggests, I am attempting to test adding gzip compression to a connection to an application I am testing. Currently I have the application set up with httptunnel, which forwards the connection to the remote host. I would like to use a script to intercept the... (5 Replies)
Discussion started by: haggismn
5 Replies

6. Shell Programming and Scripting

matching image files to create one image

Hi, I have two sets of image files. Both sets have names A to Z but set 1 ends with .cdt.png and set 2 ends with .matrix.png. I want set 1 to match with set 2 if the names match (i.e. A.cdt.png will match with A.matrix.png) and with the convert image tool (program for images), it will merge the... (6 Replies)
Discussion started by: kylle345
6 Replies

7. Shell Programming and Scripting

Show Percentage Compression in GZIP

Hi, I used gzip command to compress a huge tar file. But I saw that compression % was more than 100%. It might have inflated instead , probably because tar file is already packed properly. So I thought of unzippping it. Now after unzip I expected the tar file to be of less size than... (12 Replies)
Discussion started by: vinay4889
12 Replies

8. UNIX for Advanced & Expert Users

Tar gzip compression rate

How good is the compression rate of gzip when you use tar with the gzip option? I am pretty amazed that a 1 GB file was reduced to 1019K. This is what I did. tar -cvf tar_test.tar.gz -T /list_of_files ls -hl -rw-r-----. 1 owner group 19 Jul 23 16:00 list_of_files -rw-r-----. 1 owner group... (7 Replies)
Discussion started by: cokedude
7 Replies
All times are GMT -4. The time now is 10:51 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy