Calculation error

View: New views
4 Messages — Rating Filter:   Alert me  

Calculation error

by Tim Dylla-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi List,

   I did some testing on my own implementation of mp3, and used MAD as
reference.
Therefore I generated a sine-sweep from 0Hz to 22kHz ( as far as this is
possible ;) ) at 0dBFS, and 48kHz Samplerate. Then I encoded it with
Lame for a single Channel MPEG-1 Layer III Bitstream, 48kHz Samplerate,
320kbps Bitrate. (I don't know the exact Lame-version and optionstring
anymore, but I didn't use anything weird)
As expected, the resulting bitstream can be decoded without any obvious
error with my Decoder and also with the dist10 decoder.
MAD in contrast introduces a perceivable error right on the first half
wave of the sine sweep. I think, it's an overflow in the requantization
or the IMDCT (when I remember right, the huffman decoder produces very
high output at this moment).
I used MAD 0.15.2b in conjunction with MADFrontend on a
32bit-Windoze-machine. The option string was -b24 -d

I'm not a friend of posting large files on a mailing list without any
agreement with the moderator, so if someone is interested in the
bitstream and the resulting raw file, pleas feel free to send me a message.

With regards,

        Tim Dylla

Parent Message unknown Re: Calculation error

by Tim Dylla-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message



Andre schrieb:

> Tim Dylla <tim.dylla@...> wrote:
>> MAD in contrast introduces a perceivable error right on the first
>> half wave of the sine sweep. I think, it's an overflow in the
>> requantization or the IMDCT (when I remember right, the huffman
>> decoder produces very high output at this moment).
>
> Just a hunch, but if you are able to build MAD from source, maybe you
> could try the follow patch posted to the list a few years back...
> perhaps it helps ??
>
> diff -ruN mad-0.14.2b_orig/libmad/layer3.c
> mad-0.14.2b/libmad/layer3.c
> --- mad-0.14.2b_orig/libmad/layer3.c Thu Nov  8 15:28:02 2001
> +++ mad-0.14.2b/libmad/layer3.c Tue Mar 25 15:21:12 2003
> @@ -910,7 +910,7 @@
>        fprintf(stderr, "requantize overflow (%f * 2^%d)\n",
>        mad_f_todouble(requantized), exp);
>  # endif
> -      requantized = MAD_F_MAX;
> +      requantized = MAD_F_MAX / 2;
>      }
>      else
>        requantized <<= exp;

Nope, same Result. I'm sorry, I'm still sticking with my diploma, so I
don't have the time for extensive tests right now. Maybe someone can
confirm the problem and have a look at? Feel free to contact me for the
Bitstream in Question and the correct decoder output.

Best,

        Tim Dylla


>
>
> Andre
> --
>
>


Re: Calculation error

by Tim Dylla-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Hi list again,

   there is a bug in madplay 0.15.2b, which skips some frames in certain
conditions. Rob Leslie seems to have a patch already in the pipeline.
libmad is not affected at all.

Best,
        Tim Dylla



Tim Dylla schrieb:

>
>
> Andre schrieb:
>> Tim Dylla <tim.dylla@...> wrote:
>>> MAD in contrast introduces a perceivable error right on the first
>>> half wave of the sine sweep. I think, it's an overflow in the
>>> requantization or the IMDCT (when I remember right, the huffman
>>> decoder produces very high output at this moment).
>>
>> Just a hunch, but if you are able to build MAD from source, maybe you
>> could try the follow patch posted to the list a few years back...
>> perhaps it helps ??
>>
>> diff -ruN mad-0.14.2b_orig/libmad/layer3.c
>> mad-0.14.2b/libmad/layer3.c
>> --- mad-0.14.2b_orig/libmad/layer3.c    Thu Nov  8 15:28:02 2001
>> +++ mad-0.14.2b/libmad/layer3.c    Tue Mar 25 15:21:12 2003
>> @@ -910,7 +910,7 @@
>>        fprintf(stderr, "requantize overflow (%f * 2^%d)\n",
>>            mad_f_todouble(requantized), exp);
>>  # endif
>> -      requantized = MAD_F_MAX;
>> +      requantized = MAD_F_MAX / 2;
>>      }
>>      else
>>        requantized <<= exp;
>
> Nope, same Result. I'm sorry, I'm still sticking with my diploma, so I
> don't have the time for extensive tests right now. Maybe someone can
> confirm the problem and have a look at? Feel free to contact me for the
> Bitstream in Question and the correct decoder output.
>
> Best,
>
>     Tim Dylla
>
>
>>
>>
>> Andre
>> --
>>
>>
>
>


Re: Calculation error

by Harri Haataja-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

On Fri, Aug 24, 2007 at 12:16:12PM +0200, Tim Dylla wrote:
>   I did some testing on my own implementation of mp3, and used MAD as
> reference.
> Therefore I generated a sine-sweep from 0Hz to 22kHz ( as far as this is
> possible ;) ) at 0dBFS, and 48kHz Samplerate. Then I encoded it with
> Lame for a single Channel MPEG-1 Layer III Bitstream, 48kHz Samplerate,
> 320kbps Bitrate. (I don't know the exact Lame-version and optionstring
> anymore, but I didn't use anything weird)

> I'm not a friend of posting large files on a mailing list without any
> agreement with the moderator, so if someone is interested in the
> bitstream and the resulting raw file, pleas feel free to send me a message.

Could the generation be done with common software? (sox? clm? nyqvist?)
That could make a sort of full automatic test system if scripted.

Also, a file like that might find a home on Wikimedia or Internet Archive.

--
To know what you prefer, instead of humbly saying Amen
to what the world tells you you ought to prefer,
is to have kept your soul alive.
        -- Robert Louis Stevenson
LightInTheBox - Buy quality products at wholesale price