🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.nntp
Article #53582

Re: CP compression (or any) - some numbers...

#53582
From: The Archiver
Date: Wed, 01 Aug 2001 07:30
133 lines
5947 bytes
Stuart <stuart@knapton.clara.co.uk> wrote:

>> 500 MB  MP3-files
>> 
>> 0x00: 1.77%
>> 0x01: 0.43%
>> 0xFB: 0.62%
>> 0xFF: 1.30%
>
>Did the MP3s have ID3/ID3v2 tags? 

I must admit that I oisted to my (own) MP3s.
I ever checked their bits.

>Those MP3s I've investigated could 
>very much do with an additional compression stage (silence in MP3s seems 
>to be encoded as a long string of 0xFFs) A simple RLE-like scheme would 
>probably be sufficient for this and perhaps the other file types you've 
>investigated.

It might be a good idea to compress such formats.
But Usenet neticens are smart enough that they usually compress 
binaries when it makes sense.

>> In the 'extreme' case an MPG file would result in an overhead
>> of > 8% if all NULL chars would be encoded with a double
>> byte escape character.
>
>Adding approx 46MB to the size of the encoded file if QPLite were to be 
>used. 

Yes, but if an 'additive shift' is used then this is not the case.

>Were those 00s packed together such that an RLE scheme would work 
>well? 

I did not analyse double bytes or use a compressor on them.
I simply counted the bytes. 

>Anyway, a good case for some kind of simple pre-compression could 
>be made for this type of file (and to a lesser but still IMO significant 
>extent the others you investigated) 1-5% compression on all the above 
>file types could be achieved before any further encoding steps took 
>place.

Perhaps I should make the same test after applying a pre-compression
to all these filetypes. The mostly used compressor is PkZip/WinZip.

>I don't suppose you've got a small piece of Win32 software which could be 
>used to investigate the statistical distribution for further files, 
>or file collections? Did you write something yourself?

My own software contains a package which scans files, creates
checksums and CRCs and manages all results in a small database.
This way I can identify duplicates and renamed files.

Adding a byte-value-counter was very easy.
And making the same tests again on the same sources - but 
precompressed with ZIP would be not a big job.
(Yes, I really forgot to analyse the ZIP-format).

>> For a fixed value I would propose to add '42' to each byte
>> before encoding.

>Or a translation table calculated for each individual file 
>[...]
>Despite the explanation being a little bit more complicated than 'use a 
>byte offset' this would not IMO be difficult to implement, and would 
>provide a further 1.1% saving.

I assume that saving 30% of bandwidth is the biggest step.
Of course there should be options to make further enhancements
in a new format. But whether savings in the range of 1-3% are worth
the effort is not clear to me.

>Overhead comparisons:
> [...]

Thanks for taking the time to create this list.

>Compression could also be applied to the last 3, giving a good chance all 
>encoded files will be smaller than the original.

Perhaps we should think about this in more depth:

I see good chances to introduce a very compact encoding (as QP-Lite
or yEnc) to the Usenet-community. The users are waiting for it - and the
programmers would have to do no big job to implement it if they
can get free sources and a public domain method - and the work is small.

Adding the complexity of a compression into an encoding would require
a free (and powerful) compressor - which could be also offered as
freeware and public domain source. 
If we limit the typical 'chunck' of a multipart post to 1 MB then such a
compressor could work on a memory array - and could be easily added
as a module.   

Introducing a new compression together with a new encoding might be
a good idea (or at least having predefined options for such a compression).

But I'm not sure how difficut it would be to offer source-codes for the 
different programming languages. I assume that most news-tools are
written in C/C++ - but there might be also Basic/Delphi/.... tools.
Adapting a simply algorithm to other languages is easy.
Adapting (rewriting) a compression algorithm together with testing it
is a far more complex - and time consuming - thing.


Making two steps in one might be a good idea.
But perhaps here the second step is so long that we will fail
to make to the first one.


>I'd like to see something along these lines implemented, even though I'm 
>a mere user :) I wouldn't want any efforts for QP-Lite as a standard to 
>become fragmented before we've even left the starting block though.

I've done my own first steps by implementing a special form of
QP-lite into my own news-software. So from now on I can easily 
modify it (in encoding, compression, .....)
(Whoever runs Borland C 4.52 and needs a playground can have it)

Unfortunately I have no idea how long it would take to have even 
a first specification for QP-lite. (Jeremy ?)
So actually we have no base to build on.

btw.: I saw a posting with:   qp-lite [tm]
The [tm] sign is a critical thing for me.
If someone has the trandemark on it, then it cannot be used.

-- 
Juergen, [The Archiver]
Technical Details
Message-ID: <16309.181202@archiver.winews.net>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news.alt.net!archiver.winews.net!not-for-mail
References: <0529e.u71200@archiver.winews.net> <MPG.15d0bd03e8a0108d989a91@news.easynews.com>

Show Full Headers
Complete Article Headers
Message-ID: <16309.181202@archiver.winews.net>
Subject: Re: CP compression (or any) - some numbers...
Date: Wed, 01 Aug 2001 07:30:16 +0000
From: archiver@i3w.com (The Archiver)
References: <0529e.u71200@archiver.winews.net> <MPG.15d0bd03e8a0108d989a91@news.easynews.com>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.nntp.mbox.zip!archiver1.google.com!newsfeed.google.com!newsfeed.stanford.edu!news-spur1.maxwell.syr.edu!news.maxwell.syr.edu!news.alt.net!archiver.winews.net!not-for-mail
Newsgroups: news.software.nntp
Organization: Altopia Corp. - Usenet Access - http://www.altopia.com
Lines: 132
X-Newsreader: MyNews