EP4690797A1 - Encoder for encoding pictures of a video - Google Patents

Encoder for encoding pictures of a video

Info

Publication number
EP4690797A1
EP4690797A1 EP24785436.7A EP24785436A EP4690797A1 EP 4690797 A1 EP4690797 A1 EP 4690797A1 EP 24785436 A EP24785436 A EP 24785436A EP 4690797 A1 EP4690797 A1 EP 4690797A1
Authority
EP
European Patent Office
Prior art keywords
subblock
determining
satisfied
refined
criterion
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
EP24785436.7A
Other languages
German (de)
French (fr)
Inventor
Kenneth Andersson
Ruoyang YU
Jacob STRÖM
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Telefonaktiebolaget LM Ericsson AB
Original Assignee
Telefonaktiebolaget LM Ericsson AB
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Telefonaktiebolaget LM Ericsson AB filed Critical Telefonaktiebolaget LM Ericsson AB
Publication of EP4690797A1 publication Critical patent/EP4690797A1/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/513Processing of motion vectors
    • H04N19/517Processing of motion vectors by encoding
    • H04N19/52Processing of motion vectors by encoding by predictive encoding
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/577Motion compensation with bidirectional frame interpolation, i.e. using B-pictures
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/70Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by syntax aspects related to video coding, e.g. related to compression standards

Definitions

  • a video (a.k.a., video sequence) consists of a series of pictures (a.k.a., images) wherein each picture consists of one or more components.
  • VVC Versatile Video Coding
  • each picture is identified with a picture order count (POC) value.
  • POC picture order count
  • Components [0005] Each component of a picture can be described as a two-dimensional rectangular array of sample values (or “samples” for short).
  • a picture in a video sequence consists of three components: one luma component (Y) where the sample values are luma values and two chroma components (Cb and Cr) where the sample values are chroma values. It is also common that the dimensions of the chroma components are smaller than the luma components by a factor of two in each dimension. For example, the size of the luma component of a high- definition (HD) picture can be 1920x1080 while the chroma components may each have the dimension of 960x540. Components are sometimes referred to as color components.
  • Coding Unit and Coding Block typically, each component is split into many blocks and a coded video (a.k.a., video bitstream) comprises of a series of coded blocks. It is common in video coding that the picture is split into units that cover a specific area of the picture. [0008] Each unit consists of all blocks from all components that make up that specific area and each block belongs fully to one unit.
  • the macroblock in H.264 and the Coding unit (CU) in High Efficiency Video Coding (HEVC) are examples of units.
  • CUs may be split recursively to smaller CUs.
  • the CU at the top level is referred to as coding tree unit (CTU).
  • a CU usually contains three coding blocks -- i.e., one coding block for luma and two coding blocks for chroma.
  • the size of the luma coding block is the same as the CU.
  • the CUs can have the size of 4x4 up to 128x128.
  • Intra prediction [0011] In intra prediction (also known as spatial prediction), a block is predicted using previously decoded blocks within the same picture. In other words, samples inside the previously decoded blocks within the same picture are used to predict the samples inside the current block.
  • a picture consisting of only intra-predicted blocks is referred to as an intra picture.
  • Inter prediction In inter prediction (also known as temporal prediction), blocks of the current picture are predicted using blocks of previously decoded pictures. In other words, the samples from the blocks of the previously decoded pictures are used to predict the samples of the current block. [0014] A picture that allows inter-predicted block is referred to as an inter picture. The previously decoded pictures used for inter prediction are referred to as reference pictures. [0015] The location of the referenced block inside the reference picture is indicated using a motion vector (MV). Each MV consists of x and y components each of which represents a displacement between current block and the referenced block in x or y dimension. The value of a component may have a resolution finer than an integer position.
  • MV motion vector
  • FIG.1 shows an example of a MV for current block C.
  • the MV (2,1) indicates that the position of reference block is two steps to the right and one step down from the position of the current block C.
  • An inter picture may use several reference pictures.
  • the reference pictures are usually put into two reference picture lists, L0 and L1.
  • the reference pictures that are output before the current picture are typically the first pictures in L0.
  • the reference pictures that are output after the current picture are typically the first pictures in L1.
  • Inter predicted blocks can use one of two prediction types: uni-prediction and bi- prediction. Uni-predicted block may be predicted from one reference picture, either using L0 or L1.
  • Bi-predicted block may be predicted from two reference pictures, one from L0 and the other from L1.
  • FIG.2 shows an example of the prediction types.
  • Residual, transform, and quantization [0019] Typically, for each block, a residual block is produced where the residual block is the difference between samples of a source block (which contains original samples) and samples of a prediction block. The residual block is then typically compressed by a spatial transform which produces transform coefficients. To control the fidelity of the residual block and also the bitrate required to compress the block, the transform coefficients of the spatial transform are quantized by a quantization parameter (QP) to produce quantized transform coefficients.
  • QP quantization parameter
  • a coded block flag (CBF) is used to indicate if there are any non-zero quantized transform coefficients.
  • All coding parameters, including the quantized transform coefficients, are then entropy coded at the encoder and decoded at the decoder.
  • a reconstructed block can then be derived by inverse quantization and inverse transformation of the quantized transform coefficients (assuming the CBF is one) to produce a reconstructed residual block (or “reconstructed block” for short).
  • the reconstructed block is then added to a prediction block to produce a block corresponding to the source block.
  • Hierarchical picture coding structure [0021] In what is often referred to as “random access configuration,” intra coded pictures are positioned with a fixed interval (e.g., every second). Pictures between the intra coded pictures are typically coded with a B-GOP structure as shown in FIG.3.
  • Inter prediction information of an inter coded block in an inter coded picture in VVC may consist of the following three elements: [0026] 1.
  • a reference picture list flag (RefPicListFlag). The flag signals which reference picture list is used. When the value of the flag is equal to 0, it means L0 is used. When the value of the flag is equal to 1, it means L1 is used. When the value of the flag is equal to 2, it means both L0 and L1 are used. [0027] 2.
  • the index signals which reference picture inside the reference picture list is used.
  • the MV signals the position inside the reference picture that is used for predicting the current block.
  • the inter prediction information is also referred to as motion information.
  • the decoder stores the motion information for each inter coded block. In other words, an inter coded block maintains its own motion information.
  • Encoder decision and Rate Distortion (RD) cost [0031] In order for an encoder to decide the best prediction mode for a current block, the encoder will evaluate many or all of the possible prediction modes for the current block and select the prediction mode that yields the smallest Rate-Distortion (RD) cost. [0032] The RD cost may be calculated as ⁇ + ⁇ ⁇ ⁇ . The D (Distortion) measures the difference between the reconstructed block and the corresponding source block.
  • VVC Motion information signaling
  • VVC includes several methods of implicitly signaling motion information for each block, including the merge method and the subblock merge method. A common motivation behind the implicit methods is to inherit motion information from neighboring coded blocks.
  • Merge (a.k.a., block merge) method [0036]
  • the merge method is similar to the one in the HEVC standard. The method is sometimes referred to as block merge method since the derived motion information is used for generating the samples of the entire block.
  • the method first generates a list of motion information candidates. The list is also referred to as merge list. The candidates are derived from previously coded blocks.
  • the blocks can be spatially adjacent neighboring blocks (neighboring the current block) or temporal collocated blocks relative to the current block.
  • FIG.4 shows possible spatial blocks for fetching neighboring motion information -- the spatial neighboring blocks: left (L), top(T), top-right(TR), left-bottom (LB), and top-left (TL).
  • VVC also includes explicit motion information signaling methods such as alternative motion vector prediction (AMVP). For a current inter coded block that is coded with AMVP, its number of reference pictures, reference picture indices, and associated motion vectors are explicitly signaled and encoded into the bitstream.
  • AMVP alternative motion vector prediction
  • the block merge method is a cheaper alternative compared to the explicit motion information signaling method in terms of number of bits spent on signaling of motion information since only one index value (i.e., merge_idx) needs to be signaled.
  • an encoder may choose to encode a block in the merge mode since the merge method gives the smaller RD cost than the explicit motion information signaling method, even though the derived (i.e., inherited) motion information from neighboring inter blocks does not suit well for the current block.
  • the downside of providing relatively poor fit the benefit of substantial cheaper signaling cost may outweigh the downside. But it would be still good to improve fit without spending more bits.
  • VVC includes a tool called DMVR to further refine MVs for blocks coded in the merge mode with bi-predictive MVs. DMVR may improve the fit without spending more bits.
  • the DMVR refines the MVs on a subblock basis.
  • the min( , ) function here takes the minimum of the two input values of the function.
  • the DMVR then carries out MV refinement for each subblock having the size of sbW x sbH.
  • FIG.5 shows a 32x32 block and four 16x16 subblocks corresponding to the 32x32 block.
  • the initial MVs i.e., the MVs to be refined
  • the initial MVs for the current block are assumed to be MV0 and MV1.
  • the positions associated with the initial MVs are marked as squares in the reference pictures 0 and 1, and positions associated with a search window are marked as circles. Each circle may represent an offset MVoffset with respect to the initial MV position.
  • This hollow circle corresponds to a new motion vector MV0’ which may be equal to MV0 + MVoffset.
  • a mirroring rule is followed for deriving the new motion vector MV1’ which may be equal to MV1 – Mvoffset.
  • any points inside the search window may result in a new MV pair (MV0’, MV1’):
  • the maximum x or y component for ⁇ ⁇ ⁇ ⁇ ⁇ ⁇ ⁇ ⁇ is set to be 2 integer samples.
  • DMVR searches all MVoffsets within the search window and finds the MVoffset that gives the smallest difference between the L0 reference block and the L1 reference block.
  • the refined MVs (derived from the best MVoffset) may be used to generate prediction samples for the current block.
  • FIG.7 shows an example of initial MVs, MVoffsets, and refined MVs.
  • VVC there is no block level flag explicitly signaled for turning on/off DMVR. In other words, when the initial MVs are bi-predictive and some other conditions are met, the DMVR is applied even without explicit signaling.
  • a list of conditions for determining whether DMVR is applicable for a current block is found in B. Bross, J. Chen, S. Liu, Y.-K. Wang “Versatile Video Coding (Draft 10),” Document number JVET-S2001-vH. Teleconference, July 2020.
  • MVs are bi-predictive MVs
  • the block has more than 64 samples
  • iii) the height of the block and the width of the block are larger than or equal to 8 samples
  • the bi-predictive MVs point to one reference picture before the current picture in display order and another reference picture after the current picture in the display order
  • v) the distances from the two reference pictures to the current picture are the same
  • both reference pictures are short-term reference pictures
  • bi-prediction with CU-level weights (BCW) weight index uses equal weights
  • viii) weighted prediction is not enabled for the block
  • ix) combined intra-inter prediction mode is not enabled for the block.
  • RPR Reference picture resampling
  • VVC VVC tool
  • RPR is a VVC tool that can be used to enable switching between different resolutions in a video bitstream without encoding a startup of a new sequence with an intra picture. This gives more flexibility to adapt resolution to control bitrate which can be of used in for example video conferencing or adaptive streaming.
  • RPR can make use of previously encoded pictures of lower or higher resolution than the current picture to be encoded by re-scaling them to the resolution of the current picture as part of inter prediction of the current picture.
  • SUMMARY Certain challenges presently exist. For example, the existing DMVR scheme refines the MV for each subblock independently, and this may introduce inconsistencies to the refined MVs among the subblocks.
  • inconsistency may be a large MV difference or large MV variation.
  • the refined MVs for two adjacent subblocks could have a difference of 4 integer samples in x or y component.
  • Such a large difference is very likely to result in noticeable subblock boundaries in the reconstructed pictures and lead to worse subjective quality.
  • a method for encoding a picture includes obtaining a first candidate motion vector (MV) for a current block of the picture.
  • the method also includes determining that a criteria is satisfied, and, as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block.
  • Determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block and 2) determining that a first criterion is satisfied.
  • a computer program comprising instructions which when executed by processing circuitry of an apparatus causes the apparatus to perform any of the methods disclosed herein.
  • a carrier containing the computer program wherein the carrier is one of an electronic signal, an optical signal, a radio signal, and a computer readable storage medium.
  • an apparatus that is configured to perform the methods disclosed herein.
  • the apparatus may include memory and processing circuitry coupled to the memory.
  • FIG.1 shows an example of a motion vector (MV).
  • FIG.2 illustrates uni-inter prediction and bi-inter prediction.
  • FIG.3 shows an example of a four layer B-GOP structure.
  • FIG.4 shows possible spatial blocks for fetching neighboring motion information.
  • FIG.5 shows an example of a block and subblocks.
  • FIG.6 shows an example of initial MVs and a search window.
  • FIG.7 shows an example of initial MVs, MVoffsets, and refined MVs.
  • FIG.8 illustrates a system according to some embodiments.
  • FIG.9 shows an example of a problematic area in a reconstructed picture.
  • FIG.10 shows an example of an improved area in a reconstructed picture.
  • FIG.11 shows a process according to some embodiments.
  • FIG.12 shows an apparatus according to some embodiments.
  • FIG.8 illustrates a system 800 according to an embodiment.
  • System 800 includes an encoder 802 and a decoder 804, wherein encoder 802 is in communication with decoder 804 via a network 110 (e.g., the Internet or other network).
  • Encoder 802 encodes a source video sequence 801 (e.g., encodes blocks of units of pictures of video sequence 801) into a bitstream comprising an encoded video sequence (e.g., encoded blocks) and transmits the bitstream to decoder 804 via network 808.
  • a source video sequence 801 e.g., encodes blocks of units of pictures of video sequence 801
  • bitstream comprising an encoded video sequence (e.g., encoded blocks)
  • encoder 802 is not in communication with decoder 804, and, in such an embodiment, rather than transmitting bitstream to decoder 804, the bitstream is stored in a data storage unit for later use.
  • Decoder 804 decodes the pictures included in the encoded video sequence to produce video data for display and/or for further image processing (e.g. a machine vision task). Accordingly, decoder 804 may be part of a device 803 having an image processor 805 and/or a display 806. The image processor 805 may perform machine vision tasks on the decoded pictures.
  • the device 803 may be a mobile device, a set-top device, a head-mounted display, or any other device.
  • FIG.9 shows an example of a problematic area 902 from a reconstructed picture coded with VTM-11 (the VVC reference software) encoder.
  • the area 902 corresponds to a block with DMVR applied.
  • the subblock boundaries can be clearly seen.
  • this disclosure provides an encoder wherein, for a current block to be encoded, the encoder determines whether the current block is likely to suffer from a DMVR subjective problem, and, if so, the encoder to chooses another pair of motion vectors or other modes to avoid applying DMVR to the current block.
  • FIG.10 shows area 1002 corresponding to area 902. The area 1002 is encoded using the method according to the embodiments of this disclosure. Thus, in FIG.10, the subblock boundaries shown in the area 902 are removed.
  • Embodiments of this disclosure provide a method for selectively applying a subblock-based motion refinement (e.g., DMVR in VVC).
  • subblock-based means that the motion refinement is carried out on a subblock basis (i.e., a grid of samples having a size that is smaller than the size of a block).
  • the method may be performed by encoder 802.
  • DMVR is one type of subblock-based motion refinements, for simple explanation, DMVR and subblock-based motion refinement are used in this disclosure interchangeably.
  • encoder 102 determines whether a reference subblock of a first subblock (e.g., a subblock immediately above the first subblock or a subblock immediately to the left of the first subblock) has low spatial activity.
  • the DMVR refined MVs of the first subblock and the refined MVs from the corresponding reference subblock are further compared. Also, the top subblock boundary samples of the first subblock are compared with the bottom samples of the above subblock and the left subblock boundary samples are compared with the right most samples of the left subblock.
  • the proposed method restricts the encoder to not code the current block with the initial MVs to avoid triggering DMVR being enabled. The motivation is that for low spatial activity subblocks (usually corresponds to smooth areas), the inconsistent MVs among subblocks may lead to visible subblock boundaries.
  • the method can be used for all but the highest temporal layer where DMVR can be used unrestricted.
  • the reason for allowing DMVR in the highest temporal layer is that it is easier for DMVR to find a good motion and when it does not find a good motion, any visual artifact does not propagate to other pictures since highest temporal layers are not used for prediction of other pictures.
  • Process for selectively triggering DMVR For encoding a current block of a current picture of a video sequence, an encoder may implement a process 1100 (see FIG.11) for selectively triggering DMVR for the current block.
  • the process may evaluate whether to encode the current block with a first candidate MV (e.g., MV0).
  • a first candidate MV e.g., MV0
  • the first candidate MV may be obtained using the merge process. If the encoder decides not to encode the current block with the first candidate MV candidate, DMVR is not triggered. On the other hand, if the encoder decides to encode the current block with the first candidate MV candidate, DMVR may be triggered. By deciding not to encode the current block with the first candidate MV, DMVR is not triggered. [0077] One way of not letting the encoder to encode the current block with the first candidate MV is to set the associated RD cost of the first candidate MV to be the maximum allowed value.
  • FIG.11 is a flowchart illustrating process 1100 for encoding a picture according to some embodiments.
  • the process 1100 may begin with step s1102.
  • Step s1102 comprises obtaining a first candidate motion vector (MV) for a current block of the picture.
  • Step s1104 comprises determining that a criteria is satisfied.
  • Step s1106 comprises, as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block.
  • Determining that the criteria is satisfied comprises: determining that a subblock-based motion refinement is applicable for the current block (s1110) and determining that a first criterion is satisfied (s1112). [0079] In one embodiment, determining that the first criterion is satisfied comprises: for a first subblock of the current block, obtaining a predicted first subblock using a first refined MV for the first subblock; for a second subblock of the current block, obtaining a predicted second subblock using a second refined motion vector for the second subblock; calculating a boundary activity value (Ba) using samples within the predicted first subblock and samples within the predicted second subblock; and determining that Ba satisfies a condition (e.g., Ba is greater than or equal to a threshold boundary activity value (Th3)).
  • a condition e.g., Ba is greater than or equal to a threshold boundary activity value (Th3)
  • the “first” subblock of the current block may be any one of the subblocks of the current block.
  • the term “first” is just a label to distinguish one subblock within a current block from the other subblocks within the current and does not imply any ordering.
  • the term “refined MV” can correspond to two MVs in case of bi-prediction. [0080]
  • the boundary activity is computed across at least one subblock boundary for at least one sample inside the subblock and one sample outside the subblock but adjacent to it.
  • the boundary activity is determined from at least one of: the above subblock boundary (Ba_above), the left subblock boundary (Ba_left), the bottom subblock boundary (Ba_below), and/or the right subblock boundary (Ba_right) of the first subblock.
  • the first criterion is determined to be fulfilled when the boundary activity Ba (Ba_left, Ba_above, Ba_right, and/or Ba_bottom) is greater than a threshold value (Th3).
  • the first criterion determines if the first subblock has boundary artifacts.
  • ⁇ ⁇ , ⁇ be the samples of a prediction block generated using the first subblock and a refined motion vector rMV1
  • ⁇ ⁇ , ⁇ be samples of a prediction block generated using second subblock and a refined motion vector rMV2.
  • Th3 is 10 (when encoding in 10-bits, samples 0 to 1023). For 8 bits encoding an example setting for Th3 is 10/4. For 12 bits encoding and example setting for Th3 is 10*4.
  • the threshold Th3 may be reduced.
  • One example threshold in this case is 5 (when encoding in 10-bits, samples 0 to 1023). The reason for using a lower threshold when the resolution of a picture is reduced compared to the full resolution is that the picture becomes smoother.
  • An alternative setting is to reduce the threshold Th3 when encoding in a reduced resolution compared to the full resolution by for example RPR.
  • the first criterion is fulfilled when: 1) the boundary activity for at least one of the above subblock boundary is greater than the threshold Th3, 2) the boundary activity for the above subblock boundary and/or the boundary activity for the left subblock boundary is greater than the threshold Th3, 3) the boundary activity for the left subblock boundary and/or the boundary activity for the bottom subblock boundary is greater than the threshold Th3, and 4) the boundary activity for the bottom subblock boundary and/or the boundary activity for the right subblock boundary is greater than the threshold Th3.
  • determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: 1) determining a first spatial activity (SA) value, Sa1, using the first subblock and 2) comparing Sa1 to an SA threshold (denoted THsa) (e.g., to determine whether Sa1 is less than or equal to the SA threshold).
  • SA spatial activity
  • THsa an SA threshold
  • determining that the second criterion is satisfied further comprises 1) determining a second SA value, Sa2, using a second subblock within the current block and 2) comparing Sa2 to the SA threshold or another SA threshold.
  • determining that the second criterion is satisfied further comprises determining that one or more subblocks neighboring the first subblock (e.g., the neighboring subblocks disposed above or at the left side of the first subblock) have low spatial activity.
  • the encoder may determine to refrain from encoding the current block with the first candidate MV.
  • Sa1 is an averaged spatial activity of at least some of the samples within the first subblock, or Sa1 is a variance of at least some of the samples within the first subblock.
  • the spatial activity value of the first subblock may be calculated based on the values of source samples inside the first subblock.
  • the spatial activity value of the first subblock may be calculated as an average of the spatial activity values of a plurality of samples (e.g., all samples) inside the subblock.
  • the spatial activity value ⁇ ⁇ ⁇ ⁇ , ⁇ of the current sample may be calculated as an averaged absolute sample value difference between the current sample and its one or more neighboring samples (e.g., the neighboring sample(s) located above or at the left side of the current sample).
  • the spatial activity values of the first row and first column of samples in the first subblock may be excluded when calculating the spatial activity value of the first subblock.
  • the values of predicted samples may be used to calculate the spatial activity value of a sample inside the first subblock.
  • the use of a refined motion vector corresponds to generate predicted samples of the subblock according to at least one of the refined MVs in case of bi-prediction.
  • the spatial activity values of samples inside subblocks neighboring the first subblock may be calculated from the predicted samples obtained by using the refined motion vectors rMV above and rMV left .
  • predicted samples obtained from non-refined motion vectors may be used to calculate the spatial activity values.
  • non-refined motion corresponds to generate samples of the subblock according to at least one of the MVs of the bi-MV.
  • the spatial activity values of samples inside subblocks neighboring the first subblock may be calculated from the predicted samples obtained by using the unrefined motion vector MV.
  • the spatial activity threshold THsa may depend on the quantization parameter (QP) of the current block.
  • QP quantization parameter
  • THsa may be a function of QP.
  • the function used to derive THsa may be a polynomial function of QP.
  • the function used to derive THsa from QP may be implemented as a look-up table.
  • QP is the input entry to the look-up table
  • THsa is the stored look-up value in the look-up table.
  • the table below is an example of the look-up table.
  • the spatial activity threshold THsa may depend on QP of the current slice instead of QP of the current block.
  • THsa may depend on the hierarchy level of the current picture. In such embodiment, pictures with higher hierarchy levels may result in higher THsa.
  • the above described second criterion is the first criterion.
  • Additional Criterion for not Triggering DMVR determining whether to encode the current block with the first candidate MV may further depend on whether an additional criterion (“third criterion”) that is related to refined MV(s) of subblock(s) included in the current block is satisfied.
  • determining that the criteria is satisfied further comprises determining that a third criterion is satisfied, and determining that the third criterion is satisfied comprises: [0110] (1) deriving a first refined MV using the candidate MV and the first subblock; [0111] (2) deriving a second refined MV using the candidate MV and a second subblock within the current block; [0112] (3) calculating a difference between the first refined MV and the second refined MV; and [0113] (4) comparing the difference to a value T1.
  • the above steps are performed only if the encoder determines that i) a subblock-based motion refinement is applicable for the candidate MV, ii) the first criterion is satisfied, and iii) the second criterion is satisfied. In other embodiments, the above steps are preformed prior to determining that a subblock-based motion refinement is applicable for the candidate MV and/or prior to determining that the first criterion is satisfied and/or prior to determining that the second criterion is satisfied.
  • the third criterion may be determined to be satisfied if the absolute difference between the first subblock’s refined MV (mvC) and the neighboring subblock’s refined MV is not smaller than a threshold Th2.
  • mvA is the refined MV from the above neighboring subblock
  • mvL is the refined MV from the left neighboring subblock
  • the third criterion may be determined to be satisfied.
  • the above described third criterion is the first criterion.
  • Block Size Threshold [0120]
  • the method of selectively triggering DMVR may be enabled only for blocks having a certain size. For example, process 1100 is performed only if the current block has a size that is not smaller than 64 x 64.
  • QP Threshold [0122] In some embodiments, process 1100 is performed only for blocks with QPs that are above (or equal to) a certain QP threshold (e.g., 41). In other words, the method may be inactivated when a block has a QP that is lower than the QP threshold.
  • the method may be enabled for blocks that are within a slice having a QP above a certain QP threshold or within a picture having a QP above a certain QP threshold.
  • Temporal Layer DMVR is only enabled for the highest temporal layers. In this case it is more likely that DMVR can find a good motion since pictures are closer and any potential DMVR artifact has limited propagation to other frames.
  • a preferred setting is to only enable DMVR for the highest temporal layer. In this case any potential DMVR artifact cannot propagate to other frames. This can in VVC be achieved by setting the DmvrDisabledFlag in the picture header for a picture in a lower temporal layer than the highest temporal layer to true.
  • the criteria for deciding whether to refrain from using the first candidate MV includes a temporal layer criterion. For example, if the picture is in layer N or above, where N is a configurable value, then the criteria will not be satisfied, otherwise the criteria may be satisfied depending on the other criterions. In some embodiments, N may be set to the highest layer.
  • FIG.12 is a block diagram of an apparatus 1200 for implementing encoder 802 and/or decoder 804, according to some embodiments.
  • apparatus 1200 may be referred to as an encoder apparatus, and when apparatus 1200 implements decoder 804, apparatus 1200 may be referred to as a decoder apparatus.
  • apparatus 1200 may comprise: processing circuitry (PC) 1202, which may include one or more processors (P) 1255 (e.g., one or more general purpose microprocessors and/or one or more other processors, such as an application specific integrated circuit (ASIC), field-programmable gate arrays (FPGAs), and the like), which processors may be co-located in a single housing or in a single data center or may be geographically distributed (i.e., encoder apparatus 1200 may be a distributed computing apparatus); at least one network interface 1248 (e.g., a physical interface or air interface) comprising a transmitter (Tx) 1245 and a receiver (Rx) 1247 for enabling apparatus 1200 to transmit data to and receive data from other nodes connected to a network 110 (e.g., an Internet Protocol (IP) network) to which network interface 1248 is connected (physically or wirelessly) (e.g., network interface 1248 may be coupled to an antenna arrangement comprising one or more antennas for enabling encoder
  • PC processing circuitry
  • a computer readable storage medium 1242 may be provided.
  • CRSM 1242 may store a computer program (CP) 1243 comprising computer readable instructions (CRI) 1244.
  • CP computer program
  • CRSM 1242 may be a non-transitory computer readable medium, such as, magnetic media (e.g., a hard disk), optical media, memory devices (e.g., random access memory, flash memory), and the like.
  • the CRI 1244 of computer program 1243 is configured such that when executed by PC 1202, the CRI causes encoder apparatus 1200 to perform steps described herein (e.g., steps described herein with reference to the flow charts).
  • encoder apparatus 1200 may be configured to perform steps described herein without the need for code. That is, for example, PC 1202 may consist merely of one or more ASICs. Hence, the features of the embodiments described herein may be implemented in hardware and/or software. [0128] Summary of Various Embodiments A1.
  • a method (1000) for encoding a picture comprising: obtaining (s1002) a first candidate motion vector, MV, for a current block of the picture; determining (s1004) that a criteria is satisfied; and as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block (s1006), wherein determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block; and 2) determining that a first criterion is satisfied.
  • determining that the first criterion is satisfied comprises: for a first subblock of the current block, obtaining a predicted first subblock based on a first refined MV for the first subblock; for a second subblock of the current block, obtaining a predicted second subblock using a second refined motion vector for the second subblock; calculating a boundary activity value, Ba, using samples within the predicted first subblock and samples within the predicted second subblock; and determining that Ba satisfies a condition (e.g., Ba is greater than or equal to a threshold boundary activity value).
  • a condition e.g., Ba is greater than or equal to a threshold boundary activity value
  • determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: determining a first spatial activity (SA) value, Sa1, using the first subblock; and comparing Sa1 to an Sa threshold (e.g., to determine whether Sa1 is less than or equal to the Sa threshold).
  • SA spatial activity
  • determining that the second criterion is satisfied further comprises: determining a second SA value, Sa2, using a second subblock within the current block; and comparing Sa2 to the Sa threshold or another Sa threshold.
  • determining that the criteria is satisfied further comprises determining that a third criterion is satisfied, and determining that the third criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1.
  • determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1.
  • the predicted first subblock comprises a first sample value, s11, and a second sample value, s12; the predicted second subblock comprises a third sample value, s21, and a fourth sample value, s22; calculating a boundary activity value, Ba, using samples within the predicted first subblock and samples within the predicted second subblock comprises calculating: (
  • determining that the first criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1.
  • determining that the first criterion is satisfied comprises: determining a spatial activity value, Sa, for the first subblock; and comparing Sa to an Sa threshold (e.g., to determine whether Sa is less than or equal to the Sa threshold).
  • determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises determining that the picture is not in a highest temporal layer.
  • determining Sa1 using the first subblock comprises: obtaining a predicted first subblock for the first subblock using the first candidate motion vector; and determining Sa1 using the predicted first subblock.
  • a computer program (1243) comprising instructions (1244) which when executed by processing circuitry (1202) cause the processing circuitry (1202) to perform the method of any one of the above embodiments.
  • An apparatus (1200) for encoding a picture the apparatus configured to perform a method comprising: obtaining (s1002) a first candidate motion vector, MV, for a current block of the picture; determining (s1004) that a criteria is satisfied; and as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block (s1006), wherein determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block; and 2) determining that a first criterion is satisfied.
  • An apparatus (1200), the apparatus comprising: a memory (1242); and processing circuitry (1202) coupled to the memory (1242), wherein the apparatus (1200) is configured to perform the method of any one of embodiments A1-A12.

Landscapes

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

Abstract

There is provided a method for encoding a picture. The method comprises obtaining a first candidate motion vector, MV, for a current block of the picture. The method comprises determining that a criteria is satisfied. The method comprises, as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block, wherein determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block; and 2) determining that a first criterion is satisfied.

Description

ENCODER FOR ENCODING PICTURES OF A VIDEO TECHNICAL FIELD [0001] This disclosure relates to methods and apparatus for encoding pictures of a video. BACKGROUND [0002] Videos and Pictures [0003] A video (a.k.a., video sequence) consists of a series of pictures (a.k.a., images) wherein each picture consists of one or more components. In Versatile Video Coding (VVC), each picture is identified with a picture order count (POC) value. [0004] Components [0005] Each component of a picture can be described as a two-dimensional rectangular array of sample values (or “samples” for short). It is common that a picture in a video sequence consists of three components: one luma component (Y) where the sample values are luma values and two chroma components (Cb and Cr) where the sample values are chroma values. It is also common that the dimensions of the chroma components are smaller than the luma components by a factor of two in each dimension. For example, the size of the luma component of a high- definition (HD) picture can be 1920x1080 while the chroma components may each have the dimension of 960x540. Components are sometimes referred to as color components. [0006] Coding Unit and Coding Block [0007] Typically, each component is split into many blocks and a coded video (a.k.a., video bitstream) comprises of a series of coded blocks. It is common in video coding that the picture is split into units that cover a specific area of the picture. [0008] Each unit consists of all blocks from all components that make up that specific area and each block belongs fully to one unit. The macroblock in H.264 and the Coding unit (CU) in High Efficiency Video Coding (HEVC) are examples of units. In Versatile Video Coding (VVC), the CUs may be split recursively to smaller CUs. The CU at the top level is referred to as coding tree unit (CTU). [0009] A CU usually contains three coding blocks -- i.e., one coding block for luma and two coding blocks for chroma. The size of the luma coding block is the same as the CU. In the current VVC (i.e., version 1), the CUs can have the size of 4x4 up to 128x128. [0010] Intra prediction [0011] In intra prediction (also known as spatial prediction), a block is predicted using previously decoded blocks within the same picture. In other words, samples inside the previously decoded blocks within the same picture are used to predict the samples inside the current block. A picture consisting of only intra-predicted blocks is referred to as an intra picture. [0012] Inter prediction [0013] In inter prediction (also known as temporal prediction), blocks of the current picture are predicted using blocks of previously decoded pictures. In other words, the samples from the blocks of the previously decoded pictures are used to predict the samples of the current block. [0014] A picture that allows inter-predicted block is referred to as an inter picture. The previously decoded pictures used for inter prediction are referred to as reference pictures. [0015] The location of the referenced block inside the reference picture is indicated using a motion vector (MV). Each MV consists of x and y components each of which represents a displacement between current block and the referenced block in x or y dimension. The value of a component may have a resolution finer than an integer position. When that is the case, a filtering (typically interpolation) is done to calculate values used for prediction. FIG.1 shows an example of a MV for current block C. The MV = (2,1) indicates that the position of reference block is two steps to the right and one step down from the position of the current block C. [0016] An inter picture may use several reference pictures. The reference pictures are usually put into two reference picture lists, L0 and L1. The reference pictures that are output before the current picture are typically the first pictures in L0. The reference pictures that are output after the current picture are typically the first pictures in L1. [0017] Inter predicted blocks can use one of two prediction types: uni-prediction and bi- prediction. Uni-predicted block may be predicted from one reference picture, either using L0 or L1. Bi-predicted block may be predicted from two reference pictures, one from L0 and the other from L1. FIG.2 shows an example of the prediction types. [0018] Residual, transform, and quantization [0019] Typically, for each block, a residual block is produced where the residual block is the difference between samples of a source block (which contains original samples) and samples of a prediction block. The residual block is then typically compressed by a spatial transform which produces transform coefficients. To control the fidelity of the residual block and also the bitrate required to compress the block, the transform coefficients of the spatial transform are quantized by a quantization parameter (QP) to produce quantized transform coefficients. A coded block flag (CBF) is used to indicate if there are any non-zero quantized transform coefficients. All coding parameters, including the quantized transform coefficients, are then entropy coded at the encoder and decoded at the decoder. A reconstructed block can then be derived by inverse quantization and inverse transformation of the quantized transform coefficients (assuming the CBF is one) to produce a reconstructed residual block (or “reconstructed block” for short). The reconstructed block is then added to a prediction block to produce a block corresponding to the source block. [0020] Hierarchical picture coding structure [0021] In what is often referred to as “random access configuration,” intra coded pictures are positioned with a fixed interval (e.g., every second). Pictures between the intra coded pictures are typically coded with a B-GOP structure as shown in FIG.3. FIG.3 shows an example of a four-layer B-GOP structure using two reference pictures per a picture. Picture 0 is coded first and then picture 8 is coded using picture 0 as its reference picture. Then picture 8 and picture 0 are used as reference pictures to code picture 4. Then similarly, picture 2 and picture 6 are coded using pictures 0, 4, and 8. Then, pictures 1, 3, 5 and 7 are coded using pictures 1, 2, 4, 6, and 8. [0022] Pictures 1, 3, 5, and 7 are referred to be on the highest hierarchical level, pictures 2 and 6 are referred to be on the second highest hierarchical level, picture 4 is referred to be on third highest level, and picture 8 is referred to be on the lowest level. Typically pictures 1, 3, 5, and 7 are not used for reference of any other pictures. They are called non-reference pictures. [0023] The assigned QPs for the pictures are usually different and are set according to the hierarchy level. Higher QP is assigned for picture(s) that at higher hierarchy level. [0024] Inter prediction / Motion information [0025] Inter prediction information of an inter coded block in an inter coded picture in VVC may consist of the following three elements: [0026] 1. A reference picture list flag (RefPicListFlag). The flag signals which reference picture list is used. When the value of the flag is equal to 0, it means L0 is used. When the value of the flag is equal to 1, it means L1 is used. When the value of the flag is equal to 2, it means both L0 and L1 are used. [0027] 2. A reference picture index (RefPicIdx) per reference picture list used. The index signals which reference picture inside the reference picture list is used. [0028] 3. A motion vector (MV) per reference picture used. The MV signals the position inside the reference picture that is used for predicting the current block. [0029] The inter prediction information is also referred to as motion information. The decoder stores the motion information for each inter coded block. In other words, an inter coded block maintains its own motion information. [0030] Encoder decision and Rate Distortion (RD) cost [0031] In order for an encoder to decide the best prediction mode for a current block, the encoder will evaluate many or all of the possible prediction modes for the current block and select the prediction mode that yields the smallest Rate-Distortion (RD) cost. [0032] The RD cost may be calculated as ^^ + ^^ ∗ ^^. The D (Distortion) measures the difference between the reconstructed block and the corresponding source block. One commonly used metric for calculating D is the sum of squared difference ^^ ^^ ^^ = ௫,௬ ( ^^^( ^^, ^^) − ^^^( ^^, ^^)) , where ^^^ and ^^^ are the sample values in two blocks A and B respectively. The R (Rate) is usually an estimation of the number of bits to be spent for encoding in the mode. The ^^ is a trade-off parameter between R and D. [0033] Motion information signaling [0034] VVC includes several methods of implicitly signaling motion information for each block, including the merge method and the subblock merge method. A common motivation behind the implicit methods is to inherit motion information from neighboring coded blocks. [0035] Merge (a.k.a., block merge) method [0036] The merge method is similar to the one in the HEVC standard. The method is sometimes referred to as block merge method since the derived motion information is used for generating the samples of the entire block. [0037] The method first generates a list of motion information candidates. The list is also referred to as merge list. The candidates are derived from previously coded blocks. The blocks can be spatially adjacent neighboring blocks (neighboring the current block) or temporal collocated blocks relative to the current block. FIG.4 shows possible spatial blocks for fetching neighboring motion information -- the spatial neighboring blocks: left (L), top(T), top-right(TR), left-bottom (LB), and top-left (TL). [0038] After the merge list is generated, one of the candidates inside the list is used to derive the motion information of the current block. The candidate selection process is done on the encoder side. An encoder may select a best candidate from the list and encode an index (merge_index) in the bitstream to signal to a decoder. The decoder receives the index, follows the same merge list derivation process as the encoder, uses the index to retrieve the correct candidate. [0039] Explicit motion information signaling [0040] VVC also includes explicit motion information signaling methods such as alternative motion vector prediction (AMVP). For a current inter coded block that is coded with AMVP, its number of reference pictures, reference picture indices, and associated motion vectors are explicitly signaled and encoded into the bitstream. [0041] In general, the block merge method is a cheaper alternative compared to the explicit motion information signaling method in terms of number of bits spent on signaling of motion information since only one index value (i.e., merge_idx) needs to be signaled. When encoding an inter block, an encoder may choose to encode a block in the merge mode since the merge method gives the smaller RD cost than the explicit motion information signaling method, even though the derived (i.e., inherited) motion information from neighboring inter blocks does not suit well for the current block. Despite the downside of providing relatively poor fit, the benefit of substantial cheaper signaling cost may outweigh the downside. But it would be still good to improve fit without spending more bits. [0042] Decoder side motion vector refinement (DMVR) [0043] VVC includes a tool called DMVR to further refine MVs for blocks coded in the merge mode with bi-predictive MVs. DMVR may improve the fit without spending more bits. [0044] The DMVR refines the MVs on a subblock basis. A first step of the DMVR is to split a current block into a group of subblocks. For example, if a current inter block has width = W and height = H, the width sbW of each sub-block may be min(W, 16). Similarly, the height sbH of each subblock may be min(H, 16). The min( , ) function here takes the minimum of the two input values of the function. The DMVR then carries out MV refinement for each subblock having the size of sbW x sbH. FIG.5 shows a 32x32 block and four 16x16 subblocks corresponding to the 32x32 block. [0045] The initial MVs (i.e., the MVs to be refined) are derived using the merge method. As shown in FIG.6, the initial MVs for the current block are assumed to be MV0 and MV1. In FIG.6, the positions associated with the initial MVs are marked as squares in the reference pictures 0 and 1, and positions associated with a search window are marked as circles. Each circle may represent an offset MVoffset with respect to the initial MV position. For example, the hollow circle corresponds to an MVoffset = (-1, 1) with respect to the initial position of MV0 (the square in the reference picture 0). This hollow circle corresponds to a new motion vector MV0’ which may be equal to MV0 + MVoffset. A mirroring rule is followed for deriving the new motion vector MV1’ which may be equal to MV1 – Mvoffset. [0046] In other words, any points inside the search window may result in a new MV pair (MV0’, MV1’): ^^ ^^0′ = ^^ ^^0 + ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^1′ = ^^ ^^1 − ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^, where ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ represents the offset between the initial MV and the refined MV in one of the reference pictures. In VVC, the maximum x or y component for ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^ is set to be 2 integer samples. [0047] DMVR searches all MVoffsets within the search window and finds the MVoffset that gives the smallest difference between the L0 reference block and the L1 reference block. The difference is calculated as the sum of absolute difference (SAD) between a sample value within the L0 reference block and a sample value within the L1 reference block, i.e. ^^ ^^ ^^ = ∑ ௫,௬ | ^^0( ^^, ^^) − ^^1( ^^, ^^)| , where P0 and P1 are the sample values within the L0 and L1 blocks. [0048] Then, the refined MVs (derived from the best MVoffset) may be used to generate prediction samples for the current block. FIG.7 shows an example of initial MVs, MVoffsets, and refined MVs. [0049] In VVC, there is no block level flag explicitly signaled for turning on/off DMVR. In other words, when the initial MVs are bi-predictive and some other conditions are met, the DMVR is applied even without explicit signaling. [0050] A list of conditions for determining whether DMVR is applicable for a current block is found in B. Bross, J. Chen, S. Liu, Y.-K. Wang “Versatile Video Coding (Draft 10),” Document number JVET-S2001-vH. Teleconference, July 2020. Some of the conditions are as follows: i) the block is in the merge mode and the block’s MVs are bi-predictive MVs, ii) the block has more than 64 samples, iii) the height of the block and the width of the block are larger than or equal to 8 samples, iv) the bi-predictive MVs point to one reference picture before the current picture in display order and another reference picture after the current picture in the display order, v) the distances from the two reference pictures to the current picture are the same, vi) both reference pictures are short-term reference pictures, vii) bi-prediction with CU-level weights (BCW) weight index uses equal weights, viii) weighted prediction is not enabled for the block, ix) combined intra-inter prediction mode is not enabled for the block. [0051] Reference picture resampling (RPR) [0052] RPR is a VVC tool that can be used to enable switching between different resolutions in a video bitstream without encoding a startup of a new sequence with an intra picture. This gives more flexibility to adapt resolution to control bitrate which can be of used in for example video conferencing or adaptive streaming. RPR can make use of previously encoded pictures of lower or higher resolution than the current picture to be encoded by re-scaling them to the resolution of the current picture as part of inter prediction of the current picture. SUMMARY [0053] Certain challenges presently exist. For example, the existing DMVR scheme refines the MV for each subblock independently, and this may introduce inconsistencies to the refined MVs among the subblocks. For example, inconsistency may be a large MV difference or large MV variation. As an example, the refined MVs for two adjacent subblocks could have a difference of 4 integer samples in x or y component. Such a large difference is very likely to result in noticeable subblock boundaries in the reconstructed pictures and lead to worse subjective quality. [0054] Accordingly, in one aspect, there is provided a method for encoding a picture. The method includes obtaining a first candidate motion vector (MV) for a current block of the picture. The method also includes determining that a criteria is satisfied, and, as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block. Determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block and 2) determining that a first criterion is satisfied. [0055] In another aspect there is provided a computer program comprising instructions which when executed by processing circuitry of an apparatus causes the apparatus to perform any of the methods disclosed herein. In one embodiment, there is provided a carrier containing the computer program wherein the carrier is one of an electronic signal, an optical signal, a radio signal, and a computer readable storage medium. In another aspect there is provided an apparatus that is configured to perform the methods disclosed herein. The apparatus may include memory and processing circuitry coupled to the memory. [0056] An advantage of the embodiments disclosed herein is that they can avoid subjective problems for DMVR while providing objective performance compared to the VVC reference software for RA (random access configuration in VTM19). That is, most of the objective gain provided by DMVR can be obtained while avoiding subjective artifacts from DMVR. BRIEF DESCRIPTION OF THE DRAWINGS [0057] The accompanying drawings, which are incorporated herein and form part of the specification, illustrate various embodiments. [0058] FIG.1 shows an example of a motion vector (MV). [0059] FIG.2 illustrates uni-inter prediction and bi-inter prediction. [0060] FIG.3 shows an example of a four layer B-GOP structure. [0061] FIG.4 shows possible spatial blocks for fetching neighboring motion information. [0062] FIG.5 shows an example of a block and subblocks. [0063] FIG.6 shows an example of initial MVs and a search window. [0064] FIG.7 shows an example of initial MVs, MVoffsets, and refined MVs. [0065] FIG.8 illustrates a system according to some embodiments. [0066] FIG.9 shows an example of a problematic area in a reconstructed picture. [0067] FIG.10 shows an example of an improved area in a reconstructed picture. [0068] FIG.11 shows a process according to some embodiments. [0069] FIG.12 shows an apparatus according to some embodiments. DETAILED DESCRIPTION [0070] FIG.8 illustrates a system 800 according to an embodiment. System 800 includes an encoder 802 and a decoder 804, wherein encoder 802 is in communication with decoder 804 via a network 110 (e.g., the Internet or other network). Encoder 802 encodes a source video sequence 801 (e.g., encodes blocks of units of pictures of video sequence 801) into a bitstream comprising an encoded video sequence (e.g., encoded blocks) and transmits the bitstream to decoder 804 via network 808. In some embodiments, encoder 802 is not in communication with decoder 804, and, in such an embodiment, rather than transmitting bitstream to decoder 804, the bitstream is stored in a data storage unit for later use. Decoder 804 decodes the pictures included in the encoded video sequence to produce video data for display and/or for further image processing (e.g. a machine vision task). Accordingly, decoder 804 may be part of a device 803 having an image processor 805 and/or a display 806. The image processor 805 may perform machine vision tasks on the decoded pictures. The device 803 may be a mobile device, a set-top device, a head-mounted display, or any other device. [0071] As noted above, the existing DMVR scheme refines the MV for each subblock independently, and this may introduce inconsistencies to the refined MVs among the subblocks. FIG.9 shows an example of a problematic area 902 from a reconstructed picture coded with VTM-11 (the VVC reference software) encoder. The area 902 corresponds to a block with DMVR applied. In the block shown in FIG.9, the subblock boundaries can be clearly seen. [0072] Accordingly, this disclosure provides an encoder wherein, for a current block to be encoded, the encoder determines whether the current block is likely to suffer from a DMVR subjective problem, and, if so, the encoder to chooses another pair of motion vectors or other modes to avoid applying DMVR to the current block. FIG.10 shows area 1002 corresponding to area 902. The area 1002 is encoded using the method according to the embodiments of this disclosure. Thus, in FIG.10, the subblock boundaries shown in the area 902 are removed. [0073] Embodiments of this disclosure provide a method for selectively applying a subblock-based motion refinement (e.g., DMVR in VVC). The term “subblock-based” means that the motion refinement is carried out on a subblock basis (i.e., a grid of samples having a size that is smaller than the size of a block). The method may be performed by encoder 802. Even though DMVR is one type of subblock-based motion refinements, for simple explanation, DMVR and subblock-based motion refinement are used in this disclosure interchangeably. [0074] In one specific embodiment, when evaluating whether to code a current block with a pair of initial MVs, encoder 102 determines whether a reference subblock of a first subblock (e.g., a subblock immediately above the first subblock or a subblock immediately to the left of the first subblock) has low spatial activity. If so, the DMVR refined MVs of the first subblock and the refined MVs from the corresponding reference subblock are further compared. Also, the top subblock boundary samples of the first subblock are compared with the bottom samples of the above subblock and the left subblock boundary samples are compared with the right most samples of the left subblock. When the DMVR refined MV differences exceed a threshold and the subblock boundary samples differs more than a threshold, then the proposed method restricts the encoder to not code the current block with the initial MVs to avoid triggering DMVR being enabled. The motivation is that for low spatial activity subblocks (usually corresponds to smooth areas), the inconsistent MVs among subblocks may lead to visible subblock boundaries. To further reduce the overhead, the method can be used for all but the highest temporal layer where DMVR can be used unrestricted. The reason for allowing DMVR in the highest temporal layer is that it is easier for DMVR to find a good motion and when it does not find a good motion, any visual artifact does not propagate to other pictures since highest temporal layers are not used for prediction of other pictures. [0075] Process for selectively triggering DMVR [0076] For encoding a current block of a current picture of a video sequence, an encoder may implement a process 1100 (see FIG.11) for selectively triggering DMVR for the current block. To determine whether to trigger DMVR, the process may evaluate whether to encode the current block with a first candidate MV (e.g., MV0). As discussed above, the first candidate MV may be obtained using the merge process. If the encoder decides not to encode the current block with the first candidate MV candidate, DMVR is not triggered. On the other hand, if the encoder decides to encode the current block with the first candidate MV candidate, DMVR may be triggered. By deciding not to encode the current block with the first candidate MV, DMVR is not triggered. [0077] One way of not letting the encoder to encode the current block with the first candidate MV is to set the associated RD cost of the first candidate MV to be the maximum allowed value. For example, if the RD cost in the encoder is stored in a 16-bit unsigned variable, the associated RD cost may be set to (2^16 – 1). [0078] FIG.11 is a flowchart illustrating process 1100 for encoding a picture according to some embodiments. The process 1100 may begin with step s1102. Step s1102 comprises obtaining a first candidate motion vector (MV) for a current block of the picture. Step s1104 comprises determining that a criteria is satisfied. Step s1106 comprises, as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block. Determining that the criteria is satisfied comprises: determining that a subblock-based motion refinement is applicable for the current block (s1110) and determining that a first criterion is satisfied (s1112). [0079] In one embodiment, determining that the first criterion is satisfied comprises: for a first subblock of the current block, obtaining a predicted first subblock using a first refined MV for the first subblock; for a second subblock of the current block, obtaining a predicted second subblock using a second refined motion vector for the second subblock; calculating a boundary activity value (Ba) using samples within the predicted first subblock and samples within the predicted second subblock; and determining that Ba satisfies a condition (e.g., Ba is greater than or equal to a threshold boundary activity value (Th3)). It is noted that the “first” subblock of the current block may be any one of the subblocks of the current block. Hence, the term “first” is just a label to distinguish one subblock within a current block from the other subblocks within the current and does not imply any ordering. The term “refined MV” can correspond to two MVs in case of bi-prediction. [0080] The boundary activity is computed across at least one subblock boundary for at least one sample inside the subblock and one sample outside the subblock but adjacent to it. The boundary activity is determined from at least one of: the above subblock boundary (Ba_above), the left subblock boundary (Ba_left), the bottom subblock boundary (Ba_below), and/or the right subblock boundary (Ba_right) of the first subblock. In this embodiment, the first criterion is determined to be fulfilled when the boundary activity Ba (Ba_left, Ba_above, Ba_right, and/or Ba_bottom) is greater than a threshold value (Th3). In other words, the first criterion determines if the first subblock has boundary artifacts. [0081] Let ^^^,^ be the samples of a prediction block generated using the first subblock and a refined motion vector rMV1, and let ^^^,^ be samples of a prediction block generated using second subblock and a refined motion vector rMV2. For a subblock of size ^^ ^^ ^^, the left boundary activity ^^ ^^ ^^ ^^ ^^ ^^^ for the first subblock can be calculated as ^^ ^^ ^^ ^^ ^^ ^^^ = ൫| ^^^,^ − ^^ெି^,^|൯ where ^^ெି^,^ is the sample left of sample ^^^,^. The above boundary activity ^^ ^^ ^^ ^^ ^^ first subblock can be calculated as ^^ ^^ ^^ ^^ ^^ ^^ ^^^ = ൫| ^^^,^ − ^^^,ேି^|൯ where ^^^,ேି^ is the sample above of sample ^^^,^. The right boundary activity ^^ ^^ ^^ ^^ ^^ℎ ^^^ for the first subblock can be calculated as ^^ ^^ ^^ ^^ ^^ℎ ^^^ = ൫| ^^^ି^,^ − ^^^,^|൯ where ^^^,^ is the sample right of sample ^^^ି^,^. The bottom boundary the first subblock can be calculated as ^^ ^^ ^^ ^^ ^^ ^^ ^^ ^^^ = ൫| ^^^,^ି^ − ^^^,^|൯ where ^^^,^ is the sample below of sample ^^^,^ି^. For a subblock of size ^^ ^^ ^^, the subblock boundary activity above can be measured as ^^ ^^_ ^^ ^^ ^^ ^^ ^^ = ( ^ఢெ, ^^ ^^ ^^ ^^ ^^ ^^ ^^^,) / ^^ , the subblock boundary activity left can be measured as ^^ ^^_ ^^ ^^ ^^ ^^ = ^^ ^^ ^^ ^^ ^^^) / ^^, the subblock boundary activity below can be measured as ^^ ^^_ ^^ ^^ ^^ ^^ ^^ = (∑^ఢெ, ^^ ^^ ^^ ^^ ^^ ^^ ^^^,) / ^^ and the subblock boundary activity right can be measured as ^^ ^^_ ^^ ^^ ^^ℎ ^^ = (∑^ఢே, ^^ ^^ ^^ ^^ ^^ℎ ^^^) / ^^. [0082] One example setting for Th3 is 10 (when encoding in 10-bits, samples 0 to 1023). For 8 bits encoding an example setting for Th3 is 10/4. For 12 bits encoding and example setting for Th3 is 10*4. When a picture is encoded in 1/2 reduced resolution in both dimensions compared to the full resolution by for example RPR the threshold Th3 may be reduced. One example threshold in this case is 5 (when encoding in 10-bits, samples 0 to 1023). The reason for using a lower threshold when the resolution of a picture is reduced compared to the full resolution is that the picture becomes smoother. An alternative setting is to reduce the threshold Th3 when encoding in a reduced resolution compared to the full resolution by for example RPR. [0083] In some embodiments, the first criterion is fulfilled when: 1) the boundary activity for at least one of the above subblock boundary is greater than the threshold Th3, 2) the boundary activity for the above subblock boundary and/or the boundary activity for the left subblock boundary is greater than the threshold Th3, 3) the boundary activity for the left subblock boundary and/or the boundary activity for the bottom subblock boundary is greater than the threshold Th3, and 4) the boundary activity for the bottom subblock boundary and/or the boundary activity for the right subblock boundary is greater than the threshold Th3. [0084] Second Criterion [0085] In some embodiments, determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: 1) determining a first spatial activity (SA) value, Sa1, using the first subblock and 2) comparing Sa1 to an SA threshold (denoted THsa) (e.g., to determine whether Sa1 is less than or equal to the SA threshold). In other words, the second criterion is determined to be satisfied if the first subblock is a low spatial activity subblock. [0086] In some embodiments, determining that the second criterion is satisfied further comprises 1) determining a second SA value, Sa2, using a second subblock within the current block and 2) comparing Sa2 to the SA threshold or another SA threshold. [0087] For example, determining that the second criterion is satisfied further comprises determining that one or more subblocks neighboring the first subblock (e.g., the neighboring subblocks disposed above or at the left side of the first subblock) have low spatial activity. In one embodiment, if the first subblock and all the neighboring subblock(s) are low-spatial activity subblocks, the encoder may determine to refrain from encoding the current block with the first candidate MV. [0088] In some embodiments, Sa1 is an averaged spatial activity of at least some of the samples within the first subblock, or Sa1 is a variance of at least some of the samples within the first subblock. [0089] As noted above, the spatial activity value of the first subblock may be calculated based on the values of source samples inside the first subblock. For example, in one embodiment, the spatial activity value of the first subblock may be calculated as an average of the spatial activity values of a plurality of samples (e.g., all samples) inside the subblock. [0090] There are different ways of calculating the spatial activity value of a sample inside the first subblock. For example, in case ^^^,^ denotes the value of a current sample of the original (i.e., uncompressed) picture at position (i, j) inside the first subblock, the spatial activity value ^^ ^^ ^^^,^ of the current sample may be calculated as an averaged absolute sample value difference between the current sample and its one or more neighboring samples (e.g., the neighboring sample(s) located above or at the left side of the current sample). [0091] More specifically, in one example, the spatial activity value of the current sample may be calculated as ^^ ^^ ^^^,^ = ൫| ^^^,^ − ^^^ି^,^| + | ^^^,^ − ^^^,^ି^|൯/2, where ^^^ି^,^ denotes the value of the and ^^^,^ି^ denotes the value of the neighboring sample above the current sample. [0092] Then if the first subblock has the size of ^^ × ^^ (where M is the number of samples in a column of the subblock and N is the number of samples in a row of the subblock), the spatial activity value of the first subblock may be calculated as ^^ ^^ = ( ^ఢெ,^ఢே ^^ ^^ ^^^,^) /( ^^ × ^^). [0093] In other embodiments, instead of calculating the spatial activity value of the first subblock as an average of the spatial activity values of all samples inside the first subblock, the spatial activity values of the first row and first column of samples in the first subblock may be excluded when calculating the spatial activity value of the first subblock. That is because the samples in the first row and/or the samples in the first column do not have any neighboring samples (from the same subblock) that are above or at the left side of the samples. In such embodiments, the spatial activity value of the first subblock may be calculated as ^^ ^^ = ( ^ఢெି^,^ఢேି^ ^^ ^^ ^^^,^) /(( ^^ − 1) × ( ^^ − 1)). activity value of the first subblock may be measured as the variance of the sample values inside the first subblock. [0095] In other embodiments, instead of using the values of the original (i.e., uncompressed) samples, the values of predicted samples may be used to calculate the spatial activity value of a sample inside the first subblock. [0096] In such embodiments, the spatial activity value ^^ ^^ ^^^,^ of a current sample at position (i, j) that is within the picture and inside the first subblock may be calculated as ^^ ^^ ^^^,^ = ൫| ^^^,^ − ^^^ି^,^| + | ^^^,^ − ^^^,^ି^|൯/2, where ^^^,^ is the value of the current sample that is obtained using a refined motion vector rMVcurr for the first subblock, and the refined motion vector rMVcurr is obtained using DMVR. The use of a refined motion vector corresponds to generate predicted samples of the subblock according to at least one of the refined MVs in case of bi-prediction. [0097] Similarly, the spatial activity values of samples inside subblocks neighboring the first subblock (e.g., the neighboring subblock that is disposed above the first subblock and the neighboring subblock that is disposed at the left side of the subblock) may be calculated from the predicted samples obtained by using the refined motion vectors rMVabove and rMVleft. [0098] In other embodiments, instead of using predicted samples obtained from the refined motion vectors to calculate the spatial activity values of the samples, predicted samples obtained from non-refined motion vectors may be used to calculate the spatial activity values. Before the refinement, all subblocks within the current block have the same motion vector (MV) as the current block. The use of non-refined motion here corresponds to generate samples of the subblock according to at least one of the MVs of the bi-MV. [0099] In such embodiments, the spatial activity value ^^ ^^ ^^^,^ of a current sample at position (i, j) th/at is within the picture and inside the first subblock may be calculated as ^^ ^^ ^^^,^ = ൫| ^^^,^ − ^^^ି^,^| + | ^^^,^ − ^^^,^ି^|൯/2, wherein ^^^,^ is the value of the current sample that is obtained using the unrefined motion vector MV, i.e., the motion vector of the current block. [0100] Similarly, the spatial activity values of samples inside subblocks neighboring the first subblock (e.g., the neighboring subblock that is disposed above the first subblock and the neighboring subblock that is disposed at the left side of the subblock) may be calculated from the predicted samples obtained by using the unrefined motion vector MV. [0101] Setting the SA Threshold (THsa) [0102] In one embodiment, the spatial activity threshold THsa may depend on the quantization parameter (QP) of the current block. In other words, THsa may be a function of QP. As QP increases, THsa may also increase. The function used to derive THsa may be a polynomial function of QP. For example, the function may be ^^ℎ1 = ^^( ^^ ^^) = ^^ + ^^ ∗ ^^ ^^ + ^^ ∗ ^^ ^^, where a = 0, b = 0.0667, and c = 0.0109. the function used to derive THsa from QP may be implemented as a look-up table. Here QP is the input entry to the look-up table and THsa is the stored look-up value in the look-up table. The table below is an example of the look-up table. QP 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 THsa 0 0 0 0 0 1 1 1 1 1 2 2 2 3 3 3 4 4 5 QP 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 THsa 5 6 6 7 7 8 9 9 10 10 11 12 13 13 14 15 16 17 18 QP 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 THsa 18 19 20 21 22 23 24 25 26 27 29 30 31 32 33 34 36 36 36 QP 57 58 59 60 61 62 63 THsa 36 37 37 37 37 37 37 [0104] In other embodiment, the spatial activity threshold THsa may depend on QP of the current slice instead of QP of the current block. [0105] In other embodiment, THsa may depend on the hierarchy level of the current picture. In such embodiment, pictures with higher hierarchy levels may result in higher THsa. [0106] In some embodiments, the above described second criterion is the first criterion. [0107] Additional Criterion for not Triggering DMVR [0108] In some embodiments, determining whether to encode the current block with the first candidate MV may further depend on whether an additional criterion (“third criterion”) that is related to refined MV(s) of subblock(s) included in the current block is satisfied. [0109] Accordingly, in some embodiments, determining that the criteria is satisfied further comprises determining that a third criterion is satisfied, and determining that the third criterion is satisfied comprises: [0110] (1) deriving a first refined MV using the candidate MV and the first subblock; [0111] (2) deriving a second refined MV using the candidate MV and a second subblock within the current block; [0112] (3) calculating a difference between the first refined MV and the second refined MV; and [0113] (4) comparing the difference to a value T1. [0114] In some embodiments, the above steps are performed only if the encoder determines that i) a subblock-based motion refinement is applicable for the candidate MV, ii) the first criterion is satisfied, and iii) the second criterion is satisfied. In other embodiments, the above steps are preformed prior to determining that a subblock-based motion refinement is applicable for the candidate MV and/or prior to determining that the first criterion is satisfied and/or prior to determining that the second criterion is satisfied. [0115] In some embodiments, the third criterion may be determined to be satisfied if the absolute difference between the first subblock’s refined MV (mvC) and the neighboring subblock’s refined MV is not smaller than a threshold Th2. [0116] For example, if mvA is the refined MV from the above neighboring subblock and mvL is the refined MV from the left neighboring subblock, then, when one of the following conditions is satisfied, the third criterion may be determined to be satisfied. | ^^ ^^ ^^. ^^ − ^^ ^^ ^^. ^^| ≥ ^^ℎ2 | ^^ ^^ ^^. ^^ − ^^ ^^ ^^. ^^| ≥ ^^ℎ2 | ^^ ^^ ^^. ^^ − ^^ ^^ ^^. ^^| ≥ ^^ℎ2 | ^^ ^^ ^^. ^^ − ^^ ^^ ^^. ^^| ≥ ^^ℎ2 [0117] In some embodiments, Th2 may have a precision of one sample (e.g., Th2 = 1 sample, 2 samples, …). In other embodiments, however, Th2 may have a precision of a fraction of one sample. For example, Th2 may have a precision of 1/16 sample and have a value of 24 (i.e., Th2 = 24/16 samples). In other embodiments, the Th2 equals to 28 in 1/16th sample precision (i.e.1 ¾ full sample). [0118] In some embodiments, the above described third criterion is the first criterion. [0119] Block Size Threshold [0120] In some embodiments, the method of selectively triggering DMVR may be enabled only for blocks having a certain size. For example, process 1100 is performed only if the current block has a size that is not smaller than 64 x 64. [0121] QP Threshold [0122] In some embodiments, process 1100 is performed only for blocks with QPs that are above (or equal to) a certain QP threshold (e.g., 41). In other words, the method may be inactivated when a block has a QP that is lower than the QP threshold. Alternatively, the method may be enabled for blocks that are within a slice having a QP above a certain QP threshold or within a picture having a QP above a certain QP threshold. [0123] Temporal Layer [0124] In one embodiment, DMVR is only enabled for the highest temporal layers. In this case it is more likely that DMVR can find a good motion since pictures are closer and any potential DMVR artifact has limited propagation to other frames. A preferred setting is to only enable DMVR for the highest temporal layer. In this case any potential DMVR artifact cannot propagate to other frames. This can in VVC be achieved by setting the DmvrDisabledFlag in the picture header for a picture in a lower temporal layer than the highest temporal layer to true. Then DMVR will not be used at that picture. When hierarchical GOP based coding of size 32, there are 6 temporal layers, then only the temporal layers 0 to 4 will not use DMVR but temporal layer 5 (every second picture in display order) will allow DMVR. [0125] Temporal Layer Criterion [0126] In another embodiment, the criteria for deciding whether to refrain from using the first candidate MV includes a temporal layer criterion. For example, if the picture is in layer N or above, where N is a configurable value, then the criteria will not be satisfied, otherwise the criteria may be satisfied depending on the other criterions. In some embodiments, N may be set to the highest layer. In some embodiments, when the frame rate is below a threshold (for example 50 Hz), then there is no temporal layer criterion (i.e., the criteria may be satisfied even if the picture belongs to the highest temporal layer). [0127] FIG.12 is a block diagram of an apparatus 1200 for implementing encoder 802 and/or decoder 804, according to some embodiments. When apparatus 1200 implements encoder 802, apparatus 1200 may be referred to as an encoder apparatus, and when apparatus 1200 implements decoder 804, apparatus 1200 may be referred to as a decoder apparatus. As shown in FIG.12, apparatus 1200 may comprise: processing circuitry (PC) 1202, which may include one or more processors (P) 1255 (e.g., one or more general purpose microprocessors and/or one or more other processors, such as an application specific integrated circuit (ASIC), field-programmable gate arrays (FPGAs), and the like), which processors may be co-located in a single housing or in a single data center or may be geographically distributed (i.e., encoder apparatus 1200 may be a distributed computing apparatus); at least one network interface 1248 (e.g., a physical interface or air interface) comprising a transmitter (Tx) 1245 and a receiver (Rx) 1247 for enabling apparatus 1200 to transmit data to and receive data from other nodes connected to a network 110 (e.g., an Internet Protocol (IP) network) to which network interface 1248 is connected (physically or wirelessly) (e.g., network interface 1248 may be coupled to an antenna arrangement comprising one or more antennas for enabling encoder apparatus 1200 to wirelessly transmit/receive data); and a storage unit (a.k.a., “data storage system”) 1208, which may include one or more non-volatile storage devices and/or one or more volatile storage devices. In embodiments where PC 1202 includes a programmable processor, a computer readable storage medium (CRSM) 1242 may be provided. CRSM 1242 may store a computer program (CP) 1243 comprising computer readable instructions (CRI) 1244. CRSM 1242 may be a non-transitory computer readable medium, such as, magnetic media (e.g., a hard disk), optical media, memory devices (e.g., random access memory, flash memory), and the like. In some embodiments, the CRI 1244 of computer program 1243 is configured such that when executed by PC 1202, the CRI causes encoder apparatus 1200 to perform steps described herein (e.g., steps described herein with reference to the flow charts). In other embodiments, encoder apparatus 1200 may be configured to perform steps described herein without the need for code. That is, for example, PC 1202 may consist merely of one or more ASICs. Hence, the features of the embodiments described herein may be implemented in hardware and/or software. [0128] Summary of Various Embodiments A1. A method (1000) for encoding a picture, the method comprising: obtaining (s1002) a first candidate motion vector, MV, for a current block of the picture; determining (s1004) that a criteria is satisfied; and as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block (s1006), wherein determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block; and 2) determining that a first criterion is satisfied. A2. The method of embodiment A1, wherein determining that the first criterion is satisfied comprises: for a first subblock of the current block, obtaining a predicted first subblock based on a first refined MV for the first subblock; for a second subblock of the current block, obtaining a predicted second subblock using a second refined motion vector for the second subblock; calculating a boundary activity value, Ba, using samples within the predicted first subblock and samples within the predicted second subblock; and determining that Ba satisfies a condition (e.g., Ba is greater than or equal to a threshold boundary activity value). A3. The method of embodiment A2, wherein determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: determining a first spatial activity (SA) value, Sa1, using the first subblock; and comparing Sa1 to an Sa threshold (e.g., to determine whether Sa1 is less than or equal to the Sa threshold). A4. The method of embodiment A3, wherein determining that the second criterion is satisfied further comprises: determining a second SA value, Sa2, using a second subblock within the current block; and comparing Sa2 to the Sa threshold or another Sa threshold. A5. The method of any one of embodiments A3-A4, wherein Sa1 is an averaged spatial activity of at least some of the samples within the first subblock, or Sa1 is a variance of at least some of the samples within the first subblock. A6. The method of any one of embodiments A3-A5, wherein determining that the criteria is satisfied further comprises determining that a third criterion is satisfied, and determining that the third criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1. A7. The method of embodiment A2, wherein determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1. A8. The method of any one of embodiments A2-A7, wherein the predicted first subblock comprises a first sample value, s11, and a second sample value, s12; the predicted second subblock comprises a third sample value, s21, and a fourth sample value, s22; calculating a boundary activity value, Ba, using samples within the predicted first subblock and samples within the predicted second subblock comprises calculating: (|s11 - s21|) + (|s12 - s22|). A9. The method of embodiment A1, wherein determining that the first criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1. A10. The method of embodiment A1, wherein determining that the first criterion is satisfied comprises: determining a spatial activity value, Sa, for the first subblock; and comparing Sa to an Sa threshold (e.g., to determine whether Sa is less than or equal to the Sa threshold). A11. The method of embodiment A2, wherein determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises determining that the picture is not in a highest temporal layer. A12. The method of embodiment A3, wherein determining Sa1 using the first subblock comprises: obtaining a predicted first subblock for the first subblock using the first candidate motion vector; and determining Sa1 using the predicted first subblock. B1. A computer program (1243) comprising instructions (1244) which when executed by processing circuitry (1202) cause the processing circuitry (1202) to perform the method of any one of the above embodiments. B2. A carrier containing the computer program of embodiment B1, wherein the carrier is one of an electronic signal, an optical signal, a radio signal, and a computer readable storage medium (1242). C1. An apparatus (1200) for encoding a picture, the apparatus configured to perform a method comprising: obtaining (s1002) a first candidate motion vector, MV, for a current block of the picture; determining (s1004) that a criteria is satisfied; and as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block (s1006), wherein determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block; and 2) determining that a first criterion is satisfied. C2. The apparatus of embodiment C1, wherein the apparatus is further configured to perform the method of any one of embodiments A2-A12. D1. An apparatus (1200), the apparatus comprising: a memory (1242); and processing circuitry (1202) coupled to the memory (1242), wherein the apparatus (1200) is configured to perform the method of any one of embodiments A1-A12. [0129] Objective Results [0130] The embodiments disclosed herein can avoid subjective problems for DMVR while providing following objective performance compared to the VVC reference software for RA (random access configuration in VTM19): Y U V Class A1 0,06% 0,07% 0,04% Class A2 0,08% 0,11% 0,10% For a higher QP range QP 37, 40, 43, 46 and 49 and using GOP based RPR encoder control from VTM19 (which is favourable at higher QPs, e.g. lower bitrates) as anchor and turning off DMVR for RA: Sequence Y U V NeptuneFountain3_3840x2160_60fp 0,91% 2,64% 0,00% MountainBay2_3840x2160_30fps_42 2,58% 3,88% 2,93% Campfire_3840x2160_30fps_bt709_ 0,16% 0,17% 0,51% DaylightRoad2_3840x2160_60fps_1 4,33% 4,08% 4,06% ParkRunning3_3840x2160_50fps_10 1,78% 2,64% 2,45% DrivingPOV3_3840x2160_60fps_10b 3,72% 4,41% 3,49% H3_AMS01_3840x2160_10bit_420_HL 2,94% 2,76% 2,57% Average 2,35% 2,94% 2,29% Then when enabling DMVR but with encoder control as in this invention: Sequence Y U V NeptuneFountain3_3840x2160_60fp 0,13% 0,43% 0,00% MountainBay2_3840x2160_30fps_42 0,31% 0,65% 0,84% Campfire_3840x2160_30fps_bt709_ 0,06% 0,16% 0,07% DaylightRoad2_3840x2160_60fps_1 2,60% 2,68% 2,84% ParkRunning3_3840x2160_50fps_10 0,38% 0,57% 0,53% DrivingPOV3_3840x2160_60fps_10b 1,38% 2,01% 1,92% H3_AMS01_3840x2160_10bit_420_HL 1,96% 2,27% 2,24% Average 0,97% 1,25% 1,21% Then when enabling DMVR but with encoder control as in this invention: Sequence Y U V NeptuneFountain3_3840x2160_60fp 0,04% 0,15% 0,00% MountainBay2_3840x2160_30fps_42 0,12% 0,40% 0,54% Campfire_3840x2160_30fps_bt709_ 0,01% 0,08% 0,06% DaylightRoad2_3840x2160_60fps_1 1,09% 1,12% 1,29% ParkRunning3_3840x2160_50fps_10 0,09% 0,19% 0,23% DrivingPOV3_3840x2160_60fps_10b 0,58% 0,95% 0,88% H3_AMS01_3840x2160_10bit_420_HL 1,18% 1,51% 1,51% Average 0,45% 0,63% 0,64% [0131] Conclusion [0132] While various embodiments are described herein, it should be understood that they have been presented by way of example only, and not limitation. Thus, the breadth and scope of this disclosure should not be limited by any of the above described exemplary embodiments. Moreover, any combination of the above-described elements in all possible variations thereof is encompassed by the disclosure unless otherwise indicated herein or otherwise clearly contradicted by context. [0133] Additionally, while the processes described above and illustrated in the drawings are shown as a sequence of steps, this was done solely for the sake of illustration. Accordingly, it is contemplated that some steps may be added, some steps may be omitted, the order of the steps may be re-arranged, and some steps may be performed in parallel.

Claims

CLAIMS 1. A method (1000) for encoding a picture, the method comprising: obtaining (s1002) a first candidate motion vector, MV, for a current block of the picture; determining (s1004) that a criteria is satisfied; and as a result of determining that the criteria is satisfied, refraining from using the first candidate MV to encode the current block (s1006), wherein determining that the criteria is satisfied comprises: 1) determining that a subblock-based motion refinement is applicable for the current block; and 2) determining that a first criterion is satisfied. 2. The method of claim 1, wherein determining that the first criterion is satisfied comprises: for a first subblock of the current block, obtaining a predicted first subblock based on a first refined MV for the first subblock; for a second subblock of the current block, obtaining a predicted second subblock using a second refined motion vector for the second subblock; calculating a boundary activity value, Ba, using samples within the predicted first subblock and samples within the predicted second subblock; and determining whether Ba is greater than or equal to a threshold boundary activity value . 3. The method of claim 2, wherein determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: determining a first spatial activity, SA, value, Sa1, using the first subblock; and comparing Sa1 to an Sa threshold. 4. The method of claim 3, wherein determining that the second criterion is satisfied further comprises: determining a second SA value, Sa2, using a second subblock within the current block; and comparing Sa2 to the Sa threshold or another Sa threshold. 5. The method of any one of claims 3-4, wherein Sa1 is an averaged spatial activity of at least some of the samples within the first subblock, or Sa1 is a variance of at least some of the samples within the first subblock. 6. The method of any one of claims 3-5, wherein determining that the criteria is satisfied further comprises determining that a third criterion is satisfied, and determining that the third criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1. 7. The method of claim 2, wherein determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1. 8. The method of any one of claims 2-7, wherein the predicted first subblock comprises a first sample value, s11, and a second sample value, s12; the predicted second subblock comprises a third sample value, s21, and a fourth sample value, s22; calculating a boundary activity value, Ba, using samples within the predicted first subblock and samples within the predicted second subblock comprises calculating: |s11 - s21| + |s12 - s22|. 9. The method of claim 1, wherein determining that the first criterion is satisfied comprises: deriving a first refined MV using the first candidate MV and the first subblock; deriving a second refined MV using the first candidate MV and a second subblock within the current block; calculating a difference between the first refined MV and the second refined MV; and comparing the difference to a threshold value, T1. 10. The method of claim 1, wherein determining that the first criterion is satisfied comprises: determining a spatial activity value, Sa, for the first subblock; and comparing Sa to an Sa threshold. 11. The method of claim 2, wherein determining that the criteria is satisfied further comprises determining that a second criterion is satisfied, and determining that the second criterion is satisfied comprises determining that the picture is not in a highest temporal layer. 12. The method of claim 3, wherein determining Sa1 using the first subblock comprises: obtaining a predicted first subblock for the first subblock using the first candidate motion vector; and determining Sa1 using the predicted first subblock. 13. A computer program (1243) comprising instructions (1244) which when executed by processing circuitry (1202) cause the processing circuitry (1202) to perform the method of any one of the above claims. 14. A carrier containing the computer program of claim 13, wherein the carrier is one of an electronic signal, an optical signal, a radio signal, and a computer readable storage medium (1242). 15. An apparatus (1200) for encoding a picture, the apparatus configured to perform the method according to any one of claims 1-12. 16. An apparatus (1200), the apparatus comprising: a memory (1242); and processing circuitry (1202) coupled to the memory (1242), wherein the apparatus (1200) is configured to perform the method of any one of claims 1-12.
EP24785436.7A 2023-04-06 2024-03-27 Encoder for encoding pictures of a video Pending EP4690797A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
US202363457728P 2023-04-06 2023-04-06
PCT/SE2024/050281 WO2024210793A1 (en) 2023-04-06 2024-03-27 Encoder for encoding pictures of a video

Publications (1)

Publication Number Publication Date
EP4690797A1 true EP4690797A1 (en) 2026-02-11

Family

ID=92973196

Family Applications (1)

Application Number Title Priority Date Filing Date
EP24785436.7A Pending EP4690797A1 (en) 2023-04-06 2024-03-27 Encoder for encoding pictures of a video

Country Status (2)

Country Link
EP (1) EP4690797A1 (en)
WO (1) WO2024210793A1 (en)

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN118869984A (en) * 2017-12-08 2024-10-29 松下电器(美国)知识产权公司 Image encoding device, image decoding device, image encoding method, and image decoding method
WO2020005719A1 (en) * 2018-06-27 2020-01-02 Vid Scale, Inc. Methods and apparatus for reducing the coding latency of decoder-side motion refinement
US10638153B2 (en) * 2018-07-02 2020-04-28 Tencent America LLC For decoder side MV derivation and refinement
CA3128112A1 (en) * 2019-02-22 2020-08-27 Huawei Technologies Co., Ltd. Early termination for optical flow refinement
EP3922023A4 (en) * 2019-03-05 2022-06-15 Huawei Technologies Co., Ltd. USING EXTENDED SAMPLES WHILE SEARCHING IN DECODER-SIDE MOTION REFINER
TWI738248B (en) * 2019-03-14 2021-09-01 聯發科技股份有限公司 Methods and apparatuses of video processing with motion refinement and sub-partition base padding
CN113796084B (en) * 2019-04-14 2023-09-15 北京字节跳动网络技术有限公司 Motion vector and prediction sample refinement
CN117121486A (en) * 2021-03-02 2023-11-24 抖音视界有限公司 Inter prediction for non-binary blocks
EP4364419A4 (en) * 2021-06-30 2025-06-11 Telefonaktiebolaget LM Ericsson (publ) SELECTIVE SUB-BLOCK-BASED MOVEMENT REFINEMENT
US12526443B2 (en) * 2022-01-13 2026-01-13 Qualcomm Incorporated Coding video data using out-of-boundary motion vectors

Also Published As

Publication number Publication date
WO2024210793A1 (en) 2024-10-10

Similar Documents

Publication Publication Date Title
US12231678B2 (en) Inter prediction method and apparatus for same
TWI761415B (en) Motion vector reconstructions for bi-directional optical flow (bio)
US10986366B2 (en) Video coding with adaptive motion information refinement
US10880552B2 (en) Method and apparatus for performing optimal prediction based on weight index
KR102873107B1 (en) Inter prediction method and device in a video coding system
EP3275188B1 (en) Motion vector derivation in video coding
US20190208223A1 (en) Method and apparatus for video coding with automatic motion information refinement
WO2023076700A1 (en) Motion compensation considering out-of-boundary conditions in video coding
KR20250030972A (en) Method for processing image based on joint inter-intra prediction mode and apparatus therefor
US20240155134A1 (en) Method and apparatus for video coding using improved cross-component linear model prediction
US20250379997A1 (en) Method and apparatus for implicitly indicating motion vector predictor precision
US20260046440A1 (en) Method and apparatus for motion vector prediction based on subblock motion vector
US12439076B2 (en) Selective subblock-based motion refinement
WO2025136432A1 (en) Systems and methods for optical flow-based motion vector refinement
WO2024210793A1 (en) Encoder for encoding pictures of a video
WO2023205283A1 (en) Methods and devices for enhanced local illumination compensation
US20240236332A1 (en) Overlapped decoder side motion refinement
US12531996B2 (en) Enhanced multi-hypothesis prediction
WO2025214829A1 (en) Motion vector refinement with downsampled blocks, or hierarchical sub-blocks
WO2026005668A1 (en) Obtaining motion compensated prediction samples
US20250142108A1 (en) Motion vector difference derivation
WO2025075541A1 (en) Motion vector derivation based on block boundary distortion
KR20250149127A (en) Method And Apparatus for Video Coding Deriving And Refining Blending Parameters
WO2025067875A1 (en) Sample value generation
WO2025005846A1 (en) Motion vector derivation

Legal Events

Date Code Title Description
STAA Information on the status of an ep patent application or granted ep patent

Free format text: STATUS: THE INTERNATIONAL PUBLICATION HAS BEEN MADE

PUAI Public reference made under article 153(3) epc to a published international application that has entered the european phase

Free format text: ORIGINAL CODE: 0009012

STAA Information on the status of an ep patent application or granted ep patent

Free format text: STATUS: REQUEST FOR EXAMINATION WAS MADE

17P Request for examination filed

Effective date: 20251020

AK Designated contracting states

Kind code of ref document: A1

Designated state(s): AL AT BE BG CH CY CZ DE DK EE ES FI FR GB GR HR HU IE IS IT LI LT LU LV MC ME MK MT NL NO PL PT RO RS SE SI SK SM TR