An intra prediction method, an encoder, a decoder and a storage medium

By combining Intra-Predictive Smoothing Filtering (IPS) and Intra-Predictive Filtering (IPF), the problem of increased residuals in textured image patches during intra-prediction is solved, thereby improving coding efficiency and prediction accuracy.

CN116980596BActive Publication Date: 2025-11-25GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310996326.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-10-16
Publication Date
2025-11-25
Estimated Expiration
2040-10-16

AI Technical Summary

Technical Problem

Existing intra-frame prediction techniques over-sharpen in textured image patches, leading to increased residuals, decreased coding efficiency, and ineffective smoothing.

Method used

Intra-predictive smoothing filtering (IPS) is employed, which filters the current block by referencing multiple neighboring reference pixels in a set of multiple neighboring reference pixels. Combined with intra-predictive filtering (IPF), it improves prediction accuracy and coding efficiency.

Benefits of technology

Improve prediction accuracy, reduce residuals, enhance coding efficiency, and improve encoding/decoding quality in texture-blurred image patches.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116980596B_ABST
    Figure CN116980596B_ABST
Patent Text Reader

Abstract

The embodiment of the application provides a kind of intra prediction method, encoder, decoder and storage medium, comprising: traversing intra prediction mode, determine the initial prediction value of the initial prediction block corresponding to current block.It is respectively carried out intra prediction filtering and intra prediction smoothing filtering processing to initial prediction block, obtain first type prediction value and second type prediction value;Intra prediction smoothing filtering is the process that a plurality of adjacent reference pixels in each adjacent reference pixel set in at least two adjacent reference pixel sets are filtered to current block.Using initial prediction value, first type prediction value and second type prediction value, rate distortion cost calculation is carried out with the original pixel value of current block, determine the current prediction mode corresponding to optimal rate distortion cost.Using current prediction mode, intra prediction is carried out to current block.The index information of current prediction mode and filter identification are written in code stream, and filter identification represents the identification corresponding to intra prediction filtering and / or intra prediction smoothing filtering.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of PCT International Patent Application No. PCT / CN2020 / 121668, filed on October 16, 2020, entitled "Intra Prediction Method, Encoder, Decoder and Storage Medium", which entered the Chinese national phase as Chinese Patent Application No. 202080106028.7. TECHNICAL FIELD

[0002] Embodiments of the present application relate to video coding technology, and in particular, but not exclusively, to an intra prediction method, an encoder, a decoder and a storage medium. BACKGROUND

[0003] In video coding, in the process of coding a current block, in addition to the inter prediction mode, the intra prediction mode can also be used. The intra prediction mode can calculate a prediction block for each coding unit through an intra prediction process.

[0004] In the prior art, the intra prediction mode is usually used to predict a prediction block for a current block by means of respective angle modes and non-angle modes. According to rate-distortion cost information calculated from the prediction block and the original block, the optimal prediction mode of the current block is selected, and then the intra prediction is performed based on the prediction mode. In the current intra angle prediction, all reference pixels are not used, and the correlation between some pixels and the current block is easily ignored. The intra prediction filtering technology can effectively enhance the spatial correlation by improving the pixel prediction accuracy through point-to-point filtering. Therefore, the intra prediction filtering technology can effectively enhance the spatial correlation by improving the pixel prediction accuracy through point-to-point filtering, thereby improving the intra prediction accuracy.

[0005] However, in the intra prediction of an image block with relatively blurred texture, the over-sharpened prediction of the intra prediction filtering technology may increase and enlarge the residual, and the prediction effect is not good, thereby reducing the coding efficiency. SUMMARY

[0006] Embodiments of the present application provide an intra prediction method, an encoder, a decoder and a storage medium, which can smooth the prediction process of an image block and improve the coding efficiency.

[0007] In a first aspect, an embodiment of the present application provides an intra prediction method applied to an encoder, the method comprising:

[0008] traversing the intra prediction modes to determine an initial prediction value of an initial prediction block corresponding to the current block;

[0009] performing intra prediction filtering and intra prediction smoothing filtering on the initial prediction block respectively to obtain a first type of prediction value and a second type of prediction value; wherein the intra prediction smoothing filtering is a process of filtering the current block by using multiple adjacent reference pixels in each of at least two adjacent reference pixel sets;

[0010] performing rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value respectively with original pixel values of the current block to determine a current prediction mode corresponding to an optimal rate-distortion cost;

[0011] performing intra prediction on the current block by using the current prediction mode;

[0012] writing index information of the current prediction mode and filtering identification into a bitstream, wherein the filtering identification represents identification corresponding to the intra prediction filtering and / or the intra prediction smoothing filtering.

[0013] In a second aspect, an embodiment of the present application provides an intra prediction method applied to a decoder, and the method comprises the following steps:

[0014] obtaining a bitstream, and parsing header information of the bitstream to obtain the filtering identification;

[0015] when the filtering identification is valid identification representing that the intra prediction filtering is allowed and the intra prediction smoothing filtering is allowed, obtaining a current prediction mode and intra prediction filtering usage identification from the bitstream at least;

[0016] when the intra prediction filtering usage identification is invalid and valid intra prediction smoothing filtering usage identification is obtained from the bitstream, performing intra prediction smoothing filtering on a current block based on the current prediction mode to obtain a first prediction value.

[0017] In a third aspect, an embodiment of the present application provides an encoder, comprising:

[0018] a first determination part configured to traverse intra prediction modes to determine an initial prediction value of an initial prediction block corresponding to a current block;

[0019] a first filtering part configured to perform intra prediction filtering and intra prediction smoothing filtering on the initial prediction block respectively to obtain a first type of prediction value and a second type of prediction value; wherein the intra prediction smoothing filtering is a process of filtering the current block by using multiple adjacent reference pixels in each of at least two adjacent reference pixel sets;

[0020] The first determining part is further configured to perform rate-distortion cost calculation on the initial prediction value, the first type prediction value and the second type prediction value respectively with original pixel values of the current block, and determine a current prediction mode corresponding to an optimal rate-distortion cost.

[0021] The first prediction part is configured to perform intra prediction on the current block by using the current prediction mode.

[0022] The writing part is configured to write index information of the current prediction mode and filter identification into a bitstream, wherein the filter identification represents identification corresponding to intra prediction filtering and / or intra prediction smoothing filtering.

[0023] In a fourth aspect, an embodiment of the present application provides a decoder, comprising:

[0024] The parsing part is configured to acquire a bitstream, parse header information of the bitstream to obtain the filter identification, and when the filter identification is valid and the intra prediction smoothing filtering identification is valid, acquire at least the current prediction mode and the intra prediction filtering identification from the bitstream.

[0025] The second prediction part is configured to perform intra prediction smoothing filtering processing on the current block based on the current prediction mode to obtain a first prediction value when the intra prediction filtering identification is invalid and the valid intra prediction smoothing filtering identification is acquired from the bitstream.

[0026] In a fifth aspect, an embodiment of the present application further provides an encoder, comprising:

[0027] A first memory and a first processor;

[0028] The first memory stores a computer program capable of running on the first processor, and the first processor implements the intra prediction method of the encoder when executing the program.

[0029] In a sixth aspect, an embodiment of the present application further provides a decoder, comprising:

[0030] A second memory and a second processor;

[0031] The second memory stores a computer program capable of running on the second processor, and the second processor implements the intra prediction method of the decoder when executing the program.

[0032] In a seventh aspect, an embodiment of the present application provides a storage medium, comprising:

[0033] A computer program is stored on the computer readable medium, and when the computer program is executed by the first processor, the computer program implements the intra prediction method of the encoder, or when the computer program is executed by the second processor, the computer program implements the intra prediction method of the decoder.

[0034] The embodiment of the present application provides an intra prediction method, an encoder, a decoder and a storage medium, and the process of filtering the current block by using one adjacent reference pixel in each adjacent reference pixel set in at least two adjacent reference pixel sets is realized by using the intra prediction filtering of the encoder. The intra prediction smoothing filtering can refer to multiple adjacent reference pixels in one adjacent reference pixel set, so that the prediction is smoother, the prediction for the fuzzy image is more accurate, and therefore the coding efficiency can be improved. BRIEF DESCRIPTION OF DRAWINGS

[0035] Figures 1A-1C Exemplary component distribution diagrams in different color formats are provided for the embodiment of the present application.

[0036] Figure 2 Exemplary partition diagrams of coding units are provided for the embodiment of the present application.

[0037] Figure 3 Exemplary prediction mode diagrams are provided for the embodiment of the present application.

[0038] Figures 4A-4C Exemplary three filtering condition diagrams of intra prediction filtering are provided for the embodiment of the present application.

[0039] Figure 5 Exemplary component structure diagrams of network architecture of video coding are provided for the embodiment of the present application.

[0040] Figure 6 Exemplary video coding system structure diagrams are provided for the embodiment of the present application.

[0041] Figure 7 Exemplary video decoding system structure diagrams are provided for the embodiment of the present application.

[0042] Figure 8 A flowchart one of an intra prediction method is provided for the embodiment of the present application.

[0043] Figures 9A-9C Exemplary target reference pixel diagrams are provided for the embodiment of the present application.

[0044] Figure 10 A flowchart of an intra prediction method is provided for the embodiment of the present application. Figure 2 ;

[0045] Figure 11A flowchart of an intra prediction method is also provided for the embodiments of the present application.

[0046] Figure 12 A structural schematic diagram of an encoder is provided for the embodiments of the present application.

[0047] Figure 13 A structural schematic diagram of an encoder is provided for the embodiments of the present application. Figure 2 ;

[0048] Figure 14 A structural schematic diagram of a decoder is provided for the embodiments of the present application.

[0049] Figure 15 A structural schematic diagram of a decoder is provided for the embodiments of the present application. Figure 2 . DETAILED DESCRIPTION

[0050] The technical solutions in the embodiments of the present application will be described clearly and completely below with reference to the drawings in the embodiments of the present application. It can be understood that the specific embodiments described herein are only used to explain the related application, but not to limit the application. In addition, it should be noted that, for the convenience of description, only the parts related to the application are shown in the drawings.

[0051] In a video image, a current block (Coding Block, CB) is generally represented by a first image component, a second image component and a third image component; wherein the three image components are a luminance component, a blue chrominance component and a red chrominance component respectively, specifically, the luminance component is usually represented by a symbol Y, the blue chrominance component is usually represented by a symbol Cb or U, and the red chrominance component is usually represented by a symbol Cr or V; in this way, the video image can be represented in YCbCr format or YUV format.

[0052] Generally, digital video compression technology acts on image data in YCbCr (YUV) format, and the YUV ratio is 4:2:0, 4:2:2 or 4:4:4, Y represents luminance (Luma), Cb (U) represents blue chrominance, and Cr (V) represents red chrominance. U and V represent chrominance (Chroma) for describing color and saturation. Figures 1A-1C The distribution diagrams of components in different color formats are shown, wherein white represents Y component and black and gray represent UV components. As shown in Figure 1A 4:2:0 represents that there are 4 luminance components and 2 chrominance components (YYYYCbCr) for every 4 pixels in terms of color format, as shown in Figure 1B 4:2:2 represents that there are 4 luminance components and 4 chrominance components (YYYYCbCrCbCr) for every 4 pixels, and as Figure 1CAs shown, 4:4:4 represents full-pixel display (YYYYCbCrCbCrCbCrCbCr).

[0053] Currently, the common video coding standards are based on a hybrid block-based coding framework. Each frame in a video image is partitioned into square-shaped largest coding units (LCU) of the same size (e.g., 128x128, 64x64, etc.), each of which can be further partitioned into rectangular coding units (CU) according to a rule; and a coding unit can be further partitioned into smaller prediction units (PU). Specifically, the hybrid coding framework can include prediction, transform, quantization, entropy coding, in loop filter, etc. modules; where the prediction module can include intra prediction and inter prediction, and the inter prediction can include motion estimation and motion compensation. Due to the strong correlation between adjacent pixels in a frame of a video image, using intra prediction in video coding techniques can eliminate spatial redundancy between adjacent pixels. Inter prediction can refer to image information of different frames, use motion estimation to search for motion vector information that best matches the current partitioned block, and is used to eliminate temporal redundancy; transform converts the predicted image block to the frequency domain, energy is redistributed, and combined with quantization, information that is not sensitive to the human eye can be removed, and is used to eliminate visual redundancy; entropy coding can eliminate character redundancy according to the current context model and probability information of the binary code stream.

[0054] It should be noted that in the video coding process, the encoder first reads the image information, partitions the image into a plurality of coding tree units (CTU), and each coding tree unit can be further partitioned into a plurality of coding units (CU). These coding units can be rectangular blocks or square blocks, and the specific relationship can be referred to as shown in Figure 2

[0055] ​In the intra prediction process, the current coding unit cannot refer to the information of different frame images, but can only use the adjacent coding units of the same frame image as reference information for prediction, that is, according to the current most left-to-right and top-to-bottom coding order, the current coding unit can refer to the upper left coding unit, the upper coding unit and the left coding unit as reference information to predict the current coding unit, and the current coding unit is also used as the reference information of the next coding unit, and so on for the whole image. If the input digital video is in color format, that is, the current mainstream digital video encoder input source is in YUV 4:2:0 format, that is, every 4 pixel points of the image are composed of 4 Y components and 2 UV components, the encoder will encode the Y component and the UV component respectively, and the encoding tools and techniques used are slightly different. At the same time, the decoding end will also decode according to different formats.

[0056] For the intra prediction part of digital video coding and decoding, the information of the adjacent block image of the current frame is mainly referred to for predicting the current block. After calculating the residual information of the predicted block and the original image block, the residual information is transmitted to the decoding end through the processes of transformation and quantization. After receiving and analyzing the code stream, the decoding end obtains the residual information through the steps of inverse transformation and inverse quantization. The predicted image block obtained by the decoding end is superimposed with the residual information to obtain the reconstructed image block.

[0057] In this process, intra prediction usually predicts the current coding block to obtain a prediction block by means of respective angle modes and non-angle modes, selects the optimal prediction mode of the current coding unit according to the rate-distortion information calculated from the prediction block and the original block, and then transmits the prediction mode to the decoding end through a code stream. The decoding end analyzes the prediction mode, predicts a prediction image of the current decoding block, and superimposes the residual pixels transmitted through the code stream, so as to obtain a reconstructed image. Through the development of digital video coding standards of past generations, the non-angle mode remains relatively stable, with a mean mode and a plane mode; the angle mode is continuously increased with the evolution of digital video coding standards. For example, the H series of international digital video coding standards, the H.264 / AVC standard has only 8 angle prediction modes and 1 non-angle prediction mode; the H.265 / HEVC is expanded to 33 angle prediction modes and 2 non-angle prediction modes; and the latest general video coding standard H.266 / VVC adopts 67 prediction modes, of which 2 non-angle prediction modes are retained, and the angle mode is expanded from 33 in H.265 to 65. Needless to say, with the increase of the angle mode, the intra prediction will be more accurate and more in line with the current social demand for high-definition and ultra-high-definition video development. Not only international standards, but also domestic digital audio and video coding standards 3 (Audio Video coding Standard, AVS3) continue to expand the angle mode and the non-angle mode. The development of ultra-high-definition digital video puts forward higher requirements for intra prediction, which cannot simply rely on increasing angle prediction modes and expanding wide angles to improve coding efficiency. Therefore, the domestic digital audio and video coding standard AVS3 adopts the intra prediction filtering technology (Intra Prediction Filter, IPF), which points out that the current intra angle prediction does not use all the reference pixels, and some pixels are easily ignored in the correlation between the current coding unit. The IPF technology improves the pixel prediction accuracy through point-to-point filtering, can effectively enhance the spatial correlation, and thus improve the intra prediction accuracy. The IPF technology takes the prediction mode from the top right to the bottom left in AVS3 as an example, as shown in Figure 3

[0058] The prediction mode direction is from the top right to the bottom left, and the generated prediction value of the current coding unit mainly uses the reference pixels of the MRB row of the adjacent block, that is, the prediction pixels of the current coding unit do not refer to the reconstructed pixels of the left adjacent block. However, the current coding unit and the left reconstructed block have a spatial adjacent relationship, and if only the MRB pixels on the upper side are referred to without referring to the URB pixels on the left side, the spatial correlation is easily missed, resulting in poor prediction effect.

[0059] ​To solve this problem, an Intra Prediction Filter (IPF) is proposed, which is a filtering method applied to all the prediction modes of intra prediction to improve the accuracy of intra prediction.

[0060] The IPF is implemented mainly through the following process:

[0061] 1. The IPF determines the current prediction mode of the coding unit and classifies it into a horizontal angle prediction mode, a vertical angle prediction mode, and a non-angle prediction mode.

[0062] 2. According to different types of prediction modes, the IPF uses different filters to filter the input pixels.

[0063] 3. According to the different distances of the current pixel to the reference pixel, the IPF uses different filter coefficients to filter the input pixels.

[0064] 4. The input pixels of the IPF are the predicted pixels obtained under each prediction mode, and the output pixels are the final predicted pixels after IPF filtering.

[0065] The IPF has an enable flag ipf_enable_flag (intra prediction filter enable flag), which is an example binary variable. A value of '1' indicates that the intra prediction filter can be used, and a value of '0' indicates that the intra prediction filter should not be used. The IPF also has a use flag ipf_flag (intra prediction filter use flag), which is an example binary variable. A value of '1' indicates that the intra prediction filter should be used, and a value of '0' indicates that the intra prediction filter should not be used. If the flag ipf_flag is not present in the code stream, it is defaulted to 0.

[0066] The syntax element of ipf_flag is shown as follows:

[0067]

[0068] It should be noted that the IPF classifies prediction modes 0, 1, and 2 as non-angle prediction modes and uses a first three-tap filter to filter the predicted pixels. Prediction modes 3 to 18, prediction modes 34 to 50 are classified as vertical angle prediction modes, and a first two-tap filter is used to filter the predicted pixels. Prediction modes 19 to 32, prediction modes 51 to 65 are classified as horizontal angle prediction modes, and a second two-tap filter is used to filter the predicted pixels. Among them,

[0069] The first three-tap filter applicable to the IPF is shown in formula (1):

[0070] P'(x, y) = f(x) P(-1, y) + f(y) P(x, -1) + (1 - f(x) - f(y)) P(x, y) (1)

[0071] The first three-tap filter suitable for the IPF technique is described above, and the filtering formula is shown in formula (2):

[0072] P'(x, y) = f(x) P(-1, y) + (1 - f(x)) P(x, y) (2)

[0073] The second two-tap filter suitable for the IPF technique is described above, and the filtering formula is shown in formula (3):

[0074] P'(x, y) = f(y) P(x, -1) + (1 - f(y)) P(x, y) (3)

[0075] wherein P'(x, y) is the final prediction value of the pixel at position (x, y) in the current chroma prediction block, f(x) and f(y) are respectively the horizontal filtering coefficient of the reconstructed pixel of the reference left neighboring block and the vertical filtering coefficient of the reconstructed pixel of the reference upper neighboring block, P(-1, y) and P(x, -1) are respectively the left reconstructed pixel in the y-th row and the upper reconstructed pixel in the x-th column, and P(x, y) is the original prediction pixel value in the current chroma component prediction block. The values of x and y are within the range of the width and height of the current coding unit.

[0076] It should be noted that the values of the horizontal filtering coefficient and the vertical filtering coefficient are related to the size of the current coding unit and the distance between the prediction pixel in the current prediction block and the left reconstructed pixel and the upper reconstructed pixel. The horizontal filtering coefficient can be divided into different filter coefficient groups according to the size of the current coding unit. Table 1 shows the filter coefficients of the intra prediction filtering technique.

[0077] Table 1

[0078]

[0079]

[0080] Exemplarily, Figures 4A-4C Three filtering cases of the intra prediction filtering are shown in the schematic diagrams, which respectively filter the prediction values in the current coding unit only by referring to the upper reference pixels (i.e. Figure 4A the upper two-tap filtering); filter the prediction values in the current coding unit only by referring to the left reference pixels (i.e. Figure 4B the left two-tap filtering); and filter the prediction values in the current coding unit by referring to both the upper and left reference pixels (i.e. Figure 4CTop and left three-tap filtering.

[0081] The IPF technology acts on the intra prediction part in the hybrid framework of video coding, and is applied to all prediction modes of intra prediction, and simultaneously acts on the encoding end and the decoding end.

[0082] Based on the above concept, the embodiment of the present application provides a network architecture of a video coding and decoding system containing an intra prediction method, Figure 5 The composition structure diagram of the network architecture of the video coding and decoding system of the embodiment of the present application is shown in Figure 5 The network architecture includes one or more electronic devices 12 to 1N and a communication network 01, wherein the electronic devices 12 to 1N can perform video interaction through the communication network 01. The electronic devices in the implementation process can be various types of devices with video coding and decoding functions, for example, the electronic devices can include a mobile phone, a tablet computer, a personal computer, a personal digital assistant, a navigator, a digital telephone, a video telephone, a television, a sensing device, a server, etc., and the embodiment of the present application is not limited. The intra prediction device in the embodiment of the present application can be the above-mentioned electronic device.

[0083] The electronic device in the embodiment of the present application has a video coding and decoding function, generally includes a video encoder (i.e., an encoder) and a video decoder (i.e., a decoder).

[0084] The present application provides a video coding system, as shown in Figure 6 The video coding system 11 includes:

[0085] The video decoding system 12 includes: a transform unit 111, a quantization unit 112, a mode selection and coding control logic unit 113, an intra prediction unit 114, an inter prediction unit 115 (including: motion compensation and motion estimation), a dequantization unit 116, an inverse transform unit 117, a loop filter unit 118, an encoding unit 119, and a decoded picture buffer unit 110; for an input original video signal, a video reconstruction block can be obtained through Coding Tree Unit (CTU) division, a coding mode is determined by the mode selection and coding control logic unit 113, then, the video reconstruction block is transformed by the transform unit 111 and the quantization unit 112, including transforming residual information from a pixel domain to a transform domain, and quantizing the obtained transform coefficients, to further reduce the bit rate; the intra prediction unit 114 is configured to perform intra prediction on the video reconstruction block; wherein the intra prediction unit 114 is configured to determine an optimal intra prediction mode (i.e., a target prediction mode) of the video reconstruction block; the inter prediction unit 115 is configured to perform inter prediction coding of the received video reconstruction block relative to one or more blocks in one or more reference frames to provide temporal prediction information; wherein, the motion estimation is a process of generating a motion vector which can estimate the motion of the video reconstruction block, then, the motion compensation performs motion compensation based on the motion vector determined by the motion estimation; after determining the inter prediction mode, the inter prediction unit 115 is further configured to provide the selected inter prediction data to the encoding unit 119, and also send the calculated determined motion vector data to the encoding unit 119; in addition, the dequantization unit 116 and the inverse transform unit 117 are configured to reconstruct the video reconstruction block, reconstruct a residual block in the pixel domain, remove blockiness artifacts of the reconstructed residual block by the loop filter unit 118, then, add the reconstructed residual block to a predictive block in one of the frames of the decoded picture buffer unit 110 to generate a reconstructed video reconstruction block; the encoding unit 119 is configured to encode various coding parameters and quantized transform coefficients. The decoded picture buffer unit 110 is configured to store the reconstructed video reconstruction block for prediction reference. As the video image coding proceeds, new reconstructed video reconstruction blocks are continuously generated, which are all stored in the decoded picture buffer unit 110.

[0086] The embodiment of the present application provides a video decoding system, Figure 7 The video encoding system 12 includes: Figure 7

[0087] ​The decoding unit 121, the inverse transformation unit 127, the inverse quantization unit 122, the intra prediction unit 123, the motion compensation unit 124, the loop filter unit 125 and the decoded image buffer unit 126; the video signal input is processed by the video encoding system 11 to encode the video signal; the code stream of the video signal is input into the video decoding system 12, first through the decoding unit 121, to obtain the decoded transform coefficients; the transform coefficients are processed by the inverse transformation unit 127 and the inverse quantization unit 122, to generate the residual block in the pixel domain; the intra prediction unit 123 can be used to generate the prediction data of the current video decoding block based on the determined intra prediction direction and the data from the previously decoded block of the current frame or picture; the motion compensation unit 124 determines the prediction information for the video decoding block by parsing the motion vector and other associated syntax elements, and uses the prediction information to generate the predictive block of the video decoding block being decoded; the decoded video block is formed by summing the residual block from the inverse transformation unit 127 and the inverse quantization unit 122 and the corresponding predictive block generated by the intra prediction unit 123 or the motion compensation unit 124; the decoded video signal is filtered by the loop filter unit 125 to remove the blocking artifacts, which can improve the video quality; then the decoded video block is stored in the decoded image buffer unit 126, which stores the reference image for subsequent intra prediction or motion compensation, and also for the output of the video signal, to obtain the recovered original video signal.

[0088] The implementation of the encoder using IPT for intra prediction coding mode is as follows:

[0089] In the current coding unit, if the IPF permission identification bit is '1', all the following steps are performed, and if the IPF permission identification bit is '0', only steps a), b) and f) are performed:

[0090] a), intra prediction first traverses all prediction modes, calculates the prediction pixels under each intra prediction mode, and calculates the rate-distortion cost according to the original pixels;

[0091] b), according to the minimum rate-distortion cost principle of all the above prediction modes, the optimal prediction mode of the current coding unit is selected, and the optimal prediction mode information and the corresponding rate-distortion cost information are recorded;

[0092] c), all intra prediction modes are traversed again, and the IPF technology is started, first calculating the prediction pixels under each intra prediction mode to obtain the prediction block of the current coding unit;

[0093] d) IPF filtering is performed on the prediction block of the current coding unit, a filter corresponding to the current prediction mode is selected according to the current coding unit size, and a corresponding filter coefficient set is selected according to the current coding unit size. The specific correspondence can be found in Table 1.

[0094] e) The rate-distortion cost information of each prediction mode is calculated according to the final prediction pixel obtained through the IPF filtering technology and the original pixel, and the prediction mode with the minimum rate-distortion cost information and the corresponding cost value are recorded.

[0095] f) If the IPF permission identification bit is '0', the prediction mode index recorded in b) is transmitted to the decoding end through the code stream; if the IPF permission identification bit is '1', the minimum cost value recorded in b) is compared with the minimum cost value recorded in e), if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the code stream, and the IPF current coding unit identification bit is set to false, indicating that the IPF technology is not used, which is also transmitted to the decoding end through the code stream; if the rate-distortion in e) is smaller, the prediction mode index recorded in e) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the code stream, and the IPF current coding unit identification bit is set to true, indicating that the IPF technology is used, which is also transmitted to the decoding end through the code stream.

[0096] Then, the prediction value is superimposed with the residual information after the operations such as transformation and quantization, to obtain the reconstructed block of the current coding unit as the reference information of the subsequent coding unit.

[0097] The implementation of the decoder using IPT for intra prediction coding mode is as follows:

[0098] The decoding end obtains the code stream and parses the digital video sequence information, parses the IPF permission identification bit of the current video sequence, the current decoding unit coding mode is intra prediction coding mode, and the IPF use identification bit of the current decoding unit.

[0099] In the current decoding unit, if the IPF permission identification bit is '1', all the following steps are performed; if the IPF permission identification bit is '0', only steps a), b) and e) are performed:

[0100] a) Obtain the code stream information, parse the residual information of the current decoding unit, and obtain the time domain residual information through the inverse transformation and inverse quantization process;

[0101] b) Parse the code stream and obtain the prediction mode index of the current decoding unit, calculate the prediction block of the current decoding unit according to the adjacent reconstructed block and the prediction mode index;

[0102] c) parsing and obtaining the IPF usage flag of the IPF, if the IPF usage flag of the IPF is '0', no additional operation is performed on the current prediction block; if the IPF usage flag of the IPF is '1', d) is performed;

[0103] d) selecting a corresponding filter according to the prediction mode classification information of the current decoding unit, selecting a corresponding filter coefficient set according to the size of the current decoding unit, and then filtering each pixel in the prediction block to obtain a final prediction block;

[0104] The prediction block is superimposed with the residual information after restoration to obtain a reconstructed block of the current decoding unit, which is output after processing.

[0105] However, the intra prediction filtering technology can effectively improve the coding efficiency of intra prediction, greatly enhance the spatial correlation of intra prediction, and well solve the problem that the influence of unused reference pixels on the prediction value is ignored in the intra prediction process. However, when the intra prediction process needs to be smoothed, neither the intra prediction filtering technology nor the current intra prediction mode can well solve the similar problem. The pixel-by-pixel filtering according to the reference pixels can improve the correlation between the prediction block and the reference block, but cannot solve the smoothing problem in the prediction block.

[0106] That is, the prediction block calculated according to a single prediction mode usually has a better prediction effect in an image with relatively clear texture, and the residual is smaller and less, and the coding efficiency is improved. However, in an image block with relatively blurred texture, the too sharp prediction may cause the residual to increase and become large, the prediction effect is not good, and the coding efficiency is reduced.

[0107] Based on this, when performing intra prediction, the prediction block is subjected to the technology, and for some image blocks that need to be smoothed, the application provides an intra prediction method based on a smoothing processing intra prediction filtering enhancement technology. The intra prediction method provided in the embodiments of the application mainly acts on the intra prediction unit 114 of the video encoding system 11 and the intra prediction unit 123 of the video decoding system 12; that is, if a better prediction effect can be obtained by the intra prediction method provided in the embodiments of the application in the video encoding system 11, the video decoding recovery quality can also be improved at the decoding end.

[0108] Based on this, the technical solutions of the application are further described in detail below in combination with the drawings and embodiments. Before the detailed description, it should be noted that "first", "second", "third", etc. mentioned throughout the specification are only to distinguish different features, and do not have the functions of limiting priority, sequence, size relationship, etc.

[0109] The embodiment of the present application provides a kind of intra prediction method, this method is applied to video coding device, i.e. The function realized by the method can be realized by calling program code by processor in video coding device, of course, program code can be saved in computer storage medium, it can be seen, the video coding device at least includes processor and storage medium.Therein, current coding unit and current decoding unit are described as current block below.

[0110] Figure 8 For the implementation flowchart of the intra prediction method of the embodiment of the present application, as shown in Figure 8 The method comprises:

[0111] S101, traverse intra prediction mode, determine the initial prediction value of the initial prediction block corresponding to the current block.

[0112] S102, the initial prediction block is respectively subjected to intra prediction filtering and intra prediction smoothing filtering processing, to obtain first type prediction value and second type prediction value;Wherein, intra prediction smoothing filtering is the process that a plurality of adjacent reference pixels in each adjacent reference pixel set in at least two adjacent reference pixel sets are filtered to the current block.

[0113] S103, initial prediction value, first type prediction value and second type prediction value are respectively calculated with the original pixel value of current block to determine the optimal rate distortion cost corresponding to current prediction mode.

[0114] S104, using current prediction mode, the current block is subjected to intra prediction.

[0115] S105, the index information of current prediction mode and filter identification are written into code stream, wherein, filter identification represents the identification corresponding to intra prediction filtering and / or intra prediction smoothing filtering.

[0116] In the embodiment of the present application, a kind of intra prediction smoothing filtering technology (Intra Prediction Smooth, IPS) is proposed, on the basis of IPF, IPS technology can be superimposed to realize intra prediction.IPF and IPS are all allowed, and the intra prediction process of encoder side is carried out.

[0117] In the embodiment of the present application, video image can be divided into multiple image blocks, each current image block to be coded can be called coding block, wherein each coding block can include first image component, second image component and third image component;And current block is the coding block that first image component, second image component or third image component prediction in current video image is carried out.

[0118] It is assumed that the current block is predicted by the first image component, and the first image component is a luminance component, i.e., the image component to be predicted is a luminance component, and the current block can also be referred to as a luminance block. Alternatively, it is assumed that the current block is predicted by the second image component, and the second image component is a chroma component, i.e., the image component to be predicted is a chroma component, and the current block can also be referred to as a chroma block.

[0119] It is to be noted that the encoder determines the image component to be predicted of the current block, and performs prediction encoding on the image component to be predicted by using the plurality of prediction modes based on the parameters of the current block to obtain initial prediction values, and then calculates the rate-distortion cost corresponding to each of the plurality of prediction modes based on the initial prediction values. The minimum rate-distortion cost (i.e., the first minimum rate-distortion cost) is selected from the plurality of calculated rate-distortion costs, and the minimum rate-distortion cost is determined as the optimal rate-distortion cost. The prediction mode corresponding to the optimal rate-distortion cost is determined as the prediction mode of the current block.

[0120] In the embodiments of the present application, after it is determined that the encoder traverses all the intra prediction modes, the initial prediction value of the initial prediction block corresponding to the current block is determined, and then the IPF and IPS technologies are used to perform filtering on the current block to obtain the first type of prediction value and the second type of prediction value. The initial prediction value, the first type of prediction value, and the second type of prediction value are used to perform rate-distortion cost calculation with the original pixel value of the current block, respectively, to determine three minimum rate-distortion costs corresponding thereto, respectively. The minimum rate-distortion cost among the three minimum rate-distortion costs is selected as the optimal rate-distortion cost. The prediction mode corresponding to the optimal rate-distortion cost is the current prediction mode. The current prediction mode is used to perform intra prediction on the current block to complete the prediction of the image component to be predicted.

[0121] It is to be noted that the intra prediction smoothing filtering is a process of filtering the current block by using a plurality of adjacent reference pixels in each of the at least two adjacent reference pixel sets. The intra prediction filtering is a process of filtering the current block by using one adjacent reference pixel in each of the at least two adjacent reference pixel sets. The intra prediction smoothing filtering can refer to a plurality of adjacent reference pixels in one adjacent reference pixel set, and thus the prediction is smoother, the prediction for a blurred image is more accurate, and the coding efficiency is improved.

[0122] In the embodiments of the present application, the encoder adopts the IPF and IPS technologies to filter the current block, and the process of obtaining the first type of prediction value and the second type of prediction value is: one is to obtain the initial prediction block corresponding to the current block, and then to perform IPF and IPS processing on the initial prediction block respectively; the other is that the encoder reiterates all the intra prediction modes, and only when the IPF is enabled, the initial prediction block under each intra prediction mode is calculated, and then the initial prediction block is filtered by IPF to determine the first type of prediction value. Then, the encoder reiterates all the intra prediction modes again, and only when the IPS is enabled, the initial prediction block under each intra prediction mode is calculated, and then the initial prediction block is filtered by IPS to determine the second type of prediction value, which is not limited in the embodiments of the present application.

[0123] In some embodiments of the present application, the process of the encoder performing intra prediction filtering and intra prediction smoothing filtering on the initial prediction block to obtain the first type of prediction value and the second type of prediction value can be: the encoder performs intra prediction filtering on each pixel in the initial prediction block based on the left and upper adjacent reference pixel points of each pixel to obtain the first type of prediction value; and the encoder performs intra prediction smoothing filtering on the initial prediction block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel to obtain the second type of prediction value.

[0124] It should be noted that the encoder performs IPF filtering on the prediction block of the current block, selects the filter corresponding to the currently iterated prediction mode, selects the corresponding filter coefficient set according to the size of the current block, and the specific corresponding relationship can be checked in Table 1. After determining the filter coefficient, the prediction block is filtered based on the filter coefficient to obtain the rate-distortion cost of each prediction mode, and the second smallest rate-distortion cost is selected from the minimum rate-distortion cost.

[0125] In some embodiments of the present application, the process of the encoder performing IPS filtering can be based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the initial prediction block to determine at least two adjacent reference block ranges of at least two adjacent reference pixel sets corresponding to each pixel; from the at least two adjacent reference pixel sets, at least two target reference pixel sets belonging to the at least two adjacent reference block ranges are correspondingly determined; each target reference pixel set contains at least one target reference pixel; each pixel is subjected to intra prediction smoothing filtering based on the at least two target reference pixel sets to obtain the second type of prediction value.

[0126] In some embodiments of the present application, the process of the encoder correspondingly determining at least two target reference pixel sets belonging to at least two adjacent reference block ranges from at least two adjacent reference pixel sets can be:

[0127] In a first mode, the encoder determines, from the at least two neighboring reference pixel sets, a target reference pixel set of pixels at each of two boundary pixel positions of a neighboring reference block range of each of the at least two neighboring reference pixel sets.

[0128] In a second mode, the encoder determines, from the at least two neighboring reference pixel sets, a target reference pixel set of M pixels at any pixel position within a neighboring reference block range of each of the at least two neighboring reference pixel sets, where M is greater than 0 and does not exceed a maximum number of pixels in the corresponding neighboring reference pixel set.

[0129] In some embodiments of the present application, the at least two neighboring reference pixel sets include a left neighboring reference pixel set and an above neighboring reference pixel set, the at least two neighboring reference block ranges include a left neighboring reference pixel range and an above neighboring reference pixel range, and the at least two target reference pixel sets include a left target neighboring reference pixel set and an above target neighboring reference pixel set.

[0130] It should be noted that when the at least two neighboring reference pixel sets include a left neighboring reference pixel set and an above neighboring reference pixel set, the encoder determines a preset horizontal distance and a preset vertical distance corresponding to the current pixel, and moves the current pixel of the current block by the preset horizontal distance to the left and right to obtain a first horizontal pixel position and a second horizontal pixel position, and moves the current pixel of the current block by the preset vertical distance to the up and down to obtain a first vertical pixel position and a second vertical pixel position. Based on the first horizontal pixel position and the second horizontal pixel position, the first boundary limit and the second boundary limit of the pixel position are determined by mapping to the above neighboring reference pixel set, and the pixel position between the first boundary limit and the second boundary limit is the above neighboring reference pixel range corresponding to the above neighboring reference pixel set corresponding to the current pixel. Based on the first vertical pixel position and the second vertical pixel position, the third boundary limit and the fourth boundary limit of the pixel position are determined by mapping to the left neighboring reference pixel set, and the pixel position between the third boundary limit and the fourth boundary limit is the left neighboring reference pixel range corresponding to the left neighboring reference pixel set corresponding to the current pixel. In this way, the at least two neighboring reference block ranges are obtained. For each neighboring reference pixel set, the encoder can select at least one neighboring reference pixel (i.e., a target reference pixel set) from the reference pixels included in the neighboring reference pixel range corresponding to the neighboring reference pixel set for intra prediction, thereby selecting the at least two target reference pixel sets.

[0131] In the embodiments of the present application, the encoder does so for each pixel of the current block, thereby completing the processing of the current block. For the current pixel, the number of reference pixels in the target reference pixel set selected by the encoder from the neighboring reference pixel set can be one or multiple, which is determined based on the position of the current pixel in the current block.

[0132] It should be noted that the encoder can select the reference pixel values corresponding to the boundary positions of each neighboring reference pixel range to form the target reference pixel set, or select any M reference pixels from each neighboring reference pixel range to form the target reference pixel set, where M is greater than 0, and the embodiments of the present application do not limit this.

[0133] It should be noted that the number of M reference pixels corresponding to the determined neighboring reference pixel set can be different or the same, and the embodiments of the present application do not limit this. For example, the target reference pixel set corresponding to the upper neighboring reference pixel set can be UPNum, and the target reference pixel set corresponding to the left neighboring reference pixel set can be LFNum, where UPNum and LFNum can be the same or different.

[0134] In some embodiments of the present application, the preset horizontal distance is less than or equal to the width of the initial prediction block, and the preset vertical distance is less than or equal to the height of the initial prediction block.

[0135] In some embodiments of the present application, the preset horizontal distance and the preset vertical distance corresponding to the first type of pixels in the n rows and m columns of the initial prediction block are different from the preset horizontal distance and the preset vertical distance corresponding to other types of pixels in the initial prediction block except the n rows and m columns; n and m are natural numbers; the preset horizontal distance and the preset vertical distance corresponding to each pixel in the first type of pixels are at least partially the same or all different; and the preset horizontal distance and the preset vertical distance corresponding to each pixel in the other types of pixels are at least partially the same or all different.

[0136] It should be noted that the preset horizontal distance and the preset vertical distance are equal, and the specific values can be set in the encoder and the decoder according to the actual situation, or can be preset in the encoder and the decoder according to the size of the current prediction block, and the embodiments of the present application do not limit this.

[0137] In the embodiments of the present application, the n rows and m columns of the initial prediction block can be the first n rows and the first m columns, or other forms, and the embodiments of the present application do not limit this.

[0138] For example, the first n rows and the first m columns can use the reference pixels corresponding to the first position relationship, and the other non-first n rows and non-first m columns can use the reference pixels corresponding to the second position relationship. For example, the first three rows and the first three columns can use HD and VD both being 1, and the non-first three rows and non-first three columns can use HD and VD both being 2.

[0139] wherein n and m are not more than the size of the current block, and n and m can be the same or different, which is not limited in the embodiments of the present application.

[0140] In some embodiments of the present application, the encoder can determine the filter coefficients according to the principle mechanism of the IPF; perform the intra prediction smoothing filter processing on each pixel based on the at least two target reference pixel sets and the filter coefficients to obtain the second type of prediction values.

[0141] wherein the filter coefficients corresponding to the first type of pixels in the n rows and m columns of the initial prediction block are different from the filter coefficients corresponding to the other types of pixels in the initial prediction block except the n rows and m columns; n and m are natural numbers; the filter coefficients corresponding to each pixel in the first type of pixels are at least partially the same or all different; and the filter coefficients corresponding to each pixel in the other types of pixels are at least partially the same or all different.

[0142] In the embodiments of the present application, the IPS technology can have multiple different filter coefficients, such as the coefficients used when the current prediction pixel is in the first n rows and the first m columns being different from the filter coefficients used when the current prediction pixel is in the non-first n rows and the non-first m columns, and the filter coefficients corresponding to each pixel in the first n rows and the first m columns can also be the same, partially the same, or all different; and the filter coefficients corresponding to each pixel in the non-first n rows and the non-first m columns can also be the same, partially the same, or all different.

[0143] It should be noted that in some embodiments of the embodiments of the present application, the encoder can determine the weight coefficients; perform the weighted summation on each pixel based on the at least two target reference pixel sets and the weight coefficients to complete the intra prediction smoothing filter processing and obtain the second type of prediction values. Wherein the IPS technology can have multiple different weight coefficients, such as the coefficients used when the current prediction pixel is in the first n rows and the first m columns being different from the weight coefficients used when the current prediction pixel is in the non-first n rows and the non-first m columns, and the weight coefficients corresponding to each pixel in the first n rows and the first m columns can also be the same, partially the same, or all different; and the weight coefficients corresponding to each pixel in the non-first n rows and the non-first m columns can also be the same, partially the same, or all different.

[0144] For example, the encoder uses the position of the current prediction pixel as a reference, obtains UPNum reconstructed reference pixels on the upper side and LFNum reconstructed reference pixels on the left side as offsets with horizontal distance HD and vertical distance VD, filters or can be weighted-sums the obtained reference pixels and the current prediction pixel to obtain an accurate prediction pixel as the final prediction pixel of the current position in the prediction block.

[0145] For example, as shown in the diagram of 4 target reference pixels with a distance of 2, a is the current pixel, b and c are the adjacent reference pixel range, the encoder obtains 4 reference pixels and the prediction pixel to form a 5-tap filter or weighted to obtain the accurate corrected prediction pixel value. In the given specific example, the coefficients of the first two rows and the first two columns of the 4 reference pixels can be set to 10, the weighted coefficient of the prediction pixel without accurate correction is 216, the total sum needs to be divided by 256 or right shifted by 8 bits, and the VD and HD of the first two rows and the first two columns can be set to 1; the weighted coefficients of the 4 reference pixels other than the first two rows and the first two columns are set to 13, the coefficient of the prediction pixel without accurate correction is 204, and the total sum needs to be divided by 256 or right shifted by 8 bits. Figure 9A For example, as shown in the diagram of 4 target reference pixels with a distance of 1, a is the current pixel, b and c are the adjacent reference pixel range, the encoder obtains 4 reference pixels and the prediction pixel to form a 5-tap filter or weighted to obtain the accurate corrected prediction pixel value. In the given specific example, the weighted coefficients of the 4 reference pixels can be set to 7, the weighted coefficient of the prediction pixel without accurate correction is 228, and the total sum needs to be divided by 256 or right shifted by 8 bits.

[0146] Figure 9B For example, as shown in the diagram of 2 target reference pixels with a distance of 0, a is the current pixel, b and c are the adjacent reference pixel range, the encoder obtains 2 reference pixels and the prediction pixel to form a 3-tap filter or weighted to obtain the accurate corrected prediction pixel value. In the given specific example, the weighted coefficients of the 2 reference pixels can be set to 14, the weighted coefficient of the prediction pixel without accurate correction is 228, and the total sum needs to be divided by 256 or right shifted by 8 bits.

[0147] For example, as shown in the diagram of 2 target reference pixels with a distance of 0, a is the current pixel, b and c are the adjacent reference pixel range, the encoder obtains 2 reference pixels and the prediction pixel to form a 3-tap filter or weighted to obtain the accurate corrected prediction pixel value. In the given specific example, the weighted coefficients of the 2 reference pixels can be set to 14, the weighted coefficient of the prediction pixel without accurate correction is 228, and the total sum needs to be divided by 256 or right shifted by 8 bits. Figure 9C In the embodiments of the present application, the prediction pixel obtained by the encoder using the IPS technology can be different from other cases, for example, using 4-tap different filter coefficients or other number of taps different filter coefficients to obtain the second type of prediction value of the prediction pixel used by the IPS.

[0148]

[0149] ​​In some embodiments of the present application, when the encoder filters the current block using the IPS technology, if the coordinates of the required reconstructed reference pixels, i.e. the reference pixels in the target reference pixel set, exceed the size range of the upper neighboring reference pixel set or the left neighboring reference pixel set, the neighboring reference pixel set of the current block can also be padded before the selection of the target reference pixel set.

[0150] In some embodiments of the present application, when the preset horizontal distance is greater than the width of the initial prediction block, the leftmost reference pixel in the upper neighboring reference pixel set is padded to the left until the first boundary limit of the range of the upper neighboring reference block is determined, and / or the rightmost reference pixel in the upper neighboring reference pixel set is padded to the right until the second boundary limit of the range of the upper neighboring reference block is determined; when the preset vertical distance is less than or equal to the height of the initial prediction block, the lowermost reference pixel in the left neighboring reference pixel set is padded to the down until the third boundary limit of the range of the left neighboring reference block is determined, and / or the uppermost reference pixel in the left neighboring reference pixel set is padded to the up until the fourth boundary limit of the range of the left neighboring reference block is determined.

[0151] For example, the encoder pads the leftmost reconstructed reference pixel of the upper neighboring reconstructed pixel to the left until the required range is met, pads the rightmost reconstructed reference pixel of the upper neighboring reconstructed pixel to the right until the required range is met, pads the uppermost reconstructed reference pixel of the left neighboring reconstructed pixel to the up until the required range is met, and pads the left neighboring reconstructed pixel to the down until the required range is met. The above padding process can also be replaced by a conditional judgment method, i.e. the pixels exceeding the range are directly selected as the pixels at the boundary, and the present embodiments do not limit the padding process.

[0152] It should be noted that when the encoder filters the prediction block of the current block using the IPS technology, the filter corresponding to the current prediction mode is selected according to the current prediction mode, the filter coefficient is determined, the prediction block is filtered based on the filter coefficient, the rate-distortion cost of each prediction mode is obtained, and the third minimum rate-distortion cost is selected from the minimum rate-distortion cost.

[0153] In some embodiments of the present application, after obtaining the first type of prediction value and the second type of prediction value, the encoder performs rate-distortion cost calculation on the original pixel value of the current block, the initial prediction value, the first type of prediction value and the second type of prediction value respectively, to determine a first minimum rate-distortion cost corresponding to the initial prediction value, a second minimum rate-distortion cost corresponding to the first type of prediction value and a third minimum rate-distortion cost corresponding to the second type of prediction value; the encoder determines the optimal rate-distortion cost from the first minimum rate-distortion cost, the second minimum rate-distortion cost and the third minimum rate-distortion cost; and the encoder determines the prediction mode corresponding to the optimal rate-distortion cost as the current prediction mode. In this way, the encoder can perform intra prediction on the current block using the current prediction mode, and write the index information of the current prediction mode and the filter identifier into the bitstream, wherein the filter identifier represents the identifier corresponding to the intra prediction filtering and / or the intra prediction smoothing filtering.

[0154] In the embodiments of the present application, the filter identifier includes an intra prediction filtering enabled identifier, an intra prediction filtering used identifier, an intra prediction smoothing filtering enabled identifier and an intra prediction smoothing filtering used identifier.

[0155] In some embodiments of the present application, since the IPF and the IPS are used, the encoder determines that the intra prediction filtering enabled identifier and the intra prediction smoothing filtering enabled identifier are valid, and writes the intra prediction filtering enabled identifier and the intra prediction smoothing filtering enabled identifier into the bitstream.

[0156] The transmission of the intra prediction filtering used identifier and the intra prediction smoothing filtering used identifier to the decoder complies with one of the following transmission modes:

[0157] When the optimal rate-distortion cost is the second minimum rate-distortion cost, the encoder determines that the intra prediction filtering used identifier is valid, and writes the intra prediction filtering used identifier into the bitstream.

[0158] When the optimal rate-distortion cost is the third minimum rate-distortion cost, the encoder determines that the intra prediction filtering used identifier is invalid, and the intra prediction smoothing filtering used identifier is valid, and writes the intra prediction filtering used identifier and the intra prediction smoothing filtering used identifier into the bitstream.

[0159] When the optimal rate-distortion cost is the first minimum rate-distortion cost, the encoder determines that the intra prediction filtering used identifier is invalid, and the intra prediction smoothing filtering used identifier is invalid, and writes the intra prediction filtering used identifier and the intra prediction smoothing filtering used identifier into the bitstream.

[0160] In the embodiments of the present application, binary numbers can be used to represent whether the identifier is valid or invalid, for example, 1 represents valid and 0 represents invalid, or 0 represents valid and 1 represents invalid, and the specific setting method and setting value are not limited in the embodiments of the present application.

[0161] It can be understood that the encoder uses the intra prediction filtering to implement the process of filtering the current block using one neighboring reference pixel in each of the at least two neighboring reference pixel sets. The intra prediction smoothing filtering is smoother and more accurate for the prediction of a blurred image, and thus the coding efficiency is improved.

[0162] In some embodiments of the present application, there are three to-be-predicted components, and the encoding of Y, U and V three encoding channels is implemented, that is, the encoding type of the initial prediction value corresponds to multiple encoding channels. Then, the filtering identifier corresponding to each encoding channel uses the same identifier or a one-to-one corresponding identifier.

[0163] That is, the IPS technology is applied to each encoding channel, and the independent identifier bit is used to represent whether the IPS technology is used for the luminance component and the chrominance component.

[0164] It can be understood that the encoder uses one filtering identifier for the three encoding channels, which can save the bit and the data amount of the transmission identifier bit and reduce the complexity of the calculation.

[0165] In some embodiments of the present application, the encoder can first determine whether the current block meets the condition of IPS processing, and if not, the IPS is not used, or the current block is divided into a block meeting the condition. If yes, the intra prediction method proposed in the present application is used. Wherein,

[0166] When the size of the initial prediction block meets the prediction area threshold range, the intra prediction smoothing filtering is allowed to be used for filtering processing.

[0167] When the size of the initial prediction block is greater than the upper limit of the prediction area threshold range, the initial prediction block is divided to obtain a prediction sub-block meeting the prediction area threshold range, and the intra prediction processing flow is implemented for the prediction sub-block.

[0168] The prediction area threshold range can be not less than 4*4 or 8*8, and not more than 64*64 or 32*32. The detailed values can be set according to the actual situation. The area that is too small can not be processed by IPS, but the area that is too large can be divided to meet the IPS condition and then processed.

[0169] It can be understood that the encoder limits the use range of the IPS, and the IPS technology is not used for the unit with a small prediction block area, so as to reduce the transmission identifier bit and reduce the calculation complexity.

[0170] In some embodiments of the present application, after the encoder determines the initial prediction value of the initial prediction block corresponding to the current block, before the encoder performs intra prediction on the current block using the current prediction mode, the encoder can determine a prediction mode set according to the type of the intra prediction mode, the prediction mode set being a prediction mode that enables the intra prediction smoothing filtering technique; perform intra prediction smoothing filtering processing on the initial sub-prediction value in the initial prediction value, which is predicted using the prediction mode set, to obtain a second type of prediction value; and perform rate-distortion cost calculation on the initial prediction value and the second type of prediction value, respectively, and the original pixel value of the current block, to determine the current prediction mode corresponding to the optimal rate-distortion cost.

[0171] It can be understood that the encoder limits the use range of IPS, filters the prediction mode of the current block, and only uses the IPS technique for part of the prediction modes to reduce the transmission of the identification bit and reduce the calculation complexity.

[0172] In some embodiments of the present application, the manner in which the encoder obtains the first type of prediction value and the second type of prediction value can further include:

[0173] After the encoder traverses the intra prediction mode, determines the initial prediction value of the initial prediction block corresponding to the current block, and before the encoder performs rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value, respectively, and the original pixel value of the current block to determine the current prediction mode corresponding to the optimal rate-distortion cost, the encoder performs intra prediction filtering on the initial prediction block to obtain the first type of prediction value; and traverses the intra prediction mode, and performs prediction estimation on the current block using intra prediction smoothing filtering processing to obtain the second type of prediction value.

[0174] That is, the encoder can traverse the intra prediction mode again, perform intra prediction smoothing filtering processing on the current block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block to obtain the second type of prediction value; and does not need to perform filtering processing on the initial prediction value. The implementation principle of the filtering processing performed by the encoder on the current block is consistent with the principle of the filtering processing performed on the initial prediction block in the foregoing embodiments, which will not be described here.

[0175] For example, the encoder obtains encoding information, including an intra prediction filtering (IPF) permission identification bit and a permission identification bit of the present technical solution (IPS), and divides the image into a plurality of CTUs after obtaining the image information, and further divides the CTUs into a plurality of CUs. Each independent CU is subjected to intra prediction, and the current CU can limit the minimum area and the maximum area to perform the IPS technique.

[0176] In the intra prediction process at the encoding end, if both the IPF permission identification bit and the IPS permission identification bit are '1', all the following steps are executed; if the IPF permission identification bit is '1' and the IPS permission identification bit is '0', only a), b), c), d), e), and h) are executed; if the IPF permission identification bit is '0' and the IPS permission identification bit is '1', only a), b), f), g), and h) are executed; if both the IPF permission identification bit and the IPS permission identification bit are '0', only a), b), and h) are executed. If the IPF or IPS permission identification bit is '0', the encoding end defaults the use identification bit of the corresponding technology of all the coding blocks to '0':

[0177] a) The current coding unit traverses all the intra prediction modes, and the prediction block under each prediction mode is calculated. The rate-distortion cost information of the current prediction mode is calculated according to the original pixel block;

[0178] b) According to the minimum rate-distortion cost principle of all the prediction modes, the optimal prediction mode of the current coding unit is selected, and the optimal prediction mode information and the corresponding rate-distortion cost information are recorded;

[0179] c) All the intra prediction modes are traversed. In this process, the IPF technology is used. First, the prediction pixels under each intra prediction mode are calculated to obtain the prediction block of the current coding unit;

[0180] d) The prediction block of the current coding unit is filtered by the IPF. According to the current prediction mode, the corresponding filter is selected, and according to the size of the current coding unit, the corresponding filter coefficient set is selected. The specific corresponding relationship can be found in Table 1;

[0181] e) The rate-distortion cost information of each prediction mode is calculated according to the final prediction pixels obtained by the IPF filtering technology and the original pixels, and the prediction mode with the minimum rate-distortion cost information and the corresponding cost value are recorded;

[0182] f) traversing all intra prediction modes, the process uses IPS technique to calculate the predicted pixels under each intra prediction mode, the process of calculating the predicted pixels uses IPS technique, specifically, the predicted pixels of the process can be obtained by using several tap interpolation filters plus several reference pixels as new interpolation filter prediction, the several tap interpolation filters can be 8 tap filters, the several reference pixels can be 4, the process of obtaining the several reference pixels is as follows: taking the position of each predicted pixel as the benchmark, taking the horizontal distance HD and the vertical distance VD as the offset, obtaining the upper adjacent UPNum reconstructed reference pixels and the left adjacent LFNum reconstructed reference pixels. The HD and VD can take values of 0, 1, 2, 3, …, N, etc., N is not more than the width or height of the current block. The UPNum and LFNum can take values of 0, 1, 2, 3, …, M, etc., M is not more than the number of upper adjacent reconstructed reference pixels and the number of left adjacent reconstructed reference pixels of the current block;

[0183] g) calculating the rate-distortion cost information of each prediction mode according to the final predicted pixels obtained by the IPS technique and the original pixels, recording the prediction mode with the minimum rate-distortion cost information and the corresponding cost value;

[0184] h) if the IPF enable flag is '0' and the IPS enable flag is '0', the prediction mode index recorded in b) is transmitted to the decoding end through the bitstream; if the IPF enable flag is '1' and the IPS enable flag is '0', the minimum rate-distortion cost recorded in b) is compared with the minimum rate-distortion cost recorded in e), if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '0', indicating that the IPF technology is not used, and is also transmitted to the decoding end through the bitstream; if the rate-distortion in e) is smaller, the prediction mode recorded in e) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '1', indicating that the IPF technology is used, and is also transmitted to the decoding end through the bitstream; if the IPF enable flag is '0' and the IPS enable flag is '1', the minimum rate-distortion cost recorded in b) is compared with the minimum rate-distortion cost recorded in g), if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPS current coding unit identification flag is set to '0', indicating that the technology is not used, and is also transmitted to the decoding end through the bitstream; if the rate-distortion in g) is smaller, the prediction mode recorded in g) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPS current coding unit identification flag is set to '1', indicating that the technology is used, and is also transmitted to the decoding end through the bitstream; if the IPF enable flag is '1' and the IPS enable flag is '1', the minimum rate-distortion costs recorded in b), e) and g) are compared, if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPS current coding unit identification flag and the IPF current coding unit identification flag are set to '0', indicating that both are not used, and are also transmitted to the decoding end through the bitstream; if the rate-distortion in e) is smaller, the prediction mode recorded in e) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '1' and the IPS current coding unit identification flag is not transmitted, indicating that the IPF technology is used and the IPS technology is not used, and are also transmitted to the decoding end through the bitstream; if the rate-distortion in g) is smaller, the prediction mode recorded in g) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '0' and the IPS current coding unit identification flag is set to '1', indicating that the IPF technology is not used and the IPS technology is used, and are also transmitted to the decoding end through the bitstream.

[0185] The encoder finally superimposes the prediction block and the residual after inverse transformation and inverse quantization to obtain the reconstructed coding unit block, which is used as the prediction reference block of the next coding block.

[0186] The embodiment of the present application provides an intra prediction method, as shown in the following table, comprising the following steps. Figure 10

[0187] S201, initial prediction values of an initial prediction block corresponding to a current block are determined by traversing intra prediction modes.

[0188] S202, the initial prediction block is respectively subjected to intra prediction smoothing filtering processing to obtain second type prediction values; wherein the intra prediction smoothing filtering is a process of filtering the current block by using multiple adjacent reference pixels in each adjacent reference pixel set in at least two adjacent reference pixel sets.

[0189] S203, the initial prediction values and the second type prediction values are respectively subjected to rate-distortion cost calculation with original pixel values of the current block to determine a current prediction mode corresponding to an optimal rate-distortion cost.

[0190] S204, the current block is subjected to intra prediction by using the current prediction mode.

[0191] S205, index information of the current prediction mode and filtering identification are written into a bitstream, wherein the filtering identification represents identification corresponding to the intra prediction smoothing filtering.

[0192] In the embodiment of the present application, the encoder can only determine whether to perform IPS, and does not depend on the implementation basis of the IPF technology, so that the intra prediction smoothing filtering permission identification is valid.

[0193] In the embodiment of the present application, the encoder only performs IPS, so that when the IPS technology is started, the encoder respectively subjects the initial prediction block to intra prediction smoothing filtering processing to obtain the second type prediction values, and the encoder only needs to adopt the initial prediction values and the second type prediction values to respectively perform rate-distortion cost calculation with original pixel values of the current block to determine the current prediction mode corresponding to the optimal rate-distortion cost. The filtering processing mode is consistent with the implementation of the foregoing embodiment, and will not be described here.

[0194] In the embodiment of the present application, the filtering identification comprises an intra prediction smoothing filtering permission identification and an intra prediction smoothing filtering use identification. The encoder writes the index information of the current prediction mode into the bitstream; determines that the intra prediction smoothing filtering permission identification is valid, and writes the intra prediction smoothing filtering permission identification into the bitstream.

[0195] The transmission mode of the intra prediction smoothing filtering use identification is one of the following modes:

[0196] When the optimal rate-distortion cost is the third minimum rate-distortion cost, it is determined that the intra prediction smoothing filtering use identification is valid, and the intra prediction smoothing filtering use identification is written into the bitstream.​

[0197] When the optimal rate-distortion cost is the first minimum rate-distortion cost, it is determined that the intra prediction smoothing filter usage flag is invalid, and the intra prediction smoothing filter usage flag is written into the bitstream.

[0198] For example, the encoder obtains encoding information, including an intra prediction filter (IPF) permission flag bit and a permission flag bit of the present technical solution (IPS), and after obtaining image information, divides the image into a plurality of CTUs, and further divides the CTUs into a plurality of CUs. Each independent CU is subjected to intra prediction, and the current CU can limit the minimum area and the maximum area to perform the IPS technology.

[0199] In the intra prediction process at the encoding end, if the IPF permission flag bit and the IPS permission flag bit are both '1', all the following steps are executed; if the IPF permission flag bit is '1' and the IPS permission flag bit is '0', only a), b), c), d), e), and i) are executed; if the IPF permission flag bit is '0' and the IPS permission flag bit is '1', only a), b), f), g), h), and i) are executed; if the IPF permission flag bit and the IPS permission flag bit are both '0', only a), b), and i) are executed. If the IPF or IPS permission flag bit is '0', the encoding end defaults the usage flag bit of the corresponding technology of all the encoding blocks to '0':

[0200] a) The current encoding unit traverses all the intra prediction modes, calculates the prediction block under each prediction mode, and calculates the rate-distortion cost information of the current prediction mode according to the original pixel block;

[0201] b) According to the minimum rate-distortion cost principle of all the prediction modes, the optimal prediction mode of the current encoding unit is selected, and the optimal prediction mode information and the corresponding rate-distortion cost information are recorded;

[0202] c) All the intra prediction modes are traversed, and the IPF technology is used. First, the prediction pixels under each intra prediction mode are calculated to obtain the prediction block of the current encoding unit;

[0203] d) The prediction block of the current encoding unit is subjected to IPF filtering. According to the current prediction mode, the corresponding filter is selected, and according to the size of the current encoding unit, the corresponding filter coefficient set is selected. The specific correspondence can be found in Table 1;

[0204] e) The rate-distortion cost information of each prediction mode is calculated according to the final prediction pixels obtained through the IPF filtering technology and the original pixels, and the prediction mode of the minimum rate-distortion cost information and the corresponding cost value are recorded;

[0205] f) traversing all intra prediction modes, this process uses IPS technique, first, it calculates the predicted pixels under each intra prediction mode, and gets the prediction block of the current coding unit. The process of calculating the interpolation filter of intra prediction pixels can be different from steps a) and c), using a stronger filter can get smoother predicted pixels, in the specific implementation, 8-tap interpolation filter can be used for angle prediction mode, and the filter coefficients can be shown in the following 4 groups, each group can include 32 8-tap filter coefficients.

[0206] Set: {15, 99, 238, 315, 237, 101, 18, 1}, {14, 95, 233, 315, 242, 105, 19, 1}, {13, 91, 229, 315, 246, 109, 20, 1}, {12, 89, 226, 314, 248, 112, 22, 1}, {11, 84, 220, 314, 253, 117, 24, 1}, {10, 81, 217, 313, 257, 120, 25, 1}, {9, 77, 211, 312, 262, 125, 27, 1}, {8, 74, 208, 311, 265, 129, 28, 1}, {7, 71, 203, 310, 269, 133, 30, 1}, {7, 68, 200, 309, 271, 136, 32, 1}, {6, 65, 195, 307, 275, 141, 34, 1}, {5, 62, 190, 304, 278, 146, 37, 2}, {5, 59, 185, 302, 282, 150, 39, 2}, {4, 56, 182, 301, 285, 154, 40, 2}, {4, 54, 177, 298, 287, 158, 43, 3}, {3, 51, 172, 296, 290, 163, 46, 3}, {3, 48, 167, 294, 294, 167, 48, 3}, {3, 46, 163, 290, 296, 172, 51, 3}, {3, 43, 158, 287, 298, 177, 54, 4}, {2, 40, 154, 285, 301, 182, 56, 4}, {2, 39, 150, 282, 302, 185, 59, 5}, {2, 37, 146, 278, 304, 190, 62, 5}, {1, 34, 141, 275, 307, 195, 65, 6}, {1, 32, 136, 271, 309, 200, 68, 7}, {1, 30, 133, 269, 310, 203, 71, 7}, {1, 28, 129, 265, 311, 208, 74, 8}, {1, 27, 125, 262, 312, 211, 77, 9}, {1, 25, 120, 257, 313, 217, 81, 10}, {1, 24, 117, 253, 314, 220, 84, 11}, {1, 22, 112, 248, 314, 226, 89, 12}, {1, 20, 109, 246, 315, 229, 91, 13}, {1, 19, 105, 242, 315, 233, 95, 14};

[0207] { 7, 92, 245, 339, 245, 91, 6, -1}, { 6, 87, 239, 339, 250, 96, 8, -1}, { 5, 83, 236, 339, 255, 99, 8, -1}, { 4, 80, 231, 338, 259, 103, 10, -1}, { 3, 75, 226, 338, 265, 108, 11, -2}, { 1, 70, 220, 337, 271, 114, 13, -2}, { 1, 67, 217, 337, 275, 117, 13, -3}, { 0, 64, 211, 335, 279, 122, 16, -3}, {-1, 61, 206, 333, 283, 127, 18, -3}, {-1, 57, 202, 332, 287, 131, 19, -3}, {-2, 53, 196, 330, 292, 137, 21, -3}, {-3, 49, 190, 328, 297, 142, 24, -3}, {-3, 47, 187, 326, 300, 146, 25, -4}, {-3, 43, 181, 324, 305, 151, 27, -4}, {-3, 41, 177, 321, 308, 155, 29, -4}, {-4, 37, 171, 319, 312, 161, 32, -4}, {-4, 35, 166, 315, 315, 166, 35, -4}, {-4, 32, 161, 312, 319, 171, 37, -4}, {-4, 29, 155, 308, 321, 177, 41, -3}, {-4, 27, 151, 305, 324, 181, 43, -3}, {-4, 25, 146, 300, 326, 187, 47, -3}, {-3, 24, 142, 297, 328, 190, 49, -3}, {-3, 21, 137, 292, 330, 196, 53, -2}, {-3, 19, 131, 287, 332, 202, 57, -1}, {-3, 18, 127, 283, 333, 206, 61, -1}, {-3, 16, 122, 279, 335, 211, 64, 0}, {-3, 13, 117, 275, 337, 217, 67, 1}, {-2, 13, 114, 271, 337, 220, 70, 1}, {-2, 11, 108, 265, 338, 226, 75, 3}, {-1, 10, 103, 259, 338, 231, 80, 4}, {-1, 8, 99, 255, 339, 236, 83, 5}, {-1, 8, 96, 250, 339, 239, 87, 6};

[0208] {0, 42, 125, 178, 125, 42, 0, 0}, {-1, 40, 121, 177, 128, 46, 1, 0}, {-1, 37, 118, 177, 130, 48, 3, 0}, {-1, 36, 116, 176, 133, 50, 3, -1}, {-1, 34, 114, 176, 135, 52, 3, -1}, {-2, 32, 110, 175, 138, 56, 4, -1}, {-3, 30, 107, 174, 141, 59, 5, -1}, {-3, 29, 106, 173, 142, 60, 6, -1}, {-3, 28, 104, 172, 143, 62, 7, -1}, {-3, 25, 101, 172, 146, 64, 8, -1}, {-4, 23, 97, 171, 149, 68, 9, -1}, {-4, 21, 94, 170, 152, 71, 10, -2}, {-4, 19, 91, 168, 156, 74, 11, -3}, {-3, 19, 91, 167, 155, 74, 12, -3}, {-3, 20, 90, 165, 155, 75, 13, -3}, {-3, 18, 87, 163, 157, 79, 14, -3}, {-3, 16, 83, 160, 160, 83, 16, -3}, {-3, 14, 79, 157, 163, 87, 18, -3}, {-3, 13, 75, 155, 165, 90, 20, -3}, {-3, 12, 74, 155, 167, 91, 19, -3}, {-3, 11, 74, 156, 168, 91, 19, -4}, {-2, 10, 71, 152, 170, 94, 21, -4}, {-1, 9, 68, 149, 171, 97, 23, -4}, {-1, 8, 64, 146, 172, 101, 25, -3}, {-1, 7, 62, 143, 172, 104, 28, -3}, {-1, 6, 60, 142, 173, 106, 29, -3}, {-1, 5, 59, 141, 174, 107, 30, -3}, {-1, 4, 56, 138, 175, 110, 32, -2}, {-1, 3, 52, 135, 176, 114, 34, -1}, {-1, 3, 50, 133, 176, 116, 36, -1}, {0, 3, 48, 130, 177, 118, 37, -1}, {0, 1, 46, 128, 177, 121, 40, -1};

[0209] Four groups: {21, 105, 235, 302, 235, 105, 21, 0}, {21, 102, 231, 300, 237, 108, 24, 1}, {20, 100, 227, 298, 239, 113, 26, 1}, {19, 97, 223, 296, 241, 117, 29, 2}, {19, 94, 218, 294, 243, 121, 32, 3}, {18, 92, 214, 292, 246, 125, 34, 3}, {17, 89, 210, 290, 248, 129, 37, 4}, {17, 86, 206, 288, 250, 133, 39, 5}, {16, 84, 202, 286, 252, 137, 42, 5}, {15, 81, 198, 284, 254, 141, 45, 6}, {15, 78, 194, 282, 256, 145, 47, 7}, {14, 76, 190, 280, 258, 149, 50, 7}, {13, 73, 186, 277, 260, 154, 53, 8}, {12, 71, 182, 275, 262, 158, 55, 9}, {12, 68, 178, 273, 264, 162, 58, 9}, {11, 65, 174, 271, 267, 166, 60, 10}, {10, 63, 170, 269, 269, 170, 63, 10}, {10, 60, 166, 267, 271, 174, 65, 11}, {9, 58, 162, 264, 273, 178, 68, 12}, {9, 55, 158, 262, 275, 182, 71, 12}, {8, 53, 154, 260, 277, 186, 73, 13}, {7, 50, 149, 258, 280, 190, 76, 14}, {7, 47, 145, 256, 282, 194, 78, 15}, {6, 45, 141, 254, 284, 198, 81, 15}, {5, 42, 137, 252, 286, 202, 84, 16}, {5, 39, 133, 250, 288, 206, 86, 17}, {4, 37, 129, 248, 290, 210, 89, 17}, {3, 34, 125, 246, 292, 214, 92, 18}, {3, 32, 121, 243, 294, 218, 94, 19}, {2, 29, 117, 241, 296, 223, 97, 19}, {1, 26, 113, 239, 298, 227, 100, 20}, {1, 24, 108, 237, 300, 231, 102, 21}.

[0210] g) performing a prediction pixel accurate refinement on the prediction block of the current coding unit, the refinement process can be using the position of the current prediction pixel as a reference, and using a horizontal distance HD and a vertical distance VD as offsets to obtain UPNum reconstructed reference pixels from the top and LFNum reconstructed reference pixels from the left, and then filtering the obtained reference pixels with the current prediction pixel, or can be a weighted summation to obtain an accurate prediction pixel as the final prediction pixel at the current position in the prediction block. The HD and VD can take values of 0, 1, 2, 3, …, N, etc., and N is not more than the width or height of the current block. The UPNum and LFNum can take values of 0, 1, 2, 3, …, M, etc., and M is not more than the number of reconstructed reference pixels from the top and the number of reconstructed reference pixels from the left of the current block;

[0211] h) calculating the rate-distortion cost information of each prediction mode according to the final prediction pixel obtained by the IPS technique and the original pixel, and recording the prediction mode with the minimum rate-distortion cost information and the corresponding cost value;

[0212] i) if the IPF enable flag is '0' and the IPS enable flag is '0', the prediction mode index recorded in b) is transmitted to the decoding end through the bitstream; if the IPF enable flag is '1' and the IPS enable flag is '0', the minimum rate-distortion cost recorded in b) is compared with the minimum rate-distortion cost recorded in e), if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '0', indicating that the IPF technology is not used, and is also transmitted to the decoding end through the bitstream; if the rate-distortion in e) is smaller, the prediction mode recorded in e) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '1', indicating that the IPF technology is used, and is also transmitted to the decoding end through the bitstream; if the IPF enable flag is '0' and the IPS enable flag is '1', the minimum rate-distortion cost recorded in b) is compared with the minimum rate-distortion cost recorded in h), if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPS current coding unit identification flag is set to '0', indicating that the technology is not used, and is also transmitted to the decoding end through the bitstream; if the rate-distortion in h) is smaller, the prediction mode recorded in h) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPS current coding unit identification flag is set to '1', indicating that the technology is used, and is also transmitted to the decoding end through the bitstream; if the IPF enable flag is '1' and the IPS enable flag is '1', the minimum rate-distortion costs recorded in b), e) and h) are compared, if the rate-distortion cost in b) is smaller, the prediction mode index recorded in b) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPS current coding unit identification flag and the IPF current coding unit identification flag are set to '0', indicating that both are not used, and are also transmitted to the decoding end through the bitstream; if the rate-distortion in e) is smaller, the prediction mode recorded in e) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '1' and the IPS current coding unit identification flag is not transmitted, indicating that the IPF technology is used and the IPS technology is not used, and are also transmitted to the decoding end through the bitstream; if the rate-distortion in h) is smaller, the prediction mode recorded in h) is encoded as the optimal prediction mode of the current coding unit and transmitted to the decoding end through the bitstream, the IPF current coding unit identification flag is set to '0' and the IPS current coding unit identification flag is set to '1', indicating that the IPF technology is not used and the IPS technology is used, and are also transmitted to the decoding end through the bitstream.

[0213] The encoder finally superimposes the prediction block and the residual after inverse transformation and inverse quantization to obtain the reconstructed coding unit block, which is used as the prediction reference block of the next coding unit.

[0214] It can be understood that the encoder uses the intra prediction smoothing filtering technology to strengthen the spatial correlation of the intra prediction, and the plurality of reference pixels in the adjacent reference pixel set are smoothed, so that the problem that the too sharp prediction may cause the residual to increase and become large and the prediction effect to be poor is avoided, and the coding efficiency is improved.

[0215] The embodiment of the application provides an intra prediction method, which is applied to a video decoding device, that is, a decoder. The function realized by the method can be realized by calling program code by a processor in the video decoding device. Of course, the program code can be saved in a computer storage medium. Therefore, the video coding device at least includes a processor and a storage medium.

[0216] Figure 11 For the implementation process of the intra prediction method of the embodiment of the application, as shown in Figure 11 the method comprises the following steps.

[0217] S301, code stream is acquired, and header information of the code stream is parsed to obtain a filtering identifier.

[0218] S302, when the filtering identifier is valid and the intra prediction smoothing filtering permission identifier is valid, at least a current prediction mode and an intra prediction filtering use identifier are acquired from the code stream.

[0219] S303, when the intra prediction filtering use identifier is invalid and the valid intra prediction smoothing filtering use identifier is acquired from the code stream, based on the current prediction mode, intra prediction smoothing filtering processing is performed on the current block to obtain a first prediction value.

[0220] In the embodiment of the application, after the decoder acquires the code stream information, whether the IPF and the IPS are processed can be parsed from the header information of the code stream. That is, the intra prediction filtering permission identifier and / or the intra prediction smoothing filtering permission identifier in the filtering identifier can be parsed. When the IPF and the IPS are used, the filtering identifier is valid and the intra prediction smoothing filtering permission identifier is valid. At this time, the decoder can at least acquire the current prediction mode and the intra prediction filtering use identifier from the code stream. When the intra prediction filtering use identifier is invalid and the valid intra prediction smoothing filtering use identifier is acquired from the code stream, that is, in the case that the current block uses the current prediction mode determined by the IPS technology, based on the current prediction mode, the intra prediction smoothing filtering processing is performed on the current block, and the first prediction value can be obtained. Then, the subsequent decoding process is performed based on the first prediction value.

[0221] In some embodiments of the present application, when the intra prediction filtering is enabled, the current prediction mode is obtained from the bitstream; and the current block is subjected to the intra prediction filtering based on the current prediction mode to obtain the second prediction value.

[0222] In some embodiments of the present application, the decoder subjects the current block to the intra prediction smoothing filtering based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block to obtain the first prediction value.

[0223] In some embodiments of the present application, based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block, at least two adjacent reference block ranges of at least two adjacent reference pixel sets corresponding to each pixel are determined.

[0224] From the at least two adjacent reference pixel sets, at least two target reference pixel sets belonging to the at least two adjacent reference block ranges are determined correspondingly; each target reference pixel set contains at least one target reference pixel.

[0225] Based on the at least two target reference pixel sets, each pixel is subjected to the intra prediction smoothing filtering to obtain the first prediction value.

[0226] In some embodiments of the present application, the decoder determines the at least two target reference pixel sets from the at least two adjacent reference pixel sets in the following manner:

[0227] Manner one: from the at least two adjacent reference pixel sets, the pixels at the two boundary pixel positions of each adjacent reference block range are determined as a target reference pixel set, thereby determining the at least two target reference pixel sets.

[0228] Manner two: from the at least two adjacent reference pixel sets, M pixels at any pixel position in each adjacent reference block range are determined as a target reference pixel set, thereby determining the at least two target reference pixel sets, wherein M is greater than 0 and does not exceed the maximum number of pixels in the corresponding adjacent reference pixel set.

[0229] In some embodiments of the present application, the at least two adjacent reference pixel sets include a left adjacent reference pixel set and an upper adjacent reference pixel set.

[0230] The at least two adjacent reference block ranges include a left adjacent reference pixel range and an upper adjacent reference pixel range.

[0231] The at least two target reference pixel sets include a left target adjacent reference pixel set and an upper target adjacent reference pixel set.

[0232] In some embodiments of the present application, the preset horizontal distance is less than or equal to the width of the initial prediction block; and the preset vertical distance is less than or equal to the height of the initial prediction block.

[0233] The preset horizontal distance and the preset vertical distance corresponding to the first type of pixels in the n rows and m columns of the initial prediction block are different from the preset horizontal distance and the preset vertical distance corresponding to other types of pixels in the initial prediction block except for the n rows and m columns; n and m are natural numbers.

[0234] The preset horizontal distance and the preset vertical distance corresponding to each pixel in the first type of pixels are at least partially the same or all different.

[0235] The preset horizontal distance and the preset vertical distance corresponding to each pixel in the other types of pixels are at least partially the same or all different.

[0236] In some embodiments of the present application, the at least two target reference pixel sets are used to perform the intra prediction smoothing filtering on each pixel to obtain the first prediction value, including: determining a filtering coefficient by the decoder; and performing the intra prediction smoothing filtering on each pixel based on the at least two target reference pixel sets and the filtering coefficient to obtain the first prediction value.

[0237] In some embodiments of the present application, the filtering coefficient corresponding to the first type of pixels in the n rows and m columns of the initial prediction block is different from the filtering coefficient corresponding to other types of pixels in the initial prediction block except for the n rows and m columns; n and m are natural numbers.

[0238] The filtering coefficient corresponding to each pixel in the first type of pixels is at least partially the same or all different.

[0239] The filtering coefficient corresponding to each pixel in the other types of pixels is at least partially the same or all different.

[0240] In some embodiments of the present application, when the preset horizontal distance is greater than the width of the initial prediction block, the leftmost reference pixel in the upper adjacent reference pixel set is filled to the left until the first boundary limit of the range of the upper adjacent reference block is determined, and / or the rightmost reference pixel in the upper adjacent reference pixel set is filled to the right until the second boundary limit of the range of the upper adjacent reference block is determined.

[0241] When the preset vertical distance is less than or equal to the height of the initial prediction block, the lowermost reference pixel in the left adjacent reference pixel set is filled to the down until the third boundary limit of the range of the left adjacent reference block is determined, and / or the uppermost reference pixel in the left adjacent reference pixel set is filled to the up until the fourth boundary limit of the range of the left adjacent reference block is determined.

[0242] It should be noted that the principle of the decoder implementing the filtering process is consistent with the encoder in the embodiments of the present application, which will not be described here.

[0243] For example, the decoder acquires the code stream, and parses the code stream to obtain the IPF permission identification bit and the IPS permission identification bit of the current video sequence.

[0244] In the intra prediction decoding process, if the IPF permission identification bit and the IPS permission identification bit are both '1', all the following steps are executed; if the IPF permission identification bit is '1' and the IPS permission identification bit is '0', only steps a), b), c), d) and g) are executed; if the IPF permission identification bit is '0' and the IPS permission identification bit is '1', only steps a), b), e), f) and g) are executed; if the IPF permission identification bit and the IPS permission identification bit are both '0', only steps a), b) and g) are executed. If the IPF or IPS permission identification bit is '0', the decoding end defaults the use identification bit of the corresponding technology of all the decoded blocks to '0':

[0245] a) acquires the code stream and decodes to obtain residual information, and obtains time domain residual information through inverse transformation and inverse quantization and the like;

[0246] b) parses the code stream to obtain the prediction mode of the current decoding unit, and calculates a prediction block according to the prediction mode of the current decoding unit and the neighboring reconstructed blocks;

[0247] c) parses and acquires the use identification bit of the IPF, if the use identification bit of the IPF is '0', no additional operation is performed on the current prediction block, and step d) is skipped; if the use identification bit of the IPF is '1', step d) is executed;

[0248] d) selects a corresponding filter according to the prediction mode classification information of the current decoding unit, selects a corresponding filter coefficient set according to the size of the current decoding unit, and then filters each pixel in the prediction block to obtain the prediction block;

[0249] e) acquires the use identification bit of the IPF, if the use identification bit of the IPF is '1', the remaining process of the step is skipped and step f) is skipped; if the use identification bit of the IPF is '0', the use identification bit of the IPS is parsed and acquired. If the use identification bit of the IPS is '0', no additional operation is performed on the current prediction block, and step f) is skipped; if the use identification bit of the IPS is '1', step f) is executed;

[0250] f) performing a pixel-precise refinement of the prediction block of the current coding unit, which can be a process using the position of the current prediction pixel as a reference, obtaining UPNum neighboring reconstructed reference pixels above and LFNum neighboring reconstructed reference pixels to the left of the current prediction pixel with a horizontal distance HD and a vertical distance VD as offsets, filtering the obtained reference pixels with the current prediction pixel, or can be a weighted summation to obtain a refined prediction pixel as the final prediction pixel at the current position in the prediction block. The HD and VD can take values of 0, 1, 2, 3, …, N, etc., and N is not more than the width or height of the current block. The UPNum and LFNum can take values of 0, 1, 2, 3, …, M, etc., and M is not more than the number of neighboring reconstructed reference pixels above and to the left of the current block;

[0251] g) obtaining the reconstructed block of the current coding unit by superimposing the residual information restored in step a) with the prediction block, and outputting after processing.

[0252] For example, the implementation of the decoder side can also use the following implementation, and the embodiments of the present application are not limited. As follows:

[0253] The decoder obtains the code stream, parses the code stream to obtain the IPF permission identification bit and the IPS permission identification bit of the current video sequence.

[0254] In the intra prediction decoding process, if the IPF permission identification bit and the IPS permission identification bit are both '1', all the following steps are executed; if the IPF permission identification bit is '1' and the IPS permission identification bit is '0', only steps a), b), and d) are executed; if the IPF permission identification bit is '0' and the IPS permission identification bit is '1', only steps a), c), and d) are executed; if the IPF permission identification bit and the IPS permission identification bit are both '0', only steps a) and d) are executed. If the IPF or IPS permission identification bit is '0', the decoding end defaults the use identification bit of the corresponding technology of all decoded blocks to '0':

[0255] a) obtaining the code stream and decoding to obtain the prediction mode information, residual information, time domain residual information obtained after inverse transformation and inverse quantization of the current coding unit;

[0256] b) parsing the code stream to obtain the use identification bit of the IPF of the current coding unit;

[0257] c) if the IPF use identification bit of the current coding unit is '0', parsing the code stream to obtain the use identification bit of the IPS; if the IPF use identification bit of the current coding unit is '1', not parsing the use identification bit of the IPS;

[0258] d) If the IPF usage flag is '0' and the IPS usage flag is '0', then calculate the prediction block according to the current prediction mode and skip all remaining steps; if the IPF usage flag is '1', then execute e); if the IPS usage flag is '1', then execute f).

[0259] e) Select the corresponding filter based on the prediction mode classification information of the current decoding unit, select the corresponding filter coefficient group based on the size of the current decoding unit, and then filter each pixel in the prediction block to obtain the prediction block, skipping all remaining steps.

[0260] f) Based on the prediction pattern obtained by the current decoding unit, this process can use an interpolation filter different from those used in steps d) and e) to generate the prediction pixels. An 8-tap interpolation filter, plus several reconstructed reference pixels obtained using the positions of each prediction pixel as a reference, can be used as the interpolation filter for generating the prediction pixels. Specifically, the process of obtaining these reconstructed reference pixels is as follows: using the horizontal distance HD and vertical distance VD as offsets, obtain the upper adjacent UPNum reconstructed reference pixels and the left adjacent LFNum reconstructed reference pixels. HD and VD can take values ​​of 0, 1, 2, 3, ..., N, etc., where N does not exceed the width or height of the current block. UPNum and LFNum can take values ​​of 0, 1, 2, 3, ..., M, etc., where M does not exceed the number of upper adjacent reconstructed reference pixels and the number of left adjacent reconstructed reference pixels of the current block.

[0261] g) The predicted blocks are superimposed on the residual information restored in step a) to obtain the reconstructed block of the current decoding unit, which is then output after post-processing.

[0262] Understandably, the decoder employs intra-frame prediction filtering to filter the current block using one neighboring reference pixel from each of at least two neighboring reference pixel sets. Intra-frame prediction smoothing filtering, because it can reference multiple neighboring reference pixels from a single set, results in smoother predictions and more accurate predictions for blurred images, thus improving decoding efficiency.

[0263] like Figure 12 As shown, this application embodiment provides an encoder 1, including:

[0264] The first determining part 10 is used to traverse the intra-frame prediction mode and determine the initial prediction value of the initial prediction block corresponding to the current block.

[0265] The first filtering part 11 is configured to perform intra prediction filtering and intra prediction smoothing filtering on the initial prediction block respectively to obtain a first type of prediction value and a second type of prediction value; wherein the intra prediction smoothing filtering is a process of filtering the current block by using a plurality of adjacent reference pixels in each of at least two adjacent reference pixel sets.

[0266] The first determining part 10 is further configured to perform rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value respectively with the original pixel value of the current block to determine a current prediction mode corresponding to an optimal rate-distortion cost.

[0267] The first prediction part 12 is configured to perform intra prediction on the current block by using the current prediction mode.

[0268] The writing part 13 is configured to write index information of the current prediction mode and filtering identification into a bitstream, wherein the filtering identification represents identification corresponding to the intra prediction filtering and / or the intra prediction smoothing filtering.

[0269] In some embodiments of the present application, the first filtering part 11 is further configured to perform intra prediction filtering on each pixel in the initial prediction block based on a left adjacent reference pixel point and an upper adjacent reference pixel point of the each pixel to obtain the first type of prediction value; and perform intra prediction smoothing filtering on the initial prediction block based on a preset horizontal distance and a preset vertical distance corresponding to the each pixel to obtain the second type of prediction value.

[0270] In some embodiments of the present application, the first filtering part 11 is further configured to determine at least two adjacent reference block ranges of at least two adjacent reference pixel sets corresponding to each pixel in the initial prediction block based on the preset horizontal distance and the preset vertical distance corresponding to the each pixel; determine at least two target reference pixel sets belonging to the at least two adjacent reference block ranges from the at least two adjacent reference pixel sets; wherein each target reference pixel set contains at least one target reference pixel; perform intra prediction smoothing filtering on the each pixel based on the at least two target reference pixel sets to obtain the second type of prediction value.

[0271] In some embodiments of the present application, the first filtering part 11 is further configured to determine a target reference pixel set containing two boundary pixel positions of each adjacent reference block range from the at least two adjacent reference pixel sets, thereby determining the at least two target reference pixel sets.

[0272] In some embodiments of the present application, the first filtering part 11 is further configured to determine M pixels at any pixel position in each of the adjacent reference block ranges as a target reference pixel set, so as to determine the at least two target reference pixel sets, wherein M is greater than 0 and does not exceed the maximum number of pixels in the corresponding adjacent reference pixel set.

[0273] In some embodiments of the present application, the at least two adjacent reference pixel sets include a left adjacent reference pixel set and an upper adjacent reference pixel set.

[0274] The at least two adjacent reference block ranges include a left adjacent reference pixel range and an upper adjacent reference pixel range.

[0275] The at least two target reference pixel sets include a left target adjacent reference pixel set and an upper target adjacent reference pixel set.

[0276] In some embodiments of the present application, the preset horizontal distance is less than or equal to the width of the initial prediction block; and the preset vertical distance is less than or equal to the height of the initial prediction block.

[0277] The preset horizontal distance and the preset vertical distance corresponding to the first type of pixels at the n rows and m columns of the initial prediction block are different from the preset horizontal distance and the preset vertical distance corresponding to other types of pixels of the initial prediction block except the n rows and m columns; n and m are natural numbers.

[0278] The preset horizontal distance and the preset vertical distance corresponding to each pixel in the first type of pixels are at least partially the same or all different.

[0279] The preset horizontal distance and the preset vertical distance corresponding to each pixel in the other types of pixels are at least partially the same or all different.

[0280] In some embodiments of the present application, the first filtering part 11 is further configured to determine a filter coefficient; and perform an intra prediction smoothing filtering process on the each pixel based on the at least two target reference pixel sets and the filter coefficient, so as to obtain the second type of prediction value.

[0281] In some embodiments of the present application, the filter coefficient corresponding to the first type of pixels at the n rows and m columns of the initial prediction block is different from the filter coefficient corresponding to other types of pixels of the initial prediction block except the n rows and m columns; n and m are natural numbers.

[0282] The filter coefficient corresponding to each pixel in the first type of pixels is at least partially the same or all different.

[0283] The filter coefficients corresponding to each of the other types of pixels are at least partially identical, or all different.

[0284] In some embodiments of the present application, the first determining part 10 is further configured to perform rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value, respectively, with the original pixel value of the current block, to determine a first minimum rate-distortion cost corresponding to the initial prediction value, a second minimum rate-distortion cost corresponding to the first type of prediction value, and a third minimum rate-distortion cost corresponding to the second type of prediction value; determine an optimal rate-distortion cost from the first minimum rate-distortion cost, the second minimum rate-distortion cost and the third minimum rate-distortion cost; and determine the prediction mode corresponding to the optimal rate-distortion cost as the current prediction mode.

[0285] In some embodiments of the present application, the filter identification includes: an intra prediction filter enable identification, an intra prediction filter use identification, an intra prediction smoothing filter enable identification and an intra prediction smoothing filter use identification.

[0286] The writing part 13 is further configured to write the index information of the current prediction mode into a bitstream; determine that the intra prediction filter enable identification is valid and the intra prediction smoothing filter enable identification is valid, and write the intra prediction filter enable identification and the intra prediction smoothing filter enable identification into the bitstream.

[0287] When the optimal rate-distortion cost is the second minimum rate-distortion cost, determine that the intra prediction filter use identification is valid, and write the intra prediction filter use identification into the bitstream.

[0288] When the optimal rate-distortion cost is the third minimum rate-distortion cost, determine that the intra prediction filter use identification is invalid and the intra prediction smoothing filter use identification is valid, and write the intra prediction filter use identification and the intra prediction smoothing filter use identification into the bitstream.

[0289] When the optimal rate-distortion cost is the first minimum rate-distortion cost, determine that the intra prediction filter use identification is invalid and the intra prediction smoothing filter use identification is invalid, and write the intra prediction filter use identification and the intra prediction smoothing filter use identification into the bitstream.

[0290] In some embodiments of the present application, the first filtering part 11 is further configured to, after determining the initial prediction value of the initial prediction block corresponding to the current block according to the traversed intra prediction mode, perform intra prediction smoothing filtering on the initial sub-prediction value in the initial prediction value, which is predicted by the prediction mode set, to obtain the second type of prediction value before performing intra prediction on the current block according to the current prediction mode.

[0291] The first determining part 10 is further configured to perform rate-distortion cost calculation on the initial prediction value and the second type of prediction value respectively with the original pixel value of the current block to determine the current prediction mode corresponding to the optimal rate-distortion cost.

[0292] In some embodiments of the present application, the first filtering part 11 is further configured to, after determining the initial prediction value of the initial prediction block corresponding to the current block according to the traversed intra prediction mode, determine a prediction mode set according to the type of the intra prediction mode before performing intra prediction on the current block according to the current prediction mode, the prediction mode set being a prediction mode enabling intra prediction smoothing filtering; and perform intra prediction smoothing filtering on the initial sub-prediction value in the initial prediction value, which is predicted by the prediction mode set, to obtain the second type of prediction value.

[0293] The first determining part 10 is further configured to perform rate-distortion cost calculation on the initial prediction value and the second type of prediction value respectively with the original pixel value of the current block to determine the current prediction mode corresponding to the optimal rate-distortion cost.

[0294] In some embodiments of the present application, the filtering identifier includes an intra prediction smoothing filtering permission identifier and an intra prediction smoothing filtering use identifier.

[0295] The writing part 13 is further configured to write the index information of the current prediction mode into a bitstream; and determine that the intra prediction smoothing filtering permission identifier is valid and write the intra prediction smoothing filtering permission identifier into the bitstream.

[0296] When the optimal rate-distortion cost is the third minimum rate-distortion cost, it is determined that the intra prediction smoothing filtering use identifier is valid, and the intra prediction smoothing filtering use identifier is written into the bitstream.

[0297] When the optimal rate-distortion cost is the first minimum rate-distortion cost, it is determined that the intra prediction smoothing filtering use identifier is invalid, and the intra prediction smoothing filtering use identifier is written into the bitstream.

[0298] In some embodiments of the present application, the encoding type of the initial prediction value corresponds to multiple encoding channels.

[0299] The filtering identifier corresponding to each encoding channel adopts the same identifier or a one-to-one corresponding identifier.

[0300] In some embodiments of the present application, the first filtering part 11 is further configured to, when the size of the initial prediction block satisfies a prediction area threshold range, allow the use of intra prediction smoothing filtering for filtering processing; when the size of the initial prediction block is greater than the upper limit of the prediction area threshold range, divide the initial prediction block to obtain a prediction sub-block satisfying the prediction area threshold range; and implement the intra prediction processing procedure for the prediction sub-block.

[0301] In some embodiments of the present application, the first filtering part 11 is further configured to, after determining the initial prediction value of the initial prediction block corresponding to the current block by traversing the intra prediction mode, before determining the current prediction mode corresponding to the optimal rate-distortion cost by performing rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value with the original pixel value of the current block, respectively performing intra prediction filtering on the initial prediction block to obtain the first type of prediction value; and performing intra prediction smoothing filtering on the current block by traversing the intra prediction mode to obtain the second type of prediction value.

[0302] In some embodiments of the present application, the first filtering part 11 is further configured to, traverse the intra prediction mode, and perform intra prediction smoothing filtering on the current block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block to obtain the second type of prediction value.

[0303] In some embodiments of the present application, the first determining part 10 is further configured to, when the preset horizontal distance is greater than the width of the initial prediction block, fill leftward with the leftmost reference pixel in the set of upper adjacent reference pixels until the first boundary limit of the range of the upper adjacent reference block is determined, and / or fill rightward with the rightmost reference pixel in the set of upper adjacent reference pixels until the second boundary limit of the range of the upper adjacent reference block is determined.

[0304] When the preset vertical distance is less than or equal to the height of the initial prediction block, fill downward with the lowermost reference pixel in the set of left adjacent reference pixels until the third boundary limit of the range of the left adjacent reference block is determined, and / or fill upward with the uppermost reference pixel in the set of left adjacent reference pixels until the fourth boundary limit of the range of the left adjacent reference block is determined.

[0305] It can be understood that the encoder realizes the process of filtering the current block by using one neighboring reference pixel in each of the at least two neighboring reference pixel sets by using the intra prediction filtering. The intra prediction smoothing filtering can be smoother and more accurate for the blurred image because it can refer to multiple neighboring reference pixels in one neighboring reference pixel set, thereby improving the coding efficiency.

[0306] In practical applications, as shown in Figure 13 The embodiment of the present application further provides an encoder, which comprises:

[0307] a first memory 15 and a first processor 14;

[0308] The first memory 15 stores a computer program capable of running on the first processor 14, and the first processor 14 executes the intra prediction method on the encoder side when the program is executed.

[0309] As shown in Figure 14 The embodiment of the present application provides a decoder 2, which comprises:

[0310] The parsing part 20 is configured to acquire a code stream, parse the header information of the code stream, obtain the filtering identifier, and when the filtering identifier is valid and the intra prediction smoothing filtering identifier is valid, acquire at least a current prediction mode and an intra prediction filtering usage identifier from the code stream.

[0311] The second prediction part 21 is configured to, when the intra prediction filtering usage identifier is invalid and the valid intra prediction smoothing filtering usage identifier is acquired from the code stream, perform the intra prediction smoothing filtering process on the current block based on the current prediction mode, and obtain a first prediction value.

[0312] In some embodiments of the present application, the parsing part 20 is further configured to, after acquiring at least the current prediction mode and the intra prediction filtering usage identifier from the code stream, acquire the current prediction mode from the code stream when the intra prediction filtering usage identifier is valid.

[0313] The second prediction part 21 is further configured to perform the intra prediction filtering process on the current block based on the current prediction mode, and obtain a second prediction value.

[0314] In some embodiments of the present application, the second prediction part 21 is further configured to perform the intra prediction smoothing filtering process on the current block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block, and obtain the first prediction value.

[0315] In some embodiments of the present application, the second prediction unit 21 is further configured to determine at least two adjacent reference block ranges of at least two adjacent reference pixel sets corresponding to each pixel in the current block based on the preset horizontal distance and the preset vertical distance corresponding to the each pixel.

[0316] From the at least two adjacent reference pixel sets, at least two target reference pixel sets belonging to the at least two adjacent reference block ranges are determined, wherein each target reference pixel set contains at least one target reference pixel.

[0317] Based on the at least two target reference pixel sets, the each pixel is subjected to an intra prediction smoothing filtering process to obtain the first prediction value.

[0318] In some embodiments of the present application, the second prediction unit 21 is further configured to determine, from the at least two adjacent reference pixel sets, a target reference pixel set containing two boundary pixel positions of each adjacent reference block range, thereby determining the at least two target reference pixel sets.

[0319] In some embodiments of the present application, the second prediction unit 21 is further configured to determine, from the at least two adjacent reference pixel sets, a target reference pixel set containing M pixels at any pixel position in each adjacent reference block range, thereby determining the at least two target reference pixel sets, wherein M is greater than 0 and does not exceed the maximum number of pixels in the corresponding adjacent reference pixel set.

[0320] In some embodiments of the present application, the at least two adjacent reference pixel sets include a left adjacent reference pixel set and an upper adjacent reference pixel set.

[0321] The at least two adjacent reference block ranges include a left adjacent reference pixel range and an upper adjacent reference pixel range.

[0322] The at least two target reference pixel sets include a left target adjacent reference pixel set and an upper target adjacent reference pixel set.

[0323] In some embodiments of the present application, the preset horizontal distance is less than or equal to the width of the initial prediction block, and the preset vertical distance is less than or equal to the height of the initial prediction block.

[0324] The preset horizontal distance and the preset vertical distance corresponding to the first type of pixels at n rows and m columns of the initial prediction block are different from the preset horizontal distance and the preset vertical distance corresponding to other types of pixels of the initial prediction block except for n rows and m columns; n and m are natural numbers.

[0325] The preset horizontal distance corresponding to each pixel in the first type of pixel and the preset vertical distance are at least partially the same, or are both different.

[0326] The preset horizontal distance corresponding to each pixel in the other type of pixel and the preset vertical distance are at least partially the same, or are both different.

[0327] In some embodiments of the present application, the second prediction part 21 is further configured to determine filter coefficients, and perform intra prediction smoothing filtering on each pixel based on the at least two target reference pixel sets and the filter coefficients to obtain the first prediction value.

[0328] In some embodiments of the present application, the filter coefficients corresponding to the first type of pixel in the n rows and m columns of the initial prediction block are different from the filter coefficients corresponding to the other type of pixel in the initial prediction block except for the n rows and m columns; n and m are natural numbers.

[0329] The filter coefficients corresponding to each pixel in the first type of pixel are at least partially the same, or are both different.

[0330] The filter coefficients corresponding to each pixel in the other type of pixel are at least partially the same, or are both different.

[0331] In some embodiments of the present application, when the preset horizontal distance is greater than the width of the initial prediction block, the leftmost reference pixel in the upper adjacent reference pixel set is filled to the left until the first boundary limit of the upper adjacent reference block range is determined, and / or the rightmost reference pixel in the upper adjacent reference pixel set is filled to the right until the second boundary limit of the upper adjacent reference block range is determined.

[0332] When the preset vertical distance is less than or equal to the height of the initial prediction block, the lowermost reference pixel in the left adjacent reference pixel set is filled to the down until the third boundary limit of the left adjacent reference block range is determined, and / or the uppermost reference pixel in the left adjacent reference pixel set is filled to the up until the fourth boundary limit of the left adjacent reference block range is determined.

[0333] It can be understood that the decoder uses intra prediction filtering to realize the process of filtering the current block using one adjacent reference pixel in each of the at least two adjacent reference pixel sets. The intra prediction smoothing filtering can refer to multiple adjacent reference pixels in one adjacent reference pixel set, so that the prediction is smoother, the prediction for the blurred image is more accurate, and thus the decoding efficiency is improved.

[0334] In actual application, for example,Figure 15 As shown in the above embodiments, the present application further provides a decoder, comprising:

[0335] a second memory 22 and a second processor 23;

[0336] The second memory 22 stores a computer program capable of running on the second processor 23, and the second processor 23 implements the intra prediction method of the decoder when executing the program.

[0337] Correspondingly, the present application provides a storage medium having a computer program stored thereon, which, when executed by a first processor, implements the intra prediction method of the encoder, or which, when executed by a second processor, implements the intra prediction method of the decoder.

[0338] The above merely provides the implementation manners of the present application, but the protection scope of the present application is not limited thereto, and any modification or replacement easily conceived by those skilled in the art within the technical scope disclosed by the present application should be covered within the protection scope of the present application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.

Claims

1. An intra prediction method applied to an encoder, characterized in that, The method comprises the steps of: traversing intra prediction modes to determine an initial prediction value of an initial prediction block corresponding to the current block; performing intra prediction filtering and intra prediction smoothing filtering on the initial prediction block respectively to obtain a first type of prediction value and a second type of prediction value; wherein the intra prediction smoothing filtering is a process of filtering the current block using a plurality of adjacent reference pixels in each adjacent reference pixel set of at least two adjacent reference pixel sets; the at least two adjacent reference pixel sets are used to determine that the pixels of two boundary pixel positions of each adjacent reference block range are a target reference pixel set, thereby determining at least two target reference pixel sets; the at least two adjacent reference block ranges are determined based on a preset horizontal distance and a preset vertical distance corresponding to each pixel in the initial prediction block; the preset horizontal distance is less than or equal to the width of the initial prediction block; the preset vertical distance is less than or equal to the height of the initial prediction block; the at least two target reference pixel sets are used to determine the second type of prediction value; performing rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value respectively with the original pixel value of the current block to determine a current prediction mode corresponding to an optimal rate-distortion cost; performing intra prediction on the current block using the current prediction mode; writing index information of the current prediction mode and filtering identification into a bitstream, wherein the filtering identification represents the identification corresponding to the intra prediction filtering and / or the intra prediction smoothing filtering.

2. The method of claim 1, wherein, The method comprises the steps of: performing intra prediction filtering on each pixel in the initial prediction block based on the left adjacent reference pixel and the upper adjacent reference pixel of each pixel in the initial prediction block to obtain the first type of prediction value; performing intra prediction smoothing filtering on the initial prediction block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the initial prediction block to obtain the second type of prediction value.

3. The method of claim 2, wherein, The method comprises the steps of: determining at least two adjacent reference block ranges of at least two adjacent reference pixel sets corresponding to each pixel in the initial prediction block based on the preset horizontal distance and the preset vertical distance; correspondingly determining at least two target reference pixel sets belonging to the at least two adjacent reference block ranges from the at least two adjacent reference pixel sets; wherein each target reference pixel set contains at least one target reference pixel; performing intra prediction smoothing filtering on each pixel based on the at least two target reference pixel sets to obtain the second type of prediction value; wherein the step of correspondingly determining at least two target reference pixel sets belonging to the at least two adjacent reference block ranges from the at least two adjacent reference pixel sets comprises the steps of: From the at least two adjacent reference pixel sets, M pixels of any pixel position in each adjacent reference block range are determined as a target reference pixel set, so as to determine the at least two target reference pixel sets, wherein M is greater than 0 and does not exceed the maximum number of pixels of the corresponding adjacent reference pixel set.

4. The method of claim 3, wherein, the at least two adjacent reference pixel sets comprise a left adjacent reference pixel set and an upper adjacent reference pixel set; the at least two adjacent reference block ranges comprise a left adjacent reference pixel range and an upper adjacent reference pixel range; the at least two target reference pixel sets comprise a left target adjacent reference pixel set and an upper target adjacent reference pixel set.

5. The method of claim 3, wherein, the preset horizontal distance and the preset vertical distance corresponding to the first type of pixels in the n rows and m columns of the initial prediction block are different from the preset horizontal distance and the preset vertical distance corresponding to other types of pixels in the initial prediction block except the n rows and m columns; n and m are natural numbers; the preset horizontal distance and the preset vertical distance corresponding to each pixel in the first type of pixels are at least partially the same or all different; the preset horizontal distance and the preset vertical distance corresponding to each pixel in the other types of pixels are at least partially the same or all different.

6. The method according to any one of claims 3 to 5, characterized in that, the in-loop prediction smoothing filtering processing of each pixel based on the at least two target reference pixel sets to obtain the second type of prediction value comprises: determining a filtering coefficient; the in-loop prediction smoothing filtering processing of each pixel based on the at least two target reference pixel sets and the filtering coefficient to obtain the second type of prediction value; wherein, the filtering coefficient corresponding to the first type of pixels in the n rows and m columns of the initial prediction block is different from the filtering coefficient corresponding to other types of pixels in the initial prediction block except the n rows and m columns; n and m are natural numbers; the filtering coefficient corresponding to each pixel in the first type of pixels is at least partially the same or all different; the filtering coefficient corresponding to each pixel in the other types of pixels is at least partially the same or all different.

7. The method according to any one of claims 2 to 5, characterized in that, the rate-distortion cost calculation of the initial prediction value, the first type of prediction value and the second type of prediction value with the original pixel value of the current block respectively to determine the current prediction mode corresponding to the optimal rate-distortion cost comprises: the rate-distortion cost calculation of the initial prediction value, the first type of prediction value and the second type of prediction value with the original pixel value of the current block respectively to determine the first minimum rate-distortion cost corresponding to the initial prediction value, the second minimum rate-distortion cost corresponding to the first type of prediction value and the third minimum rate-distortion cost corresponding to the second type of prediction value; from the first minimum rate-distortion cost, the second minimum rate-distortion cost and the third minimum rate-distortion cost, the minimum optimal rate-distortion cost is determined; the prediction mode corresponding to the optimal rate-distortion cost is obtained as the current prediction mode; wherein, The filter identification includes: intra prediction filter enable identification, intra prediction filter use identification, intra prediction smoothing filter enable identification and intra prediction smoothing filter use identification; The writing of the index information of the current prediction mode and the filter identification into the bitstream includes: writing the index information of the current prediction mode into the bitstream; determining that the intra prediction filter enable identification and the intra prediction smoothing filter enable identification are valid, and writing the intra prediction filter enable identification and the intra prediction smoothing filter enable identification into the bitstream; when the optimal rate-distortion cost is the second minimum rate-distortion cost, determining that the intra prediction filter use identification is valid, and writing the intra prediction filter use identification into the bitstream; when the optimal rate-distortion cost is the third minimum rate-distortion cost, determining that the intra prediction filter use identification is invalid and the intra prediction smoothing filter use identification is valid, and writing the intra prediction filter use identification and the intra prediction smoothing filter use identification into the bitstream; when the optimal rate-distortion cost is the first minimum rate-distortion cost, determining that the intra prediction filter use identification is invalid and the intra prediction smoothing filter use identification is invalid, and writing the intra prediction filter use identification and the intra prediction smoothing filter use identification into the bitstream.

8. The method of claim 1, wherein, After the traversal of the intra prediction modes and the determination of the initial prediction value of the initial prediction block corresponding to the current block, before the intra prediction of the current block by using the current prediction mode, the method further includes: determining a prediction mode set according to the type of the intra prediction mode, the prediction mode set being a prediction mode enabling an intra prediction smoothing filter technology; performing intra prediction smoothing filter processing on an initial sub-prediction value predicted by using the prediction mode set from the initial prediction value, to obtain a second type of prediction value; performing rate-distortion cost calculation on the initial prediction value and the second type of prediction value and original pixel values of the current block respectively, to determine the current prediction mode corresponding to the optimal rate-distortion cost; wherein The filter identification includes: intra prediction smoothing filter enable identification and intra prediction smoothing filter use identification; The writing of the index information of the current prediction mode and the filter identification into the bitstream includes: writing the index information of the current prediction mode into the bitstream; determining that the intra prediction smoothing filter enable identification is valid, and writing the intra prediction smoothing filter enable identification into the bitstream; when the optimal rate-distortion cost is the third minimum rate-distortion cost, determining that the intra prediction smoothing filter use identification is valid, and writing the intra prediction smoothing filter use identification into the bitstream; when the optimal rate-distortion cost is the first minimum rate-distortion cost, determining that the intra prediction smoothing filter use identification is invalid, and writing the intra prediction smoothing filter use identification into the bitstream.

9. The method of claim 1, wherein, After the traversing the intra prediction mode to determine the initial prediction value of the initial prediction block corresponding to the current block, before the adopting the initial prediction value, the first prediction value and the second prediction value to respectively perform rate-distortion cost calculation with the original pixel value of the current block to determine the current prediction mode corresponding to the optimal rate-distortion cost, the method further comprises: performing intra prediction filtering on the initial prediction block to obtain the first prediction value; traversing the intra prediction mode, and performing prediction estimation on the current block by using intra prediction smoothing filtering to obtain the second prediction value; wherein, the traversing the intra prediction mode, and performing prediction estimation on the current block by using intra prediction smoothing filtering to obtain the second prediction value comprises: traversing the intra prediction mode, and performing intra prediction smoothing filtering on the current block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block to obtain the second prediction value.

10. An intra prediction method applied to a decoder, characterized in that, comprises: obtaining a code stream, and parsing the header information of the code stream to obtain a filtering identifier; when the filtering identifier is valid and the intra prediction smoothing filtering identifier is valid, obtaining the current prediction mode and the intra prediction filtering usage identifier from the code stream; when the intra prediction filtering usage identifier is invalid and the valid intra prediction smoothing filtering usage identifier is obtained from the code stream, performing intra prediction smoothing filtering on the current block based on the current prediction mode to obtain the first prediction value; wherein, the intra prediction smoothing filtering is a process of filtering the current block by using a plurality of adjacent reference pixels in each adjacent reference pixel set of at least two adjacent reference pixel sets; the at least two adjacent reference pixel sets are used to determine that the pixels of two boundary pixel positions of each adjacent reference block range are a target reference pixel set, so as to determine at least two target reference pixel sets, and the at least two adjacent reference block ranges are determined based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the initial prediction block; the preset horizontal distance is less than or equal to the width of the initial prediction block; the preset vertical distance is less than or equal to the height of the initial prediction block; and the at least two target reference pixel sets are used to determine the first prediction value.

11. The method of claim 10, wherein, the performing intra prediction smoothing filtering on the current block based on the current prediction mode to obtain the first prediction value comprises: performing intra prediction smoothing filtering on the current block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block to obtain the first prediction value.

12. The method of claim 11, wherein, the performing intra prediction smoothing filtering on the current block based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block to obtain the first prediction value comprises: determining at least two adjacent reference block ranges of at least two adjacent reference pixel sets corresponding to each pixel based on the preset horizontal distance and the preset vertical distance corresponding to each pixel in the current block; and correspondingly determining at least two target reference pixel sets belonging to the range of the at least two adjacent reference blocks from the at least two adjacent reference pixel sets, wherein each target reference pixel set contains at least one target reference pixel; performing intra prediction smoothing filtering processing on each pixel based on the at least two target reference pixel sets to obtain the first prediction value; wherein the corresponding determining at least two target reference pixel sets belonging to the range of the at least two adjacent reference blocks from the at least two adjacent reference pixel sets comprises: determining M pixels at any pixel position in each adjacent reference block range as a target reference pixel set from the at least two adjacent reference pixel sets, thereby determining the at least two target reference pixel sets, wherein M is greater than 0 and does not exceed the maximum number of pixels of the corresponding adjacent reference pixel set.

13. The method of claim 12, wherein the at least two adjacent reference pixel sets comprise a left adjacent reference pixel set and an upper adjacent reference pixel set; the at least two adjacent reference block ranges comprise a left adjacent reference pixel range and an upper adjacent reference pixel range; the at least two target reference pixel sets comprise a left target adjacent reference pixel set and an upper target adjacent reference pixel set.

14. The method of claim 12 or 13, wherein the preset horizontal distance and the preset vertical distance corresponding to the first type of pixels in the n rows and m columns of the initial prediction block are different from the preset horizontal distance and the preset vertical distance corresponding to other types of pixels in the initial prediction block except for the n rows and m columns; n and m are natural numbers; the preset horizontal distance and the preset vertical distance corresponding to each pixel in the first type of pixels are at least partially the same or all different; the preset horizontal distance and the preset vertical distance corresponding to each pixel in the other types of pixels are at least partially the same or all different.

15. The method of claim 12 or 13, wherein, the performing intra prediction smoothing filtering processing on each pixel based on the at least two target reference pixel sets to obtain the first prediction value comprises: determining a filtering coefficient; performing intra prediction smoothing filtering processing on each pixel based on the at least two target reference pixel sets and the filtering coefficient to obtain the first prediction value.

16. The method of claim 11, wherein the filtering coefficient corresponding to the first type of pixels in the n rows and m columns of the initial prediction block is different from the filtering coefficient corresponding to other types of pixels in the initial prediction block except for the n rows and m columns; n and m are natural numbers; the filtering coefficient corresponding to each pixel in the first type of pixels is at least partially the same or all different; the filtering coefficient corresponding to each pixel in the other types of pixels is at least partially the same or all different.

17. An encoder comprising: comprising: a first determining part configured to traverse intra prediction modes to determine an initial prediction value of an initial prediction block corresponding to a current block; The first filtering part is configured to perform intra prediction filtering and intra prediction smoothing filtering on the initial prediction block respectively to obtain a first type of prediction value and a second type of prediction value; wherein the intra prediction smoothing filtering is a process of filtering the current block by using a plurality of adjacent reference pixels in each of at least two adjacent reference pixel sets; the at least two adjacent reference pixel sets are used to determine pixels at two boundary pixel positions of each adjacent reference block range as a target reference pixel set, thereby determining at least two target reference pixel sets; the at least two adjacent reference block ranges are determined based on a preset horizontal distance and a preset vertical distance corresponding to each pixel in the initial prediction block; the preset horizontal distance is less than or equal to the width of the initial prediction block; the preset vertical distance is less than or equal to the height of the initial prediction block; and the at least two target reference pixel sets are used to determine the second type of prediction value. The first determining part is further configured to perform rate-distortion cost calculation on the initial prediction value, the first type of prediction value and the second type of prediction value respectively with the original pixel value of the current block to determine a current prediction mode corresponding to an optimal rate-distortion cost. The first prediction part is configured to perform intra prediction on the current block by using the current prediction mode. The writing part is configured to write index information of the current prediction mode and filtering identification into a bitstream, wherein the filtering identification represents identification corresponding to the intra prediction filtering and / or the intra prediction smoothing filtering.

18. A decoder, comprising: The parsing part is configured to obtain a bitstream, parse header information of the bitstream to obtain filtering identification, and when the filtering identification is valid identification representing that the intra prediction filtering is allowed and valid identification representing that the intra prediction smoothing filtering is allowed, at least obtain the current prediction mode and intra prediction filtering use identification from the bitstream. The second prediction part is configured to perform intra prediction smoothing filtering on the current block based on the current prediction mode to obtain a first prediction value when the intra prediction filtering use identification is invalid and valid intra prediction smoothing filtering use identification is obtained from the bitstream; wherein the intra prediction smoothing filtering is a process of filtering the current block by using a plurality of adjacent reference pixels in each of at least two adjacent reference pixel sets. The at least two adjacent reference pixel sets are used to determine pixels at two boundary pixel positions of each adjacent reference block range as a target reference pixel set, thereby determining at least two target reference pixel sets; the at least two adjacent reference block ranges are determined based on a preset horizontal distance and a preset vertical distance corresponding to each pixel in the initial prediction block; the preset horizontal distance is less than or equal to the width of the initial prediction block; the preset vertical distance is less than or equal to the height of the initial prediction block; and the at least two target reference pixel sets are used to determine the first prediction value. The first memory and the first processor are included. The first memory stores a computer program capable of running on the first processor, and the first processor implements the intra prediction method in any one of claims 1 to 9 when executing the program.

19. An encoder comprising: The first memory and the first processor are included. ​ ​ 20. A decoder, comprising: ​ a second memory and a second processor; the second memory stores a computer program capable of running on the second processor, and the second processor implements the intra prediction method according to any one of claims 10 to 16 when executing the program.

21. A storage medium, characterized by a computer program is stored thereon, and the computer program, when executed by the first processor, implements the intra prediction method according to any one of claims 1 to 9, or the computer program, when executed by the second processor, implements the intra prediction method according to any one of claims 10 to 16.

Citation Information

Patent Citations

  • Boundary filtering method for intra-frame prediction

    CN107801024A

  • Processing reference samples used for intra-prediction of a picture block

    CN110199522A