Skip to main content


Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Anyone familiar with 3GPP reference AMR-WB source? (Read 4405 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Anyone familiar with 3GPP reference AMR-WB source?

One of my projects is to investigate the performance of the Split-multistage VQ in AMR-WB at quantising ISFs.  What I'm trying to do is save the ISFs and quantised ISFs to separate files for analysis. 

I've got the floating-point version of the 3GPP reference source code and am a bit confused about the ISF decoding.  Both enc_lpc.c and dec_lpc.c have the same split-multistage VQ decoding functions, yet the encoder version is slightly different.  Also, the quantised ISFs (in WORD16) I get from these functions are nowhere close to the original ISFs.

Any help would be very much appreciated.  Thanks.

Anyone familiar with 3GPP reference AMR-WB source?

Reply #1
The differences are not related to the quantization algorithm. Have you checked the document of 3GPP 26.190? There you can see the detailed algorithm for quantizing the ISF. The codebooks needed are those included in enc_rom.c from the source code, you can use the same for the decoding part.
I have some functions that perform the coding in Matlab, codebooks included, if you are interested.

Also, the 'encoded' ISF that you obtain are not the ISF quantized, they are just a set of indexes for the codebooks used. At the decoding part, the index is used to search in the codebook the corresponding codevector, and reconstruct the ISF vector. For comparing you should quantize and unquantize, and see the differences between the orginal and the quantized-unquantized.


Anyone familiar with 3GPP reference AMR-WB source?

Reply #2
Thanks for the reply.  I did quantize and unquantize but the output was totally different to the input.  I figured it out eventually.  Even though this is the floating point version of the source, the ISFs are quantised to shorts and certain constants and scaling factors are used to ensure the dynamic range fits within the shorts range.  In the decoding, I removed all these and replaced the codebooks with their floating point versions (reverse of the quantize function), and got meaningful output.