Encoding acceleration method and system based on precoding information splitting

By splitting the precoding information of the HEVC video encoder to generate encoding cost information for small-sized coding blocks, the problem of high computational complexity of the HEVC video encoder on small-sized coding blocks is solved, thereby improving encoding efficiency and accelerating the process.

CN116996679BActive Publication Date: 2026-02-06PENINSULA INFORMATION TECH INC
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310721353.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-06-16
Publication Date
2026-02-06
Estimated Expiration
2043-06-16

AI Technical Summary

Technical Problem

Existing HEVC video encoders cannot accelerate encoding by using pre-encoding information when processing small-sized code blocks, resulting in high encoding computation complexity and hindering their practical application in mobile devices with low power consumption and computing power.

Method used

By splitting the coding cost information of larger coding blocks, coding cost information of smaller coding blocks is generated, which is used to assist in the coding mode decision of smaller coding blocks, including intra-frame and inter-frame coding analysis.

Benefits of technology

While ensuring encoding quality, it improves encoding efficiency, achieves accelerated encoding of small-sized encoding blocks, reduces the computation process, and is suitable for mobile devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116996679B_ABST
    Figure CN116996679B_ABST
Patent Text Reader

Abstract

The embodiment of the present application discloses a coding acceleration method and system based on pre-coding information splitting. The technical scheme provided by the embodiment of the present application obtains first coding cost information of a first fixed-size coding block obtained by pre-coding a current frame, splits the first coding cost information to obtain second coding cost information of a corresponding number of second fixed-size coding blocks, determines a frame type of the current frame, selects corresponding second coding cost information for coding analysis based on the frame type and a block size of a current coding block, and codes the current coding block according to a coding analysis result, wherein the coding analysis includes intra-frame coding analysis and / or inter-frame coding analysis. By using the above technical means, the coding analysis of small-size coding blocks is performed by using the split coding cost information to assist in coding mode decision of the corresponding coding blocks, the coding efficiency is improved while the coding quality is ensured, and the coding acceleration effect of small-size coding blocks is realized.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] Embodiments of the present application relate to the technical field of video coding, in particular to a coding acceleration method and system based on pre-encoding information splitting. BACKGROUND

[0002] At present, in order to reduce the operation complexity of the encoder, the HEVC video encoder will perform pre-encoding before formal encoding to provide pre-encoding information for the coding frame type decision and other operations of the formal encoding, thereby improving the coding efficiency. In the pre-encoding process, the source resolution video is down-sampled by 1 / 2 to obtain a low-resolution video, and the intra-frame and inter-frame coding costs of each 8x8 size coding block on the low-resolution video are calculated to assist the mode decision and other processes in the formal encoding process, thereby achieving the effect of reducing the operation complexity of the encoder.

[0003] However, since the 8x8 coding blocks processed in the pre-encoding process are mapped to the 16x16 coding blocks of the actual source resolution in the actual encoding process, when the intra-frame and inter-frame coding costs of the pre-encoding 8x8 coding blocks are used to accelerate the formal encoding process, it is only applicable to the mode decision process of the coding blocks with a size of 16x16 or more. For the coding blocks with a smaller size (such as 8x8 size coding blocks) that may be divided in the formal encoding process, the pre-encoding information cannot be used for coding acceleration, and the coding operation complexity is still relatively high. SUMMARY

[0004] Embodiments of the present application provide a coding acceleration method and system based on pre-encoding information splitting, which can accelerate the coding of smaller size coding blocks, improve the video coding efficiency, and solve the technical problem that smaller size coding blocks cannot use pre-encoding information for coding acceleration.

[0005] In a first aspect, embodiments of the present application provide a coding acceleration method based on pre-encoding information splitting, comprising:

[0006] obtaining first coding cost information of a first fixed size coding block obtained by pre-encoding a current frame, splitting the first coding cost information to obtain second coding cost information of a corresponding number of second fixed size coding blocks;

[0007] determining the frame type of the current frame, selecting the corresponding second coding cost information for coding analysis based on the frame type and the block size of the current coding block, and performing coding of the current coding block according to the coding analysis result, wherein the coding analysis includes intra-frame coding analysis and / or inter-frame coding analysis.

[0008] In a second aspect, embodiments of the present application provide a coding acceleration system based on pre-encoding information splitting, comprising:

[0009] The splitting module is configured to obtain first encoding cost information of a first fixed-size coding block obtained by pre-encoding a current frame, and split the first encoding cost information to obtain second encoding cost information of a corresponding number of second fixed-size coding blocks;

[0010] The analysis module is configured to determine a frame type of the current frame, select corresponding second encoding cost information for encoding analysis based on the frame type and a block size of the current coding block, and perform encoding of the current coding block according to an encoding analysis result, wherein the encoding analysis includes intra-frame encoding analysis and / or inter-frame encoding analysis.

[0011] In a third aspect, an encoding acceleration device based on pre-encoding information splitting is provided, including:

[0012] a memory and one or more processors;

[0013] The memory is configured to store one or more programs.

[0014] When the one or more programs are executed by the one or more processors, the one or more processors implement the encoding acceleration method based on pre-encoding information splitting as described in the first aspect.

[0015] In a fourth aspect, a computer readable storage medium is provided, which stores computer executable instructions, and the computer executable instructions, when executed by a computer processor, are configured to perform the encoding acceleration method based on pre-encoding information splitting as described in the first aspect.

[0016] In a fifth aspect, a computer program product is provided, which contains instructions, and when the instructions are run on a computer or processor, the computer or processor performs the encoding acceleration method based on pre-encoding information splitting as described in the first aspect.

[0017] The embodiments of the present application obtain first encoding cost information of a first fixed-size coding block obtained by pre-encoding a current frame, split the first encoding cost information to obtain second encoding cost information of a corresponding number of second fixed-size coding blocks, determine a frame type of the current frame, select corresponding second encoding cost information for encoding analysis based on the frame type and a block size of the current coding block, and perform encoding of the current coding block according to an encoding analysis result, wherein the encoding analysis includes intra-frame encoding analysis and / or inter-frame encoding analysis. By splitting the encoding cost information of a large-size coding block and using the split encoding cost information for encoding analysis of a small-size coding block to assist in coding mode decision of the corresponding coding block, the above technical means saves the operation process, improves the encoding efficiency while ensuring the encoding quality, and achieves the encoding acceleration effect of small-size coding blocks. BRIEF DESCRIPTION OF DRAWINGS

[0018] Figure 1 is a flowchart of an encoding acceleration method based on pre-encoding information splitting provided by an embodiment of the present application;

[0019] Figure 2 is a video encoding flowchart in an embodiment of the present application;

[0020] Figure 3 is a data storage structure schematic diagram in an embodiment of the present application;

[0021] Figure 4 is an intra-frame encoding acceleration flowchart in an embodiment of the present application;

[0022] Figure 5 is a certificate encoding acceleration flowchart in an embodiment of the present application;

[0023] Figure 6 is a structure schematic diagram of an encoding acceleration system based on pre-encoding information splitting provided by an embodiment of the present application;

[0024] Figure 7 is a structure schematic diagram of an encoding acceleration device based on pre-encoding information splitting provided by an embodiment of the present application. DETAILED DESCRIPTION

[0025] In order to make the objects, technical solutions and advantages of the present application clearer, the following further describes specific embodiments of the present application in conjunction with the drawings. It can be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application. In addition, it should be noted that, for the convenience of description, only parts related to the present application are shown in the drawings, but not all contents. Before discussing the example embodiments in more detail, it should be mentioned that some example embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts describe each operation (or step) as a sequential process, many of the operations can be implemented in parallel, concurrently or simultaneously. In addition, the order of the operations can be rearranged. The process can be terminated when its operations are completed, but can also have additional steps not included in the drawings. The process can correspond to a method, function, procedure, subroutine, subprogram, etc.

[0026] The encoding acceleration method based on pre-encoding information splitting provided by the present application aims to split the encoding cost information of a larger size encoding block, use the split encoding cost information to perform encoding analysis of a smaller size encoding block, and assist in making encoding mode decision of the corresponding encoding block, so as to achieve encoding acceleration effect of the small size encoding block.

[0027] In a related video encoding scenario, taking the HEVC encoder as an example, HEVC increases more intra and inter encoding modes compared with previous video encoding standards, and meanwhile allows more sizes of encoding blocks, using the quad-tree partitioning technique to traverse the RDO process to obtain the optimal block size. The introduction of these encoding tools enables HEVC to obtain higher compression ratio than AVC, but the operation complexity undoubtedly limits the practical application of HEVC in mobile platforms which are limited in computing power and power consumption, so it is imperative to reduce the operation complexity of HEVC under the condition of controllable quality loss, and it is of great significance for mobile applications.

[0028] The HEVC encoder includes a pre-encoding module, which is used to obtain the spatial and temporal adaptive qp offset values and the intra and inter encoding costs for rate control, and by calculating the intra and inter encoding costs of the 8x8 encoding block, the mode decision or the encoding block partitioning in the formal encoding process is accelerated. However, the minimum encoding unit of the HEVC encoder is 8x8, and the block size on the 1 / 2 down-sampling pixel plane analyzed and processed by the pre-encoding module is also 8x8. However, the 8x8 encoding block analyzed and processed by the pre-encoding module should correspond to the 16x16 encoding block of the source resolution in the actual encoding process. Therefore, when using the intra and inter encoding costs of the 8x8 encoding block in the pre-encoding module to accelerate the formal encoding, it is only applicable to the mode decision or partitioning of the encoding block with a size of 16x16 or more. However, by counting the encoding block size in the HEVC encoding stream, it can be found that there are still a large number of 8x8 size encoding blocks. Especially for complex texture content, smaller size encoding blocks are more likely to appear in I and P frames, and this part of smaller size encoding blocks cannot be accelerated by using the pre-encoding information.

[0029] Therefore, the HEVC encoder significantly improves the encoding quality while greatly increasing the encoding complexity and reducing the encoding speed, which hinders its practical application in mobile terminals which are low in power consumption and computing power. For the optimal intra and inter encoding cost information of the 8x8 block calculated by the pre-encoding module in the encoder, in the mode decision and encoding block partitioning of the encoding block in the formal encoding process, only the encoding analysis acceleration of the encoding block with a size of 16x16 or more can be solved. For the 8x8 size encoding block, since the pre-encoding information at the corresponding position cannot be obtained, only the original logic of encoding analysis can be followed to traverse various modes to find the optimal mode, and the encoding operation complexity is still relatively high.

[0030] Based on this, an encoding acceleration method based on pre-encoding information splitting is provided to solve the technical problem that small size encoding blocks cannot be accelerated by using pre-encoding information.

[0031] Embodiment:

[0032] Figure 1A flowchart of the encoding acceleration method based on pre-encoding information splitting provided in the embodiment is given. The encoding acceleration method based on pre-encoding information splitting provided in the embodiment can be executed by an encoding acceleration device based on pre-encoding information splitting. The encoding acceleration device based on pre-encoding information splitting can be implemented in software and / or hardware. The encoding acceleration device based on pre-encoding information splitting can be composed of two or more physical entities, or one physical entity. Generally, the encoding acceleration device based on pre-encoding information splitting can be an encoder device, a computer, a mobile phone, a tablet, or other computing devices with video encoding function.

[0033] The following describes the encoding acceleration method based on pre-encoding information splitting with the encoding acceleration device based on pre-encoding information splitting as the main body for executing the encoding acceleration method based on pre-encoding information splitting. Referring to Figure 1 The encoding acceleration method based on pre-encoding information splitting specifically includes:

[0034] S110, obtaining first encoding cost information of a first fixed-size coding block obtained by pre-encoding a current frame, and splitting the first encoding cost information to obtain second encoding cost information of a corresponding number of second fixed-size coding blocks;

[0035] S120, determining a frame type of the current frame, selecting corresponding second encoding cost information for encoding analysis based on the frame type and a block size of a current coding block, and performing encoding of the current coding block according to an encoding analysis result. The encoding analysis includes intra-frame encoding analysis and / or inter-frame encoding analysis.

[0036] When the encoding acceleration is performed by pre-encoding information splitting, the pre-encoding information of each fixed-size coding block in the pre-encoding process of a video frame is obtained. The encoding information of the coding blocks divided according to the fixed size is split for subsequent formal encoding process. The split pre-encoding information is used for encoding analysis of small coding blocks of the video frame, and the encoding acceleration effect is achieved.

[0037] Taking the HEVC video encoder as an example, the pre-encoding module mainly performs optimal frame structure decision, spatial adaptive qp offset analysis, and temporal adaptive qp offset analysis. Secondly, the 8x8 block level optimal intra-frame encoding cost and optimal inter-frame encoding cost obtained in the pre-encoding process are also used in the rate control module to calculate the frame level and macro block row level qp. The pre-encoding process is based on 1 / 2 down-sampling of the original frame to obtain a 1 / 2 down-sampled frame corresponding to the original frame, and the above pre-encoding analysis process is performed using the 1 / 2 down-sampled frame. The 1 / 2 down-sampled frame is divided into 8x8 encoding blocks to analyze the block level characteristics, so for the encoding blocks with a size of 16x16 or more in the original frame, pre-encoding information corresponding to the position can be found, for example, the 16x16 encoding block in the original frame corresponds to the 8x8 encoding block in the 1 / 2 down-sampled frame one by one, and the 32x32 encoding block in the original frame corresponds to four 8x8 encoding blocks in the 1 / 2 down-sampled frame, but for the 8x8 size encoding block in the original frame, there is no corresponding 4x4 size pre-encoding information in the 1 / 2 down-sampled frame.

[0038] Therefore, the present application splits the pre-encoding information of the pre-encoded encoding block of the current frame, defines the pre-encoded encoding block as a first fixed size encoding block, and its pre-encoding information as first encoding cost information. The split encoding block is defined as a second fixed size encoding block, and its corresponding pre-encoding information is second encoding cost information. For example, the pre-encoding information of the 8x8 encoding block is split to make the pre-encoding analysis process generate pre-encoding information in units of 4x4 blocks. Thus, the decision basis is provided for the mode decision of the 8x8 size encoding block in the formal encoding process, so as to skip some unnecessary mode decisions, and at the same time, the judgment basis is provided for the division of the 16x16 size encoding block to speed up the encoding analysis process.

[0039] Exemplarily, referring to Figure 2 , a video encoding flowchart of the present application is provided. For a frame of video frame input into the encoder, it is first converted into a YUV video sequence. The YUV video sequence needs to be analyzed by pre-encoding to generate the intra-frame and inter-frame encoding cost of the 1 / 2 down-sampled 8x8 encoding block, i.e. the first encoding cost information. Before that, the pre-encoding information generated by the pre-encoding analysis is assigned a data storage structure by the lowres initialization module for storing the corresponding pre-encoding information. Since the present application needs to generate four 4x4 intra-frame and inter-frame encoding costs according to the 8x8 encoding block, in the lowres initialization module, additional space needs to be allocated to store all the 4x4 block intra-frame and inter-frame encoding costs.

[0040] Further, in the normal pre-encoding analysis process, first, the intra-frame and inter-frame cost is calculated by taking 8x8 blocks as the basic unit, the optimal intra-frame mode and the optimal inter-frame matching block are searched, the satd (Sum of Absolute Transform Differences) of the optimal intra-frame mode is calculated as the optimal intra-frame encoding cost, and the satd of the optimal inter-frame matching block is calculated as the optimal inter-frame encoding cost, so as to obtain the encoding cost information of an 8x8 block. In the optimal intra-frame mode selection process and the optimal inter-frame matching block search process of the pre-encoding, the 8x8 block is still taken as the basic unit, but when the satd is calculated, the 8x8 block needs to be split into four 4x4 blocks to calculate the satd respectively. The four 4x4 blocks share the same intra-frame mode and inter-frame motion vector, but the residual distribution can still reflect the spatial and temporal domain complexity of different regions in the 8x8 block, so the satd is calculated by taking the 4x4 block as the unit to represent the complexity of different regions. In this way, by splitting the pre-encoding information of the pre-encoding process, the second encoding cost information (the encoding cost information of the four 4x4 blocks) is obtained after splitting the first encoding cost information (the encoding cost information of the 8x8 block).

[0041] After obtaining the intra-frame and inter-frame encoding cost of the 4x4 block on the current frame 1 / 2 down-sampling plane, the mode selection of the encoding block with the size of 8x8 and the division of the 16x16 size encoding block in the formal encoding process can be assisted to make a decision. For example, when the intra-frame optimal encoding cost of the four 4x4 blocks is balanced, it indicates that the texture complexity of the current block is relatively uniform. At this time, if the intra-frame optimal encoding cost is small, the formal encoding process is more inclined to encode the 16x16 size encoding block corresponding to the 8x8 block as a whole, and no longer continue to divide it into 8x8 size encoding blocks. On the contrary, if the intra-frame optimal encoding cost of the four 4x4 blocks is extremely unbalanced, the difference between the maximum value and the minimum value is large, which indicates that the 16x16 size encoding block corresponding to the 8x8 block has strong edge information. At this time, the formal encoding process is more inclined to divide the 16x16 size encoding block into 8x8 smaller encoding blocks, so as to expect that each 8x8 size encoding block can find its own optimal intra-frame encoding mode and reduce the residual error and distortion. The inter-frame encoding has the same tendency, so the intra-frame optimal encoding cost and the inter-frame optimal encoding cost of the pre-encoding 4x4 block can be used as the basis for accelerating the intra-frame and inter-frame encoding process. In this way, by allocating additional storage space, the intra-frame and inter-frame encoding cost of the 4x4 block is generated in the pre-encoding, and the division of the 16x16 size encoding block in the intra-frame encoding and the mode selection of the 8x8 size encoding block in the inter-frame encoding are accelerated according to the intra-frame encoding cost of the pre-encoding 4x4 block, the frame type of the current frame and the block size, so as to realize the encoding acceleration effect.

[0042] It should be noted that in actual application, the coding block size of pre-coding and formal coding can be different for different video coding standards. That is, the coding block for pre-coding analysis can be an 8x8 size coding block obtained by 1 / 2 down-sampling a 16x16 size coding block, or can be a coding block of other different sizes. According to the coding acceleration requirement of coding blocks of different sizes in the formal coding process, the first fixed size coding block and the second fixed size coding block can be adaptively set, and the embodiments of the present application do not make fixed limitation on the specific coding block size, which will not be described here.

[0043] Specifically, the embodiments of the present application are described in detail below taking the pre-coding information of 8x8 block as an example. Before the second coding cost information of the corresponding number of second fixed size coding blocks is obtained by splitting the first coding cost information, it further includes: determining the splitting number of the first fixed size coding block corresponding to the second fixed size coding block, and allocating a data storage structure according to the total number and the splitting number of the first fixed size coding block to store the second coding cost information.

[0044] Wherein, assuming that the number of 8x8 blocks divided by 1 / 2 down-sampling pixel plane is cuCount, 4*cuCount data structures are additionally allocated for the second coding cost information of the split 4x4 blocks to store the intra-optimal coding cost and the inter-optimal coding cost, that is, the second coding cost information. A three-dimensional array is used to store the intra-optimal coding cost and the inter-optimal coding cost information of all 4x4 blocks. The three-dimensional array is represented as: lowresCost4x4[BFRAME_MAX+2][BFRAME_MAX+2][4*cuCount]. Wherein, the first two dimensions of lowresCost4x4 represent the distance of the current frame and the forward reference frame and the distance of the current frame and the backward reference frame, if the forward and backward distances are 0, the lowresCost4x4 actually stores the intra coding cost, and the rest are inter coding cost. The third dimension represents the position of the 4x4 block, such as the current frame lowresCost4x4[1][1][0], which refers to the bidirectional prediction cost of the first 4x4 block of the current frame and the previous frame and the next frame. lowresCost4x4[0][0][0] represents the intra coding cost of the first 4x4 block of the current frame, and the specific data type of lowresCost4x4 is uint16_t, the first two dimensions of which are related to the reference distance, and the maximum reference distance is the maximum number of b frames allowed+2 (BFRAME_MAX+2), which can be adjusted more reasonably according to actual coding requirements. When the corresponding information is extracted from the data structure, the intra-optimal coding cost 4x4[i] and the inter-optimal coding cost 4x4[i] need to be calculated from lowresCost4x4, and the calculation formula is as follows:

[0045] Intra optimal encoding cost 4x4[i] = lowresCost4x4[0][0][i]

[0046] Inter optimal encoding cost 4x4[i] = lowresCost4x4[dist0][dist1][i]

[0047] Wherein, dist0 represents the distance between the current frame and the forward reference frame, dist1 represents the distance between the current frame and the backward reference frame, dist0 and dist1 are given in the analysis process of formal encoding, and i represents the position of the loop through all 4x4 blocks. Based on the above pre-constructed data storage structure, the splitting and storage of the first encoding cost information of the pre-encoding of the current frame can be performed in the pre-encoding process of the current frame.

[0048] Further, after splitting the first encoding cost information to obtain the second encoding cost information of the corresponding number of second fixed size encoding blocks, each second encoding cost information is stored in the data storage structure allocated to the corresponding first fixed size encoding block according to the row scanning order of the second fixed size encoding block.

[0049] The encoding cost data structure of the 8x8 block in the pre-encoding analysis process is stored in the row scanning order. Since the 8x8 block is split into 4 4x4 blocks in the embodiment of the present application, the 4 4x4 blocks of each 8x8 block are also stored in the row scanning order when storing the lowresCost4x4 data structure. As shown in Figure 3 1, 2, 3, and 4 belong to the first 8x8 block, 5, 6, 7, and 8 belong to the second 8x8 block, and the encoding cost information of each 4x4 block is stored in the Figure 2 order number, and after storing a row of 8x8 blocks, the next row is stored. The calculation of the 4x4 block encoding cost is to replace the original 8x8 block satd calculation with 4 4x4 satd calculations. The satd of the 8x8 block to be stored in the original data structure is the sum of the satd of the 4 4x4 blocks. Since the satd of the 8x8 block is calculated by traversing the 4x4 blocks and then summed, the calculation amount is not increased too much, and the encoding efficiency of the subsequent pre-encoding information auxiliary encoding can be guaranteed.

[0050] Then, the second encoding cost information stored in the above encoding process can be selected based on the frame type and the block size of the current encoding block to perform encoding analysis. Referring to Figure 4 , the intra encoding analysis process includes:

[0051] S1201, in the case that the frame type is an I frame and the block size of the current coding block corresponds to the block size before the first fixed size coding block is down-sampled, extracting the intra-frame coding cost information contained in each second coding cost information corresponding to the current coding block, and calculating the maximum intra-frame coding cost and the average intra-frame coding cost based on the extracted intra-frame coding cost information;

[0052] S1202, performing a current coding block corresponding block size level intra-frame mode checking process skip judgment based on the maximum intra-frame coding cost and the average intra-frame coding cost.

[0053] In the case that the current frame is an I frame, in the coding recursive analysis of the I frame, if the current coding block size is 16x16, the corresponding 8x8 block position on the 1 / 2 down-sampled pixel plane is obtained, so that the intra-frame optimal coding cost (i.e. intra-frame coding cost information) of the four 4x4 blocks is obtained. The intra-frame optimal coding cost is calculated from the lowresCost4x4 data structure according to the above data structure solving formula. Then, the maximum intra-frame coding cost intraCostMax and the average intra-frame coding cost intraCostAvg of the four 4x4 blocks are calculated according to the calculated intra-frame optimal coding cost, and then the current coding block corresponding block size level intra-frame mode checking process skip judgment is performed. The current coding block corresponding block size level intra-frame mode checking process skip judgment based on the maximum intra-frame coding cost and the average intra-frame coding cost includes:

[0054] In the case that the maximum intra-frame coding cost is greater than the average intra-frame coding cost by a set multiple, and the coding depth of the current coding block is less than the coding depth of the associated coding block, the intra-frame mode checking process of the current coding block corresponding block size level is skipped, and the intra-frame mode checking process of the next block size level is entered.

[0055] If intraCostMax is greater than intraCostAvg*2, and the coding depths of the associated coding blocks (left and upper coding blocks) of the current 16x16 size coding block are both greater than the current layer depth, the current layer mode checking is skipped, and the mode checking of the 8x8 size is directly entered. Through the mode checking skip, the intra-frame coding is accelerated. In actual application, different comparison conditions can be set according to the maximum intra-frame coding cost and the average intra-frame coding cost, and the current coding block corresponding block size level intra-frame mode checking process skip judgment is performed according to the comparison result. The specific comparison conditions are not limited in the present application, and will not be described here.

[0056] On the other hand, referring to Figure 5 , the inter-frame coding analysis process includes:

[0057] S1203, in the case that the frame type is a P frame or a B frame, and the block size of the current coding block corresponds to the block size of the first fixed-size coding block, extracting the intra-frame coding cost information and the inter-frame coding cost information contained in the second coding cost information corresponding to the current coding block;

[0058] S1204, in the case that the inter-frame coding cost information is greater than the product of the intra-frame coding cost information and the intra-frame influence coefficient, and the associated coding block adopts the intra-frame mode check, skipping the inter-frame mode check procedure of the current coding block.

[0059] S1205, in the case that the inter-frame coding cost information is greater than the intra-frame coding cost information, and the inter-frame mode check procedure of the current coding block is not skipped, screening out the candidate motion vectors for motion estimation of the current coding block.

[0060] When the current frame is a P frame or a B frame, in the inter-frame coding recursive analysis, if the size of the current coding block is 8x8, first, the position coordinates of the 4x4 block on the 1 / 2 down-sampling pixel plane corresponding to the current coding block are also obtained, and the intra-frame coding cost intraCost4x4 and the inter-frame coding cost interCost4x4 of the 4x4 block are taken out. If interCost4x4 is greater than intraCost4x4*ratioIntra4x4 (ratioIntra4x4 is the intra-frame influence coefficient, which is 1.25 here), and the associated coding blocks of the 8x8 size coding block all adopt the intra-frame mode check, i.e., the modes of the left coding block and the upper coding block are both intra-frame modes, the inter-frame mode check is skipped. If the inter-frame mode check is not skipped, further judgment is made before the inter-frame mode check. If interCost4x4 is greater than intraCost4x4, the number of candidate motion vectors that need to be checked for motion estimation of the current 8x8 size coding block is reduced, and usually, the parent block motion vector of the current coding block and the corresponding 8x8 block motion vector in the corresponding 1 / 2 down-sampling plane are screened out from the candidate motion vectors mvs, so as to simplify the motion estimation process.

[0061] In addition, after extracting the intra-frame coding cost information and the inter-frame coding cost information contained in the second coding cost information corresponding to the current coding block, the following steps are further included:

[0062] In the case that the intra-frame coding cost information is greater than the product of the inter-frame coding cost information and the inter-frame influence coefficient, and the associated coding block does not adopt the intra-frame mode check, the intra-frame mode check procedure of the current coding block is skipped.

[0063] When the intra mode check is performed on the 8x8 block, if the intraCost4x4 is greater than the interCost4x4*ratioInter4x4 (ratioInter4x4 is the inter-influence coefficient, which is 1.5 here), and the associated coding blocks (i.e. the left coding block and the upper coding block) of the 8x8 size coding block are not intra mode, the intra mode check is skipped to save the operation.

[0064] As can be seen from the above intra coding acceleration and inter coding acceleration strategies, since the intra-inter coding cost of the 4x4 block used in the present application is not the real satd value obtained by the intra mode selection and inter motion estimation of the real 4x4 coding block, the mode information or depth information of the partial surrounding block or the upper parent block is used for further constraint in the use process, so as to reduce the quality loss caused by some misjudgments.

[0065] So far, by splitting the pre-encoding 8x8 block coding cost, the pre-encoding analysis process generates the intra-inter coding cost in the unit of 4x4 block size. Thus, the decision basis is provided for the mode decision of the 8x8 size coding block in the formal coding process, so as to skip some unnecessary mode decisions, and meanwhile, the fast division of the 16x16 size coding block can be accelerated. According to the actual test, the performance of the final algorithm on the mobile terminal is that the encoding fps is accelerated by 1.7%, and the bdrate loss of the encoder quality evaluation is only 0.12%.

[0066] In the above, the first coding cost information of the first fixed size coding block obtained by pre-encoding the current frame is acquired, the first coding cost information is split to obtain the second coding cost information of the corresponding number of second fixed size coding blocks; the frame type of the current frame is determined, the corresponding second coding cost information is selected based on the frame type and the block size of the current coding block for coding analysis, and the coding of the current coding block is performed according to the coding analysis result. The coding analysis includes intra coding analysis and / or inter coding analysis. By splitting the coding cost information of the larger size coding block and using the split coding cost information for coding analysis of the smaller size coding block, the coding mode decision of the corresponding coding block is assisted, the operation process is saved, the coding efficiency is improved while the coding quality is guaranteed, and the coding acceleration effect of the small size coding block is realized.

[0067] On the basis of the above embodiment, Figure 6 A structure diagram of an encoding acceleration system based on pre-encoding information splitting is provided in the present application. Referring to Figure 6 The encoding acceleration system based on pre-encoding information splitting provided in the present embodiment specifically includes a splitting module 21 and an analysis module 22.

[0068] The splitting module 21 is configured to obtain first coding cost information of a first fixed-size coding block obtained by pre-encoding a current frame, and split the first coding cost information to obtain second coding cost information of a corresponding number of second fixed-size coding blocks.

[0069] The analysis module 22 is configured to determine a frame type of the current frame, select corresponding second coding cost information for coding analysis based on the frame type and a block size of the current coding block, and perform coding of the current coding block according to a coding analysis result, wherein the coding analysis includes intra-frame coding analysis and / or inter-frame coding analysis.

[0070] Specifically, before splitting the first coding cost information to obtain the second coding cost information of the corresponding number of second fixed-size coding blocks, the method further includes:

[0071] determining a splitting number of the first fixed-size coding block corresponding to the second fixed-size coding block, and allocating a data storage structure to store the second coding cost information according to a total number of the first fixed-size coding blocks and the splitting number.

[0072] After splitting the first coding cost information to obtain the second coding cost information of the corresponding number of second fixed-size coding blocks, the method further includes:

[0073] storing each second coding cost information into the data storage structure allocated to the corresponding first fixed-size coding block in a row scanning order of the second fixed-size coding block.

[0074] Specifically, the selecting of the corresponding second coding cost information for the coding analysis based on the frame type and the block size of the current coding block includes:

[0075] S1201, in a case where the frame type is an I frame and the block size of the current coding block corresponds to a block size before downsampling of the first fixed-size coding block, extracting intra-frame coding cost information contained in each second coding cost information corresponding to the current coding block, and calculating a maximum intra-frame coding cost and an average intra-frame coding cost based on the extracted intra-frame coding cost information.

[0076] S1202, performing a frame-intra mode check process skip judgment of a block size level corresponding to the current coding block based on the maximum intra-frame coding cost and the average intra-frame coding cost.

[0077] The performing of the frame-intra mode check process skip judgment of the block size level corresponding to the current coding block based on the maximum intra-frame coding cost and the average intra-frame coding cost includes:

[0078] In a case that the maximum intra coding cost is greater than the average intra coding cost by a set multiple, and the coding depth of the current coding block is less than the coding depth of the associated coding block, skip the intra mode check process of the current coding block at the block size level, and enter the intra mode check process of the next block size level.

[0079] On the other hand, the encoding analysis based on the frame type and the block size of the current coding block selects the corresponding second coding cost information, including:

[0080] S1203, in a case that the frame type is a P frame or a B frame, and the block size of the current coding block corresponds to the block size of the first fixed-size coding block, extract the intra coding cost information and the inter coding cost information contained in the second coding cost information corresponding to the current coding block;

[0081] S1204, in a case that the inter coding cost information is greater than the product of the intra coding cost information and the intra influence coefficient, and the associated coding block adopts the intra mode check, skip the inter mode check process of the current coding block;

[0082] S1205, in a case that the inter mode check process of the current coding block is not skipped, and the inter coding cost information is greater than the intra coding cost information, exclude the candidate motion vector of the current coding block for motion estimation.

[0083] After extracting the intra coding cost information and the inter coding cost information contained in the second coding cost information corresponding to the current coding block, further comprising:

[0084] In a case that the intra coding cost information is greater than the product of the inter coding cost information and the inter influence coefficient, and the associated coding block does not adopt the intra mode check, skip the intra mode check process of the current coding block.

[0085] The above, by obtaining the first coding cost information of the first fixed-size coding block pre-encoded in the current frame, splitting the first coding cost information to obtain the second coding cost information of the corresponding number of second fixed-size coding blocks; determine the frame type of the current frame, select the corresponding second coding cost information based on the frame type and the block size of the current coding block for encoding analysis, and perform encoding of the current coding block according to the encoding analysis result, the encoding analysis includes intra coding analysis and / or inter coding analysis. By using the above technical means, the coding cost information of the larger size coding block is split, and the split coding cost information is used for coding analysis of the smaller size coding block to assist in coding mode decision of the corresponding coding block, save the operation process, improve the coding efficiency while ensuring the coding quality, and realize the coding acceleration effect of the small size coding block.

[0086] The encoding acceleration system based on precoding information splitting provided in this application embodiment can be configured to execute the encoding acceleration method based on precoding information splitting provided in the above embodiment, and has corresponding functions and beneficial effects.

[0087] Based on the above practical examples, this application also provides a coding acceleration device based on precoding information decomposition, referring to... Figure 7 The encoding acceleration device based on pre-encoded information splitting includes a processor 31, a memory 32, a communication module 33, an input device 34, and an output device 35. The memory, as a computer-readable storage medium, can be configured to store software programs, computer-executable programs, and modules, such as program instructions / modules corresponding to the encoding acceleration method based on pre-encoded information splitting described in any embodiment of this application (e.g., the splitting module and analysis module in the encoding acceleration system based on pre-encoded information splitting). The communication module is configured to perform data transmission. The processor executes various functional applications and data processing of the device by running the software programs, instructions, and modules stored in the memory, thereby implementing the aforementioned encoding acceleration method based on pre-encoded information splitting. The input device can be configured to receive input digital or character information and generate key signal inputs related to user settings and function control of the device. The output device may include a display screen or other display device. The encoding acceleration device based on pre-encoded information splitting provided above can be configured to execute the encoding acceleration method based on pre-encoded information splitting provided in the above embodiments, possessing corresponding functions and beneficial effects.

[0088] Based on the above embodiments, this application also provides a computer-readable storage medium storing computer-executable instructions. These instructions, when executed by a computer processor, are configured to perform a coding acceleration method based on pre-coded information splitting. The storage medium can be any type of memory device or storage device. Of course, the computer-readable storage medium provided in this application may not be limited to the coding acceleration method based on pre-coded information splitting as described above; it can also perform related operations in the coding acceleration method based on pre-coded information splitting provided in any embodiment of this application.

[0089] Based on the above embodiments, this application also provides a computer program product. The technical solution of this application, in essence or in other words, the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. The computer program product is stored in a storage medium and includes several instructions to cause a computer device, mobile terminal, or processor therein to execute all or part of the steps of the encoding acceleration method based on pre-encoded information splitting described in the various embodiments of this application.

Claims

1. A method for encoding acceleration based on pre-encoding information splitting, characterized in that, The method comprises the following steps: obtaining a first fixed-size coding block obtained by pre-encoding a current frame, splitting the first fixed-size coding block to obtain a corresponding number of second fixed-size coding blocks, and determining second coding cost information of the second fixed-size coding blocks; determining a frame type of the current frame, and selecting corresponding second coding cost information for coding analysis based on the frame type and the block size of the current coding block, wherein, in the case that the frame type is an I frame and the block size of the current coding block is equal to the block size of the first fixed-size coding block before 1 / 2 downsampling, extracting intra-frame coding cost information contained in each of the second coding cost information corresponding to the current coding block, calculating a maximum intra-frame coding cost and an average intra-frame coding cost based on the extracted intra-frame coding cost information, and performing an intra-frame mode coding process skip judgment of the block size level corresponding to the current coding block based on the maximum intra-frame coding cost and the average intra-frame coding cost; in the case that the frame type is a P frame or a B frame and the block size of the current coding block is equal to the block size of the first fixed-size coding block, extracting intra-frame coding cost information and inter-frame coding cost information contained in the second coding cost information corresponding to the current coding block; in the case that the inter-frame coding cost information is greater than the product of the intra-frame coding cost information and an intra-frame influence coefficient, and the associated coding block adopts an intra-frame mode coding, skipping an inter-frame mode checking process of the current coding block, the associated coding block being a coding block on the left and top sides of the current coding block; in the case that the inter-frame mode checking process of the current coding block is not skipped and the inter-frame coding cost information is greater than the intra-frame coding cost information, removing the parent block motion vector of the current coding block and the corresponding 8x8 block motion vector in the corresponding 1 / 2 downsampling plane from the candidate motion vector; and performing coding of the current coding block according to the coding analysis result, the coding analysis including intra-frame coding analysis and / or inter-frame coding analysis.

2. The encoding acceleration method based on pre-encoding information splitting according to claim 1, characterized in that, Before splitting the first fixed-size coding block to obtain a corresponding number of second fixed-size coding blocks and determining second coding cost information of the second fixed-size coding blocks, the method further comprises the following steps: determining the number of splits of the first fixed-size coding block corresponding to the second fixed-size coding blocks, and allocating a data storage structure to store the second coding cost information according to the total number of the first fixed-size coding blocks and the number of splits.

3. The encoding acceleration method based on pre-encoding information splitting according to claim 2, characterized in that, After splitting the first fixed-size coding block to obtain a corresponding number of second fixed-size coding blocks and determining second coding cost information of the second fixed-size coding blocks, the method further comprises the following steps: storing each of the second coding cost information in the data storage structure allocated corresponding to the first fixed-size coding block according to the row scanning order of the second fixed-size coding blocks.

4. The encoding acceleration method based on pre-encoding information splitting according to claim 1, characterized in that, The step of performing an intra-frame mode coding process skip judgment of the block size level corresponding to the current coding block based on the maximum intra-frame coding cost and the average intra-frame coding cost comprises: In a case that the maximum intra coding cost is greater than the average intra coding cost by a set multiple, and a coding depth of the current coding block is less than a coding depth of associated coding blocks, the intra mode coding process of the current coding block at the block size level is skipped, and an intra mode coding process of a next block size level is entered, the associated coding blocks being coding blocks on the left and top sides of the current coding block.

5. The encoding acceleration method based on pre-encoding information splitting according to claim 1, characterized in that, After extracting the intra coding cost information and the inter coding cost information contained in the second coding cost information corresponding to the current coding block, the method further comprises: In a case that the intra coding cost information is greater than a product of the inter coding cost information and an inter influence coefficient, and the associated coding blocks do not use the intra mode coding, the intra mode coding process of the current coding block is skipped.

6. A coding acceleration system based on pre-encoding information splitting, characterized in that, The method comprises: The splitting module is configured to obtain a first fixed-size coding block obtained by pre-coding a current frame, split the first fixed-size coding block to obtain a corresponding number of second fixed-size coding blocks, and determine second coding cost information of the second fixed-size coding blocks; The analysis module is configured to determine a frame type of the current frame, and select corresponding coding analysis of the second coding cost information based on the frame type and a block size of the current coding block, wherein, in a case that the frame type is an I frame, and the block size of the current coding block is equal to a block size before 1 / 2 down-sampling of the first fixed-size coding block, intra coding cost information contained in each of the second coding cost information corresponding to the current coding block is extracted, a maximum intra coding cost and an average intra coding cost are calculated based on the extracted intra coding cost information, and a skip judgment of an intra mode coding process of the current coding block at a block size level is performed based on the maximum intra coding cost and the average intra coding cost; in a case that the frame type is a P frame or a B frame, and the block size of the current coding block is equal to a block size of the first fixed-size coding block, intra coding cost information and inter coding cost information contained in the second coding cost information corresponding to the current coding block are extracted; in a case that the inter coding cost information is greater than a product of the intra coding cost information and an intra influence coefficient, and the associated coding blocks use the intra mode coding, an inter mode check process of the current coding block is skipped, the associated coding blocks being coding blocks on the left and top sides of the current coding block; in a case that the inter mode check process of the current coding block is not skipped, and the inter coding cost information is greater than the intra coding cost information, a parent block motion vector of the current coding block and a corresponding 8x8 block motion vector in a corresponding 1 / 2 down-sampling plane are removed from candidate motion vectors; and encoding of the current coding block is performed according to an encoding analysis result, the encoding analysis including intra encoding analysis and / or inter encoding analysis.

7. An encoding acceleration device based on pre-encoding information splitting, characterized in that, The apparatus comprises: a memory and one or more processors; the memory is configured to store one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors implement the encoding acceleration method based on pre-coding information splitting as claimed in any one of claims 1-5.

8. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer executable instructions which, when executed by a computer processor, are configured to perform the encoding acceleration method based on pre-encoding information splitting as claimed in any one of claims 1-5.

9. A computer program product, characterised in that, The computer program product contains instructions which, when run on a computer or processor, cause the computer or processor to perform the encoding acceleration method based on pre-encoding information splitting as claimed in any one of claims 1-5.

Citation Information

Patent Citations

  • Image encoding method

    CN109561304A

  • Video predictive coding method and apparatus

    WO2022121786A1