Results 1 to 4 of 4

Thread: Compressibility Tool

  1. #1
    Member
    Join Date
    Jun 2008
    Location
    G
    Posts
    372
    Thanks
    26
    Thanked 22 Times in 15 Posts

    Compressibility Tool

    Hi,

    exists a Tool which takes a file as input and prints number as output, which measures the compressibility of the input file?

    It needs to working in linux. I thinking at a number between 0- 255 like it is implemented in zpaq.

    Thank you in advance.

  2. #2
    Administrator Shelwien's Avatar
    Join Date
    May 2008
    Location
    Kharkov, Ukraine
    Posts
    3,134
    Thanks
    179
    Thanked 921 Times in 469 Posts
    1. Take a codec you like (preferably latest paq8px for more precise results, or zstd for speed)
    2. Compress the file
    3. Calculate bpc as 8*archive_size/original_size
    4. If bpc<8 then file is compressible

    So actual "tool" can be implemented as a shell script.
    There's really no other way to do it - even for paq8px there'd be some files which it can't compress,
    but some other tool can.

    At most you can optimize some compression algorithm for this task, by cutting off actual output, etc.
    But any fast method would be imprecise - it won't do recompression, for example.

  3. #3
    Member
    Join Date
    Jun 2008
    Location
    G
    Posts
    372
    Thanks
    26
    Thanked 22 Times in 15 Posts
    Quote Originally Posted by Shelwien View Post
    1. Take a codec you like (preferably latest paq8px for more precise results, or zstd for speed)
    2. Compress the file
    3. Calculate bpc as 8*archive_size/original_size
    4. If bpc<8 then file is compressible

    So actual "tool" can be implemented as a shell script.
    There's really no other way to do it - even for paq8px there'd be some files which it can't compress,
    but some other tool can.

    At most you can optimize some compression algorithm for this task, by cutting off actual output, etc.
    But any fast method would be imprecise - it won't do recompression, for example.
    Thank you for proposing this solution, but iam looking in some variant where i dont need to compress the file first, like zpaq does it.

  4. #4
    Administrator Shelwien's Avatar
    Join Date
    May 2008
    Location
    Kharkov, Ukraine
    Posts
    3,134
    Thanks
    179
    Thanked 921 Times in 469 Posts
    1. Any estimation method would be a compression algorithm, just without output
    2. zpaq estimation is likely slower than zstd compression... I think it used some simple LZP model

Similar Threads

  1. Optimize new markup language for compressibility
    By SolidComp in forum Data Compression
    Replies: 3
    Last Post: 31st August 2018, 09:01
  2. LZMA markup tool
    By Shelwien in forum Data Compression
    Replies: 13
    Last Post: 29th November 2015, 23:05
  3. texture tool compressor
    By GOZARCK in forum Data Compression
    Replies: 4
    Last Post: 13th November 2013, 12:06
  4. New GUI tool
    By encode in forum Data Compression
    Replies: 31
    Last Post: 18th November 2010, 22:55
  5. compression trace tool
    By Shelwien in forum Data Compression
    Replies: 6
    Last Post: 19th August 2009, 03:52

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •