CN112804524A - Intra-frame fast mode decision method for AVS2 - Google Patents

Intra-frame fast mode decision method for AVS2 Download PDF

Info

Publication number
CN112804524A
CN112804524A CN201911111352.3A CN201911111352A CN112804524A CN 112804524 A CN112804524 A CN 112804524A CN 201911111352 A CN201911111352 A CN 201911111352A CN 112804524 A CN112804524 A CN 112804524A
Authority
CN
China
Prior art keywords
intra
modes
candidate
satd
current
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201911111352.3A
Other languages
Chinese (zh)
Other versions
CN112804524B (en
Inventor
贾惠柱
向国庆
李源
谢豪
解晓东
黄铁军
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Peking University
Original Assignee
Peking University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Peking University filed Critical Peking University
Priority to CN201911111352.3A priority Critical patent/CN112804524B/en
Publication of CN112804524A publication Critical patent/CN112804524A/en
Application granted granted Critical
Publication of CN112804524B publication Critical patent/CN112804524B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/103Selection of coding mode or of prediction mode
    • H04N19/11Selection of coding mode or of prediction mode among a plurality of spatial predictive coding modes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/12Selection from among a plurality of transforms or standards, e.g. selection between discrete cosine transform [DCT] and sub-band transform or selection between H.263 and H.264
    • H04N19/122Selection of transform size, e.g. 8x8 or 2x4x8 DCT; Selection of sub-band transforms of varying structure or type
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/146Data rate or code amount at the encoder output
    • H04N19/147Data rate or code amount at the encoder output according to rate distortion criteria

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Discrete Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

An intra fast mode decision method for AVS2, comprising the steps of: comparing the texture direction angles corresponding to the beta and the 30 angle prediction modes, selecting the angle prediction mode corresponding to the 12 angles closest to the beta, adding 3 non-angle prediction modes, and traversing the calculation of the rate-distortion cost based on the SATD of the 15 intra-frame prediction modes; and after comparison, 9 intra-frame prediction modes with smaller rate-distortion cost based on the SATD are obtained as candidate modes, and the candidate modes are sequentially arranged according to the sequence of the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list. The technical scheme of the invention can accelerate the intra-frame mode decision under the condition that the objective quality of the video is almost unchanged, and finally reduce the computational complexity of intra-frame coding.

Description

Intra-frame fast mode decision method for AVS2
Technical Field
The present invention is an intra fast mode decision method for AVS2,
background
Intra-frame coding is one of the important components in video coding technology. Currently, the mainstream coding tools employ multiple intra prediction modes to process different video image contents. For example, in the AVS2 video coding standard, all PUs need to go through 33 intra prediction modes to perform RMD process, and obtain 9 better candidate modes to perform the next RDO process, and the optimal intra prediction mode is selected by comparing the rate-distortion cost. With the above coding structure, the performance of intra coding is significantly increased, but the complexity is sharply increased.
If we could reduce the encoding time in the intra mode decision process by the intra fast mode decision algorithm, this would help to reduce the computational complexity of intra coding while keeping the objective quality of the video almost unchanged.
In the prior art document Min B, Cheng R C.A Fast CU Size Decision Algorithm for the HEVC Intra Encoder [ J ]. IEEE Transactions on Circuits and Systems for Video Technology,2015,25(5):892-896, the authors propose a Fast Algorithm that depends on the relationship between the texture characteristics of a coding unit and its optimal coding mode. The algorithm may reduce the number of intra prediction modes entering the mode decision process, but it does not take into account spatio-temporal neighbor information.
Disclosure of Invention
The main object of the present invention is to reduce the intra mode decision time, thereby reducing the computational complexity of intra coding.
An intra fast mode decision method for AVS2, comprising the steps of:
step one, acquiring gradient values of each pixel in the current PU in the horizontal and vertical directions by using a Sobel operator, and calculating the gradient values as shown in the following
Gxij=pi+1,j-1+2×pi+1,j+pi+1,j+1-pi-1,j-1-2×p-1i,j-pi-1,j+1, (1)
Gyij=pi-1,j-1+2×pi,j-1+pi+1,j-1-pi-1,j+1-2×pi,j+1-pi+1,j+1, (2)
Wherein p isi,jRepresenting the pixel at position (i, j), GxijAnd GyijRepresenting the gradient values of the pixel in the horizontal and vertical directions, respectively.
Step two, the Gx obtained according to the stepijAnd GyijThe gradient angle θ of the current PU is calculated by formula (3).
Figure BDA0002270826790000021
Where n represents the number of pixels in the horizontal or vertical direction in the current PU.
Step three, obtaining a texture direction angle beta of the current PU through a formula (4);
Figure BDA0002270826790000022
step four, when the beta is closest to the texture direction angle corresponding to the intra-frame angle prediction mode 3 or 32, turning to step six; otherwise, go to the next step;
comparing the texture direction angles corresponding to the beta and the 30 angle prediction modes, selecting the angle prediction mode corresponding to the 12 angles closest to the beta, adding 3 non-angle prediction modes, and traversing the calculation of the rate-distortion cost based on the SATD of the 15 intra-frame prediction modes; through comparison, 9 intra-frame prediction modes with smaller rate-distortion cost based on SATD are obtained as candidate modes, and the candidate modes are sequentially arranged according to the sequence of the corresponding rate-distortion cost based on SATD from small to large to form a first-stage candidate list; turning to the step seven;
and step six, when the beta is closest to the texture direction angle corresponding to the intra angle prediction mode 3 or 32, performing an RMD process in an AVS2 standard on the current PU, namely completely traversing the rate-distortion cost calculation based on SATD of the 33 intra prediction modes, and obtaining 9 intra prediction modes with smaller rate-distortion cost based on SATD as candidate modes. And sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list.
Step seven, repeating the steps for the prediction units PU with different sizes, and completing the construction of the first-level candidate lists of all the prediction units PU;
and step eight, comparing the optimal intra-frame prediction mode of the adjacent PU on the left side of the current PU with the modes in the first-level candidate list. If the pattern exists in the first-level candidate list, the candidate list is not changed; if the mode does not exist, removing the last bit mode in the candidate list, moving the rest modes backwards by one bit in sequence, and placing the optimal intra-frame prediction mode of the left adjacent PU in the first bit of the candidate list;
and step nine, repeating the process in the step eight for the optimal intra-frame prediction modes of the PU adjacent to the upper side of the current PU and the PU at the same position of the previous frame.
Step ten, selecting the first 3 or 5 candidate modes in the candidate list for RDO according to the difference of PU sizes; namely: the first 5 were selected at 4x4PU, and the first 3 at 8x8, 16x16, 32x32, 64x64 PU.
The technical scheme of the invention brings beneficial effects
The technical scheme of the invention combines the first-stage candidate mode construction based on the gradient direction, the candidate list updating based on the space-time correlation and the candidate mode number adjustment based on the probability statistics to jointly optimize the RMD and the RDO in the intra-frame mode decision process, can accelerate the intra-frame mode decision under the condition that the objective quality of the video is almost unchanged, and finally reduces the calculation complexity of intra-frame coding.
The method adopts a first-level candidate mode list construction combining with the gradient direction, the update of a candidate list based on the space-time correlation and an intra-frame fast mode decision scheme based on the adjustment of the number of candidate modes based on probability statistics;
1) in the construction of a first-stage candidate mode based on the gradient direction, a first-stage candidate mode list is obtained under the selection of the gradient direction and the standard RMD;
2) in the updating of the candidate mode list based on the space-time correlation, updating the first-level candidate mode list by using MPMs and LF of the current PU space adjacent PUs;
3) in the adjustment of the number of candidate modes based on probability statistics, different numbers of intra-frame prediction modes in a candidate list are selected according to different sizes of coding units to participate in the traversal of rate distortion optimization.
Drawings
FIG. 1 is a flow chart of the working process of the present invention;
fig. 2 is a schematic diagram illustrating a first-level candidate pattern list selection process according to the present invention.
Detailed Description
An intra fast mode decision method for AVS2, comprising the steps of:
step one, acquiring gradient values of each pixel in the current PU in the horizontal and vertical directions by using a Sobel operator, and calculating the gradient values as shown in the following
Gxij=pi+1,j-1+2×pi+1,j+pi+1,j+1-pi-1,j-1-2×p-1i,j-pi-1,j+1, (1)
Gyij=pi-1,j-1+2×pi,j-1+pi+1,j-1-pi-1,j+1-2×pi,j+1-pi+1,j+1, (2)
Wherein p isi,jRepresenting the pixel at position (i, j), GxijAnd GyijRepresenting the gradient values of the pixel in the horizontal and vertical directions, respectively.
Step two, the Gx obtained according to the stepijAnd GyijThe gradient angle θ of the current PU is calculated by formula (3).
Figure BDA0002270826790000051
Where n represents the number of pixels in the horizontal or vertical direction in the current PU.
Step three, obtaining a texture direction angle beta of the current PU through a formula (4);
Figure BDA0002270826790000052
step four, when the beta is closest to the texture direction angle corresponding to the intra-frame angle prediction mode 3 or 32, turning to step six; otherwise, go to the next step;
comparing the texture direction angles corresponding to the beta and the 30 angle prediction modes, selecting the angle prediction mode corresponding to the 12 angles closest to the beta, adding 3 non-angle prediction modes, and traversing the calculation of the rate-distortion cost based on the SATD of the 15 intra-frame prediction modes; through comparison, 9 intra-frame prediction modes with smaller rate-distortion cost based on SATD are obtained as candidate modes, and the candidate modes are sequentially arranged according to the sequence of the corresponding rate-distortion cost based on SATD from small to large to form a first-stage candidate list; turning to the step seven;
step six, when the beta is closest to the texture direction angle corresponding to the intra angle prediction mode 3 or 32, abandoning the operations in the steps one to five, and performing the RMD process in the AVS2 standard on the current PU, namely completely traversing the computation of the rate-distortion cost based on the SATD of the 33 intra prediction modes to obtain 9 intra prediction modes with smaller rate-distortion cost based on the SATD as candidate modes. And sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list.
Step seven, repeating the steps for the prediction units PU with different sizes, and completing the construction of the first-level candidate lists of all the prediction units PU;
step eight, comparing the optimal intra-frame prediction mode of the adjacent PU on the left side of the current PU with the modes in the first-level candidate list; if the pattern exists in the first-level candidate list, the candidate list is not changed; if the mode does not exist, removing the last bit mode in the candidate list, moving the rest modes backwards by one bit in sequence, and placing the optimal intra-frame prediction mode of the left adjacent PU in the first bit of the candidate list;
step nine, repeating the process in the step eight for the optimal intra-frame prediction mode of the PU adjacent to the upper side of the current PU and the PU at the same position of the previous frame;
step ten, selecting the first 3 or 5 candidate modes in the candidate list for RDO according to the difference of PU sizes; namely: the first 5 were selected at 4x4PU, and the first 3 at 8x8, 16x16, 32x32, 64x64 PU.
The method mainly comprises three parts, namely the construction of a first-stage candidate list based on the gradient direction, the updating of a candidate list based on the MPM of space-time adjacency and the adjustment of the number of candidate modes based on probability statistics, and a flow chart is shown in figure 1. Where LF represents the intra optimal prediction mode of the PU at the same location in the frame prior to the current PU.
1) Gradient direction based first level candidate pattern list construction
The Sobel operator is a widely used, simple and efficient edge detection operator. In edge detection, pixels usually have directionality, and gradient values in corresponding directions can be obtained through a horizontal or vertical Sobel operator. Therefore, the gradient information of each pixel of the current PU is obtained by using a Sobel operator, and a first-stage candidate mode list is obtained by combining the RMD process in the standard. Under the judgment of gradient information, some angle modes are selected to enter a rate distortion optimization process, and a detailed algorithm is described as follows:
(1) obtaining the gradient value of each pixel in the current PU in the horizontal and vertical directions by using a Sobel operator, and calculating the gradient values as shown in the following
Gxij=pi+1,j-1+2×pi+1,j+pi+1,j+1-pi-1,j-1-2×p-1i,j-pi-1,j+1, (1)
Gyij=pi-1,j-1+2×pi,j-1+pi+1,j-1-pi-1,j+1-2×pi,j+1-pi+1,j+1, (2)
Wherein p isi,jRepresenting the pixel at position (i, j), GxijAnd GyijRespectively representing the gradients of the pixel in the horizontal and vertical directionsAn amplitude value.
(2) The gradient angle θ of the current PU is calculated by equation (3).
Figure BDA0002270826790000071
Where n represents the number of pixels in the horizontal or vertical direction in the current PU.
(3) The grain direction angle β is obtained by equation (4).
Figure BDA0002270826790000072
The angular prediction modes corresponding to the 12 angles closest to β are selected, plus the RMD in the 3 non-angular mode progression criteria. And selecting 9 prediction modes with lower cost to form a first-stage candidate mode list through SATD-based rate-distortion cost comparison. As shown in fig. 2.
(4) It should be noted that, when the texture direction angle β obtained in step (3) is not within the range where the 33 intra angle prediction modes are distributed, the operations in steps (1) to (3) are abandoned, and the RMD process in the AVS2 standard is selected, so that 9 prediction modes are selected from the 33 prediction modes to form the first-level candidate mode list.
2) Update of candidate list based on spatiotemporal correlation
Considering that a PU of a video has temporal and spatial correlation, the current PU is similar in texture information to its neighboring PUs. Thus, the first level candidate mode list may be updated according to intra MPMs and LFs of the left PU and the upper PU. The detailed algorithmic process is as follows:
(1) first, we need to first obtain the intra MPM of the left PU by comparing it with the prediction modes in the first level candidate mode list. If so, the candidate pattern list is not changed, and if not, the pattern is added to the current list and moved to the first position of the candidate list.
(2) Similarly, judging whether the MPM in the frame of the upper PU exists in the candidate list updated in the step (1), if so, keeping the original position unchanged; if not, the pattern is added to the current list and moved to the second place of the candidate list.
(3) Like the MPMs updates on the top and left sides, PUs at the same location in the previous frame also have significant reference meaning. Comparing the intra-frame optimal prediction mode of the PU with the same position in the previous frame with the list updated in the step (2). If the pattern exists, the list is unchanged; if not, the pattern is moved to bit 1 of the list for updating.
3) Probability statistics based adjustment of number of candidate patterns
Through a large number of experimental statistics and analysis, it is found that the 9 candidate modes in the AVS2 standard tend to be selected as the optimal intra prediction modes only by the first few less expensive candidate modes. The first candidate mode percentage is up to 63.4%, the second candidate mode percentage is also up to 21.1%, the first five candidate modes account for 96.9%, and almost all prediction modes are occupied. The algorithm will have different numbers of candidate patterns to participate in the rate-distortion optimization traversal according to different coding unit sizes, and the specific number is shown in table 1.
TABLE 1 PU size and number of candidate modes
PU size Number of candidate patterns
4x 4 5
8x 8 3
16x 16 3
32x 32 3
64x 64 3
PU (polyurethane): the prediction unit is a basic unit for prediction encoding by AVS 2. In intra prediction, the size of a PU includes 4x4, 8x8, 16x16, 32x32, 64x 64.
In the AVS2 standard, there are 33 intra prediction modes for a PU, including 3 non-angular prediction modes (0-2) and 30 angular prediction modes (3-32), each corresponding to a texture direction angle. Wherein, the optimal intra prediction mode of the current PU is obtained through RMD and RDO. The RMD process requires the computation of SATD-based rate-distortion costs for a complete traversal of the 33 intra-prediction modes, and 9 intra-prediction modes with smaller SATD-based rate-distortion costs are obtained as candidate modes. The RDO process needs to go through the calculation of the rate-distortion cost of the above 9 candidate modes, and obtain the intra-frame prediction mode with the minimum rate-distortion cost as the optimal intra-frame prediction mode.
The technical scheme of the invention adopts two steps to optimize the computational complexity of the intra mode decision.
In the first step, the gradient information of the current PU is obtained by using a Sobel operator. And obtaining the texture direction angle of the current PU through the gradient information of the current PU. Comparing the texture direction angle of the current PU with the texture direction angles corresponding to the 30 angle prediction modes, and selecting 12 optimal intra-frame angle prediction modes. The SATD-based rate-distortion cost calculation for the 15 intra prediction modes is traversed by adding 3 non-angular prediction modes. 9 intra prediction modes with smaller rate distortion cost based on SATD are obtained as candidate modes.
And secondly, updating the candidate list obtained in the first step through the optimal intra-frame prediction modes of the spatial-temporal adjacent PUs, and finally selecting the first 3 or 5 candidate modes from the candidate list for RDO according to the difference of PU sizes.
The detailed process is as follows:
the first step is as follows:
(1) obtaining the gradient value of each pixel in the current PU in the horizontal and vertical directions by using a Sobel operator, and calculating the gradient values as shown in the following
Gxij=pi+1,j-1+2×pi+1,j+pi+1,j+1-pi-1,j-1-2×p-1i,j-pi-1,j+1, (1)
Gyij=pi-1,j-1+2×pi,j-1+pi+1,j-1-pi-1,j+1-2×pi,j+1-pi+1,j+1, (2)
Wherein p isi,jRepresenting the pixel at position (i, j), GxijAnd GyijRepresenting the gradient values of the pixel in the horizontal and vertical directions, respectively.
(2) The gradient angle θ of the current PU is calculated by equation (3).
Figure BDA0002270826790000101
Where n represents the number of pixels in the horizontal or vertical direction in the current PU.
(3) And (4) obtaining the texture direction angle beta of the current PU through a formula (4).
Figure BDA0002270826790000102
(4) The texture direction angles corresponding to β and the 30 angle prediction modes are compared, and the angle prediction mode corresponding to the 12 angles closest to β is selected. The SATD-based rate-distortion cost calculation for the 15 intra prediction modes is traversed by adding 3 non-angular prediction modes. Through comparison, 9 intra-frame prediction modes with smaller rate-distortion cost based on SATD are obtained as candidate modes. And sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list.
(5) It should be noted that, when β is closest to the texture direction angle corresponding to the intra angle prediction mode 3 or 32, the operations in steps (1) to (4) are abandoned, and the RMD process in the AVS2 standard, that is, the SATD-based rate-distortion cost calculation for the complete traversal of 33 intra prediction modes is performed on the current PU, so as to obtain 9 intra prediction modes with smaller SATD-based rate-distortion cost as candidate modes. And sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list.
(6) And repeating the steps by the prediction units PU with different sizes to complete the construction of the first-level candidate list.
The second step is that:
(1) the optimal intra prediction mode of the current PU's left neighboring PU is compared to the modes in the first level candidate list. If the pattern exists in the first-level candidate list, the candidate list is not changed; if the mode does not exist, the mode of the last bit in the candidate list is removed, the remaining modes are sequentially moved backward by one bit, and the optimal intra prediction mode of the left adjacent PU is placed at the first bit of the candidate list.
(2) Repeating the process in step (1) for the optimal intra prediction modes of the upper side neighboring PU to the current PU and the co-located PU of the previous frame.
(3) And finally, selecting the first 3 or 5 candidate modes in the candidate list according to the difference of PU sizes for RDO. Namely: the first 5 were selected at 4x4PU, and the first 3 at 8x8, 16x16, 32x32, 64x64 PU.
PU (polyurethane): the prediction unit is a basic unit for prediction encoding by AVS 2. In intra prediction, the size of a PU includes 4x4, 8x8, 16x16, 32x32, 64x 64.
In the AVS2 standard, there are 33 intra prediction modes for a PU, including 3 non-angular prediction modes (0-2) and 30 angular prediction modes (3-32), each corresponding to a texture direction angle. Wherein, the optimal intra prediction mode of the current PU is obtained through RMD and RDO. The RMD process requires the computation of SATD-based rate-distortion costs for a complete traversal of the 33 intra-prediction modes, and 9 intra-prediction modes with smaller SATD-based rate-distortion costs are obtained as candidate modes. The RDO process needs to go through the calculation of the rate-distortion cost of the above 9 candidate modes, and obtain the intra-frame prediction mode with the minimum rate-distortion cost as the optimal intra-frame prediction mode.
The technical scheme of the invention adopts two steps to optimize the computational complexity of the intra mode decision.
In the first step, the gradient information of the current PU is obtained by using a Sobel operator. And obtaining the texture direction angle of the current PU through the gradient information of the current PU. Comparing the texture direction angle of the current PU with the texture direction angles corresponding to the 30 angle prediction modes, and selecting 12 optimal intra-frame angle prediction modes. The SATD-based rate-distortion cost calculation for the 15 intra prediction modes is traversed by adding 3 non-angular prediction modes. 9 intra prediction modes with smaller rate distortion cost based on SATD are obtained as candidate modes.
And secondly, updating the candidate list obtained in the first step through the optimal intra-frame prediction modes of the spatial-temporal adjacent PUs, and finally selecting the first 3 or 5 candidate modes from the candidate list for RDO according to the difference of PU sizes.
The detailed process is as follows:
the first step is as follows:
(1) obtaining the gradient value of each pixel in the current PU in the horizontal and vertical directions by using a Sobel operator, and calculating the gradient values as shown in the following
Gxij=pi+1,j-1+2×pi+1,j+pi+1,j+1-pi-1,j-1-2×p-1i,j-pi-1,j+1, (1)
Gyij=pi-1,j-1+2×pi,j-1+pi+1,j-1-pi-1,j+1-2×pi,j+1-pi+1,j+1, (2)
Wherein p isi,jRepresenting the pixel at position (i, j), GxijAnd GyijRepresenting the gradient values of the pixel in the horizontal and vertical directions, respectively.
(2) The gradient angle θ of the current PU is calculated by equation (3).
Figure BDA0002270826790000121
Where n represents the number of pixels in the horizontal or vertical direction in the current PU.
(3) And (4) obtaining the texture direction angle beta of the current PU through a formula (4).
Figure BDA0002270826790000122
(4) The texture direction angles corresponding to β and the 30 angle prediction modes are compared, and the angle prediction mode corresponding to the 12 angles closest to β is selected. The SATD-based rate-distortion cost calculation for the 15 intra prediction modes is traversed by adding 3 non-angular prediction modes. Through comparison, 9 intra-frame prediction modes with smaller rate-distortion cost based on SATD are obtained as candidate modes. And sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list.
(5) It should be noted that, when β is closest to the texture direction angle corresponding to the intra angle prediction mode 3 or 32, the operations in steps (1) to (4) are abandoned, and the RMD process in the AVS2 standard, that is, the SATD-based rate-distortion cost calculation for the complete traversal of 33 intra prediction modes is performed on the current PU, so as to obtain 9 intra prediction modes with smaller SATD-based rate-distortion cost as candidate modes. And sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list.
(6) And repeating the steps by the prediction units PU with different sizes to complete the construction of the first-level candidate list.
The second step is that:
(4) the optimal intra prediction mode of the current PU's left neighboring PU is compared to the modes in the first level candidate list. If the pattern exists in the first-level candidate list, the candidate list is not changed; if the mode does not exist, the mode of the last bit in the candidate list is removed, the remaining modes are sequentially moved backward by one bit, and the optimal intra prediction mode of the left adjacent PU is placed at the first bit of the candidate list.
(5) Repeating the process in step (1) for the optimal intra prediction modes of the upper side neighboring PU to the current PU and the co-located PU of the previous frame.
(6) And finally, selecting the first 3 or 5 candidate modes in the candidate list according to the difference of PU sizes for RDO. Namely: the first 5 were selected at 4x4PU, and the first 3 at 8x8, 16x16, 32x32, 64x64 PU.
Abbreviations and Key term definitions
PU (polyurethane): prediction unit, prediction unit
RMD: rough mode decision
RDO: rate distortion optimization
SATD: sum of absolute transformed difference
MPM: most probable mode
LF: and the intra-frame optimal prediction mode of the PU at the same position in the previous frame of the current PU.

Claims (1)

1. An intra fast mode decision method for AVS2, comprising the steps of:
step one, acquiring gradient values of each pixel in the current PU in the horizontal direction and the vertical direction by using a Sobel operator, and calculating as shown below;
Gxij=pi+1,j-1+2×pi+1,j+pi+1,j+1-pi-1,j-1-2×p-1i,j-pi-1,j+1, (1)
Gyij=pi-1,j-1+2×pi,j-1+pi+1,j-1-pi-1,j+1-2×pi,j+1-pi+1,j+1,1, (2)
wherein p isi,jRepresenting the pixel at position (i, j), GxijAnd GyijRepresenting the gradient values of the pixel in the horizontal and vertical directions, respectively。
Step two, the Gx obtained according to the stepijAnd GyijCalculating the gradient angle theta of the current PU through a formula (3);
Figure FDA0002270826780000011
where n represents the number of pixels in the horizontal or vertical direction in the current PU.
Step three, obtaining a texture direction angle beta of the current PU through a formula (4);
Figure FDA0002270826780000012
step four, when the beta is closest to the texture direction angle corresponding to the intra-frame angle prediction mode 3 or 32, turning to step six; otherwise, go to the next step;
comparing the texture direction angles corresponding to the beta and the 30 angle prediction modes, selecting the angle prediction mode corresponding to the 12 angles closest to the beta, adding 3 non-angle prediction modes, and traversing the calculation of the rate-distortion cost based on the SATD of the 15 intra-frame prediction modes; through comparison, 9 intra-frame prediction modes with smaller rate-distortion cost based on SATD are obtained as candidate modes, and the candidate modes are sequentially arranged according to the sequence of the corresponding rate-distortion cost based on SATD from small to large to form a first-stage candidate list; turning to the step seven;
and step six, when the beta is closest to the texture direction angle corresponding to the intra angle prediction mode 3 or 32, performing an RMD process in an AVS2 standard on the current PU, namely completely traversing the rate-distortion cost calculation based on SATD of the 33 intra prediction modes, and obtaining 9 intra prediction modes with smaller rate-distortion cost based on SATD as candidate modes. Sequentially arranging the candidate modes according to the corresponding rate-distortion cost based on the SATD from small to large to form a first-level candidate list;
step seven, repeating the steps for the prediction units PU with different sizes, and completing the construction of the first-level candidate lists of all the prediction units PU;
and step eight, comparing the optimal intra-frame prediction mode of the adjacent PU on the left side of the current PU with the modes in the first-level candidate list. If the pattern exists in the first-level candidate list, the candidate list is not changed; if the mode does not exist, removing the last bit mode in the candidate list, moving the rest modes backwards by one bit in sequence, and placing the optimal intra-frame prediction mode of the left adjacent PU in the first bit of the candidate list;
step nine, repeating the process in the step eight for the optimal intra-frame prediction mode of the PU adjacent to the upper side of the current PU and the PU at the same position of the previous frame;
step ten, selecting the first 3 or 5 candidate modes in the candidate list for RDO according to the difference of PU sizes; namely: the first 5 were selected at 4x4PU, and the first 3 at 8x8, 16x16, 32x32, 64x64 PU.
CN201911111352.3A 2019-11-13 2019-11-13 Intra-frame fast mode decision method for AVS2 Active CN112804524B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911111352.3A CN112804524B (en) 2019-11-13 2019-11-13 Intra-frame fast mode decision method for AVS2

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911111352.3A CN112804524B (en) 2019-11-13 2019-11-13 Intra-frame fast mode decision method for AVS2

Publications (2)

Publication Number Publication Date
CN112804524A true CN112804524A (en) 2021-05-14
CN112804524B CN112804524B (en) 2022-11-25

Family

ID=75804033

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911111352.3A Active CN112804524B (en) 2019-11-13 2019-11-13 Intra-frame fast mode decision method for AVS2

Country Status (1)

Country Link
CN (1) CN112804524B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113271461A (en) * 2021-05-18 2021-08-17 上海大学 Intra-frame prediction mode decision method and system based on self-adaptive cost score threshold
CN113630596A (en) * 2021-06-25 2021-11-09 杭州未名信科科技有限公司 AVS3 intra-frame prediction mode rough selection method, system and medium
WO2024067036A1 (en) * 2022-09-26 2024-04-04 广州市百果园信息技术有限公司 Decision method and apparatus for intra-frame prediction mode, and video encoding device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106231302A (en) * 2016-07-28 2016-12-14 同观科技(深圳)有限公司 A kind of determination method and system of optimal frames inner estimation mode
US20170230673A1 (en) * 2016-02-05 2017-08-10 Blackberry Limited Rolling intra prediction for image and video coding
CN107343198A (en) * 2017-05-08 2017-11-10 上海大学 A kind of quick decision method of AVS2 inter-frame forecast modes
CN109922337A (en) * 2017-12-13 2019-06-21 博雅视云(北京)科技有限公司 AVS2 intra mode decision fast algorithm and realization device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170230673A1 (en) * 2016-02-05 2017-08-10 Blackberry Limited Rolling intra prediction for image and video coding
CN106231302A (en) * 2016-07-28 2016-12-14 同观科技(深圳)有限公司 A kind of determination method and system of optimal frames inner estimation mode
CN107343198A (en) * 2017-05-08 2017-11-10 上海大学 A kind of quick decision method of AVS2 inter-frame forecast modes
CN109922337A (en) * 2017-12-13 2019-06-21 博雅视云(北京)科技有限公司 AVS2 intra mode decision fast algorithm and realization device

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113271461A (en) * 2021-05-18 2021-08-17 上海大学 Intra-frame prediction mode decision method and system based on self-adaptive cost score threshold
CN113630596A (en) * 2021-06-25 2021-11-09 杭州未名信科科技有限公司 AVS3 intra-frame prediction mode rough selection method, system and medium
WO2024067036A1 (en) * 2022-09-26 2024-04-04 广州市百果园信息技术有限公司 Decision method and apparatus for intra-frame prediction mode, and video encoding device

Also Published As

Publication number Publication date
CN112804524B (en) 2022-11-25

Similar Documents

Publication Publication Date Title
CN112804524B (en) Intra-frame fast mode decision method for AVS2
CN106961606B (en) HEVC intra-frame coding mode selection method based on texture division characteristics
CN107071416B (en) HEVC intra-frame prediction mode rapid selection method
WO2018010492A1 (en) Rapid decision making method for intra-frame prediction mode in video coding
CN109565593B (en) Image encoding/decoding method and apparatus, and recording medium storing bit stream
CN103096069B (en) The method and apparatus of derivation intra prediction mode
JP5065404B2 (en) Video coding with intra coding selection
CN116962717A (en) Image encoding/decoding method, storage medium, and transmission method
CN113273213A (en) Image encoding/decoding method and apparatus, and recording medium storing bit stream
CN109804625A (en) The recording medium of method and apparatus and stored bits stream to encoding/decoding image
CN103248895B (en) A kind of quick mode method of estimation for HEVC intraframe coding
CN102648631A (en) Method and apparatus for encoding/decoding high resolution images
CN103297781A (en) High efficiency video coding (HEVC) intraframe coding method, device and system based on texture direction
CN104168480B (en) Intra-prediction code mode fast selecting method based on HEVC standard
CN103997645B (en) Quick HEVC intra-frame coding unit and pattern decision method
CN101969561A (en) Intra-frame mode selection method and device and encoder
CN114586366A (en) Inter-frame prediction method, encoder, decoder, and storage medium
Ting et al. Gradient-based PU size selection for HEVC intra prediction
CN102186081A (en) H.264 intra-frame mode selection method based on gradient vector
CN102547257B (en) Method for obtaining optimal prediction mode and device
RU2562414C1 (en) Method for fast selection of spatial prediction mode in hevc coding system
CN101895755A (en) Quick 4*4 block intra-frame prediction mode selecting method
CN109547798B (en) Rapid HEVC inter-frame mode selection method
CN107613294A (en) A kind of method for fast skipping P, B frame intra prediction mode in HEVC
KR100846780B1 (en) Motion vector derivation method and apparatus

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant