A method and device for determining intra-frame prediction mode, electronic device and storage medium
Patent Information
- Application Number
- CN202410675328.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-28
- Publication Date
- 2025-01-24
- Estimated Expiration
- 2044-05-28
Smart Images

Figure CN118250466B_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of computer technology, and in particular to a method and device for determining an intra-frame prediction mode, an electronic device, and a storage medium. Background Art
[0002] High Efficiency Video Coding (HEVC) has become the mainstream of video coding. More and more film and television production, video communication, radio and television broadcasting, etc. are gradually adopting the HEVC video coding standard. For each prediction unit (PU) in HEVC, the luminance component (luma component) of the PU is extracted to obtain the luminance prediction block (PB), and the chrominance component (Cr component or Cb component) of the PU is extracted to obtain the chrominance PB. In the HEVC video coding standard, the luminance PB and chrominance PB corresponding to a PU use a serial algorithm to select the best intra-frame prediction mode, which results in a long overall time consumption, affects the PU coding efficiency, and is not suitable for high frame rate coding scenarios. Summary of the invention
[0003] The present disclosure proposes a technical solution of a method and device for determining an intra-frame prediction mode, an electronic device, and a storage medium.
[0004] According to one aspect of the present disclosure, a method for determining an intra-frame prediction mode is provided, and the method is applied to HEVC. The method includes: for a HEVC current PU, determining a luma candidate intra-frame prediction mode set of a luma PB corresponding to a luma component of the current PU, and determining a first chroma candidate intra-frame prediction mode set of a chroma PB corresponding to a chroma component of the current PU based on the luma candidate intra-frame prediction mode set; determining a rate-distortion cost of the luma PB under each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set, and determining in parallel a rate-distortion cost of the chroma PB under each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set; determining a candidate intra-frame prediction mode with the smallest rate-distortion cost in the luma candidate intra-frame prediction mode set as a target luma intra-frame prediction mode corresponding to the luma PB; and determining a target chroma intra-frame prediction mode corresponding to the chroma PB based on the target luma intra-frame prediction mode and the rate-distortion cost of each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set.
[0005] In a possible implementation, the optional intra-frame prediction modes corresponding to the brightness PB include: a Planar mode, a DC mode, and multiple angle modes; the determination of the brightness candidate intra-frame prediction mode set of the brightness PB corresponding to the brightness component of the current PU includes: determining the SATD cost corresponding to each angle mode in the multiple angle modes, and determining the angle mode with the smallest SATD cost as the target angle mode; based on the Planar mode, the DC mode, and the target angle mode, determine the brightness candidate intra-frame prediction mode set.
[0006] In a possible implementation, determining the first chroma candidate intra-frame prediction mode set of the chroma PB corresponding to the chroma component of the current PU according to the luma candidate intra-frame prediction mode set includes: determining the optional intra-frame prediction mode corresponding to the chroma PB according to the target angle mode; determining the first chroma candidate intra-frame prediction mode set according to the optional intra-frame prediction mode corresponding to the chroma PB.
[0007] In a possible implementation, the target luma intra prediction mode corresponding to the chroma PB is determined based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set, including: determining a second chroma candidate intra prediction mode set of the chroma PB based on the target luma intra prediction mode; determining the target luma intra prediction mode corresponding to the chroma PB based on the second chroma candidate intra prediction mode set of the chroma PB and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set.
[0008] In a possible implementation, the second chroma candidate intra-frame prediction mode set of the chroma PB is determined based on the target luma intra-frame prediction mode, including: determining the optional intra-frame prediction mode corresponding to the chroma PB according to the target angle mode and the target luma intra-frame prediction mode; and determining the second chroma candidate intra-frame prediction mode set according to the optional intra-frame prediction mode corresponding to the chroma PB.
[0009] In a possible implementation, the second chroma candidate intra-frame prediction mode set based on the chroma PB and the rate-distortion cost of each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set determines the target chroma intra-frame prediction mode corresponding to the chroma PB, including: determining the candidate intra-frame prediction mode that is simultaneously in the first chroma candidate intra-frame prediction mode set and the second chroma candidate intra-frame prediction mode set and has the smallest rate-distortion cost as the target chroma intra-frame prediction mode.
[0010] In a possible implementation manner, the method further includes: determining a chroma mode number of the target chroma intra prediction mode based on the target luma intra prediction mode and using a preset encoding method.
[0011] According to one aspect of the present disclosure, an intra-frame prediction mode determination device is provided, the device is applied to HEVC, and the device includes: a candidate intra-frame prediction mode set determination module, which is used to determine, for a HEVC current PU, a luminance candidate intra-frame prediction mode set of a luminance PB corresponding to a luminance component of the current PU, and determine, based on the luminance candidate intra-frame prediction mode set, a first chrominance candidate intra-frame prediction mode set of a chrominance PB corresponding to a chrominance component of the current PU; and a rate-distortion cost determination module, which is used to determine the rate of the luminance PB under each candidate intra-frame prediction mode in the luminance candidate intra-frame prediction mode set. A module for determining a rate-distortion cost of the chroma PB under each candidate intra prediction mode in the first chroma candidate intra prediction mode set, and in parallel; a luma intra prediction mode determination module, for determining the candidate intra prediction mode with the smallest rate-distortion cost in the luma candidate intra prediction mode set as the target luma intra prediction mode corresponding to the luma PB; a chroma intra prediction mode determination module, for determining the target chroma intra prediction mode corresponding to the chroma PB based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set.
[0012] According to one aspect of the present disclosure, an electronic device is provided, comprising: a processor; and a memory for storing processor-executable instructions; wherein the processor is configured to call the instructions stored in the memory to execute the above method.
[0013] According to one aspect of the present disclosure, a computer-readable storage medium is provided, on which computer program instructions are stored, and the computer program instructions implement the above method when executed by a processor.
[0014] In the embodiment of the present disclosure, for the HEVC current PU, after determining the luma candidate intra-frame prediction mode set of the luma PB corresponding to the luma component of the current PU, the first chroma candidate intra-frame prediction mode set of the chroma PB corresponding to the chroma component of the current PU can be determined according to the luma candidate intra-frame prediction mode set, so that when determining the rate-distortion cost of the luma PB under each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set, the rate-distortion cost of the chroma PB under each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set can be determined in parallel, and further, when the rate-distortion cost of the chroma PB in each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set is determined, the rate-distortion cost of the chroma PB in each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set can be determined in parallel. When the candidate intra-frame prediction mode with the smallest distortion cost is determined as the target luminance intra-frame prediction mode corresponding to the luminance PB, since the rate-distortion cost of each candidate intra-frame prediction mode in the first chrominance candidate intra-frame prediction mode set has been determined above, the target chrominance intra-frame prediction mode corresponding to the chrominance PB can be quickly determined based on the target luminance intra-frame prediction mode and the rate-distortion cost of each candidate intra-frame prediction mode in the first chrominance candidate intra-frame prediction mode set. This effectively shortens the total time required to determine the intra-frame prediction mode of the current PU while ensuring the accuracy of the target chrominance intra-frame prediction mode, so that the encoding efficiency of the current PU can be effectively improved.
[0015] It should be understood that the above general description and the following detailed description are exemplary and explanatory only and do not limit the present disclosure. Other features and aspects of the present disclosure will become clear from the following detailed description of exemplary embodiments with reference to the accompanying drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings herein are incorporated into the specification and constitute a part of the specification. These drawings illustrate embodiments consistent with the present disclosure and are used to illustrate the technical solutions of the present disclosure together with the specification.
[0017] Figure 1 A flowchart of a method for determining an intra-frame prediction mode according to an embodiment of the present disclosure is shown.
[0018] Figure 2 A block diagram of a device for determining an intra-frame prediction mode according to an embodiment of the present disclosure is shown.
[0019] Figure 3 A block diagram of an electronic device according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0020] Various exemplary embodiments, features and aspects of the present disclosure will be described in detail below with reference to the accompanying drawings. The same reference numerals in the accompanying drawings represent elements with the same or similar functions. Although various aspects of the embodiments are shown in the accompanying drawings, the drawings are not necessarily drawn to scale unless otherwise specified.
[0021] The word “exemplary” is used exclusively herein to mean “serving as an example, example, or illustration.” Any embodiment described herein as “exemplary” is not necessarily to be construed as preferred or advantageous over other embodiments.
[0022] The term "and / or" herein is only a description of the association relationship of the associated objects, indicating that there may be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the term "at least one" herein represents any combination of at least two of any one or more of a plurality of. For example, including at least one of A, B, and C can represent including any one or more elements selected from the set consisting of A, B, and C.
[0023] In addition, in order to better illustrate the present disclosure, numerous specific details are given in the following specific embodiments. It should be understood by those skilled in the art that the present disclosure can also be implemented without certain specific details. In some examples, methods, means, components and circuits well known to those skilled in the art are not described in detail in order to highlight the subject matter of the present disclosure.
[0024] HEVC video coding standard has become the mainstream of video coding at present, and more and more film and television production, video communication, radio and television broadcasting, etc. are gradually adopting HEVC video coding standard. The characteristic of HEVC video coding is that under the same coding quality, the bit rate is reduced to half of Advanced Video Coding (AVC) video coding, that is, under the same bit rate, the coding quality of HEVC is twice that of AVC.
[0025] HEVC adopts a hybrid coding framework, using intra-frame and inter-frame prediction to eliminate the temporal and spatial redundancy of video frames, using discrete cosine transform and quantization technology to eliminate the frequency domain redundancy of residual pixels, and compressing syntax elements through arithmetic coding. Predictive coding is one of the core technologies in video coding. For video signals, there is a strong spatial correlation between adjacent pixels in an image, and there is also a strong temporal correlation between adjacent images. Therefore, advanced video coding often uses intra-frame prediction and inter-frame prediction, using the coded pixels in the image to predict the adjacent pixels, or using the coded image to predict the image to be coded, thereby effectively removing the correlation between the spatial and temporal domains of the video.
[0026] For each PU in HEVC, the luminance component (luma component) of the PU is extracted to obtain the luminance PB, and the chrominance component (Cr component or Cb component) of the PU is extracted to obtain the chrominance PB. In the HEVC video coding standard, the selection of the best intra-frame prediction mode for the luminance PB and chrominance PB corresponding to a PU adopts a serial algorithm, which results in a long overall time consumption, affects the PU coding efficiency, and is not suitable for high frame rate coding scenarios.
[0027] The embodiment of the present disclosure provides a method for determining an intra-frame prediction mode, which can effectively shorten the total time consumption for determining the intra-frame prediction mode of the current PU, thereby effectively improving the coding efficiency of the current PU. The method for determining an intra-frame prediction mode provided by the embodiment of the present disclosure is described in detail below.
[0028] Figure 1 A flowchart of a method for determining an intra-frame prediction mode according to an embodiment of the present disclosure is shown. The method can be executed by an electronic device such as a terminal device or a server. The terminal device can be a user equipment (UE), a mobile device, a user terminal, a terminal, a cellular phone, a cordless phone, a personal digital assistant (PDA), a handheld device, a computing device, a vehicle-mounted device, a wearable device, etc. The method can be implemented by a processor calling a computer-readable instruction stored in a memory. Alternatively, the method can be executed by a server. Figure 1 As shown, the method includes:
[0029] In step S11, for the HEVC current PU, the luma candidate intra prediction mode set of the luma PB corresponding to the luma component of the current PU is determined, and based on the luma candidate intra prediction mode set, the first chroma candidate intra prediction mode set of the chroma PB corresponding to the chroma component of the current PU is determined.
[0030] HEVC includes 35 intra-frame prediction modes: Planar mode, Direct Current (DC) mode, and 33 angle modes. Among them, angle modes 2 to 17 are horizontal modes, and angle modes 18 to 34 are vertical modes. Table 1 shows the 35 intra-frame prediction modes and their corresponding intra-frame mode numbers.
[0031]
[0032] As shown in Table 1, the intra mode number 0 is used to indicate the Planar mode, the intra mode number 1 is used to indicate the DC mode, and the intra mode numbers 2 to 34 are used to indicate 33 angle modes.
[0033] Intra-frame prediction of the luma component in HEVC supports five PU sizes: 4×4, 8×8, 16×16, 32×32, and 64×64. Therefore, the size of the current PU can be one of the following: 4×4, 8×8, 16×16, 32×32, and 64×64.
[0034] The optional intra prediction modes corresponding to the luma PB in HEVC include the above 35 intra prediction modes. Therefore, the luma mode number can directly use the intra mode number shown in Table 1 above.
[0035] There are five optional intra prediction modes corresponding to chroma PB in HEVC: Planar mode, vertical mode (angle mode 26), horizontal mode (angle mode 10), DC mode, and target brightness intra prediction mode corresponding to brightness PB. Among them, the target brightness intra prediction mode corresponding to brightness PB refers to the best intra prediction mode finally selected for brightness PB from the 35 intra prediction modes shown in Table 1 above.
[0036] In the related art, a serial method is used to determine the best intra-frame prediction mode for luma PB and chroma PB. First, the best luma intra-frame prediction mode corresponding to luma PB is selected from 35 intra-frame prediction modes based on the rate-distortion cost. Then, the most probable mode (MPM) set corresponding to chroma PB is constructed based on the best luma intra-frame prediction mode. Then, the best chroma intra-frame prediction mode corresponding to chroma PB is selected from the MPM set based on the rate-distortion cost. This serial method will result in a long overall time consumption for intra-frame prediction mode selection, affecting the encoding speed, and is not suitable for high frame rate encoding scenarios.
[0037] In order to shorten the time consumption of selecting the best target intra-frame prediction mode, the embodiment of the present disclosure adopts parallelized intra-frame prediction mode selection. First, in the first stage, a luma candidate intra-frame prediction mode set including a small number of candidate intra-frame prediction modes is preliminarily screened out for luma PB from 35 intra-frame prediction modes. Since the final target luma intra-frame prediction mode of luma PB is one of the luma candidate intra-frame prediction mode set, the first chroma candidate intra-frame prediction mode set of chroma PB can be preliminarily constructed based on the luma candidate intra-frame prediction mode set.
[0038] The following text will describe in detail how to determine the luma candidate intra-frame prediction mode set for luma PB and how to determine the first chroma candidate intra-frame prediction mode set for chroma PB based on the luma candidate intra-frame prediction mode set in combination with possible implementation methods of the present disclosure, which will not be repeated here.
[0039] In step S12, the rate-distortion cost of luma PB in each candidate intra prediction mode in the luma candidate intra prediction mode set is determined, and the rate-distortion cost of chroma PB in each candidate intra prediction mode in the first chroma candidate intra prediction mode set is determined in parallel.
[0040] Since the luma candidate intra prediction mode set of the luma PB and the first chroma candidate intra prediction mode set of the chroma PB are determined in the first stage, the rate-distortion cost of the chroma PB can be calculated in parallel with the rate-distortion cost of the luma PB to screen the best luma intra prediction mode in the second stage, without waiting for the best luma intra prediction mode to be determined before calculating the rate-distortion cost of the chroma PB to screen the best chroma intra prediction mode, thereby effectively shortening the time consumption.
[0041] In one example, after determining the rate-distortion cost of chroma PB under each candidate intra-prediction mode in the first chroma candidate intra-prediction mode set, the rate-distortion cost of each candidate intra-prediction mode in the first chroma candidate intra-prediction mode set is stored for subsequent screening of the best chroma intra-prediction mode based on the rate-distortion cost.
[0042] In step S13, the candidate intra-frame prediction mode with the minimum rate-distortion cost in the luma candidate intra-frame prediction mode set is determined as the target luma intra-frame prediction mode corresponding to the luma PB.
[0043] In the above-mentioned second stage, after determining the rate-distortion cost of luma PB under each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set, in the third stage, the candidate intra-frame prediction mode with the smallest rate-distortion cost in the luma candidate intra-frame prediction mode set can be directly determined as the optimal intra-frame prediction mode corresponding to luma PB, that is, the target luma intra-frame prediction mode.
[0044] In step S14, a target chroma intra prediction mode corresponding to the chroma PB is determined based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set.
[0045] After the target luma intra-frame prediction mode is determined in the third stage, since the optional intra-frame prediction mode of chroma PB depends on the target luma intra-frame prediction mode, based on the target luma intra-frame prediction mode and the rate-distortion cost of each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set stored in the second stage, the optimal chroma intra-frame prediction mode corresponding to chroma PB, that is, the target chroma intra-frame prediction mode, can be determined.
[0046] The following text will describe in detail how to determine the target chroma intra-frame prediction mode corresponding to the chroma PB based on the target luminance intra-frame prediction mode and the rate-distortion cost of each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set, in combination with possible implementation methods of the embodiments of the present disclosure, which will not be elaborated here.
[0047] In the embodiment of the present disclosure, for the HEVC current PU, after determining the luma candidate intra-frame prediction mode set of the luma PB corresponding to the luma component of the current PU, the first chroma candidate intra-frame prediction mode set of the chroma PB corresponding to the chroma component of the current PU can be determined according to the luma candidate intra-frame prediction mode set, so that when determining the rate-distortion cost of the luma PB under each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set, the rate-distortion cost of the luma PB under each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set can be determined in parallel, and further, when the rate-distortion cost of the luma PB in each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set is determined, the rate-distortion cost of the luma PB in each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set can be determined in parallel. When the candidate intra-frame prediction mode with the smallest distortion cost is determined as the target luminance intra-frame prediction mode corresponding to the luminance PB, since the rate-distortion cost of each candidate intra-frame prediction mode in the first chrominance candidate intra-frame prediction mode set has been determined above, the target chrominance intra-frame prediction mode corresponding to the chrominance PB can be quickly determined based on the target luminance intra-frame prediction mode and the rate-distortion cost of each candidate intra-frame prediction mode in the first chrominance candidate intra-frame prediction mode set. This effectively shortens the total time required to determine the intra-frame prediction mode of the current PU while ensuring the accuracy of the target chrominance intra-frame prediction mode, so that the encoding efficiency of the current PU can be effectively improved.
[0048] In a possible implementation, the optional intra-frame prediction modes corresponding to the luma PB include: a Planar mode, a DC mode, and multiple angle modes; determining a set of luma candidate intra-frame prediction modes of the luma PB corresponding to the luma component of the current PU, including: determining a sum of absolute transformed differences (SATD) cost corresponding to each angle mode in the multiple angle modes, and determining the angle mode with the smallest SATD cost as the target angle mode; determining a set of luma candidate intra-frame prediction modes based on the Planar mode, the DC mode, and the target angle mode.
[0049] For various angle modes of the intra-frame prediction mode (for example, the 33 angle modes shown in Table 1 above), the SATD cost of the luminance PB in each angle mode is calculated, and the angle mode with the smallest SATD cost is selected as the target angle mode, thereby determining the Planar mode, DC mode, and target angle mode as the luminance candidate intra-frame prediction mode set that only includes three candidate intra-frame prediction modes selected for the luminance PB in the first stage.
[0050] Compared with calculating the rate-distortion cost for all 35 intra-frame prediction modes to determine the target brightness intra-frame prediction mode, since a brightness candidate intra-frame prediction mode set including only three candidate intra-frame prediction modes is screened out from the 35 intra-frame prediction modes, it is only necessary to calculate the rate-distortion cost for the three candidate intra-frame prediction modes to determine the target brightness intra-frame prediction mode, thereby effectively shortening the time for determining the target brightness intra-frame prediction mode for the brightness PB.
[0051] The method of determining the SATD cost of the brightness PB in each angle mode may refer to the SATD algorithm in the related art, and the present disclosure does not make any specific limitation on this.
[0052] In one possible implementation, a first chroma candidate intra-frame prediction mode set of the chroma PB corresponding to the chroma component of the current PU is determined based on the luma candidate intra-frame prediction mode set, including: determining an optional intra-frame prediction mode corresponding to the chroma PB based on the target angle mode; and determining a first chroma candidate intra-frame prediction mode set based on the optional intra-frame prediction mode corresponding to the chroma PB.
[0053] According to the HEVC coding rules, there are five optional intra-frame prediction modes corresponding to chroma PB in HEVC: Planar mode, angle mode 26, angle mode 10, DC mode, and target luminance intra-frame prediction mode corresponding to luminance PB. Therefore, different first chroma candidate intra-frame prediction mode sets can be obtained according to whether the target angle mode corresponding to the luminance PB is the same as the optional intra-frame prediction mode: angle mode 26 / 10.
[0054] In an example, when the target angle mode is angle mode 10 or angle mode 26 , determining the first chroma candidate intra prediction mode set includes: Planar mode, DC mode, angle mode 26 , angle mode 10 , and angle mode 34 .
[0055] When the target angle mode is angle mode 10 or angle mode 26, the target luminance intra-frame prediction mode can only be one of the Planar mode, DC mode, and angle mode 10 / 26. That is to say, the fifth optional intra-frame prediction mode corresponding to the chroma PB is one of the first four optional intra-frame prediction modes. At this time, it can be replaced by angle mode 34. That is, the first chroma candidate intra-frame prediction mode set of chroma PB includes: Planar mode, angle mode 26, angle mode 10, DC mode, and angle mode 34.
[0056] In an example, when the target angle mode is neither angle mode 10 nor angle mode 26, determining the first chroma candidate intra prediction mode set includes: Planar mode, DC mode, angle mode 26, angle mode 10, and target angle mode.
[0057] When the target angle mode is neither angle mode 10 nor angle mode 26, that is, the fifth optional intra-frame prediction mode corresponding to the chroma PB may not be one of the first four optional intra-frame prediction modes. At this time, the first chroma candidate intra-frame prediction mode set of chroma PB includes: Planar mode, angle mode 26, angle mode 10, DC mode, and target angle mode.
[0058] Based on the above approach, when the target luma intra prediction mode is not determined, the first chroma candidate intra prediction mode set for the chroma PB can be determined in advance, so as to prepare for the subsequent second stage parallel calculation of the rate-distortion cost of the luma PB and the chroma PB.
[0059] After determining the target luma intra prediction mode corresponding to luma PB based on the rate-distortion cost, the target luma intra prediction mode corresponding to chroma PB can be determined based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set.
[0060] In one possible implementation, based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set, the target luma intra prediction mode corresponding to the chroma PB is determined, including: determining a second chroma candidate intra prediction mode set for the chroma PB based on the target luma intra prediction mode; determining the target luma intra prediction mode corresponding to the chroma PB based on the second chroma candidate intra prediction mode set for the chroma PB and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set.
[0061] Based on the target luminance intra-frame prediction mode, the second chrominance candidate intra-frame prediction mode set of chrominance PB can be determined. The second chrominance candidate intra-frame prediction mode set includes the truly optional intra-frame prediction modes of chrominance PB, that is, the above-mentioned MPM set, which is more accurate than the first chrominance candidate intra-frame prediction mode set.
[0062] In one possible implementation, a second chroma candidate intra-frame prediction mode set of chroma PB is determined based on the target luma intra-frame prediction mode, including: determining an optional intra-frame prediction mode corresponding to the chroma PB according to the target angle mode and the target luma intra-frame prediction mode; and determining a second chroma candidate intra-frame prediction mode set according to the optional intra-frame prediction mode corresponding to the chroma PB.
[0063] According to the HEVC coding rules, there are five optional intra-frame prediction modes corresponding to chroma PB in HEVC: Planar mode, angle mode 26, angle mode 10, DC mode, and target brightness intra-frame prediction mode corresponding to brightness PB. Therefore, different second chroma candidate intra-frame prediction mode sets can be obtained according to whether the target angle mode corresponding to brightness PB is the same as the optional intra-frame prediction mode: angle mode 26 / 10, and whether the final target brightness intra-frame prediction mode is the same as the target angle mode.
[0064] In an example, when the target angle mode is angle mode 10 or angle mode 26 , determining the second chroma candidate intra prediction mode set includes: Planar mode, DC mode, angle mode 26 , angle mode 10 , and angle mode 34 .
[0065] When the target angle mode is angle mode 10 or angle mode 26, the target luma intra prediction mode can only be one of Planar mode, DC mode, and angle mode 10 / 26, that is, the fifth optional intra prediction mode corresponding to chroma PB is one of the first four optional intra prediction modes, and at this time, it can be replaced by angle mode 34, that is, the second chroma candidate intra prediction mode set of chroma PB includes: Planar mode, DC mode, angle mode 26, angle mode 10, and angle mode 34. In this case, the second chroma candidate intra prediction mode set is the same as the first chroma candidate intra prediction mode set.
[0066] In one example, when the target angle mode is neither angle mode 10 nor angle mode 26, and the target luminance intra-frame prediction mode is Planar mode or DC mode, the second chrominance candidate intra-frame prediction mode set is determined to include: Planar mode, DC mode, angle mode 26, angle mode 10, and mode 34.
[0067] When the target angle mode is neither angle mode 10 nor angle mode 26, and the target luma intra prediction mode is Planar mode or DC mode, the fifth optional intra prediction mode corresponding to the chroma PB is also one of the first four optional intra prediction modes, and in this case, it can be replaced by angle mode 34, that is, the second chroma candidate intra prediction mode set of the chroma PB includes: Planar mode, DC mode, angle mode 26, angle mode 10, mode 34. In this case, the second chroma candidate intra prediction mode set is the same as the first chroma candidate intra prediction mode set.
[0068] In one example, when the target angle mode is neither angle mode 10 nor angle mode 26, and the target luminance intra-frame prediction mode is the target angle mode, the second chrominance candidate intra-frame prediction mode set is determined to include: Planar mode, DC mode, angle mode 26, angle mode 10, and target angle mode.
[0069] When the target angle mode is neither angle mode 10 nor angle mode 26, and the target luma intra prediction mode is the target angle mode, the fifth optional intra prediction mode corresponding to the chroma PB is not one of the first four optional intra prediction modes. At this time, the second chroma candidate intra prediction mode set of the chroma PB includes: Planar mode, angle mode 26, angle mode 10, DC mode, and target angle mode. In this case, the second chroma candidate intra prediction mode set is different from the first chroma candidate intra prediction mode set.
[0070] In one possible implementation, a target chroma intra prediction mode corresponding to the chroma PB is determined based on the second chroma candidate intra prediction mode set of the chroma PB and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set, including: determining the candidate intra prediction mode that is in both the first chroma candidate intra prediction mode set and the second chroma candidate intra prediction mode set and has the smallest rate-distortion cost as the target chroma intra prediction mode.
[0071] Since the second chroma candidate intra-frame prediction mode set includes the truly optional intra-frame prediction modes of chroma PB, the candidate intra-frame prediction mode that is in both the first chroma candidate intra-frame prediction mode set and the second chroma candidate intra-frame prediction mode set and has the lowest rate-distortion cost is the optimal chroma intra-frame prediction mode corresponding to chroma PB, that is, the target chroma intra-frame prediction mode.
[0072] In one example, five candidate intra prediction modes in a first chroma candidate intra prediction mode set are sorted from small to large based on rate-distortion cost; then, whether the candidate intra prediction mode is in a second chroma candidate intra prediction mode set is determined from small to large according to the rate-distortion cost, until a target chroma intra prediction mode is selected that is in both the first chroma candidate intra prediction mode set and the second chroma candidate intra prediction mode set and has the smallest rate-distortion cost.
[0073] For example, the first chroma candidate intra prediction mode set includes: Planar mode, angle mode 26, angle mode 10, DC mode, target luma intra prediction mode (non-angle mode 26 and non-angle mode 10); the second chroma candidate intra prediction mode set includes: Planar mode, angle mode 26, angle mode 10, DC mode, angle mode 34. The five candidate intra prediction modes included in the first chroma candidate intra prediction mode set are sorted from small to large according to rate-distortion cost: target luma intra prediction mode, angle mode 26, angle mode 10, Planar mode, DC mode. First, the target luma intra prediction mode with the smallest rate-distortion cost is judged, and it is determined that the target luma intra prediction mode with the smallest rate-distortion cost is not in the second chroma candidate intra prediction mode set; further, the angle mode 26 with the second smallest rate-distortion cost is judged, and it is determined that the angle mode 26 with the second smallest rate-distortion cost is in the second chroma candidate intra prediction mode set, so the angle mode 26 is determined as the target chroma intra prediction mode.
[0074] In a possible implementation, the method further includes: determining a chroma mode number of a target chroma intra prediction mode based on the target luma intra prediction mode and using a preset encoding method.
[0075] In order to facilitate rapid execution of subsequent encoding processing based on the target chroma intra prediction mode, the chroma mode number of the target chroma intra prediction mode is determined based on the target luma intra prediction mode using a preset encoding method.
[0076] In an example, when the target luma intra prediction mode is not Planar mode, DC mode, angle mode 26, or angle mode 10, the five optional intra prediction modes corresponding to the chroma PB may be numbered according to Table 2 below.
[0077]
[0078] As shown in Table 2, when the target luminance intra prediction mode is not Planar mode, DC mode, angle mode 26, or angle mode 10, and the target chrominance intra prediction mode is DC mode, the chrominance mode number of the target chrominance intra prediction mode is determined to be mode 3; when the target luminance intra prediction mode is not Planar mode, DC mode, angle mode 26, or angle mode 10, and the target chrominance intra prediction mode is angle mode 26, the chrominance mode number of the target chrominance intra prediction mode is determined to be mode 1; and so on.
[0079] In one example, when the target luma intra prediction mode is one of Planar mode, DC mode, angle mode 26, and angle mode 10, and the target chroma intra prediction mode is the same as the target luma intra prediction mode, the chroma mode number of the target chroma intra prediction mode is directly determined to be mode 4.
[0080] In one example, when the target luminance intra prediction mode is one of Planar mode, DC mode, angle mode 26, and angle mode 10, but the target chrominance intra prediction mode is different from the target luminance intra prediction mode, the target chrominance intra prediction mode corresponding to the chrominance PB can be numbered according to the following Table 3.
[0081]
[0082] As shown in Table 3, when the target luma intra prediction mode is Planar mode and the target chroma intra prediction mode is DC mode, the chroma mode number of the target chroma intra prediction mode is determined to be mode 3; when the target luma intra prediction mode is angle mode 26 and the target chroma intra prediction mode is angle mode 10, the chroma mode number of the target chroma intra prediction mode is determined to be mode 2; and so on.
[0083] The luma mode number of the target luma intra prediction mode is determined based on the above Table 1. When the encoding module subsequently performs encoding processing on the current PU, it can quickly determine the target luma intra prediction mode corresponding to the luma PB based on the luma mode number, and quickly determine the target chroma intra prediction mode corresponding to the chroma PB based on the chroma mode number, thereby quickly completing the intra encoding of the luma PB and the chroma PB.
[0084] In the embodiment of the present disclosure, for the HEVC current PU, after determining the luma candidate intra-frame prediction mode set of the luma PB corresponding to the luma component of the current PU, the first chroma candidate intra-frame prediction mode set of the chroma PB corresponding to the chroma component of the current PU can be determined according to the luma candidate intra-frame prediction mode set, so that when determining the rate-distortion cost of the luma PB under each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set, the rate-distortion cost of the chroma PB under each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set can be determined in parallel, and further, when the rate-distortion cost of the chroma PB in each candidate intra-frame prediction mode in the luma candidate intra-frame prediction mode set is determined, the rate-distortion cost of the chroma PB in each candidate intra-frame prediction mode in the first chroma candidate intra-frame prediction mode set can be determined in parallel. When the candidate intra-frame prediction mode with the smallest distortion cost is determined as the target luminance intra-frame prediction mode corresponding to the luminance PB, since the rate-distortion cost of each candidate intra-frame prediction mode in the first chrominance candidate intra-frame prediction mode set has been determined above, the target chrominance intra-frame prediction mode corresponding to the chrominance PB can be quickly determined based on the target luminance intra-frame prediction mode and the rate-distortion cost of each candidate intra-frame prediction mode in the first chrominance candidate intra-frame prediction mode set. This effectively shortens the total time required to determine the intra-frame prediction mode of the current PU while ensuring the accuracy of the target chrominance intra-frame prediction mode, so that the encoding efficiency of the current PU can be effectively improved.
[0085] It can be understood that the above-mentioned various method embodiments mentioned in the present disclosure can be combined with each other to form a combined embodiment without violating the principle logic. Due to space limitations, the present disclosure will not repeat them. It can be understood by those skilled in the art that in the above-mentioned method of the specific implementation method, the specific execution order of each step should be determined according to its function and possible internal logic.
[0086] In addition, the present disclosure also provides an intra-frame prediction mode determination device, an electronic device, a computer-readable storage medium, and a program, all of which can be used to implement any intra-frame prediction mode determination method provided by the present disclosure. The corresponding technical solutions and descriptions are referred to the corresponding records in the method part and will not be repeated here.
[0087] Figure 2 FIG. 2 is a block diagram of a device for determining an intra-frame prediction mode according to an embodiment of the present disclosure. Figure 2 As shown, the device 20 includes:
[0088] The candidate intra prediction mode set determination module 21 is used to determine, for the HEVC current PU, a luma candidate intra prediction mode set of a luma PB corresponding to the luma component of the current PU, and determine, based on the luma candidate intra prediction mode set, a first chroma candidate intra prediction mode set of a chroma PB corresponding to the chroma component of the current PU;
[0089] a rate-distortion cost determination module 22, configured to determine a rate-distortion cost of a luma PB in each candidate intra-prediction mode in a luma candidate intra-prediction mode set, and to determine a rate-distortion cost of a chroma PB in each candidate intra-prediction mode in a first chroma candidate intra-prediction mode set in parallel;
[0090] The luma intra prediction mode determination module 23 is used to determine the candidate intra prediction mode with the smallest rate-distortion cost in the luma candidate intra prediction mode set as the target luma intra prediction mode corresponding to the luma PB;
[0091] The chroma intra prediction mode determination module 24 is used to determine a target chroma intra prediction mode corresponding to the chroma PB based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set.
[0092] In a possible implementation, the optional intra-frame prediction modes corresponding to the brightness PB include: Planar mode, DC mode, and multiple angle modes;
[0093] The candidate intra prediction mode set determination module is specifically used for:
[0094] Determine the SATD cost corresponding to each angle mode among the multiple angle modes, and determine the angle mode with the minimum SATD cost as the target angle mode;
[0095] Based on the Planar mode, DC mode, and target angle mode, a set of luminance candidate intra prediction modes is determined.
[0096] In a possible implementation, the candidate intra prediction mode set determination module is specifically configured to:
[0097] According to the target angle mode, determine the optional intra-frame prediction mode corresponding to the chroma PB;
[0098] According to the optional intra prediction mode corresponding to the chroma PB, a first chroma candidate intra prediction mode set is determined.
[0099] In a possible implementation, the chrominance intra-frame prediction mode determination module 24 is specifically configured to:
[0100] Determine a second chroma candidate intra prediction mode set for chroma PB based on the target luma intra prediction mode;
[0101] Based on the second chroma candidate intra prediction mode set of the chroma PB and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set, a target luma intra prediction mode corresponding to the chroma PB is determined.
[0102] In a possible implementation, the chrominance intra-frame prediction mode determination module 24 is specifically configured to:
[0103] Determine the optional intra-frame prediction mode corresponding to the chrominance PB according to the target angle mode and the target brightness intra-frame prediction mode;
[0104] According to the optional intra prediction mode corresponding to the chroma PB, a second chroma candidate intra prediction mode set is determined.
[0105] In a possible implementation, the chrominance intra-frame prediction mode determination module 24 is specifically configured to:
[0106] A candidate intra prediction mode that is in both the first chroma candidate intra prediction mode set and the second chroma candidate intra prediction mode set and has the smallest rate-distortion cost is determined as a target chroma intra prediction mode.
[0107] In a possible implementation, the apparatus 20 further includes:
[0108] The encoding module is used to determine the chroma mode number of the target chroma intra-frame prediction mode based on the target luminance intra-frame prediction mode and using a preset encoding method.
[0109] This method has a specific technical connection with the internal structure of the computer system, and can solve the technical problem of how to improve the hardware computing efficiency or execution effect (including reducing the amount of data storage, reducing the amount of data transmission, increasing the hardware processing speed, etc.), thereby obtaining the technical effect of improving the internal performance of the computer system in accordance with the laws of nature.
[0110] In some embodiments, the functions or modules included in the device provided by the embodiments of the present disclosure can be used to execute the method described in the above method embodiments. The specific implementation can refer to the description of the above method embodiments, and for the sake of brevity, it will not be repeated here.
[0111] The embodiment of the present disclosure also provides a computer-readable storage medium on which computer program instructions are stored, and the computer program instructions implement the above method when executed by a processor. The computer-readable storage medium can be a volatile or non-volatile computer-readable storage medium.
[0112] An embodiment of the present disclosure further proposes an electronic device, comprising: a processor; and a memory for storing instructions executable by the processor; wherein the processor is configured to call the instructions stored in the memory to execute the above method.
[0113] The embodiments of the present disclosure also provide a computer program product, including a computer-readable code, or a non-volatile computer-readable storage medium carrying the computer-readable code. When the computer-readable code runs in a processor of an electronic device, the processor in the electronic device executes the above method.
[0114] The electronic device may be provided as a terminal, a server, or a device in other forms.
[0115] Figure 3 A block diagram of an electronic device according to an embodiment of the present disclosure is shown. Figure 3 , the electronic device 1900 can be provided as a server or a terminal device. Figure 3 , the electronic device 1900 includes a processing component 1922, which further includes one or more processors, and a memory resource represented by a memory 1932 for storing instructions executable by the processing component 1922, such as an application. The application stored in the memory 1932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 1922 is configured to execute instructions to perform the above method.
[0116] The electronic device 1900 may also include a power supply component 1926 configured to perform power management of the electronic device 1900, a wired or wireless network interface 1950 configured to connect the electronic device 1900 to a network, and an input / output interface 1958. The electronic device 1900 may operate based on an operating system stored in the memory 1932, such as a Microsoft Server operating system (Windows Server 2003). TM ), Apple's graphical user interface operating system (Mac OS X TM ), a multi-user, multi-process computer operating system (Unix TM ), a free and open source Unix-like operating system (Linux TM ), an open source Unix-like operating system (FreeBSD TM ) or similar.
[0117] In an exemplary embodiment, a non-volatile computer-readable storage medium is also provided, such as a memory 1932 including computer program instructions, which can be executed by the processing component 1922 of the electronic device 1900 to perform the above method.
[0118] The present disclosure may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present disclosure.
[0119] Computer-readable storage media can be a tangible device that can hold and store instructions used by an instruction execution device. Computer-readable storage media can be, for example, (but not limited to) an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination thereof. More specific examples (non-exhaustive lists) of computer-readable storage media include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, for example, a punch card or a convex structure in a groove on which instructions are stored, and any suitable combination thereof. The computer-readable storage media used here is not interpreted as a transient signal itself, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagated by a waveguide or other transmission medium (for example, a light pulse by an optical fiber cable), or an electrical signal transmitted by a wire.
[0120] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0121] The computer program instructions for performing the operations of the present disclosure may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-dependent instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. The computer-readable program instructions may be executed entirely on the user's computer, partially on the user's computer, as a separate software package, partially on the user's computer, partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect through the Internet). In some embodiments, by using the state information of the computer-readable program instructions to personalize an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), the electronic circuit may execute the computer-readable program instructions, thereby implementing various aspects of the present disclosure.
[0122] Various aspects of the present disclosure are described herein with reference to flowcharts and / or block diagrams of methods, devices (systems) and computer program products according to embodiments of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of boxes in the flowchart and / or block diagram can be implemented by computer-readable program instructions.
[0123] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0124] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0125] The flow chart and block diagram in the accompanying drawings show the possible architecture, function and operation of the system, method and computer program product according to multiple embodiments of the present disclosure. In this regard, each square box in the flow chart or block diagram can represent a part of a module, program segment or instruction, and a part of the module, program segment or instruction includes one or more executable instructions for realizing the specified logical function. In some alternative implementations, the function marked in the square box can also occur in a sequence different from that marked in the accompanying drawings. For example, two continuous square boxes can actually be executed substantially in parallel, and they can sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each square box in the block diagram and / or flow chart, and the combination of the square boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or action, or can be implemented with a combination of special hardware and computer instructions.
[0126] The computer program product may be implemented in hardware, software or a combination thereof. In one optional embodiment, the computer program product is embodied as a computer storage medium, and in another optional embodiment, the computer program product is embodied as a software product, such as a software development kit (SDK) and the like.
[0127] The above description of various embodiments tends to emphasize the differences between the various embodiments. The same or similar aspects can be referenced to each other, and for the sake of brevity, they will not be repeated herein.
[0128] Those skilled in the art will appreciate that, in the above method of specific implementation, the order in which the steps are written does not imply a strict execution order and does not constitute any limitation on the implementation process. The specific execution order of the steps should be determined by their functions and possible internal logic.
[0129] If the technical solution of this application involves personal information, the product using the technical solution of this application has clearly informed the personal information processing rules and obtained the individual's voluntary consent before processing the personal information. If the technical solution of this application involves sensitive personal information, the product using the technical solution of this application has obtained the individual's separate consent before processing the sensitive personal information, and at the same time meets the "explicit consent" requirement. For example, on personal information collection devices such as cameras, clear and prominent signs are set to inform that the personal information collection scope has been entered and personal information will be collected. If the individual voluntarily enters the collection scope, it is deemed that he or she agrees to the collection of his or her personal information; or on the device that processes personal information, the personal information processing rules are notified by obvious signs / information, and the individual's authorization is obtained through pop-up information or by asking the individual to upload his or her personal information; among them, the personal information processing rules may include information such as the personal information processor, the purpose of personal information processing, the processing method, and the type of personal information processed.
[0130] The embodiments of the present disclosure have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or improvements to the technology in the market, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein.
Claims
1. A method for determining an intra-frame prediction mode, characterized in that: The method is applied to high efficiency video coding (HEVC), and the method comprises: For a HEVC current prediction unit PU, determine a luma candidate intra prediction mode set of a luma prediction block PB corresponding to a luma component of the current PU, and determine a first chroma candidate intra prediction mode set of a chroma PB corresponding to a chroma component of the current PU according to the luma candidate intra prediction mode set; Determine a rate-distortion cost of the luma PB in each candidate intra prediction mode in the luma candidate intra prediction mode set, and determine in parallel a rate-distortion cost of the chroma PB in each candidate intra prediction mode in the first chroma candidate intra prediction mode set; Determine the candidate intra-frame prediction mode with the smallest rate-distortion cost in the luma candidate intra-frame prediction mode set as the target luma intra-frame prediction mode corresponding to the luma PB; Determine a target chroma intra prediction mode corresponding to the chroma PB based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set; The optional intra-frame prediction modes corresponding to the brightness PB include: a planar mode, a direct current DC mode, and multiple angle modes; The determining a set of luminance candidate intra prediction modes of a luminance PB corresponding to a luminance component of the current PU comprises: Determine the sum of absolute transformation differences (SATD) cost corresponding to each angle mode in the plurality of angle modes, and determine the angle mode with the minimum SATD cost as the target angle mode; The luma candidate intra prediction mode set is determined based on the Planar mode, the DC mode, and the target angle mode.
2. The method according to claim 1, characterized in that The determining, according to the luma candidate intra prediction mode set, a first chroma candidate intra prediction mode set of the chroma PB corresponding to the chroma component of the current PU comprises: Determining, according to the target angle mode, an optional intra-frame prediction mode corresponding to the chroma PB; The first chroma candidate intra-frame prediction mode set is determined according to the optional intra-frame prediction mode corresponding to the chroma PB.
3. The method according to claim 1, characterized in that The determining, based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set, a target luma intra prediction mode corresponding to the chroma PB, comprises: Determine a second chroma candidate intra prediction mode set for the chroma PB based on the target luma intra prediction mode; Based on the second chroma candidate intra prediction mode set of the chroma PB and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set, a target luma intra prediction mode corresponding to the chroma PB is determined.
4. The method according to claim 3, characterized in that The determining, based on the target luma intra prediction mode, a second chroma candidate intra prediction mode set for the chroma PB comprises: Determine, according to the target angle mode and the target luminance intra prediction mode, an optional intra prediction mode corresponding to the chrominance PB; The second chroma candidate intra-frame prediction mode set is determined according to the optional intra-frame prediction mode corresponding to the chroma PB.
5. The method according to claim 3 or 4, characterized in that: The determining a target chroma intra prediction mode corresponding to the chroma PB based on the second chroma candidate intra prediction mode set of the chroma PB and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set comprises: The candidate intra prediction mode that is simultaneously in the first chroma candidate intra prediction mode set and the second chroma candidate intra prediction mode set and has the smallest rate-distortion cost is determined as the target chroma intra prediction mode.
6. The method according to claim 1, characterized in that The method further comprises: Based on the target luma intra prediction mode, a chroma mode number of the target chroma intra prediction mode is determined using a preset encoding method.
7. An intra-frame prediction mode determination device, characterized in that: The device is applied to HEVC, and the device includes: A candidate intra prediction mode set determination module is used to determine, for a HEVC current PU, a luma candidate intra prediction mode set of a luma PB corresponding to a luma component of the current PU, and determine, based on the luma candidate intra prediction mode set, a first chroma candidate intra prediction mode set of a chroma PB corresponding to a chroma component of the current PU; a rate-distortion cost determination module, configured to determine a rate-distortion cost of the luma PB in each candidate intra-prediction mode in the luma candidate intra-prediction mode set, and to determine in parallel a rate-distortion cost of the chroma PB in each candidate intra-prediction mode in the first chroma candidate intra-prediction mode set; a luma intra prediction mode determination module, configured to determine the candidate intra prediction mode with the minimum rate-distortion cost in the luma candidate intra prediction mode set as the target luma intra prediction mode corresponding to the luma PB; a chroma intra prediction mode determination module, configured to determine a target chroma intra prediction mode corresponding to the chroma PB based on the target luma intra prediction mode and the rate-distortion cost of each candidate intra prediction mode in the first chroma candidate intra prediction mode set; The optional intra-frame prediction modes corresponding to the brightness PB include: Planar mode, DC mode, and multiple angle modes; The candidate intra prediction mode set determination module is specifically used to: Determine the SATD cost corresponding to each angle mode among the multiple angle modes, and determine the angle mode with the minimum SATD cost as the target angle mode; A luma candidate intra prediction mode set is determined based on the Planar mode, the DC mode, and the target angle mode.
8. An electronic device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to call the instructions stored in the memory to execute the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having computer program instructions stored thereon, characterized in that: When the computer program instructions are executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Prediction mode selection method and device
CN104853192A
HEVC-oriented fast intra-frame prediction mode decision method and device
CN105657420A
Method for determining intra prediction mode, method for encoding image, and method for decoding image
CN115988223A