A parameter determination method and device, electronic equipment and storage medium

CN116668708BActive Publication Date: 2026-08-07BEIJING DAJIA INTERNET INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJING DAJIA INTERNET INFORMATION TECH CO LTD
Filing Date
2023-05-08
Publication Date
2026-08-07

AI Technical Summary

Technical Problem

[0004]本公开提供一种参数确定方法、装置、电子设备及存储介质,解决了相关技术在确定率失真代价的过程中,不同视频的相关率失真优化参数是固定的,如此可能导致对单个序列不能获得最佳的压缩性能,会影响视频编码无法达到最大压缩效率的技术问题

Benefits of technology

[0030]基于上述任一方面,本公开中,电子设备可以获取待处理视频,并且确定待处理图像对应的多个图像块组;然后电子设备可以基于多个图像块组中每个图像块组包括的初始亮度块以及该每个图像块组包括的色度块,确定待处理视频的纹理特征。之后,电子设备可以基于待处理视频的纹理特征,亮度分量的优化因子以及色度分量的优化因子,确定权重参数。本公开中,由于待处理视频的纹理特征用于表征待处理视频中的亮度分量以及待处理视频中的色度分量之间的不一致程度,而不同视频中亮度分量与色度分量之间的不一致程度可能并不相同。如此,电子设备基于待处理视频的纹理特征,亮度分量的优化因子以及色度分量的优化因子,可以准确、有效地确定出与该待识别视频对应的权重参数。又由于该权重参数用于确定待处理视频在视频编码过程中的率失真代价,进而电子设备可以准确地确定出视频在不同编码模式下的率失真代价,提升视频编码的有效性,能够使得单个序列获得最佳的压缩性能,保证视频编码达到最大压缩效率。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116668708B_ABST
    Figure CN116668708B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a parameter determination method and device, electronic equipment and storage medium, and relates to the technical field of video coding. The method comprises: obtaining a to-be-processed video, the to-be-processed video comprising a to-be-processed image; determining a plurality of image block groups corresponding to the to-be-processed image; determining a texture feature of the to-be-processed video based on an initial luminance block included in each image block group of the plurality of image block groups and a chroma block included in the each image block group; and determining a weight parameter based on the texture feature of the to-be-processed video, an optimization factor of a luminance component and an optimization factor of a chroma component, the weight parameter being used to determine a rate-distortion cost of the to-be-processed video in a video coding process. In the present disclosure, the electronic equipment can accurately determine the rate-distortion cost of the video under different coding modes, thereby improving the effectiveness of video coding.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of video coding technology, and in particular to a parameter determination method, apparatus, electronic device, and storage medium. Background Technology

[0002] Currently, video encoding devices can encode video based on different modes to generate different videos. Furthermore, these devices can determine the rate-distortion cost of the video in different modes based on the encoding distortion and related parameters.

[0003] However, in the process of incurring the aforementioned deterministic rate distortion cost, the correlation rate distortion optimization parameters are fixed for different videos. This may result in the inability to obtain the best compression performance for a single sequence, which will affect the video encoding and prevent it from reaching the maximum compression efficiency. Summary of the Invention

[0004] This disclosure provides a parameter determination method, apparatus, electronic device, and storage medium, which solves the technical problem that in the process of determining rate distortion costs, the correlation rate distortion optimization parameters for different videos are fixed, which may lead to the inability to obtain the best compression performance for a single sequence, thus affecting the video encoding and preventing it from achieving the maximum compression efficiency.

[0005] The technical solution of this disclosure is as follows:

[0006] According to a first aspect of the present disclosure, a parameter determination method is provided. The method may include: acquiring a video to be processed, the video to be processed including an image to be processed; determining a plurality of image block groups corresponding to the image to be processed, wherein an image block group includes an initial luma block and a chroma block; determining texture features of the video to be processed based on the initial luma block included in each of the plurality of image block groups and the chroma block included in each of the image block groups, the texture features of the video to be processed being used to characterize the degree of inconsistency between the luma component and the chroma component in the video to be processed; and determining weight parameters based on the texture features of the video to be processed, optimization factors for the luma component, and optimization factors for the chroma component, the weight parameters being used to determine the rate-distortion cost of the video to be processed during video encoding.

[0007] Optionally, determining the texture features of the video to be processed based on the initial luminance block and the chrominance block included in each of the plurality of image block groups may specifically include: downsampling the initial luminance block included in each image block group to obtain a target luminance block corresponding to each image block group, wherein the size of the target luminance block corresponding to each image block group is the same as the size of the chrominance block included in each image block group; determining the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the chrominance block included in each image block group; determining the texture features of the image to be processed based on the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the chrominance block included in each image block group; and determining the texture features of the video to be processed based on the texture features of the image to be processed.

[0008] Optionally, each image block group includes one luminance block and two chrominance blocks, the two chrominance blocks including a U component chrominance block and a V component chrominance block. The determination of the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the chrominance block included in each image block group may specifically include: determining the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chrominance block included in each image block group, and determining the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chrominance block included in each image block group.

[0009] Optionally, determining the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group may specifically include: determining that the texture features of the image to be processed satisfy the following formula:

[0010]

[0011] Among them, P UV This represents the texture features of the image to be processed, and N represents the number of image patch groups. This represents the similarity between the pixel values ​​of the target luminance block corresponding to the i-th image block group and the pixel values ​​of the U-component chrominance blocks included in the i-th image block group. This represents the similarity between the pixel value of the target luminance block corresponding to the i-th image block group and the pixel value of the V component chrominance block included in the i-th image block group, where i is an integer greater than or equal to 1 and N is an integer greater than or equal to i.

[0012] Optionally, the parameter determination method further includes: obtaining the quantization parameters of the luminance component and the quantization parameters of the chrominance component; determining the optimization factor of the luminance component based on the quantization parameters of the luminance component, and determining the optimization factor of the chrominance component based on the quantization parameters of the chrominance component.

[0013] Optionally, determining the weight parameters based on the texture features, luminance component optimization factor, and chrominance component optimization factor of the video to be processed may specifically include: determining that the weight parameters satisfy the following formula:

[0014]

[0015] Among them, W UV This represents the weight parameter, P. UV λ represents the texture features of the video to be processed. Y The optimization factor, λ, represents the luminance component. UV The optimization factor for the chromaticity component is represented by k, which represents the second parameter, d, which represents the third parameter, and b, which represents the fourth parameter, where k > 0, d > 0, and b > 0.

[0016] According to a second aspect of the present disclosure, a parameter determination apparatus is provided. The apparatus may include an acquisition module and a determination module; the acquisition module is configured to acquire a video to be processed, the video to be processed including an image to be processed; the determination module is configured to determine a plurality of image block groups corresponding to the image to be processed, wherein one image block group includes an initial luminance block and a chrominance block; the determination module is further configured to determine texture features of the video to be processed based on the initial luminance block included in each of the plurality of image block groups and the chrominance block included in each of the image block groups, the texture features of the video to be processed being used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed; the determination module is further configured to determine weight parameters based on the texture features of the video to be processed, optimization factors for the luminance component, and optimization factors for the chrominance component, the weight parameters being used to determine the rate-distortion cost of the video to be processed during the video encoding process.

[0017] Optionally, the parameter determining device further includes a processing module; the processing module is configured to downsample the initial luminance blocks included in each image block group to obtain a target luminance block corresponding to each image block group, the size of the target luminance block corresponding to each image block group being the same as the size of the chrominance blocks included in each image block group; the determining module is specifically configured to determine the similarity between the pixel values ​​of the target luminance blocks corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group; the determining module is further specifically configured to determine the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance blocks corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group; the determining module is further specifically configured to determine the texture features of the video to be processed based on the texture features of the image to be processed.

[0018] Optionally, each image block group includes a luminance block and two chrominance blocks, the two chrominance blocks including a U component chrominance block and a V component chrominance block; the determining module is further specifically configured to determine the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chrominance block included in each image block group, and to determine the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chrominance block included in each image block group.

[0019] Optionally, the determining module is further configured to determine that the texture features of the image to be processed satisfy the following formula:

[0020]

[0021] Among them, P UV This represents the texture features of the image to be processed, and N represents the number of image patch groups. This represents the similarity between the pixel values ​​of the target luminance block corresponding to the i-th image block group and the pixel values ​​of the U-component chrominance blocks included in the i-th image block group. This represents the similarity between the pixel value of the target luminance block corresponding to the i-th image block group and the pixel value of the V component chrominance block included in the i-th image block group, where i is an integer greater than or equal to 1 and N is an integer greater than or equal to i.

[0022] Optionally, the acquisition module is further configured to acquire the quantization parameters of the luminance component and the quantization parameters of the chrominance component; the determination module is further configured to determine the optimization factor of the luminance component based on the quantization parameters of the luminance component, and to determine the optimization factor of the chrominance component based on the quantization parameters of the chrominance component.

[0023] Optionally, the determining module is specifically configured to determine that the weight parameter satisfies the following formula:

[0024]

[0025] Among them, W UV This represents the weight parameter, P. UV λ represents the texture features of the video to be processed. Y The optimization factor, λ, represents the luminance component. UV The optimization factor for the chromaticity component is represented by k, which represents the second parameter, d, which represents the third parameter, and b, which represents the fourth parameter, where k > 0, d > 0, and b > 0.

[0026] According to a third aspect of the present disclosure, an electronic device is provided, which may include: a processor and a memory configured to store processor-executable instructions; wherein the processor is configured to execute the instructions to implement any of the optional parameter determination methods in the first aspect described above.

[0027] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided, on which instructions are stored, such that when the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is able to perform any of the optional parameter determination methods described in the first aspect.

[0028] According to a fifth aspect of the present disclosure, a computer program product is provided, the computer program product including computer instructions that, when executed on a processor of an electronic device, cause the electronic device to perform any of the optional parameter determination methods in the first aspect.

[0029] The technical solutions provided by the embodiments of this disclosure have at least the following beneficial effects:

[0030] Based on any of the above aspects, in this disclosure, the electronic device can acquire a video to be processed and determine multiple image block groups corresponding to the image to be processed; then, the electronic device can determine the texture features of the video to be processed based on the initial luminance block included in each of the multiple image block groups and the chrominance block included in each of the image block groups. Subsequently, the electronic device can determine weight parameters based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component. In this disclosure, since the texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed, and the degree of inconsistency between the luminance component and the chrominance component may be different in different videos, the electronic device can accurately and effectively determine the weight parameters corresponding to the video to be identified based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component. Furthermore, since the weight parameters are used to determine the rate-distortion cost of the video to be processed during the video encoding process, the electronic device can accurately determine the rate-distortion cost of the video under different encoding modes, improve the effectiveness of video encoding, enable a single sequence to obtain optimal compression performance, and ensure that video encoding achieves maximum compression efficiency.

[0031] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description

[0032] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this disclosure and, together with the description, serve to explain the principles of this disclosure, and are not intended to unduly limit this disclosure.

[0033] Figure 1 A flowchart illustrating a parameter determination method provided in an embodiment of this disclosure is shown.

[0034] Figure 2 A flowchart illustrating yet another parameter determination method provided in an embodiment of this disclosure is shown;

[0035] Figure 3 A flowchart illustrating yet another parameter determination method provided in an embodiment of this disclosure is shown;

[0036] Figure 4 A flowchart illustrating yet another parameter determination method provided in an embodiment of this disclosure is shown;

[0037] Figure 5 A flowchart illustrating yet another parameter determination method provided in an embodiment of this disclosure is shown;

[0038] Figure 6 A flowchart illustrating yet another parameter determination method provided in an embodiment of this disclosure is shown;

[0039] Figure 7 A schematic diagram of a parameter determination device provided in an embodiment of this disclosure is shown;

[0040] Figure 8 A schematic diagram of another parameter determination device provided in an embodiment of this disclosure is shown. Detailed Implementation

[0041] To enable those skilled in the art to better understand the technical solutions of this disclosure, the technical solutions in the embodiments of this disclosure will be clearly and completely described below with reference to the accompanying drawings.

[0042] It should be noted that the terms "first," "second," etc., used in the specification, claims, and accompanying drawings of this disclosure are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this disclosure described herein can be implemented in orders other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with this disclosure. Rather, they are merely examples of apparatuses and methods consistent with some aspects of this disclosure as detailed in the appended claims.

[0043] It should also be understood that the term "comprising" indicates the presence of the described feature, whole, step, operation, element and / or component, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements and / or components.

[0044] It should be noted that the user information (including but not limited to user device information, user personal information, user behavior information, etc.) and data (including but not limited to videos to be processed) involved in this disclosure are all information and data authorized by the user or fully authorized by all parties.

[0045] In related technologies, during the determination rate distortion process, the correlation rate distortion optimization parameters are fixed for different videos. This may result in the inability to obtain the best compression performance for a single sequence, which will affect the video encoding and prevent it from reaching the maximum compression efficiency.

[0046] Based on this, embodiments of this disclosure provide a parameter determination method. Since the texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance and chrominance components in the video, and the degree of inconsistency between the luminance and chrominance components may differ in different videos, the electronic device can accurately and effectively determine the weight parameters corresponding to the video to be identified based on the texture features, optimization factors for the luminance components, and optimization factors for the chrominance components. Furthermore, since these weight parameters are used to determine the rate-distortion cost of the video during the video encoding process, the electronic device can accurately determine the rate-distortion cost of the video under different encoding modes, improving the effectiveness of video encoding, enabling a single sequence to achieve optimal compression performance, and ensuring that video encoding reaches maximum compression efficiency.

[0047] The parameter determination method, apparatus, electronic device, and storage medium provided in this disclosure are applied to video encoding scenarios (specifically, scenarios where a better encoding mode is selected from multiple encoding modes). When the electronic device acquires the video to be processed, it can determine the weight parameters according to the method provided in this disclosure. These weight parameters are used to determine the rate-distortion cost of the video to be processed during the video encoding process.

[0048] The parameter determination method provided in the embodiments of this disclosure is illustrated below with reference to the accompanying drawings:

[0049] For example, the electronic device executing the parameter determination method provided in the embodiments of this disclosure can be a mobile phone, tablet computer, desktop computer, laptop computer, handheld computer, notebook computer, ultra-mobile personal computer (UMPC), netbook, as well as cellular phone, personal digital assistant (PDA), augmented reality (AR) / virtual reality (VR) device, etc., which can install and use content community applications. This disclosure does not impose special limitations on the specific form of the electronic device. It can interact with the user through one or more methods such as keyboard, touchpad, touch screen, remote control, voice interaction, or handwriting device.

[0050] Optionally, the aforementioned electronic device may be an independent physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery network (CDN) acceleration services, as well as big data and artificial intelligence platforms.

[0051] like Figure 1 As shown, the parameter determination method provided in this embodiment may include S101-S104.

[0052] S101. Electronic device acquires video to be processed.

[0053] The video to be processed includes the image to be processed.

[0054] It should be understood that electronic devices can perform frame extraction on the video to be processed, resulting in multiple video frames. The image to be processed is one or more of these multiple video frames.

[0055] S102, The electronic device determines multiple image block groups corresponding to the image to be processed.

[0056] One image block group includes an initial luminance block and a chrominance block.

[0057] In one alternative implementation, the electronic device divides the image to be processed into multiple image block groups based on the resolution and a preset size, and can determine the number of these multiple image block groups.

[0058] For example, assuming the resolution of the image to be processed is 1280px (pixels) × 720px, and the above-mentioned preset size is 8px × 8px, the electronic device can determine that the number of the above-mentioned multiple image block groups is 160*90=14400.

[0059] S103. The electronic device determines the texture features of the video to be processed based on the initial luminance block included in each of the multiple image block groups and the chrominance block included in each of the multiple image block groups.

[0060] The texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed.

[0061] Specifically, the electronic device can determine the texture features of the video to be processed based on the pixel values ​​of the initial luminance blocks included in each image block group and the pixel values ​​of the chrominance blocks included in each image block group.

[0062] It should be understood that the texture features of the video to be processed can also characterize the data correlation between color channels in the video. Furthermore, the texture features of the video to be processed can also characterize the differences in texture detail characteristics within the video.

[0063] S104. The electronic device determines the weight parameters based on the texture features, luminance component optimization factor, and chrominance component optimization factor of the video to be processed.

[0064] The weighting parameter is used to determine the rate-distortion cost of the video being processed during the video encoding process.

[0065] It is understood that the optimization factors for the luminance component and the chrominance component mentioned above can be pre-stored in the electronic device or determined (or calculated) by the electronic device.

[0066] The technical solution provided by the above embodiments can bring at least the following beneficial effects: As shown in S101-S104, the electronic device can acquire the video to be processed and determine multiple image block groups corresponding to the image to be processed; then, the electronic device can determine the texture features of the video to be processed based on the initial luminance block included in each of the multiple image block groups and the chrominance block included in each of the image block groups. Afterwards, the electronic device can determine the weight parameters based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component. In this embodiment of the disclosure, since the texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed, and the degree of inconsistency between the luminance component and the chrominance component may be different in different videos, the electronic device can accurately and effectively determine the weight parameters corresponding to the video to be identified based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component. Furthermore, since this weighting parameter is used to determine the rate-distortion cost of the video to be processed during the video encoding process, the electronic device can accurately determine the rate-distortion cost of the video under different encoding modes, improve the effectiveness of video encoding, enable a single sequence to obtain the best compression performance, and ensure that video encoding achieves maximum compression efficiency.

[0067] Combination Figure 1 ,like Figure 2 As shown, in one implementation of this disclosure, the electronic device determines the texture features of the video to be processed based on the initial luminance block included in each of the multiple image block groups and the chrominance block included in each of the multiple image block groups, specifically including S1031-S1034.

[0068] S1031. The electronic device downsamples the initial brightness blocks included in each image block group to obtain the target brightness block corresponding to each image block group.

[0069] The size of the target luminance block corresponding to each image block group is the same as the size of the chrominance block corresponding to each image block group.

[0070] Optionally, each of the above image block groups includes an initial brightness block.

[0071] Referring to the example in S102 above, assuming that the size of the initial luminance block included in each image block group is the same as the preset size (i.e., 8px × 8px), and the storage format of the image to be processed is 420P, then the electronic device determines that the size of the chroma block included in each image group is 4px × 4px. Furthermore, the electronic device downsamples the initial luminance block included in each image block group, and the size of the target luminance block corresponding to each image block group is also 4px × 4px.

[0072] S1032, The electronic device determines the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group.

[0073] Optionally, the electronic device can determine the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group based on methods such as Pearson correlation coefficient, Euclidean distance, cosine similarity, and dot product similarity.

[0074] S1033. The electronic device determines the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group.

[0075] Based on the description of the above embodiments, it should be understood that the texture features of the image to be processed can characterize the degree of inconsistency between the luminance component and the chrominance component in the image to be processed, can also characterize the data correlation between color channels in the image to be processed, and can also characterize the differences in texture detail characteristics in the image to be processed.

[0076] S1034. The electronic device determines the texture features of the video to be processed based on the texture features of the image to be processed.

[0077] In one scenario, when there is only one image to be processed, the electronic device can determine the texture features of that image as the texture features of the video to be processed.

[0078] In another scenario, when the number of images to be processed is more than one (i.e., greater than two), the electronic device can determine the average value of the texture features of the images to be processed and use that average value as the texture features of the video to be processed.

[0079] The technical solution provided by the above embodiments can bring at least the following beneficial effects: As shown in S1031-S1034, the electronic device can downsample the initial luminance blocks included in each image block group to obtain the target luminance block corresponding to each image block group; then the electronic device can determine the similarity between the pixel value of the target luminance block corresponding to each image block group and the chrominance blocks included in each image block group; subsequently, the electronic device can determine the texture features of the image to be processed based on the similarity, and determine the texture features of the image to be processed based on the texture features of the image to be processed. In this embodiment of the present disclosure, the electronic device can determine the texture features of the image to be processed based on the similarity between the pixel value of the target luminance block corresponding to each image block group and the chrominance blocks included in each image block group, and thus determine the texture features of the video to be processed. This allows for convenient and quick determination of the texture features of the video to be processed, thereby improving the efficiency of determining the weight parameters.

[0080] In one implementation of this disclosure, each image block group includes one luminance block and two chrominance blocks, the two chrominance blocks including a U component chrominance block and a V component chrominance block. (Combined with...) Figure 2 ,like Figure 3 As shown, the above-mentioned electronic device determines the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the chrominance block included in each image block group, specifically including S1032a.

[0081] S1032a The electronic device determines the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chromaticity block included in each image block group, and determines the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chromaticity block included in each image block group.

[0082] It should be understood that since each image patch group includes one luminance patch and two chrominance patches, the electronic device can more accurately determine (or characterize) the similarity between the pixel value of the target luminance patch corresponding to each image patch group and the pixel value of a certain chrominance patch (e.g., the U component chrominance patch) in each image patch group, as well as the similarity between the pixel value of the target luminance patch and the pixel value of another chrominance patch (i.e., the V component chrominance patch) in each image patch group. This can improve the accuracy of texture features.

[0083] In one alternative implementation, the electronic device determines the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the U component chrominance blocks included in each image block group, specifically including step A.

[0084] Step A: The electronic device determines that the similarity between the pixel value of the target luminance block corresponding to the i-th image block group and the pixel value of the U component chrominance block included in the i-th image block group satisfies the following formula:

[0085]

[0086] in, Y represents the similarity between the pixel value of the target luminance block corresponding to the i-th image patch group and the pixel value of the U component chrominance block included in the i-th image patch group, where N represents the number of the above multiple image patch groups. i U represents the pixel value of the target brightness block corresponding to the i-th image block group. i This represents the pixel values ​​of the U component chroma blocks included in the i-th image block group. This represents the average pixel value of the target brightness block corresponding to the multiple image block groups. This represents the average pixel value of the U component chromaticity blocks included in the multiple image block groups, where i is an integer greater than or equal to 1, and N is an integer greater than or equal to i.

[0087] Optionally, the electronic device can also determine that the similarity between the pixel value of the target luminance block corresponding to the i-th image block group and the pixel value of the U component chrominance block included in the i-th image block group satisfies the following formula:

[0088]

[0089] in, Y represents the similarity between the pixel value of the target luminance block corresponding to the i-th image patch group and the pixel value of the U component chrominance block included in the i-th image patch group, where N represents the number of the multiple image patch groups, and Y represents the similarity between the pixel value of the target luminance block corresponding to the i-th image patch group and the pixel value of the U component chrominance block included in the i-th image patch group. i U represents the pixel value of the target brightness block corresponding to the i-th image block group. i This represents the pixel values ​​of the U component chroma blocks included in the i-th image block group. This represents the average pixel value of the target brightness block corresponding to the multiple image block groups. σY represents the average pixel value of the U component chromaticity blocks included in the multiple image block groups, σU represents the standard deviation of the pixel values ​​of the target luminance blocks corresponding to the multiple image block groups, and N represents the standard deviation of the pixel values ​​of the U component chromaticity blocks included in the multiple image block groups. i is an integer greater than or equal to 1, and N is an integer greater than or equal to i.

[0090] It should be noted that the specific process by which the electronic device determines the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chrominance block included in each image block group is the same as or similar to the explanation of the above-mentioned electronic device determining the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chrominance block included in each image block group, and will not be repeated here.

[0091] Combination Figure 3 ,like Figure 4 As shown, in one implementation of this disclosure, the electronic device determines the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group, specifically including S1033a.

[0092] S1033a. The electronic device determines that the texture features of the image to be processed satisfy the following formula:

[0093]

[0094] Among them, P UV This represents the texture features of the image to be processed, and N represents the number of image patch groups. This represents the similarity between the pixel values ​​of the target luminance block corresponding to the i-th image block group and the pixel values ​​of the U-component chrominance blocks included in the i-th image block group. This represents the similarity between the pixel value of the target luminance block corresponding to the i-th image block group and the pixel value of the V component chrominance block included in the i-th image block group, where i is an integer greater than or equal to 1 and N is an integer greater than or equal to i.

[0095] The technical solution provided by the above embodiments can bring at least the following beneficial effects: As shown in S1033a, the electronic device can determine the texture features of the image to be processed based on the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chrominance block included in each image block group, and the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chrominance block included in each image block group, combined with a specific formula, thereby accurately and effectively determining the texture features of the image to be processed. Furthermore, the electronic device can accurately and effectively determine the weight parameters.

[0096] Combination Figure 1 ,like Figure 5 As shown, the parameter determination method provided in this embodiment may further include S105-S106.

[0097] S105. The electronic device acquires the quantization parameters of the luminance component and the quantization parameters of the chrominance component.

[0098] It should be understood that the quantization parameter (QP) of the luminance component is used to characterize the compression of the luminance component in spatial detail, while the quantization parameter of the chrominance component is used to characterize the compression of the chrominance component in spatial detail.

[0099] S106. The electronic device determines the optimization factor of the luminance component based on the quantization parameters of the luminance component, and determines the optimization factor of the chrominance component based on the quantization parameters of the chrominance component.

[0100] The technical solutions provided by the above embodiments can bring at least the following beneficial effects: As shown in S105-S106, the electronic device can obtain the quantization parameters of the luminance component and the quantization parameters of the chrominance component; then, the electronic device determines the optimization factor of the luminance component based on the quantization parameters of the luminance component, and determines the optimization factor of the chrominance component based on the quantization parameters of the chrominance component. In this embodiment of the present disclosure, the electronic device can accurately and effectively determine the optimization factor of the luminance component (or chrominance component) based on the quantization parameters of the luminance component (or chrominance component). This allows for the accurate and effective determination of the weighting parameters.

[0101] Combination Figure 1 ,like Figure 6 As shown, in one implementation of this disclosure, the electronic device determines weight parameters based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component, which may specifically include S1041.

[0102] S1041. The weight parameters of electronic devices are determined to satisfy the following formula:

[0103]

[0104] Among them, W UV This represents the weight parameter, P. UV λ represents the texture features of the video to be processed. Y The optimization factor, λ, represents the luminance component. UV The optimization factor for the chromaticity component is represented by k, which represents the second parameter, d, which represents the third parameter, and b, which represents the fourth parameter, where k > 0, d > 0, and b > 0.

[0105] In one alternative implementation, the optimization factor for the luminance component can satisfy the following formula:

[0106]

[0107] Where, λ Y QP represents the optimization factor for the luminance component. Y The quantization parameter represents the luminance component, where 'a' represents the first parameter and 'a > 0'.

[0108] Optionally, once the electronic device obtains one of the optimized parameters for the luminance component and the optimized parameters for the chrominance component, it can also determine the other optimized parameter based on a certain method (or rule).

[0109] Specifically, electronic devices can determine the optimized parameters of the chromaticity components to satisfy the following formula:

[0110] QP UV =QP Y +ΔQP

[0111] Among them, QP UV QP represents the optimization parameters for the chromaticity components. Y The value represents the optimization parameter of the luminance component, ΔQP represents the difference in optimization parameters, and ΔQP is an integer.

[0112] For example, in the H.265 standard, the range of the above-mentioned optimization parameter difference can be [-12, 12].

[0113] The technical solution provided by the above embodiments can bring at least the following beneficial effects: As shown in S1041, the electronic device can determine the weight parameters based on the texture features of the video to be processed, the optimization factor of the luminance component, the optimization factor of the chrominance component, and a specific formula, and can accurately and effectively determine the weight parameters. Furthermore, the electronic device can accurately and effectively determine the rate-distortion cost of the video to be recognized in the video encoding process based on these weight parameters, thereby improving the effectiveness of video encoding.

[0114] In one implementation of this disclosure, the electronic device can determine the rate-distortion cost of the video to be identified during the video encoding process based on a certain encoding mode.

[0115] Specifically, the electronic device can determine that the rate-distortion cost of the video to be identified in this encoding mode satisfies the following formula:

[0116] argminJ=D Y +W UV ×(D U +D V )+λ Y ×R Y +λ UV (R U +R V )

[0117] Where argminJ represents the rate-distortion cost of the video to be identified in this encoding mode, and D Y W represents the encoding distortion of the luminance component in the video to be identified under this encoding mode. UV D represents the aforementioned weighting parameter. UD represents the encoding distortion of the U component in the video to be identified under this encoding mode. V λ represents the encoding distortion of the V component in the video to be identified under this encoding mode. Y R represents the optimization factor for the luminance component. Y λ represents the number of bits consumed when encoding the luminance components in the video to be recognized. UV R represents the optimization factor for the chromaticity components. U R represents the number of bits consumed when encoding the U component in the video to be recognized. V This indicates the number of bits consumed when encoding the V component in the video to be identified.

[0118] It is understood that, in practical implementation, the electronic device described in the embodiments of this disclosure may include one or more hardware structures and / or software modules for implementing the aforementioned corresponding parameter determination method, and these hardware structures and / or software modules may constitute an electronic device. Those skilled in the art should readily recognize that, based on the algorithm steps of the various examples described in conjunction with the embodiments disclosed herein, this disclosure can be implemented in hardware or a combination of hardware and computer software. Whether a function is executed in a hardware or software-driven manner depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this disclosure.

[0119] Based on this understanding, the present disclosure also provides a parameter determination device. Figure 7 A schematic diagram of the parameter determination device provided in an embodiment of this disclosure is shown. Figure 7 As shown, the parameter determining device 10 may include an acquisition module 101 and a determining module 102.

[0120] The acquisition module 101 is configured to acquire a video to be processed, which includes images to be processed.

[0121] The determining module 102 is configured to determine multiple image block groups corresponding to the image to be processed, wherein an image block group includes an initial luminance block and a chrominance block.

[0122] The determining module 102 is further configured to determine the texture features of the video to be processed based on the initial luminance block included in each of the plurality of image block groups and the chrominance block included in each of the image block groups, wherein the texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed.

[0123] The determining module 102 is also configured to determine weight parameters based on the texture features, luminance component optimization factors, and chrominance component optimization factors of the video to be processed. These weight parameters are used to determine the rate-distortion cost of the video to be processed during the video encoding process.

[0124] Optionally, the parameter determining device 10 further includes a processing module 103.

[0125] The processing module 103 is configured to downsample the initial luminance blocks included in each image block group to obtain the target luminance block corresponding to each image block group. The size of the target luminance block corresponding to each image block group is the same as the size of the chrominance blocks included in each image block group.

[0126] The determining module 102 is specifically configured to determine the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group.

[0127] The determining module 102 is further configured to determine the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group.

[0128] The determining module 102 is further configured to determine the texture features of the video to be processed based on the texture features of the image to be processed.

[0129] Optionally, each image block group includes a luminance block and two chrominance blocks, the two chrominance blocks including a U component chrominance block and a V component chrominance block.

[0130] The determining module 102 is further configured to determine the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chrominance block included in each image block group, and to determine the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chrominance block included in each image block group.

[0131] Optionally, the determining module 102 is further configured to determine that the texture features of the image to be processed satisfy the following formula:

[0132]

[0133] Among them, P UV This represents the texture features of the image to be processed, and N represents the number of image patch groups. This represents the similarity between the pixel values ​​of the target luminance block corresponding to the i-th image block group and the pixel values ​​of the U-component chrominance blocks included in the i-th image block group. This represents the similarity between the pixel value of the target luminance block corresponding to the i-th image block group and the pixel value of the V component chrominance block included in the i-th image block group, where i is an integer greater than or equal to 1 and N is an integer greater than or equal to i.

[0134] Optionally, the acquisition module 101 is also configured to acquire the quantization parameters of the luminance component and the quantization parameters of the chrominance component.

[0135] The determining module 102 is also configured to determine the optimization factor of the luminance component based on the quantization parameters of the luminance component, and to determine the optimization factor of the chrominance component based on the quantization parameters of the chrominance component.

[0136] Optionally, the determining module 102 is specifically configured to determine that the weight parameter satisfies the following formula:

[0137]

[0138] Among them, W UV This represents the weight parameter, P. UV λ represents the texture features of the video to be processed. Y The optimization factor, λ, represents the luminance component. UV The optimization factor for the chromaticity component is represented by k, which represents the second parameter, d, which represents the third parameter, and b, which represents the fourth parameter, where k > 0, d > 0, and b > 0.

[0139] As described above, the present disclosure embodiments can divide the parameter determination device into functional modules according to the above method examples. The integrated modules can be implemented in hardware or software. Furthermore, it should be noted that the module division in the present disclosure embodiments is illustrative and only represents one logical functional division; in actual implementation, other division methods may be used. For example, each function can be divided into its own functional modules, or two or more functions can be integrated into one processing module.

[0140] Regarding the parameter determination device in the above embodiments, the specific methods of operation of each module and its beneficial effects have been described in detail in the foregoing method embodiments, and will not be repeated here.

[0141] Figure 8 This is a schematic diagram of another parameter determining device provided in this disclosure. For example... Figure 8 The parameter determination device 20 may include at least one processor 201 and a memory 203 for storing processor-executable instructions. The processor 201 is configured to execute the instructions in the memory 203 to implement the parameter determination method in the above embodiments.

[0142] In addition, the parameter determination device 20 may also include a communication bus 202 and at least one communication interface 204.

[0143] Processor 201 may be a processor (central processing unit, CPU), microprocessor unit, ASIC, or one or more integrated circuits for controlling the execution of programs according to the present disclosure.

[0144] The communication bus 202 may include a path for transmitting information between the aforementioned components.

[0145] Communication interface 204 uses any transceiver-like device for communicating with other devices or communication networks, such as Ethernet, radio access network (RAN), wireless local area networks (WLAN), etc.

[0146] The memory 203 may be a read-only memory (ROM) or other type of static storage device capable of storing static information and instructions, random access memory (RAM) or other type of dynamic storage device capable of storing information and instructions, or electrically erasable programmable read-only memory (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compressed optical discs, laser discs, optical discs, digital versatile optical discs, Blu-ray discs, etc.), magnetic disk storage media or other magnetic storage devices, or any other medium capable of carrying or storing desired program code in the form of instructions or data structures and accessible by a computer, but not limited thereto. The memory may exist independently and be connected to the processing unit via a bus. The memory may also be integrated with the processing unit.

[0147] The memory 203 stores instructions for executing the present invention, and the processor 201 controls the execution of these instructions. The processor 201 executes the instructions stored in the memory 203 to implement the functions of the method disclosed herein.

[0148] In a specific implementation, as one embodiment, the processor 201 may include one or more CPUs, for example... Figure 8 CPU0 and CPU1 in the CPU.

[0149] In a specific implementation, as one example, the parameter determination device 20 may include multiple processors, for example... Figure 8 Processors 201 and 207 are described herein. Each of these processors may be a single-core (single-CPU) processor or a multi-core (multi-CPU) processor. A processor here may refer to one or more devices, circuits, and / or processing cores used to process data (e.g., computer program instructions).

[0150] In a specific implementation, as one embodiment, the parameter determination device 20 may further include an output device 205 and an input device 206. The output device 205 communicates with the processor 201 and can display information in various ways. For example, the output device 205 may be a liquid crystal display (LCD), a light-emitting diode (LED) display device, a cathode ray tube (CRT) display device, or a projector, etc. The input device 206 communicates with the processor 201 and can accept user input in various ways. For example, the input device 206 may be a mouse, keyboard, touchscreen device, or sensing device, etc.

[0151] Those skilled in the art will understand that Figure 8 The structure shown does not constitute a limitation on the parameter determining device 20, and may include more or fewer components than shown, or combine certain components, or use different component arrangements.

[0152] In addition, this disclosure also provides a computer-readable storage medium including instructions that, when executed by a processor of an electronic device, cause the electronic device to perform the parameter determination method provided in the above embodiments.

[0153] In addition, this disclosure also provides a computer program product including instructions that, when executed by a processor of an electronic device, cause the electronic device to perform the parameter determination method provided in the above embodiments.

[0154] Other embodiments of this disclosure will readily occur to those skilled in the art upon consideration of the specification and practice of the invention disclosed herein. This disclosure is intended to cover any variations, uses, or adaptations of this disclosure that follow the general principles of this disclosure and include common knowledge or customary techniques in the art not disclosed herein. The specification and examples are to be considered exemplary only, and the true scope and spirit of this disclosure are indicated by the claims.

Claims

1. A method for determining parameters, characterized in that, include: Acquire the video to be processed, which includes the image to be processed; Determine multiple image block groups corresponding to the image to be processed, wherein an image block group includes an initial luminance block and a chrominance block; Based on the initial luminance block included in each of the plurality of image block groups and the chrominance block included in each of the plurality of image block groups, the texture features of the video to be processed are determined, and the texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed. Based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component, a weight parameter is determined. The weight parameter is used to determine the rate-distortion cost of the video to be processed during the video encoding process. The weighting parameters satisfy the following formula: ; in, This represents the weight parameter. This represents the texture features of the video to be processed. The optimization factor represents the brightness component. The optimization factor for the chromaticity component is represented by k, the second parameter, d, and b, where k > 0, d > 0, and b > 0. The method further includes: Obtain the quantization parameters of the luminance component and the quantization parameters of the chrominance component; The optimization factor of the luminance component is determined based on the quantization parameter of the luminance component, and the optimization factor of the chrominance component is determined based on the quantization parameter of the chrominance component.

2. The parameter determination method according to claim 1, characterized in that, The step of determining the texture features of the video to be processed based on the initial luminance blocks and chrominance blocks included in each of the plurality of image block groups includes: The initial luminance blocks included in each image block group are downsampled to obtain the target luminance block corresponding to each image block group. The size of the target luminance block corresponding to each image block group is the same as the size of the chrominance blocks included in each image block group. Determine the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group; The texture features of the image to be processed are determined based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group. The texture features of the video to be processed are determined based on the texture features of the image to be processed.

3. The parameter determination method according to claim 2, characterized in that, Each image block group includes one luminance block and two chrominance blocks, the two chrominance blocks including a U component chrominance block and a V component chrominance block. Determining the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group includes: The similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the U component chrominance block included in each image block group is determined, and the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the V component chrominance block included in each image block group is also determined.

4. The parameter determination method according to claim 3, characterized in that, The step of determining the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group includes: The texture features of the image to be processed are determined to satisfy the following formula: ; in, This represents the texture features of the image to be processed. This indicates the number of the plurality of image patch groups. Indicating the first of the plurality of image block groups The pixel value of the target brightness block corresponding to the first image block group is the same as the first... The similarity between pixel values ​​of the U component chromaticity blocks included in a group of image patches. Indicates the first The pixel value of the target brightness block corresponding to the first image block group is the same as the first... The similarity between pixel values ​​of the V component chroma blocks included in a group of image patches. For integers greater than or equal to 1 greater than or equal to Integers.

5. A parameter determining device, characterized in that, include: Get the module and determine the module; The acquisition module is configured to acquire a video to be processed, the video to be processed including an image to be processed; The determining module is configured to determine multiple image block groups corresponding to the image to be processed, wherein an image block group includes an initial luminance block and a chrominance block; The determining module is further configured to determine the texture features of the video to be processed based on the initial luminance block included in each of the plurality of image block groups and the chrominance block included in each of the plurality of image block groups, wherein the texture features of the video to be processed are used to characterize the degree of inconsistency between the luminance component and the chrominance component in the video to be processed. The determining module is further configured to determine weight parameters based on the texture features of the video to be processed, the optimization factor of the luminance component, and the optimization factor of the chrominance component. The weight parameters are used to determine the rate-distortion cost of the video to be processed during the video encoding process. The weighting parameters satisfy the following formula: ; in, This represents the weight parameter. This represents the texture features of the video to be processed. An optimization factor representing the luminance component. The optimization factor for the chromaticity component is represented by k, which represents the second parameter, d, which represents the third parameter, and b, which represents the fourth parameter, where k > 0, d > 0, and b > 0. The acquisition module is further configured to acquire the quantization parameters of the luminance component and the quantization parameters of the chrominance component; The determining module is further configured to determine the optimization factor of the luminance component based on the quantization parameters of the luminance component, and to determine the optimization factor of the chrominance component based on the quantization parameters of the chrominance component.

6. The parameter determining device according to claim 5, characterized in that, The parameter determination device further includes a processing module; The processing module is configured to downsample the initial luminance blocks included in each image block group to obtain the target luminance block corresponding to each image block group, wherein the size of the target luminance block corresponding to each image block group is the same as the size of the chrominance blocks included in each image block group. The determining module is specifically configured to determine the similarity between the pixel value of the target luminance block corresponding to each image block group and the pixel value of the chrominance block included in each image block group; The determining module is further specifically configured to determine the texture features of the image to be processed based on the similarity between the pixel values ​​of the target luminance block corresponding to each image block group and the pixel values ​​of the chrominance blocks included in each image block group; The determining module is further configured to determine the texture features of the video to be processed based on the texture features of the image to be processed.

7. An electronic device, characterized in that, The electronic device includes: processor; A memory configured to store processor-executable instructions; The processor is configured to execute the instructions to implement the parameter determination method as described in any one of claims 1-4.

8. A computer-readable storage medium storing instructions thereon, characterized in that, When the instructions in the computer-readable storage medium are executed by the processor of the electronic device, the electronic device is able to perform the parameter determination method as described in any one of claims 1-4.

Citation Information

Patent Citations

  • Rate distortion optimization method and device

    CN104093022A

  • Video processing method and device, storage medium and computer program product

    CN115118982A