Video encoding method, device, electronic device, storage medium, program product, and method for generating a bitstream

By performing pre-defined variable statistics and mapping relationship function processing on the coding units of the video coding tree, the process of updating quantization parameters is simplified, the problem of high computational complexity in existing technologies is solved, and coding efficiency is improved.

CN119299689BActive Publication Date: 2025-11-04BEIJING DAJIA INTERNET INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411426547.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-12
Publication Date
2025-11-04
Estimated Expiration
2044-10-12

AI Technical Summary

Technical Problem

Existing video coding technologies involve complex calculation processes, large computational loads, and long processing times when selecting quantization parameters and optimizing coding modes, which limits coding efficiency.

Method used

By performing statistical processing on the encoding variables of each encoding tree unit, statistical values ​​of encoding information are obtained, and the quantization parameter increment is determined using a mapping function, thus simplifying the quantization parameter update process.

Benefits of technology

The calculation process was reduced, the amount of computation was decreased, the calculation time was shortened, and the coding efficiency was optimized.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119299689B_ABST
    Figure CN119299689B_ABST
Patent Text Reader

Abstract

The present disclosure provides a video coding method, device, electronic equipment, storage medium, program product and method for generating a bitstream, the video coding method comprising: obtaining coding information of a current video frame after mode decision, wherein the current video frame is divided into a plurality of coding tree units, each coding tree unit comprising a plurality of coding units, and the coding information comprising information of preset coding variables of each coding unit; for each coding tree unit, performing the following processing: performing statistical processing on the information of the preset coding variables of each coding unit in the current coding tree unit to obtain a coding information statistical value; determining a quantization parameter increment according to the coding information statistical value and a mapping relationship function, wherein the mapping relationship function is used to specify a mapping relationship between the coding information statistical value and the quantization parameter increment; and encoding the current coding tree unit based on the determined quantization parameter increment. The method can simplify the calculation of the quantization parameter increment and optimize the coding efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present disclosure relates to video coding and compression. More specifically, the present disclosure relates to a video coding method, apparatus, electronic device, storage medium, program product and a method of generating a bitstream. BACKGROUND

[0002] Various electronic devices (e.g., digital televisions, laptop or desktop computers, tablet computers, digital cameras, digital recording devices, digital media players, video gaming consoles, smart phones, video teleconferencing devices, video streaming devices, etc.) support digital video. Electronic devices transmit and receive, or otherwise communicate, digital video data over communication networks and / or store digital video data on storage devices. Because the bandwidth of communication networks and the storage capacity of storage devices are limited resources, video data can be compressed according to one or more video coding standards prior to being communicated or stored. For example, video coding standards include Versatile Video Coding (VVC), Joint Exploration Test Model (JEM), High Efficiency Video Coding (HEVC / H.265), Advanced Video Coding (AVC / H.264), Moving Picture Experts Group (MPEG) codecs, etc. Video coding generally employs predictive methods to exploit redundancies in video data. Video coding aims to compress video data into a form that uses a lower bit rate, while avoiding or minimizing degradations to video quality.

[0003] In modern video coding, rate control is a key technique to guarantee video quality and transmission efficiency. Effective rate allocation needs to be managed in detail at different coding unit levels, such as GOP (Group of Pictures) level, slice level, CU (Coding Unit) level, to balance the needs of coding quality and bit rate allocation. Among them, the rate control at the CU level involves the selection of QP (Quantization Parameter) and the optimization of coding mode, which directly affects the objective and subjective quality of the coded video.

[0004] In the related art, the QP is initially determined, then the mode decision is made, and then a plurality of different QPs are obtained based on the initially determined QP, and trial operations are performed on the plurality of different QPs, and finally the final QP is selected according to the trial operation results. However, the calculation process of this scheme is complex, the calculation amount is large, and the time is long, which restricts the coding efficiency. SUMMARY

[0005] Embodiments of the present disclosure provide a video encoding method, device, electronic equipment, storage medium, program product and method for generating a bitstream, for solving at least one of the above problems.

[0006] According to an aspect of the present disclosure, a video encoding method is provided, comprising: obtaining encoding information of a current video frame after mode decision, wherein the current video frame is divided into a plurality of coding tree units, each coding tree unit comprising a plurality of coding units, and the encoding information comprises information of a preset encoding variable of each coding unit; for each coding tree unit, performing the following processing: performing statistical processing on the information of the preset encoding variable of each coding unit in the current coding tree unit to obtain an encoding information statistical value; determining a quantization parameter increment according to the encoding information statistical value and a mapping relationship function, wherein the mapping relationship function is used to specify a mapping relationship between the encoding information statistical value and the quantization parameter increment; and encoding the current coding tree unit based on the determined quantization parameter increment.

[0007] Optionally, the preset encoding variable comprises at least one encoding variable, and the statistical processing on the information of the preset encoding variable of each coding unit in the current coding tree unit to obtain an encoding information statistical value comprises: performing corresponding statistical processing on the information of each encoding variable of each coding unit in the current coding tree unit respectively to obtain at least one encoding information statistical value.

[0008] Optionally, the preset encoding variable comprises a prediction mode, and the statistical processing on the information of each encoding variable of each coding unit in the current coding tree unit to obtain at least one encoding information statistical value comprises: statistically processing proportions of coding units of an intra prediction mode and proportions of coding units of a skip prediction mode in the current coding tree unit to obtain an intra proportion and a skip proportion as two encoding information statistical values, wherein the proportions are area proportions or number proportions.

[0009] Optionally, the determining of the quantization parameter increment according to the encoding information statistical value and the mapping relationship function comprises: performing weighted summation on the at least one encoding information statistical value to determine the quantization parameter increment.

[0010] Optionally, the weight used for the weighted summation of the at least one encoding information statistical value is obtained through offline fitting with an optimization of a subjective encoding quality index, and the subjective encoding quality index comprises at least one of the following: a video multi-method assessment fusion score, a mean opinion score, a visual quality score and a structural similarity index.

[0011] Optionally, the preset coding variable includes at least one of a prediction mode of a coding unit, a block size of a coding unit, a transform mode of a coding unit, a prediction mode of a neighboring coding unit of a coding unit, a block size of a neighboring coding unit of a coding unit, and a transform mode of a neighboring coding unit of a coding unit; the statistical processing related to the prediction mode includes statistics of a proportion of at least one prediction mode in the current coding tree unit, the at least one prediction mode including at least one of an intra prediction mode and a skip prediction mode, the proportion being an area proportion or a number proportion; the statistical processing related to the block size includes statistics of an average value of the block size; and the statistical processing related to the transform mode includes statistics of a proportion of at least one transform mode in the current coding tree unit, the proportion being an area proportion or a number proportion.

[0012] Optionally, the processing performed for each coding tree unit further includes: performing clipping processing on the quantization parameter increment determined according to the coding information statistics value and the mapping relationship function using a clipping function to obtain a clipped quantization parameter increment as a finally determined quantization parameter increment, wherein the clipping function is used to limit the quantization parameter increment within a preset value range.

[0013] Optionally, the encoding of the current coding tree unit based on the determined quantization parameter increment includes: in a case where the quantization parameter increment is less than 0, adjusting the quantization parameter of the current coding tree unit according to the quantization parameter increment; and in a case where the quantization parameter increment is greater than or equal to 0, maintaining the quantization parameter of the current coding tree unit.

[0014] According to another aspect of the present disclosure, a video encoding apparatus is provided, including: an acquisition unit configured to acquire coding information of a current video frame after mode decision, wherein the current video frame is divided into a plurality of coding tree units, each coding tree unit including a plurality of coding units, and the coding information includes information of preset coding variables of each coding unit; a processing unit configured to perform, for each coding tree unit, the following processing: performing statistical processing on the information of the preset coding variables of each coding unit in the current coding tree unit to obtain a coding information statistics value; determining a quantization parameter increment according to the coding information statistics value and a mapping relationship function, wherein the mapping relationship function is used to specify a mapping relationship between the coding information statistics value and the quantization parameter increment; and encoding the current coding tree unit based on the determined quantization parameter increment.

[0015] Optionally, the preset coding variable includes at least one coding variable, and the processing unit is further configured to perform corresponding statistical processing on the information of each coding variable of each coding unit in the current coding tree unit to obtain at least one coding information statistics value.

[0016] Optionally, the preset encoding variable includes a prediction mode, and the processing unit is further configured to count proportions of coding units of an intra prediction mode and proportions of coding units of a skip prediction mode in the current coding tree unit, to obtain an intra proportion and an intra proportion as two encoding information statistical values, wherein the counted proportions are area proportions or number proportions.

[0017] Optionally, the processing unit is further configured to perform weighted summation on the at least one encoding information statistical value to determine the quantization parameter increment.

[0018] Optionally, the weights used in the weighted summation of the at least one encoding information statistical value are obtained through offline fitting with an optimization of a subjective encoding quality index, and the subjective encoding quality index includes at least one of the following: a video multi-method assessment fusion score, a mean opinion score, a visual quality score, and a structural similarity index.

[0019] Optionally, the preset encoding variable includes at least one of the following: a prediction mode of a coding unit, a block size of a coding unit, a transform mode of a coding unit, a prediction mode of a neighboring coding unit of a coding unit, a block size of a neighboring coding unit of a coding unit, and a transform mode of a neighboring coding unit of a coding unit; wherein the statistical processing related to the prediction mode includes counting proportions of at least one prediction mode in the current coding tree unit, and the at least one prediction mode includes at least one of the following: an intra prediction mode and a skip prediction mode, and the counted proportions are area proportions or number proportions; the statistical processing related to the block size includes counting an average value of the block size; and the statistical processing related to the transform mode includes counting proportions of at least one transform mode in the current coding tree unit, and the counted proportions are area proportions or number proportions.

[0020] Optionally, the processing unit is further configured to perform clipping processing on the quantization parameter increment determined according to the encoding information statistical value and the mapping relationship function, using a clipping function, to obtain a clipped quantization parameter increment as a finally determined quantization parameter increment, wherein the clipping function is used to limit the quantization parameter increment within a preset value range.

[0021] Optionally, the processing unit is further configured to: in a case where the quantization parameter increment is less than 0, adjust the quantization parameter of the current coding tree unit according to the quantization parameter increment; and in a case where the quantization parameter increment is greater than or equal to 0, maintain the quantization parameter of the current coding tree unit.

[0022] According to another aspect of the present disclosure, an electronic device is provided, comprising: at least one processor; at least one memory storing computer executable instructions, wherein the computer executable instructions, when executed by the at least one processor, cause the at least one processor to perform the video encoding method as described above.

[0023] According to another aspect of the present disclosure, a computer readable storage medium is provided, when instructions in the computer readable storage medium are executed by at least one processor, cause the at least one processor to perform the video encoding method as described above.

[0024] According to another aspect of the present disclosure, a computer program product is provided, comprising computer instructions, which, when executed by at least one processor, implement the video encoding method as described above.

[0025] According to another aspect of the present disclosure, a computer program product is provided, comprising instructions for storing a bitstream, wherein the bitstream comprises: video data generated according to the video encoding method as described above.

[0026] According to another aspect of the present disclosure, a method for generating a bitstream is provided, comprising: generating a bitstream according to the video encoding method as described above.

[0027] The video encoding method, device, electronic device, storage medium, program product and method for generating a bitstream according to the exemplary embodiments of the present disclosure can quantitatively reflect the encoding characteristics possessed by the current coding tree unit by performing statistical processing based on the information of the preset encoding variable (e.g. prediction mode) of each coding unit for each coding tree unit to obtain the encoding information statistical value. On this basis, the mapping relationship function between the encoding information statistical value and the quantization parameter increment is utilized to determine the quantization parameter increment according to the actual statistical encoding information statistical value, so that the explicit quantization parameter increment can be obtained with a target, and then the encoding is performed. At this time, the quantization parameter QP only needs to be updated once, without the need to update the quantization parameter QP multiple times and repeatedly perform trial operations, thereby effectively simplifying the calculation process, reducing the calculation amount, shortening the calculation time consumption, and optimizing the encoding efficiency.

[0028] It will be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF DRAWINGS

[0029] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate examples consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0030] Figure 1 is a block diagram illustrating an exemplary system for encoding and decoding a video block according to some embodiments of the present disclosure.

[0031] Figure 2 is a block diagram illustrating an exemplary video encoder in accordance with some embodiments of the present disclosure.

[0032] Figure 3 is a block diagram illustrating an exemplary video decoder in accordance with some embodiments of the present disclosure.

[0033] Figure 4 is a flowchart illustrating a video encoding method in accordance with some embodiments of the present disclosure.

[0034] Figure 5 is a flowchart illustrating a processing of a video encoding method for a coding tree unit in accordance with some embodiments of the present disclosure.

[0035] Figure 6 is a block diagram illustrating a video encoding apparatus in accordance with some embodiments of the present disclosure.

[0036] Figure 7 is a diagram illustrating a computing environment coupled with a user interface in accordance with some embodiments of the present disclosure. DETAILED DESCRIPTION

[0037] Reference will now be made in detail to specific implementations, examples of which are illustrated in the accompanying drawings. In the following detailed description of embodiments of the present disclosure, numerous specific details are set forth in order to provide a thorough understanding of the subject matter presented herein. However, it will be apparent to one skilled in the art that the subject matter presented can be practiced without these specific details. In other instances, well-known methods, procedures, components, and networks have not been described in detail so as not to unnecessarily obscure aspects of the subject matter.

[0038] It should be noted that the terms "first", "second", and the like, used in the description and the claims of the present disclosure, as well as in the accompanying drawings, are used to distinguish between similar objects, not to describe a particular sequential or chronological order. It is to be understood that the use of these terms in the description is merely for distinguishing between the objects, and the data so distinguished can be interchanged under appropriate circumstances to accomplish the embodiments of the present disclosure described herein, in sequences other than those described by the claims and / or illustrated in the drawings.

[0039] Figure 1 is a block diagram illustrating an exemplary system 10 for encoding and decoding video blocks in parallel in accordance with some embodiments of the present disclosure. As Figure 1As shown in FIG. 1, system 10 includes a source device 12 that generates and encodes video data to be decoded at a later time by a destination device 14. Source device 12 and destination device 14 can comprise any of a wide variety of electronic devices, including a cloud server, a server computer, a desktop or laptop computer, a tablet computer, a smart phone, a set-top box, a digital television, a camera, a display device, a digital media player, a video gaming console, a video streaming device, and the like. In some implementations, source device 12 and destination device 14 are equipped with wireless communication capability.

[0040] In some implementations, destination device 14 can receive the encoded video data to be decoded via link 16. Link 16 can comprise any type of communication medium or device capable of moving the encoded video data from source device 12 to destination device 14.

[0041] In other implementations, the encoded video data can be transmitted from output interface 22 to storage device 32. Subsequently, the encoded video data in storage device 32 can be accessed by destination device 14 via input interface 28.

[0042] As Figure 1 As shown in FIG. 1, source device 12 includes video source 18, video encoder 20, and output interface 22. Video source 18 can comprise a source such as a video capture device (e.g., a video camera), a video archive containing previously captured video, a video feed interface to receive video from a video content provider, and / or a computer graphics system for generating computer graphics video as the source video.

[0043] The captured, pre-captured, or computer-generated video can be encoded by video encoder 20. The encoded video data can be transmitted directly to destination device 14 via output interface 22 of source device 12. The encoded video data can also (or alternatively) be stored onto storage device 32 for later access by destination device 14 or other devices, for decoding and / or playback.

[0044] Destination device 14 includes input interface 28, video decoder 30, and display device 34. Input interface 28 can include a receiver and / or a modem, and receives encoded video data over link 16. The encoded video data communicated over link 16, or provided on storage device 32, can include a variety of syntax elements generated by video encoder 20 for use by video decoder 30 in decoding the video data. Such syntax elements can be included within the encoded video data transmitted on a communication medium, stored on a storage medium, or stored on a file server.

[0045] Video encoder 20 and video decoder 30 can operate according to a proprietary standard or industry standard, such as VVC, HEVC, MPEG-4, Part 10, AVC, or extensions of such standards. It should be understood that the present disclosure is not limited to a specific video coding / decoding standard and can apply to other video coding / decoding standards. It is generally contemplated that video encoder 20 of source device 12 can be configured to encode video data according to any of these current or future standards. Similarly, it is also generally contemplated that video decoder 30 of destination device 14 can be configured to decode video data according to any of these current or future standards.

[0046] Video encoder 20 and video decoder 30 can be implemented as any of a variety of suitable encoder and / or decoder circuitry, such as one or more microprocessors, digital signal processors (DSPs), application specific integrated circuits (ASICs), field programmable gate arrays (FPGAs), discrete logic circuitry, software, hardware, firmware or any combinations thereof. When implemented partially in software, an electronic device can store instructions for the software in a suitable, non- transitory computer-readable medium and execute the instructions in hardware using one or more processors to perform the video coding / decoding operations disclosed in the present disclosure. Each of video encoder 20 and video decoder 30 can be included in one or more encoders or decoders, either of which can be integrated as part of a combined encoder / decoder (CODEC) in a respective device.

[0047] Figure 2 FIG. 1 is a block diagram illustrating an example video encoder 20 according to some embodiments described in the present disclosure. Video encoder 20 can perform intra-prediction coding and inter-prediction coding on video blocks within a video frame. Intra-prediction coding relies on spatial prediction to reduce or remove spatial redundancy in the video data within a given video frame or picture. Inter-prediction coding relies on temporal prediction to reduce or remove temporal redundancy in the video data within neighboring video frames or pictures of a video sequence. It should be noted that in the field of video coding, the term “frame” can be used as a synonym for the term “image” or “picture.”

[0048] As Figure 2As shown in FIG. 1, video encoder 20 includes video data memory 40, prediction processing unit 41, decoded picture buffer (DPB) 64, summer 50, transform processing unit 52, quantization unit 54, and entropy encoding unit 56. Prediction processing unit 41 further includes motion estimation unit 42, motion compensation unit 44, partition unit 45, intra-prediction processing unit 46, and intra block copy (BC) unit 48. In some implementations, video encoder 20 also includes inverse quantization unit 58, inverse transform processing unit 60, and summer 62 for video block reconstruction. A loop filter 63, such as a deblocking filter, can be located between summer 62 and DPB 64 to filter block boundaries to remove blockiness artifacts from reconstructed video. In addition to the deblocking filter, another loop filter (e.g., a sample adaptive offset (SAO) filter, a cross component sample adaptive offset (CCSAO) filter, and / or an adaptive loop filter (ALF)) can be used to filter the output of summer 62. In some examples, the loop filters can be omitted, and the decoded video blocks can be provided directly from summer 62 to DPB 64. Video encoder 20 can take the form of a fixed or programmable hardware encoder, or can be dispersed into one or more of the illustrated fixed or programmable hardware encoders.

[0049] Video data memory 40 can store video data to be encoded by the components of video encoder 20. The video data in video data memory 40 can be obtained, for example, from video source 18 as shown in FIG. 1. DPB 64 is a buffer that stores reference video data (e.g., reference frames or pictures) for use in encoding video data by video encoder 20 (e.g., in intra- or inter-coding modes). Figure 1

[0050] As shown in FIG. 1, video encoder 20 includes video data memory 40, prediction processing unit 41, decoded picture buffer (DPB) 64, summer 50, transform processing unit 52, quantization unit 54, and entropy encoding unit 56. Prediction processing unit 41 further includes motion estimation unit 42, motion compensation unit 44, partition unit 45, intra-prediction processing unit 46, and intra block copy (BC) unit 48. In some implementations, video encoder 20 also includes inverse quantization unit 58, inverse transform processing unit 60, and summer 62 for video block reconstruction. A loop filter 63, such as a deblocking filter, can be located between summer 62 and DPB 64 to filter block boundaries to remove blockiness artifacts from reconstructed video. In addition to the deblocking filter, another loop filter (e.g., a sample adaptive offset (SAO) filter, a cross component sample adaptive offset (CCSAO) filter, and / or an adaptive loop filter (ALF)) can be used to filter the output of summer 62. In some examples, the loop filters can be omitted, and the decoded video blocks can be provided directly from summer 62 to DPB 64. Video encoder 20 can take the form of a fixed or programmable hardware encoder, or can be dispersed into one or more of the illustrated fixed or programmable hardware encoders. Figure 2

[0051] ​​Prediction processing unit 41 can select one of a plurality of possible predictive encoding modes, e.g., one of a plurality of intra-predictive encoding modes or one of a plurality of inter-predictive encoding modes, for the current video block based on the error results (e.g., coding rate and level of distortion). Prediction processing unit 41 can provide the resulting intra- or inter-predicted block to summer 50 to generate a residual block, and to summer 62 to reconstruct the encoded block for use as part of a reference frame at a later time. Prediction processing unit 41 also provides syntax elements, e.g., motion vectors, intra-mode indicators, partitioning information, and other such syntax information, to entropy encoding unit 56.

[0052] To select an appropriate intra-predictive encoding mode for the current video block, intra-prediction processing unit 46 within prediction processing unit 41 can perform intra-predictive encoding of the current video block in relation to one or more neighboring blocks in the same frame as the current block being encoded to provide spatial prediction. Motion estimation unit 42 and motion compensation unit 44 within prediction processing unit 41 perform inter-predictive encoding of the current video block in relation to one or more predictive blocks in one or more reference frames to provide temporal prediction. Video encoder 20 can perform multiple encoding passes, e.g., to select a suitable encoding mode for each block of video data.

[0053] In some implementations, motion estimation unit 42 determines an inter-prediction mode for a current video frame by generating motion vectors according to a predetermined pattern within a sequence of video frames, the motion vectors indicating displacement of video blocks within the current video frame relative to predictive blocks within a reference video frame. Motion estimation performed by motion estimation unit 42 is a process of generating motion vectors that estimate motion for video blocks. For example, a motion vector can indicate displacement of a video block within a current video frame or picture relative to a predictive block within a reference frame that is related to a current block being encoded within the current frame. The predetermined pattern can designate video frames in the sequence as P-frames or B-frames. Intra-BC unit 48 can determine vectors for intra-BC encoding (e.g., block vectors) in a similar manner as motion vectors determined by motion estimation unit 42 for inter-prediction, or can utilize block vectors determined by motion estimation unit 42.

[0054] Whether the predictive block is from the same frame according to intra-prediction or a different frame according to inter-prediction, video encoder 20 can form pixel difference values by subtracting pixel values of the predictive block from pixel values of the current video block being encoded, thereby forming a residual video block. The pixel difference values forming the residual video block can include both luma component differences and chroma component differences.

[0055] Intra prediction processing unit 46 can encode the current block using various intra prediction modes, e.g., during a separate encoding pass, and can select a suitable intra prediction mode to use from the tested intra prediction modes (or, in some examples, the mode selection unit). Intra prediction processing unit 46 can provide information indicating the selected intra prediction mode for the block to entropy encoding unit 56. Entropy encoding unit 56 can encode information indicating the selected intra prediction mode in the bitstream.

[0056] After prediction processing unit 41 determines a prediction block for the current video block via either inter prediction or intra prediction, summer 50 forms a residual video block by subtracting the prediction block from the current video block. The residual video data in the residual block can be included in one or more TUs and is provided to transform processing unit 52. Transform processing unit 52 transforms the residual video data into residual transform coefficients using a transform, e.g., a discrete cosine transform (DCT) or a conceptually similar transform.

[0057] Transform processing unit 52 can send the resulting transform coefficients to quantization unit 54. Quantization unit 54 quantizes the transform coefficients to further reduce bit rate. The quantization process can also reduce the bit depth associated with some or all of the coefficients. The degree of quantization can be modified by adjusting a quantization parameter. In some examples, quantization unit 54 can then perform a scan of the matrix including the quantized transform coefficients. Alternatively, entropy encoding unit 56 can perform the scan.

[0058] After quantization, entropy encoding unit 56 entropy encodes the quantized transform coefficients using, e.g., context adaptive variable length coding (CAVLC), context adaptive binary arithmetic coding (CABAC), syntax-based context-adaptive binary arithmetic coding (SBAC), probability interval partitioning entropy (PIPE) coding, or another entropy encoding methodology or technique, into a video bitstream. The encoded bitstream can then be transmitted to video decoder 30, as shown in FIG. 3, or archived, as shown in FIG. 4, for later transmission to or retrieval by video decoder 30. Entropy encoding unit 56 can also entropy encode motion vectors and other syntax elements for the current video frame being encoded. Figure 1 Figure 1

[0059] ​​The inverse quantization unit 58 and the inverse transform processing unit 60 apply inverse quantization and inverse transform, respectively, to reconstruct the residual video block in the pixel domain for generating a reference block used to predict other video blocks. As noted above, the motion compensation unit 44 can generate a motion compensated prediction block from one or more reference blocks of a frame stored in the DPB 64. The motion compensation unit 44 can also apply one or more interpolation filters to the prediction block to calculate sub-integer pixel values for use in motion estimation.

[0060] The summer 62 adds the reconstructed residual block to the motion compensated prediction block produced by the motion compensation unit 44 to produce a reference block for storage in the DPB 64. The reference block can then be used by the intra BC unit 48, the motion estimation unit 42, and the motion compensation unit 44 as a prediction block to inter predict another video block in a subsequent video frame.

[0061] Figure 3 FIG. 1 shows a block diagram of an example video decoder 30 in accordance with some embodiments of the present disclosure. The video decoder 30 includes a video data memory 79, an entropy decoding unit 80, a prediction processing unit 81, an inverse quantization unit 86, an inverse transform processing unit 88, a summer 90, and a DPB 92. The prediction processing unit 81 further includes a motion compensation unit 82, an intra prediction unit 84, and an intra BC unit 85. The video decoder 30 can perform a decoding process substantially reciprocal to the encoding process described above in connection with the video encoder 20. Figure 2 The decoding process described in connection with the video encoder 20 is substantially reciprocal. For example, the motion compensation unit 82 can generate prediction data based on motion vectors received from the entropy decoding unit 80, while the intra prediction unit 84 can generate prediction data based on intra prediction mode indicators received from the entropy decoding unit 80.

[0062] In some examples, embodiments of the present disclosure can be dispersed among one or more of the units of the video decoder 30. For example, the intra BC unit 85 can perform embodiments of the present disclosure alone or in combination with other units of the video decoder 30, such as the motion compensation unit 82, the intra prediction unit 84, and the entropy decoding unit 80. In some examples, the video decoder 30 can not include the intra BC unit 85, and the functionality of the intra BC unit 85 can be performed by other components of the prediction processing unit 81, such as the motion compensation unit 82.

[0063] The video data memory 79 can store video data, such as an encoded video bitstream, to be decoded by the other components of the video decoder 30. The video data stored in the video data memory 79 can be obtained, for example, from the storage device 32, from a local video source, such as a camera, via wired or wireless network communication of video data, or by accessing a physical data storage medium, such as a flash drive or hard disk.

[0064] During the decoding process, video decoder 30 receives an encoded video bitstream that represents encoded video frames and associated syntax elements of video blocks. Entropy decoding unit 80 of video decoder 30 entropy decodes the bitstream to generate quantized coefficients, motion vectors or intra-prediction mode indicators, and other syntax elements. Entropy decoding unit 80 then forwards the motion vectors or intra-prediction mode indicators, and other syntax elements to prediction processing unit 81.

[0065] When a video frame is coded as an intra-predicted coded (I) frame or an intra coded prediction block in other types of frames, intra-prediction unit 84 of prediction processing unit 81 can generate prediction data for a video block of the current video frame based on the intra-prediction mode signaled and reference data from previously decoded blocks of the current frame.

[0066] When a video frame is coded as an inter-predicted coded (i.e., B or P) frame, motion compensation unit 82 of prediction processing unit 81 produces one or more prediction blocks for a video block of the current video frame based on the motion vectors and other syntax elements received from entropy decoding unit 80. Each of the prediction blocks can be produced from a reference frame within one of the reference frame lists. Video decoder 30 can construct the reference frame lists, i.e., List 0 and List 1, using default construction techniques based on reference frames stored in DPB 92.

[0067] In some examples, when a video block is encoded according to the intra BC mode described herein, intra BC unit 85 of prediction processing unit 81 produces a prediction block for the current video block based on the block vector and other syntax elements received from entropy decoding unit 80. The prediction block can be within a reconstructed region of the same picture as the current video block, as defined by video encoder 20.

[0068] Motion compensation unit 82 and / or intra BC unit 85 determine the prediction information for a video block of the current video frame by parsing the motion vectors and other syntax elements, and then use the prediction information to produce a prediction block for the current video block being decoded.

[0069] Motion compensation unit 82 can also perform interpolation to calculate interpolated values for sub-integer pixels of reference blocks using interpolation filters as used by video encoder 20 during encoding of the video blocks. In this case, motion compensation unit 82 can determine the interpolation filters used by video encoder 20 from the syntax elements received, and use these interpolation filters to produce the prediction blocks.

[0070] Inverse quantization unit 86 inverse quantizes quantized transform coefficients provided in the bitstream and entropy decoded by entropy decoding unit 80 using the same quantization parameter calculated by video encoder 20 for each video block in the video frame to determine a degree of quantization. Inverse transform processing unit 88 applies an inverse transform, e.g., an inverse DCT, an inverse integer transform, or a conceptually similar inverse transform process, to the transform coefficients in order to reconstruct the residual blocks in the pixel domain.

[0071] After motion compensation unit 82 or intra BC unit 85 generates the prediction block for the current video block based on the vectors and other syntax elements, adder 90 reconstructs the decoded video block for the current video block by adding the residual block from inverse transform processing unit 88 to the corresponding prediction block generated by motion compensation unit 82 and intra BC unit 85. In-loop filter 91, e.g., a de-blocking filter, a SAO filter, a CCSAO filter, and / or an ALF, can be located between adder 90 and DPB 92 to further process the decoded video block. In some examples, in-loop filter 91 can be omitted, and the decoded video block can be directly provided by adder 90 to DPB 92. The decoded video block in a given frame is then stored in DPB 92, which stores reference frames for subsequent motion compensation of video blocks that follow. DPB 92 or a memory device separate from DPB 92 can also store decoded video for later presentation on a display device (e.g., display device 34 of FIG. 1). Figure 1

[0072] Figure 4 is a flowchart illustrating an exemplary video encoding method according to some embodiments of the present disclosure. The video encoding method can be implemented in the video encoder 20 introduced above.

[0073] Referring to Figure 4 In step S410, the encoding information of the current video frame after mode decision is obtained.

[0074] Specifically, the current video frame is divided into a plurality of coding tree units (CTUs), each of which includes a plurality of coding units (CUs), and the encoding information includes information of preset encoding variables of each coding unit.

[0075] In step S420, for each coding tree unit, a process is respectively performed to encode the current coding tree unit.

[0076] This step is the focus of the present disclosure. Figure 5 A specific process flow is shown, including steps S421 to S423.

[0077] Referring to Figure 5 ​In step S421, the preset coding variable information of each coding unit in the current coding tree unit is statistically processed to obtain a coding information statistical value.

[0078] In step S422, a quantization parameter increment is determined according to the coding information statistical value and a mapping relationship function. The mapping relationship function is used to specify the mapping relationship between the coding information statistical value and the quantization parameter increment.

[0079] In step S423, the current coding tree unit is encoded based on the determined quantization parameter increment.

[0080] By statistically processing the preset coding variable (such as a prediction mode) information of each coding unit to obtain a coding information statistical value for each coding tree unit, the coding characteristics of the current coding tree unit can be quantitatively reflected. On this basis, the mapping relationship function between the coding information statistical value and the quantization parameter increment (ΔQP) is used to determine the quantization parameter increment according to the actual statistical coding information statistical value, so that a specific quantization parameter increment can be obtained with a target, and then the encoding is performed. At this time, the quantization parameter QP needs to be updated only once, and there is no need to update the quantization parameter QP repeatedly and repeatedly perform trial operations, thereby effectively simplifying the calculation process, reducing the calculation amount, shortening the calculation time, and optimizing the encoding efficiency.

[0081] Next, step S420 is further described.

[0082] In some embodiments, the preset coding variable includes at least one coding variable, and step S421 includes: respectively performing corresponding statistical processing on the information of each coding variable of each coding unit in the current coding tree unit to obtain at least one coding information statistical value.

[0083] In these embodiments, by performing appropriate statistical processing according to the types of preset coding variables, the coding information statistical value obtained can better reflect the coding characteristics of the coding tree unit. It should be understood that at this time, the mapping relationship function is specifically used to specify the mapping relationship between the at least one coding information statistical value and the quantization parameter increment.

[0084] In some embodiments, the preset coding variable specifically includes a prediction mode, and accordingly, the information of the preset coding variable includes a prediction mode adopted by the coding unit, such as an intra prediction mode of DC (Direct Current), Planar, Directional, and the like, or an inter prediction mode of Merge, skip, AMVP (Adaptive Motion Vector Prediction), and the like. In the above, the information of each coding variable of each coding unit in the current coding tree unit is respectively subjected to corresponding statistical processing to obtain at least one coding information statistical value, including: a proportion of coding units of the intra prediction mode in the current coding tree unit and a proportion of coding units of the skip prediction mode in the current coding tree unit, to obtain the intra proportion and the intra proportion as two coding information statistical values, wherein the proportions are area proportions or number proportions.

[0085] In these embodiments, the two coding information statistical values are obtained by performing statistical processing on the two prediction modes of the intra prediction mode and the skip prediction mode. The intra prediction mode is mainly used when no reference or a suitable reference in the time domain is found, in which case the residual is generally large, thus representing an extreme case. The skip prediction mode does not need to code the residual, is generally accurate, and the residual information does not need to be transmitted, thus representing another extreme case. Other prediction modes are between the two extremes. Different coding information of different prediction modes results in different relationships between the code rate and the distortion. By selecting the two prediction modes representing the two extreme cases and performing statistical processing thereon to obtain the coding information statistical values, the coding characteristics of the current coding tree unit can be effectively reflected with as little data as possible, which helps to sufficiently reduce the computational complexity and improve the coding efficiency.

[0086] It should be understood that the intra prediction mode includes a plurality of specific prediction modes, and thus a plurality of specific intra prediction modes (such as the DC mode, the Planar mode, and the Directional mode) are actually counted as the intra prediction mode, and the skip prediction mode is a specific inter prediction mode, and thus only the skip prediction mode needs to be counted without counting other inter prediction modes.

[0087] It should be noted that the IBC (Inter Block Copy) mode and the Palette mode also belong to the intra prediction mode, but they belong to the screen content coding mode and have different characteristics from other intra prediction modes, and thus the IBC mode and the Palette mode are not counted as the intra prediction mode in the statistical processing.

[0088] In particular, there is a special prediction mode, CIIP (Coding Unit Intra Prediction) mode. The prediction mode is a joint mode of Merge and Planar, and in general, the region residual is also large, so it can be counted as an intra prediction mode.

[0089] As to the specific counting method, since each coding unit has a specific prediction mode, the selected intra prediction mode and the skip prediction mode can be quantified by counting the area ratio or the number ratio of each prediction mode in the current coding tree unit. The area ratio is the ratio of the total area of the coding units using the corresponding prediction mode in the total area of the current coding tree unit, and the number ratio is the ratio of the number of the coding units using the corresponding prediction mode in the total number of the coding units in the current coding tree unit.

[0090] In some embodiments, step S422 comprises: weighting and summing the at least one coding information statistic value to determine the quantization parameter increment.

[0091] In these embodiments, after obtaining the at least one coding information statistic value, the different coding information statistic values can be integrated into one whole by weighting and summing, to obtain the quantization parameter increment, and to realize convenient calculation of the quantization parameter increment. In other words, the mapping relationship function represents a function of weighting and summing the at least one coding information statistic value. It should be understood that since different types of coding variables often use different statistical processing, the obtained coding information statistic values may have different units and orders of magnitude. Therefore, when weighting and summing, the weight corresponding to each coding information statistic value can be adjusted to adjust the order of magnitude, so that the weighted sum is exactly equal to the quantization parameter increment. This means that the sum of the weights corresponding to different coding information statistic values is not equal to 1, and may even have different orders of magnitude.

[0092] In some embodiments, the weight used for weighting and summing the at least one coding information statistic value is obtained by offline fitting with the optimization of the subjective coding quality index as the target, and the subjective coding quality index includes at least one of the following: video multi-method assessment fusion score, mean opinion score, visual quality score, structural similarity index.

[0093] In these embodiments, considering that existing schemes for trial operation of multiple different QPs tend to mainly focus on optimization of objective quality, insufficient consideration of subjective quality improvement can lead to poor coding effect in some cases. By targeting subjective coding quality indicators to obtain the weights of various coding information statistics, the subjective quality of the encoded video data obtained by the embodiments of the present disclosure can be effectively improved, and the coding effect can be optimized. It should be understood that the above-mentioned several subjective coding quality indicators can be used alone, or at least two of them can be used in combination, and in addition to these several subjective coding quality indicators, other reasonable subjective coding quality indicators can also be used, and the present disclosure does not limit this.

[0094] Specifically, during offline fitting, a control variable method can be used to obtain suitable quantization parameter increments under different coding information statistics, and the standard for evaluating suitable quantization parameter increments is that the selected subjective coding quality indicators have relatively optimal values, thereby obtaining a large amount of associated data, each set of associated data including a specific coding information statistic and a corresponding quantization parameter increment, and then using the weights of each coding information statistic as the fitting target, the associated data is fitted and processed, thereby obtaining the weights and the mapping relationship function.

[0095] As an example, in other embodiments, a network model can also be used as the mapping relationship function, in which case the network model needs to be trained offline. During training, a large amount of associated data can be obtained by the above-mentioned method, and then these associated data are used as training samples for training the network model, or the selected subjective coding quality indicators are maximized as the training target, and the present disclosure does not limit this.

[0096] In some embodiments, the preset coding variable includes at least one of: a prediction mode of a coding unit, a block size of the coding unit, a transform mode of the coding unit, a prediction mode of a neighboring coding unit of the coding unit, a block size of the neighboring coding unit of the coding unit, a transform mode of the neighboring coding unit of the coding unit; wherein the statistical processing related to the prediction mode includes statistics of a proportion of at least one prediction mode in the current coding tree unit, the at least one prediction mode including at least one of: an intra prediction mode, a skip prediction mode, and the statistics of the proportion being an area proportion or a number proportion; the statistical processing related to the block size includes statistics of an average value of the block size; and the statistical processing related to the transform mode includes statistics of a proportion of at least one transform mode in the current coding tree unit, and the statistics of the proportion being an area proportion or a number proportion.

[0097] In the embodiments, the preset coding variables can be selected from a plurality of coding variables, so as to fully describe the coding characteristics of the coding tree units. Specifically, the preset coding variables can be the coding variables of the coding units themselves, so as to directly describe the coding units in the current coding tree unit; or the preset coding variables can be the coding variables of the neighboring coding units of the coding units, so as to broaden the information range of the description. As an example, only the coding variables of the coding units themselves can be used, or the coding variables of the coding units and their neighboring coding units can be used, or only the coding variables of the neighboring coding units of the coding units can be used, and the present disclosure does not limit this. In addition to the coding units, the coding variables can be at least one of a prediction mode, a block size, and a change mode, so as to provide rich information. The prediction mode can refer to the description in the foregoing embodiments, and a few representative prediction modes can be selected and their proportions can be counted, or the proportions of all prediction modes can be counted, and the present disclosure does not limit this. In particular, for the neighboring coding units of the coding units, since each coding unit usually has two neighboring coding units, when counting the proportions, the area proportion can be the proportion of the sum of the areas of all the neighboring coding units using the corresponding prediction mode in the sum of the areas of all the neighboring coding units of all the coding units in the current coding tree unit, and the number proportion can be the proportion of the sum of the numbers of all the neighboring coding units using the corresponding prediction mode in the number of all the neighboring coding units of all the coding units in the current coding tree unit. The change mode can refer to the prediction mode, a few representative change modes can be selected and their proportions can be counted, or the proportions of all change modes can be counted. The block size is specifically the size of the coding unit, which can be represented by the depth of the coding unit obtained when the coding unit is divided, and since the block size itself is a quantization value, the counting can be achieved by calculating the average of the block sizes of the coding units, and other counting methods can also be used, and the present disclosure does not limit this. It should be understood that when the preset coding variables used or the coding information counting values are changed, the mapping relationship function needs to be re-determined accordingly.

[0098] In some embodiments, the processing performed in step S420 for each coding tree unit further includes: for the quantization parameter increment determined according to the coding information counting value and the mapping relationship function, performing clipping processing using a clipping function to obtain a clipped quantization parameter increment as the finally determined quantization parameter increment, wherein the clipping function is used to limit the quantization parameter increment within a preset value range.

[0099] In these embodiments, considering that the quantization parameter increment calculated based on the mapping relationship function is only a theoretical value conforming to the mapping relationship, and cannot guarantee absolute suitability for coding accordingly, by further increasing the clipping function, the finally determined quantization parameter increment can be limited within a reasonable fluctuation range, thereby reducing the picture quality reduction caused by unreasonable quantization parameter increment, and effectively guaranteeing the coding effect. As an example, the value range can be determined based on the target of limiting the occurrence of bad cases, in combination with theoretical analysis and experience, and the specific numerical value of the value range is not limited in the present disclosure.

[0100] Specifically, for the quantization parameter increment determined according to the coding information statistical value and the mapping relationship function (hereinafter referred to as the candidate quantization parameter increment), the clipping function is used for clipping processing in the following manner: in the case where the candidate quantization parameter increment is less than or equal to the lower limit value of the preset value range, the lower limit value of the preset value range is taken as the finally determined quantization parameter increment; in the case where the candidate quantization parameter increment is within the preset value range, the candidate quantization parameter increment is taken as the finally determined quantization parameter increment; in the case where the candidate quantization parameter increment is greater than or equal to the upper limit value of the preset value range, the upper limit value of the preset value range is taken as the finally determined quantization parameter increment.

[0101] It should be understood that, for the convenience of description, the mapping relationship function and the clipping function are described separately in the present disclosure, but in actual execution, the two can be combined into one function, for example, for the above embodiment of counting the proportions of the intra prediction mode and the skip prediction mode, the combined function can be expressed by the following formula:

[0102] ΔQP = clip(w intra × ratio intra +w skip × ratio skip ,QP min ,QP max ).

[0103] wherein clip represents the clipping function, ratio intra and ratio skip represent the proportions of the inter prediction mode and the skip prediction mode in the current coding tree unit respectively, w intra and w skip represent the weights of the proportions of the inter prediction mode and the skip prediction mode respectively, QP min represents the lower limit value of the preset value range, and QP max represents the upper limit value of the preset value range.

[0104] In some embodiments, step S423 comprises: in a case where the quantization parameter increment is less than 0, adjusting the quantization parameter of the current coding tree unit according to the quantization parameter increment; in a case where the quantization parameter increment is greater than or equal to 0, keeping the quantization parameter of the current coding tree unit unchanged.

[0105] In these embodiments, the smaller the quantization parameter, the smaller the code rate and the better the image quality. If the quantization parameter increment is less than 0, it indicates that the current coding tree unit needs to further reduce the code rate and improve the image quality. By adjusting the quantization parameter of the current coding tree unit according to the final determined quantization parameter increment in a case where the quantization parameter increment is less than 0, and re-encoding, the image quality can be effectively improved. In a case where the final determined quantization parameter increment is greater than or equal to 0, it indicates that no additional image quality repair work is needed at this time. By not adjusting the quantization parameter, the image quality can be guaranteed, and no additional encoding operation is needed, which can directly enter the subsequent encoder work, and can effectively improve the encoding efficiency.

[0106] In summary, in one specific embodiment, the present disclosure can introduce a preset encoding variable (prediction mode) based on subjective quality improvement into the mapping relationship estimation (i.e. mapping relationship function and clipping function) of the quantization parameter increment in combination with the mode decision and the trial operation of multiple different QPs, to provide a more accurate mode selection strategy, optimize the encoding efficiency, and improve the subjective quality. Through the video encoding method of this specific embodiment, the range of the quantization parameter of the coding tree unit level can be wider, and in the ROI (Region of Interest) with more detailed textures such as human faces, because the intra prediction mode occupies a larger proportion, the change range of the quantization parameter increment is larger, the code rate allocation is more, and the image is clearer, thereby improving the subjective quality of the video encoding, and the visual effect in complex scenes is obviously improved. With the support of experimental data, the quantitative results of the improvement of the subjective quality are shown.

[0107] Figure 6 is a block diagram illustrating a video encoding apparatus according to an example embodiment of the present disclosure.

[0108] Referring to Figure 6 , the video encoding apparatus 600 comprises an acquisition unit 601 and a processing unit 602.

[0109] The acquisition unit 601 can acquire the encoding information of the current video frame after the mode decision, wherein the current video frame is divided into a plurality of coding tree units, each coding tree unit comprises a plurality of coding units, and the encoding information comprises the information of the preset encoding variable of each coding unit.

[0110] The processing unit 602 can perform the following processing for each coding tree unit: performing statistical processing on information of preset coding variables of each coding unit in the current coding tree unit to obtain a coding information statistical value; determining a quantization parameter increment according to the coding information statistical value and a mapping relationship function, wherein the mapping relationship function is used to specify a mapping relationship between the coding information statistical value and the quantization parameter increment; and encoding the current coding tree unit based on the determined quantization parameter increment.

[0111] Optionally, the preset coding variables include at least one coding variable, and the processing unit 602 can further perform corresponding statistical processing on information of each coding variable of each coding unit in the current coding tree unit to obtain at least one coding information statistical value.

[0112] Optionally, the preset coding variables include a prediction mode, and the processing unit 602 can further statistically process proportions of coding units of an intra prediction mode and a skip prediction mode in the current coding tree unit to obtain an intra proportion and an intra proportion as two coding information statistical values, wherein the proportions are area proportions or number proportions.

[0113] Optionally, the processing unit 602 can further perform weighted summation on the at least one coding information statistical value to determine the quantization parameter increment.

[0114] Optionally, the weights used for the weighted summation of the at least one coding information statistical value are obtained through offline fitting with an optimization of a subjective coding quality index, and the subjective coding quality index includes at least one of the following: a video multi-method assessment fusion score, a mean opinion score, a visual quality score, and a structural similarity index.

[0115] Optionally, the preset coding variables include at least one of the following: a prediction mode of a coding unit, a block size of a coding unit, a transform mode of a coding unit, a prediction mode of a neighboring coding unit of a coding unit, a block size of a neighboring coding unit of a coding unit, and a transform mode of a neighboring coding unit of a coding unit; wherein the statistical processing related to the prediction mode includes statistical processing of proportions of at least one prediction mode in the current coding tree unit, the at least one prediction mode includes at least one of the following: an intra prediction mode and a skip prediction mode, and the proportions are area proportions or number proportions; the statistical processing related to the block size includes statistical processing of an average value of the block size; and the statistical processing related to the transform mode includes statistical processing of proportions of at least one transform mode in the current coding tree unit, and the proportions are area proportions or number proportions.

[0116] Optionally, the processing unit 602 can further clip the quantization parameter increment determined according to the coding information statistic value and the mapping relationship function using a clipping function to obtain a clipped quantization parameter increment as the finally determined quantization parameter increment, wherein the clipping function is used to limit the quantization parameter increment in a preset value range.

[0117] Optionally, the processing unit 602 can further: in a case where the quantization parameter increment is less than 0, adjust the quantization parameter of the current coding tree unit according to the quantization parameter increment; and in a case where the quantization parameter increment is greater than or equal to 0, maintain the quantization parameter of the current coding tree unit.

[0118] As to the apparatus in the above-described embodiments, the specific manners in which various units perform operations have been described in detail in the embodiments of the method, and thus will not be described in detail here.

[0119] Figure 7 A computing environment 710 coupled with a user interface 750 is shown. The computing environment 710 can be part of a data processing server. The computing environment 710 includes a processor 720, a memory 730, and an input / output (I / O) interface 740.

[0120] The processor 720 generally controls the overall operation of the computing environment 710, such as operations associated with displaying, data acquisition, data communication, and image processing. The processor 720 can include one or more processors for executing instructions to perform all or some of the steps in the above-described methods. In addition, the processor 720 can include one or more modules that facilitate interaction with other components of the computing environment 710. The processor can be a central processing unit (CPU), a microprocessor, a microcontroller, a graphics processing unit (GPU), etc.

[0121] The memory 730 is configured to store various types of data to support the operation of the computing environment 710. The memory 730 can include predetermined software 732. Examples of such data include instructions for any application or method operating on the computing environment 710, video data sets, image data, etc. The memory 730 can be implemented by using any type of volatile or non-volatile memory device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk, or optical disk.

[0122] The I / O interface 740 provides an interface between the processor 720 and peripheral interface modules (e.g., a keyboard, a click wheel, buttons, etc.). The buttons can include, but are not limited to, a home button, a start scanning button, and a stop scanning button. The I / O interface 740 can be coupled with an encoder and a decoder.

[0123] In embodiments, there is also provided a non-transitory computer readable storage medium comprising a plurality of programs, e.g., in the memory 730, executable by the processor 720 in the computing environment 710 for performing the above-described methods, and / or storing a bitstream generated by the above-described encoding method or a bitstream to be decoded by the above-described decoding method. In one example, the plurality of programs can be executable by the processor 720 in the computing environment 710 for receiving (e.g., from a video encoder 20 in a video encoder 20) a bitstream or data stream comprising encoded video information (e.g., video blocks representative of encoded video frames, and / or associated one or more syntax elements, etc.), and also executable by the processor 720 in the computing environment 710 for performing the above-described decoding methods in accordance with the received bitstream or data stream. In another example, the plurality of programs can be executable by the processor 720 in the computing environment 710 for performing the above-described encoding methods to encode video information (e.g., video blocks representative of video frames, and / or associated one or more syntax elements, etc.) into a bitstream or data stream, and also executable by the processor 720 in the computing environment 710 for transmitting (e.g., to a video decoder 30) the bitstream or data stream. Figure 2 In another example, the plurality of programs can be executable by the processor 720 in the computing environment 710 for performing the above-described encoding methods to encode video information (e.g., video blocks representative of video frames, and / or associated one or more syntax elements, etc.) into a bitstream or data stream, and also executable by the processor 720 in the computing environment 710 for transmitting (e.g., to a video decoder 30) the bitstream or data stream. Figure 3 In another example, the plurality of programs can be executable by the processor 720 in the computing environment 710 for performing the above-described encoding methods to encode video information (e.g., video blocks representative of video frames, and / or associated one or more syntax elements, etc.) into a bitstream or data stream, and also executable by the processor 720 in the computing environment 710 for transmitting (e.g., to a video decoder 30) the bitstream or data stream. Figure 2 In another example, the plurality of programs can be executable by the processor 720 in the computing environment 710 for performing the above-described encoding methods to encode video information (e.g., video blocks representative of video frames, and / or associated one or more syntax elements, etc.) into a bitstream or data stream, and also executable by the processor 720 in the computing environment 710 for transmitting (e.g., to a video decoder 30) the bitstream or data stream. Figure 3 In another example, the plurality of programs can be executable by the processor 720 in the computing environment 710 for performing the above-described encoding methods to encode video information (e.g., video blocks representative of video frames, and / or associated one or more syntax elements, etc.) into a bitstream or data stream, and also executable by the processor 720 in the computing environment 710 for transmitting (e.g., to a video decoder 30) the bitstream or data stream.

[0124] In embodiments, there is provided a bitstream generated by the above-described encoding method or to be decoded by the above-described decoding method. In embodiments, there is provided a bitstream comprising encoded video information generated by the above-described encoding method or to be decoded by the above-described decoding method.

[0125] In an embodiment, there is also provided a computing device comprising: one or more processors (e.g., the processor 720); and a non-transitory computer-readable storage medium or memory 730 having stored therein a plurality of programs that can be executed by the one or more processors, wherein the one or more processors, when executing the plurality of programs, are configured to perform the above-described method.

[0126] In an embodiment, there is also provided a computer program product having instructions for storing or transmitting a bitstream comprising encoded video information generated by the above-described encoding method or to be decoded by the above-described decoding method. In an embodiment, there is also provided a computer program product comprising a plurality of programs, e.g., in the memory 730, that can be executed by the processor 720 in the computing environment 710 for performing the above-described method. For example, the computer program product can comprise a non-transitory computer-readable storage medium.

[0127] In an embodiment, the computing environment 710 can be implemented by one or more ASICs, DSPs, digital signal processing devices (DSPDs), programmable logic devices (PLDs), FPGAs, GPUs, controllers, microcontrollers, microprocessors, or other electronic components, for performing the above-described method.

[0128] In an embodiment, there is also provided a method of storing a bitstream comprising storing the bitstream on a digital storage medium, wherein the bitstream comprises encoded video information generated by the above-described encoding method or to be decoded by the above-described decoding method.

[0129] In an embodiment, there is also provided a method for transmitting a bitstream generated by the above-described encoder. In an embodiment, there is also provided a method for receiving a bitstream to be decoded by the above-described decoder.

[0130] The description of the present disclosure has been presented for purposes of illustration and is not intended to be exhaustive or limited to the disclosure made. Many modifications, variations, and alternative implementations will be apparent to those of ordinary skill in the art based on the teachings from the description and associated drawings.

[0131] Unless otherwise specified, the order of steps of the method according to the present disclosure is merely intended to be illustrative, and the steps of the method according to the present disclosure are not limited to the above-described specific order, but can be changed according to the actual situation. In addition, at least one of the steps of the method according to the present disclosure can be adjusted, combined, or deleted according to the actual needs.

[0132] The examples are chosen and described in order to explain the principles of the disclosure and to enable others skilled in the art to best utilize the various implementations of the disclosure and various implementations with various modifications as are suited to the particular use contemplated. Therefore, specific details of the examples are not intended for limiting purposes only and are contemplated to be in accord with the principles of the disclosure as defined in the following claims.

Claims

1. A method of video coding, the method comprising: The video encoding method comprises: obtaining encoding information of a current video frame after mode decision, wherein the current video frame is divided into a plurality of coding tree units, each coding tree unit comprises a plurality of coding units, and the encoding information comprises information of preset encoding variables of each coding unit; for each coding tree unit, the following processing is performed: statistically processing the information of the preset encoding variables of each coding unit in the current coding tree unit to obtain an encoding information statistical value; determining a quantization parameter increment according to the encoding information statistical value and a mapping relationship function, wherein the mapping relationship function is used to specify the mapping relationship between the encoding information statistical value and the quantization parameter increment; encoding the current coding tree unit based on the determined quantization parameter increment.

2. The video coding method of claim 1, wherein, The preset encoding variables comprise at least one encoding variable, wherein the statistical processing of the information of the preset encoding variables of each coding unit in the current coding tree unit to obtain an encoding information statistical value comprises: respectively performing corresponding statistical processing on the information of each encoding variable of each coding unit in the current coding tree unit to obtain at least one encoding information statistical value.

3. The video coding method of claim 2, wherein, The preset encoding variables comprise a prediction mode, wherein the statistical processing of the information of each encoding variable of each coding unit in the current coding tree unit to obtain at least one encoding information statistical value comprises: statistically processing the proportion of the coding units of the intra prediction mode in the current coding tree unit and the proportion of the coding units of the skip prediction mode in the current coding tree unit to obtain the proportion of the intra prediction mode and the proportion of the intra prediction mode as two encoding information statistical values, wherein the proportion is an area proportion or a number proportion.

4. The video coding method of claim 2, wherein, The determination of the quantization parameter increment according to the encoding information statistical value and the mapping relationship function comprises: performing weighted summation on the at least one encoding information statistical value to determine the quantization parameter increment.

5. The video encoding method of claim 3, wherein: the weight used in the weighted summation of the at least one encoding information statistical value is obtained through offline fitting with the optimization of a subjective encoding quality index as the target, and the subjective encoding quality index comprises at least one of the following: video method assessment fusion score, mean opinion score, visual quality score, and structural similarity index.

6. The video encoding method of claim 1, wherein: the preset encoding variables comprise at least one of the following: prediction mode of a coding unit, block size of a coding unit, transform mode of a coding unit, prediction mode of a neighboring coding unit of a coding unit, block size of a neighboring coding unit of a coding unit, and transform mode of a neighboring coding unit of a coding unit; the statistical processing related to the prediction mode comprises statistical processing of the proportion of at least one prediction mode in the current coding tree unit, and the at least one prediction mode comprises at least one of the following: intra prediction mode and skip prediction mode, and the proportion is an area proportion or a number proportion; the statistical processing related to the block size comprises statistical processing of the average value of the block size; The statistical processing related to the transform mode comprises counting a proportion of the at least one transform mode in the current coding tree unit, and the counted proportion is an area proportion or a number proportion.

7. The video coding method of any of claims 1 to 6, wherein, The processing performed for each coding tree unit further comprises: For the quantization parameter increment determined according to the coding information statistical value and the mapping relationship function, a clipping function is used for clipping processing to obtain a clipped quantization parameter increment as a finally determined quantization parameter increment, wherein the clipping function is used for limiting the quantization parameter increment in a preset value range.

8. The video coding method of any of claims 1 to 6, wherein, The encoding of the current coding tree unit based on the determined quantization parameter increment comprises: In the case that the quantization parameter increment is less than 0, the quantization parameter of the current coding tree unit is adjusted according to the quantization parameter increment; In the case that the quantization parameter increment is greater than or equal to 0, the quantization parameter of the current coding tree unit is maintained.

9. A video encoding apparatus, comprising: The video encoding apparatus comprises: An obtaining unit configured to obtain coding information of a current video frame after mode decision, wherein the current video frame is divided into a plurality of coding tree units, each coding tree unit comprises a plurality of coding units, and the coding information comprises information of a preset coding variable of each coding unit; A processing unit configured to perform the following processing for each coding tree unit: statistical processing on the information of the preset coding variable of each coding unit in the current coding tree unit to obtain a coding information statistical value; determination of a quantization parameter increment according to the coding information statistical value and a mapping relationship function, wherein the mapping relationship function is used for specifying a mapping relationship between the coding information statistical value and the quantization parameter increment; and encoding of the current coding tree unit based on the determined quantization parameter increment.

10. An electronic device, comprising: comprise: at least one processor; at least one memory storing computer executable instructions, wherein the computer executable instructions, when executed by the at least one processor, cause the at least one processor to perform the video encoding method according to any one of claims 1 to 8.

11. A computer readable storage medium, characterized in that, The computer readable storage medium comprises computer instructions which, when executed by the at least one processor, cause the at least one processor to perform the video encoding method according to any one of claims 1 to 8.

12. A computer program product comprising computer instructions, characterized in that, The computer instructions, when executed by the at least one processor, implement the video encoding method according to any one of claims 1 to 8.

13. A computer program product having instructions for storing a bitstream, characterized in that, The bitstream comprises: video data generated according to the video encoding method according to any one of claims 1 to 8.

14. A method of generating a bitstream, the method comprising: comprise: generating a bitstream according to the video encoding method according to any one of claims 1 to 8.

Citation Information

Patent Citations

  • Prediction method and device using reference block

    CN110463201A

  • AVC coding method and device

    CN116567246A