[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: huffmandict: Matlab compatibility, Matlab bugs..
From: |
Muthiah Annamalai |
Subject: |
Re: huffmandict: Matlab compatibility, Matlab bugs.. |
Date: |
Fri, 06 Oct 2006 16:12:22 -0500 |
> From: Simon Persson <address@hidden>
> Subject: Re: huffmandict: Matlab compatibility, Matlab bugs..
> To: address@hidden
> Message-ID: <address@hidden>
> Content-Type: text/plain; charset="utf-8"
>
> On Thursday 05 October 2006 21:59, Muthiah Annamalai wrote:
> > Hi there,
> > Im trying to write some functions in Matlab communication toolbox
> > (source coding functions) for Octave forge.
> >
> > While I was doing that, I came across a funny bug in Matlab.
> >
> > Huffman encoding is done in 2 steps (according to Matlab),
> > and the first step generates dictionary.
> > Essentially all Huffman coding does it map low probability symbols
> > to long codewords and vice-verca.
> >
> > So the wierd thing (in Matlab impl) is that for 0-probability symbols
> > have long code words assigned to them. I wonder... why someone will
> > infact even have a zero probability symbols occur in their data?
> >
>
> Maybe someone wants to estimate probabilites from a smaller sample than the
> full data to be encoded. Then codes for all symbols are still needed even if
> they don't occur in the analysed sample. That's the only reason I can think
> of.
>
> Simon
I dont understand you. Huffman codes are supposed to be *static* and
*apriori* code words. Im not talking about adaptive Huffman codewords
here. To me that is plain B.S, I asked with a friend and he doesnt
differ much; also I wouldnt know how to do such a thing anyway .
Anyone who can 'make it compatible' is welcome to.
And FYI I think it is with the version (Matlab) 7 R14 SP2.
So maybe the fixed it, maybe they didnt I dont know. Maybe we
shouldnt bother... maybe we should wait till Matlab becomes the
world-order ...
I reported a bug, lets see.
-Muthu