Coding unit partitioning method based on dual texture complexity

By using a coding unit partitioning method based on dual texture complexity, we can distinguish between coding units with obvious textures and those without, select an appropriate partitioning strategy, and solve the problems of low efficiency and insufficient accuracy in existing video coding technologies, thus achieving more efficient and accurate coding unit partitioning.

CN120769042BActive Publication Date: 2025-11-14JIAYUAN SCI & TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202511212500.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-08-28
Publication Date
2025-11-14
Estimated Expiration
2045-08-28

AI Technical Summary

Technical Problem

Existing video coding technologies suffer from high computational complexity, low efficiency, and insufficient accuracy when dividing coding units. This is especially true in high-definition video coding, where quadtree combined with multi-type tree partitioning strategies are time-consuming and only support a limited number of partitioning mechanisms.

Method used

A coding unit partitioning method based on dual texture complexity is adopted. By detecting the texture complexity of the coding unit, it distinguishes between coding units with obvious texture and those without obvious texture. Different partitioning processes and strategies are selected according to the unit type, such as reverse partitioning, quadtree combined with multi-type tree partitioning, or standard partitioning, to optimize the coding unit partitioning process.

Benefits of technology

It improves video coding efficiency and coding unit partitioning accuracy, reduces partitioning time, and enhances the partitioning efficiency and accuracy of coding units.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120769042B_ABST
    Figure CN120769042B_ABST
Patent Text Reader

Abstract

This application provides a coding unit partitioning method based on dual texture complexity, belonging to the field of video coding technology. The method involves: detecting the texture complexity of the target coding unit; determining the unit type of the target coding unit based on the texture complexity, a first preset threshold, and a second preset threshold; the unit type including: a coding unit with obvious texture or a coding unit without obvious texture; determining the target partitioning process for the target coding unit based on the unit type; the target partitioning process including: a partitioning process with obvious texture or a partitioning process without obvious texture; determining the target partitioning strategy based on the target partitioning process and texture complexity; and performing the partitioning operation on the target coding unit according to the target partitioning strategy, which includes: a reverse partitioning strategy, a quadtree combined with multiple tree types partitioning strategy, or a standard partitioning strategy. This application can improve video coding efficiency and the partitioning efficiency and accuracy of coding units.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of video coding technology, and more specifically, to a coding unit partitioning method based on dual texture complexity. Background Technology

[0002] With the increasing maturity of chip technology and video capture technology, users' demands for video quality are constantly rising, and high-definition and ultra-high-definition video are becoming increasingly popular. This has led to an explosive growth in raw video data, placing higher demands on video data storage and transmission. To meet these demands, the new video coding technology (Versatile Video Coding, VCC) optimizes the partitioning accuracy and flexibility of coding units through a quad-tree plus multi-type tree (QTMT) partitioning structure, thereby improving video compression efficiency and overcoming the bandwidth bottleneck of video data storage and transmission. However, this video coding technology also brings high computational complexity. QTMT supports multiple partitioning mechanisms, including quad-tree (QT), horizontal binary tree (HBT), vertical binary tree (VBT), horizontal ternary tree (HTT), and vertical ternary tree (VTT).

[0003] Currently, the partitioning efficiency of QTMT is often improved by early termination fast partitioning decisions. Among them, early termination fast partitioning decisions are often performed by artificial features such as texture complexity analysis, rate-distortion cost thresholding, and adjacent coding unit correlation. Texture complexity analysis is used to evaluate whether a coding unit needs to be partitioned, rate-distortion cost thresholding is used to evaluate whether the current coding unit needs to terminate the subsequent partitioning operation early, and adjacent coding unit correlation is used to mask some impossible modes by partitioning depth and partitioning mode of already encoded adjacent coding units.

[0004] However, when dividing coding units based on the fast partitioning decision of early termination, a large amount of manual feature extraction is required, and the actual encoding process only supports QT partitioning operation and no partitioning operation. This results in low partitioning accuracy of coding units, long partitioning time, and low video encoding efficiency. Summary of the Invention

[0005] The purpose of this application is to provide a coding unit partitioning method based on dual texture complexity, which can improve video coding efficiency as well as the partitioning efficiency and accuracy of coding units.

[0006] The embodiments of this application are implemented as follows:

[0007] A first aspect of this application provides a coding unit partitioning method based on dual texture complexity, applied in an encoder, the coding unit partitioning method comprising:

[0008] The texture complexity in the target coding unit of the encoder is detected, and the unit type of the target coding unit is determined according to the texture complexity, the first preset threshold and the second preset threshold. The texture complexity includes: the total horizontal gradient value, the total vertical gradient value and the gradient difference. The unit type includes: a coding unit with obvious texture or a coding unit without obvious texture.

[0009] Based on the unit type of the target coding unit, the target partitioning process of the target coding unit is determined. The target partitioning process includes: obvious texture partitioning process or no obvious texture coding partitioning process.

[0010] Based on the target partitioning process and texture complexity, a target partitioning strategy is determined, and the target encoding unit is partitioned according to the target partitioning strategy. The target partitioning strategy includes: reverse partitioning strategy, quadtree combined with multi-type tree partitioning strategy or standard partitioning strategy. The quadtree combined with multi-type tree partitioning strategy includes at least one of the following: quadtree partitioning, horizontal binary tree partitioning, vertical binary tree partitioning, horizontal ternary tree partitioning and vertical ternary tree partitioning.

[0011] As one possible implementation, detecting texture complexity in a target coding unit includes:

[0012] Calculate the horizontal and vertical gradient values ​​between each pixel in the target coding unit and its neighboring pixels. Neighboring pixels include those that are horizontally shifted to the right and those that are vertically shifted downward.

[0013] Determine the number of rows and columns of the target coding unit based on all the pixels contained in the target coding unit;

[0014] The total horizontal gradient value of the target coding unit is determined based on the number of rows, the number of columns, and the horizontal gradient values ​​between each pixel and its neighboring pixels.

[0015] The total vertical gradient value of the target coding unit is determined based on the number of rows, the number of columns, and the vertical gradient values ​​between each pixel and its neighboring pixels.

[0016] The gradient difference of the target coding unit is determined based on the total horizontal gradient value and the total vertical gradient value.

[0017] As one possible implementation, the gradient difference of the target coding unit is determined based on the total horizontal gradient value and the total vertical gradient value, including:

[0018] Calculate the first ratio between the total horizontal gradient value and the total vertical gradient value;

[0019] Calculate the second ratio between the total vertical gradient value and the total horizontal gradient value;

[0020] The maximum value between the first ratio and the second ratio is taken as the gradient difference of the target coding unit.

[0021] As one possible implementation, the unit type of the target coding unit is determined based on texture complexity, a first preset threshold, and a second preset threshold, including:

[0022] Determine whether the gradient difference is greater than a first preset threshold;

[0023] If so, then the unit type of the target coding unit is determined to be an obvious texture coding unit;

[0024] If not, determine whether the total horizontal gradient value and the total vertical gradient value are both greater than the second preset threshold. If so, determine that the unit type of the target coding unit is an obvious texture coding unit.

[0025] If not, then the unit type of the target coding unit is determined to be a coding unit without obvious texture.

[0026] As one possible implementation, the target partitioning process is a clear texture partitioning process. Based on the target partitioning process and texture complexity, the target partitioning strategy is determined, including:

[0027] If the gradient difference is greater than the first preset threshold and the gradient difference is greater than the preset gradient difference threshold, then the target partitioning strategy is determined to be the reverse partitioning strategy. The reverse partitioning strategy includes horizontal partitioning and vertical partitioning.

[0028] If the gradient difference is less than or equal to the preset gradient difference threshold, and both the total horizontal gradient value and the total vertical gradient value are greater than the preset total gradient threshold, then the target partitioning strategy is determined to be a quadtree combined with multi-type tree partitioning strategy.

[0029] As one possible implementation, if the gradient difference is less than or equal to a preset gradient difference threshold, and both the total horizontal gradient value and the total vertical gradient value are greater than a preset total gradient threshold, then the target partitioning strategy is determined to be a quadtree combined with multiple tree types partitioning strategy, including:

[0030] If the gradient difference is greater than the first preset threshold and the total vertical gradient is greater than the total horizontal gradient, then horizontal binary tree partitioning and horizontal ternary tree partitioning are determined as the target partitioning strategies.

[0031] If the gradient difference is greater than the first preset threshold and the total vertical gradient is less than the total horizontal gradient, then vertical binary tree partitioning and vertical ternary tree partitioning are determined as the target partitioning strategies.

[0032] If the gradient difference is less than the first preset threshold, and the maximum value between the total vertical gradient and the total horizontal gradient is greater than the second preset threshold, then the quadtree partitioning is determined as the target partitioning strategy.

[0033] As one possible implementation, the target partitioning process is a texture-free partitioning process. Before determining the target partitioning strategy based on the target partitioning process and texture complexity, the following steps are taken:

[0034] The target coding unit is divided into multiple sub-coding blocks, and multiple sub-block search boxes are set up. Each sub-block search box covers a preset area with the adjacent sub-block search boxes.

[0035] As one possible implementation, the target partitioning strategy is determined based on the target partitioning process and texture complexity, including:

[0036] The intensity of texture change for each pixel is determined based on each pixel in the target coding unit and the associated pixels corresponding to each pixel.

[0037] Based on the number of rows and columns of the target coding unit and the intensity of texture change of each pixel, the texture complexity of each sub-block search box is determined, and the maximum texture complexity is determined from the texture complexity of each sub-block search box.

[0038] The target partitioning strategy is determined based on the maximum texture complexity, the third preset threshold, and the fourth preset threshold.

[0039] As one possible implementation, the target partitioning strategy is determined based on the maximum texture complexity, a third preset threshold, and a fourth preset threshold, including:

[0040] If the maximum texture complexity is less than or equal to the third preset threshold, then the target coding unit is determined to be free from partitioning.

[0041] If the maximum texture complexity is greater than the third preset threshold and less than the fourth preset threshold, then the target partitioning strategy is determined to be the standard partitioning strategy.

[0042] If the maximum texture complexity is greater than or equal to the fourth preset threshold, then the target partitioning strategy is determined to be a quadtree combined with multi-type tree partitioning strategy.

[0043] As one possible implementation, the target partitioning strategy is determined to be a quadtree combined with multi-type tree partitioning strategy, including:

[0044] If the search box for the sub-block corresponding to the maximum texture complexity is at the vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is greater than the column texture complexity, then horizontal binary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

[0045] If the search box for the sub-block corresponding to the maximum texture complexity is at the vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is less than the column texture complexity, then the vertical binary tree partitioning and the quadtree partitioning are determined as the target partitioning strategies.

[0046] If the sub-block search box corresponding to the maximum texture complexity is at a non-vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is greater than the column texture complexity, then horizontal ternary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

[0047] If the sub-block search box corresponding to the maximum texture complexity is located at a non-vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is less than the column texture complexity, then vertical ternary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

[0048] A second aspect of this application provides an encoder, which includes a control unit and a plurality of encoding units, wherein the control unit performs a partitioning operation on each of the encoding units based on the encoding unit partitioning method described in the first aspect above.

[0049] A third aspect of this application provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the coding unit partitioning method described in the first aspect.

[0050] The beneficial effects of the embodiments of this application include:

[0051] This application provides a coding unit partitioning method based on dual texture complexity. An encoder converts received image frames into corresponding pixel data. Based on the pixel data of image blocks in the target coding unit, the encoder determines the texture complexity of the target coding unit and, based on the texture complexity, determines whether the target coding unit is a clearly textured coding unit or a coding unit without clearly textured data. If the target coding unit is a clearly textured coding unit, the corresponding target partitioning process is determined to be a clearly textured partitioning process; if the target coding unit is without clearly textured data, the corresponding target partitioning process is determined to be a non-clearly textured partitioning process. Based on the target partitioning process and the texture complexity of the target coding unit, the target coding strategy for the target coding unit is determined to be one of the following: a reverse partitioning strategy, a quadtree combined with multiple types of tree partitioning strategy, and a standard partitioning strategy. The target coding unit is then partitioned based on the target partitioning strategy. By dividing multiple coding units in the encoder into two categories—clearly textured coding units and non-clearly textured coding units—and executing the clearly textured partitioning process and the non-clearly textured partitioning process in parallel, partitioning time can be saved. Furthermore, selecting the optimal partitioning strategy based on the texture complexity of the target coding unit during subsequent partitioning can reduce the partitioning difficulty and improve the partitioning accuracy of the coding unit. This achieves the effect of improving video coding efficiency as well as the partitioning efficiency and accuracy of coding units. Attached Figure Description

[0052] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.

[0053] Figure 1 A flowchart illustrating the first coding unit partitioning method based on dual texture complexity provided in this application embodiment;

[0054] Figure 2 A flowchart illustrating the second coding unit partitioning method based on dual texture complexity provided in this application embodiment;

[0055] Figure 3 A flowchart illustrating the third coding unit partitioning method based on dual texture complexity provided in this application embodiment;

[0056] Figure 4 A flowchart illustrating the fourth coding unit partitioning method based on dual texture complexity provided in this application embodiment;

[0057] Figure 5 A flowchart illustrating the fifth coding unit partitioning method based on dual texture complexity provided in this application embodiment;

[0058] Figure 6 This application provides a schematic diagram of the structure of a segmented sub-coding block of an encoding unit.

[0059] Figure 7 A schematic diagram of the structure of a search box provided in an embodiment of this application;

[0060] Figure 8 A flowchart of the sixth coding unit partitioning method based on dual texture complexity provided in the embodiments of this application;

[0061] Figure 9 A flowchart of the seventh coding unit partitioning method based on dual texture complexity provided in the embodiments of this application;

[0062] Figure 10 A texture complexity distribution map of a search box provided in an embodiment of this application;

[0063] Figure 11 A flowchart illustrating the eighth coding unit partitioning method based on dual texture complexity provided in this application embodiment;

[0064] Figure 12 A division rate curve of an encoding unit provided in an embodiment of this application;

[0065] Figure 13 This is a schematic diagram of the structure of an encoder provided in an embodiment of this application.

[0066] Reference numerals: 10: encoder; 101: control unit; 102: encoding unit. Detailed Implementation

[0067] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.

[0068] Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.

[0069] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.

[0070] Currently, early termination is often used to improve the partitioning efficiency of QTMT. This early termination strategy is based on artificial features such as texture complexity analysis, rate-distortion cost thresholding, and the correlation between adjacent coding units. Texture complexity analysis uses methods such as the sum of absolute values ​​of transformed differences and residual Hadamard transforms (SATD), gradient information, variance information, and edge detection operators (Sobel operator) to divide image patches into smooth and textured blocks. Smooth blocks skip deeper partitioning, while textured blocks undergo subsequent partitioning operations. The rate-distortion cost threshold is used to evaluate whether the current coding unit should terminate its subsequent partitioning mode early. If the rate-distortion cost (RD Cost) of the current coding unit is lower than the adaptive threshold, the subsequent partitioning mode of the current coding unit is terminated early. The correlation between adjacent coding units refers to constructing a spatiotemporal prediction model by referencing the partitioning depth of already encoded adjacent coding units, using the partitioning depth and partitioning mode of surrounding already encoded adjacent coding units to filter out some impossible patterns for the current coding unit. However, this approach requires extensive manual feature extraction, which makes the partitioning strategy time-consuming and consequently leads to low video coding efficiency. Furthermore, this approach only supports two mechanisms in actual coding: QT partitioning and no partitioning, resulting in low precision in coding unit partitioning.

[0071] It's worth noting that Quadtree Combined Multi-Type Tree (QTMT) is one of the most time-consuming encoding techniques in VVC coding. QTMT supports multiple partitioning mechanisms, including Quadtree (QT), Horizontal Binary Tree (HBT), Vertical Binary Tree (VBT), Horizontal Tritree (HTT), and Vertical Tritree (VTT). HBT, VBT, HTT, and VTT are collectively referred to as Multi-Type Trees (MTTs). Leaf nodes of a QT can be further partitioned by a QTMT, while leaf nodes of an MTT can only be further partitioned using an MTT.

[0072] Furthermore, in the actual VCC encoding process, the 64-bit × 64-bit encoding unit can only be selected from two mechanisms: QT partitioning or no partitioning. That is, the partitioning strategy for the 64-bit × 64-bit encoding unit is a binary strategy. The speedup gain generated by this partitioning strategy does not have a significant impact on the entire partitioning encoding process of QTMT. The partitioning process of QTMT still has the problem of long processing time.

[0073] Furthermore, the maximum allowed data size for the root node of a binary tree and the root node of a ternary tree is 32 bits. This means that there are six partitioning mechanisms to choose from for a 32-bit × 32-bit coding unit, such as no partitioning, QT, HBT, VBT, HTT, and VTT. This greatly increases the difficulty of the coding unit partitioning process, thereby reducing video coding efficiency.

[0074] To address this, this application provides a coding unit partitioning method based on dual texture complexity. By detecting the texture complexity within the target coding unit, the method determines whether the target coding unit is a clearly textured coding unit or a coding unit without a clearly textured structure. Based on the unit type of the target coding unit, the corresponding target partitioning process is invoked. Based on the target partitioning process and the texture complexity of the target coding unit, the method determines whether the target partitioning strategy is a reverse partitioning strategy, a quadtree combined with multiple tree partitioning strategy, or a standard partitioning strategy. Finally, based on the target partitioning strategy, the image blocks in the coding unit are partitioned to compress video data and save video encoding time. This achieves the effect of improving video encoding efficiency as well as the partitioning efficiency and accuracy of coding units.

[0075] It is worth noting that the coding unit partitioning method based on dual texture complexity provided in this application is mainly for partitioning coding units with a size of 32 bits × 32 bits, but it does not mean that the coding partitioning method provided in this application can only be used for coding units of this size. This application does not make any specific limitation in this regard.

[0076] The following description, in conjunction with the accompanying drawings, provides a detailed explanation of the coding unit partitioning method based on dual texture complexity provided in the embodiments of this application.

[0077] Figure 1 A flowchart illustrating a coding unit partitioning method based on dual texture complexity provided in this application is shown. This method is applied to an encoder, which can be deployed in a computer device; this application does not specifically limit its application. See also... Figure 1 This application provides a coding unit partitioning method based on dual texture complexity, including:

[0078] The encoder specifically refers to a video encoder, which is a hardware and software tool used to compress raw video data into a specific format encoding stream. Its main purpose is to significantly compress the size of video files while maintaining video quality, so that video data is easier to store and transmit.

[0079] It is worth noting that a video encoder contains multiple encoding units. These encoding units, as the core processing devices of the video encoder, are used to divide the image frames received by the encoder into logical blocks. The video encoder then selects an appropriate compression strategy to compress the image blocks within each encoding unit. The division of the encoding unit is the core of image block compression within that unit; a preferred division strategy can ensure a low distortion rate for the image blocks within the encoding unit.

[0080] It should also be noted that after receiving a certain image frame from the video stream, the encoder will perform data conversion on the current image frame to obtain the pixel data corresponding to the current image frame. The encoder evaluates the internal texture complexity of each coding unit based on the pixel data of the image blocks in each coding unit.

[0081] S101. Detect the texture complexity in the target coding unit of the encoder, and determine the unit type of the target coding unit based on the texture complexity, the first preset threshold and the second preset threshold. The texture complexity includes: the total horizontal gradient value, the total vertical gradient value and the gradient difference. The unit type includes: a coding unit with obvious texture or a coding unit without obvious texture.

[0082] Optionally, the encoder includes multiple coding units. The encoder divides the received current image frame into multiple image blocks through multiple coding units. The target coding unit refers to any coding unit in the encoder, and this application does not specifically limit it.

[0083] Optionally, texture complexity is mainly used to reflect the intensity and directional diversity of pixel value changes in image blocks within a coding unit. Slow pixel value changes indicate low complexity (such as a solid color background), while drastic pixel value changes (such as flowers, trees, or animal fur) indicate low complexity. Video encoders often evaluate the texture complexity of image blocks within a coding unit using key features such as statistical features, frequency domain features, and structural features. Statistical features are often calculated using algorithms such as variance and gradient magnitude; frequency domain features are obtained by performing a discrete cosine transform on the image blocks and statistically analyzing the energy proportion of high-frequency coefficients; structural features are obtained through edge density and directional consistency detection, which are not specifically limited in this application.

[0084] Texture complexity includes: total horizontal gradient value, total vertical gradient value, and gradient difference. The total horizontal gradient value is used to characterize the total gradient value of each pixel in the target coding unit in the horizontal direction, the total vertical gradient value is used to characterize the total gradient value of each pixel in the target coding unit in the vertical direction, and the gradient difference is used to characterize the degree of pixel change between the total horizontal gradient value and the total vertical gradient value in the target coding unit.

[0085] It is worth noting that the horizontal gradient value is used to describe the intensity of the pixel value change between two adjacent pixels (pixels in the same row) in the horizontal direction, while the vertical gradient value is used to describe the intensity of the pixel value change between two adjacent pixels (pixels in the same column) in the vertical direction. The higher the gradient value, the richer the image details in that area, and the more detailed the subdivision is required. The lower the gradient value, the less image details in that area, and only a coarse subdivision is needed.

[0086] Optionally, both the first preset threshold and the second preset threshold are gradient thresholds preset by the user. The texture complexity of the target coding unit is compared with the first preset threshold and the second preset threshold to determine whether the target coding unit is a clearly textured coding unit or a coding unit without clearly textured texture. A clearly textured coding unit refers to an image patch in the target coding unit containing rich image content, while a coding unit without clearly textured texture refers to an image patch in the target coding unit containing flat image content.

[0087] S102. Based on the unit type of the target coding unit, determine the target partitioning process of the target coding unit. The target partitioning process includes: obvious texture partitioning process or no obvious texture coding partitioning process.

[0088] Optionally, if the texture complexity of the target coding unit is low, then the target coding unit is a coding unit without obvious texture, and the target coding unit is roughly divided by calling the coding unit without obvious texture division process.

[0089] Optionally, if the texture complexity of the target coding unit is high, then the target coding unit is a distinct texture coding unit, and the distinct texture coding partitioning process is called to perform fine partitioning on the target coding unit.

[0090] S103. Based on the target partitioning process and texture complexity, determine the target partitioning strategy, and perform partitioning operations on the target coding units according to the target partitioning strategy. The target partitioning strategy includes: reverse partitioning strategy, quadtree combined with multi-type tree partitioning strategy or standard partitioning strategy. The quadtree combined with multi-type tree partitioning strategy includes at least one of the following: quadtree partitioning, horizontal binary tree partitioning, vertical binary tree partitioning, horizontal ternary tree partitioning and vertical ternary tree partitioning.

[0091] Optionally, the video encoder selects a target partitioning strategy for the target coding unit based on the internal texture complexity of the target coding unit and the target partitioning process matched by the target coding unit, and partitions the target coding unit based on the target partitioning strategy.

[0092] The target partitioning strategy refers to the partitioning strategy that matches the target coding unit. Target partitioning strategies include: reverse partitioning strategy, quadtree combined with multi-type tree partitioning strategy, and standard partitioning strategy. Reverse partitioning strategy refers to a partitioning strategy that is opposite to the horizontal or vertical gradient change trend of the target coding unit. Quadtree combined with multi-type tree partitioning strategy refers to a partitioning strategy that combines quadtrees and multi-type trees. Specifically, quadtree combined with multi-type tree partitioning strategy refers to a partitioning strategy obtained by combining at least one of quadtree partitioning, horizontal / vertical binary tree partitioning, and horizontal / vertical ternary tree partitioning. For example, the quadtree combined with multi-type tree partitioning strategy can be just quadtree partitioning, or it can be a partitioning strategy that combines horizontal binary tree partitioning and horizontal ternary tree partitioning in parallel; this application does not specifically limit this.

[0093] It is worth noting that quadtree partitioning is suitable for partitioning complex texture regions. Quadtrees can be partitioned in both horizontal and vertical directions, dividing one coding unit into four sub-blocks. Binary trees are suitable for partitioning elongated regions, dividing one coding unit into two sub-blocks. Tritrees are suitable for partitioning regions with gradient edges, dividing one coding unit into three sub-blocks. Meanwhile, no partitioning operation is required for coding units in flat regions.

[0094] Optionally, the standard partitioning strategy may specifically be a cross-scene video coding test model (VTM), which is not specifically limited in this application.

[0095] In this embodiment, the received image frame is converted into corresponding pixel data by an encoder. Based on the pixel data of the image block in the target coding unit, the encoder determines the texture complexity of the target coding unit and, based on the texture complexity, determines whether the target coding unit is a clearly textured coding unit or a coding unit without clearly textured data. If the target coding unit is a clearly textured coding unit, the target partitioning process corresponding to the target coding unit is determined to be a clearly textured partitioning process; if the target coding unit is a coding unit without clearly textured data, the target partitioning process corresponding to the target coding unit is determined to be a coding process without clearly textured data. Based on the target partitioning process corresponding to the target coding unit and the texture complexity of the target coding unit, the target coding strategy corresponding to the target coding unit is determined to be one of the following: a reverse partitioning strategy, a quadtree combined with multiple types of tree partitioning strategy, and a standard partitioning strategy. The target coding unit is then partitioned based on the target partitioning strategy. Dividing multiple coding units in the encoder into two categories—clearly textured coding units and coding units without clearly textured data—and executing the clearly textured partitioning process and the coding unit without clearly textured data in parallel can save partitioning time. Furthermore, selecting the optimal partitioning strategy based on the texture complexity of the target coding unit during subsequent partitioning can reduce the partitioning difficulty and improve the partitioning accuracy of the coding unit. This achieves the effect of improving video coding efficiency as well as the partitioning efficiency and accuracy of coding units.

[0096] In one alternative implementation, see [link to implementation details]. Figure 2 The operation of "detecting the texture complexity in the target coding unit" in step S101 above can be specifically as follows:

[0097] S201. Calculate the horizontal gradient value and vertical gradient value between each pixel in the target coding unit and its neighboring pixels. The neighboring pixels include: the neighboring pixels that are horizontally shifted to the right and the neighboring pixels that are vertically shifted downward.

[0098] Optionally, after data conversion, the image block in the target coding unit is used to obtain multiple pixels corresponding to the image block. Adjacent pixels refer to pixels that are spatially adjacent in the horizontal and vertical directions.

[0099] Optionally, the horizontal gradient value refers to the change in pixel intensity between a pixel and its adjacent pixel that is horizontally shifted to the right, and the vertical gradient value refers to the change in pixel intensity between a pixel and its adjacent pixel that is vertically shifted downwards.

[0100] Optionally, the horizontal gradient value between each pixel in the target coding unit and its neighboring pixels is calculated according to the following formula (1):

[0101] (1)

[0102] in, Used to represent pixels and adjacent pixels The horizontal gradient values ​​between them This refers to the horizontal gradient value of a pixel within the target coding unit. (x, y) represents the spatial position of the pixel within the target coding unit, and (x, y+1) represents the position of the adjacent pixel shifted one position to the right horizontally. It refers to the horizontal gradient value of the adjacent pixel that is shifted one position to the right in the horizontal direction.

[0103] Optionally, the vertical gradient value between each pixel in the target coding unit and its adjacent pixels is calculated according to the following formula (2):

[0104] (2)

[0105] in, Used to represent pixels and adjacent pixels Vertical gradient values ​​between This refers to the vertical gradient value of a pixel within the target coding unit. (x, y) represents the spatial position of the pixel within the target coding unit, and (x+1, y) represents the position of the adjacent pixel that is shifted down one position vertically. It refers to the vertical gradient value of the adjacent pixel that is shifted down by 1 position in the vertical direction.

[0106] S202. Determine the number of rows and columns of the target coding unit based on all the pixels contained in the target coding unit.

[0107] Optionally, all pixels contained in the target coding unit are traversed to determine the number of rows and columns corresponding to the target coding unit. The number of rows is used to describe the distribution of pixels in the target coding unit in the horizontal direction, and the number of columns is used to describe the distribution of pixels in the target coding unit in the vertical direction.

[0108] S203. Determine the total horizontal gradient value of the target coding unit based on the number of rows, the number of columns, and the horizontal gradient values ​​between each pixel and its neighboring pixels.

[0109] Optionally, the total horizontal gradient value of the target coding unit in the horizontal direction is calculated according to the following formula (3):

[0110] (3)

[0111] in, The total horizontal gradient value is used for the target coding unit, where W represents the number of rows in the target coding unit and H represents the number of columns in the target coding unit. Used to represent pixels and adjacent pixels The horizontal gradient value between them.

[0112] S204. Determine the total vertical gradient value of the target coding unit based on the number of rows, the number of columns, and the vertical gradient values ​​between each pixel and its adjacent pixels.

[0113] Optionally, the total vertical gradient value of the target coding unit in the vertical direction is calculated according to the following formula (4):

[0114] (4)

[0115] in, The total vertical gradient value used for the target coding unit, where W represents the number of rows in the target coding unit and H represents the number of columns in the target coding unit. Used to represent pixels and adjacent pixels The vertical gradient value between them.

[0116] S205. Determine the gradient difference of the target coding unit based on the total horizontal gradient value and the total vertical gradient value.

[0117] In one optional implementation, step S205 can specifically be performed as follows:

[0118] Calculate the first ratio between the total horizontal gradient value and the total vertical gradient value;

[0119] Calculate the second ratio between the total vertical gradient value and the total horizontal gradient value;

[0120] The maximum value between the first ratio and the second ratio is taken as the gradient difference of the target coding unit.

[0121] Alternatively, the gradient difference of the target coding unit can be calculated according to the following formula (5):

[0122] (5)

[0123] in, Used to represent the gradient difference of the target coding unit, The total horizontal gradient value used for the target coding unit The total vertical gradient value used for the target coding unit.

[0124] Optionally, when the gradient difference of the target coding unit When the gradient difference of the target coding unit is greater than the intensity of the horizontal pixel value change in the image block, it indicates that the image content of the image block in the target coding unit changes drastically in the horizontal direction; when the gradient difference of the target coding unit is greater than the intensity of the vertical pixel value change in the image block, it indicates that the horizontal pixel value change in the image block in the target coding unit is drastic. When this occurs, it indicates that the intensity of pixel value change in the vertical direction of the image block in the target coding unit is greater than the intensity of pixel value change in the horizontal direction, meaning that the image content of the image block in the target coding unit changes drastically in the vertical direction.

[0125] In one alternative implementation, see [link to implementation details]. Figure 3 The operation of "determining the unit type of the target coding unit based on texture complexity, a first preset threshold, and a second preset threshold" in step S101 above can be specifically as follows:

[0126] S301. Determine whether the gradient difference is greater than the first preset threshold.

[0127] Optionally, the first preset threshold Thrtend is a gradient threshold preset by the user. The first preset threshold is used to measure the gradient difference change between the horizontal and vertical directions of the coding unit. The first preset threshold Thrtend can be 1.5, 2.0, etc., and preferably Thrtend=1.5. This application does not make specific limitations on this.

[0128] S302. If so, then the unit type of the target coding unit is determined to be an obvious texture coding unit.

[0129] Optionally, when the gradient difference between the horizontal and vertical directions of the image block in the target coding unit is greater than a first preset threshold, it is determined that the image content of the image block in the target coding unit is rich, and the target coding unit is a distinct texture coding unit. Then, a distinct texture segmentation process is performed on the target coding unit.

[0130] S303. If not, determine whether the total horizontal gradient value and the total vertical gradient value are both greater than the second preset threshold.

[0131] Optionally, the second preset threshold TH is a gradient threshold preset by the user. The second preset threshold is used to measure the gradient change of the target coding unit in the horizontal direction and the gradient change of the target coding unit in the vertical direction. The second preset threshold can be 10000, 11000, etc., preferably TH=10000. This application does not make specific limitations on this.

[0132] Optionally, when the gradient difference between the horizontal and vertical directions of the image patch in the target coding unit is less than or equal to the first preset threshold, it is further determined whether the total horizontal gradient value of the target coding unit is greater than the second preset threshold and whether the total vertical gradient value of the target coding unit is greater than the second preset threshold, so as to further determine whether the target coding unit is a clear texture coding unit or a non-clear texture coding unit.

[0133] S304. If so, then the unit type of the target coding unit is determined to be an obvious texture coding unit.

[0134] Optionally, when the gradient difference between the horizontal and vertical directions of the image block in the target coding unit is less than or equal to the first preset threshold, but the total horizontal gradient value and the total vertical gradient value of the target coding unit are both greater than the second preset threshold, it is determined that the image content of the image block in the target coding unit is rich, and the target coding unit is a distinct texture coding unit, and a distinct texture segmentation process is performed on the target coding unit.

[0135] S305. If not, then the unit type of the target coding unit is determined to be a coding unit without obvious texture.

[0136] Optionally, when the gradient difference between the horizontal and vertical directions of the image block in the target coding unit is less than or equal to a first preset threshold, and the total horizontal gradient value and the total vertical gradient value of the target coding unit are both less than or equal to a second preset threshold, the image content of the image block in the target coding unit is determined to be flat, and the target coding unit is a coding unit without obvious texture. The process of dividing the target coding unit into parts without obvious texture is then performed.

[0137] Furthermore, the VTM.10 standard algorithm was used to encode the video sequences BasketballDrive, BQTerrace, Johnny, RaceHorses, BQMall, and BQSquare. During the encoding process, the total horizontal gradient value of the coding units was calculated for both the partitioning operation and the non-partitioning operation. Total vertical gradient value Based on the gradient difference, the first preset threshold Thrtend=1.5 and the second preset threshold TH=10000 were determined to be the optimal solution.

[0138] In one alternative implementation, see [link to implementation details]. Figure 4 The target segmentation process is a clear texture segmentation process, and the specific operation of step S103 above can be as follows:

[0139] S401. If the gradient difference is greater than the first preset threshold and the gradient difference is greater than the preset gradient difference threshold, then the target partitioning strategy is determined to be the reverse partitioning strategy. The reverse partitioning strategy includes horizontal partitioning and vertical partitioning.

[0140] Optionally, the preset gradient difference threshold is a gradient threshold preset by the user. The preset gradient difference threshold is used to measure whether the gradient difference of the coding unit is large enough. The preset gradient difference threshold can be 3.0, 5.0, etc., and this application does not make specific limitations on it.

[0141] Optionally, when the gradient difference of the target coding unit is greater than the first preset threshold, and the gradient difference of the target coding unit also exceeds the preset gradient difference threshold, that is, when the gradient difference of the target coding unit is large and the image content of the target coding unit changes drastically in a certain direction, the target partitioning strategy of the target coding unit is determined to be the reverse partitioning strategy.

[0142] Among them, when the gradient difference of the target coding unit When the gradient difference of the target coding unit indicates that the image content of the image block changes drastically in the horizontal direction, the target coding unit needs to be vertically divided; This indicates that the image content of the image block in the target coding unit changes drastically in the vertical direction, and the target coding unit needs to be divided horizontally.

[0143] S402. If the gradient difference is less than or equal to the preset gradient difference threshold, and the total horizontal gradient value and the total vertical gradient value are both greater than the preset total gradient threshold, then the target partitioning strategy is determined to be a quadtree combined with multi-type tree partitioning strategy.

[0144] Optionally, the preset total gradient threshold is a total gradient threshold set by the user. The preset total gradient threshold is used to measure whether the total gradient value in the horizontal direction and the total gradient value in the vertical direction of the coding unit are large enough. The preset total gradient threshold can be 15000, 20000, etc., and this application does not make a specific limitation on it.

[0145] Optionally, when the gradient difference of the target coding unit is less than the preset gradient difference threshold, and the total horizontal gradient value and the total vertical gradient value of the target coding unit both exceed the preset total gradient threshold, that is, the total horizontal gradient value and the total vertical gradient value of the target coding unit are both large, and there are image blocks with complex image content changes inside the target coding unit, then the target partitioning strategy of the target coding unit is determined to be the quadtree joint multi-type tree partitioning strategy.

[0146] In one alternative implementation, see [link to implementation details]. Figure 5 The specific operation of step S402 above can be as follows:

[0147] S501. If the gradient difference is greater than the first preset threshold and the total vertical gradient is greater than the total horizontal gradient, then horizontal binary tree partitioning and horizontal ternary tree partitioning are determined as the target partitioning strategies.

[0148] Optionally, when the gradient difference of the target coding unit Greater than the first preset threshold And the total vertical gradient value of the target coding unit Greater than the total horizontal gradient value of the target coding unit In this case, the horizontal binary tree HBT partition and the horizontal ternary tree HTT partition are used as the target partitioning strategy for the target coding unit.

[0149] S502. If the gradient difference is greater than the first preset threshold and the total vertical gradient is less than the total horizontal gradient, then the vertical binary tree partitioning and the vertical ternary tree partitioning are determined as the target partitioning strategies.

[0150] Optionally, when the gradient difference of the target coding unit Greater than the first preset threshold And the total vertical gradient value of the target coding unit Less than the total horizontal gradient value of the target coding unit In this case, the vertical binary tree (VBT) partition and the vertical ternary tree (VTT) partition are used as the target partitioning strategy for the target coding unit.

[0151] S503. If the gradient difference is less than the first preset threshold, and the maximum value between the total vertical gradient value and the total horizontal gradient value is greater than the second preset threshold, then the quadtree partitioning is determined as the target partitioning strategy.

[0152] Optionally, when the gradient difference of the target coding unit Less than the first preset threshold And the total vertical gradient value of the target coding unit The total horizontal gradient value of the target coding unit If the maximum value in the value is greater than the second preset threshold TH, then the quadtree QT partitioning will be used as the target partitioning strategy for the target coding unit.

[0153] In one optional implementation, the target partitioning process is a partitioning process without obvious texture. Before determining the target partitioning strategy based on the target partitioning process and texture complexity, the process includes:

[0154] The target coding unit is divided into multiple sub-coding blocks, and multiple sub-block search boxes are set up. Each sub-block search box covers a preset area with the adjacent sub-block search boxes.

[0155] It's worth noting that when the image content texture of an image block within a target coding unit is excessively steep, judging whether the target coding unit needs further segmentation as a whole results in a flattened overall image content trend. This can easily lead to the neglect of local texture variations within the target coding unit, resulting in lower segmentation accuracy. This is because when the striped texture within a coding unit is excessively steep, only some areas of the target coding unit exhibit texture fluctuations, while other parts show almost no texture changes. This leads to low overall texture complexity for the target coding unit, potentially causing it to be classified as a coding unit with no obvious texture. Therefore, to avoid neglecting local texture complexity due to the overall texture complexity of the target coding unit, the texture complexity of the entire target coding unit is no longer used as the criterion when performing a segmentation process for units with no obvious texture.

[0156] Furthermore, when performing a textureless partitioning process on a target coding unit that is a textureless coding unit, the entire target coding unit is divided into multiple sub-coding blocks. Based on the logical relationship between the entire target coding unit and the multiple sub-coding blocks, it is determined whether each sub-coding block needs to be partitioned. If a sub-coding block in the target coding unit needs to be partitioned, then the target coding unit containing the sub-coding block also needs to be partitioned.

[0157] Optionally, a sub-coding block refers to a coding block within a target coding unit. The size of the sub-coding block is smaller than the size of the target coding unit. For example, if the size of the target coding unit is 32 bits × 32 bits, the size of the sub-coding block is 8 bits × 8 bits. See [link to relevant documentation]. Figure 6 The 32-bit × 32-bit target coding unit is divided into 16 8-bit × 8-bit sub-coding blocks.

[0158] Optionally, a sub-block search box refers to a detection box that performs texture complexity search on each sub-code block in the target coding unit, and adjacent sub-block search boxes refer to sub-block search boxes that are spatially adjacent to each other. See also... Figure 7 Nine 16-bit × 16-bit sub-block search boxes are set up. Each sub-block search box covers half of the area of ​​the adjacent sub-block search box. Specifically, each sub-block search box covers four 8-bit × 8-bit sub-coded blocks, and adjacent sub-block search boxes cover two 8-bit × 8-bit sub-coded blocks.

[0159] Optionally, the preset area refers to the area where the sub-block search box overlaps with the adjacent sub-block search box. The preset area can be half an area, and this application does not specifically limit it.

[0160] In one alternative implementation, see [link to implementation details]. Figure 8 The specific operation of step S103 above can be as follows:

[0161] S801. Determine the texture change intensity of each pixel based on each pixel in the target coding unit and the associated pixels corresponding to each pixel.

[0162] Alternatively, the texture variation intensity of each pixel in a unit without obvious texture coding can be calculated using the following formula (6):

[0163] (6)

[0164] in, Used to represent pixels The intensity of texture variation, Used to represent the gradient magnitude of a pixel at spatial location (x, y) in a non-texture coding unit. This represents the associated pixel that has been shifted 1 position horizontally to the left and 1 position vertically upward. This represents the associated pixel that has been horizontally shifted one position to the left. This represents the associated pixel that has been shifted 1 position horizontally to the left and 1 position vertically downwards. This indicates the associated pixel that has been vertically shifted upwards by 1 position. This indicates the associated pixel that has been vertically shifted down one position. This represents the associated pixel that has been shifted 1 position horizontally to the right and 1 position vertically upwards. This represents the associated pixel that has been horizontally shifted one position to the right. This represents the associated pixel that has been shifted 1 position horizontally to the right and 1 position vertically downwards.

[0165] S802. Determine the texture complexity of each sub-block search box based on the number of rows and columns of the target coding unit and the texture change intensity of each pixel, and determine the maximum texture complexity from the texture complexity of each sub-block search box.

[0166] Alternatively, the texture complexity of each sub-block search box can be calculated using the following formula (7):

[0167] (7)

[0168] in, The texture complexity is used to represent the sub-block search box numbered (m, n), where (m, n) represents the sub-block search box number. Used to represent pixels The intensity of texture variation.

[0169] Alternatively, the maximum texture complexity without obvious coding units can be calculated using the following formula (8):

[0170] (8)

[0171] in, Used to represent maximum texture complexity The texture complexity used to represent the search box numbered (m, n).

[0172] S803. Determine the target partitioning strategy based on the maximum texture complexity, the third preset threshold, and the fourth preset threshold.

[0173] Optionally, the third preset threshold and the fourth preset threshold are complex texture thresholds preset by the user. The user can set the values ​​of the third preset threshold and the fourth preset threshold according to the division accuracy of no obvious texture coding unit. This application does not make specific limitations on this.

[0174] In one alternative implementation, see [link to implementation details]. Figure 9 The specific operation of step S803 above can be as follows:

[0175] S901. If the maximum texture complexity is less than or equal to the third preset threshold, then the target coding unit is determined to be free from partitioning.

[0176] Optionally, when there is no obvious texture coding unit, the maximum texture complexity Less than or equal to the third preset threshold When there is no obvious texture coding unit, no further partitioning operation is required, that is, the target coding unit is encoded in a 32-bit × 32-bit manner.

[0177] S902. If the maximum texture complexity is greater than the third preset threshold and less than the fourth preset threshold, then the target partitioning strategy is determined to be the standard partitioning strategy.

[0178] Optionally, when there is no obvious texture coding unit, the maximum texture complexity Greater than the third preset threshold And the maximum texture complexity without obvious texture coding units Less than the fourth preset threshold When there are no obvious texture coding units, the VTM partitioning strategy is used for partitioning.

[0179] S903. If the maximum texture complexity is greater than or equal to the fourth preset threshold, then the target partitioning strategy is determined to be the quadtree combined with multi-type tree partitioning strategy.

[0180] Optionally, when there is no obvious texture coding unit, the maximum texture complexity Greater than the fourth preset threshold When the image texture of an image block without a clear texture coding unit is not complex, the quadtree joint multi-type tree partitioning strategy is directly selected based on the maximum texture complexity of the image block without a clear texture coding unit.

[0181] Figure 10 For a texture complexity distribution map of a search box provided in this application, see [link to relevant documentation]. Figure 10 This allows us to determine the texture complexity distribution of each sub-block search box within the target coding unit. Specifically, four 8-bit × 8-bit sub-coding blocks form a 16-bit × 16-bit sub-coding block, which slides in rows and columns at a size of 8 pixels to obtain nine sub-block search boxes, and the texture complexity of the nine sub-search boxes is calculated.

[0182] In one alternative implementation, see [link to implementation details]. Figure 11 The specific operation of step S903 above can be as follows:

[0183] S1101. If the sub-block search box corresponding to the maximum texture complexity is at the vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is greater than the column texture complexity, then horizontal binary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

[0184] Optionally, row texture complexity refers to the sum of texture complexity of the search boxes of each row sub-block in the target coding unit, and column texture complexity refers to the sum of texture complexity of the search boxes of each column sub-block in the target coding unit.

[0185] Optionally, when the maximum texture complexity The corresponding sub-block search box is located at the vertex position of the target encoding unit, i.e., the maximum texture complexity. The corresponding sub-block search box is , , , If any sub-block search box in the target encoding unit has a row texture complexity greater than column texture complexity, then the quadtree QT partitioning and the horizontal binary tree HBT partitioning are used as the target partitioning strategies for that target encoding unit.

[0186] S1102. If the sub-block search box corresponding to the maximum texture complexity is at the vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is less than the column texture complexity, then the vertical binary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

[0187] Optionally, when the maximum texture complexity The corresponding sub-block search box is located at the vertex position of the target encoding unit, i.e., the maximum texture complexity. The corresponding sub-block search box is , , , If any sub-block search box in the target encoding unit has a row texture complexity that is less than the column texture complexity, then the quadtree QT partition and the vertical binary tree VBT partition shall be used as the target partitioning strategy for the target encoding unit.

[0188] S1103. If the sub-block search box corresponding to the maximum texture complexity is at a non-vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is greater than the column texture complexity, then determine the horizontal ternary tree partitioning and quadtree partitioning as the target partitioning strategy.

[0189] Optionally, when the maximum texture complexity The corresponding sub-block search box is located at a non-vertex position of the target encoding unit, i.e., the maximum texture complexity. The corresponding sub-block search box is , , , , If any sub-block search box in the target encoding unit has a row texture complexity greater than column texture complexity, then the quadtree QT partition and the horizontal ternary tree HTT partition shall be used as the target partitioning strategy for the target encoding unit.

[0190] S1104. If the sub-block search box corresponding to the maximum texture complexity is at a non-vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is less than the column texture complexity, then the vertical ternary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

[0191] Optionally, when the maximum texture complexity The corresponding sub-block search box is located at a non-vertex position of the target encoding unit, i.e., the maximum texture complexity. The corresponding sub-block search box is , , , , If any sub-block search box in the target encoding unit has a row texture complexity greater than column texture complexity, then the quadtree QT partition and the vertical ternary tree VTT partition shall be used as the target partitioning strategy for the target encoding unit.

[0192] It is worth noting that the embodiments of this application use statistical methods to determine the third preset threshold. And based on the maximum texture complexity of undivided coding units. Sort the data by QP value, discard the last 10% of each group, and determine the third preset threshold based on the average of the remaining data. When encoding with different QP values, the corresponding third preset threshold is used to determine the maximum texture complexity. .

[0193] Figure 12 A partitioning rate curve of a coding unit provided in this application is shown in the figure. Figure 12 The larger the QP value, the higher the fourth preset threshold at the same SR. The larger the value, the more likely a fourth preset threshold is to be used to achieve the same SR at a larger QP value. Among them, the fourth preset threshold The selection of the fourth preset threshold directly affects the number of times the encoding unit executes the VTM algorithm. To ensure the encoding speed and compression ratio of the encoding unit, the fourth preset threshold is used. The preferred value is 0.85, but this application does not impose a specific limitation on it.

[0194] The encoder and computer-readable storage medium used to implement the coding unit partitioning method based on dual texture complexity provided in this application are described below. The specific implementation process and technical effects are described above and will not be repeated below.

[0195] Figure 13 This is a schematic diagram of the structure of an encoder provided in this application. See also... Figure 13 The encoder 10 includes a control unit 101 and multiple encoding units 102. The control unit 101 stores a computer program corresponding to the encoding unit partitioning method based on dual texture complexity. When the control unit 101 executes the computer program, it makes partitioning decisions for the multiple encoding units 102. The specific implementation process of the control unit 101 executing the computer program is the same as that in the aforementioned embodiments, and will not be described in detail here.

[0196] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, can implement the steps in the various method embodiments described above.

[0197] Optionally, this application also provides a program product, such as a computer-readable storage medium, including a program that, when executed by a processor, performs any of the above-described embodiments of the coding unit partitioning method based on dual texture complexity.

[0198] The integrated units implemented as software functional units described above can be stored in a computer-readable storage medium. These software functional units, stored in a storage medium, include several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) or processor to execute partial steps of the methods of the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0199] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

[0200] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application should be included within the protection scope of this application.

Claims

1. A coding unit partitioning method based on dual texture complexity, characterized in that, When applied to an encoder, the coding unit partitioning method includes: The texture complexity in the target coding unit of the encoder is detected, and the unit type of the target coding unit is determined according to the texture complexity, a first preset threshold and a second preset threshold. The texture complexity includes: total horizontal gradient value, total vertical gradient value and gradient difference. The unit type includes: obvious texture coding unit or no obvious texture coding unit. Based on the unit type of the target coding unit, the target partitioning process of the target coding unit is determined, and the target partitioning process includes: a clear texture partitioning process or a no-clear texture coding partitioning process; Based on the target partitioning process and the texture complexity, a target partitioning strategy is determined, and the target encoding unit is partitioned according to the target partitioning strategy. The target partitioning strategy includes: a reverse partitioning strategy, a quadtree combined with multiple tree types partitioning strategy, or a standard partitioning strategy. The quadtree combined with multiple tree types partitioning strategy includes at least one of the following: quadtree partitioning, horizontal binary tree partitioning, vertical binary tree partitioning, horizontal ternary tree partitioning, and vertical ternary tree partitioning. The target partitioning process is a partitioning process without obvious texture. Before determining the target partitioning strategy based on the target partitioning process and the texture complexity, the process includes: The target encoding unit is divided into multiple sub-encoding blocks, and multiple sub-block search boxes are set up, with each sub-block search box covering a preset area with its adjacent sub-block search box; The step of determining the target partitioning strategy based on the target partitioning process and the texture complexity includes: The texture change intensity of each pixel is determined based on each pixel in the target encoding unit and the associated pixels corresponding to each pixel. Based on the number of rows and columns of the target coding unit and the intensity of texture change of each pixel, the texture complexity of each sub-block search box is determined, and the maximum texture complexity is determined from the texture complexity of each sub-block search box. The target partitioning strategy is determined based on the maximum texture complexity, the third preset threshold, and the fourth preset threshold.

2. The coding unit partitioning method according to claim 1, characterized in that, The detection of texture complexity in the target encoding unit includes: Calculate the horizontal gradient value and vertical gradient value between each pixel in the target coding unit and its neighboring pixels. The neighboring pixels include: neighboring pixels that are horizontally shifted to the right and neighboring pixels that are vertically shifted downward. The number of rows and columns of the target coding unit are determined based on all the pixels contained in the target coding unit. The total horizontal gradient value of the target coding unit is determined based on the number of rows, the number of columns, and the horizontal gradient values ​​between each pixel and its neighboring pixels. The total vertical gradient value of the target coding unit is determined based on the number of rows, the number of columns, and the vertical gradient values ​​between each pixel and its adjacent pixels. The gradient difference of the target coding unit is determined based on the total horizontal gradient value and the total vertical gradient value.

3. The coding unit partitioning method according to claim 2, characterized in that, Determining the gradient difference of the target coding unit based on the total horizontal gradient value and the total vertical gradient value includes: Calculate the first ratio between the total horizontal gradient value and the total vertical gradient value; Calculate the second ratio between the total vertical gradient value and the total horizontal gradient value; The maximum value between the first ratio and the second ratio is taken as the gradient difference of the target coding unit.

4. The coding unit partitioning method according to claim 1, characterized in that, Determining the unit type of the target coding unit based on the texture complexity, the first preset threshold, and the second preset threshold includes: Determine whether the gradient difference is greater than the first preset threshold; If so, then the unit type of the target coding unit is determined to be an obvious texture coding unit; If not, then determine whether the total horizontal gradient value and the total vertical gradient value are both greater than the second preset threshold. If so, then determine that the unit type of the target coding unit is an obvious texture coding unit. If not, then the unit type of the target coding unit is determined to be a coding unit without obvious texture.

5. The coding unit partitioning method according to claim 1, characterized in that, The target partitioning process is a clear texture partitioning process. Based on the target partitioning process and the texture complexity, a target partitioning strategy is determined, including: If the gradient difference is greater than the first preset threshold and the gradient difference is greater than the preset gradient difference threshold, then the target partitioning strategy is determined to be a reverse partitioning strategy, and the reverse partitioning strategy includes: horizontal partitioning and vertical partitioning; If the gradient difference is less than or equal to the preset gradient difference threshold, and both the total horizontal gradient value and the total vertical gradient value are greater than the preset total gradient threshold, then the target partitioning strategy is determined to be a quadtree combined with multi-type tree partitioning strategy.

6. The coding unit partitioning method according to claim 5, characterized in that, If the gradient difference is less than or equal to the preset gradient difference threshold, and both the total horizontal gradient value and the total vertical gradient value are greater than the preset total gradient threshold, then the target partitioning strategy is determined to be a quadtree combined with multiple tree types partitioning strategy, including: If the gradient difference is greater than the first preset threshold and the total vertical gradient value is greater than the total horizontal gradient value, then horizontal binary tree partitioning and horizontal ternary tree partitioning are determined as the target partitioning strategies. If the gradient difference is greater than the first preset threshold and the total vertical gradient value is less than the total horizontal gradient value, then vertical binary tree partitioning and vertical ternary tree partitioning are determined as the target partitioning strategies. If the gradient difference is less than the first preset threshold, and the maximum value between the total vertical gradient value and the total horizontal gradient value is greater than the second preset threshold, then the quadtree partitioning is determined as the target partitioning strategy.

7. The coding unit partitioning method according to claim 1, characterized in that, The step of determining the target partitioning strategy based on the maximum texture complexity, the third preset threshold, and the fourth preset threshold includes: If the maximum texture complexity is less than or equal to the third preset threshold, then it is determined that the target encoding unit does not need to be divided. If the maximum texture complexity is greater than the third preset threshold and the maximum texture complexity is less than the fourth preset threshold, then the target partitioning strategy is determined to be the standard partitioning strategy. If the maximum texture complexity is greater than or equal to the fourth preset threshold, then the target partitioning strategy is determined to be a quadtree combined with multi-type tree partitioning strategy.

8. The coding unit partitioning method according to claim 7, characterized in that, The target partitioning strategy is a quadtree combined with multi-type tree partitioning strategy, including: If the sub-block search box corresponding to the maximum texture complexity is located at the vertex of the target encoding unit, and the row texture complexity of the target encoding unit is greater than the column texture complexity, then horizontal binary tree partitioning and quadtree partitioning are determined as the target partitioning strategies. If the sub-block search box corresponding to the maximum texture complexity is located at the vertex of the target encoding unit, and the row texture complexity of the target encoding unit is less than the column texture complexity, then vertical binary tree partitioning and quadtree partitioning are determined as the target partitioning strategies. If the sub-block search box corresponding to the maximum texture complexity is located at a non-vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is greater than the column texture complexity, then horizontal ternary tree partitioning and quadtree partitioning are determined as the target partitioning strategies. If the sub-block search box corresponding to the maximum texture complexity is located at a non-vertex position of the target encoding unit, and the row texture complexity of the target encoding unit is less than the column texture complexity, then vertical ternary tree partitioning and quadtree partitioning are determined as the target partitioning strategies.

Citation Information

Patent Citations

  • Intra-frame division method and system based on textural features and storage medium

    CN111432212A

  • Fast algorithm suitable for intra-frame prediction division judgment of VVC standard

    CN111818332A

  • Rapid CU division method for VVC of ERP panoramic video and storage medium

    CN117041736A

  • Block division method, block division device, equipment and storage medium

    CN117880516A

  • Image coding method and device, product, equipment and medium

    CN119484824A