Use of interleaved predictions
By adopting sub-block-based motion prediction methods and various motion compensation technologies in video coding and decoding technology, the problem of global motion compensation being difficult to represent intra-frame moving objects is solved, and the efficiency and quality of video coding are improved.
Patent Information
- Application Number
- CN202080007786.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2019-01-14
- Filing Date
- 2020-01-02
- Publication Date
- 2024-10-15
- Estimated Expiration
- 2040-01-02
AI Technical Summary
Existing video coding and decoding technology has deficiencies in the representation of intra-frame moving objects. In particular, global motion compensation is difficult to fully represent intra-frame moving objects, resulting in low video coding efficiency.
Adopt a sub-block-based motion prediction method by subdividing video blocks into sub-blocks and assigning different motion information to each sub-block, such as reference index or motion vector, combined with affine prediction, optional temporal motion vector prediction, spatial domain- Technologies such as temporal motion vector prediction, bidirectional optical flow and frame rate up-conversion are used to perform motion compensation to improve coding efficiency.
It improves the efficiency and quality of video coding, can more accurately represent moving objects within a frame, and reduces coding complexity and storage requirements.
Smart Images

Figure CN113261281B_ABST
Abstract
Description
[0001] CROSS-REFERENCE TO RELATED APPLICATIONS
[0002] This application is filed in accordance with applicable patent laws and / or regulations of the Paris Convention to timely claim the priority and benefits of International Patent Application No. PCT / CN2019 / 070058 filed on January 2, 2019, International Patent Application No. PCT / CN2019 / 071507 filed on January 13, 2019, and International Patent Application No. PCT / CN2019 / 071576 filed on January 14, 2019. The entire disclosure of the above applications is incorporated herein by reference as part of the disclosure of this application. Technical Field
[0003] This patent document relates to video encoding and decoding technology, devices and systems. Background Art
[0004] Motion compensation (MC) is a technique in video processing for predicting frames in a video by taking into account the motion of the camera and / or objects in the video given previous and / or future frames. Motion compensation can be used in encoding of video data for video compression. Summary of the invention
[0005] This document discloses methods, systems and apparatus related to sub-block based motion prediction in video motion compensation.
[0006] In one representative aspect, a method of video processing is disclosed, the method comprising: deriving one or more motion vectors for a first set of sub-blocks of a first subdivision pattern belonging to a current video block of a video; and performing conversion between the current video block and a codec representation of the video based on the one or more motion vectors.
[0007] In another representative aspect, a method of video processing is disclosed. The method includes: subdividing a video block of a first color component to obtain a first set of subblocks of the first color component; subdividing a corresponding video block of a second color component to obtain a second set of subblocks of the second color component; deriving one or more motion vectors of the first set of subblocks based on one or more motion vectors of the second set of subblocks; and converting between a video block and a codec representation of a video based on the one or more motion vectors of the first set of subblocks and the second set of subblocks.
[0008] In another representative aspect, a method of video processing is disclosed. The method includes: for conversion between a current video block of a video and a bitstream representation of the video, subdividing the current video block into partitions according to a plurality of subdivision patterns according to a height (H) or a width (W) of the current video block; and performing the conversion using interlaced prediction of the plurality of partitions.
[0009] In another representative aspect, a method of video processing is disclosed. The method includes: determining to apply prediction to a current video block of a video, the prediction including subdividing the current video block into sub-blocks according to a subdivision pattern; determining to apply a bit shift to generate a prediction block on the sub-block of the current video block; and performing conversion between the current video block and a codec representation of the video.
[0010] In another representative aspect, a method of video processing is disclosed. The method includes: determining whether to use an interlaced prediction tool for conversion between a current block and a codec representation of the video based on characteristics of a current video block of the video; and performing conversion according to the determination, wherein upon determining that the characteristics of the current video block do not meet a condition, the conversion is performed by disabling the use of an affine prediction tool and / or an interlaced prediction tool.
[0011] In another representative aspect, a method of video processing is disclosed. The method includes: determining whether to use an interlaced prediction tool for conversion between the current block and a codec representation of the video based on characteristics of a current video block of the video; and performing conversion according to the determination, wherein once it is determined that the characteristics of the current video block meet a condition, the conversion is performed by an affine prediction tool and / or an interlaced prediction tool.
[0012] In another representative aspect, a method of video processing is disclosed. The method includes: determining that interlaced prediction is to be applied to a current video block of a video; and disabling bi-directional prediction for the current video block based on determining that interlaced prediction is to be applied; and performing conversion between the current video block and a codec representation of the video.
[0013] In another representative aspect, a method of video processing is disclosed. The method includes: for a conversion between a current video block of a video and a codec representation of the video, determining refined motion information of at least one sub-block of the current video block; and using the refined motion information for conversion, wherein the refined motion information is generated based on an interlaced prediction tool, in which multiple patterns are used to generate motion information of a partition of the current video block, and wherein the refined motion information of the current video block is used for subsequent processing or selectively stored based on whether a condition is satisfied.
[0014] In another representative aspect, a method of video processing is disclosed. The method includes: determining whether to apply interlaced prediction to a current video block of a video; and determining to use a filtering process for the current video block based on the determination of whether to apply interlaced prediction to the current video block; and converting between the current video block and a codec representation of the video based on the determination of the use of the filtering process.
[0015] In another representative aspect, a method of video processing is disclosed. The method includes: determining whether to apply interlaced prediction to a current video block of a video; and determining whether to use local illumination compensation or weighted prediction for the current video block based on the determination of the use of interlaced prediction; and converting between the current video block and a codec representation of the video based on the determination of the use of local illumination compensation or weighted prediction.
[0016] In another representative aspect, a method of video processing is disclosed, the method comprising: determining that weighted prediction applies to a current video block of a video or a sub-block of the current video block; and performing conversion between the current video block and a coded representation of the video by disabling a bidirectional optical flow (BDOF) technique.
[0017] In another representative aspect, a device is disclosed that includes a processor and a non-volatile memory having instructions thereon. The instructions, when executed by the processor, cause the processor to select a set of pixels from a video frame to form a block, subdivide the block into a first set of subblocks according to a first pattern, generate a first intermediate prediction block based on the first set of subblocks, subdivide the block into a second set of subblocks according to a second pattern, wherein at least one subblock in the second set has a different size than a subblock in the first set, generate a second intermediate prediction block based on the second set of subblocks, and determine a prediction block based on the first intermediate prediction block and the second intermediate prediction block.
[0018] In yet another representative aspect, a method of video processing includes deriving one or more motion vectors for a first set of sub-blocks of a current video block, wherein each of the first set of sub-blocks has a first subdivision pattern, and reconstructing the current video block based on the one or more motion vectors.
[0019] In yet another representative aspect, the various techniques described herein may be implemented as a computer program product stored on a non-transitory computer-readable medium. The computer program product includes program code for performing the methods described herein.
[0020] In yet another representative aspect, a video decoder device may implement a method as described herein.
[0021] The details of one or more implementations are set forth in the appendices, drawings, and description attached below. Other features will be apparent from the description and drawings, and from the claims. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] Figure 1 is a diagram illustrating an example of sub-block based prediction.
[0023] Figure 2 An example of an affine motion field for a block described by two control point motion vectors is shown.
[0024] Figure 3 An example of an affine motion vector field for each sub-block of a block is shown.
[0025] Figure 4 An example of motion vector prediction of block 400 in AF_INTER mode is shown.
[0026] Figure 5A An example of the selection order of candidate blocks for the current coding unit (CU) is shown.
[0027] Figure 5B Another example of candidate blocks for the current CU in AF_MERGE mode is shown.
[0028] Figure 6 An example of an optional temporal motion vector prediction (ATMVP) motion prediction process for a CU is shown.
[0029] Figure 7 An example of one CU having four sub-blocks and neighboring blocks is shown.
[0030] Figure 8 An exemplary optical flow trajectory in the bidirectional optical flow (BIO) method is shown.
[0031] Fig. 9A An example of an access location outside a block is shown.
[0032] Fig. 9B Shown is a padding area that can be used to avoid extra memory accesses and calculations.
[0033] Fig.10 An example of bilateral matching used in a frame rate up-conversion (FRUC) method is shown.
[0034] Fig.11 An example of template matching used in the FRUC method is shown.
[0035] Fig.12 An example of unilateral motion estimation (ME) in the FRUC method is shown.
[0036] Fig.13 An example of interleaved prediction with two subdivision styles according to the disclosed technique is shown.
[0037] Fig.14A An exemplary subdivision pattern for subdividing a block into 4×4 sub-blocks according to the disclosed technique is shown.
[0038] Fig. 14B An exemplary subdivision pattern for subdividing a block into 8×8 sub-blocks according to the disclosed technique is shown.
[0039] Fig. 14C An exemplary subdivision pattern for subdividing a block into 4×8 sub-blocks according to the disclosed technique is shown.
[0040] Fig.14D An exemplary subdivision pattern for subdividing a block into 8×4 sub-blocks according to the disclosed technique is shown.
[0041] Fig.14E An exemplary subdivision pattern for subdividing a block into non-uniform sub-blocks according to the disclosed techniques is shown.
[0042] Fig.14F Another exemplary subdivision pattern for subdividing a block into non-uniform sub-blocks according to the disclosed technique is shown.
[0043] Figure 14G Yet another exemplary subdivision pattern for subdividing a block into non-uniform sub-blocks according to the disclosed technique is shown.
[0044] Figures 15A to 15D An exemplary embodiment of partial interleaved prediction is shown.
[0045] Figures 16A to 16C An exemplary embodiment of deriving the MV of one subdivision pattern from another subdivision pattern is shown.
[0046] Figures 17A to 17C An exemplary embodiment of selecting a subdivision style based on the size of the current video block is shown.
[0047] Fig.18A and Fig.18B An exemplary embodiment is shown in which an MV of a sub-block in one component within a subdivision pattern is derived from an MV of the sub-block in another component within another subdivision pattern.
[0048] Fig.19 is an example flow chart of a method for video processing based on some implementations of the disclosed technology.
[0049] Fig. 20 is an example flow chart of a video processing method based on some other implementations of the disclosed technology.
[0050] FIG. 21A to FIG. 21D is an example flow chart of a video processing method based on some other implementations of the disclosed technology.
[0051] Figures 22A to 22D is an example flow chart of a video processing method based on some other implementations of the disclosed technology.
[0052] Fig.23 and Fig.24 is a block diagram of an example of a hardware platform for implementing the video processing method described in the disclosed technology. DETAILED DESCRIPTION
[0053] Global motion compensation is one of many variants of motion compensation techniques and can be used to predict the motion of the camera. However, objects moving within a frame are not adequately represented by various implementations of global motion compensation. Local motion estimation (such as block motion compensation) that subdivides a frame into blocks of pixels for motion prediction can be used to account for objects moving within a frame.
[0054] Sub-block based prediction developed based on block motion compensation was first introduced into the video coding standard by High Efficiency Video Codec (HEVC) Annex I (3D-HEVC). Figure 1 1 is a schematic diagram showing an example of sub-block based prediction. In the case of sub-block based prediction, a block 100 (such as a coding unit (CU) or a prediction unit (PU)) is subdivided into several non-overlapping sub-blocks 101. Different sub-blocks may be assigned different motion information, such as reference indices or motion vectors (MVs). Motion compensation is then performed separately for each sub-block.
[0055] In order to explore future video codec technologies beyond HEVC, the Joint Video Exploration Team (JVET) was jointly established by the Video Coding Experts Group (VCEG) and the Moving Picture Experts Group (MPEG) in 2015. Many methods have been adopted by JVET and added to the reference software called Joint Exploration Model (JEM). In JEM, sub-block based prediction is adopted in several codec technologies, such as affine prediction, optional temporal motion vector prediction (ATMVP), spatial-temporal motion vector prediction (STMVP), bidirectional optical flow (BIO), and frame rate up conversion (FRUC) discussed in detail below.
[0056] Affine prediction
[0057] In HEVC, only the translation motion model is applied for motion compensated prediction (MCP). However, cameras and objects can have many types of motions, such as zoom-in / out, rotation, perspective motion, and / or other unconventional motions. On the other hand, JEM applies a simplified affine transformation motion compensated prediction. Figure 2 An example of an affine motion field of a block 200 described by two control point motion vectors V0 and V1 is shown. The motion vector field (MVF) of the block 200 can be described by the following equation:
[0058]
[0059] like Figure 2 As shown in 0x , v 0y ) is the motion vector of the upper left control point, and (v 1x , v 1y) is the motion vector of the upper right control point. To simplify motion compensation prediction, sub-block based affine transformation prediction can be applied. The sub-block size M×N is derived as follows:
[0060]
[0061] Here, MVPre is the fractional precision of the motion vector (e.g., 1 / 16 in JEM). 2x , v 2y ) is the motion vector of the lower left control point calculated according to equation (1). If necessary, M and N can be adjusted downward to make them divisors of w and h respectively.
[0062] Figure 3 An example of an affine MVF for each sub-block of block 300 is shown. To derive the motion vector for each M×N sub-block, the motion vector of the central sample of each sub-block can be calculated according to equation (1) and rounded to a fractional motion vector precision (e.g., 1 / 16 in JEM). Then, a motion compensated interpolation filter can be applied to generate a prediction for each sub-block using the derived motion vector. After MCP, the high-precision motion vector of each sub-block is rounded and saved to the same precision as the normal motion vector.
[0063] In JEM, there are two affine motion modes: AF_INTER mode and AF_MERGE mode. For CUs whose width and height are both greater than 8, AF_INTER mode can be applied. The affine flag in the CU level is signaled in the bitstream to indicate whether AF_INTER mode is used. In AF_INTER mode, a pair of motion vectors {(v0, v1)|v0={v1|v2={v2|v3|v4|v5|v6|v7|v8|v9|v1|v1|v1|v1|v2 ... A , v B , v C},v1={v D , v E}}'s candidate list. Figure 4 An example of motion vector prediction (MVP) of a block 400 in AF_INTER mode is shown. Figure 4As shown in , v0 is selected from the motion vector of sub-block A, B or C. The motion vector from the adjacent block can be scaled according to the reference list. The motion vector can also be scaled according to the relationship between the picture order count (POC) of the reference of the adjacent block, the POC of the reference of the current CU, and the POC of the current CU. The scheme for selecting v1 from adjacent sub-blocks D and E is similar. If the number of candidate lists is less than 2, the list is filled by a motion vector pair consisting of each of the AMVP candidates. When the candidate list is greater than 2, the candidates can first be classified according to adjacent motion vectors (e.g., based on the similarity of the two motion vectors in a pair of candidates). In some implementations, the first two candidates are retained. In some embodiments, a rate-distortion (RD) cost check is used to determine which motion vector pair candidate is selected as the control point motion vector prediction (CPMVP) of the current CU. An index indicating the position of the CPMVP in the candidate list can be signaled in the bitstream. After the CPMVP of the current affine CU is determined, affine motion estimation is applied, and the control point motion vector (CPMV) is found. The difference between the CPMV and the CPMVP is then signaled in the bitstream.
[0064] When a CU is applied in AF_MERGE mode, it obtains the first block coded in affine mode from valid neighboring reconstructed blocks. Figure 5A FIG. 5 shows an example of the selection order of candidate blocks of the current CU 500. Figure 5A As shown in , the selection order may be from the left ( 501 ), top ( 502 ), top right ( 503 ), bottom left ( 504 ) to top left ( 505 ) of the current CU 500 . Figure 5B Another example of candidate blocks of the current CU 500 in AF_MERGE mode is shown. If the neighboring lower left block 501 is encoded and decoded in affine mode, such as Figure 5B As shown in , the motion vectors v2, v3 and v4 of the upper left corner, upper right corner and lower left corner of the CU containing the sub-block 501 are derived. The motion vector v0 of the upper left corner on the current CU 500 is calculated based on v2, v3 and v4. The motion vector v1 of the upper right corner of the current CU is calculated accordingly. After the CPMV of the current CU v0 and v1 is calculated according to the affine motion model in equation (1), the MVF of the current CU can be generated. In order to identify whether the current CU is encoded and decoded in AF_MERGE mode, when there is at least one neighboring block encoded and decoded in affine mode, the affine flag can be signaled in the bitstream.
[0065] Optional Temporal Motion Vector Prediction (ATMVP)
[0066] In the ATMVP method, the temporal motion vector prediction (TMVP) method is modified by retrieving multiple sets of motion information (including motion vectors and reference indices) from blocks smaller than the current CU.
[0067] Figure 6 An example of the ATMVP motion prediction process for CU 600 is shown. The ATMVP method predicts the motion vector of a sub-CU 601 within CU 600 in two steps. The first step is to identify a corresponding block 651 in a reference picture 650 with a time domain vector. The reference picture 650 is also called a motion source picture. The second step is to partition the current CU 600 into sub-CUs 601 and obtain the motion vector and reference index of each sub-CU from the block corresponding to each sub-CU.
[0068] In the first step, the reference picture 650 and the corresponding block are determined by the motion information of the spatial neighboring blocks of the current CU 600. In order to avoid repeated scanning process of the neighboring blocks, the first MERGE candidate in the MERGE candidate list of the current CU 600 is used. The first available motion vector and its associated reference index are set to the temporal vector and the index of the motion source picture. In this way, the corresponding block can be identified more accurately than TMVP, where the corresponding block (sometimes called collocation block) is always in the lower right or central position relative to the current CU.
[0069] In a second step, the corresponding blocks of the sub-CU 651 are identified by the temporal vector in the motion source picture 650 by adding the temporal vector to the coordinates of the current CU. For each sub-CU, the motion information of the sub-CU is derived using the motion information of its corresponding block (e.g., the minimum motion grid covering the central sample point). After identifying the motion information of the corresponding N×N block, it is converted into the motion vector and reference index of the current sub-CU in the same way as the TMVP of HEVC, where motion scaling and other processes apply. For example, the decoder checks whether the low latency condition is met (e.g., the POC of all reference pictures of the current picture is less than the POC of the current picture), and possibly uses the motion vector MVx (e.g., the motion vector corresponding to the reference picture list X) to predict the motion vector MVy of each sub-CU (e.g., X is equal to 0 or 1, and Y is equal to 1-X).
[0070] Spatial-Temporal Motion Vector Prediction (STMVP)
[0071] In the STMVP method, the motion vector of the sub-CU is recursively derived following the raster scan order. Figure 7An example of a CU with four sub-blocks and neighboring blocks is shown. Consider an 8×8 CU 700, which contains four 4×4 sub-CUs, A (701), B (702), C (703), and D (704). The neighboring 4×4 blocks in the current frame are labeled a (711), b (712), c (713), and d (714).
[0072] The motion derivation of sub-CU A begins with identifying its two spatial neighbors. The first neighbor is the N×N block (block c 713) above sub-CU A701. If block c (713) is not available or is intra-coded, check the other N×N blocks above sub-CU A (701) (from left to right, starting from block c 713). The second neighbor is the block on the left side of sub-CU A 701 (block b 712). If block b (712) is not available or is intra-coded, check the other blocks on the left side of sub-CU A 701 (from top to bottom, starting from block b 712). For each list, the motion information obtained from the neighboring blocks is scaled to the first reference frame for the given list. Next, the temporal motion vector prediction (TMVP) of sub-block A 701 is derived by following the same process as TMVP as specified in HEVC. The motion information of the collocation block at block D 704 is retrieved and scaled accordingly. Finally, after extracting and scaling the motion information, all available motion vectors are averaged separately for each reference list. The averaged motion vector is assigned as the motion vector of the current sub-CU.
[0073] Bidirectional Optical Flow (BIO)
[0074] The Bidirectional Optical Flow (BIO) method is a sample-wise motion refinement performed on top of block-wise motion compensation for bidirectional prediction. In some implementations, the sample-level motion refinement does not use signaling.
[0075] make I (k) is the luminance value from reference k (k=0,1) after block motion compensation, and I (k) The horizontal and vertical components of the gradient. Assuming that the optical flow is valid, the motion vector field (v x ,v y ) is given by:
[0076]
[0077] Combining this optical flow equation with the Hermite interpolation of the motion trajectory for each sample point yields a unique third-order polynomial whose matching function value I (k) and the derivative at the end Both. The value of this polynomial at t=0 is the BIO prediction:
[0078]
[0079] Figure 8 An exemplary optical flow trajectory in the bidirectional optical flow (BIO) method is shown. Here, τ0 and τ1 refer to the distance from the reference frame. The distances τ0 and τ1 are calculated based on the POC of Ref0 and Ref1: τ0 = POC (current) - POC (Ref0), τ1 = POC (Ref1) - POC (current). If the two predictions are from the same temporal direction (both from the past or from the future), the signs are different (e.g., τ0·τ1 < 0). In this case, if the predictions are not from the same moment (e.g., τ0≠τ1), BIO is applied. Both reference regions have non-zero motion (e.g., MVx0, MVy0, MVx1, MVy1≠0), and the block motion vector is proportional to the temporal distance (e.g., MVx0 / MVx1 = MVy0 / MVy1 = -τ0 / τ1).
[0080] The motion vector field (v) is determined by minimizing the difference Δ between the values at point A and point B. x ,v y ). Figures 9A-9B An example of the intersection of the motion trajectory and the reference frame plane is shown. For Δ, the model only uses the first linear term of the local Taylor expansion:
[0081]
[0082] All values in the above equations depend on the sample location, denoted as (i′, j′). Assuming that the motion is consistent in the local surrounding area, Δ can be minimized within a (2M+1)×(2M+1) square window Ω centered at the currently predicted point (i, j), where M equals 2:
[0083]
[0084] For this optimization problem, JEM uses a simplified scheme, minimizing first in the vertical direction and then in the horizontal direction. This yields the following:
[0085]
[0086] in,
[0087]
[0088] To avoid division by zero or very small values, regularization parameters r and m can be introduced into equations (7) and (8).
[0089] r=500·4 d-8 Equation (10)
[0090] m=700·4 d-8 Equation (11)
[0091] Here, d is the bit depth of the video samples.
[0092] In order to make the memory access of BIO the same as that of conventional bi-directional prediction motion compensation, all predictions and gradient values I are calculated for the position within the current block. (k) , Fig. 9A An example of an access location outside of block 900 is shown. Fig. 9A As shown in , in equation (9), a (2M+1)×(2M+1) square window Ω centered on the current predicted point on the boundary of the predicted block needs to access locations outside the block. In JEM, I outside the block (k) , The value of is set equal to the closest available value within the block. For example, this can be implemented as filling area 901, such as Fig. 9B as shown in .
[0093] Using BIO, the motion field can be refined for each sample. In order to reduce the computational complexity, a block-based BIO is used in JEM. The motion refinement can be calculated based on a 4x4 block. In the block-based BIO, the s in equation (9) for all samples in the 4x4 block is n The values of can be aggregated, and then s n The aggregated values are used to derive the BIO motion vector offsets for the 4×4 block. More specifically, the following formula can be used for block-based BIO derivation:
[0094]
[0095] Here, b k Refers to the set of samples belonging to the kth 4x4 block of the predicted block. s in equations (7) and (8) n ((s n,bk )>>4) is replaced to derive the associated motion vector offset.
[0096] In some cases, the MV regiment of BIO may be unreliable due to noise or irregular motion. Therefore, in BIO, the size of the MV regiment is clipped to a threshold. The threshold is determined based on whether all the reference pictures of the current picture are from one direction. For example, if all the reference pictures of the current picture are from one direction, the value of the threshold is set to 12×2. 14-d ; otherwise, set it to 12×2 13-d .
[0097] The gradient of the BIO may be calculated simultaneously with the motion compensated interpolation using operations consistent with the HEVC motion compensation process (e.g., 2D separable finite impulse response (FIR)). In some embodiments, the input to the 2D separable FIR is the same reference frame samples as the motion compensation process and the fractional positions (fracX, fracY) according to the fractional part of the block motion vector. For the horizontal gradient The signal is first interpolated vertically using BIOfilterS, which corresponds to the fractional position fracY with a descaling displacement of d-8. Then a gradient filter BIOfilterG is applied in the horizontal direction corresponding to the fractional position fracX with a descaling displacement of 18-d. For the vertical gradient Corresponding to the fractional position fracY with descaling displacement d-8, a gradient filter is applied vertically using BIOfilterG. Then corresponding to the fractional position fracX with descaling displacement 18-d, a signal displacement is performed in the horizontal direction using BIOfilterS. The length of the interpolation filter for gradient calculation BIOfilterG and signal displacement BIOfilterF can be shorter (e.g., 6-tap) in order to maintain a reasonable complexity. Table 1 shows exemplary filters for gradient calculation of different fractional positions of block motion vectors in BIO. Table 2 shows exemplary interpolation filters that can be used for prediction signal generation in BIO.
[0098] Table 1: Example filters for gradient calculation in BIO
[0099] Fractional pixel position Gradient interpolation filter (BIOfilterG) 0 {8,-39,-3,46,-17,5} 1 / 16 {8,-32,-13,50,-18,5} 1 / 8 {7,-27,-20,54,-19,5} 3 / 16 {6,-21,-29,57,-18,5} 1 / 4 {4,-17,-36,60,-15,4} 5 / 16 {3,-9,-44,61,-15,4} 3 / 8 {1,-4,-48,61,-13,3} 7 / 16 {0,1,-54,60,-9,2} 1 / 2 {-1,4,-57,57,-4,1}
[0100] Table 2: Exemplary interpolation filters for prediction signal generation in BIO
[0101] Fractional pixel position Interpolation filter for prediction signal (BIOfilterS) 0 {0,0,64,0,0,0} 1 / 16 {1,-3,64,4,-2,0} 1 / 8 {1,-6,62,9,-3,1} 3 / 16 {2,-8,60,14,-5,1} 1 / 4 {2,-9,57,19,-7,2} 5 / 16 {3,-10,53,24,-8,2} 3 / 8 {3,-11,50,29,-9,2} 7 / 16 {3,-11,44,35,-10,3} 1 / 2 {3,-10,35,44,-11,3}
[0102] In JEM, BIO can be applied to all bi-directionally predicted blocks when the two predictions come from different reference pictures. BIO can be disabled when local illumination compensation (LIC) is enabled for a CU.
[0103] In some embodiments, OBMC is applied to the block after the normal MC process. In order to reduce computational complexity, BIO may not be applied during the OBMC process. This means that during the OBMC process, when using its own MV, BIO is applied in the MC process of the block, and when using the MV of the neighboring block, BIO is not applied in the MC process.
[0104] Frame Rate Up Conversion (FRUC)
[0105] When the Merge flag of a CU is true, the FRUC flag may be signaled to the CU. When the FRUC flag is false, the Merge index may be signaled and the normal Merge mode is used. When the FRUC flag is true, an additional FRUC mode flag may be signaled to indicate which method (e.g., bilateral matching or template matching) to use to derive motion information for the block.
[0106] On the encoder side, the decision whether to use the FRUC Merge mode for a CU is based on RD cost selection, as done for normal Merge candidates. For example, by using RD cost selection, multiple matching modes (e.g., bilateral matching and template matching) are checked for a CU. The one pointing to the minimum cost is further compared with other CU modes. If the FRUC matching mode is the most efficient one, the FRUC flag is set to true for the CU and the relevant matching mode is used.
[0107] Typically, the motion derivation process in FRUC Merge mode has two steps: first a CU-level motion search, then a sub-CU-level motion refinement. At the CU level, an initial motion vector is derived for the entire CU based on bilateral matching or template matching. First, a list of MV candidates is generated, and the candidate pointing to the minimum matching cost is selected as the starting point for further CU-level refinement. Then a local search based on bilateral matching or template matching is performed around the starting point. The MV that results in the minimum matching cost is taken as the MV of the entire CU. Subsequently, the motion information is further refined at the sub-CU level using the derived CU motion vector as the starting point.
[0108] For example, the following derivation process is performed for W×H CU motion information derivation. In the first stage, the MV of the entire W×H CU is derived. In the second stage, the CU is further subdivided into M×M sub-CUs. The value of M is calculated as in (16), and D is a predetermined partition depth, which is set to 3 by default in JEM. Then the MV of each sub-CU is derived.
[0109]
[0110] Fig.10 An example of bilateral matching used in a frame rate up conversion (FRUC) method is shown. Bilateral matching is used to derive motion information of the current CU by finding the closest match between two blocks along the motion trajectory of the current CU (1000) in two different reference pictures (1010, 1011). Under the assumption of a continuous motion trajectory, the motion vectors MV0 (1001) and MV 1(1002) is proportional to the temporal distance between the current picture and the two reference pictures, for example, TD0 (1003) and TD1 (1004). In some embodiments, when the current picture 1000 is temporally between the two reference pictures (1010, 1011) and the temporal distance from the current picture to the two reference pictures is the same, bilateral matching becomes a mirror image based on bidirectional MV.
[0111] Fig.11 An example of template matching used in the FRUC method is shown. Template matching can be used to derive motion information of the current CU 1100 by finding the closest match between a template in the current picture (e.g., the upper and / or left adjacent blocks of the current CU) and a block in the reference picture 1110 (e.g., the same size as the template). In addition to the above-mentioned FRUC Merge mode, template matching can also be applied to the AMVP mode. In both JEM and HEVC, there are two candidates for AMVP. Using the template matching method, new candidates can be derived. If the newly derived candidate by template matching is different from the first existing AMVP candidate, it is inserted at the beginning of the AMVP candidate list, and then the list size is set to 2 (e.g., by removing the second existing AMVP candidate). When applied to AMVP mode, only CU-level search is applied.
[0112] The MV candidates set at the CU level may include the following: (1) if the current CU is in AMVP mode, the original AMVP candidate, (2) all Merge candidates, (3) several MVs in the interpolated MV field (described later) and the upper and left adjacent motion vectors.
[0113] When bilateral matching is used, each valid MV of a Merge candidate can be used as input to generate MV pairs under the assumption of bilateral matching. For example, a valid MV of a Merge candidate is (MVa, ref a ). Then, find the reference image ref of its paired bilateral MV in other reference list B. b , so that ref a and ref b Located on different sides of the current picture in time. If such a ref in reference list B b If not available, ref b is identified as ref a Different reference, and its temporal distance to the current picture is the smallest one in list B. In determining ref b Afterwards, based on the current image and ref a ,ref b The temporal distance between them is calculated by scaling MVa to derive MVb.
[0114] In some implementations, four MVs from the interpolated MV field can also be added to the CU-level candidate list. More specifically, the interpolated MVs at the positions (0,0), (W / 2,0), (0, H / 2), and (W / 2, H / 2) of the current CU are added. When FRUC is applied to AMVP mode, the original AMVP candidate is also added to the CU-level MV candidate set. In some implementations, at the CU level, 15 MVs for the AMVP CU and 13 MVs for the Merge CU can be added to the candidate list.
[0115] The MV candidate set at the sub-CU level includes (1) MVs determined from the CU level search, (2) top, left, top-left, and top-right neighboring MVs, (3) scaled versions of collocated MVs from reference pictures, (4) one or more ATMVP candidates (e.g., up to four), and (5) one or more STMVP candidates (e.g., up to four). The scaled MVs from the reference picture are derived as follows. The reference pictures in the two lists are traversed. The MV at the collocated position of the sub-CU in the reference picture is scaled to the reference of the starting CU level MV. The ATMVP and STMVP candidates can be the first four. At the sub-CU level, one or more MVs (e.g., up to 17) are added to the candidate list.
[0116] Generation of interpolated MV fields
[0117] Before encoding and decoding the frame, an interpolated motion field is generated for the entire picture based on the single-sided ME. The motion field can then be used as a CU-level or sub-CU-level MV candidate.
[0118] In some embodiments, the motion field of each reference picture in both reference lists is traversed at a 4x4 block level. Fig.12 An example of a single-sided motion estimation (ME) 1200 in the FRUC method is shown. For each 4×4 block, if the motion associated with the block passes through a 4×4 block in the current picture (e.g. Fig.12 As shown) and the block has not been assigned any interpolated motion, the motion of the reference block is scaled to the current picture according to the temporal distances TD0 and TD1 (in the same way as the MV scaling of TMVP in HEVC), and the scaled motion is assigned to the block in the current frame. If no scaled MV is assigned to the 4×4 block, the motion of the block is marked as unavailable in the interpolated motion field.
[0119] Interpolation and matching costs
[0120] When the motion vectors point to fractional sample locations, motion compensated interpolation is required.To reduce complexity, bilinear interpolation can be used instead of conventional 8-tap HEVC interpolation for both bilateral matching and template matching.
[0121] The calculation of the matching cost is slightly different at different steps. When selecting a candidate from a candidate set at the CU level, the matching cost can be the sum of absolute differences (SAD) of bilateral matching or template matching. After determining the starting MV, the matching cost C of the bilateral matching of the sub-CU level search is calculated as follows:
[0122]
[0123] Here, w is a weight factor. In some embodiments, w can be set to 4 based on experience. MV and MV s Indicates the current MV and the starting MV respectively. SAD can still be used as the matching cost of template matching for sub-CU level search.
[0124] In FRUC mode, MV is derived by using luma samples only. The derived motion will be used for both luma and chroma for MC inter prediction. After deciding MV, final MC is performed using 8-tap interpolation filter for luma and 4-tap interpolation filter for chroma.
[0125] MV refinement is based on the style of MV search, which has the criteria of bilateral matching cost or template matching cost. In JEM, two search styles are supported - unrestricted center biased diamond search (UCBDS) and adaptive cross search for MV refinement at CU level and sub-CU level respectively. For CU and sub-CU level MV refinement, MV is directly searched with quarter luma sample MV precision, and followed by one-eighth luma sample MV refinement. The search range for MV refinement at CU and sub-CU steps is set to equal 8 luma samples.
[0126] In bilateral matching Merge mode, bidirectional prediction is applied because the motion information of a CU is derived based on the closest match between two blocks along the motion trajectory of the current CU in two different reference pictures. In template matching Merge mode, the encoder can choose between unidirectional prediction from list0, unidirectional prediction from list1, or bidirectional prediction for the CU. The selection can be based on the template matching cost as follows:
[0127] If costBi <= factor * min (cost0, cost1)
[0128] Bidirectional prediction is used;
[0129] Otherwise, if cost0 <= cost1
[0130] Then use the one-way prediction from list0;
[0131] otherwise,
[0132] Use the one-way prediction from list1;
[0133] Here, cost0 is the SAD of list0 template matching, cost1 is the SAD of list1 template matching, and costBi is the SAD of bidirectional prediction template matching. For example, when the value of factor is equal to 1.25, it means that the selection process is biased towards bidirectional prediction. Inter prediction direction selection can be applied to the CU level template matching process.
[0134] Deblocking process in VVC
[0135] 8.6.2 Deblocking Filtering Process
[0136] 8.6.2.1 Overview
[0137] The input to this process is the reconstructed picture before deblocking, ie the array recPictureL and, when ChromaArrayType is not equal to 0, the arrays recPictureCb and recPictureCr.
[0138] The output of this process is the modified reconstructed picture after deblocking, ie the array recPictureL and, when ChromaArrayType is not equal to 0, the arrays recPictureCb and recPictureCr.
[0139] First, filter the vertical edges in the picture. Then, filter the horizontal edges in the picture with samples modified by the vertical edge filtering process as input. The vertical edges and horizontal edges in the CTB of each CTU are processed separately based on the codec unit. Filter the vertical edges of the codec blocks in the codec unit starting from the edge on the left hand side of the codec block and moving through the edges in its geometric order towards the right side of the codec block. Filter the horizontal edges of the codec blocks in the codec unit starting from the edge at the top of the codec block and moving through the edges in its geometric order towards the bottom of the codec block.
[0140] NOTE - Although the filtering process is specified on a picture basis in this specification, the filtering process can be implemented on a codec unit basis to have equivalent results as long as the decoder properly considers the processing dependency order to produce the same output values.
[0141] The deblocking filtering process is applied to all codec sub-block edges and transform block edges of a picture, except for the following types of edges:
[0142] – edges at the borders of the picture,
[0143] – When loop_filter_across_tiles_enabled_flag is equal to 0, edges that coincide with tile boundaries,
[0144] – an edge that coincides with the top or left border of a tile group that has tile_group_loop_filter_across_tile_groups_enabled_flag equal to 0 or tile_group_deblocking_filter_disabled_flag equal to 1,
[0145] – an edge within a tile group with tile_group_deblocking_filter_disabled_flag equal to 1,
[0146] – edges that do not correspond to the boundaries of the 8x8 grid of samples of the component under consideration,
[0147] – edges within chroma samples using inter prediction on both sides of the edge,
[0148] – An edge of a chroma transform block that is not an edge of the associated transform unit.
[0149] [Ed.(BB): Adapting the syntax once the pieces are integrated.]
[0150] The edge type, vertical or horizontal, is represented by the variable edgeType as specified in Table 8-17.
[0151] Table 8-17 – Names associated with edgeType
[0152] edgeType The name of the edgeType
[0153] 0 (vertical edge) EDGE_VER
[0154] 1 (horizontal edge) EDGE_HOR
[0155] When tile_group_deblocking_filter_disabled_flag of the current tile group is equal to 0, the following applies:
[0156] –The variable treeType is exported as follows:
[0157] – If tile_group_type is equal to 1 and qtbtt_dual_tree_intra_flag is equal to 1, treeType is set equal to DUAL_TREE_LUMA.
[0158] – Otherwise, treeType is set equal to SINGLE_TREE.
[0159] – Filter vertical edges by the deblocking filtering process for one direction with the following call, as specified in clause 8.6.2.2, using the variable treeType, the reconstructed picture before deblocking, that is, the array recPictureL, and when ChromaArrayType is not equal to 0 or treeType is equal to SINGLE_TREE, the arrays recPictureCb and recPictureCr, and the variable edgeType set equal to EDGE_VER as input, and the modified reconstructed picture after deblocking, that is, the array recPictureL, and when ChromaArrayType is not equal to 0 or treeType is equal to SINGLE_TREE, the arrays recPictureCb and recPictureCr as output.
[0160] – Filter horizontal edges by performing a deblocking filtering process for one direction with the following call, as specified in clause 8.6.2.2, using the variable treeType, the modified reconstructed picture after deblocking, i.e., the array recPictureL, and when ChromaArrayType is not equal to 0 or treeType is equal to SINGLE_TREE, the arrays recPictureCb and recPictureCr, and the variable edgeType set equal to EDGE_HOR as input, and the modified reconstructed picture after deblocking, i.e., the array recPictureL, and when ChromaArrayType is not equal to 0 or treeType is equal to SINGLE_TREE, the arrays recPictureCb and recPictureCr as output.
[0161] – When tile_group_type is equal to 1 and qtbtt_dual_tree_intra_flag is equal to 1, the following applies:
[0162] – The variable treeType is set equal to DUAL_TREE_CHROMA
[0163] – Filter vertical edges by the deblocking filtering process for one direction with the following call, as specified in clause 8.6.2.2, using the variable treeType, the reconstructed picture before deblocking, i.e., the arrays recPictureCb and recPictureCr, and the variable edgeType set equal to EDGE_VER as input, and the modified reconstructed picture after deblocking, i.e., the arrays recPictureCb and recPictureCr as output.
[0164] – Filter the horizontal edges by the deblocking filtering process for one direction with the following call, as specified in clause 8.6.2.2, using the variable treeType, the modified reconstructed picture after deblocking, i.e., the arrays recPictureCb and recPictureCr, and the variable edgeType set equal to EDGE_HOR as input, and the modified reconstructed picture after deblocking, i.e., the arrays recPictureCb and recPictureCr as output.
[0165] 8.6.2.2 Deblocking filter process for one direction
[0166] The input to this process is:
[0167] – The variable treeType specifies whether a single tree (SINGLE_TREE) or a dual tree is used to split the CTU, and when using a dual tree, whether the luma (DUAL_TREE_LUMA) or chroma components (DUAL_TREE_CHROMA) are currently processed,
[0168] – when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the reconstructed picture before deblocking, i.e., the array recPictureL,
[0169] – When ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA, the arrays recPictureCb and recPictureCr,
[0170] – The variable edgeType specifies whether vertical (EDGE_VER) or horizontal (EDGE_HOR) edges are filtered.
[0171] The output of this process is the modified reconstructed picture after deblocking, namely:
[0172] – When treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the array recPictureL,
[0173] – When ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA, the arrays recPictureCb and recPictureCr.
[0174] For each coding unit with coding block width log2CbW, coding block height log2CbH, and the position of the top-left sample of the coding block (xCb, yCb), when edgeType is equal to EDGE_VER and xCb % 8 is equal to 0 or when edgeType is equal to EDGE_HOR and yCb % 8 is equal to 0, the edges are filtered by the following steps in the order:
[0175] 1. The coding block width nCbW is set to be equal to 1 << log2CbW, and the coding block height nCbH is set to be equal to 1 << log2CbH
[0176] 2. The variable filterEdgeFlag is derived as follows:
[0177] – If edgeType is equal to EDGE_VER and one or more of the following conditions are true, then filterEdgeFlag is set to be equal to 0:
[0178] – The left boundary of the current coding block is the left boundary of the picture.
[0179] – The left boundary of the current coding block is the left boundary of the slice and loop_filter_across_tiles_enabled_flag is equal to 0.
[0180] – The left boundary of the current coding block is the left boundary of the tile group and tile_group_loop_filter_across_tile_groups_enabled_flag is equal to 0.
[0181] – Otherwise, if edgeType is equal to EDGE_HOR and one or more of the following conditions are true, then the variable filterEdgeFlag is set to be equal to 0:
[0182] – The top boundary of the current luma coding block is the top boundary of the picture.
[0183] – The top boundary of the current codec block is the top boundary of the slice and loop_filter_across_tiles_enabled_flag is equal to 0.
[0184] – The top boundary of the current codec block is the top boundary of the slice group and tile_group_loop_filter_across_tile_groups_enabled_flag is equal to 0.
[0185] – Otherwise, filterEdgeFlag is set equal to 1.
[0186] [Ed.(BB): Adapting the syntax once the pieces are integrated.]
[0187] 3. All elements of the two-dimensional (nCbW) x (nCbH) array edgeFlags are initialized to zero.
[0188] 4. Invoke the transform block boundary derivation process specified in clause 8.6.2.3 as follows, using the position (xB0, yB0) set equal to (0, 0), the block width nTbW set equal to nCbW, the block height nTbH set equal to nCbH, the variable treeType, the variable filterEdgeFlag, the array edgeFlags, and the variable edgeType as inputs, and its modified array edgeFlags as output.
[0189] 5. Call the derivation process of the codec subblock boundaries specified in clause 8.6.2.4 with the following, using the position (xCb, yCb), the codec block width nCbW, the codec block height nCbH, the array edgeFlags, and the variable edgeType as input, and the modified array edgeFlags as output.
[0190] 6. The image sample array recPicture is exported as follows:
[0191] – If treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, recPicture is set equal to the reconstructed luma picture sample array recPictureL before deblocking.
[0192] – Otherwise (treeType is equal to DUAL_TREE_CHROMA), recPicture is set equal to the reconstructed chroma picture sample array recPictureCb before deblocking.
[0193] 7. Invoke the boundary filter strength derivation process specified in clause 8.6.2.5 as follows, using the picture sample array recPicture, the luma positions (xCb, yCb), the codec block width nCbW, the codec block height nCbH, the variable edgeType, and the array edgeFlags as input, and the (nCbW)x(nCbH) array verBs as output.
[0194] 8. The edge filtering process is called as follows:
[0195] – If edgeType is equal to EDGE_VER, the vertical edge filtering process of the codec unit specified in clause 8.6.2.6.1 is invoked as follows, using the variable treeType, the reconstructed picture before deblocking, i.e., when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the array recPictureL, and when ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA, the arrays recPictureCb and recPictureCr, the position (xCb, yCb), the codec block width nCbW, the codec block height nCbH, and the array verBs as input, and the modified reconstructed picture, i.e., when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the array recPictureL, and when ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA, the arrays recPictureCb and recPictureCr.
[0196] – Otherwise, if edgeType is equal to EDGE_HOR, the horizontal edge filtering process of the codec unit as specified in clause 8.6.2.6.2 is invoked with the variable treeType and the modified reconstructed picture before deblocking, i.e., the array recPictureL when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, and the arrays recPictureCb and when ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA recPictureCr, position (xCb, yCb), codec block width nCbW, codec block height nCbH, and array horBs as input, and the modified reconstructed picture, i.e., array recPictureL when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, and arrays recPictureCb and recPictureCr as output.
[0197] 8.6.2.3 Derivation of Transform Block Boundaries
[0198] The input to this process is:
[0199] – Position (xB0, yB0), specifies the top left sample of the current block relative to the top left sample of the current codec block,
[0200] – The variable nTbW specifies the width of the current block,
[0201] – variable nTbH, specifies the height of the current block,
[0202] – The variable treeType specifies whether a single tree (SINGLE_TREE) or a dual tree is used to split the CTU, and when using a dual tree, whether the luma (DUAL_TREE_LUMA) or chroma components (DUAL_TREE_CHROMA) are currently processed,
[0203] – variable filterEdgeFlag,
[0204] – 2D (nCbW) x (nCbH) array edgeFlags,
[0205] – The variable edgeType specifies whether vertical (EDGE_VER) or horizontal (EDGE_HOR) edges are filtered.
[0206] The output of this process is a modified two-dimensional (nCbW) x (nCbH) array edgeFlags.
[0207] The maximum transform block size maxTbSize is derived as follows:
[0208] maxTbSize=(treeType==DUAL_TREE_CHROMA)? MaxTbSizeY / 2:MaxTbSizeY(8862)
[0209] Depending on maxTbSize, the following applies:
[0210] – If nTbW is greater than maxTbSize or nTbH is greater than maxTbSize, the following order of steps applies.
[0211] 1. The variables newTbW and newTbH are derived as follows:
[0212] newTbW=(nTbW>maxTbSize)? (nTbW / 2):nTbW(8 863)
[0213] newTbH=(nTbH>maxTbSize)? (nTbH / 2):nTbH(8 864)
[0214] 2. The derivation process for the transform block boundaries specified in this clause is called as follows, using the position (xB0, yB0), the variable nTbW set equal to newTbW and the variable nTbH set equal to newTbH, the variable filterEdgeFlag, the array edgeFlags, and the variable edgeType as inputs, and the output is the modified version of the array edgeFlags.
[0215] 3. If nTbW is greater than maxTbSize, then the derivation process for the transform block boundaries specified in this clause is called as follows, with the luma position (xTb0, yTb0) set equal to (xTb0+newTbW, yTb0), the variable nTbW set equal to newTbW and the variable nTbH set equal to newTbH, the variable filterEdgeFlag, the array edgeFlags and the variable edgeType as inputs, and the output is a modified version of the array edgeFlags.
[0216] 4. If nTbH is greater than maxTbSize, the derivation process for the transform block boundaries specified in this clause is invoked as follows, using the luma position (xTb0, yTb0) set equal to (xTb0, yTb0+newTbH), the variable nTbW set equal to newTbW and the variable nTbH set equal to newTbH, the variable filterEdgeFlag, the array edgeFlags and the variable edgeType as inputs, and the output is a modified version of the array edgeFlags.
[0217] 5. If nTbW is greater than maxTbSize and nTbH is greater than maxTbSize, then the derivation process for the transform block boundaries specified in this clause is invoked as follows, with the luma position (xTb0, yTb0) set equal to (xTb0+newTbW, yTb0+newTbH), the variable nTbW set equal to newTbW and the variable nTbH set equal to newTbH, the variable filterEdgeFlag, the array edgeFlags and the variable edgeType as inputs, and the output is a modified version of the array edgeFlags.
[0218] – Otherwise, the following applies:
[0219] – If edgeType is equal to EDGE_VER, the value of edgeFlags[xB0][yB0+k] is derived for k=0..nTbH-1 as follows:
[0220] –If xB0 is equal to 0, edgeFlags[xB0][yB0+k] is set equal to filterEdgeFlag.
[0221] – Otherwise, edgeFlags[xB0][yB0+k] is set equal to 1.
[0222] – Otherwise (edgeType equals EDGE_HOR), the value of edgeFlags[xB0+k][yB0] is derived for k=0..nTbW-1 as follows:
[0223] –If yB0 is equal to 0, edgeFlags[xB0+k][yB0] is set equal to filterEdgeFlag.
[0224] – Otherwise, edgeFlags[xB0+k][yB0] is set equal to 1.
[0225] 8.6.2.4 Derivation process of codec sub-block boundaries
[0226] The input to this process is:
[0227] – Position (xCb, yCb), specifies the top left sample of the current codec block relative to the top left sample of the current picture,
[0228] –Variable nCbW specifies the width of the current codec block.
[0229] –Variable nCbH, specifies the height of the current codec block,
[0230] – 2D (nCbW) x (nCbH) array edgeFlags,
[0231] – The variable edgeType specifies whether vertical (EDGE_VER) or horizontal (EDGE_HOR) edges are filtered.
[0232] The output of this process is a modified two-dimensional (nCbW) x (nCbH) array edgeFlags.
[0233] The number of coded sub-blocks numSbX in the horizontal direction and the number of coded sub-blocks numSbY in the vertical direction are derived as follows:
[0234] – If CuPredMode[xCb][yCb] == MODE_INTRA, then numSbX and numSbY are both set equal to 1.
[0235] – Otherwise, numSbX and numSbY are set equal to NumSbX[xCb][yCb] and NumSbY[xCb][yCb], respectively.
[0236] Depending on the value of edgeType, the following applies:
[0237] – If edgeType is equal to EDGE_VER and numSbX is greater than 1, then for i = 1..min((nCbW / 8)-1, numSbX-1), k = 0..nCbH-1, the following applies:
[0238] edgeFlags[i*Max(8,nCbW / numSbX)][k]=1(8 865)
[0239] – Otherwise, if edgeType is equal to EDGE_HOR and numSbY is greater than 1, for j = 1..min((nCbH / 8)-1, numSbY-1), k = 0..nCbW-1, the following applies:
[0240] edgeFlags[k][j*Max(8,nCbH / numSbY)]=1(8 866)
[0241] 8.6.2.5 Derivation process of boundary filter strength
[0242] The input to this process is:
[0243] – Picture sample array recPicture,
[0244] – Position (xCb, yCb), specifies the top left sample of the current codec block relative to the top left sample of the current picture,
[0245] –Variable nCbW specifies the width of the current codec block.
[0246] –Variable nCbH, specifies the height of the current codec block,
[0247] – The variable edgeType specifies whether the filter is a vertical (EDGE_VER) or horizontal (EDGE_HOR) edge.
[0248] – 2D (nCbW) x (nCbH) array of edgeFlags.
[0249] The output of this process is a two-dimensional (nCbW)x(nCbH) array bS specifying the boundary filter strength.
[0250] The variables xDi, yDj, xN and yN are derived as follows:
[0251] –If edgeType is equal to EDGE_VER, xDi is set equal to (i<<3), yDj is set equal to (j<<2), xN is set equal to Max(0, (nCbW / 8)-1), and yN is set equal to (nCbH / 4)-1.
[0252] – Otherwise (edgeType equals EDGE_HOR), xDi is set equal to (i<<2), yDj is set equal to (j<<3), xN is set equal to (nCbW / 4)-1 and yN is set equal to Max(0, (nCbH / 8)-1).
[0253] For xDi, where i = 0..xN, and yDj, where j = 0..yN, the following applies:
[0254] – If edgeFlags[xDi][yDj] is equal to 0, the variable bS[xDi][yDj] is set equal to 0.
[0255] – Otherwise, the following applies:
[0256] – The sample values p0 and q0 are derived as follows:
[0257] – If edgeType is equal to EDGE_VER, p0 is set equal to recPicture[xCb+xDi-1][yCb+yDj] and q0 is set equal to recPicture[xCb+xDi][yCb+yDj].
[0258] – Otherwise (edgeType equals EDGE_HOR), p0 is set equal to recPicture[xCb+xDi][yCb+yDj-1] and q0 is set equal to recPicture[xCb+xDi][yCb+yDj].
[0259] – The variable bS[xDi][yDj] is derived as follows:
[0260] – If sample p0 or q0 is in a coded block of a codec unit coded in intra prediction mode, bS[xDi][yDj] is set equal to 2.
[0261] – Otherwise, if the block edge is also a transform block edge and sample p0 or q0 is in a transform block containing one or more non-zero transform coefficient levels, then bS[xDi][yDj] is set equal to 1.
[0262] – Otherwise, bS[xDi][yDj] is set equal to 1 if one or more of the following conditions are true:
[0263] – For the prediction of the coded subblock containing sample p0, a different reference picture or a different number of motion vectors is used than for the prediction of the coded subblock containing sample q0.
[0264] NOTE 1 – Determining whether the reference pictures used for two codec sub-blocks are the same or different is based only on which pictures are referenced, and is independent of whether an index from reference picture list 0 or an index from reference picture list 1 is used to form the prediction, or whether the index positions within the reference picture lists are different.
[0265] NOTE 2 – The number of motion vectors used to predict the codec sub-block with left top sample coverage (xSb, ySb) is equal to PredFlagL0[xSb][ySb]+PredFlagL1[xSb][ySb].
[0266] – One motion vector is used to predict the codec sub-block containing sample p0, and one motion vector is used to predict the codec sub-block containing sample q0, and the absolute difference between the horizontal or vertical components of the motion vectors used is greater than or equal to 4 in units of quarter luma samples.
[0267] – Two motion vectors and two different reference pictures are used to predict the codec sub-block containing sample p0, and two motion vectors of the same two reference pictures are used to predict the codec sub-block containing sample q0, and the absolute difference between the horizontal or vertical components of the two motion vectors used in the prediction of the two codec sub-blocks of the same reference picture is greater than or equal to 4 in units of quarter luma samples.
[0268] – Two motion vectors for the same reference picture are used to predict the codec sub-block containing sample p0, and two motion vectors for the same reference picture are used to predict the codec sub-block containing sample q0, and both of the following conditions are true:
[0269] – the absolute difference between the horizontal or vertical components of the list 0 motion vectors used in the prediction of the two codec sub-blocks is greater than or equal to 4 in units of quarter luma samples, or the absolute difference between the horizontal or vertical components of the list 0 motion vectors used in the prediction of the two codec sub-blocks is greater than or equal to 4 in units of quarter luma samples.
[0270] – the absolute difference between the horizontal or vertical component of the list 0 motion vector used in the prediction of the codec sub-block containing sample p0 and the list 1 motion vector used in the prediction of the codec sub-block containing sample q0 is greater than or equal to 4 in units of quarter luma samples, or the absolute difference between the horizontal or vertical component of the list 1 motion vector used in the prediction of the codec sub-block containing sample p0 and the list 0 motion vector used in the prediction of the codec sub-block containing sample q0 is greater than or equal to 4 in units of quarter luma samples.
[0271] – Otherwise, set the variable bS[xDi][yDj] equal to 0.
[0272] 8.6.2.6 Edge Filtering Process
[0273] 8.6.2.6.1 Vertical edge filtering process
[0274] The input to this process is:
[0275] – The variable treeType specifies whether a single tree (SINGLE_TREE) or a dual tree is used to split the CTU, and when using a dual tree, whether the luma component (DUAL_TREE_LUMA) or the chroma component (DUAL_TREE_CHROMA) is currently being processed,
[0276] – when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the reconstructed picture before deblocking, i.e., the array recPictureL,
[0277] – When ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA, the arrays recPictureCb and recPictureCr,
[0278] – Position (xCb, yCb), specifies the top left sample of the current codec block relative to the top left sample of the current picture,
[0279] –Variable nCbW specifies the width of the current codec block.
[0280] –Variable nCbH specifies the height of the current codec block.
[0281] The output of this process is the modified reconstructed picture after deblocking, namely:
[0282] – When treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the array recPictureL,
[0283] – Arrays recPictureCb and recPictureCr when ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA.
[0284] When treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the filtering process for edges in the luma codec block of the current codec unit consists of the following steps in the following order:
[0285] 1. The variable xN is set equal to Max(0, (nCbW / 8)-1) and yN is set equal to (nCbH / 4)-1.
[0286] 2. For xDk equal to k<<3, where k=0..nN and yDm equal to m<<2, where m=0..yN, apply the following:
[0287] – When bS[xDk][yDm] is greater than 0, the following sequence of steps applies:
[0288] a. Invoke the block edge determination process specified in clause 8.6.2.6.3 as follows, using treeType, the picture sample array recPicture set equal to the luma picture sample array recPictureL, the location of the luma codec block (xCb, yCb), the luma location of the block (xDk, yDm), the variable edgeType set to EDGE_VER, the boundary filter strength bS[xDk][yDm], and the bit depth bD set to BitDepthY as inputs, and the decisions dE, dEp and dEq, and the variable tC as outputs.
[0289] b. Invoke the block edge filtering process specified in clause 8.6.2.6.4 with the following, using the picture sample array recPicture set equal to the luma picture sample array recPictureL, the location of the luma codec block (xCb, yCb), the luma location of the block ((xDk, yDm)), the variable edgeType set equal to EDGE_VER, the determined values of dE, dEp and dEq, and the variable tC as input, and the modified luma picture sample array recPictureL as output.
[0290] When ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE, the filtering process for edges in the chroma codec block of the current codec unit consists of the following steps in the following order:
[0291] 1. The variable xN is set equal to Max(0, (nCbW / 8)-1) and yN is set equal to Max(0, (nCbH / 8)-1).
[0292] 2. The variable edgeSpacing is set equal to 8 / SubWidthC.
[0293] 3. The variable edgeSections is set equal to yN*(2 / SubHeightC).
[0294] 4. For xDk equal to k*edgeSpacing, where k=0..xN and yDm equal to m<<2, where m=0..edgeSections, apply the following:
[0295] – When bS[xDk*SubWidthC][yDm*SubHeightC] is equal to 2 and (((xCb / SubWidthC+xDk)>>3)<<3) is equal to xCb / SubWidthC+xDk, apply the following steps in the following order:
[0296] a. Invoke the chroma block edge filtering process specified by clause 8.6.2.6.5 with the following, using the chroma picture sample array recPictureCb, the position of the chroma codec block (xCb / SubWidthC, yCb / SubHeightC), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_VER and the variable cQpPicOffset set equal to pps_cb_qp_offset as input, and the modified chroma picture sample array recPictureCb as output.
[0297] b. Invoke the chroma block edge filtering process specified in clause 8.6.2.6.5 with the following, using the chroma picture sample array recPictureCr, the position of the chroma codec block (xCb / SubWidthC, yCb / SubHeightC), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_VER and the variable cQpPicOffset set equal to pps_cr_qp_offset as input, and the modified chroma picture sample array recPictureCr as output.
[0298] When treeType is equal to DUAL_TREE_CHROMA, the filtering process for the edges between the two chroma codec blocks of the current codec unit consists of the following steps in the following order:
[0299] 1. The variable xN is set equal to Max(0, (nCbW / 8)-1) and yN is set equal to (nCbH / 4)-1.
[0300] 2. For xDk equal to k<<3, where k=0..xN and yDm equal to m<<2, where m=0..yN, apply the following:
[0301] – When bS[xDk][yDm] is greater than 0, the following sequence of steps applies:
[0302] a. Invoke the block edge determination process specified in clause 8.6.2.6.3 as follows, using treeType, the picture sample array recPicture set equal to the chroma picture sample array recPictureCb, the position of the chroma codec block (xCb, yCb), the position of the chroma block (xDk, yDm), the variable edgeType set equal to EDGE_VER, the boundary filter strength bS[xDk][yDm], and the bit depth bD set equal to BitDepthC as inputs, and determine dE, dEp and dEq, and the variable tC as output.
[0303] b. Invoke the block edge filtering process specified in clause 8.6.2.6.4 with the following, using the picture sample array recPicture set equal to the chroma picture sample array recPictureCb, the position of the chroma codec block (xCb, yCb), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_VER, the determined values of dE, dEp and dEq, and the variable tC as input, and the modified chroma picture sample array recPictureCb as output.
[0304] c. Invoke the block edge filtering process specified in clause 8.6.2.6.4 with the following, using the picture sample array recPicture set equal to the chroma picture sample array recPictureCr, the position of the chroma codec block (xCb, yCb), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_VER, the determined values of dE, dEp and dEq, and the variable tC as input, and the modified chroma picture sample array recPictureCr as output.
[0305] 8.6.2.6.2 Horizontal edge filtering process
[0306] The input to this process is:
[0307] – The variable treeType specifies whether a single tree (SINGLE_TREE) or a dual tree is used to split the CTU, and when using a dual tree, whether the luma component (DUAL_TREE_LUMA) or the chroma component (DUAL_TREE_CHROMA) is currently being processed,
[0308] – when treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the reconstructed picture before deblocking, i.e., the array recPictureL,
[0309] – When ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA, the arrays recPictureCb and recPictureCr,
[0310] – Position (xCb, yCb), specifies the top left sample of the current codec block relative to the top left sample of the current picture,
[0311] –Variable nCbW specifies the width of the current codec block.
[0312] –Variable nCbH specifies the height of the current codec block.
[0313] The output of this process is the modified reconstructed picture after deblocking, namely:
[0314] – When treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the array recPictureL,
[0315] – Arrays recPictureCb and recPictureCr when ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE or DUAL_TREE_CHROMA.
[0316] When treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the filtering process for edges in the luma codec block of the current codec unit consists of the following steps in the following order:
[0317] 1. The variable yN is set equal to Max(0, (nCbH / 8)-1) and xN is set equal to (nCbW / 4)-1.
[0318] 2. For yDm equal to m<<3, where m=0..yN and xDk equal to k<<2, where k=0..xN, apply the following:
[0319] – When bS[xDk][yDm] is greater than 0, the following sequence of steps applies:
[0320] a. Invoke the block edge determination process specified in clause 8.6.2.6.3 as follows, using treeType, the picture sample array recPicture set equal to the luma picture sample array recPictureL, the location of the luma codec block (xCb, yCb), the luma location of the block ((xDk, yDm)), the variable edgeType set equal to EDGE_HOR, the boundary filter strength bS[xDk][yDm], and the bit depth bD set equal to BitDepthY as inputs, and determine dE, dEp and dEq, and variable tC as output.
[0321] b. Invoke the block edge filtering process specified in clause 8.6.2.6.4 with the following, using the picture sample array recPicture set equal to the luma picture sample array recPictureL, the location of the luma codec block (xCb, yCb), the luma location of the block ((xDk, yDm)), the variable edgeType set equal to EDGE_HOR, the determined values of dEp, dEp and dEq, and the variable tC as input, and the modified luma picture sample array recPictureL as output.
[0322] When ChromaArrayType is not equal to 0 and treeType is equal to SINGLE_TREE, the filtering process for edges in the chroma codec block of the current codec unit consists of the following steps in the following order:
[0323] 1. The variable xN is set equal to Max(0, (nCbW / 8)-1) and yN is set equal to Max(0, (nCbH / 8)-1).
[0324] 2. The variable edgeSpacing is set equal to 8 / SubHeightC.
[0325] 3. The variable edgeSections is set equal to xN*(2 / SubWidthC).
[0326] 4. For yDm equal to m*edgeSpacing, where m=0..yN and xDk equal to k<<2, where k=0..edgeSections, apply the following:
[0327] – When bS[xDk*SubWidthC][yDm*SubHeightC] is equal to 2 and (((yCb / SubHeightC+yDm)>>3)<<3) is equal to yCb / SubHeightC+yDm, apply the following steps in the following order:
[0328] a. Invoke the chroma block edge filtering process specified in clause 8.6.2.6.5 with the following, using the chroma picture sample array recPictureCb, the position of the chroma codec block (xCb / SubWidthC, yCb / SubHeightC), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_HOR and the variable cQpPicOffset set equal to pps_cb_qp_offset as input, and the modified chroma picture sample array recPictureCb as output.
[0329] b. Invoke the chroma block edge filtering process specified in clause 8.6.2.6.5 with the following, using the chroma picture sample array recPictureCr, the position of the chroma codec block (xCb / SubWidthC, yCb / SubHeightC), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_HOR and the variable cQpPicOffset set equal to pps_cr_qp_offset as input, and the modified chroma picture sample array recPictureCr as output.
[0330] When treeType is equal to DUAL_TREE_CHROMA, the filtering process for the edges between the two chroma codec blocks of the current codec unit consists of the following steps in the following order:
[0331] 1. The variable yN is set equal to Max(0, (nCbH / 8)-1) and xN is set equal to (nCbW / 4)-1.
[0332] 2. For yDm equal to m<<3, where m=0..yN and xDk equal to k<<2, where k=0..xN, apply the following:
[0333] – When bS[xDk][yDm] is greater than 0, the following sequence of steps applies:
[0334] a. Invoke the block edge determination process specified in clause 8.6.2.6.3 as follows, using treeType, the picture sample array recPicture set equal to the chroma picture sample array recPictureCb, the position of the chroma codec block (xCb, yCb), the position of the chroma block (xDk, yDm), the variable edgeType set equal to EDGE_HOR, the boundary filter strength bS[xDk][yDm], and the bit depth bD set equal to BitDepthC as inputs, and determine dE, dEp and dEq, and the variable tC as output.
[0335] b. Invoke the block edge filtering process specified in clause 8.6.2.6.4 with the following, using the picture sample array recPicture set equal to the chroma picture sample array recPictureCb, the position of the chroma codec block (xCb, yCb), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_HOR, the determined values of dE, dEp and dEq, and the variable tC as input, and the modified chroma picture sample array recPictureCb as output.
[0336] c. Invoke the block edge filtering process specified in clause 8.6.2.6.4 with the following, using the picture sample array recPicture set equal to the chroma picture sample array recPictureCr, the position of the chroma codec block (xCb, yCb), the chroma position of the block (xDk, yDm), the variable edgeType set equal to EDGE_HOR, the determined values of dE, dEp and dEq, and the variable tC as input, and the modified chroma picture sample array recPictureCr as output.
[0337] 8.6.2.6.3 Block edge determination process
[0338] The input to this process is:
[0339] – The variable treeType specifies whether a single tree (SINGLE_TREE) or a dual tree is used to split the CTU, and when using a dual tree, whether the luma component (DUAL_TREE_LUMA) or the chroma component (DUAL_TREE_CHROMA) is currently being processed,
[0340] – Picture sample array recPicture,
[0341] – Position (xCb, yCb), specifies the top left sample of the current codec block relative to the top left sample of the current picture,
[0342] – Position (xBl, yBl), specifies the top left sample of the current block relative to the top left sample of the current codec block,
[0343] – The variable edgeType specifies whether the filter is a vertical (EDGE_VER) or horizontal (EDGE_HOR) edge.
[0344] – variable bS, specifies the boundary filter strength,
[0345] –Variable bD specifies the depth of the current component.
[0346] The output of this process is:
[0347] – contains the determining variables dE, dEp and dEq,
[0348] –Variable tC.
[0349] If edgeType is equal to EDGE_VER, then the sample values pi,k and qi,k, where i = 0..3 and k = 0 and 3, are derived as follows:
[0350] qi,k=recPictureL[xCb+xBl+i][yCb+yBl+k](8 867)
[0351] pi,k=recPictureL[xCb+xBl-i-1][yCb+yBl+k](8 868)
[0352] Otherwise (edgeType equals EDGE_HOR), the sample values pi,k and qi,k, where i = 0..3 and k = 0 and 3, are derived as follows:
[0353] qi,k=recPicture[xCb+xBl+k][yCb+yBl+i] (8 869)
[0354] pi,k=recPicture[xCb+xBl+k][yCb+yBl-i-1] (8 870)
[0355] The variable qpOffset is derived as follows:
[0356] – If sps_ladf_enabled_flag is equal to 1 and treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, the following applies:
[0357] – The variable lumaLevel that reconstructs the brightness level is exported as follows:
[0358] lumaLevel=((p0,0+p0,3+q0,0+q0,3)>>2), (8 871)
[0359] – The variable qpOffset is set equal to sps_ladf_lowest_interval_qp_offset and is modified as follows:
[0360]
[0361] – Otherwise (treeType is equal to DUAL_TREE_CHROMA), qpOffset is set equal to 0.
[0362] The variables QpQ and QpP are derived as follows:
[0363] – If treeType is equal to SINGLE_TREE or DUAL_TREE_LUMA, QpQ and QpP are set equal to the QpY value of the codec unit that includes the codec blocks containing samples q0,0 and p0,0 respectively.
[0364] – Otherwise (treeType is equal to DUAL_TREE_CHROMA), QpQ and QpP are set equal to the QpC value of the codec unit that includes the codec blocks containing samples q0,0 and p0,0 respectively.
[0365] The variable qP is derived as follows:
[0366] qP=((QpQ+QpP+1)>>1)+qpOffset (8 873)
[0367] The value of the variable β′ is determined based on the quantization parameter Q as specified in Table 8-18, and the quantization parameter Q is derived as follows:
[0368] Q=Clip3(0,63,qP+(tile_group_beta_offset_div2<<1)) (8874)
[0369] Wherein tile_group_beta_offset_div2 is the value of the syntax element tile_group_beta_offset_div2 of the slice group containing the sample q0,0.
[0370] The variable β is derived as follows:
[0371] β=β′*(1<<(bD-8))(8 875)
[0372] The value of the variable tC′ is determined based on the quantization parameter Q as specified in Table 8-18, and the quantization parameter Q is derived as follows:
[0373] Q=Clip3(0, 65, qP+2*(bS-1)+(tile_group_tc_offset_div2<<1))(8 876)
[0374] Wherein tile_group_tc_offset_div2 is the value of the syntax element tile_group_tc_offset_div2 of the slice group containing the sample q0,0.
[0375] The variable tC is derived as follows:
[0376] tC=tC′*(1<<(bD-8))(8 877)
[0377] Depending on the value of edgeType, the following applies:
[0378] – If edgeType is equal to EDGE_VER, the following order of steps applies:
[0379] 1. The variables dpq0, dpq3, dp, dq, and d are derived as follows:
[0380] dp0=Abs(p2,0-2*p1,0+p0,0) (8 878)
[0381] dp3=Abs(p2,3-2*p1,3+p0,3) (8 879)
[0382] dq0=Abs(q2,0-2*q1,0+q0,0) (8 880)
[0383] dq3=Abs(q2,3-2*q1,3+q0,3) (8 881)
[0384] dpq0=dp0+dq0(8 882)
[0385] dpq3=dp3+dq3(8 883)
[0386] dp=dp0+dp3 (8 884)
[0387] dq=dq0+dq3 (8 885)
[0388] d=dpq0+dpq3 (8 886)
[0389] 2. The variables dE, dEp and dEq are set equal to 0.
[0390] 3. When d is less than β, apply the following sequence of steps:
[0391] a. The variable dpq is set equal to 2*dpq0.
[0392] b. For the sample position (xCb+xBl, yCb+yBl), the sample decision process as specified in clause 8.6.2.6.6 is called as follows, using the sample values p0,0, p3,0, q0,0, and q3,0, the variables dpq, β, and tC as inputs, and the output is assigned to the decision dSam0.
[0393] c. The variable dpq is set equal to 2*dpq3.
[0394] d. For the sample position (xCb+xBl, yCb+yBl+3), the sample decision process as specified in clause 8.6.2.6.6 is called as follows, using the sample values p0,3, p3,3, q0,3, and q3,3, the variables dpq, β and tC as inputs, and the output is assigned to the decision dSam3.
[0395] e. The variable dE is set equal to 1.
[0396] f. When dSam0 is equal to 1 and dSam3 is equal to 1, the variable dE is set equal to 2.
[0397] g. When dp is less than (β+(β>>1))>>3, the variable dEp is set equal to 1.
[0398] h. When dq is less than (β+(β>>1))>>3, the variable dEq is set equal to 1.
[0399] – Otherwise (edgeType equals EDGE_HOR), the following steps are applied in the following order:
[0400] 1. The variables dpq0, dpq3, dp, dq, and d are derived as follows:
[0401] dp0=Abs(p2,0-2*p1,0+p0,0) (8 887)
[0402] dp3=Abs(p2,3-2*p1,3+p0,3) (8 888)
[0403] dq0=Abs(q2,0-2*q1,0+q0,0) (8 889)
[0404] dq3=Abs(q2,3-2*q1,3+q0,3) (8 890)
[0405] dpq0=dp0+dq0(8 891)
[0406] dpq3=dp3+dq3(8 892)
[0407] dp=dp0+dp3 (8 893)
[0408] dq=dq0+dq3 (8 894)
[0409] d=dpq0+dpq3 (8 895)
[0410] 2. The variables dE, dEp and dEq are set equal to 0.
[0411] 3. When d is less than β, apply the following sequence of steps:
[0412] a. The variable dpq is set equal to 2*dpq0.
[0413] b. For the sample position (xCb+xBl, yCb+yBl), the sample decision process as specified in clause 8.6.2.6.6 is called as follows, using the sample values p0,0, p3,0, q0,0 and q3,0, variables dpq, β and tC as inputs, and the output is assigned to the decision dSam0.
[0414] c. The variable dpq is set equal to 2*dpq3.
[0415] d. For the sample position (xCb+xBl+3, yCb+yBl), the sample decision process as specified in clause 8.6.2.6.6 is called as follows, using the sample values p0,3, p3,3, q0,3 and q3,3, the variables dpq, β and tC as inputs, and the output is assigned to the decision dSam3.
[0416] e. The variable dE is set equal to 1.
[0417] f. When dSam0 is equal to 1 and dSam3 is equal to 1, the variable dE is set equal to 2.
[0418] g. When dp is less than (β+(β>>1))>>3, the variable dEp is set equal to 1.
[0419] h. When dq is less than (β+(β>>1))>>3, the variable dEq is set equal to 1.
[0420] Table 8 18 – Derivation of threshold variables β′ and tC′ from input Q
[0421]
[0422] 8.6.2.6.4 Block edge filtering process
[0423] The input to this process is:
[0424] – Picture sample array recPicture,
[0425] – Position (xCb, yCb), specifies the top left sample of the current codec block relative to the top left sample of the current picture,
[0426] – Position (xBl, yBl), specifies the top left sample of the current block relative to the top left sample of the current codec block,
[0427] – The variable edgeType specifies whether the filter is a vertical (EDGE_VER) or horizontal (EDGE_HOR) edge.
[0428] – contains the determining variables dE, dEp and dEq,
[0429] –Variable tC.
[0430] The output of this process is the modified picture sample array recPicture.
[0431] Depending on the value of edgeType, the following applies:
[0432] – If edgeType is equal to EDGE_VER, the following order of steps applies:
[0433] 1. The sample point values pi,k and qi,k, with i = 0..3 and k = 0..3, are derived as follows:
[0434] qi,k=recPictureL[xCb+xBl+i][yCb+yBl+k](8 896)
[0435] pi,k=recPictureL[xCb+xBl-i-1][yCb+yBl+k](8 897)
[0436] 2. When dE is not equal to 0, for each sample point position (xCb+xBl, yCb+yBl+k), k=0..3, apply the following sequence of steps:
[0437] a. Invoke the filtering process of samples as specified in clause 8.6.2.6.7 with the following, using sample values pi,k,qi,k, where i = 0..3, positions (xPi,yPi) set equal to (xCb+xBl-i-1,yCb+yBl+k) and (xQi,yQi) (i = 0..2) set equal to (xCb+xBl+i,yCb+yBl+k), determining dE, variables dEp and dEq and variable tC as inputs, and the number of filtered samples nDp and nDq from each side of the block boundary and the filtered sample values pi' and qj' as outputs.
[0438] b. When nDp is greater than 0, the filtered sample value pi' (where i = 0..nDp-1) replaces the corresponding sample in the sample array recPicture as follows:
[0439] recPicture[xCb+xBl-i-1][yCb+yBl+k]=pi'(8 898)
[0440] c. When nDq is greater than 0, the filtered sample value qj' (where j = 0..nDq-1) replaces the corresponding sample in the sample array recPicture:
[0441] recPicture[xCb+xBl+j][yCb+yBl+k]=qj'(8 899)
[0442] – Otherwise (edgeType equals EDGE_HOR), the following steps are applied in the following order:
[0443] 1. The sample point values pi,k and qi,k, where i = 0..3 and k = 0..3 are derived as follows:
[0444] qi,k=recPictureL[xCb+xBl+k][yCb+yBl+i](8 900)
[0445] pi,k=recPictureL[xCb+xBl+k][yCb+yBl-i-1](8 901)
[0446] 2. When dE is not equal to 0, for each sample point position (xCb+xBl+k, yCb+yBl), k=0..3, apply the following sequence of steps:
[0447] a. Invoke the filtering process of samples as specified in clause 8.6.2.6.7 with the following, using sample values pi,k,qi,k, where i = 0..3, positions (xPi,yPi) set equal to (xCb+xBl+k, yCb+yBl-i-1) and (xQi,yQi) (i = 0..2) set equal to (xCb+xBl+k, yCb+yBl+i), determining dE, variables dEp and dEq, and variable tC as inputs, and the number of filtered samples nDp and nDq from each side of the block boundary and the filtered sample values pi' and qj' as outputs.
[0448] b. When nDp is greater than 0, the filtered sample value pi' (where i = 0..nDp-1) replaces the corresponding sample in the sample array recPicture:
[0449] recPicture[xCb+xBl+k][yCb+yBl-i-1]=pi'(8 902)
[0450] c. When nDq is greater than 0, the filtered sample value qj' (where j = 0..nDq-1) replaces the corresponding sample in the sample array recPicture:
[0451] recPicture[xCb+xBl+k][yCb+yBl+j]=qj'(8 903)
[0452] 8.6.2.6.5 Filtering of chroma block edges
[0453] This procedure is called only if ChromaArrayType is not equal to 0.
[0454] The input to this process is:
[0455] – chrominance picture sample array s′,
[0456] – Chroma position (xCb, yCb), specifies the top left sample of the current chroma codec block relative to the top left chroma sample of the current picture,
[0457] – Chroma position (xBl, yBl), specifies the top left sample of the current chroma block relative to the top left sample of the current chroma codec block,
[0458] – The variable edgeType specifies whether the filter is a vertical (EDGE_VER) or horizontal (EDGE_HOR) edge.
[0459] –Variable cQpPicOffset specifies the picture-level chroma quantization parameter offset.
[0460] The output of this process is a modified chrominance picture sample array s'.
[0461] If edgeType is equal to EDGE_VER, the values pi and qi, where i = 0..1 and k = 0..3, are derived as follows:
[0462] qi,k=s′[xCb+xBl+i][yCb+yBl+k](8 904)
[0463] pi,k=s′[xCb+xBl-i-1][yCb+yBl+k](8 905)
[0464] Otherwise (edgeType equals EDGE_HOR), the sample values pi and qi, where i = 0..1 and k = 0..3, are derived as follows:
[0465] qi,k=s′[xCb+xBl+k][yCb+yBl+i](8 906)
[0466] pi,k=s′[xCb+xBl+k][yCb+yBl-i-1](8 907)
[0467] The variables QpQ and QpP are set equal to the value of QpY for the codec unit comprising the codec block containing samples q0,0 and p0,0 respectively.
[0468] If ChromaArrayType is equal to 1, the variable QpC is determined as specified in Table 8-15 based on the index qPi, which is derived as follows:
[0469] qPi=((QpQ+QpP+1)>>1)+cQpPicOffset(8 908)
[0470] Otherwise (ChromaArrayType is greater than 1), the variable QpC is set equal to Min(qPi, 63).
[0471] NOTE - The variable cQpPicOffset provides an adjustment to the value of pps_cb_qp_offset or pps_cr_qp_offset, depending on whether the chroma component being filtered is a Cb or Cr component. However, to avoid the need to change the amount of adjustment within the picture, the filtering process does not include an adjustment to the value of tile_group_cb_qp_offset or tile_group_cr_qp_offset.
[0472] The value of the variable tC′ is determined based on the chromaticity quantization parameter Q as specified in Table 8-18. The chromaticity quantization parameter Q is derived as follows:
[0473] Q=Clip3(0, 65, QpC+2+(tile_group_tc_offset_div2<<1)) (8 909)
[0475] Wherein tile_group_tc_offset_div2 is the value of the syntax element tile_group_tc_offset_div2 of the slice group containing the sample q0,0.
[0476] The variable tC is derived as follows:
[0477] tC=tC′*(1<<(BitDepthC-8))(8 910)
[0478] Depending on the value of edgeType, the following applies:
[0479] – If edgeType is equal to EDGE_VER, then for each sample position (xCb+xBl, yCb+yBl+k), k=0..3, apply the following sequence of steps:
[0480] 1. The filtering process for chroma samples as specified in clause 8.6.2.6.8 is invoked with the following, using sample values pi,k, qi,k, where i = 0..1, positions (xCb+xBl-1, yCb+yBl+k) and (xCb+xBl, yCb+yBl+k) and variable tC as input, and filtered sample values p0′ and q0′ as output.
[0481] 2. The filtered sample values p0′ and q0′ replace the corresponding samples in the sample array s′ as follows:
[0482] s′[xCb+xBl][yCb+yBl+k]=q0′(8 911)
[0483] s′[xCb+xBl-1][yCb+yBl+k]=p0′(8 912)
[0484] – Otherwise (edgeType equals EDGE_HOR), for each sample position (xCb+xBl+k, yCb+yBl), k=0..3, apply the following sequence of steps:
[0485] 1. The filtering process for chroma samples as specified in clause 8.6.2.6.8 is invoked with the following, using sample values pi,k, qi,k, where i = 0..1, positions (xCb+xBl+k, yCb+yBl-1) and (xCb+xBl+k, yCb+yBl), and variable tC as input, and the filtered sample values p0′ and q0′ as output.
[0486] 2. The filtered sample values p0′ and q0′ replace the corresponding samples in the sample array s′ as follows:
[0487] s′[xCb+xBl+k][yCb+yBl]=q0′(8 913)
[0488] s′[xCb+xBl+k][yCb+yBl-1]=p0′(8 914)
[0489] 8.6.2.6.6 Sample point determination process
[0490] The input to this process is:
[0491] – Sample values p0, p3, q0 and q3,
[0492] – Variables dpq, β and tC.
[0493] The output of this process is the variable dSam containing the decision.
[0494] The variable dSam is specified as follows:
[0495] –If dpq is less than (β>>2), then Abs(p3-p0)+Abs(q0-q3) is less than (β>>3) and Abs(p0-q0) is less than (5*tC+1)>>1, and dSam is set equal to 1.
[0496] – Otherwise, dSam is set equal to 0.
[0497] 8.6.2.6.7 Sample filtering process
[0498] The input to this process is:
[0499] – sample point values pi and qi, where i = 0..3,
[0500] – The positions of pi and qi, (xPi, yPi)(xQi, yQi), where i = 0..2,
[0501] – variable dE,
[0502] – variables dEp and dEq, containing the decision of the filter samples p1 and q1 respectively,
[0503] –Variable tC.
[0504] The output of this process is:
[0505] – the number of filtered samples nDp and nDq,
[0506] – Filtered sample values pi′ and qj′, where i=0..nDp-1, j=0..nDq-1.
[0507] Depending on the value of dE, the following applies:
[0508] – If the variable dE is equal to 2, both nDp and nDq are set equal to 3 and the following strong filtering is applied:
[0509] p0′=Clip3(p0-2*tC, p0+2*tC, (p2+2*p1+2*p0+2*q0+q1+4)>>3)(8 915)
[0510] p1′=Clip3(p1-2*tC, p1+2*tC, (p2+p1+p0+q0+2)>>2) (8 916)
[0512] p2′=Clip3(p2-2*tC, p2+2*tC, (2*p3+3*p2+p1+p0+q0+4)>>3)(8 917)
[0513] q0′=Clip3(q0-2*tC, q0+2*tC, (p1+2*p0+2*q0+2*q1+q2+4)>>3)(8 918)
[0514] q1′=Clip3(q1-2*tC, q1+2*tC, (p0+q0+q1+q2+2)>>2) (8 919)
[0516] q2′=Clip3(q2-2*tC, q2+2*tC, (p0+q0+q1+3*q2+2*q3+4)>>3)(8 920)
[0517] – Otherwise, nDp and nDq are both set equal to 0 and the following weak filtering is applied:
[0518] – Apply the following:
[0519] ==(9*(q0-p0)-3*(q1-p1)+8)>>4(8 921)
[0520] – When Abs() is less than tC*10, the following sequence of steps is applied:
[0521] – The filtered sample values p0′ and q0′ are specified as follows:
[0522] ==Clip3(-tC,tC,) (8 922)
[0523] p0′=Clip1Y(p0+) (8 923)
[0524] q0′=Clip1Y(q0-) (8 924)
[0525] – When dEp is equal to 1, the filtered sample value p1′ is specified as follows:
[0526] p=Clip3(-(tC>>1), tC>>1, (((p2+p0+1)>>1)-p1+)>>1)(8 925)
[0527] p1′=Clip1Y(p1+p)(8 926)
[0528] – When dEq is equal to 1, the filtered sample value q1′ is specified as follows:
[0529] q=Clip3(-(tC>>1), tC>>1, (((q2+q0+1)>>1)-q1-)>>1)(8 927)
[0530] q1′=Clip1Y(q1+q)(8 928)
[0531] –nDp is set equal to dEp+1 and nDq is set equal to dEq+1.
[0532] When nDp is greater than 0 and one or more of the following conditions are true, nDp is set equal to 0:
[0533] –pcm_loop_filter_disabled_flag is equal to 1 and pcm_flag[xP0][yP0] is equal to 1.
[0534] – cu_transquant_bypass_flag is equal to 1 for the codec unit that includes the codec block containing sample p0.
[0535] When nDq is greater than 0 and one or more of the following conditions are true, nDq is set equal to 0:
[0536] –pcm_loop_filter_disabled_flag is equal to 1 and pcm_flag[xQ0][yQ0] is equal to 1.
[0537] – cu_transquant_bypass_flag is equal to 1 for the codec unit that includes the codec block containing sample q0.
[0538] 8.6.2.6.8 Filtering of chroma samples
[0539] This procedure is called only if ChromaArrayType is not equal to 0.
[0540] The input to this process is:
[0541] – Chroma sample values pi and qi, where i = 0..1,
[0542] – the chrominance positions of p0 and q0, (xP0, yP0) and (xQ0, yQ0),
[0543] –Variable tC.
[0544] The output of this process is the filtered sample values p0′ and q0′.
[0545] The filtered sample values p0′ and q0′ are derived as follows:
[0546] ==Clip3(-tC,tC,((((q0-p0)<<2)+p1-q1+4)>>3)) (8 929)
[0547] p0′=Clip1C(p0+) (8 930)
[0548] q0′=Clip1C(q0-) (8 931)
[0549] The filtered sample value, p0′, is replaced by the corresponding input sample value, p0, when one or more of the following conditions are true:
[0550] –pcm_loop_filter_disabled_flag is equal to 1 and pcm_flag[xP0*SubWidthC][yP0*SubHeightC] is equal to 1.
[0551] – cu_transquant_bypass_flag is equal to 1 for the codec unit that includes the codec block containing sample p0.
[0552] The filtered sample value, q0′, is replaced by the corresponding input sample value q0 when one or more of the following conditions are true:
[0553] –pcm_loop_filter_disabled_flag is equal to 1 and pcm_flag[xQ0*SubWidthC][yQ0*SubHeightC] is equal to 1.
[0554] – cu_transquant_bypass_flag is equal to 1 for the codec unit that includes the codec block containing sample q0.
[0555] 8.6.3 Sample point adaptive migration process
[0556] 8.6.3.1 Overview
[0557] The input to this process is the reconstructed picture sample array recPictureL before sample adaptive shifting and, when ChromaArrayType is not equal to 0, the arrays recPictureCb and recPictureCr.
[0558] The output of this process is the modified reconstructed picture sample array saoPictureL after sample adaptive shifting, and when ChromaArrayType is not equal to 0, the arrays saoPictureCb and saoPictureCr.
[0559] This process is performed based on CTB after the deblocking filtering process of the decoded picture is completed.
[0560] The sample values in the modified reconstructed picture sample array saoPictureL, and when ChromaArrayType is not equal to 0, the arrays saoPictureCb and saoPictureCr are initially set equal to the sample values in the reconstructed picture sample array recPictureL, and when ChromaArrayType is not equal to 0, to the arrays recPictureCb and recPictureCr, respectively.
[0561] For each CTU with CTB position (rx, ry), where rx = 0..PicWidthInCtbsY - 1 and ry = 0..PicHeightInCtbsY - 1, the following rules apply:
[0562] – When the tile_group_sao_luma_flag of the current slice group is equal to 1, call the CTB modification process specified in Clause 8.6.3.2 with the following inputs: recPicture set to be equal to recPictureL, cIdx set to 0, (rx, ry), and both nCtbSw and nCtbSh set to be equal to CtbSizeY, and the modified luma picture sample array saoPictureL as the output.
[0563] – When ChromaArrayType is not equal to 0 and the tile_group_sao_chroma_flag of the current slice group is equal to 1, call the CTB modification process specified in Clause 8.6.3.2 with the following inputs: recPicture set to recPictureCb, cIdx set to 1, (rx, ry), nCtbSw set to be equal to (1 << CtbLog2SizeY) / SubWidthC, nCtbSh set to be equal to (1 << CtbLog2SizeY) / SubHeightC, and the modified chroma picture sample array saoPictureCb as the output.
[0564] – When ChromaArrayType is not equal to 0 and the tile_group_sao_chroma_flag of the current slice group is equal to 1, call the CTB modification process specified in Clause 8.6.3.2 with the following inputs: recPicture set to recPictureCr, cIdx set to 2, (rx, ry), nCtbSw set to be equal to (1 << CtbLog2SizeY) / SubWidthC, nCtbSh set to be equal to (1 << CtbLog2SizeY) / SubHeightC, and the modified chroma picture sample array saoPictureCr as the output.
[0565] 8.6.3.2 CTB Modification Process
[0566] The inputs to this process are:
[0567] – The picture sample array recPicture of color component cIdx,
[0568] – The variable cIdx, specifying the color component index,
[0569] – a pair of variables (rx, ry) specifying the CTB location,
[0570] –CTB width nCtbSw and height nCtbSh.
[0571] The output of this process is the modified picture sample array saoPicture of the color component cIdx.
[0572] The variable bitDepth is derived as follows:
[0573] – If cIdx is equal to 0, bitDepth is set equal to BitDepthY.
[0574] – Otherwise, bitDepth is set equal to BitDepthC.
[0575] The position (xCtb, yCtb), relative to the top left sample component cIdx of the current picture, specifies the top left sample of the current CTB of the color component cIdx, and is derived as follows:
[0576] (xCtb, yCtb) = (rx*nCtbSw, ry*nCtbSh) (8 932)
[0577] The sample point positions within the current CTB are derived as follows:
[0578] (xSi, ySj)=(xCtb+i, yCtb+j) (8 933)
[0579] (xYi,yYj)=(cIdx==0)? (xSi, ySj): (xSi*SubWidthC, ySj*SubHeightC) (8934)
[0580] For all sample positions (xSi, ySj) and (xYi, yYj) with i = 0..nCtbSw–1 and j = 0..nCtbSh-1, depending on the values of pcm_loop_filter_disabled_flag, pcm_flag[xYi][yYj] and cu_transquant_bypass_flag of the codec unit containing the codec block covering recPicture[xSi][ySj], the following applies:
[0581] – saoPicture[xSi][ySj] is not modified if one or more of the following conditions are true:
[0582] –pcm_loop_filter_disabled_flag and pcm_flag[xYi][yYj] are both equal to 1.
[0583] –cu_transquant_bypass_flag is equal to 1.
[0584] –SaoTypeIdx[cIdx][rx][ry] is equal to 0.
[0585] [Ed.(BB): Revised highlighted section pending future decision on conversion / quantization bypass.]
[0586] – Otherwise, if SaoTypeIdx[cIdx][rx][ry] is equal to 2, apply the following steps in the following order:
[0587] 1. Based on SaoEoClass[cIdx][rx][ry], the values of hPos[k] and vPos[k] for k=0..1 are specified in Tables 8-19.
[0588] 2. The variable edgeIdx is derived as follows:
[0589] – The modified sample point positions (xSik′, ySjk′) and (xYik′, yYjk′) are derived as follows:
[0590] (xSik′, ySjk′)=(xSi+hPos[k], ySj+vPos[k]) (8 935)
[0591] (xYik′,yYjk′)=(cIdx==0)? (xSik′, ySjk′): (xSik′*SubWidthC, ySjk′*SubHeightC) (8 936)
[0592] – edgeIdx is set equal to 0 if one or more of the following conditions is true for all sample positions (xSik′, ySjk′) and (xYik′, yYjk′), k=0..1:
[0593] – The sample at position (xSik′, ySjk′) is outside the picture boundary.
[0594] – The sample at position (xSik′, ySjk′) belongs to different slice groups and one of the following two conditions is true:
[0595] –MinTbAddrZs[xYik′>>MinTbLog2SizeY][yYjk′>>MinTbLog2SizeY] is less than MinTbAddrZs[xYi>>MinTbLog2SizeY][yYj>>MinTbLog2SizeY] and tile_group_loop_filter_across_tile_groups_enabled_flag in the slice group to which the sample recPicture[xSi][ySj] belongs is equal to 0.
[0596] –MinTbAddrZs[xYi>>MinTbLog2SizeY][yYj>>MinTbLog2SizeY] is less than MinTbAddrZs[xYik′>>MinTbLog2SizeY][yYjk′>>MinTbLog2SizeY] and tile_group_loop_filter_across_tile_groups_enabled_flag in the slice group to which the sample recPicture[xSik′][ySjk′] belongs is equal to 0.
[0597] – loop_filter_across_tiles_enabled_flag is equal to 0 and the samples at position (xSik′, ySjk′) belong to different tiles.
[0598] [Ed.(BB): Modify highlighted part when merging slices without slice groups]
[0599] – Otherwise, edgeIdx is derived as follows:
[0600] – Apply the following:
[0601] edgeIdx=2+Sign(recPicture[xSi][ySj]-recPicture[xSi+hPos[0]][ySj+vPos[0]])+Sign(recPicture[xSi][ySj]-recPicture[xSi+hPos[1]][ySj+vPos[1]]) (8937)
[0602] – When edgeIdx is equal to 0, 1, or 2, edgeIdx is modified as follows:
[0603] edgeIdx=(edgeIdx==2)? 0: (edgeIdx+1) (8 938)
[0604] 3. The modified picture sample array saoPicture[xSi][ySj] is derived as follows:
[0605] saoPicture[xSi][ySj]=Clip3(0, (1< <bitDepth)-1,recPicture[xSi][ySj]+SaoOffsetVal[cIdx][rx][ry][edgeIdx]) (8 939)
[0606] – Otherwise (SaoTypeIdx[cIdx][rx][ry] is equal to 1), apply the following steps in the following order:
[0607] 1. The variable bandShift is set equal to bitDepth-5.
[0608] 2. The variable saoLeftClass is set equal to sao_band_position[cIdx][rx][ry].
[0609] 3. The list bandTable is defined with 32 elements and all elements are initially set equal to 0. Then, four of the elements (indicating the start position of the bands of explicit offsets) are modified as follows:
[0610] For (k=0;k<4;k++)
[0611] bandTable[(k+saoLeftClass)&31]=k+1 (8 940)
[0612] 4. The variable bandIdx is set equal to bandTable[recPicture[xSi][ySj]>>bandShift].
[0613] 5. The modified picture sample array saoPicture[xSi][ySj] is derived as follows:
[0614] saoPicture[xSi][ySj]=Clip3(0, (1< <bitDepth)-1,recPicture[xSi][ySj]+
[0615] SaoOffsetVal[cIdx][rx][ry][bandIdx]) (8 941)
[0616] Table 8-19 – Specification of hPos and vPos according to sample point adaptive offset classification
[0617]
[0618] When the size of the sub-block is small, the sub-block based prediction techniques discussed above can be used to obtain more accurate motion information for each sub-block. However, smaller sub-blocks result in higher bandwidth requirements in motion compensation. On the other hand, the motion information derived for smaller sub-blocks may not be accurate, especially when there is some noise in the block. Therefore, having a fixed sub-block size within a block may be suboptimal.
[0619] This document describes techniques that can be used in various embodiments to use non-uniform and / or variable sub-block sizes to address the bandwidth and accuracy issues introduced by fixed sub-block sizes. These techniques (also known as interlaced prediction) use different ways of subdividing blocks so that motion information can be obtained more robustly without increasing bandwidth consumption.
[0620] Using the interlaced prediction technique, the block is subdivided into sub-blocks in one or more subdivision patterns. The subdivision pattern represents the way in which the block is subdivided into sub-blocks, including the size of the sub-blocks and the position of the sub-blocks. For each subdivision pattern, the corresponding prediction block can be generated by deriving the motion information of each sub-block based on the subdivision pattern. Therefore, in some embodiments, even for one prediction direction, multiple prediction blocks can be generated by multiple subdivision patterns. In some embodiments, for each prediction direction, only one subdivision pattern can be applied.
[0621] Fig.13 An example of interleaved prediction with two subdivision patterns according to the techniques of the present disclosure is shown. The current block 1300 can be subdivided into multiple patterns. For example, Fig.13 As shown, the current block is subdivided into both pattern 0 (1301) and pattern 1 (1302). Two prediction blocks P0 (1303) and P1 (1304) are generated. The final prediction block P (1305) of the current block 1300 can be generated by calculating the weighted sum of P0 (1303) and P1 (1304).
[0622] More generally, given X subdivision patterns, X prediction blocks of the current block can be generated by sub-block based prediction with X subdivision patterns, denoted as P0, P1, ..., P X-1 The final prediction of the current block denoted as P can be generated as
[0623]
[0624] Here, (x, y) are the coordinates of the pixel in the block, and w i (x, y) is P i As an example and not by way of limitation, the weight may be expressed as:
[0625]
[0626] N is a non-negative value. Alternatively, the bit shift operation in equation (16) can also be expressed as:
[0627]
[0628] The sum of the weights as a power of 2 allows the weighted sum P to be computed more efficiently by performing bit shift operations instead of floating point divisions.
[0629] In the following, various implementations are presented as separate chapters and items. Different chapters and items are used in this document only to facilitate understanding, and the scope of the embodiments and techniques described in each chapter / item is not limited to the chapter / item.
[0630] Use of interleaved prediction for different codecs
[0631] Item 1: Note that the interleaved prediction techniques disclosed herein can be applied to one, some, or all codec techniques based on sub-block prediction. For example, the interleaved prediction techniques can be applied to affine prediction, while other codec techniques based on sub-block prediction (e.g., ATMVP, STMVP, FRUC, or BIO) do not use interleaved prediction. As another example, affine, ATMVP, and STMVP are all applicable to the interleaved prediction techniques disclosed herein.
[0632] Definition of subdivision style
[0633] Item 2: The subdivision pattern may have different shapes, sizes or positions of sub-blocks. In some embodiments, the subdivision pattern may include irregular sub-block sizes. Figures 14A-14G Several examples of subdivision patterns for 16×16 blocks are shown. Fig.14A In , the blocks are subdivided into 4×4 sub-blocks according to the disclosed technique. This pattern is also used in JEM. Fig. 14B An example of subdividing a block into 8×8 sub-blocks according to the techniques of this disclosure is shown. Fig. 14C An example of subdividing a block into 8×4 sub-blocks according to the disclosed technique is shown. Fig.14D An example of subdividing a block into 4×8 sub-blocks according to the techniques of this disclosure is shown. Fig.14E In the embodiment of the present disclosure, a portion of a block is subdivided into 4×4 sub-blocks according to the techniques of the present disclosure. Pixels at the block boundary are subdivided into smaller sub-blocks having sizes such as 2×4, 4×2, or 2×2. Some sub-blocks may be merged to form larger sub-blocks. Fig.14F Examples of adjacent sub-blocks are shown, such as a 4×4 sub-block and a 2×4 sub-block, which are merged to form a larger sub-block having a size such as 6×4, 4×6, or 6×6. Figure 14GIn , a portion of a block is subdivided into 8×8 sub-blocks. Pixels at the block boundary are subdivided into smaller sub-blocks, which have sizes such as 8×4, 4×8 or 4×4.
[0634] Item 3: The shape and size of the sub-block in the sub-block based prediction can be determined based on the shape and / or size of the codec block and / or the codec block information. For example, in some embodiments, when the current block has a size of M×N, the sub-block has a size of 4×N (or 8×N, etc.). That is, the sub-block has the same height as the current block. In some embodiments, when the current block has a size of M×N, the sub-block has a size of M×4 (or M×8, etc.). That is, the sub-block has the same width as the current block. In some embodiments, when the current block has a size of M×N (where M>N), the sub-block has a size of A×B, where A>B (for example, 8×4). Alternatively, the sub-block may have a size of B×A (for example, 4×8). In some embodiments, the current block has a size of M×N. When M×N<=T (or Min(M,N)<=T, or Max(M,N)<=T, etc.), the sub-block has a size of A×B, and when M×N>T (or Min(M,N)>T, or Max(M,N)>T, etc.), the sub-block has a size of C×D, where A<=C and B<=D. For example, if M×N<=256, the sub-block may be a size of 4×4. In some implementations, the sub-block has a size of 8×8.
[0635] Enable / disable interlaced prediction and interlaced prediction encoding and decoding process
[0636] Item 4: In some embodiments, whether to apply interlaced prediction may be determined based on the inter-frame prediction direction. For example, in some embodiments, interlaced prediction may be applied to bidirectional prediction but not to unidirectional prediction. As another example, when multiple hypotheses are applied, interlaced prediction may be applied to one prediction direction when there is more than one reference block.
[0637] Item 5: In some embodiments, how to apply interlaced prediction can also be determined based on the inter-frame prediction direction. In some embodiments, a bidirectional prediction block with sub-block based prediction is subdivided into sub-blocks in two different subdivision styles for two different reference lists. For example, when predicting from reference list 0 (L0), the bidirectional prediction block is subdivided into 4×8 sub-blocks, such as Fig.14D When predicting from reference list 1 (L1), the same block is subdivided into 8×4 sub-blocks, as shown in Fig. 14C The final prediction P is calculated as
[0638]
[0639] Here, P 0 and P 1They are the predictions from L0 and L1 respectively. w 0 and w 1 are the weight values of L0 and L1 respectively. As shown in Equation (16), the weight values can be determined as: w 0 (x,y) + w 1 (x,y) = 1 << N (where N is a non - negative integer value). Since there are fewer sub - blocks used for prediction in each direction (e.g., a 4×8 sub - block compared to an 8×8 sub - block), less bandwidth is required for computation compared to existing sub - block - based methods. By using larger sub - blocks, the prediction results are also less susceptible to the influence of noise.
[0640] In some embodiments, a unidirectional prediction block with sub - block - based prediction is divided into sub - blocks in two or more different subdivision styles for the same reference list. For example, the prediction P L of list L (L = 0 or 1) is calculated as
[0641]
[0642] where XL is the number of subdivision styles of list L. is generated by prediction with the i - th subdivision style, and is the weight value of. For example, when XL is 2, two subdivision styles are applied to list L. In the first subdivision style, the block is divided into 4×8 sub - blocks, as Fig.14D shown. In the second subdivision style, the block is divided into 8×4 sub - blocks as Fig.14D shown.
[0643] In one embodiment, a bidirectional prediction block with sub - block - based prediction is considered as a combination of two unidirectional prediction blocks from L0 and L1 respectively. The predictions from each list can be derived as described in the above example. The final prediction P can be calculated as
[0644]
[0645] where the parameters a and b are two additional weights applied to the two internal prediction blocks. In this specific example, a and b can both be set to 1. Similar to the above example, since fewer sub - blocks are used for prediction in each direction (e.g., a 4×8 sub - block compared to an 8×8 sub - block), the bandwidth usage is better or at the same level as existing sub - block - based methods. At the same time, the prediction results can be improved by using larger sub - blocks.
[0646] In some embodiments, a single non - uniform style can be used in each unidirectional prediction block. For example, for each list L (e.g., L0 or L1), the block is divided into different styles (e.g., as Fig.14E or Fig.14FUsing fewer sub-blocks reduces the bandwidth requirement. The non-uniformity of the sub-blocks also increases the robustness of the prediction results.
[0647] In some embodiments, for a multi-hypothesis codec block, for each prediction direction (or reference picture list), there may be more than one prediction block generated by different subdivision styles. Multiple prediction blocks may be used to generate a final prediction with additional weights applied. For example, the additional weight may be set to 1 / M, where M is the total number of prediction blocks generated.
[0648] Item 6: In some embodiments, the encoder may determine whether and how to apply interlaced prediction. The encoder may then send information corresponding to the determination to the decoder at a sequence level, a picture level, a view level, a slice level, a codec tree unit (CTU) (also referred to as a maximum codec unit (LCU)) level, a CU level, a PU level, a tree unit (TU) level, a slice level, a slice group level, or a region level (which may contain multiple CU / PU / Tu / LCU). The information may be signaled in a sequence parameter set (SPS), a view parameter set (VPS), a picture parameter set (PPS), a slice header (SH), a picture header, a sequence header, or the first block at a slice level or a slice group level, a CTU / LCU, a CU, a PU, a TU, or a region.
[0649] In some implementations, interlaced prediction is applicable to existing sub-block methods, such as affine prediction, ATMVP, STMVP, FRUC or BIO. In this case, no additional signaling cost is required. In some implementations, the new sub-block Merge candidate generated by interlaced prediction can be inserted into the Merge list, for example, interlaced prediction + ATMVP, interlaced prediction + STMVP, interlaced prediction + FRUC, etc. In some implementations, a signaling flag can be signaled to indicate whether interlaced prediction is used. In one example, if the current block is affine inter-frame coded, a signaling flag is signaled to indicate whether interlaced prediction is used. In some implementations, if the current block is affine Merge coded and unidirectional prediction is applied, a signaling flag can be signaled to indicate whether interlaced prediction is used. In some implementations, if the current block is affine Merge coded, a signaling flag can be signaled to indicate whether interlaced prediction is used. In some implementations, if the current block is affine Merge coded and unidirectional prediction is applied, interlaced prediction can always be used. In some implementations, if the current block is affine Merge coded, interlaced prediction may always be used.
[0650] In some implementations, a flag indicating whether interleaved prediction is used may be inherited without being signaled. Some examples include:
[0651] (i) In one example, if the current block is affine merge encoded, inheritance can be used.
[0652] (ii) In one example, the signature may be inherited from the signature of a neighboring block that inherits the affine model.
[0653] (iii) In one example, the flag is inherited from a predetermined neighboring block, such as a left or above neighboring block.
[0654] (iv) In one example, the flag may be inherited from the first encountered neighboring block of the affine codec.
[0655] (v) In one example, if no neighboring blocks are affine coded, then this flag may be inferred to be zero.
[0656] (vi) In one example, this flag may be inherited only when the current block applies unidirectional prediction.
[0657] (vii) In one example, this flag can be inherited only when the current block and its inherited neighboring block are in the same CTU.
[0658] (viii) In one example, this flag can be inherited only when the current block and its inherited neighboring block are in the same CTU row.
[0659] (ix) In one example, when deriving an affine model from temporal neighboring blocks, the flag may not be inherited from the flag of the neighboring blocks.
[0660] (x) In one example, a flag may not be inherited from a flag of a neighboring block that is not located in the same LCU or LCU row or video data processing unit (such as 64×64 or 128×128).
[0661] (xi) In one example, how the flag is signaled and / or derived may depend on the block size and / or codec information of the current block.
[0662] In some implementations, if the reference picture is the current picture, interlaced prediction is not applied. For example, if the reference picture is the current picture, a flag indicating whether interlaced prediction is used is not signaled.
[0663] In some embodiments, the subdivision pattern to be used by the current block can be derived based on information from spatial and / or temporal neighboring blocks. For example, instead of relying on the encoder to signal relevant information, both the encoder and the decoder can adopt a set of predetermined rules to obtain the subdivision pattern based on temporal adjacency (e.g., the subdivision pattern of the same block previously used) or spatial adjacency (e.g., the subdivision pattern used by the neighboring block).
[0664] Weight value
[0665] Item 7: In some embodiments, the weight value w can be fixed. For example, all subdivision styles can be weighted equally: w i (x, y)=1.
[0666] Item 8: In some embodiments, the weight value can be determined based on the location of the block and the subdivision style used. For example, for different (x, y), w i (x, y) may be different. In some embodiments, the weight value may also depend on the sub-block prediction based coding technique (eg, affine or ATMVP) and / or other coding information (eg, skip or non-skip mode, and / or MV information).
[0667] Item 9: In some embodiments, the encoder may determine a weight value and send the value to the decoder at a sequence level, a picture level, a slice level, a CTU / LCU level, a CU level, a PU level, or a region level (which may include multiple CU / PU / Tu / LCU). The weight value may be signaled in a sequence parameter set (SPS), a picture parameter set (PPS), a slice header (SH), a CTU / LCU, a CU, a PU, or the first block of a region. In some embodiments, the weight value may be derived from the weight values of spatial and / or temporal neighboring blocks.
[0668] Partial interleaving prediction
[0669] Item 10: In some embodiments, partial interleaved prediction may be implemented as follows.
[0670] In some embodiments, interlaced prediction is applied to a portion of the current block. Prediction samples at some locations are calculated as a weighted sum of two or more sub-block-based predictions. Prediction samples at other locations are not used for the weighted sum. For example, these prediction samples are copied from sub-block-based predictions with a specific subdivision pattern.
[0671] In some embodiments, the current block is predicted by sub-block based predictions P1 and P2 with subdivision patterns D0 and D1, respectively. The final prediction is calculated as P = w0×P0+w1×P1. At some positions, w0≠0 and w1≠0. But at some other positions, w0=1 and w1=0, i.e., interlaced prediction is not applied at these positions.
[0672] In some embodiments, interlaced prediction is not applied to the four corner sub-blocks, such as Fig.15A shown.
[0673] In some embodiments, interlaced prediction is not applied to the leftmost column of the sub-block and the rightmost column of the sub-block, such as Fig. 15B as shown in .
[0674] In some embodiments, interlaced prediction is not applied to the topmost row of a sub-block and the bottommost row of a sub-block, such as Fig. 15C shown.
[0675] In some embodiments, interlaced prediction is not applied to the topmost row of rows of sub-blocks, the bottommost row, the leftmost column of sub-blocks, and the rightmost column of sub-blocks, such as Fig.15D as shown in .
[0676] In some embodiments, whether and how to apply partial interlaced prediction may depend on the size / shape of the current block.
[0677] For example, in some embodiments, if the size of the current block satisfies certain conditions, interlaced prediction is applied to the entire block; otherwise, interlaced prediction is applied to a portion (or some portions) of the block. The conditions include but are not limited to: (assuming that the width and height of the current block are W and H, respectively, and T, T1, T2 are integer values):
[0678] W>=T1 and H>=T2;
[0679] W<=T1 and H<=T2;
[0680] W>=T1 or H>=T2;
[0681] W<=T1 or H<=T2;
[0682] W+H>=T
[0683] W+H<=T
[0684] W×H>=T
[0685] W×H<=T
[0686] In some embodiments, partial interlaced prediction is applied to a portion of the current block that is smaller than the current block. For example, in some embodiments, the portion of the block excludes sub-blocks as follows. In some embodiments, if W ≥ H, then interlaced prediction is not applied as follows Fig. 15B The leftmost column of the sub-block and the rightmost column of the sub-block shown; otherwise, interleaved prediction is not applied as shown in Fig. 15C The top-most row of sub-blocks and the bottom-most row of sub-blocks are shown.
[0687] For example, in some embodiments, if W>H, then interleaved prediction is not applied. Fig. 15B The leftmost column of the sub-block and the rightmost column of the sub-block shown; otherwise, interleaved prediction is not applied as shown in Fig. 15C The top-most row of sub-blocks and the bottom-most row of sub-blocks are shown.
[0688] In some embodiments, for different regions in a block, whether to apply and how to apply interleaved prediction can be different. For example, assume that the current block is predicted by sub-block based predictions P1 and P2 with subdivision patterns D0 and D1 respectively. The final prediction is calculated as P(x, y) = w0 × P0(x, y) + w1 × P1(x, y). If the position (x, y) belongs to a sub-block of size S0×H0 with subdivision style D0; and belongs to a sub-block S1×H1 with subdivision style D1, if one or more of the following conditions are met, then set w0 = 1 and w1 = 0 (for example, interleaved prediction is not applied at this position):
[0689] S1 < T1;
[0690] H1 < T2;
[0691] S1 < T1 and H1 < T2; or
[0692] S1 < T1 or H1 < T2,
[0693] In this article, T1 and T2 are integers. For example, T1 = T2 = 4.
[0694] Examples of Techniques Integrated with Encoder Embodiments
[0695] Item 11: In some embodiments, interleaved prediction is not applied during the motion estimation (ME) process.
[0696] For example, interleaved prediction is not applied during the ME process for 6-parameter affine prediction.
[0697] For example, if the size of the current block meets certain conditions such as the following, then interleaved prediction is not applied during the ME process. Here, assume that the width and height of the current block are W and H respectively, and T, T1, T2 are integer values:
[0698] W >= T1 and H >= T2;
[0699] W <= T1 and H <= T2;
[0700] W >= T1 or H >= T2;
[0701] W <= T1 or H <= T2;
[0702] W + H >= T
[0703] W + H <= T
[0704] W × H >= T
[0705] W × H <= T
[0706] For example, if the current block is split from the parent block, and the parent block does not select the affine mode at the encoder, interlaced prediction is omitted in the ME process.
[0707] Alternatively, if the current block is split from the parent block, and the parent block does not select the affine mode at the encoder, the affine mode is not checked at the encoder.
[0708] Example embodiment of MV export
[0709] In the following example, SatShift(x,n) is defined as
[0710]
[0711] Shift(x, n) is defined as Shift(x, n) = (x + shift0) >> n. In one example, shift0 and / or shift1 are set to (1 <<n)> >1 or (1<<(n-1)). In another example, shift0 and / or shift1 are set to 0.
[0712] Item 12: In some embodiments, the MV of each sub-block in one subdivision pattern may be derived directly from an affine model (such as using equation (1)), or it may be derived from the MV of a sub-block within another subdivision pattern.
[0713] (a) In one example, the MV of sub-block B with subdivision pattern 0 may be derived from the MVs of some or all of the sub-blocks within subdivision pattern 1 that overlap with sub-block B.
[0714] (b) Figures 16A-16C Some examples are shown. Fig.16A In the example, the MV of a specific sub-block in subdivision style 1 will be exported. 1 (x,y). Fig. 16B Subdivision pattern 0 (solid line) and subdivision pattern 1 (dashed line) in a block are shown, indicating that there are four sub-blocks within subdivision pattern 0 that overlap with certain sub-blocks within subdivision pattern 1. Fig. 16C Four MVs are shown: MVs of four sub-blocks in subdivision pattern 0 that overlap with a particular sub-block in subdivision pattern 1 0 (x-2,y-2) , MV 0 (x+2,y-2) , MV 0 (x-2,y+2) And MV 0 (x+2,y+2) Then the MV 1 (x,y) From the MV 0 (x-2,y-2) , MV 0 (x+2,y-2) , MV0 (x-2,y+2) and MV 0 (x+2,y+2) Export.
[0715] (c) Assume that the MV' of a sub-block in subdivision pattern 1 is obtained from k in subdivision pattern 0. + MV0, MV1 of a sub-block 1 , MV2, …MVk. MV' can be derived as:
[0716] (i) MV' = MVn, where n is any number from 0 to k.
[0717] (ii)MV' = f(MV0, MV 1 , MV2,…,MVk). f is a linear function.
[0718] (iii)MV' = f(MV0, MV 1 , MV2,…,MVk). f is a nonlinear function.
[0719] (iv)MV' = Average(MV0, MV 1 , MV2, …, MVk). Average is an averaging operation.
[0720] (v)MV' = Median(MV0, MV 1 , MV2, …, MVk). Median is an operation to obtain the median value.
[0721] (vi)MV'=Max(MV0,MV 1 , MV2, …, MVk). Max is the operation to obtain the maximum value.
[0722] (vii)MV′=Min(MV0,MV 1 , MV2, …, MVk). Min is the operation to obtain the minimum value.
[0723] (viii) MV′=MaxAbs(MV0,MV 1 , MV2, …, MVk). MaxAbs is the operation that obtains the value with the largest absolute value.
[0724] (ix) MV′=MinAbs(MV0,MV 1 , MV2, …, MVk). MinAbs is the operation that obtains the value with the smallest absolute value.
[0725] (x) Fig.16A As an example, MV 1 (x,y) Can be exported as:
[0726] 1.MV 1 (x,y) =SatShift(MV0(x-2,y-2)+MV0(x+2,y-2)+MV0(x-2,y+2)+MV0(x+2,y+2),2);
[0727] 2.MV 1 (x,y) =Shift(MV0(x-2,y-2)+MV0(x+2,y-2)+MV0(x-2,y+2)+MV0(x+2,y+2),2);
[0728] 3.MV 1 (x,y) =SatShift(MV0(x-2,y-2)+MV0(x+2,y-2),1);
[0729] 4.MV 1 (x,y) =Shift(MV0(x-2,y-2)+MV0(x+2,y-2),1);
[0730] 5.MV 1 (x,y) =SatShift(MV0(x-2,y+2)+MV0(x+2,y+2),1);
[0731] 6.MV 1 (x,y) =Shift(MV0(x-2,y+2)+MV0(x+2,y+2),1);
[0732] 7.MV 1 (x,y) =SatShift(MV0(x-2,y-2)+MV0(x+2,y+2),1);
[0733] 8.MV 1 (x,y) =Shift(MV0(x-2,y-2)+MV0(x+2,y+2),1);
[0734] 9.MV 1 (x,y) =SatShift(MV0(x-2,y-2)+MV0(x-2,y+2),1);
[0735] 10.MV 1 (x,y) =Shift(MV0(x-2,y-2)+MV0(x-2,y+2),1);
[0736] 11.MV 1 (x,y) =SatShift(MV0(x+2,y-2)+MV0(x+2,y+2),1);
[0737] 12.MV 1 (x,y) =Shift(MV0(x+2,y-2)+MV0(x+2,y+2),1);
[0738] 13.MV 1 (x,y) =SatShift(MV0(x+2,y-2)+MV0(x-2,y+2),1);
[0739] 14.MV 1 (x,y) =Shift(MV0(x+2,y-2)+MV0(x-2,y+2),1);
[0740] 15.MV 1 (x,y) =MV 0 (x-2,y-2) ;
[0741] 16.MV 1 (x,y) =MV 0 (x+2,y-2) ;
[0742] 17.MV 1 (x,y) =MV 0 (x-2,y+2) ;or
[0743] 18.MV 1 (x,y) =MV 0 (x+2,y+2) .
[0744] Item 13: In some embodiments, how to select the subdivision style may depend on the width and height of the current block.
[0745] (a) For example, if width>T1 and height>T2 (eg, T1=T2=4), two subdivision styles are selected. Fig.17A Examples of two subdivision styles are shown.
[0746] (b) For example, if height <= T2 (eg, T2=4), two other subdivision styles are selected. Fig. 17B Examples of two subdivision styles are shown.
[0747] (c) For example, if width<=T1 (eg, T1=4), two more subdivision styles are selected. Fig. 17C Examples of two subdivision styles are shown.
[0748] Item 14: In some embodiments, the MV of each sub-block within one subdivision pattern for one color component C1 may be derived from the MV of a sub-block within another subdivision pattern for another color component C0.
[0749] (a) For example, C1 refers to a color component that is encoded / decoded after another color component, such as Cb or Cr or U or V or R or B.
[0750] (b) For example, C0 refers to a color component that is encoded / decoded before another color component, such as Y or G.
[0751] (c) In one example, how the MV of a sub-block within one subdivision pattern of one color component is derived from the MV of a sub-block within another subdivision pattern of another color component may depend on the color format, such as 4:2:0, or 4:2:2, or 4:4:4.
[0752] (d) In one example, after reducing or enlarging the coordinates according to the color format, the MV of a sub-block B in a color component C1 having a subdivision pattern C1Pt (t=0 or 1) may be derived from the MVs of some or all of the sub-blocks in a color component C0 having a subdivision pattern C0Pr (r=0 or 1) that overlap with sub-block B.
[0753] (i) In one example, C0Pr is always equal to C0P0.
[0754] (e) Fig.18A and 18B Two examples are shown. The color format is 4:2:0. The MV of the sub-block in the Cb component is derived from the MV of the sub-block in the Y component.
[0755] (i) in Fig.18A On the left, the MV of a specific Cb sub-block B in subdivision style 0 is to be exported Cb0 (x’,y’) . Fig.18A The right side shows the four Y sub-blocks in subdivision pattern 0, which overlap with Cb sub-block B when reduced by 2:1. Assuming x=2*x' and y=2*y', the four MVs of the four Y sub-blocks in subdivision pattern 0 are: MV 0 (x-2,y-2) , MV 0 (x+2,y-2) , MV 0 (x-2,y+2) and MV 0 (x+2,y+2) Used to export MV Cb0(x’,y’) .
[0756] (ii) Fig.18B Left, MV of a specific Cb sub-block B in subdivision pattern 1 Cb0 (x’,y’) to be exported. Fig.18B The right side shows the four Y sub-blocks in subdivision pattern 0, which overlap with Cb sub-block B when 2:1 reduction is performed. Assuming x=2*x' and y=2*y', the four MVs of the four Y sub-blocks in subdivision pattern 0 are: MV 0 (x-2,y-2) , MV 0 (x+2,y-2) , MV 0 (x-2,y+2) and MV 0 (x+2,y+2) For exporting MV Cb0 (x’,y’) .
[0757] (f) Assume that the MV' of a sub-block of color component C1 is derived from MV0 of the k-1 sub-block of color component C0, MV 1 , MV2, …MVk are derived. MV' can be derived as:
[0758] (i) MV' = MVn, where n is any number from 0 to k.
[0759] (ii)MV' = f(MV0, MV 1 , MV2,…,MVk). f is a linear function.
[0760] (iii)MV' = f(MV0, MV 1 , MV2,…,MVk). f is a nonlinear function.
[0761] (iv)MV' = Average(MV0, MV 1 , MV2, …, MVk). Average is an averaging operation.
[0762] (v)MV' = Median(MV0, MV 1 , MV2, …, MVk). Median is an operation to obtain the median value.
[0763] (vi)MV'=Max(MV0,MV 1 , MV2, …, MVk). Max is the operation to obtain the maximum value.
[0764] (vii)MV′=Min(MV0,MV 1 , MV2, …, MVk). Min is the operation to obtain the minimum value.
[0765] (viii) MV′=MaxAbs(MV0,MV 1 , MV2, …, MVk). MaxAbs is the operation that obtains the value with the largest absolute value.
[0766] (ix) MV′=MinAbs(MV0,MV 1 , MV2, …, MVk). MinAbs is the operation that obtains the value with the smallest absolute value.
[0767] (x) Fig.18A and Fig.18B As an example, MV Cbt (x’,y’) , where t = 0 or 1, can be derived as:
[0768] 1. MV Cbt (x’,y’) =SatShift(MV0(x-2,y-2)+MV0(x+2,y-2)+MV0(x-2,y+2)+MV0(x+2,y+2),2);
[0769] 2. MV Cbt (x’,y’) =Shift(MV0(x-2,y-2)+MV0(x+2,y-2)+MV0(x-2,y+2)+MV0(x+2,y+2),2);
[0770] 3. MV Cbt (x’,y’) =SatShift(MV0(x-2,y-2)+MV0(x+2,y-2),1);
[0771] 4. MV Cbt (x’,y’) =Shift(MV0(x-2,y-2)+MV0(x+2,y-2),1);
[0772] 5. MV Cbt (x’,y’) =SatShift(MV0(x-2,y+2)+MV0(x+2,y+2),1);
[0773] 6. MV Cbt (x’,y’) =Shift(MV0(x-2,y+2)+MV0(x+2,y+2),1);
[0774] 7. MV Cbt (x’,y’) =SatShift(MV0(x-2,y-2)+MV0(x+2,y+2),1);
[0775] 8.MV Cbt (x’,y’) =Shift(MV0(x-2,y-2)+MV0(x+2,y+2),1);
[0776] 9.MV Cbt (x’,y’) =SatShift(MV0(x-2,y-2)+MV0(x-2,y+2),1);
[0777] 10.MV Cbt (x’,y’) =Shift(MV0(x-2,y-2)+MV0(x-2,y+2),1);
[0778] 11.MV Cbt (x’,y’) =SatShift(MV0(x+2,y-2)+MV0(x+2,y+2),1);
[0779] 12.MV Cbt (x’,y’) =Shift(MV0(x+2,y-2)+MV0(x+2,y+2),1);
[0780] 13.MV Cbt (x’,y’) =SatShift(MV0(x+2,y-2)+MV0(x-2,y+2),1);
[0781] 14.MV Cbt (x’,y’) =Shift(MV0(x+2,y-2)+MV0(x-2,y+2),1);
[0782] 15.MV Cbt (x’,y’) =MV 0 (x-2,y-2) ;
[0783] 16.MV Cbt (x’,y’) =MV 0 (x+2,y-2) ;
[0784] 17.MV Cbt (x’,y’) =MV 0 (x-2,y+2) ;
[0785] 18.MV Cbt (x’,y’) =MV 0 (x+2,y+2) ;
[0786] Example embodiment of interleaved prediction for bi-directional prediction
[0787] Item 15: In some embodiments, when interleaved prediction is applied on bidirectional prediction, the following method may be applied to save the increase in internal bit depth due to different weights:
[0788] (a) For a list X (X = 0 or 1), P X (x, y) = Shift(W0(x, y)*P X 0(x,y)+W1(x,y)*P X 1(x,y),SW), where P X (x, y) is the prediction of list X, P X 0(x,y) and P X 1(x,y) are the predictions of list X in subdivision style 0 and subdivision style 1, respectively. W0 and W1 are integers representing interleaved prediction weight values, and SW represents the precision of the weight values.
[0789] (b) The final prediction value is derived as P(x,y)=Shift(Wb0(x,y)*P 0 (x,y)+Wb1(x,y)*P 1 (x, y), SWB), where Wb0 and Wb1 are integers used in weighted bidirectional prediction, and SWB is the precision. When there is no weighted bidirectional prediction, Wb0=Wb1=SWB=1.
[0790] (c) In some embodiments, P X 0(x,y) and P X 1(x,y) can be kept as the accuracy of the interpolation filter. For example, they can be unsigned integers with 16 bits. The final prediction value is derived as P(x,y)=Shift(Wb0(x,y)*P 0 (x,y)+Wb1(x,y)*P 1 (x, y), S W B + PB), where PB is the additional precision from the interpolation filter, for example, PB = 6. In this case, W0 (x, y) * P X 0(x,y) or W1(x,y)*P X 1(x,y) may exceed 16 bits. It is proposed to change P X 0(x,y) and P X 1(x,y) is first right-shifted to a lower precision to avoid exceeding 16 bits.
[0791] (i) For example, for a list X (X = 0 or 1), P X (x, y) = Shift(W0(x, y)*PLX 0(x,y)+W1(x,y)*PL X 1(x,y),SW), where PL X 0(x,y)=Shift(P X 0(x,y),M),PL X 1(x,y)=Shift(P X 1(x,y),M). And the final prediction is derived as P(x,y)=Shift(Wb0(x,y)*P 0 (x,y)+Wb1(x,y)*P 1 (x, y), SWB+PB-M). For example, M is set to 2 or 3.
[0792] (d) The above method can also be applied to other bidirectional prediction methods with different weighting factors for two reference prediction blocks, such as generalized bi-prediction (GBi, where the weights can be, for example, 3 / 8, 5 / 8), weighted prediction (where the weights can be very large values).
[0793] (e) The above method can also be applied to other multi-hypothesis unidirectional prediction or bidirectional prediction methods with different weight factors for different reference prediction blocks.
[0794] Example Embodiments of Block Size Dependency
[0795] Item 16: Whether and / or how to apply interlaced prediction may depend on the block width W and height H.
[0796] a. In one example, whether and / or how to apply interleaved prediction may depend on the size of the VPDU (Video Processing Data Unit, which typically represents the maximum allowed block size processed in a hardware design).
[0797] b. In one example, when interleaved prediction is disabled for a specific block size (or a block with specific codec information), the original prediction method may be employed.
[0798] i. Alternatively, affine mode can be simply disabled for such blocks.
[0799] c. In one example, when W>T1 and H>T2, interleaved prediction cannot be used.
[0800] For example, T1=T2=64;
[0801] d. In one example, when W>T1 or H>T2, interleaved prediction cannot be used.
[0802] For example, T1=T2=64;
[0803] e. In one example, when W*H > T, interlaced prediction cannot be used. For example, T = 64*64;
[0804] f. In one example, when W < T1 and H < T2, interlaced prediction cannot be used.
[0805] For example, T1 = T2 = 16;
[0806] g. In one example, when W < T1 or H > T2, interlaced prediction cannot be used.
[0807] For example, T1 = T2 = 16;
[0808] h. In one example, when W*H < T, interlaced prediction cannot be used. For example, T = 16*16;
[0809] i. In one example, for a sub-block (e.g., a coding / decoding unit) not located at a block boundary, interlaced affine can be disabled for this sub-block. Alternatively, in addition, the prediction result using the original affine prediction method can be directly used as the final prediction for this sub-block.
[0810] j. In one example, when W > T1 and H > T2, interlaced prediction is used in a different way. For example, T1 = T2 = 64;
[0811] k. In one example, when W > T1 or H > T2, interlaced prediction is used in a different way. For example, T1 = T2 = 64;
[0812] l. In one example, when W*H > T, interlaced prediction is used in a different way. For example, T = 64*64;
[0813] m. In one example, when W < T1 and H < T2, interlaced prediction is used in a different way. For example, T1 = T2 = 16;
[0814] n. In one example, when W < T1 or H > T2, interlaced prediction is used in a different way. For example, T1 = T2 = 16;
[0815] o. In one example, when W*H < T, interlaced prediction is used in a different way. For example, T = 16*16;
[0816] p. In one example, when H > X (e.g., H equals 128, X = 64), interlaced prediction is not applied to the samples of the sub-blocks belonging to the upper W*(H / 2) partition and the lower W*(H / 2) partition across the current block;
[0817] q. In one example, when W>X (e.g., W is equal to 128, X=64), interlaced prediction is not applied to samples belonging to sub-blocks across the left (W / 2)*H partition and the right (W / 2)*H partition of the current block;
[0818] r. In one example, when W>X and H>Y (e.g., W=H=128, X=Y=64),
[0819] i. Interlaced prediction is not applied to samples belonging to sub-blocks across the left (W / 2)*H partition and the right (W / 2)*H partition of the current block;
[0820] ii. Interlaced prediction is not applied to samples belonging to sub-blocks across the upper W*(H / 2) partition and the lower W*(H / 2) partition of the current block;
[0821] s. In one example, interlaced prediction is enabled only for blocks with a specific set of widths and / or heights.
[0822] t. In one example, interlaced prediction is disabled only for blocks with a specific set of widths and / or heights.
[0823] u. In one example, interlaced prediction is only used for certain types of pictures / slices / slice groups / slices / or other types of video data units.
[0824] i. For example, interlaced prediction is only used for P pictures or B pictures;
[0825] ii. For example, a flag is signaled in the header of a picture / slice / slice group / slice to indicate whether interlaced prediction can be used.
[0826] l. For example, this flag is signaled only if affine prediction is allowed.
[0827] Item 17: Propose a signaling message to indicate whether / how to apply the functional interleaved prediction and the dependency between width and height. This message can be signaled in SPS / VPS / PPS / slice header / picture header / slice / slice group header / CTU / CTU row / multiple CTUs / or other types of video processing units.
[0828] Item 18: In one example, when interleaved prediction is used, bi-directional prediction is not allowed.
[0829] a. For example, when interleaved prediction is used, an index indicating whether bidirectional prediction is used is not signaled.
[0830] b. Alternatively, the indication of whether bidirectional prediction is not allowed may be signaled in SPS / VPS / PPS / slice header / picture header / slice / slice group header / CTU / CTU row / multiple CTUs.
[0831] Item 19: It is proposed to further refine the motion information of a sub-block based on motion information derived from two or more patterns.
[0832] a. In one example, the refined motion information can be used to predict the following block to be encoded.
[0833] b. In one example, refined motion information can be employed in filtering processes such as deblocking, SAO, ALF.
[0834] c. Whether to store refined information may be based on the position of the sub-block relative to the entire block / CTU / CTU row / slice / slice band / slice group / picture.
[0835] d. Whether to store the refined information may be based on the coding mode of the current block and / or the neighboring blocks.
[0836] e. Whether to store refined information can be based on the size of the current block.
[0837] f. Whether to store refined information can be based on picture / slice type / reference picture list, etc.
[0838] Item 20: It is proposed that whether and / or how a deblocking process or other kind of filtering process (such as SAO, adaptive loop filtering) is applied may depend on whether interlaced prediction is applied.
[0839] a. In one example, no deblocking is performed on an edge between two sub-blocks in one subdivision pattern of a block if the edge is within a sub-block in another subdivision pattern of the block.
[0840] b. In one example, deblocking is weakened on an edge between two sub-blocks in one sub-division pattern of a block if the edge is within a sub-block in another sub-division pattern of the block.
[0841] i. In one example, bS[xDi][yDj] described in the VVC deblocking process is reduced for such edges.
[0842] ii. In one example, the β described in the VVC deblocking process is reduced for such edges.
[0843] iii. In one example, such edges are reduced as described in the VVC deblocking process.
[0844] iv. In one example, tC described in the VVC deblocking process is reduced for such edges.
[0845] c. In one example, deblocking is enforced on an edge between two sub-blocks in one subdivision pattern of a block if the edge is within a sub-block in another subdivision pattern of the block.
[0846] i. In one example, bS[xDi][yDj] described in the VVC deblocking process is improved for such edges.
[0847] ii. In one example, the β described in the VVC deblocking process is increased for such edges.
[0848] iii. In one example, such edges are enhanced as described in the VVC deblocking process.
[0849] iv. In one example, tC described in the VVC deblocking process is increased for such edges.
[0850] Item 21: It is proposed that whether and / or how to apply local illumination compensation or weighted prediction to a block / sub-block may depend on whether interlaced prediction is applied.
[0851] a. In one example, when a block is coded in interlaced prediction mode, it is not allowed local illumination compensation or weighted prediction.
[0852] b. Alternatively, furthermore, if interlaced prediction is applied to a block / sub-block, no signaling is required to enable the indication of local illumination compensation.
[0853] Project 22: Proposes that bidirectional optical flow (BIO) can be skipped when weighted prediction is applied to a block or sub-block.
[0854] a. In one example, BIO can be applied to blocks with weighted prediction.
[0855] b. In one example, BIO can be applied to blocks with weighted prediction, however, certain conditions should be met.
[0856] i. In one example, it is required that at least one parameter should be within a range, or equal to a specific value.
[0857] ii. In one example, certain reference picture restrictions may apply.
[0858] The above embodiments and examples can be implemented in the following Fig.19 to the context of the [] method.
[0859] Fig.19 An exemplary flow chart of a method 1900 for video processing based on some implementations of the disclosed technology is shown. The method 1900 includes, at 1902, deriving one or more motion vectors of a first set of sub-blocks of a first subdivision pattern of a current video block of a video. The method 1900 includes, at 1904, performing conversion between the current video block and a codec representation of the video based on the one or more motion vectors.
[0860] Fig. 20 An exemplary flow chart of a method 2000 for video processing based on some implementations of the disclosed technology is shown. The method 2000 includes, at 2002, subdividing a video block of a first color component to obtain a first set of sub-blocks of the first color component. The method 2000 also includes, at 2004, subdividing a corresponding video block of a second color component to obtain a second set of sub-blocks of the second color component. The method 2000 also includes, at 2006, deriving one or more motion vectors of the first set of sub-blocks based on one or more motion vectors of the second set of sub-blocks. The method 2000 also includes, at 2008, converting between the video block and a coded representation of the video based on the one or more motion vectors of the first set and the second set of sub-blocks.
[0861] Fig.21A An exemplary flow chart of a method 2110 for video processing based on some implementations of the disclosed technology is shown. The method 2110 includes, at 2112, for conversion between a current video block of a video and a bitstream representation of the video, subdividing the current video block into partitions according to a plurality of subdivision patterns according to a height (H) or a width (W) of the current video block. The method 2110 also includes, at 2114, performing the conversion using interlaced prediction of the plurality of partitions.
[0862] Fig.21B An exemplary flow chart of a method 2120 of video processing based on some implementations of the disclosed technology is shown. The method 2120 includes, at 2122, determining to apply a prediction to a current video block of a video, the prediction including subdividing the current video block into sub-blocks according to a subdivision pattern. The method 2120 also includes, at 2124, determining to apply a bit shift to generate a prediction block on the sub-block of the current video block. The method 2120 also includes, at 2126, performing a conversion between the current video block and a codec representation of the video.
[0863] Fig. 21C An exemplary flow chart of a method 2130 for video processing based on some implementations of the disclosed technology is shown. The method 2130 includes, at 2132, determining whether to use an interlaced prediction tool for conversion between a current block and a codec representation of the video based on characteristics of a current video block of the video. The method 2130 also includes, at 2134, performing the conversion based on the determination. In some implementations, upon determining that the current video block does not meet the conditional characteristics, the conversion is performed by disabling the use of an affine prediction tool and / or an interlaced prediction tool. In some implementations, upon determining that the current video block meets the conditional characteristics, the conversion is performed by using an affine prediction tool and / or an interlaced prediction tool.
[0864] Fig.21DAn exemplary flow chart of a method 2140 of video processing based on some implementations of the disclosed technology is shown. The method 2140 includes, at 2142, determining that interlaced prediction is to be applied to a current video block of a video. The method 2140 also includes, at 2144, disabling bidirectional prediction for the current video block based on determining that interlaced prediction is to be applied. The method 2140 also includes, at 2146, converting between the current video block and a codec representation of the video.
[0865] Fig.22A An exemplary flow chart of a method 2210 for video processing based on some implementations of the disclosed technology is shown. The method 2210 includes, at 2212, determining refined motion information of a current video block for a conversion between a current video block of a video and a codec representation of the video. The method 2210 also includes, at 2214, using the refined motion information for conversion. In some implementations, the refined motion information is generated based on an interlaced prediction tool, wherein the motion information of the segmentation of the current video block is generated using multiple styles, and the refined motion information of the current video block is used for subsequent processing or selectively stored based on whether a condition is met.
[0866] Fig. 22B An exemplary flow chart of a method 2220 of video processing based on some implementations of the disclosed technology is shown. The method 2220 includes, at 2222, determining whether interlaced prediction is applied to a current video block of a video. The method 2220 also includes, at 2224, determining to use a filtering process for the current video block based on the determination of whether interlaced prediction is applied to the current video block. The method 2220 also includes, at 2226, converting between the current video block and a coded representation of the video based on the determination of the use of the filtering process.
[0867] Fig. 22C An exemplary flow chart of a method 2230 of video processing based on some implementations of the disclosed technology is shown. The method 2230 includes, at 2232, determining whether interlaced prediction is applied to a current video block of a video. The method 2230 also includes, at 2234, determining whether to apply local illumination compensation or weighted prediction to the current video block based on the determination of the use of interlaced prediction. The method 2230 also includes, at 2236, converting between the current video block and a coded representation of the video based on the determination of the use of local illumination compensation or weighted prediction.
[0868] Fig.22DAn exemplary flow chart of a method 2240 of video processing based on some implementations of the disclosed technology is shown. The method 2240 includes, at 2242, determining that weighted prediction applies to a current video block of a video or a sub-block of the current video block. The method 2240 also includes, at 2244, converting between the current video block and a coded representation of the video by disabling a bidirectional optical flow (BDOF) technique.
[0869] In the method discussed above, partial interleaving can be implemented. Using this scheme, samples in a first subset of prediction samples are calculated as a weighted combination of a first intermediate prediction block, and samples in a second subset of prediction samples are copied from a subblock-based prediction, where the first subset and the second subset are based on a subdivision pattern. The first subset and the second subset can together constitute an entire prediction block, for example, a block currently being processed. Figures 15A-15D As shown in, in various examples, the second subset excluded from interleaving may consist of (a) corner sub-blocks or (b) the topmost row of sub-blocks and the bottommost row of sub-blocks or (c) the leftmost column of sub-blocks or the rightmost column of sub-blocks. The size of the block currently being processed may be used as a condition to decide whether to exclude certain sub-blocks from interleaving prediction.
[0870] As described further in this document, the encoding process can avoid checking the affine pattern of blocks subdivided from a parent block, where the parent block itself is encoded with a pattern different from the affine pattern.
[0871] In some embodiments, a video decoder device may implement a method of video decoding in which improved block-based motion prediction as described herein is used for video decoding. The method may include forming a block of a video using a set of pixels from a video frame. The block may be subdivided into a first set of sub-blocks according to a first pattern. The first intermediate prediction block may correspond to the first set of sub-blocks. The block may include a second set of sub-blocks according to a second pattern. At least one sub-block in the second set has a different size from the sub-blocks in the first set. The method may also determine a prediction block based on the first intermediate prediction block and a second intermediate prediction block generated from the second set of sub-blocks. Other features of the method may be similar to the above-described method 1900.
[0872] In some embodiments, a decoder-side method of video decoding may use block-based motion prediction for improving video quality by using blocks of a video frame for prediction, where a block corresponds to a set of pixel blocks. The block may be subdivided into a plurality of sub-blocks based on the size of the block or information from another block that is spatially or temporally adjacent to the block, where at least one of the plurality of sub-blocks has a different size than the other sub-blocks. The decoder may use motion vector prediction generated by applying a codec algorithm to the plurality of sub-blocks. Other features of the method are described with respect to method 2000 and the corresponding description.
[0873] Yet another method of video processing includes deriving one or more motion vectors for a first set of sub-blocks of a current video block, wherein each of the first set of sub-blocks has a first subdivision pattern, and reconstructing the current video block based on the one or more motion vectors.
[0874] In some embodiments, deriving one or more motion vectors is based on an affine model.
[0875] In some embodiments, deriving the one or more motion vectors is based on motion vectors of one or more of a second set of sub-blocks, each of the second set of sub-blocks having a second subdivision pattern different from the first subdivision pattern, and one or more of the second set of sub-blocks overlaps with at least one of the first set of sub-blocks. For example, the one or more motion vectors of the first set of sub-blocks include MV 1 , one or more motion vectors of the second set of sub-blocks include MV 01 , MV 02 , MV 03 , … and MV 0K , and K is a positive integer. In this example, MV 1 =f(MV 01 , MV 02 , MV 03 , …, MV 0K ). In another example, f(·) is a linear function. In yet another example, f(·) is a nonlinear function. In yet another example, MV 1 =average(MV 01 , MV 02 , MV 03 , …, MV 0K ), and average(·) is an average operation. In another example, MV 1 =median(MV 01 , MV 02 , MV 03 , …, MV 0K ), and median(·) is an operation to calculate the median value. In another example, MV 1 =min(MV 01 , MV 02 , MV 03 , …, MV 0K ), and min(·) is an operation of selecting the minimum value from multiple input values. In another example, MV 1 =MaxAbs(MV 01 , MV 02 , MV 03 , …, MV 0K), and MaxAbs(·) is an operation of selecting the maximum absolute value from multiple input values.
[0876] In some embodiments, the first set of sub-blocks corresponds to a first color component, and deriving one or more motion vectors is based on motion vectors of one or more of a second set of sub-blocks, each of the second set of sub-blocks having a second subdivision pattern different from the first subdivision pattern, and the second set of sub-blocks corresponds to a second color component different from the first color component. In an example, the first color component is encoded or decoded after the third color component, and wherein the third color component is one of Cr, Cb, U, V, R, or B. In another example, the second color component is encoded or decoded before the third color component, and wherein the third color component is Y or G. In yet another example, deriving the one or more motion vectors is also based on a color format of at least one of the second set of sub-blocks. In yet another example, the color format is 4:2:0, 4:2:2, or 4:4:4.
[0877] In some embodiments, the first subdivision pattern is based on the height or width of the current video block.
[0878] Fig.23 2300. The device 2300 may be used to implement one or more methods described herein. The device 2300 may be implemented as a smartphone, a tablet computer, a computer, an Internet of Things (IoT) receiver, etc. The device 2300 may include one or more processors 2302, one or more memories 2304, and video processing hardware 2306. The processor(s) 2302 may be configured to implement one or more methods described herein (including but not limited to Figures 19 to 22D 2304 can be used to store data and code for implementing the methods and techniques described herein. Video processing hardware 2306 can be used to implement some of the techniques described in this document in hardware circuits.
[0879] Fig.24 is another example of a block diagram of a video processing system in which the disclosed techniques may be implemented. Fig.24 2900 . The present invention relates to a block diagram of an exemplary video processing system 2900 in which various techniques disclosed herein may be implemented. Various implementations may include some or all of the components of the system 2900. The system 2900 may include an input 2902 for receiving video content. The video content may be received in a raw or uncompressed format, such as 8 or 10 bit multi-component pixel values, or may be in a compressed or encoded format. The input 2902 may represent a network interface, a peripheral bus interface, or a storage interface. Examples of network interfaces include wired interfaces such as Ethernet, a passive optical network (PON), and wireless interfaces such as Wi-Fi or a cellular interface.
[0880] System 2900 may include coding component 2904, which may implement various coding or coding methods described in this document. Coding component 2904 may reduce the average bit rate of the video from input 2902 to the output of coding component 2904 to generate the coded representation of the video. Therefore, coding techniques are sometimes referred to as video compression or video transcoding techniques. The output of coding component 2904 may be stored or transmitted via a connected communication, as represented by component 2906. The bitstream (or coding) representation of the storage or communication of the video received at input 2902 may be used by component 2908 to generate pixel values or displayable video sent to display interface 2910. The process of generating user-visible video from bitstream representation is sometimes referred to as video decompression. In addition, although some video processing operations are referred to as "coding" operations or tools, it should be understood that coding tools or operations are used at encoders, and the corresponding decoding tools or operations of the reverse coding results will be performed by decoders.
[0881] Examples of peripheral bus interfaces or display interfaces may include Universal Serial Bus (USB) or High Definition Multimedia Interface (HDMI) or DisplayPort, etc. Examples of storage interfaces include SATA (Serial Advanced Technology Attachment), PCI, IDE interfaces, etc. The technology described in this document may be implemented in various electronic devices, such as mobile phones, laptop computers, smart phones, or other devices capable of performing digital data processing and / or video display.
[0882] In some embodiments, the video encoding and decoding method can be implemented in Fig.23 or device implementation on the hardware platform described in 24.
[0883] Various techniques and embodiments may be described using the following clause-based format.
[0884] The first set of items describes certain features and aspects of the disclosed technology listed in the previous sections, including, for example, item 1.
[0885] 1. A method for video processing, comprising: deriving one or more motion vectors of a first set of sub-blocks of a first subdivision pattern belonging to a current video block of a video; and performing conversion between the current video block and a codec representation of the video based on the one or more motion vectors.
[0886] 2. The method of clause 1, wherein deriving one or more motion vectors is based on an affine model.
[0887] 3. The method of clause 1, wherein deriving the one or more motion vectors is based on motion vectors of a second set of sub-blocks, wherein the second set of sub-blocks has a second subdivision pattern different from the first subdivision pattern.
[0888] 4. The method of clause 3, wherein the second set of sub-blocks overlaps with the first set of sub-blocks.
[0889] 5. The method of clause 3, wherein the one or more motion vectors of the first set of sub-blocks include MV 1 , and the motion vectors of the second set of sub-blocks include MV 01 , MV 02 , MV 03 , … and MV 0K , and where K is a positive integer.
[0890] 6. The method of clause 5, wherein MV 1 =f(MV 01 , MV 02 , MV 03 , …, MV 0K ).
[0891] 7. The method of clause 6, wherein f(·) is a linear function.
[0892] 8. The method of clause 6, wherein f(·) is a nonlinear function.
[0893] 9. The method of clause 5, wherein MV 1 =average(MV 01 , MV 02 , MV 03 , …, MV 0K ), where average(·) is the average operation.
[0894] 10. The method of clause 5, wherein MV 1 =median(MV 01 , MV 02 , MV 03 , …, MV 0K ), where median(·) is the operation that calculates the median value.
[0895] 11. The method of clause 5, wherein MV 1 =max(MV 01 , MV 02 , MV 03 , …, MV 0K ), where max(·) is an operation that selects the maximum value from multiple input values.
[0896] 12. The method of clause 5, wherein MV 1 =min(MV 01 , MV 02 , MV 03 , …, MV 0K ), where min(·) is an operation that selects the minimum value from multiple input values.
[0897] 13. The method of clause 5, wherein MV 1 =MaxAbs(MV 01 , MV 02 , MV 03 , …, MV 0K ), where MaxAbs(·) is an operation that selects the maximum absolute value from multiple input values.
[0898] 14. The method of clause 5, wherein MV 1 =MinAbs(MV 01 , MV 02 , MV 03 , …, MV 0K ), where MinAbs(·) is an operation that selects the minimum absolute value from multiple input values.
[0899] 15. The method of any one of clauses 1 to 14, wherein performing the conversion comprises generating a codec representation from a current video block.
[0900] 16. The method of any of clauses 1 to 14, wherein performing the conversion comprises generating a current video block from a codec representation.
[0901] 17. A device in a video system, comprising a processor and a non-volatile memory having instructions thereon, wherein the instructions, when executed by the processor, cause the processor to implement the method of one or more of clauses 1 to 16.
[0902] 18. A computer program product stored on a non-transitory computer readable medium, said computer program product comprising program code for performing the method of one or more of claims 1 to 16.
[0903] The second set of items describes certain features and aspects of the disclosed technology listed in the previous sections, including, for example, item 14.
[0904] The third collection of items describes certain features and aspects of the disclosed technology listed in the previous sections, including, for example, items 13, 15, 16, 17, and 18.
[0905] 1. A video processing method, comprising:
[0906] For conversion between a current video block of a video and a bitstream representation of the video, subdividing the current video block into partitions according to a plurality of subdivision patterns according to a height (H) or a width (W) of the current video block; and
[0907] The converting is performed using interleaved prediction of the plurality of partitions.
[0908] 2. The method of clause 1, wherein the current video block is subdivided according to two subdivision patterns when W>T1 and H>T2, T1, T2 are integer values.
[0909] 3. The method as described in clause 2, wherein T1=T2=4.
[0910] 4. The method of clause 1, wherein the current video block is subdivided according to two subdivision patterns when H<=T2, T2 being an integer.
[0911] 5. The method of clause 4, wherein T2=4.
[0912] 6. The method of clause 1, wherein the current video block is subdivided according to two subdivision patterns when W<=T1, T1 being an integer.
[0913] 7. The method of clause 6, wherein T1=4.
[0914] 8. A video processing method, comprising:
[0915] Determining to apply prediction to a current video block of a video, the prediction comprising subdividing the current video block into sub-blocks according to a subdivision pattern;
[0916] Determining to apply a bit shift to generate a prediction block on a sub-block of the current video block; and
[0917] A conversion is performed between the current video block and a codec representation of the video.
[0918] 9. The method of clause 8, wherein bi-directional prediction or uni-directional prediction is applied to the current video block.
[0919] 10. The method of clause 8, wherein one or more motion vectors associated with the current video block have an internal bit depth, the internal bit depth being dependent on a weight value of the prediction.
[0920] 11. A method as described in clause 8, wherein, for the reference picture list X of the current video block, PX(x, y) = Shift(W0(x, y)*PX0(x, y)+W1(x, y)*PX1(x, y), SW), where PX(x, y) is the prediction of the list X as 0 or 1, PX0(x, y) and PX1(x, y) are the predictions of the list X using subdivision style 0 and subdivision style 1, respectively, W0 and W1 are integers representing weight values of the interlaced prediction, SW represents the precision of the interlaced weight value, and Shift(x, n) is defined as Shift(x, n) = (x+offset0)>>n.
[0921] 12. A method as described in clause 8, wherein the final prediction value is derived as P(x, y) = Shift(Wb0(x, y)*P0(x, y)+Wb1(x, y)*P1(x, y), SWB), where Wb0 and Wb1 are integers representing weight values of the bidirectional prediction, P0(x, y) and P1(x, y) represent the predictions of list 0 and list 1 respectively, SWB is the accuracy of the weighted bidirectional prediction, and Shift(x, n) is defined as Shift(x, n) = (x+offset0)>>n.
[0922] 13. The method of clause 12, wherein Wb0=Wb1=SWB=1.
[0923] 14. A method as described in clause 8, wherein interpolation filtering is applied to generate a prediction block and the final prediction value is derived as P(x, y) = Shift(Wb0(x, y)*P0(x, y)+Wb1(x, y)*P1(x, y), SWB+PB), where Wb0 and Wb1 are integers representing weight values for interleaved prediction, SWB is the precision of weighted bidirectional prediction, PB is the additional precision from the interpolation filtering, and Shift(x, n) is defined as Shift(x, n) = (x+offset0)>>n.
[0924] 15. A method as described in clause 14, wherein PX0(x,y) and PX1(x,y) are predictions of reference picture list X using subdivision style 0 and subdivision style 1, respectively, and wherein PX0(x,y) and PX1(x,y) are right shifted.
[0925] 16. The method of clause 8, wherein the bi-directional prediction uses different weight factors for two reference prediction blocks.
[0926] 17. A method as described in clause 11 or 14, wherein PX0(x, y) is modified as PX0(x, y) = Shift(PX0(x, y), M) and / or PX1(x, y) is modified as PX1(x, y) = Shift(PX1(x, y), M), where M is an integer and P(x, y) = Shift(Wb0(x, y)*P0(x, y)+Wb1(x, y)*P1(x, y), SWB+PB-M).
[0927] 18. A video processing method, comprising:
[0928] determining, based on characteristics of a current video block of a video, whether to use an interlaced prediction tool for conversion between the current block and a codec representation of the video; and
[0929] performing said conversion according to said determination,
[0930] Once it is determined that the characteristic of the current video block does not satisfy a condition, the conversion is performed by disabling the use of an affine prediction tool and / or the interlaced prediction tool.
[0931] 19. A video processing method, comprising:
[0932] determining, based on characteristics of a current video block of a video, whether to use an interlaced prediction tool for conversion between the current block and a codec representation of the video; and
[0933] performing said converting according to said determining, and
[0934] Once it is determined that the characteristic of the current video block satisfies a condition, the conversion is performed by using an affine prediction tool and / or the interlaced prediction tool.
[0935] 20. The method of clause 18 or 19, wherein the characteristic of the current video block comprises at least one of a width or a height of the current video block.
[0936] 21. The method according to clause 18 or 19, further comprising:
[0937] A size of a video processing data unit (VPDU) is determined, and wherein determining whether to use the interleaved prediction tool is based on the size of the VPDU.
[0938] 22. The method of clause 18, wherein a prediction method different from the interlaced prediction is applied to the current video block.
[0939] 23. The method as described in clause 18, wherein the width and height of the current video block are W and H respectively, and T, T1, and T2 are integer values, and wherein the interleaved prediction is disabled for a specific condition, the specific condition including one of the following:
[0940] i. W > T1 and H > T2,
[0941] ii. W > T1 or H > T2,
[0942] iii. W x H > T,
[0943] iv. W < T1 and H < T2, or
[0944] v. W < T1 or H < T2
[0945] vi. W * H < T.
[0946] 24. The method as described in clause 18 or 19, further comprising:
[0947] determining that a first sub - block of the current video block is not located at a block boundary; and
[0948] once it is determined that the first sub - block is not located at the block boundary, disabling the interleaved affine technique for the first sub - block.
[0949] 25. The method as described in clause 24, wherein the prediction result from the original affine prediction technique is used for the final prediction of the first sub - block.
[0950] 26. The method as described in clause 18, wherein the width and height of the current video block are W and H respectively, and T, T1, and T2 are integer values, and wherein the interleaved prediction is used for a specific condition, the specific condition including one of the following:
[0951] i. W > T1 and H > T2,
[0952] ii. W > T1 or H > T2,
[0953] iii. W x H > T,
[0954] iv. W < T1 and H < T2, or
[0955] v. W < T1 or H < T2
[0956] vi. W * H < T.
[0957] 27. The method as described in clause 18, wherein in the case where the height (H) of the current video block is greater than X, X being an integer, the interleaved prediction is not applied to the samples of the sub - blocks belonging to the upper W * (H / 2) division and the lower W * (H / 2) division across the current video block.
[0958] 28. A method as described in clause 18, wherein when the width (W) of the current video block is greater than X, where X is an integer, the interlaced prediction is not applied to samples belonging to sub-blocks that span both the left (W / 2)*H partition and the right (W / 2)*H partition of the current video block.
[0959] 29. A method as described in clause 27 or 28, wherein X=64.
[0960] 30. The method of clause 19, wherein the interlaced prediction is enabled for a particular type of video data unit comprising the current video block, the video data unit comprising a picture, a slice, a slice group, or a slice.
[0961] 31. The method of clause 19, wherein the interlaced prediction is for a P picture or a B picture.
[0962] 32. A method as claimed in clause 18 or 19, wherein a flag indicating whether the interlaced prediction tool is used or disabled is signalled in a header of a picture, slice, slice group or slice.
[0963] 33. The method of clause 32, wherein the flag is signaled based on whether affine prediction is allowed for the current video block.
[0964] 34. A method as described in clause 18 or 19, wherein a notification message is signaled in a video processing unit to indicate whether to use the characteristics of the current video block, and the video processing unit includes a video parameter set (VPS), a sequence parameter set (SPS), a picture parameter set (PPS), a slice header, a picture header, a slice group header, a slice, a codec tree unit (CTU), or a CTU row.
[0965] 35. A video processing method, comprising:
[0966] determining that interlaced prediction is to be applied to a current video block of the video;
[0967] Disabling bi-prediction for the current video block based on determining that interlaced prediction is to be applied; and
[0968] A conversion is performed between the current video block and a codec representation of the video.
[0969] 36. A method as described in clause 35, wherein an index indicating the use of bidirectional prediction is not signaled.
[0970] 37. A method as described in clause 36, wherein bidirectional prediction is disabled based on an indication signaled in a video parameter set (VPS), a sequence parameter set (SPS), a picture parameter set (PPS), a slice header, a picture header, a slice group header, a slice, a codec tree unit (CTU), a CTU row, or multiple CTUs.
[0971] 38. A method as described in any of clauses 1 to 37, wherein the converting includes generating pixel values of the current video block from the bitstream representation.
[0972] 39. A method as described in any of clauses 1 to 37, wherein the conversion includes generating the bitstream representation from pixel values of the current video block.
[0973] 40. An apparatus in a video system comprising a processor and a non-volatile memory having instructions thereon, wherein the instructions, when executed by the processor, cause the processor to implement the method of one or more of clauses 1 to 39.
[0974] 41. A computer program product stored on a non-transitory computer readable medium, the computer program product comprising program code for performing the method of one or more of clauses 1 to 39.
[0975] The fourth collection of items describes certain features and aspects of the disclosed technology listed in the previous sections, including, for example, items 19, 20, 21, and 22.
[0976] 1. A video processing method, comprising:
[0977] For a conversion between a current video block of a video and a codec representation of the video, determining refined motion information for at least one sub-block of the current video block; and
[0978] performing the converting using the refined motion information,
[0979] wherein the refined motion information is generated based on an interlaced prediction tool, in which multiple patterns are used to generate segmented motion information of the current video block, and
[0980] The refined motion information of the current video block is used for subsequent processing or selectively stored based on whether a condition is satisfied.
[0981] 2. The method of clause 1, wherein the subsequent processing is conversion of a subsequent block to be converted after the current video block.
[0982] 3. The method of clause 1, wherein the subsequent processing is a filtering process of the current video block.
[0983] 4. A method as described in clause 1, wherein whether the condition is met is determined based on the position of the sub-block, and the position is related to a block, CTU, CTU row, slice, slice, slice group or picture in the video.
[0984] 5. The method of clause 1, wherein whether the condition is satisfied is determined based on a codec mode of at least one of the current video block or a neighboring video block of the current video block.
[0985] 6. The method of clause 1, wherein determining whether the condition is satisfied is based on a size of the current video block.
[0986] 7. The method of clause 1, wherein whether the condition is satisfied is determined based on at least one of a picture, a slice type, or a reference picture list associated with the current video block.
[0987] 8. A video processing method, comprising:
[0988] determining whether interlaced prediction applies to a current video block of a video;
[0989] determining to use a filtering process for the current video block based on determining whether the interlaced prediction applies to the current video block; and
[0990] Converting between the current video block and a codec representation of the video is performed based on the determination of use of the filtering process.
[0991] 9. The method of clause 8, wherein the filtering process comprises a deblocking process, a sample adaptive offset (SAO) filter or an adaptive loop filter.
[0992] 10. The method according to clause 8, further comprising:
[0993] Parameters related to how the filtering process is applied are determined, and wherein the converting is performed based on the parameters of the filtering process.
[0994] 11. The method of clause 8, wherein the filtering process is not applied on an edge between two subblocks in a subdivision pattern of the current video block if the edge is within a subblock in another subdivision pattern of the current video block.
[0995] 12. The method of clause 8, wherein the filtering process is at a weaker level than an edge between two subblocks in a subdivision pattern of the current video block, in case the edge is within a subblock in another subdivision pattern of the current video block.
[0996] 13. The method of clause 9, wherein at least one of the variables bS[xDi][yDj], β, Δ, or tC used in the deblocking process has a smaller value for the edge.
[0997] 14. The method of clause 8, wherein the filtering process is at a stronger level than an edge between two subblocks in a subdivision pattern of the current video block, in case the edge is within a subblock in another subdivision pattern of the current video block.
[0998] 15. The method of clause 14, wherein at least one of the variables bS[xDi][yDj], β, Δ, or tC used in the deblocking process has a larger value for the edge.
[0999] 16. A video processing method, comprising:
[1000] determining whether interlaced prediction applies to a current video block of a video;
[1001] Based on determining the use of the interlaced prediction, determining whether to use local illumination compensation or weighted prediction for the current video block; and
[1002] Based on the determination of use of the local illumination compensation or the weighted prediction, a conversion is performed between the current video block and a codec representation of the video.
[1003] 17. The method according to clause 16, further comprising:
[1004] Parameters related to how to apply the local illumination compensation or the weighted prediction are determined, and wherein the converting is performed based on the parameters of the local illumination compensation or the weighted prediction.
[1005] 18. The method of clause 16, wherein upon determining that the interlaced prediction is applied to the current video block, the local illumination compensation or weighted prediction is disabled.
[1006] 19. The method of clause 16, wherein for the current video block or a sub-block of the current video block to which the interlaced prediction is applied, an indication that the local illumination compensation or the weighted prediction is enabled is not signaled.
[1007] 20. A video processing method, comprising:
[1008] Determining that weighted prediction applies to a current video block of a video or a sub-block of the current video block; and
[1009] Converting between the current video block and a codec representation of the video is performed by disabling a Bidirectional Optical Flow (BDOF) technique.
[1010] 21. The method of clause 20, wherein the BDOF technique is applied to blocks with weighted prediction when certain conditions are met.
[1011] 22. The method of clause 21, wherein a parameter of the BDOF technique is within a threshold range or equal to a specific value.
[1012] 23. The method of clause 22, wherein a specific reference picture restriction is applied to the current video block.
[1013] 24. The method of any one of clauses 1 to 23, wherein the converting comprises generating pixel values of the current video block from the bitstream representation.
[1014] 25. A method as described in any of clauses 1 to 23, wherein the converting includes generating the bitstream representation from pixel values of the current video block.
[1015] 26. An apparatus in a video system, comprising a processor and a non-volatile memory having instructions thereon, wherein the instructions, when executed by the processor, cause the processor to implement the method of one or more of clauses 1 to 25.
[1016] 27. A computer program product stored on a non-transitory computer readable medium, the computer program product comprising program code for performing the method of one or more of clauses 1 to 25.
[1017] It will be appreciated from the foregoing that specific embodiments of the disclosed technology have been described herein for illustrative purposes, but various modifications may be made without departing from the scope of the invention. Accordingly, the disclosed technology is not to be limited except as set forth in the appended claims.
[1018] The disclosed and other embodiments, modules and functional operations described in this document may be implemented in digital electronic circuits, or in computer software, firmware or hardware, including the structures disclosed in this document and their structural equivalents, or a combination of one or more of them. The disclosed and other embodiments may be implemented as one or more computer program products, i.e., one or more computer program instruction modules encoded on a computer-readable medium, for execution by a data processing device or for controlling the operation of a data processing device. The computer-readable medium may be a machine-readable storage device, a machine-readable storage substrate, a memory device, a combination of substances that affect a machine-readable propagation signal, or a combination of one or more of them. The term "data processing device" includes all devices, devices and machines for processing data, including, for example, a programmable processor, a computer or multiple processors or computers. In addition to hardware, the device may also include code that creates an execution environment for the computer program in question, for example, code constituting processor firmware, a protocol stack, a database management system, an operating system, or a combination of one or more of them. Propagation signaling is an artificially generated signal, such as a machine-generated electrical signal, an optical signal, or an electromagnetic signal, which is generated to encode information for transmission to a suitable receiver device.
[1019] A computer program (also referred to as a program, software, software application, script, or code) may be written in any form of programming language, including compiled or interpreted languages, and it may be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a computing environment. A computer program does not necessarily correspond to a file in a file system. A program may be stored in a portion of a file that holds other programs or data (e.g., one or more scripts stored in a markup language file), in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files storing portions of one or more modules, subroutines, or code). A computer program may be deployed to execute on one computer or on multiple computers located at one site or distributed over multiple sites and interconnected by a communications network.
[1020] The processes and logic flows described in this document may be performed by one or more programmable processors executing one or more computer programs to perform functions by operating on input data and generating output. The processes and logic flows may also be performed by, and apparatus may be implemented as, special purpose logic circuitry, such as an FPGA (field programmable gate array) or an ASIC (application specific integrated circuit).
[1021] Processors suitable for executing computer programs include, for example, general-purpose and special-purpose microprocessors, and any one or more processors of any type of digital computer. Typically, the processor will receive instructions and data from a read-only memory or a random access memory or both. The basic elements of a computer are a processor for executing instructions and one or more memory devices for storing instructions and data. Typically, a computer will also include one or more mass storage devices (such as magnetic disks, magneto-optical disks, or optical disks) for storing data or be operably coupled thereto to receive data from one or more mass storage devices or transfer data to one or more mass storage devices. However, a computer does not require such a device. Computer-readable media suitable for storing computer program instructions and data include all forms of non-volatile memory, media, and memory devices, including, for example, semiconductor memory devices, such as EPROM, EEPROM, and flash memory devices; magnetic disks, such as internal hard disks or removable disks; magneto-optical disks; and, CD ROM and DVD-ROM disks. The processor and memory may be supplemented by or incorporated into a dedicated logic circuit.
[1022] Although this patent document contains many details, these details should not be interpreted as limitations on any invention or the scope of the claim, but rather as descriptions of features specific to particular embodiments of particular inventions. Certain features described in this patent document in the context of separate embodiments may also be implemented in combination in a single embodiment. Conversely, various features described in the context of a single embodiment may also be implemented in multiple embodiments, either individually or in any suitable subcombination. In addition, although the above features may be described as working in certain combinations and even initially claimed as such, one or more features from the claimed combination may be removed from the combination in some cases, and the claimed combination may be directed to a subcombination or a variation of the subcombination.
[1023] Similarly, although operations are depicted in a particular order in the drawings, this should not be understood as requiring that such operations be performed in the particular order shown or in sequential order, or that all of the operations shown be performed, in order to achieve desired results. Furthermore, the separation of various system components in the embodiments described in this patent document should not be understood as requiring such separation in all embodiments.
[1024] Only a few implementations and examples are described, and other implementations, enhancements, and variations may be made based on what is described and illustrated in this patent document.
Claims
1. A video processing method, comprising: Determining to apply prediction to a current video block of a video, the prediction comprising subdividing the current video block into sub-blocks according to a subdivision pattern; Determining to apply a bit shift to generate a prediction block on a sub-block of the current video block; as well as performing conversion between the current video block and the bit stream of the video, Where interpolation filtering is applied to generate a prediction block, and the final prediction value is derived as P(x, y) = Shift(Wb0(x, y)*P 0 (x,y)+Wb1(x,y)*P 1 (x, y), SWB+PB), where Wb0 and Wb1 are integers representing weight values for bidirectional prediction, SWB is the precision of weighted bidirectional prediction, PB is the additional precision from the interpolation filter, and P 0 (x, y) and P 1 (x, y) represents the predictions of list 0 and list 1 respectively, and Shift(x, n) is defined as Shift(x, n) = (x + offset0) >> n, where offset0 represents the offset.
2. The method of claim 1, wherein one or more motion vectors associated with the current video block have an internal bit depth, the internal bit depth being dependent on a weight value of the prediction.
3. The method of claim 1, wherein: For the reference picture list X, P of the current video block X (x, y) = Shift(W0(x, y)*P X 0(x,y)+W1(x,y)*P X 1(x, y), SW), where P X (x, y) is the prediction of the list X as 0 or 1, P X 0(x, y) and P X 1(x, y) is the prediction of list X using subdivision style 0 and subdivision style 1 respectively, W0 and W1 are integers representing the weight values of interleaved prediction, and SW represents the precision of the interleaved weight value.
4. The method of claim 1, wherein the final prediction value is derived as P(x, y) = Shift(Wb0(x, y)*P 0 (x,y)+Wb1(x,y)*P 1 (x, y), SWB).
5. The method of claim 4, wherein: Wb0=Wb1=SWB=1.
6. The method of claim 3, wherein P X 0(x, y) and P X 1(x, y) are the predictions of reference picture list X using subdivision style 0 and subdivision style 1, respectively, and where P X 0(x, y) and P X 1(x, y) is shifted right.
7. The method of claim 1, wherein the bidirectional prediction uses different weight factors for two reference prediction blocks.
8. The method of claim 3, wherein P X 0(x, y) is modified to P X 0(x, y) = Shift(P X 0(x, y), M) and / or P X 1(x, y) is modified to P X 1(x, y) = Shift(P X 1(x,y), M), where M is an integer, and P(x,y)=Shift(Wb0(x,y)*P0(x,y)+Wb1(x,y)*P1(x,y), SWB+PB-M).
9. The method of claim 1, further comprising: For conversion between a current video block of a video and a bitstream of the video, subdividing the current video block into a plurality of partitions according to a plurality of subdivision patterns according to a height (H) or a width (W) of the current video block; and The converting is performed using interleaved prediction of the plurality of partitions. 10 . The method of claim 9 , wherein the current video block is subdivided according to two subdivision patterns when W>T1 and H>T2, T1, T2 are integer values. The method of claim 10 , wherein T1=T2=4. 12 . The method of claim 9 , wherein when H<=T2, T2 is an integer, the current video block is subdivided according to two subdivision patterns. The method of claim 12 , wherein T2=4. 14 . The method of claim 9 , wherein when W<=T1, T1 is an integer, the current video block is subdivided according to two subdivision patterns. The method of claim 14 , wherein T1=4.
16. The method of claim 1, further comprising: Based on characteristics of a current video block of a video, determining whether to use an interlaced prediction tool for conversion between the current video block and a bitstream of the video; as well as performing said conversion according to said determination, Once it is determined that the characteristic of the current video block does not satisfy a condition, the conversion is performed by disabling the use of an affine prediction tool and / or the interlaced prediction tool.
17. The method of claim 1, further comprising: Based on characteristics of a current video block of a video, determining whether to use an interlaced prediction tool for conversion between the current video block and a bitstream of the video; as well as performing the converting according to the determining, and Once it is determined that the characteristic of the current video block satisfies a condition, the conversion is performed by using an affine prediction tool and / or the interlaced prediction tool.
18. The method of claim 16 or 17, wherein the characteristic of the current video block comprises at least one of a width or a height of the current video block.
19. The method of claim 16 or 17, further comprising: A size of a video processing data unit (VPDU) is determined, and wherein determining whether to use the interleaved prediction tool is based on the size of the VPDU.
20. The method according to claim 16, wherein a prediction method different from the interleaved prediction is applied to the current video block.
21. The method according to claim 16, wherein the width and height of the current video block are W and H respectively, and T, T1, and T2 are integer values, and wherein the interleaved prediction is disabled for a specific condition, the specific condition including one of the following: i. W > T1 and H > T2, ii. W > T1 or H > T2, iii. W * H > T, iv. W < T1 and H < T2, v. W < T1 or H < T2, vi. W * H < T.
22. The method according to claim 16 or 17, further comprising: determining that a first sub-block of the current video block is not located at a block boundary; and once it is determined that the first sub-block is not located at the block boundary, disabling the interleaved affine technique for the first sub-block.
23. The method according to claim 22, wherein a prediction result from an original affine prediction technique is used for the final prediction of the first sub-block.
24. The method according to claim 16, wherein the width and height of the current video block are W and H respectively, and T, T1, and T2 are integer values, and wherein the interleaved prediction is used for a specific condition, the specific condition including one of the following: i. W > T1 and H > T2, ii. W > T1 or H > T2, iii. W * H > T, iv. W < T1 and H < T2, v. W < T1 or H < T2, vi. W * H < T.
25. The method according to claim 16, wherein in the case where the height (H) of the current video block is greater than X, X being an integer, the interleaved prediction is not applied to samples of sub-blocks belonging to the upper W * (H / 2) division and the lower W * (H / 2) division across the current video block.
26. The method according to claim 16, wherein in the case where the width (W) of the current video block is greater than X, X being an integer, the interleaved prediction is not applied to samples of sub-blocks belonging to both the left (W / 2) * H division and the right (W / 2) * H division across the current video block.
27. The method according to claim 25 or 26, wherein X = 64.
28. The method according to claim 17, wherein the interleaved prediction is allowed for a specific type of video data unit including the current video block, the video data unit including a picture, a slice, a slice group, or a tile.
29. The method according to claim 17, wherein the interleaved prediction is used for a P picture or a B picture.
30. The method according to claim 16 or 17, wherein a flag indicating whether to use or disable the interleaved prediction tool is signaled in the header of a picture, a slice, a slice group, or a tile.
31. The method according to claim 30, wherein the flag is signaled based on whether affine prediction is allowed for the current video block.
32. The method of claim 16 or 17, wherein a message is signaled in a video processing unit to indicate whether to use the characteristics of the current video block, the video processing unit comprising a video parameter set (VPS), a sequence parameter set (SPS), a picture parameter set (PPS), a slice header, a picture header, a slice group header, a slice, a codec tree unit (CTU), or a CTU row.
33. The method of claim 1, further comprising: determining that interlaced prediction is to be applied to a current video block of the video; Based on determining that interlaced prediction is to be applied, bi-prediction is disabled for the current video block. The method of claim 33 , wherein an index indicating use of bidirectional prediction is not signaled.
35. The method of claim 34, wherein bi-directional prediction is disabled based on an indication signaled in a video parameter set (VPS), a sequence parameter set (SPS), a picture parameter set (PPS), a slice header, a picture header, a slice group header, a slice, a codec tree unit (CTU), a CTU row, or a plurality of CTUs.
36. The method of any one of claims 1-17, 20-21, 23-26, 28-29, 33-35, wherein the converting comprises generating pixel values of the current video block from the bitstream.
37. The method of any one of claims 1-17, 20-21, 23-26, 28-29, 33-35, wherein the converting comprises generating the bitstream from pixel values of the current video block.
38. A device in a video system, comprising a processor and a non-volatile memory having instructions thereon, wherein the instructions, when executed by the processor, cause the processor to implement the method of any one of claims 1 to 37.
39. A non-transitory computer-readable storage medium comprising instructions for performing the method of any one of claims 1 to 37.
