Method and apparatus of regression-based prediction refinement with hardware-friendly simplification in video coding systems
A regression-based prediction refinement model with hardware-friendly simplifications addresses computational complexity in video coding systems by using interpolation filters, padding, and residual term clipping, enhancing coding efficiency and accuracy.
Patent Information
- Application Number
- PCT/CN2026/098206
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2025-05-21
- Filing Date
- 2026-05-21
- Publication Date
- 2026-11-26
AI Technical Summary
Existing video coding systems, such as VVC, face challenges in achieving efficient prediction refinement due to computational complexity and additional operations required for template regions, which affect coding efficiency.
Implement a regression-based prediction refinement model that utilizes a template region to derive prediction samples using a shorten-tap interpolation filter, padding, or integer-pel motion vector rounding, along with residual term clipping and weight parameter optimization to simplify hardware requirements.
Enhances coding efficiency by reducing computational complexity and memory bandwidth overhead while improving prediction accuracy through refined prediction samples.
Smart Images

Figure CN2026098206_26112026_PF_FP_ABST
Abstract
Description
METHOD AND APPARATUS OF REGRESSION-BASED PREDICTION REFINEMENT WITH HARDWARE-FRIENDLY SIMPLIFICATION IN VIDEO CODING SYSTEMSCROSS REFERENCE TO RELATED APPLICATIONS
[0001] The present invention is a non-Provisional Application of and claims priority to U.S. Provisional Patent Application No. 63 / 809,404, filed on May 21, 2025. The U.S. Provisional Patent Application is hereby incorporated by reference in its entirety.FIELD OF THE INVENTION
[0002] The present invention relates to video coding system. In particular, the present invention relates to prediction refinement using a regression-based model to improve coding efficiency.BACKGROUND
[0003] Versatile video coding (VVC) is the latest international video coding standard developed by the Joint Video Experts Team (JVET) of the ITU-T Video Coding Experts Group (VCEG) and the ISO / IEC Moving Picture Experts Group (MPEG) . The standard has been published as an ISO standard: ISO / IEC 23090-3: 2021, Information technology -Coded representation of immersive media -Part 3: Versatile video coding, published Feb. 2021. VVC is developed based on its predecessor HEVC (High Efficiency Video Coding) by adding more coding tools to improve coding efficiency and also to handle various types of video sources including 3-dimensional (3D) video signals.
[0004] Fig. 1A illustrates an exemplary adaptive Inter / Intra video encoding system incorporating loop processing. For Intra Prediction 110, the prediction data is derived based on previously coded video data in the current picture. For Inter Prediction 112, Motion Estimation (ME) is performed at the encoder side and Motion Compensation (MC) is performed based on the result of ME to provide prediction data derived from other picture (s) and motion data. Switch 114 selects Intra Prediction 110 or Inter Prediction 112 and the selected prediction data is supplied to Adder 116 to form prediction errors, also called residues. The prediction error is then processed by Transform (T) 118 followed by Quantization (Q) 120. The transformed and quantized residues are then coded by Entropy Encoder 122 to be included in a video bitstream corresponding to the compressed video data. The bitstream associated with the transform coefficients is then packed with side information such as motion and coding modes associated with Intra prediction and Inter prediction, and other information such as parameters associated with loop filters applied to underlying image area. The side information associated with Intra Prediction 110, Inter prediction 112 and in-loop filter 130, is provided to Entropy Encoder 122 as shown in Fig. 1A. When an Inter-prediction mode is used, a reference picture or pictures have to be reconstructed at the encoder end as well. Consequently, the transformed and quantized residues are processed by Inverse Quantization (IQ) 124 and Inverse Transformation (IT) 126 to recover the residues. The residues are then added back to prediction data 136 at Reconstruction (REC) 128 to reconstruct video data. The reconstructed video data may be stored in Reference Picture Buffer 134 and used for prediction of other frames.
[0005] As shown in Fig. 1A, incoming video data undergoes a series of processing in the encoding system. The reconstructed video data from REC 128 may be subject to various impairments due to a series of processing. Accordingly, in-loop filter 130 is often applied to the reconstructed video data before the reconstructed video data are stored in the Reference Picture Buffer 134 in order to improve video quality. For example, deblocking filter (DF) , Sample Adaptive Offset (SAO) and Adaptive Loop Filter (ALF) may be used. The loop filter information may need to be incorporated in the bitstream so that a decoder can properly recover the required information. Therefore, loop filter information is also provided to Entropy Encoder 122 for incorporation into the bitstream. In Fig. 1A, Loop filter 130 is applied to the reconstructed video before the reconstructed samples are stored in the reference picture buffer 134. The system in Fig. 1A is intended to illustrate an exemplary structure of a typical video encoder. It may correspond to the High Efficiency Video Coding (HEVC) system, VP8, VP9, H. 264 or VVC.
[0006] The decoder, as shown in Fig. 1B, can use some of the functional blocks as the encoder. For example, the decoder can reuse Inverse Quantization 124 and Inverse Transform 126; however, Transform 118 and Quantization 120 are not needed at the decoder. Instead of Entropy Encoder 122, the decoder uses an Entropy Decoder 140 to decode the video bitstream into quantized transform coefficients and needed coding information (e.g. ILPF information, Intra prediction information and Inter prediction information) . The Intra prediction 150 at the decoder side does not need to perform the mode search. Instead, the decoder only needs to generate Intra prediction according to Intra prediction information received from the Entropy Decoder 140. Furthermore, for Inter prediction, the decoder only needs to perform motion compensation (MC 152) according to Inter prediction information received from the Entropy Decoder 140 without the need for motion estimation.
[0007] In VVC, the Sequence Parameter Set (SPS) and the Picture Parameter Set (PPS) contain high-level syntax elements that apply to entire coded video sequences and pictures, respectively. The Picture Header (PH) and Slice Header (SH) contain high-level syntax elements that apply to a current coded picture and a current coded slice, respectively.
[0008] In VVC, a coded picture is partitioned into non-overlapped square block regions represented by the associated coding tree units (CTUs) . A coded picture can be represented by a collection of slices, each comprising an integer number of CTUs. The individual CTUs in a slice are processed in raster-scan order. A bi-predictive (B) slice may be decoded using intra prediction or inter prediction with at most two motion vectors and reference indices to predict the sample values of each block. A predictive (P) slice is decoded using intra prediction or inter prediction with at most one motion vector and reference index to predict the sample values of each block. An intra (I) slice is decoded using intra prediction only.
[0009] In the present invention, techniques of prediction refinement using a regression-based model with hardware-friendly simplification are disclosed. BRIEF SUMMARY OF THE INVENTION
[0010] A method and apparatus of video coding for prediction refinement using a regression-based model for hardware-friendly simplification are disclosed. According to this method, input data associated with a current block is received, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side. A template region associated with the current block is identified. Prediction samples of the template region are derived using reconstructed samples in at least one reference picture based on motion information of the current block, wherein a shorten-tap interpolation filter is utilised to generate interpolated samples associated with non-integer motion for the prediction samples of the template region, or a padding process is utilised to generate the prediction samples of the template region, or wherein a motion vector utilised for deriving the prediction samples of the template region is rounded to an integer-pel precision. A set of residual terms is determined based on differences between the reconstructed samples of the template region and prediction samples of the template region. One or more weight parameters for a combination model are obtained. A prediction refinement is determined for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model. The target prediction sample is refined using the prediction refinement to generate a refined prediction sample. The current block is encoded or decoded by using prediction information comprising the refined prediction sample.
[0011] In one embodiment, the shorten-tap interpolation filter has a filter length shorter than an original interpolation filter.
[0012] In one embodiment, the padding process comprises padding a portion of reference samples of the template region from previously reconstructed samples associated with the current block in the reference picture.
[0013] In one embodiment, the template region of the current block comprises an above template region, a left template region, an above-left template region, or a combination thereof. In one embodiment, the set of residual terms comprise M residual terms from a closest first line in the above template region and N residual terms from a closest second line in the left template region, and wherein M and N are positive integers.
[0014] In one embodiment, the combination model corresponds to a linear model. In one embodiment, the linear model further comprises a bias term. In one embodiment, the one or more weight parameters associated with the linear model are determined using a regression process. In one embodiment, the one or more weight parameters associated with the linear model are retrieved from a memory. In one embodiment, the one or more weight parameters stored in the memory were previously derived based on an offline training using a regression process.
[0015] According to another method, input data associated with a current block is received, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side. A template region associated with the current block is identified. Prediction samples of the template region are derived using reconstructed samples in at least one reference picture based on motion information of the current block. A set of residual terms is determined based on differences between the reconstructed samples of the template region and the prediction samples of the template region, wherein the set of residual terms are subjected to a clipping operation to restrict a dynamic range of the set of residual terms to a target bit-depth smaller than an original bit-depth. One or more weight parameters are obtained for a combination model. A prediction refinement is determined for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model. The target prediction sample is refined using the prediction refinement to generate a refined prediction sample. The current block is encoded or decoded by using prediction information comprising the refined prediction sample.BRIEF DESCRIPTION OF THE DRAWINGS
[0016] Fig. 1A illustrates an exemplary adaptive Inter / Intra video coding system incorporating loop processing.
[0017] Fig. 1B illustrates a corresponding decoder for the encoder in Fig. 1A.
[0018] Fig. 2A-B illustrate two examples of residual terms in the regression-based prediction refinement model.
[0019] Fig. 3 illustrates an example of computing additional prediction samples of the template region for prediction refinement during generating the prediction samples of the current block.
[0020] Fig. 4 illustrates a flowchart of an exemplary video coding system that derives prediction refinement using a regression-based model with hardware-friendly simplification according to an embodiment of the present invention.
[0021] Fig. 5 illustrates a flowchart of another exemplary video coding system that derives prediction refinement using a regression-based model with hardware-friendly simplification according to an embodiment of the present invention.DETAILED DESCRIPTION OF THE INVENTION
[0022] It will be readily understood that the components of the present invention, as generally described and illustrated in the figures herein, may be arranged and designed in a wide variety of different configurations. Thus, the following more detailed description of the embodiments of the systems and methods of the present invention, as represented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. References throughout this specification to “one embodiment, ” “an embodiment, ” or similar language mean that a particular feature, structure, or characteristic described in connection with the embodiment may be included in at least one embodiment of the present invention. Thus, appearances of the phrases “in one embodiment” or “in an embodiment” in various places throughout this specification are not necessarily all referring to the same embodiment.
[0023] Furthermore, the described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments. One skilled in the relevant art will recognize, however, that the invention can be practiced without one or more of the specific details, or with other methods, components, etc. In other instances, well-known structures, or operations are not shown or described in detail to avoid obscuring aspects of the invention. The illustrated embodiments of the invention will be best understood by reference to the drawings, wherein like parts are designated by like numerals throughout. The following description is intended only by way of example, and simply illustrates certain selected embodiments of apparatus and methods that are consistent with the invention as claimed herein.
[0024] PROPOSED METHOD
[0025] In this disclosure, several inventions using regression-based methods for the problem of prediction refinement are proposed.
[0026] 2. Regression-based Prediction Refinement Model
[0027] 2.1 Formula of regression-based prediction refinement model
[0028] In one embodiment, the input of the regression-based prediction refinement model may contain one or more residual terms. The residual term can be a difference between the reconstructed sample and the prediction sample generated using the motion information of the current block, as shown in the following formula. res (x, y) =rec (x, y) -pred (x, y) .
[0029] In one embodiment, the input of the regression-based prediction refinement model may contain one or more prediction terms. The prediction term can be a prediction sample generated using the motion information of the current block at the corresponding position.
[0030] In one embodiment, the input of the regression-based prediction refinement model contains one bias term B, and the definition of bias term is shown in the following formula: B=1<< (BitDepth-1) .
[0031] In one embodiment, the input of the regression-based prediction refinement model contains one or more position terms. The position term can be the horizontal or vertical relative position of the current sample.
[0032] For one example, position terms X and Y are calculated with respect to the top-left coordinates of the current block, as shown in the following formula: X=x-xblock Y=y-yblock
[0033] For another example, position terms X and Y are calculated with respect to the top-left coordinates of the template region, as shown in the following formula: X=x-xtemplate Y=y-ytemplate.
[0034] In another embodiment, the position terms in the regression-based prediction refinement model can be normalized by the current block size. For example, some definitions of position terms X and Y are shown in the following formula:
[0035] In another embodiment, the position terms in the regression-based prediction refinement model can be normalized by the current block size, and then be scaled by a predefined value s. For example, some definitions of position terms X and Y are shown in the following formula:
[0036] In one embodiment, the input of the regression-based prediction refinement model contains one or more similarity term. The similarity term S (x, y, i) can be the difference between the prediction of the current position pred (x, y) and the prediction of a neighbouring position pred (x+Δxi, y+Δyi) , as shown in the following formula: S (x, y, i) =pred (x, y) -pred (x+Δxi, y+Δyi) .
[0037] In another embodiment, the similarity term S (x, y, i) can be the absolute value of the difference between the prediction of the current position pred (x, y) and the prediction of a neighbouring position pred (x+Δxi, y+Δyi) , as shown in the following formula: S (x, y, i) =|pred (x, y) -pred (x+Δxi, y+Δyi) |.
[0038] In another embodiment, the absolute operation in the similarity term S (x, y, i) can be replaced by the square operation, so the similarity term can be the square of the difference between the prediction of the current position pred (x, y) and the prediction of a neighbouring position pred (x+Δxi, y+Δyi) , as shown in the following formula: S (x, y, i) =(pred (x, y) -pred (x+Δxi, y+Δyi) )2
[0039] In another embodiment, the similarity term S (x, y, i) mentioned above can be further multiplied by a residual term of a neighbouring position res (x+Δxi, y+Δyi) , as shown in the following formula: S (x, y, i) =|pred (x, y) -pred (x+Δxi, y+Δyi) |*res (x+Δxi, y+Δyi) S (x, y, i) = (pred (x, y) -pred (x+Δxi, y+Δyi) )2*res (x+Δxi, y+Δyi) .
[0040] In one embodiment, the input of the regression-based prediction refinement model contains one or more OBMC term. The OBMC term can be the prediction sample generated by the motion information of the neighbouring block, as shown in the following formula: OBMC (x, y) =predOBMC (x, y) .
[0041] In another embodiment, the OBMC term can be the difference between the reconstructed sample and the prediction sample generated by the motion information of the neighbouring block, as shown in the following formula: OBMC (x, y) =rec (x, y) -predOBMC (x, y) .
[0042] In one embodiment, the regression-based prediction refinement model may have N residual terms corresponding to the N neighbouring positions, where N is a positive integer. Each residual term can have its corresponding parameter ci, as shown in the following formula:
[0043] For one example, there are 14 residual terms in the regression model, as illustrated in Fig. 2A. The position marked with “T” is the current position where the regression model will be used to derive the prediction refinement, and the positions marked with numbers are the corresponding positions of each residual terms. For another example, there are 8 residual terms in the regression model, as illustrated in Fig. 2B.
[0044] In another embodiment, the regression-based prediction refinement model may have one bias term and N residual terms corresponding to the N neighbouring positions, where N is a positive integer:
[0045] In another embodiment, the regression-based prediction refinement model may have M residual terms at the closest line in the above template region, and / or N residual terms at the closest line in the left template region, where M and N are positive integers:
[0046] In another embodiment, the regression-based prediction refinement model may have one bias term, M residual terms at the closest line in the above template region, and / or N residual terms at the closest line in the left template region, where M and N are positive integers:
[0047] In one embodiment, the regression-based prediction refinement model may have M residual terms corresponding to the M neighbouring positions, and N prediction terms corresponding to the N neighbouring positions, where M and N are positive integers:
[0048] In one embodiment, the regression-based prediction refinement model may have one bias term, M residual terms corresponding to the M neighbouring positions, and N prediction terms corresponding to the N neighbouring positions, where M and N are positive integers:
[0049] In one embodiment, the regression-based prediction refinement model may have one bias term, two position terms, and M residual terms corresponding to the M neighbouring positions, where M is a positive integer:
[0050] In one embodiment, the regression-based prediction refinement model may have one bias term, M residual terms corresponding to the M neighbouring positions, and N similarity terms corresponding to the N neighbouring positions, where M and N are positive integers:
[0051] In one embodiment, the regression-based prediction refinement model may have one bias term, M residual terms corresponding to the M neighbouring positions, and N OBMC terms corresponding to the N neighbouring positions, where M and N are positive integers:
[0052] In one embodiment, the regression-based prediction refinement model may be any combination of the terms mentioned above.
[0053] In one embodiment, if the corresponding position of a residual term has not been encoded or decoded, and the reconstructed sample at this position is not available, the residual term at this position can be replaced with 0.
[0054] In another embodiment, if the corresponding position of a residual term has not been encoded or decoded, and the reconstructed sample at this position is not available, the residual term at this position can be replaced with the refinement generated by the regression-based prediction refinement model for that position.
[0055] 2.1.2 Derive regression-based model using the template region
[0056] As with other regression-based methods, the samples in the template region may be used to derive the parameters of the regression-based prediction refinement model.
[0057] In one embodiment, only the samples in the above template region may be used to derive the parameters of the regression-based prediction refinement model.
[0058] In another embodiment, only the samples in the left template region may be used to derive the parameters of the regression-based prediction refinement model.
[0059] In another embodiment, the samples in the above template region and the left template region may be used to derive the parameters of the regression-based prediction refinement model.
[0060] In another embodiment, the samples in the above template region, the left template region and the above-left template region may be used to derive the parameters of the regression-based prediction refinement model.
[0061] In one embodiment, the reconstructed samples in the template region may be used to derive the parameters of the regression-based prediction refinement model.
[0062] In another embodiment, the prediction samples in the template region may be used to derive the parameters of the regression-based prediction refinement model. The prediction samples in the template region are generated using the same coding method as the current block.
[0063] In another embodiment, the difference between the reconstructed samples and the prediction samples in the template region may be used to derive the parameters of the regression-based prediction refinement model.
[0064] In one embodiment, when deriving the optimal parameter of the regression model using the samples in the template region, the difference between the reconstructed samples and the prediction samples of one position may be the regression target, and the difference between the reconstructed samples and the prediction samples of its neighbouring positions may be the input of the regression model.
[0065] In one embodiment, an auto-correlation matrix A and a cross-correlation vector b are prepared by collecting training data pairs in the template region, and then we may derive the optimal parameters of the regression-based prediction refinement model by solving the matrix equation Ax=b.
[0066] In one embodiment, LDL decomposition method may be used to solve the matrix equation Ax=b to derive the optimal parameters of the regression-based prediction refinement model.
[0067] In another embodiment, Gaussian elimination decomposition method may be used to solve the matrix equation Ax=b to derive the optimal parameters of the regression-based prediction refinement model.
[0068] 2.1.3 Offline derived regression-based model
[0069] In one embodiment, the parameters of the regression-based prediction refinement model may be loaded from memory, and the parameters in memory are derived offline.
[0070] In one embodiment, the parameters of the regression-based prediction refinement model may be position dependent. The horizontal position x and the vertical position y may be used as indexes of memory.
[0071] In one embodiment, the parameters of the regression-based prediction refinement model may be block size dependent. The block width and the block height may be used as indexes of memory.
[0072] 2.1.4 Residual clipping in template region
[0073] Since the residual value of the template is calculated by the reconstructed sample and the prediction sample generated by the motion information of the current block, if the object corresponding to a position in the template region has different motion than the current block, these positions may generate some extremely high or extremely low residual values. Several methods are proposed to deal with this problem.
[0074] In one embodiment, when finishing the calculation of the residual value of the template region, a clipping operation may be added to the residual value. The residual value will be clipped within a range (min, max) , where min and max can be two pre-defined integers: res′ (x, y) =Clip (res (x, y) , min, max) .
[0075] In another embodiment, when finishing the calculation of the residual value of the template region, a clipping operation may be added to the residual value. The residual value will be clipped within a range (min, max) , where min and max are derived from the residual value of the template region.
[0076] For one example, the upper bound value max may be the maximum value of the line closest to the current block in the template region, and the lower bound value min may be the minimum value of the line closest to the current block in the template region.
[0077] For another example, the upper bound value max may be the maximum value of the M lines closest to the current block in the template region, and the lower bound value min may be the minimum value of the N lines closest to the current block in the template region, where M and N are positive integers.
[0078] 2.2 Regression-based Prediction Refinement
[0079] 2.2.1 Weighting prediction refinement
[0080] In one embodiment, after deriving the optimal parameters of the regression-based prediction refinement model, the regression model may be applied to the current block to generate the prediction refinement refinement (x, y) , and then the final prediction pred′ (x, y) may be obtained by adding the original prediction pred (x, y) and the sample-wise prediction refinement refinement (x, y) , as shown in the following formula: pred′ (x, y) =pred (x, y) +refinement (x, y) .
[0081] In one embodiment, the prediction refinement derived from the regression model may be further multiplied by a weight w (x, y) before being added to the original prediction, as shown in the following formula: pred′ (x, y) =pred (x, y) +refinement (x, y) *w (x, y) .
[0082] In one embodiment, the weight w (x, y) is related to the horizontal position x and the vertical position y, where the horizontal position x and the vertical position y may be calculated with respect to the top-left coordinates of the current block. As the horizontal position x and / or the vertical position y increases, the weight w (x, y) will decrease or remain unchanged.
[0083] For one example, the weight may linearly decrease as horizontal position x and / or the vertical position y increases. For another example, the weight may exponentially decrease as horizontal position x and / or the vertical position y increases.
[0084] In another embodiment, the weight w (x, y) may be obtained from a lookup table, and the horizontal position x and the vertical position y can be used as indexes of the lookup table.
[0085] 2.2.2 Prediction refinement with clipping
[0086] In one embodiment, the prediction refinement derived from the regression model may be clipped within a range (min, max) before being added to the original prediction, as shown in the following formula. The upper bound and the lower bound of the range may be found in the template region: pred′ (x, y) =pred (x, y) +Clip (refinement (x, y) , min, max) .
[0087] For one example, the upper bound value max may be the maximum value of the line closest to the current block in the template region, and the lower bound value min may be the minimum value of the line closest to the current block in the template region.
[0088] For another example, the upper bound value max may be the maximum value of the M lines closest to the current block in the template region, and the lower bound value min may be the minimum value of the N lines closest to the current block in the template region, where M and N are positive integers.
[0089] 2.2.3 Combinations
[0090] In one embodiment, the weighting prediction refinement and the prediction refinement with clipping may be combined. The prediction refinement derived from the regression model may be firstly multiplied by a weight w (x, y) , and then it may be clipped within a range (min, max) before being added to the original prediction, as shown in the following formula: pred′ (x, y) =pred (x, y) +Clip (refinement (x, y) *w (x, y) , min, max) .
[0091] In another embodiment, the weighting prediction refinement and the prediction refinement with clipping may be combined. The prediction refinement derived from the regression model may be firstly clipped within a range (min, max) , and then it may be multiplied by a weight w (x, y) before being added to the original prediction, as shown in the following formula: pred′ (x, y) =pred (x, y) +Clip (refinement (x, y) , min, max) *w (x, y) .
[0092] 2.3 Syntax Design for Prediction Refinement
[0093] In one embodiment, a prediction refinement flag may be signalled for each block to indicate whether the proposed regression-based prediction refinement method is used or not.
[0094] In one embodiment, only blocks coded by certain specific coding modes need to signal the prediction refinement flag. If the block is not coded by certain specific coding modes, the prediction refinement flag may infer to be false, and the proposed regression-based prediction refinement method will not be applied.
[0095] For one example, certain specific coding modes may be non-merge mode. For another example, certain specific coding modes may be non-LIC mode. For another example, certain specific coding modes may be non-affine mode.
[0096] In another embodiment, only blocks coded by non-merge modes may signal the prediction refinement flag to indicate whether the proposed regression-based prediction refinement method is used or not. For the blocks coded by merge modes, the prediction refinement flag may be inherited from the merge candidate.
[0097] In one embodiment, if the prediction refinement flag is true, a flag may be further signalled after the prediction refinement flag to indicate whether the template residual clipping method is used or not.
[0098] In one embodiment, only blocks with an area greater than a predefined threshold TH may signal the prediction refinement flag to indicate whether the proposed regression-based prediction refinement method is used or not. For the blocks with an area less than TH, the prediction refinement flag may infer to be true, and the proposed regression-based prediction refinement method will be always applied or always not applied.
[0099] In another embodiment, only blocks with an area less than a predefined threshold TH may signal the prediction refinement flag to indicate whether the proposed regression-based prediction refinement method is used or not. For the blocks with an area greater than TH, the prediction refinement flag may infer to be true, and the proposed regression-based prediction refinement method will be always applied or always not applied.
[0100] In another embodiment, only blocks with a QP value greater than a predefined threshold TH may signal the prediction refinement flag to indicate whether the proposed regression-based prediction refinement method is used or not. For the blocks with QP less than TH, the prediction refinement flag may infer to be true, and the proposed regression-based prediction refinement method will be always applied or always not applied.
[0101] In another embodiment, only blocks with QP less than a predefined threshold TH may signal the prediction refinement flag to indicate whether the proposed regression-based prediction refinement method is used or not. For the blocks with a QP value greater than TH, the prediction refinement flag may infer to be true, and the proposed regression-based prediction refinement method will be always applied or always not applied.
[0102] In one embodiment, whether the proposed regression-based prediction refinement method is applied to the current block may be implicitly determined by checking the block size.
[0103] For one example, if the block area is less than a predefined threshold TH, the regression-based prediction refinement method may be applied to the current block. Otherwise, the regression-based prediction refinement method may not be applied to the current block.
[0104] For another example, if the block area is greater than a predefined threshold TH, the regression-based prediction refinement method may be applied to the current block. Otherwise, the regression-based prediction refinement method may not be applied to the current block.
[0105] In one embodiment, whether the proposed regression-based prediction refinement method is applied to the current block may be implicitly determined by checking the QP value.
[0106] For one example, if the QP value of the block is less than a predefined threshold TH, the regression-based prediction refinement method may be applied to the current block. Otherwise, the regression-based prediction refinement method may not be applied to the current block.
[0107] For another example, if the QP value of the block is greater than a predefined threshold TH, the regression-based prediction refinement method may be applied to the current block. Otherwise, the regression-based prediction refinement method may not be applied to the current block.
[0108] In one embodiment, whether the proposed regression-based prediction refinement method is applied to the current block may be implicitly determined by checking the difference between the motion of the current block and the motion vector of the neighbouring block. For one example, the difference may be the Euclidean distance as shown in the following formula, where (mv′x, mv′y) is the motion vector of the current block, and (mvx, mvy) is the motion vector of the neighbouring block:
[0109] For one example, if the motion vector difference is less than a predefined threshold TH, the regression-based prediction refinement method may be applied to the current block. Otherwise, the regression-based prediction refinement method may not be applied to the current block.
[0110] For another example, if the motion vector difference is greater than a predefined threshold TH, the regression-based prediction refinement method may be applied to the current block. Otherwise, the regression-based prediction refinement method may not be applied to the current block.
[0111] In one embodiment, a high-level syntax may be signalled for enabling the prediction refinement. This high-level syntax may be signalled in SPS, PPS, PH or SH to indicate if the proposed method is allowed for the current sequence, picture, or slice.
[0112] 2..4 Hardware-Friendly Simplification
[0113] In this disclosure, methods of prediction refinement are proposed to improve the coding efficiency. However, these methods require the additional motion compensation operations for the template region and cause higher computational complexities. The following disclosures are proposed to reduce the computational complexity of the prediction refinement methods.
[0114] 2.4.1 Bit Depth Reduction
[0115] In one embodiment, the residual term can be clipped and represented by an N-bit integer, where N is a positive integer smaller than the original bit-depth of the residual term. For example, if the codec internal bit-depth is 10, the original bit depth of the residual term is 11 because it is the difference between two 10-bit values, and the residual term can be clipped within -128 and 127, which can be represented by an 8-bit integer.
[0116] In one sub-embodiment, the value of N is related to the internal bit-depth. For example, N is determined according to the internal bit-depth minus 2. If the internal bit-depth is 10, N is set to 8. If the internal bit-depth is 12, N is set to 10.
[0117] In another sub-embodiment, the N value is related to the bit-depth of the input sequence. For example, N is determined according to the bit-depth of the input sequence minus 2. If the bit-depth of the input sequence is 10, N is set to 8. If the bit-depth of the input sequence is 12, N is set to 10. In another sub-embodiment, only the internal bit-depth larger than a predefined threshold M will apply the proposed clipping simplification. For example, the threshold M is set to 8. If the internal bit-depth is 8, no clipping is applied. If the internal bit-depth is 10, clipping is applied for simplification.
[0118] In another sub-embodiment, only the bit-depth of the input sequence larger than a predefined threshold M will apply the proposed clipping simplification. For example, the threshold M is set to 8. If the bit-depth of the input sequence is 8, no clipping is applied. If the bit-depth of the input sequence is 10, clipping is applied for simplification.
[0119] 2.4.2 Simplification of Motion Compensation for Template Region
[0120] The proposed prediction refinement methods may need to calculate the residuals of the neighbouring template region, which may require additional motion compensation operations in the template region to obtain the prediction of the template region. In this disclosure, several methods are proposed to simplify the additional computations for the prediction of the template region.
[0121] In one embodiment, the prediction of the current block and the template region can be generated together. For example, if the size of the current block is W*H and the template width is T, a prediction of size (W+T) * (H+T) is generated using motion compensation as shown in Fig. 3. In Fig. 3, during generating the prediction samples for the current block (i.e., the reference block) , the prediction samples of the template region (i.e., the T-shaped grey area adjacent to the reference block) can be generated at the same time.
[0122] In another embodiment, the generation of the prediction of the template region can be replaced by reusing the prediction of the first row and / or column of the current block. For example, the predictions of the first row can be copied to the predictions of the above template region, and the predictions of the first column can be copied to the predictions of the left template region.
[0123] Another problem encountered when generating the prediction of the template region is that a larger range of reconstructed samples of the reference frame needs to be fetched from the memory. This disclosure proposes several methods to solve this issue.
[0124] In one embodiment, another interpolation filter can be used for generating the prediction of the template region, and this interpolation filter has a shorter tap than the original interpolation filter for motion compensation. By employing a shorter-tap interpolation filter for the template region, the need to fetch additional reconstructed reference samples from external memory is eliminated, thereby reducing memory bandwidth overhead. For example, if the interpolation filter for motion compensation is 12-tap, we can use another 10-tap interpolation filter for generating the prediction of the template region.
[0125] In another embodiment, the additional reconstructed samples of the reference frame for the template region can be padded from the existing reconstructed samples of the reference frame for the current block, and the padding method can be repetitive padding. For example, if the template width is 1, one more above rows and left columns of the reconstructed samples of the reference frame are needed for generating the prediction of the template region, and the additional sample can be padded from the existing reconstructed samples of the reference frame for the current block.
[0126] In another embodiment, the motion vector used for the template region can be rounded to an integer before the motion compensation is applied to the template region. In the case of integer-pel motion, the interpolation filtering operation for the motion compensation of the template region is bypassed. Consequently, the memory access requirements are reduced as no additional reconstructed samples from the reference frame are required to be retrieved.
[0127] Any of the foregoing proposed methods of regression-based prediction refinement can be implemented in encoders and / or decoders. For example, any of the proposed methods can be implemented in an inter / intra / prediction module of an encoder, and / or an inter / intra / prediction module of a decoder. Alternatively, any of the proposed methods can be implemented as a circuit coupled to the inter / intra / prediction module of the encoder and / or the inter / intra / prediction module of the decoder, so as to provide the information needed by the inter / intra / prediction module
[0128] With reference to the exemplary encoder and decoder in Fig. 1A and Fig 1B, the proposed methods can be implemented in the intra / inter prediction modules. For example, in the encoder side, the required processing can be implemented as part of the Inter-Pred. unit 112 or Intra Pred. unit 110 as shown in Fig. 1A. However, the encoder may also use additional processing unit to implement the required processing. For the decoder side, the required processing can be implemented as part of the MC unit 152 or Intra Pred. 150 as shown in Fig. 1B. However, the decoder may also use additional processing unit to implement the required processing. Alternatively, any of the proposed methods can be implemented as a circuit coupled to the inter / intra / prediction module of the encoder and / or the inter / intra / prediction module of the decoder, so as to provide the information needed by the inter / intra / prediction module. While the Inter-Pred. 112 and Intra Pred. 110 in the encoder side and MC 152 and Intra Pred. 150 in the decoder side are shown as individual processing units, they may correspond to executable software or firmware codes stored on a media, such as hard disk or flash memory, for a CPU (Central Processing Unit) or programmable devices (e.g. DSP (Digital Signal Processor) or FPGA (Field Programmable Gate Array) ) .
[0129] Fig. 4 illustrates a flowchart of an exemplary video coding system that derives prediction refinement using a regression-based model with hardware-friendly simplification according to an embodiment of the present invention. The steps shown in the flowchart may be implemented as program codes executable on one or more processors (e.g., one or more CPUs) at the encoder side. The steps shown in the flowchart may also be implemented based hardware such as one or more electronic devices or processors arranged to perform the steps in the flowchart. According to this method, input data associated with a current block is received in step 410, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side. A template region associated with the current block is identified in step 420. A template region associated with the current block is identified. Prediction samples of the template region are derived using reconstructed samples in at least one reference picture based on motion information of the current block in step 430, wherein a shorten-tap interpolation filter is utilised to generate interpolated samples associated with non-integer motion for the prediction samples of the template region, or a padding process is utilised to generate the prediction samples of the template region, or wherein a motion vector utilised for deriving the prediction samples of the template region is rounded to an integer-pel precision. A set of residual terms is determined based on differences between the reconstructed samples of the template region and prediction samples of the template region in step 440. One or more weight parameters for a combination model are obtained in step 450. A prediction refinement is determined for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model in step 460. The target prediction sample is refined using the prediction refinement to generate a refined prediction sample in step 470. The current block is encoded or decoded by using prediction information comprising the refined prediction sample in step 480.
[0130] Fig. 5 illustrates a flowchart of another exemplary video coding system that derives prediction refinement using a regression-based model with hardware-friendly simplification according to an embodiment of the present invention. According to another method, input data associated with a current block is received in step 510, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side. A template region associated with the current block is identified in step 520. Prediction samples of the template region are derived using reconstructed samples in at least one reference picture based on motion information of the current block in step 530. A set of residual terms is determined based on differences between the reconstructed samples of the template region and the prediction samples of the template region in step 540, wherein the set of residual terms are subjected to a clipping operation to restrict a dynamic range of the set of residual terms to a target bit-depth smaller than an original bit-depth. One or more weight parameters are obtained for a combination model in step 550. A prediction refinement is determined for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model in step 560. The target prediction sample is refined using the prediction refinement to generate a refined prediction sample in step 570. The current block is encoded or decoded by using prediction information comprising the refined prediction sample in step 580.
[0131] The flowcharts shown are intended to illustrate an example of video coding according to the present invention. A person skilled in the art may modify each step, re-arranges the steps, split a step, or combine steps to practice the present invention without departing from the spirit of the present invention. In the disclosure, specific syntax and semantics have been used to illustrate examples to implement embodiments of the present invention. A skilled person may practice the present invention by substituting the syntax and semantics with equivalent syntax and semantics without departing from the spirit of the present invention.
[0132] The above description is presented to enable a person of ordinary skill in the art to practice the present invention as provided in the context of a particular application and its requirement. Various modifications to the described embodiments will be apparent to those with skill in the art, and the general principles defined herein may be applied to other embodiments. Therefore, the present invention is not intended to be limited to the particular embodiments shown and described, but is to be accorded the widest scope consistent with the principles and novel features herein disclosed. In the above detailed description, various specific details are illustrated in order to provide a thorough understanding of the present invention. Nevertheless, it will be understood by those skilled in the art that the present invention may be practiced.
[0133] Embodiment of the present invention as described above may be implemented in various hardware, software codes, or a combination of both. For example, an embodiment of the present invention can be one or more circuit circuits integrated into a video compression chip or program code integrated into video compression software to perform the processing described herein. An embodiment of the present invention may also be program code to be executed on a Digital Signal Processor (DSP) to perform the processing described herein. The invention may also involve a number of functions to be performed by a computer processor, a digital signal processor, a microprocessor, or field programmable gate array (FPGA) . These processors can be configured to perform particular tasks according to the invention, by executing machine-readable software code or firmware code that defines the particular methods embodied by the invention. The software code or firmware code may be developed in different programming languages and different formats or styles. The software code may also be compiled for different target platforms. However, different code formats, styles and languages of software codes and other means of configuring code to perform the tasks in accordance with the invention will not depart from the spirit and scope of the invention.
[0134] The invention may be embodied in other specific forms without departing from its spirit or essential characteristics. The described examples are to be considered in all respects only as illustrative and not restrictive. The scope of the invention is therefore, indicated by the appended claims rather than by the foregoing description. All changes which come within the meaning and range of equivalency of the claims are to be embraced within their scope.
Claims
1.A method of video coding, the method comprising:receiving input data associated with a current block, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side;identifying a template region associated with the current block;deriving prediction samples of the template region using reconstructed samples in at least one reference picture based on motion information of the current block, wherein a shorten-tap interpolation filter is utilised to generate interpolated samples associated with non-integer motion for the prediction samples of the template region, or a padding process is utilised to generate the prediction samples of the template region, or wherein a motion vector utilised for deriving the prediction samples of the template region is rounded to an integer-pel precision;determining a set of residual terms based on differences between the reconstructed samples of the template region and prediction samples of the template region;obtaining one or more weight parameters for a combination model;determining a prediction refinement for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model;refining the target prediction sample using the prediction refinement to generate a refined prediction sample; andencoding or decoding the current block by using prediction information comprising the refined prediction sample.2.The method of Claim 1, wherein the shorten-tap interpolation filter has a filter length shorter than an original interpolation filter for motion compensation of the current block.3.The method of Claim 1, wherein the padding process comprises padding a portion of reference samples of the template region from previously reconstructed samples associated with the current block in the reference picture.4.The method of Claim 1, wherein the template region of the current block comprises an above template region, a left template region, an above-left template region, or a combination thereof.5.The method of Claim 4, wherein the set of residual terms comprise M residual terms from a closest first line in the above template region and N residual terms from a closest second line in the left template region, and wherein M and N are positive integers.6.The method of Claim 1, wherein the combination model corresponds to a linear model.7.The method of Claim 1, wherein the combination model further comprises a bias term.8.The method of Claim 1, wherein the one or more weight parameters associated with the combination model are determined using a regression process.9.The method of Claim 1, wherein the one or more weight parameters associated with the combination model are retrieved from a memory.10.The method of Claim 9, wherein the one or more weight parameters stored in the memory were previously derived based on an offline training using a regression process.11.The method of Claim 1, wherein the prediction samples of the template region are generated at a same time during generating the prediction samples of the current block by generating prediction samples covering an extended area covering the current block and the template region.12.The method of Claim 1, wherein the prediction samples of the template region are generated by reusing the prediction samples of the current block in a first row or a first column of the current block.13.An apparatus for video coding, the apparatus comprising one or more electronic circuits or processors arranged to:receive input data associated with a current block, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side;identify a template region associated with the current block;derive prediction samples of the template region using reconstructed samples in at least one reference picture based on motion information of the current block, wherein a shorten-tap interpolation filter is utilised to generate interpolated samples associated with non-integer motion for the prediction samples of the template region, or a padding process is utilised to generate the prediction samples of the template region, or wherein a motion vector utilised for deriving the prediction samples of the template region is rounded to an integer-pel precision;determine a set of residual terms based on differences between reconstructed samples of the template region and the prediction samples of the template region;obtain one or more weight parameters for a combination model, wherein the one or more weight parameters are associated with a regression-based model;determine a prediction refinement for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model;refine the target prediction sample using the prediction refinement to generate a refined prediction sample; andencode or decode the current block by using prediction information comprising the refined prediction sample.14.A method of video coding, the method comprising:receiving input data associated with a current block, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side;identifying a template region associated with the current block;deriving prediction samples of the template region using reconstructed samples in at least one reference picture based on motion information of the current block;determining a set of residual terms based on differences between the reconstructed samples of the template region and the prediction samples of the template region;wherein the set of residual terms are subjected to a clipping operation to restrict a dynamic range of the set of residual terms to a target bit-depth smaller than an original bit-depth;obtaining one or more weight parameters for a combination model;determining a prediction refinement for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model;refining the target prediction sample using the prediction refinement to generate a refined prediction sample; andencoding or decoding the current block by using prediction information comprising the refined prediction sample.15.An apparatus for video coding, the apparatus comprising one or more electronic circuits or processors arranged to:receive input data associated with a current block, wherein the input data comprise pixel data for the current block to be encoded at an encoder side or coded data associated with the current block to be decoded at a decoder side;identify a template region associated with the current block;derive prediction samples of the template region using reconstructed samples in at least one reference picture based on motion information of the current block;determining a set of residual terms based on differences between the reconstructed samples of the template region and the prediction samples of the template region;wherein the set of residual terms are subjected to a clipping operation to restrict a dynamic range of the set of residual terms to a target bit-depth smaller than an original bit-depth;obtain one or more weight parameters for a combination model;determine a prediction refinement for a target prediction sample based on the obtained one or more weight parameters and the set of residual terms according to the combination model;refine the target prediction sample using the prediction refinement to generate a refined prediction sample; andencode or decode the current block by using prediction information comprising the refined prediction sample.
