Signaling by using template matching cost
Abstract
An apparatus including processing circuitry is provided. The processing circuitry is configured to, when a first syntax element indicates that a non-linear function-based prediction method is applied to reconstruct a current block, determine a prediction model from a plurality of candidate prediction models based on a plurality of TM costs between a template of the current block and a template of a reference block according to the plurality of candidate prediction models associated with the non-linear function-based prediction method. The processing circuitry is configured to determine a prediction block of the current block as the reference block processed by a non-linear function of the prediction model.
Claims
exact text as granted — not AI-modifiedWhat is claimed is:
1 . A method of video decoding, the method comprising:
receiving a bitstream including a first syntax element that indicates whether a function-based prediction method is applied to reconstruct a current block based on a template matching prediction, the function-based prediction method applying a prediction model that is associated with a template type of a template of the current block and includes a function that is applied to a reference block of the current block, the function including parameters derived based on the template of the current block and a template of the reference block; when the first syntax element indicates that the function-based prediction method is applied to reconstruct the current block, determining the prediction model from a plurality of candidate prediction models based on a plurality of template matching (TM) costs between the template of the current block and the template of the reference block according to the plurality of candidate prediction models associated with the function-based prediction method; and determining a prediction block of the current block as the reference block processed by the function of the prediction model.
2 . The method of claim 1 , wherein the determining the prediction model further comprises:
applying a function of each of the plurality of candidate prediction models to the template of the current block and the template of the reference block to obtain a processed template of the current block and the processed template of the reference block; determining each of the plurality of TM costs based on the processed template of the current block and the processed template of the reference block according to a respective one of the plurality of candidate prediction models; and determining the prediction model from the plurality of candidate prediction models that corresponds to a minimum TM cost of the plurality of TM costs.
3 . The method of claim 1 , wherein the determining the prediction block of the current block further comprises:
applying the function of the prediction model to process samples of the reference block; and determining the prediction block of the current block as the samples of the reference block processed by the function of the prediction model.
4 . The method of claim 1 , wherein:
the function is one of a linear function and a non-linear function, and the linear function is defined as
∑
i
=
0
n
(
α
i
×
p
(
x
i
,
y
i
)
)
,
p(x i ,y i ) being a sample of the reference block, α i and β being factors.
5 . The method of claim 1 , wherein the template type includes one of:
a first template type that includes a first template region positioned at a left side of the current block, a second template type that includes a second template region positioned at a top side of the current block, a third template type including the first template region positioned at the left side of the current block and the second template region positioned at the top side of the current block, and a fourth temple type including the first template region positioned at the left side of the current block, the second template region positioned at the top side of the current block, and a top-left template region positioned at a top-left corner of the current block and arranged between the first template region and the second template region.
6 . The method of claim 1 , wherein the first syntax element indicates that the prediction model is applied to at least one of a Cb component and a Cr component of the current block.
7 . The method of claim 1 , wherein the determining the prediction model comprises:
generating processed samples of the template of the current block and processed samples of the template of the reference block based on a first candidate prediction model of the plurality of candidate prediction models; determining a first TM cost of the plurality of TM costs based on the processed samples of the template of the current block and the processed samples of the template of the reference block; filtering the samples of the template of the current block and the samples of the template of the reference block; generating processed filtered samples of the template of the current block and processed filtered samples of the template of the current block based on the first candidate prediction model; and determining a second TM cost of the plurality of TM costs based on the processed filtered samples of the template of the current block and the processed filtered samples of the template of the reference block.
8 . The method of claim 7 , wherein the filtering further comprises:
subtracting a mean of samples of the template of the current block from each of the samples of the template of the current block to generate adjusted samples of the template of the current block; subtracting a mean of samples of the template of the reference block from each of the samples of the template of the reference block to generated adjust samples of the template of the current block; and determining a third TM cost of the plurality of TM costs based on the adjusted samples of the template of the current block and the adjusted samples of the template of the reference block.
9 . The method of claim 1 , wherein the determining the prediction model comprises:
determining a first TM cost of the plurality of TM costs based on samples of the template of the current block and samples of the template of the reference block; generating processed samples of the template of the current block and processed samples of the template of the reference block based on a first candidate prediction model of the plurality of candidate prediction models; and determining a second TM cost of the plurality of TM costs based on the processed samples of the template of the current block and the processed samples of the template of the reference block.
10 . The method of claim 1 , wherein the determining the prediction block of the current block further comprises:
determining one of the plurality of TM costs that is indicated by a second syntax element in the bitstream; determining the prediction model from the plurality of candidate prediction models that corresponds to the determined one of the plurality of TM costs; applying the function of the prediction model to process samples of the reference block; and determining the prediction block of the current block based on the samples of the reference block that are processed by the function of the prediction model.
11 . The method of claim 2 , further comprising:
normalizing each TM cost of the plurality of TM costs by dividing the respective TM cost with a template size corresponding to the respective TM cost; reordering the plurality of normalized TM costs in an ascending order based on the normalized TM costs; and generating a candidate list based on the plurality of reordered normalized TM costs.
12 . The method of claim 11 , further comprising:
receiving a third syntax element in the bitstream that indicates which one of the plurality of reordered normalized TM costs is selected, the third syntax element being associated with at least one of a Cb component or a Cr component of the current block; and determining the prediction model from the plurality of candidate prediction models that corresponds to the TM cost indicated by the third syntax element.
13 . A method of video encoding, the method comprising:
determining whether a function-based prediction method is applied to predict a current block based on a template matching prediction, the function-based prediction method applying a prediction model that is associated with a template type of a template of the current block and includes a function that is applied to a reference block of the current block, the function including parameters derived based on the template of the current block and a template of the reference block; when the function-based prediction method is determined to be applied to predict the current block, determining the prediction model from a plurality of candidate prediction models based on a plurality of template matching (TM) costs between the template of the current block and the template of the reference block according to the plurality of candidate prediction models associated with the function-based prediction method; and determining a prediction block of the current block as the reference block processed by the function of the prediction model.
14 . The method of claim 13 , wherein the determining the prediction model further comprises:
applying a function of each of the plurality of candidate prediction models to the template of the current block and the template of the reference block to obtain a processed template of the current block and the processed template of the reference block; determining each of the plurality of TM costs based on the processed template of the current block and the processed template of the reference block according to a respective one of the plurality of candidate prediction models; and determining the prediction model from the plurality of candidate prediction models that corresponds to a minimum TM cost of the plurality of TM costs.
15 . The method of claim 13 , wherein the determining the prediction block of the current block further comprises:
applying the function of the prediction model to process samples of the reference block; and determining the prediction block of the current block as the samples of the reference block processed by the function of the prediction model.
16 . The method of claim 13 , wherein:
the function is one of a linear function and a non-linear function, and the linear function is defined as
∑
i
=
0
n
(
α
i
×
p
(
x
i
,
y
i
)
)
,
p(x i ,y i ) being a sample of the reference block, α i and β being factors.
17 . The method of claim 13 , wherein the template type includes one of:
a first template type that includes a first template region positioned at a left side of the current block, a second template type that includes a second template region positioned at a top side of the current block, a third template type including the first template region positioned at the left side of the current block and the second template region positioned at the top side of the current block, and a fourth temple type including the first template region positioned at the left side of the current block, the second template region positioned at the top side of the current block, and a top-left template region positioned at a top-left corner of the current block and arranged between the first template region and the second template region.
18 . The method of claim 13 , further comprising:
encoding a first syntax element into a bitstream to indicate that the prediction model is applied to at least one of a Cb component and a Cr component of the current block.
19 . The method of claim 13 , wherein the determining the prediction model comprises:
generating processed samples of the template of the current block and processed samples of the template of the reference block based on a first candidate prediction model of the plurality of candidate prediction models; determining a first TM cost of the plurality of TM costs based on the processed samples of the template of the current block and the processed samples of the template of the reference block; filtering the samples of the template of the current block and the samples of the template of the reference block; generating processed filtered samples of the template of the current block and processed filtered samples of the template of the current block based on the first candidate prediction model; and determining a second TM cost of the plurality of TM costs based on the processed filtered samples of the template of the current block and the processed filtered samples of the template of the reference block.
20 . A non-transitory computer readable medium storing a video media bitstream encoded by an encoding method, the encoding method comprising:
determining whether a function-based prediction method is applied to predict a current block based on a template matching prediction, the function-based prediction method applying a prediction model that is associated with a template type of a template of the current block and includes a function that is applied to a reference block of the current block, the function including parameters derived based on the template of the current block and a template of the reference block; when the function-based prediction method is determined to be applied to predict the current block, determining the prediction model from a plurality of candidate prediction models based on a plurality of template matching (TM) costs between the template of the current block and the template of the reference block according to the plurality of candidate prediction models associated with the function-based prediction method; determining a prediction block of the current block as the reference block processed by the function of the prediction model; and encoding the current block into the video media bitstream based on the determined prediction block of the current block.Join the waitlist — get patent alerts
Track US2025386016A1 — get alerts on status changes and closely related new filings.
We store only your email — no account needed. See our privacy policy.