Entropy coding using escape codes to switch between plural code tables
AssigneeMicrosoft Corporation
InventorsSanjeev Mehrotra, Wei-Ge Chen
Life of this patent
Estimating the term…
Abstract
An audio encoder performs entropy encoding of audio data. For example, an audio encoder determines whether a first code table in a group of plural code tables contains a code representing a first vector. If it does, the code is used, and otherwise the escape code from the first code table is used and the first vector is encoded using, at least in part, a second code table. An audio decoder performs corresponding entropy decoding.
Claims12
In a computer system that implements an audio decoder, a method of decoding data comprising plural encoded vectors, the method comprising:
- decoding, by the computer system that implements the audio decoder, a first code, wherein the decoding the first code comprises:
- receiving the first code;
- looking up the first code in a first code table in a group of plural code tables;
- determining whether the first code is an escape code from the first code table;
- if the first code is the escape code from the first code table:
- receiving a second code, wherein the second code is not included in the first code table;
- and
- decoding the second code;
- if the first code is not the escape code from the first code table:
- looking up a first vector, having a first number of plural symbols, in the first code table, wherein the first vector is associated with the first code in the first code table;
- and
- including the first number of plural symbols of the first vector in a decoded data stream;
- wherein sum of values of the first number of plural symbols is a basis for whether the first code is the escape code or not the escape code from the first code table, wherein the second code is associated in a second code table with a second vector that has a second number of symbols, and wherein the first number of plural symbols differs from the second number of symbols by a factor of 2.
In a computer system that implements an audio encoder, a method of encoding data comprising plural vectors, the method comprising:
- encoding, by the computer system that implements the audio encoder, a first vector comprising a first number of plural symbols, wherein the encoding the first vector comprises:
- determining whether a first code table in a group of plural code tables contains a code representing the first vector;
- if the first code table does not contain the code representing the first vector;
- including an escape code from the first code table in an encoded data stream;
- if the first code table contains the code representing the first vector;
- including the code representing the first vector in the encoded data stream;
- wherein sum of values of the first number of plural symbols of the first vector is a basis for whether the first code table contains the code representing the first vector;
- and
- wherein the first code table does not contain the code representing the first vector, and wherein the method further comprises:
- encoding a second vector comprising a second number of symbols, wherein the encoding the second vector comprises:
- determining whether a second code table in the group of plural code tables contains a code representing the second vector;
- if the second code table does not contain the code representing the second vector;
- including an escape code from the second code table in the encoded data stream;
- if the second code table contains the code representing the second vector;
- including the code representing the second vector in the encoded data stream;
- wherein values of the second number of symbols of the second vector are a basis for whether the second code table contains the code representing the second vector, wherein the second code table differs from the first code table, and wherein the first number of plural symbols differs from the second number of symbols by a factor of 2.
A storage medium storing computer-executable instructions for causing a computer system programmed thereby to perform a method of decoding data comprising plural encoded vectors, the method comprising:
- decoding a first code, wherein the decoding the first code comprises:
- receiving the first code;
- looking up the first code in a first code table in a group of plural code tables;
- determining whether the first code is an escape code from the first code table;
- if the first code is the escape code from the first code table:
- receiving a second code, wherein the second code is not included in the first code table;
- and
- decoding the second code;
- if the first code is not the escape code from the first code table:
- looking up a first vector, having a first number of plural symbols, in the first code table, wherein the first vector is associated with the first code in the first code table;
- and
- including the first number of plural symbols of the first vector in a decoded data stream;
- wherein sum of values of the first number of plural symbols are a basis for whether the first code is the escape code or not the escape code from the first code table, wherein the second code is associated in a second code table with a second vector that has a second number of symbols, and wherein the first number of plural symbols differs from the second number of symbols by a factor of 2.
Dependencies are inferred from the claim text.