# US 2013/0259119 A1 · Apparatuses and methods for providing quantized coefficients for video encoding

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2013/0259119 A1
- Document ID: US20130259119A1
- Status: Published application
- Kind: A1
- Application number: 13/434,736
- Filed: 2012-03-29
- Published: 2013-10-03
- Earliest claimed: 2012-03-29
- Assignees: Magnum Semiconductor, Inc.
- Inventors: ERIC C. PEARSON
- Web page: https://patentgrep.com/patent/US20130259119A1

## CPC

- H04N 19/19: using optimisation based on Lagrange multipliers
- H04N 19/124: Quantisation
- H04N 19/147: according to rate distortion criteria (rate-distortion as a criterion for motion estimation H04N19/567)
- H04N 19/149: by estimating the code amount by means of a model, e.g. mathematical model or statistical model
- H04N 19/176: the region being a block, e.g. a macroblock
- H04N 19/91: Entropy coding, e.g. variable length coding [VLC] or arithmetic coding
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

Apparatuses and methods for optimizing rate-distortion costs in a signal are disclosed. An apparatus may comprise a quantization block that may be configured to generate a plurality of candidates for each of a plurality of coefficients. The quantization block may further generate a respective plurality of arcs based, at least in part, on the plurality of candidates. The quantization block may be configured to determine which of the plurality of arcs has a lowest cost using a trellis optimization technique. Fractional bit estimations may be used to calculate rate, and inverse lambda may be used to calculate candidate coefficients.

## Claims

### Claim 1

An encoder configured to receive a video signal, the encoder comprising:
a prediction block configured provide a predictor in accordance with an encoding standard;
a subtractor configured to subtract the predictor from the video signal to provide a residual;
a transform configured to receive the residual and provide the residual in the frequency domain including a plurality of coefficients;
a quantization block configured to serially receive the plurality of coefficients, optimize rate-distortion associated with the plurality of coefficients to generate a plurality of modified coefficients, wherein the quantization block includes:
an optimization block configured to generate a plurality of candidates for each of the plurality of coefficients, wherein the optimization block is further configured to calculate a rate associated with each of the candidates using look-up tables configured to provide a fractional rate estimation, and wherein the optimization block is configured to calculate an arc for each of the candidates, wherein the arc includes the respective rate, and wherein the optimization block includes components arranged in a trellis configuration, to identify a minimum cost set of coefficients and output the plurality of modified coefficients having the minimum cost arc; and
a coding block configured to encode the plurality of modified coefficients into a coded bitstream in accordance with the encoding standard.

### Claim 2 (depends on 1)

The encoder according to claim 1 wherein the optimization block is further configured to calculate a distortion cost associated with each candidate, wherein the distortion cost is calculated using inverse lambda.

### Claim 3 (depends on 1)

The encoder according to claim 1 wherein the encoding standard is the H.264 coding standard.

### Claim 4 (depends on 1)

The encoder according to claim 1, further comprising a mode decision block configured to receive the video signal and provide lambda to the quantization block.

### Claim 5 (depends on 1)

The encoder according to claim 1, wherein the rate associated with each of the candidates is clamped to a predetermined number of bits.

### Claim 6 (depends on 1)

The encoder according to claim 1, wherein the optimization block includes:
a node cost block for each state of an encoding standard, wherein the node cost blocks are each configured to generate an arc associated with each candidate, wherein the arcs each include a rate cost and a distortion cost; and
minimum cost blocks associated with the node cost blocks, wherein each of the minimum cost blocks is configured to receive arcs from the node cost blocks corresponding to a state of the minimum cost blocks, wherein the minimum cost blocks are configured to identify a lowest cost arc from the received arcs, generate an updated arc, and provide the updated arc to the node cost block associated with the respective state.

### Claim 7

An optimization block for generating modified coefficients for use in encoding video, the optimization block comprising:
a candidate generation block configured to generate a plurality of candidate coefficients based, at least in part, on a received coefficient;
a plurality of node cost blocks coupled to the candidate generation block, each of the plurality of node cost blocks configured to provide a plurality of arcs based, at least in part, on the plurality of candidates, each of the plurality of arcs including a rate cost and a distortion cost, wherein the rate cost is calculated using fractional bit estimation, and the distortion cost is calculated using inverse lambda; and
a plurality of minimum cost blocks coupled to at least one of the plurality of node cost blocks and configured to receive at least one of the respective plurality of arcs and determine which arc of the at least one respective plurality of arcs has a lowest cost.

### Claim 8 (depends on 7)

The optimization block of claim 7, wherein the apparatus is included in an encoder.

### Claim 9 (depends on 7)

The apparatus of claim 7, wherein the plurality of node cost blocks and the plurality of minimum cost blocks are configured in a trellis arrangement.

### Claim 10 (depends on 7)

The apparatus of claim 7, wherein the optimization block further includes a rate block configured to calculate the rate cost, wherein the rate block is configured to perform a binarization process to provide a prefix bincount and a bypass bitcount, wherein the rate block includes:
a first rate estimation table configured to output a first rate cost for one of the bins of the prefix bincount, and
a second rate estimation table configured to output a second rate cost for another of the bins of the prefix bincount; and
an adder configured to add the first rate cost, the second rate cost, and the bypass bitcount to provide the rate cost.

### Claim 11 (depends on 10)

The apparatus of claim 10, wherein the first and second rate estimation tables are look-up tables.

### Claim 12 (depends on 10)

The apparatus of claim 10, wherein the optimization block further includes a first state update table configured to provide a first context update based on one of the bins of the prefix bincount and a second update table configured to provide a second context update based on another of the bins of the prefix bincount, and wherein the optimization block is configured to combine the first context update and the second context update to generate a next context.

### Claim 13 (depends on 12)

The apparatus of claim 12, wherein the first, second, and next contexts are CABAC contexts.

### Claim 14

A method, comprising:
generating a residual based on a difference between a predicted video signal and an actual video signal;
transforming the residual to a frequency domain including a plurality of coefficients;
optimizing rate-distortion associated with the plurality of coefficients to generate a modified set of coefficients, wherein said optimizing rate-distortion comprises generating candidate coefficients using inverse lambda and estimating rates associated with the plurality of coefficients using look-up tables; and
encoding the modified set of coefficients for use in video transmission.

### Claim 15 (depends on 14)

The method of claim 14, wherein said optimizing comprises:
performing an inverse zigzag operation on the plurality of coefficients to generate a coefficient vector; and
serially processing the coefficients of the coefficient vector.

### Claim 16 (depends on 14)

The method of claim 14, wherein said optimizing comprises utilizing a trellis optimization technique to find a minimum cost arc associated with the candidate coefficients using CABAC states.

### Claim 17 (depends on 14)

The method of claim 14, wherein the encoding comprises encoding at a fixed rate configured to generate a CAVLC bitstream.

### Claim 18 (depends on 14)

The method of claim 14, further comprising transcoding the CAVLC bitstream to generate a CABAC coded bitstream.

### Claim 19 (depends on 18)

The method of claim 18, wherein the transcoding comprises real-time conversion.

### Claim 20 (depends on 14)

The method of claim 14, wherein the predicted video signal is generated in accordance with an H.264 standard.
