CN110933444A - Bit width value storage method and device - Google Patents

Bit width value storage method and device Download PDF

Info

Publication number
CN110933444A
CN110933444A CN201811100726.7A CN201811100726A CN110933444A CN 110933444 A CN110933444 A CN 110933444A CN 201811100726 A CN201811100726 A CN 201811100726A CN 110933444 A CN110933444 A CN 110933444A
Authority
CN
China
Prior art keywords
bit width
value
pixel
pixel block
difference
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201811100726.7A
Other languages
Chinese (zh)
Other versions
CN110933444B (en
Inventor
曲道远
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Ingenic Semiconductor Co Ltd
Original Assignee
Beijing Ingenic Semiconductor Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Ingenic Semiconductor Co Ltd filed Critical Beijing Ingenic Semiconductor Co Ltd
Priority to CN201811100726.7A priority Critical patent/CN110933444B/en
Publication of CN110933444A publication Critical patent/CN110933444A/en
Application granted granted Critical
Publication of CN110933444B publication Critical patent/CN110933444B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/60Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding
    • H04N19/61Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding in combination with predictive coding
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/12Selection from among a plurality of transforms or standards, e.g. selection between discrete cosine transform [DCT] and sub-band transform or selection between H.263 and H.264
    • H04N19/122Selection of transform size, e.g. 8x8 or 2x4x8 DCT; Selection of sub-band transforms of varying structure or type
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/124Quantisation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/13Adaptive entropy coding, e.g. adaptive variable length coding [AVLC] or context adaptive binary arithmetic coding [CABAC]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Discrete Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

The invention provides a bit width value storage method and a bit width value storage device, wherein the method comprises the following steps: acquiring bit width trees corresponding to 4 2x2 reconstructed frames; performing difference processing on the bit width value corresponding to each 2x2 pixel block in the bit width tree and the bit width values corresponding to 4 2x2 reconstruction frames to obtain four difference values; the four differences are written into TEXT. Because the difference value is written in the TEXT, the bandwidth occupied by writing and reading the reconstructed frame is small, thereby realizing the compression processing of the reconstructed frame, and because the data is compressed, the bandwidth requirement can be reduced in the encoding and decoding process.

Description

Bit width value storage method and device
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a bit width value storage method and apparatus.
Background
As shown in fig. 1, in the video codec, the steps shown in fig. 1 need to be performed: entropy coding, inverse quantization, inverse transformation, motion compensation, reference frames, external storage, etc. These require constant data exchange with off-chip memory, including: writing of a reconstructed frame, acquisition of a reference frame, and the like. While data is being written or retrieved, a significant amount of bandwidth consumption is incurred.
In the encoding and decoding process, the DDR needs to be accessed in real time to obtain the required data, and due to the huge bandwidth requirement, the DDR consumes a large part of power generated by writing and reading data, so that the DDR bandwidth reduction becomes particularly important in video encoding and decoding.
No effective solution has been proposed at present for the DDR bandwidth if reduced.
Disclosure of Invention
The embodiment of the invention provides a bit width value storage method and device, and aims to achieve the purpose of reducing the bandwidth requirement of DDR in the video coding and decoding process.
The embodiment of the invention provides a bit width value storage method, which comprises the following steps:
acquiring bit width trees corresponding to 4 2x2 reconstructed frames;
performing difference processing on the bit width value corresponding to each 2x2 pixel block in the bit width tree and the bit width values corresponding to 4 2x2 reconstruction frames to obtain four difference values;
the four differences are written into TEXT.
In one embodiment, the step of performing difference processing on the bit width value corresponding to each 2 × 2 pixel block in the bit width tree and the bit width value corresponding to 4 2 × 2 reconstructed frames to obtain four differences includes:
when the difference is-2, it is represented by 0;
when the difference is-1, the expression is 1;
when the difference is 0, it is represented by 2;
when the difference is 1, it is represented by 3.
In one embodiment, when all the pixel values in the 4 2 × 2 reconstructed frames are the same, the bit width value corresponding to the 4 2 × 2 reconstructed frames is set to 15.
In one embodiment, obtaining the bit width tree corresponding to 4 reconstructed frames 2 × 2 includes:
acquiring the 4 reconstructed frames of 2x 2;
determining the minimum pixel value in each 2x2 pixel block to obtain 4 pixel values;
taking the minimum value in the 4 pixel values as the minimum value of the 4x4 pixel blocks;
subtracting the minimum value of the corresponding 2 × 2 pixel blocks from the 4 2 × 2 pixel blocks respectively, and determining the minimum pixel value in each 2 × 2 pixel block after subtracting the minimum value to obtain the minimum value tree;
determining the maximum value of each 2x2 pixel block after the 4 2x2 pixel blocks are respectively subtracted by the minimum value;
converting the maximum value in each 2x2 pixel block into a binary value;
and converting the maximum value in each 2x2 pixel block into binary digits as bit width to obtain a bit width tree.
In one embodiment, after obtaining the bit width trees corresponding to the 4 2 × 2 reconstructed frames, the method further includes:
determining bit width values corresponding to 4 reconstructed frames of 2x2 according to the following constraint conditions:
the bit width of the minimum value of the 4x4 pixel blocks is not less than the bit width of the maximum value in each 2x2 pixel block minus 1;
the bit width of the maximum value in each 2x2 pixel block is not less than the bit width of the minimum value of said 4x4 pixel block minus 2.
An embodiment of the present invention further provides a bit width value storage device, including:
the acquisition module is used for acquiring bit width trees corresponding to 4 2x2 reconstructed frames;
the processing module is used for performing difference processing on the bit width value corresponding to each 2x2 pixel block in the bit width tree and the bit width value corresponding to 4 2x2 reconstruction frames to obtain four difference values;
and the writing module is used for writing the four difference values into TEXT.
In one embodiment, the processing module is represented by 0 when the difference is-2; when the difference is-1, the expression is 1; when the difference is 0, it is represented by 2; when the difference is 1, it is represented by 3.
In one embodiment, when all the pixel values in the 4 2 × 2 reconstructed frames are the same, the bit width value corresponding to the 4 2 × 2 reconstructed frames is set to 15.
In one embodiment, the obtaining module comprises:
an obtaining unit, configured to obtain the 4 2 × 2 reconstructed frames;
a first determining unit, configured to determine a minimum pixel value in each 2 × 2 pixel block, to obtain 4 pixel values;
a generating unit, configured to use a minimum value of the 4 pixel values as a minimum value of the 4 × 4 pixel block;
a calculating unit, configured to subtract the minimum value of the corresponding 2 × 2 pixel block from each of the 4 2 × 2 pixel blocks, and determine the minimum pixel value in each of the 2 × 2 pixel blocks after subtracting the minimum value, so as to obtain the minimum value tree;
a second determining unit configured to determine a maximum value in each of the 2 × 2 pixel blocks after subtracting the minimum value from each of the 4 2 × 2 pixel blocks;
a conversion unit for converting the maximum value in each 2 × 2 pixel block into a binary value;
and the generating unit is used for converting the maximum value in each 2x2 pixel block into binary digits as bit width to obtain a bit width tree.
In one embodiment, the above apparatus further comprises:
the determining module is configured to determine bit width values corresponding to 4 2 × 2 reconstructed frames according to the following constraint conditions after acquiring bit width trees corresponding to the 4 2 × 2 reconstructed frames:
the bit width of the minimum value of the 4x4 pixel blocks is not less than the bit width of the maximum value in each 2x2 pixel block minus 1;
the bit width of the maximum value in each 2x2 pixel block is not less than the bit width of the minimum value of said 4x4 pixel block minus 2.
The application also provides a terminal device, which comprises a processor and a memory for storing processor executable instructions, wherein the processor executes the instructions to realize the steps of the method.
The present application also provides a computer readable storage medium having stored thereon computer instructions which, when executed, implement the steps of the above-described method.
In the embodiment of the present invention, a bit width tree corresponding to 4 2 × 2 reconstructed frames is obtained, then a bit width value corresponding to each 2 × 2 pixel block in the bit width tree is subjected to difference processing with a bit width value corresponding to 4 2 × 2 reconstructed frames to obtain four difference values, and the four difference values are written in the TEXT. Because the difference value is written in the TEXT, the bandwidth occupied by writing and reading the reconstructed frame is small, thereby realizing the compression processing of the reconstructed frame, and because the data is compressed, the bandwidth requirement can be reduced in the encoding and decoding process.
Drawings
The accompanying drawings, which are included to provide a further understanding of the invention and are incorporated in and constitute a part of this application, illustrate embodiment(s) of the invention and together with the description serve to explain the principles of the invention. In the drawings:
fig. 1 is a video coding method architecture diagram according to the present application;
FIG. 2 is a schematic diagram of a reconstructed frame storage method according to the application;
FIG. 3 is a schematic representation of a reconstructed frame according to the present application;
FIG. 4 is a schematic mb diagram according to the present application;
FIG. 5 is a schematic view of a transverse 4x4 run in series according to the present application;
FIG. 6 is a diagram of a specific example of specific pixel values of 4x4(sbk0) according to the present application;
fig. 7 is a schematic of the minimization of 2x2 according to the present application;
FIG. 8 is a schematic diagram of minimum tree formation according to the present application;
FIG. 9 is a schematic diagram of binary scaling according to the present application;
FIG. 10 is a diagram illustrating a bit width tree corresponding to a minimum tree according to the present application;
FIG. 11 is a schematic diagram of a constrained bit-width tree according to the present application;
FIG. 12 is a schematic of zero _ idx according to the present application;
FIG. 13 is a minimum value schematic of 4x4 blocks according to the present application;
FIG. 14 is a method flow diagram of a bit width value storage method according to the present application;
fig. 15 is a block diagram of the structure of a bit-width value storage device according to the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail with reference to the following embodiments and accompanying drawings. The exemplary embodiments and descriptions of the present invention are provided to explain the present invention, but not to limit the present invention.
In this example, in order to reduce the bandwidth of the DDR, it is considered that data can be compressed in the process of video encoding, and the compressed data is stored.
Specifically, as shown in fig. 2, in the process of video encoding and decoding, the compressed data (TEXT) is stored in the TEXT BUFFER, and the LIST identifying each mb information is stored in the LIST BUFFER. Where mb denotes a 16x16 block, i.e., a block of size 16 pixels by 16 pixels. TEXT represents data after the reconstructed frame is compressed, and LIST is used to identify data of the TEXT address size.
To better illustrate the present application, some of the words and concepts involved in FIG. 2 are explained below:
1) original frame, one frame in the original video image.
2) Reconstructed frame, recon frame, reconstructed image frame after encoding and decoding the original frame.
3) A group, 16 × 4 block, i.e., a block of size 16 pixels by 4 pixels, is the basic compression unit.
4) sbk, 4x4 blocks, i.e., blocks of 4 pixels by 4 pixels in size.
5) mbk, 2x2 blocks, i.e., blocks of 2 pixels by 2 pixels in size, one sbk contains 4 mbk.
6) pxl, 1 pixel.
The reconstructed frame may be as shown in fig. 3, one reconstructed frame may contain some number of mb as shown in fig. 4, and one mb contains 16 4 × 4 (sbk). The compression unit is 16x4, i.e. as shown in fig. 5, 4x4 consecutive in the transverse direction, for example: sbk0, sbk1, sbk2, sbk 3. Each square block represents 4x4, and the minimum value is selected at the 4x4 level to generate a minimum value tree and a bit width tree.
Taking a specific pixel value of 4 × 4(sbk0) as an example, the compression process is explained as follows: as shown in fig. 6, for a specific pixel value of 4 × 4(sbk0), the following steps may be included:
s1: a minimum tree is calculated.
As shown in fig. 7, the minimum value is taken for each 2 × 2, and the minimum value is taken again for 4 minimum values.
As shown in fig. 8, the new minimum tree is formed by subtracting the respective minimum values from the 4 2 × 2 values, and subtracting the minimum value (5 of 5, 11, 12, 11) from the 4 minimum value groups. That is, the minimum square 5 is the minimum value of the 4 × 4 blocks, and the remaining values are the difference values.
S2: and calculating a bit width tree.
The correspondence between values and bit widths can be as shown in table 1 below:
TABLE 1
Figure BDA0001806590690000051
Figure BDA0001806590690000061
The maximum value of the 4 numbers is taken and the bit width is calculated.
For example: as shown in fig. 9, the maximum value of the 1 st 2 × 2 is 18, which is 10010 converted to binary, and therefore 5 bits.
Therefore, the bit width tree corresponding to the minimum value tree is shown in fig. 10.
When implemented, the following constraints can be set:
1) when 4 values of bc _ f4 are all 0, bc _ f3 is equal to 15.
2) bc _ f3 is not less than the maximum value in bc _ f4 minus 1.
3) Each value in bc _ f4 is not less than bc _ f3 minus 2.
After being constrained by the above constraint conditions, the bit width tree becomes as shown in fig. 11.
The 4 values of bc _ f4 are respectively subtracted from bc _ f3 to obtain four difference values: bc _ f4_ diff0, bc _ f4_ diff1, bc _ f4_ diff2, and bc _ f4_ diff 3.
Where a diff value of 0 represents a difference of-2, 1 represents a difference of-1, 2 represents a difference of 0, and 3 represents a difference of 1, then 4 diff values are written in the TEXT.
Wherein bc _ f3 equals 15 if all pixels within the 4x4 block are the same; if min _ f3 are all equal to 0, bc _ f3 is equal to 0; if min _ f3 equals 0 or 1, bc _ f3 equals 1, only 4 1-bit values bin _ f3_ mbk of min _ f3 need to be stored; if min _ f4 equals 0 or 1, bc _ f4 equals 1, only 4 1-bit values bin _ f4_ pxl of min _ f4 need to be stored; if 4 of the values bc _ f3 and bc _ f4 are greater than 1, zero _ idx is calculated for each of the 4 node minimum trees, where zero _ idx may be as shown in fig. 12.
Specifically, as shown in FIG. 13, the minimum value min _ f2 of 4 × 4 blocks (sbk0, sbk1, sbk2, sbk3) can be obtained in sequence,
sbk0_ min _ f2, sbk1_ min _ f2, sbk2_ min _ f2, sbk3_ min _ f 2. Then, as shown in fig. 13, a new minimum value tree and a new bit width tree are generated according to the above method, resulting in min _ f1 and 4 min _ f 2.
Meanwhile, bc _ f2 is calculated according to min _ f2, the bc _ f2 is not restricted, and has the value range of 0-8 and 15, wherein 0 represents that 4 values of min _ f2 are all 0, and 15 represents that the 16x4 pixels are all equal to min _ f 1. When bc _ f2 is equal to 1, 4 1-bit values bin _ f2_ sbk are also written, and when bc _ f2 is greater than 1 and less than 15, zero _ idx _ f2 and three bins _ f2_ idx are also written.
S3: TEXT write format
After compression, the format of TEXT write to memory can be as shown in table 2 below:
TABLE 2
Figure BDA0001806590690000071
Figure BDA0001806590690000081
S4: LIST write format:
LIST information of each mb occupies 64bits, and the format is shown in table 3 below:
TABLE 3
Figure BDA0001806590690000091
In this specification, adjectives such as first and second may only be used to distinguish one element or action from another, without necessarily requiring or implying any actual such relationship or order. References to an element or component or step (etc.) should not be construed as limited to only one of the element, component, or step, but rather to one or more of the element, component, or step, etc., where the context permits.
Fig. 14 is a bit width value storage method according to an embodiment of the present disclosure. Although the flow described below includes operations that occur in a particular order, it should be appreciated that the processes may include more or less operations that are performed sequentially or in parallel (e.g., using parallel processors or a multi-threaded environment). As shown in fig. 14, the method includes:
step 1401: acquiring bit width trees corresponding to 4 2x2 reconstructed frames;
step 1402: performing difference processing on the bit width value corresponding to each 2x2 pixel block in the bit width tree and the bit width values corresponding to 4 2x2 reconstruction frames to obtain four difference values;
step 1403: the four differences are written into TEXT.
Specifically, in the above step 1402, the bit width value corresponding to each 2 × 2 pixel block in the bit width tree is subjected to difference processing with the bit width value corresponding to 4 2 × 2 reconstructed frames, so as to obtain four difference values, where the difference value is-2, and may be represented by 0; when the difference is-1, the expression is 1; when the difference is 0, it is represented by 2; when the difference is 1, it is represented by 3.
And setting the corresponding bit width value of the 4 2 × 2 reconstructed frames to be 15 under the condition that all the pixel values in the 4 2 × 2 reconstructed frames are the same.
The step 1401 of obtaining the bit width tree corresponding to the 4 2 × 2 reconstructed frames may include:
s1: acquiring the 4 reconstructed frames of 2x 2;
s2: determining the minimum pixel value in each 2x2 pixel block to obtain 4 pixel values;
s3: taking the minimum value in the 4 pixel values as the minimum value of the 4x4 pixel blocks;
s4: subtracting the minimum value of the corresponding 2 × 2 pixel blocks from the 4 2 × 2 pixel blocks respectively, and determining the minimum pixel value in each 2 × 2 pixel block after subtracting the minimum value to obtain the minimum value tree;
s5: determining the maximum value of each 2x2 pixel block after the 4 2x2 pixel blocks are respectively subtracted by the minimum value;
s6: converting the maximum value in each 2x2 pixel block into a binary value;
s7: and converting the maximum value in each 2x2 pixel block into binary digits as bit width to obtain a bit width tree.
In implementation, after acquiring the bit width trees corresponding to the 4 2 × 2 reconstructed frames, the bit width values corresponding to the 4 2 × 2 reconstructed frames may be determined according to the following constraint conditions:
1) the bit width of the minimum value of the 4 × 4 pixel blocks is not less than the bit width of the maximum value in the maximum values in each 2 × 2 pixel block minus 1;
2) the bit width of the maximum value in each 2x2 pixel block is not less than the bit width of the minimum value of said 4x4 pixel block minus 2.
Based on the same inventive concept, embodiments of the present invention further provide a bit width value storage device, as described in the following embodiments. Because the principle of the bit width value storage device for solving the problem is similar to the bit width value storage method, the implementation of the bit width value storage device can refer to the implementation of the bit width value storage method, and repeated details are not repeated. As used hereinafter, the term "unit" or "module" may be a combination of software and/or hardware that implements a predetermined function. Although the means described in the embodiments below are preferably implemented in software, an implementation in hardware, or a combination of software and hardware is also possible and contemplated. Fig. 15 is a block diagram of a structure of a bit-width value storage apparatus according to an embodiment of the present invention, and as shown in fig. 15, the bit-width value storage apparatus may include: the configuration of the acquisition module 1501, the processing module 1502, and the writing module 1503 will be described below.
An obtaining module 1501, configured to obtain 4bit width trees corresponding to 2 × 2 reconstructed frames;
a processing module 1502, configured to perform difference processing on a bit width value corresponding to each 2 × 2 pixel block in the bit width tree and a bit width value corresponding to 4 2 × 2 reconstructed frames to obtain four difference values;
a writing module 1503, configured to write the four difference values into TEXT.
In one embodiment, the processing module 1502 indicates 0 when the difference is-2; when the difference is-1, the expression is 1; when the difference is 0, it is represented by 2; when the difference is 1, it is represented by 3.
In one embodiment, when all the pixel values in the 4 2 × 2 reconstructed frames are the same, the bit width value corresponding to the 4 2 × 2 reconstructed frames is set to 15.
In one embodiment, the obtaining module 1501 may include: an obtaining unit, configured to obtain the 4 2 × 2 reconstructed frames; a first determining unit, configured to determine a minimum pixel value in each 2 × 2 pixel block, to obtain 4 pixel values; a generating unit, configured to use a minimum value of the 4 pixel values as a minimum value of the 4 × 4 pixel block; a calculating unit, configured to subtract the minimum value of the corresponding 2 × 2 pixel block from each of the 4 2 × 2 pixel blocks, and determine the minimum pixel value in each of the 2 × 2 pixel blocks after subtracting the minimum value, so as to obtain the minimum value tree; a second determining unit configured to determine a maximum value in each of the 2 × 2 pixel blocks after subtracting the minimum value from each of the 4 2 × 2 pixel blocks; a conversion unit for converting the maximum value in each 2 × 2 pixel block into a binary value; and the generating unit is used for converting the maximum value in each 2x2 pixel block into binary digits as bit width to obtain a bit width tree.
In one embodiment, the apparatus may further include: the determining module is configured to determine bit width values corresponding to 4 2 × 2 reconstructed frames according to the following constraint conditions after acquiring bit width trees corresponding to the 4 2 × 2 reconstructed frames:
1) the bit width of the minimum value of the 4 × 4 pixel blocks is not less than the bit width of the maximum value in the maximum values in each 2 × 2 pixel block minus 1;
2) the bit width of the maximum value in each 2x2 pixel block is not less than the bit width of the minimum value of said 4x4 pixel block minus 2.
In another embodiment, a software is provided, which is used to execute the technical solutions described in the above embodiments and preferred embodiments.
In another embodiment, a storage medium is provided, in which the software is stored, and the storage medium includes but is not limited to: optical disks, floppy disks, hard disks, erasable memory, etc.
From the above description, it can be seen that the embodiments of the present invention achieve the following technical effects: and acquiring a bit width tree corresponding to 4 2 × 2 reconstructed frames, then performing difference processing on a bit width value corresponding to each 2 × 2 pixel block in the bit width tree and a bit width value corresponding to 4 2 × 2 reconstructed frames to obtain four difference values, and writing the four difference values into TEXT. Because the difference value is written in the TEXT, the bandwidth occupied by writing and reading the reconstructed frame is small, thereby realizing the compression processing of the reconstructed frame, and because the data is compressed, the bandwidth requirement can be reduced in the encoding and decoding process.
Although the present application provides method steps as described in an embodiment or flowchart, additional or fewer steps may be included based on conventional or non-inventive efforts. The order of steps recited in the embodiments is merely one manner of performing the steps in a multitude of orders and does not represent the only order of execution. When an actual apparatus or client product executes, it may execute sequentially or in parallel (e.g., in the context of parallel processors or multi-threaded processing) according to the embodiments or methods shown in the figures.
The apparatuses or modules illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. For convenience of description, the above devices are described as being divided into various modules by functions, and are described separately. The functionality of the modules may be implemented in the same one or more software and/or hardware implementations of the present application. Of course, a module that implements a certain function may be implemented by a plurality of sub-modules or sub-units in combination.
The methods, apparatus or modules described herein may be implemented in computer readable program code to a controller implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer readable medium storing computer readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, Application Specific Integrated Circuits (ASICs), programmable logic controllers and embedded microcontrollers, examples of which include, but are not limited to, the following microcontrollers: the ARC625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic for the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may therefore be considered as a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
Some of the modules in the apparatus described herein may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, classes, etc. that perform particular tasks or implement particular abstract data types. The application may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
From the above description of the embodiments, it is clear to those skilled in the art that the present application can be implemented by software plus necessary hardware. Based on such understanding, the technical solutions of the present application may be embodied in the form of software products or in the implementation process of data migration, which essentially or partially contributes to the prior art. The computer software product may be stored in a storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, mobile terminal, server, or network device, etc.) to perform the methods described in the various embodiments or portions of the embodiments of the present application.
The embodiments in the present specification are described in a progressive manner, and the same or similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. All or portions of the present application are operational with numerous general purpose or special purpose computing system environments or configurations. For example: personal computers, server computers, hand-held or portable devices, tablet-type devices, mobile communication terminals, multiprocessor systems, microprocessor-based systems, programmable electronic devices, network PCs, minicomputers, mainframe computers, distributed computing environments that include any of the above systems or devices, and the like.
While the present application has been described with examples, those of ordinary skill in the art will appreciate that there are numerous variations and permutations of the present application without departing from the spirit of the application, and it is intended that the appended claims encompass such variations and permutations without departing from the spirit of the application.

Claims (10)

1. A method for storing a bit width value, comprising:
acquiring bit width trees corresponding to 4 2x2 reconstructed frames;
performing difference processing on the bit width value corresponding to each 2x2 pixel block in the bit width tree and the bit width values corresponding to 4 2x2 reconstruction frames to obtain four difference values;
the four differences are written into TEXT.
2. The method according to claim 1, wherein the step of differencing the bit width value corresponding to each 2 × 2 pixel block in the bit width tree with the bit width value corresponding to 4 2 × 2 reconstructed frames to obtain four differences comprises:
when the difference is-2, it is represented by 0;
when the difference is-1, the expression is 1;
when the difference is 0, it is represented by 2;
when the difference is 1, it is represented by 3.
3. The method according to claim 1, wherein the bit width value corresponding to the 4 2x2 reconstructed frames is set to 15 if all pixel values in the 4 2x2 reconstructed frames are the same.
4. The method of claim 1, wherein obtaining the bit width tree corresponding to 4 2x2 reconstructed frames comprises:
acquiring the 4 reconstructed frames of 2x 2;
determining the minimum pixel value in each 2x2 pixel block to obtain 4 pixel values;
taking the minimum value in the 4 pixel values as the minimum value of the 4x4 pixel blocks;
subtracting the minimum value of the corresponding 2 × 2 pixel blocks from the 4 2 × 2 pixel blocks respectively, and determining the minimum pixel value in each 2 × 2 pixel block after subtracting the minimum value to obtain the minimum value tree;
determining the maximum value of each 2x2 pixel block after the 4 2x2 pixel blocks are respectively subtracted by the minimum value;
converting the maximum value in each 2x2 pixel block into a binary value;
and converting the maximum value in each 2x2 pixel block into binary digits as bit width to obtain a bit width tree.
5. The method of claim 4, wherein after obtaining the bit width tree corresponding to the 4 2x2 reconstructed frames, the method further comprises:
determining bit width values corresponding to 4 reconstructed frames of 2x2 according to the following constraint conditions:
the bit width of the minimum value of the 4x4 pixel blocks is not less than the bit width of the maximum value in each 2x2 pixel block minus 1;
the bit width of the maximum value in each 2x2 pixel block is not less than the bit width of the minimum value of said 4x4 pixel block minus 2.
6. A bit-width value storage device, comprising:
the acquisition module is used for acquiring bit width trees corresponding to 4 2x2 reconstructed frames;
the processing module is used for performing difference processing on the bit width value corresponding to each 2x2 pixel block in the bit width tree and the bit width value corresponding to 4 2x2 reconstruction frames to obtain four difference values;
and the writing module is used for writing the four difference values into TEXT.
7. The apparatus of claim 6, wherein the processing module indicates 0 when the difference is-2; when the difference is-1, the expression is 1; when the difference is 0, it is represented by 2; when the difference is 1, it is represented by 3.
8. The apparatus according to claim 6, wherein the bit width value corresponding to the 4 2x2 reconstructed frames is set to 15 if all pixel values in the 4 2x2 reconstructed frames are the same.
9. The apparatus of claim 6, wherein the obtaining module comprises:
an obtaining unit, configured to obtain the 4 2 × 2 reconstructed frames;
a first determining unit, configured to determine a minimum pixel value in each 2 × 2 pixel block, to obtain 4 pixel values;
a generating unit, configured to use a minimum value of the 4 pixel values as a minimum value of the 4 × 4 pixel block;
a calculating unit, configured to subtract the minimum value of the corresponding 2 × 2 pixel block from each of the 4 2 × 2 pixel blocks, and determine the minimum pixel value in each of the 2 × 2 pixel blocks after subtracting the minimum value, so as to obtain the minimum value tree;
a second determining unit configured to determine a maximum value in each of the 2 × 2 pixel blocks after subtracting the minimum value from each of the 4 2 × 2 pixel blocks;
a conversion unit for converting the maximum value in each 2 × 2 pixel block into a binary value;
and the generating unit is used for converting the maximum value in each 2x2 pixel block into binary digits as bit width to obtain a bit width tree.
10. The apparatus of claim 9, further comprising:
the determining module is configured to determine bit width values corresponding to 4 2 × 2 reconstructed frames according to the following constraint conditions after acquiring bit width trees corresponding to the 4 2 × 2 reconstructed frames:
the bit width of the minimum value of the 4x4 pixel blocks is not less than the bit width of the maximum value in each 2x2 pixel block minus 1;
the bit width of the maximum value in each 2x2 pixel block is not less than the bit width of the minimum value of said 4x4 pixel block minus 2.
CN201811100726.7A 2018-09-20 2018-09-20 Bit width value storage method and device Active CN110933444B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811100726.7A CN110933444B (en) 2018-09-20 2018-09-20 Bit width value storage method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811100726.7A CN110933444B (en) 2018-09-20 2018-09-20 Bit width value storage method and device

Publications (2)

Publication Number Publication Date
CN110933444A true CN110933444A (en) 2020-03-27
CN110933444B CN110933444B (en) 2021-10-29

Family

ID=69856217

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811100726.7A Active CN110933444B (en) 2018-09-20 2018-09-20 Bit width value storage method and device

Country Status (1)

Country Link
CN (1) CN110933444B (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080267295A1 (en) * 2007-04-26 2008-10-30 Chih-Ta Star Sung Video decompression, de-interlacing and frame rate conversion with frame buffer compression
CN103974072A (en) * 2013-01-29 2014-08-06 江山 Frame storage method based on block compression during video decoding
CN105744275A (en) * 2016-02-22 2016-07-06 青岛海信电器股份有限公司 Video data input method, video data output method, video data input device and video data output device
CN106375762A (en) * 2015-07-22 2017-02-01 杭州海康威视数字技术股份有限公司 Reference frame data compression method and apparatus
CN107026999A (en) * 2016-08-04 2017-08-08 成都小娱网络科技有限公司 Compression method is cached outside a kind of piece for ultra high-definition processing system for video
US9767529B1 (en) * 2013-12-18 2017-09-19 Mediatek Inc. Method and apparatus for accessing compressed data and/or uncompressed data of image frame in frame buffer

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20080267295A1 (en) * 2007-04-26 2008-10-30 Chih-Ta Star Sung Video decompression, de-interlacing and frame rate conversion with frame buffer compression
CN103974072A (en) * 2013-01-29 2014-08-06 江山 Frame storage method based on block compression during video decoding
US9767529B1 (en) * 2013-12-18 2017-09-19 Mediatek Inc. Method and apparatus for accessing compressed data and/or uncompressed data of image frame in frame buffer
CN106375762A (en) * 2015-07-22 2017-02-01 杭州海康威视数字技术股份有限公司 Reference frame data compression method and apparatus
CN105744275A (en) * 2016-02-22 2016-07-06 青岛海信电器股份有限公司 Video data input method, video data output method, video data input device and video data output device
CN107026999A (en) * 2016-08-04 2017-08-08 成都小娱网络科技有限公司 Compression method is cached outside a kind of piece for ultra high-definition processing system for video

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
亢丽娟: "提高HEVC视频编码性能的相关技术研究", 《中国优秀硕士学位论文全文数据库》 *

Also Published As

Publication number Publication date
CN110933444B (en) 2021-10-29

Similar Documents

Publication Publication Date Title
CN102016829B (en) The error calculated during reverse discrete cosine transform reduces
US11715002B2 (en) Efficient data encoding for deep neural network training
US20150277776A1 (en) Data storage control apparatus and data storage control method
US20220014767A1 (en) Bit plane encoding of data arrays
CN114222129A (en) Image compression encoding method, image compression encoding device, computer equipment and storage medium
CN105472389A (en) Out-chip buffer compression method for superhigh-definition processing system
CN103716634A (en) Method and apparatus for data compression using error plane coding
CN114615507B (en) Image coding method, decoding method and related device
CN110913230A (en) Video frame prediction method and device and terminal equipment
CN110913219A (en) Video frame prediction method and device and terminal equipment
CN110933444B (en) Bit width value storage method and device
CN110933413A (en) Video frame processing method and device
CN111083479A (en) Video frame prediction method and device and terminal equipment
CN110944212A (en) Video frame reconstruction method and device and terminal equipment
CN110933442B (en) 16x4 level reference frame compression method and device
Matsuda et al. Lossless coding using predictors and arithmetic code optimized for each image
US20170201759A1 (en) Method and device for image encoding and image decoding
CN109474826B (en) Picture compression method and device, electronic equipment and storage medium
CN110933443A (en) Video reconstruction frame storage method and device
CN110545437B (en) Coefficient encoding method, coefficient decoding method, electronic device, and medium
CN111083500A (en) Video frame reconstruction method and device and terminal equipment
CN110830806A (en) Video frame prediction method and device and terminal equipment
CN107172425B (en) Thumbnail generation method and device and terminal equipment
US10015507B2 (en) Transform system and method in video and image compression
US11496770B2 (en) Media object compression/decompression with adaptive processing for block-level sub-errors and/or decomposed block-level sub-errors

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant