Method for encoding and decoding video, and decoding device
The method of dividing video data into blocks, descaling and clipping coefficients addresses the high computational complexity and memory requirements of H.264/AVC, achieving reduced memory and complexity for embedded systems.
Patent Information
- Application Number
- JP2024191430
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2011-01-18
- Filing Date
- 2024-10-31
- Publication Date
- 2025-09-25
- Estimated Expiration
- 2032-01-18
AI Technical Summary
Current coding standards like H.264/AVC face increased computational complexity and memory requirements, leading to higher costs and complexity in embedded systems, especially when dealing with large values produced by matrix multiplication and quantization operations.
A method for encoding and decoding video that involves dividing video data into blocks, generating quantized coefficients, descaling and clipping coefficients to a predetermined bit depth, and applying inverse transforms to reduce memory requirements and computational complexity.
Reduces memory requirements and computational complexity while maintaining acceptable rate-distortion loss, making it suitable for resource-constrained systems.
Smart Images

Figure 0007744492000001 
Figure 0007744492000002 
Figure 0007744492000003
Abstract
Description
[Technical Field]
[0001] There is no cross-reference to related applications.
[0002] The present invention relates to reduced dynamic range image decoding. [Background technology]
[0003] Current coding standards, such as H.264 / AVC, generally achieve relatively high coding efficiency at the expense of increased computational complexity. As computational complexity increases, encoding and / or decoding speed tends to decrease. Also, the demand for higher fidelity tends to increase over time, which tends to require increasingly larger memory requirements and increasingly larger memory bandwidth requirements. Particularly in the case of embedded systems, the increasing memory requirements and increasing memory bandwidth requirements tend to result in increasingly more expensive and computationally complex circuitry.
[0004] Referring to FIG. 1, many decoders receive coded data for blocks of an image (in other words, an encoder provides coded data for blocks of an image). Typically, an image is divided into blocks, and each block is coded using some method, such as a discrete cosine transform (DCT), and provided to a decoder. The decoder receives the coded blocks and decodes each block using some method, such as an inverse discrete cosine transform. Decoding of image coefficients for an image block is often performed using matrix multiplication. The matrix multiplication may be performed horizontally or vertically. In some cases, for example, an 8-bit value may become a 16-bit value through a first multiplication, and a 24-bit value through a second multiplication. Furthermore, the coding of each block of an image is typically quantized, which maps the coded values to a smaller set of quantized coefficients used for transmission. Quantization requires inverse quantization by the decoder, which maps the set of quantized coefficients used for transmission back to the appropriate coded values. The desired number of bits for the inverse quantized data is a design parameter. The large values that can be produced by matrix multiplication and dequantization operations are problematic, especially for resource-constrained systems such as embedded systems.
[0005] The foregoing and other objects, features, and advantages of the present invention will be readily understood from the following detailed description of the invention taken in conjunction with the accompanying drawings. Summary of the Invention
[0006] A preferred embodiment is a method for encoding video, comprising the steps of: dividing the video data into one or more video blocks, each video block representing a plurality of pixels; encoding the one or more blocks of video, the encoding comprising generating a set of quantized coefficients for each block of video; transmitting to a decoding device a set of quantization coefficients corresponding to the one or more blocks of video included in the bitstream; The decoding device descaling the quantized coefficients based on a quantization parameter, a coefficient index, and a transform size to generate descaled coefficients; modifying the descaled coefficients to generate modified descaled coefficients, the modifying step including applying a variable based on the transform size; clipping the modified descaled coefficients to a predetermined bit depth to generate clipped coefficients; inverse transforming the clipped coefficients to output a decoded residual; The data of the moving image is decoded by executing a process including The above transform size is 8x8. [Brief explanation of the drawings]
[0007] [Figure 1] FIG. 1 illustrates an encoder and a decoder. [Figure 2] FIG. 1 shows a decoder comprising an inverse quantizer and an inverse transformer. [Figure 3A] FIG. 1 illustrates a modified inverse quantizer. [Figure 3B] FIG. 1 illustrates a modified inverse quantizer. [Figure 4] FIG. 1 shows a modified inverse transformer. [Figure 5] FIG. 10 illustrates another decoder. [Figure 6] FIG. 10 illustrates another decoder. DETAILED DESCRIPTION OF THE INVENTION
[0008] Referring to Figure 2 (Prior Art), a decoder that dequantizes and inverse transforms quantized coefficients received from an encoder for a block of an image is shown where relevant. The decoder receives quantized coefficients 200 at an inverse quantizer 210. The coefficients output from the inverse quantizer 210 are stored in a memory 220. The stored coefficients 220 are processed by a transform pair by an inverse transform unit 230 to obtain a decoded residue 310. The inverse transform uses a matrix multiplication operator to map data from the transform domain to the spatial domain.
[0009] The inverse quantizer 210 includes a descaling process by the descaler 240. The descaling process by the descaler 240 descales the quantized coefficients 200. The descaling process corresponds to multiplying the multiplication level value (also called the quantized coefficients 200) by an integer that depends on the quantization parameter (QP), the coefficient index, and the transform size (N). An example of the descaling process by the descaler 240 is the "Level * IntegerValue(Remainder,Coefficient index) * 16, and other transform sizes. * The descaling process by descaler 240 is preferably based primarily on a function of the remainder, the transform size (N), and / or the coefficient index (e.g., position) to determine intermediate set value 250. The remainder is a function of the quantization parameter (QP) and P * The sum of the BitIncrement and the modulo P is taken ((QP+P *The modulo is defined as x%y, the remainder when x is divided by y, where x is an integer x≧0 and y is an integer y>0, as defined in the H.264 / AVC standard. In one embodiment, P can take on a value of 6. An adjustment mechanism A 260 may be applied to the value 250 or may be a variable that depends on the transform size (N) and / or a function of the received Period. Period is the ratio of the quantization parameter (QP) and P, where "BitIncrement" is the bit depth increment. * The sum of the BitIncrement and the P is divided by ((QP+P * The " / " is defined as integer division with the result truncated towards 0 (rounded down) as defined in the H.264 / AVC standard. For example, 7 / 4 and -7 / -4 round down to 1, and -7 / 4 and 7 / -4 round down to -1. In one embodiment, P can take on a value of 6. The resulting value 250 may be further modified by adjustment mechanism A 260, but is not modified by modifier 270. (Period+B) The residuals may be modified by a factor of B, where B is a variable depending on the transform size. The result of the modification by the modification unit 270 is stored in the memory 220. The inverse transform unit 230 may perform a one-dimensional inverse horizontal transform by the inverse horizontal transform unit 280, and the result may be stored in the memory 290. The inverse transform unit 230 may also perform a one-dimensional inverse vertical transform by the inverse vertical transform unit 300, to obtain the decoded residual 310. The transform unit 280 and the transform unit 300 may be reversed in order, if necessary.
[0010] When implementing "Part 10: Advanced Video Coding," ISO Publication: ISO / IEC 14496-10:2005 - Information Technology - Coding Of Audio-Visual Objects (incorporated herein by reference) (H.264 / AVC Standard), the memory bandwidth of the video decoder shown in FIG. 2 may be limited by using constraints. For example, in Section 8.5.10 of the H.264 / AVC Standard, the width of memory accesses for 4x4 luma DC transform coefficients is limited by including the following statement: "The bitstream shall not exceed -2 (7+bitDepth) From 2 (7+bitDepth) Any element f that exceeds the integer range up to -1 ij (i, j = 0..3 in f) should not contain data obtained at (7+bitDepth) From 2 (7+bitDepth) Any element dcY that exceeds the integer range up to -1 ij(i, j = 0..3 in dcY) should not be included." The H.264 / AVC standard includes similar memory restrictions for other residual blocks. In addition to including complex memory bandwidth restrictions, the H.264 / AVC standard does not provide a mechanism to ensure that these restrictions are enforced. Similarly, the JCT-VC "Dradt Test Model Under Consideration," JCTVC-A205, JCT-VC Meeting, Dresden, April 2010 (JCT-VC) (incorporated herein by reference) does not include a memory bandwidth enforcement mechanism. For robustness, a decoder must be prepared to accept a compliant bitstream or a bitstream that violates these restrictions due to transmission errors that damage a non-conforming encoder. To mitigate these possible restrictions, decoders often provide additional memory bandwidth to accommodate a non-compliant bitstream, at the expense of additional cost and complexity.
[0011] To achieve a more computationally robust decoder with limited memory bandwidth and / or memory storage requirements, the decoder should be modified in an appropriate manner. However, modifications to the decoder to reduce memory requirements should not significantly degrade the rate distortion performance of the corresponding video. Otherwise, even if memory requirements are reduced, the resulting video quality will be unsuitable for viewing by a viewer. The modification by the modifying unit 270 doubles the coefficient value every six steps in the quantization parameter, which can significantly increase the size of the memory requirements. The increased value results in one or more zeros (0) being included as the least significant bits.
[0012] With an understanding of the operation of the inverse quantizer 210 (see FIG. 2, prior art), and referring to FIG. 3A, an improved inverse quantizer (improved inverse quantizer, improved inverse quantizer) 400 (see FIGS. 3A and 3B, non-prior art) receives quantized coefficients 405 and descales the quantized coefficients via a descaler 410 to obtain an intermediate set of values 420. The descaling of the quantized coefficients is preferably based on a function of the remainder, the transform size (N), and / or the coefficient index (e.g., position). An optional adjustment mechanism C 430 may be applied. To determine the resulting data 440, the adjustment mechanism C 430 is preferably a variable that depends on a function of the transform size (N) or the received quantization parameter (QP). The resulting data 440 from the quantized coefficients 405 may contain problematic data or otherwise not comply with standards. Therefore, the improved inverse quantizer 400 should impose fixed constraints on the resulting data 440. The resulting data 440 is preferably clipped to a predetermined bit depth by a clipping unit 450, and the N×N block of data is stored in memory internal to the inverse quantizer 400. For example, by clipping to a predetermined bit depth of 16 bits by the clipping unit 450, any value greater than 32,767 is set to the maximum value, i.e., 32,767. Similarly, for a predetermined bit depth of 16 bits, any value less than −32,767 is set to the minimum value, i.e., −32,767. Other bit depths and clipping values may be used as well. In this way, the maximum memory bandwidth required is limited by the system in a manner independent of the input quantization coefficients 405. This reduces the computational complexity of the system and memory requirements, which is particularly suitable for embedded systems.
[0013] After clipping by the clipping unit 450, the data that has reached the maximum predetermined bit depth is corrected by the correction unit 460. (Period+B)The result of the modification by the modifying unit 460 is provided as a coefficient 470. After clipping by the clipping unit 450, the modifier 460 modifies the (Period+B) By performing the correction by a factor of 2, the rate-distortion loss is reduced. Preferably, the adjustment mechanism C 430 used for 8×8 transform coefficients is (5-Period) and the correction unit 460 (Period+B) is 2 (Period-6) The processing by the modifier 460 may be based on a function of the transform size (N) or the received quantization parameter (QP), as appropriate. Also, the adjustment mechanism C 430 used for other sizes of transform coefficients (4x4, 16x16, 32x32, etc.) is preferably zero (0), and the adjustment by the modifier 460 is preferably 2 (N). (Period+B) The value of is 2 (Period) Also, B may be a function of N, and C may be a function of N. Referring to FIG. 3B, a specific embodiment of FIG. 3A is shown.
[0014] Referring to FIG. 4, coefficients 470 from the inverse quantizer 400 (see FIGS. 3A and 3B) are provided to an inverse transform unit 480 configured to provide a decoded residual 490 having an acceptable rate-distortion loss. The coefficients 470 may be preferably transformed by a one-dimensional inverse horizontal (or vertical) transform by a one-dimensional inverse horizontal (or vertical) transform unit 500. Based on the desired number of output bits to maintain an acceptable rate-distortion loss, the output of the transform unit 500 may be modified by a bit-shifting unit 510 to a desired number of bits. In this manner, a selected number of least significant bits are discarded to reduce the system's memory requirements. For example, if 19 bits are expected from the inverse transform unit 500 and a 16-bit result is desired, the right bit-shifting by the bit-shifting unit 510 removes the 3 least significant bits. The resulting shifted bits are clipped by a clipping unit 520 to a predetermined threshold, such as 16 bits. The clipping by the clipping unit 520 also enforces memory bandwidth limitations, and the result is stored in memory 530. The data stored in memory 530 is significantly smaller as a result of the shift by the bit shift unit 510, which removes the least significant bit(s). The data stored in memory 530 is then shifted left by a left bit shift operation by a bit shift unit 540, preferably by the same number of bits as the right bit shift operation by the bit shift unit 510. As a result of the shift, the least significant bit becomes zero (0). The shifted data is then preferably transformed by a one-dimensional inverse vertical (or horizontal) transform by an inverse vertical (or horizontal) transform unit 550, to obtain the decoded residual 490.
[0015] The rate-distortion loss depends on the number of bits used in the processing and the data block size. The right bit-shifting by the bit-shifting unit 510 and the left bit-shifting by the bit-shifting unit 540 preferably depend on the block size N (the number of horizontal pixels by the number of vertical pixels for a square block of pixels). For example, the shift for a 4×4 block is 3, the shift for an 8×8 block is 2, the shift for a 16×16 block is 8, and the shift for a 32×32 block is 9. The right bit-shifting by the bit-shifting unit 510 and the left bit-shifting by the bit-shifting unit 540 may also be determined based on a bitstream-delivered parameter such as a quantization parameter (QP), an internal bit-depth increment (IBDI), a transform precision extension (TPE) parameter, or other decoder-selectable parameters.
[0016] 5, in another embodiment, the decoder receives quantized coefficients that are processed by any suitable inverse quantization unit (inverse quantizer) 600 and any suitable inverse transform unit 610. It is desirable to include express memory bandwidth limitations, which are preferably achieved by including a clipping function by clipping unit 620. After clipping by clipping unit 620, the data is stored in memory 630. The data is then used for inverse transformation by inverse transform unit 610.
[0017] Referring to FIG. 6, in another embodiment, the decoder receives quantized coefficients that are processed by any suitable inverse quantization unit (inverse quantizer) 700 and any suitable inverse transform unit 710. For example, the inverse transform by the inverse transform unit 710 may be that shown in FIG. 4. To reduce computational complexity, it is desirable to include an express memory bandwidth limit, preferably achieved by including a clipping function by a clipping unit 720. After the clipping function by the clipping unit 720, the data is stored in memory 730. The data is then used for the inverse transform by the inverse transform unit 710. It is further desirable to include an explicit memory bandwidth limit, preferably achieved by including a clipping function by a clipping unit 740 between pairs of one-dimensional transforms. The one-dimensional transforms may be performed in any order and in any manner. After the clipping function by the clipping unit 740, the data is stored in memory 750.
[0018] The terms and expressions employed in the foregoing specification are used herein as terms of description and not of limitation. Nor is there any intention in the use of such terms and expressions to exclude any equivalents of the features shown and described or portions thereof. It will be understood that the scope of the invention is defined and limited only by the claims which follow.
Claims
1. 1. A method for encoding and decoding video, comprising: dividing the video data into one or more video blocks, each video block representing a plurality of pixels; encoding the one or more blocks of video, the encoding comprising generating a set of quantized coefficients for each block of video; transmitting to a decoding device a set of quantization coefficients corresponding to the one or more blocks of video included in the bitstream; The decoding device descaling the quantized coefficients based on a quantization parameter, a coefficient index, and a transform size to generate descaled coefficients; modifying the descaled coefficients to generate modified descaled coefficients, the modifying step including applying a variable based on the transform size and not based on a quantization parameter; clipping the modified descaled coefficients to a predetermined bit depth to generate clipped coefficients; inverse transforming the clipped coefficients to output a decoded residual; The data of the moving image is decoded by executing a process including The transform size is 8x8.
2. Inverse transforming the clipped coefficients to output a decoded residual comprises: one-dimensionally inverse transforming the clipped coefficients in a first direction to generate inverse transformed coefficients in the first direction; right shifting the inverse transformed coefficients in the first direction to generate first shifted inverse transformed coefficients having a smaller bit depth than the inverse transformed coefficients in the first direction; clipping the first shifted and inverse transformed coefficients to the predetermined bit depth to generate second clipped coefficients; one-dimensionally inverse transforming the second clipped coefficients in a second direction to determine the decoded residual; The method of claim 1 , comprising:
3. The step of right-shifting the coefficients inverse transformed in the first direction comprises: selecting a specific number of bits by which to shift the coefficients inverse transformed in the first direction based on a size of a block of video, from among a plurality of different numbers of bits by which to shift the coefficients; shifting the inverse transformed coefficients in the first direction to the right by the particular number of bits; The method of claim 2 , comprising:
4. The method of claim 2 , wherein the first direction is a horizontal direction.
5. The method of claim 2 , wherein the first direction is a vertical direction.
6. The method of claim 2 , wherein the second direction is orthogonal to the first direction.
7. Shifting the inverse transformed coefficients in the first direction to the right to generate first shifted inverse transformed coefficients comprises: selecting a particular number of bits by which to shift the coefficients from among a plurality of different numbers of bits by which to shift the coefficients; shifting the inverse transformed coefficients in the first direction to the right by the particular number of bits to generate first shifted inverse transformed coefficients; The method of claim 2 , comprising:
8. Selecting the particular number of bits by which to shift the coefficients may include: determining that blocks of the video are of a particular size; selecting a specific number of bits by which to shift coefficients corresponding to a specific size of a block of the video from a plurality of different numbers of bits by which to shift coefficients corresponding to different sizes of blocks of the video; The method of claim 7, comprising:
9. 3. The method of claim 2, wherein the step of right-shifting the inverse transformed coefficients in a first direction includes right-shifting the inverse transformed coefficients in a first direction by an amount based on a transform precision extension parameter.
10. A decoding device for decoding a moving image, comprising: descaling quantized coefficients of the blocks of the video based on a quantization parameter, a coefficient index, and a transform size to generate descaled coefficients; modifying the descaled coefficients to generate modified descaled coefficients, the modifying step including applying a variable based on the transform size and not based on a quantization parameter; clipping the modified descaled coefficients to a predetermined bit depth to generate clipped coefficients; inverse transforming the clipped coefficients to output a decoded residual; The data of the moving image is decoded by executing a process including A decoding device, wherein the transform size is 8x8.
Citation Information
Patent Citations
Inverse conversion circuit
JP2007079972A
Dequantization circuit, dequantization method, and image reproduction device
WO2008120433A1