Context adaptive binary arithmetic coding method and device
There is provided an video encoding/decoding method and apparatus. The video decoding method comprises acquiring a bitstream including a predetermined context element, performing at least one of a context model determination, a probability update, and a probability interval determination on the predetermined syntax element, and arithmetically decoding the predetermined syntax element on the basis of a result of the performance.
1. A video decoding method, comprising:
acquiring a bitstream including a syntax element;
performing at least one of a context model determination, a probability update, and a probability interval determination based on the syntax element; and
arithmetically decoding the syntax element based on the context model determination,
wherein the context model determination comprises selecting a probability model for the syntax element,
wherein the probability model for the syntax element of a current block is determined based on a prediction mode of an adjacent block of the current block, and
wherein the probability model for the syntax element of the current block is determined based on whether the prediction mode of the adjacent block is a matrix weighted intra prediction mode.
2. The video decoding method of claim 1 , wherein the context model determination includes a context initialization,
wherein the context initialization is performed on a first Coding Tree Unit (CTU) of a horizontal line of CTUs, and
wherein the context initialization is performed using information of a block which is adjacent to an upper side of the first CTU.
3. The video decoding method of claim 2 , wherein the context initialization is performed on the first CTU of the horizontal line of the CTUs in a tile.
4. The video decoding method of claim 1 , wherein the probability model for the syntax element of the current block is determined based on whether the prediction mode of the adjacent block is an intra prediction mode.
5. The video decoding method of claim 1 , wherein the probability model for the syntax element of the current block is determined based on whether the prediction mode of the adjacent block is an affine inter mode or a sub-block merge mode.
6. The video decoding method of claim 1 , wherein the probability model for the syntax element of the current block is determined based on whether the prediction mode of the adjacent block is an intra block copy mode.
7. The video decoding method claim 1 , wherein the probability model for the syntax element of the current block is determined based on an indicator which is used to determine whether a planar mode is used for the adjacent block.
8. A video encoding method, comprising:
performing at least one of a context model determination, a probability update, and a probability interval determination on a syntax element;
arithmetically encoding the syntax element based on the context model determination; and
generating a bitstream including the syntax element arithmetically encoded,
wherein the context model determination comprises selecting a probability model for the syntax element,
wherein the probability model for the syntax element of a current block is determined based on a prediction mode of an adjacent block of the current block, and
wherein the probability model for the syntax element of the current block is determined based on whether the prediction mode of the adjacent block is a matrix weighted intra prediction mode.
9. The video encoding method of claim 8 , wherein the context model determination includes a context initialization,
wherein the context initialization is performed on a first Coding Tree Unit (CTU) of a horizontal line of CTUs, and
wherein the context initialization is performed using information of a block which is adjacent to an upper side of the first CTU.
10. A non-transitory computer-readable medium storing the bitstream generated by the video encoding method of claim 8 .
11. A non-transitory computer-readable medium storing a bitstream, the bitstream comprising a syntax element,
wherein at least one of a context model determination, a probability update, and a probability interval determination on the syntax element is performed based on the syntax element,
wherein the syntax element is arithmetically decoded based on the context model determination, wherein
wherein the context model determination comprises selecting a probability model for the syntax element,
wherein the probability model for the syntax element of a current block is determined based on a prediction mode of an adjacent block of the current block, and
wherein the probability model for the syntax element of the current block is determined based on whether the prediction mode of the adjacent block is a matrix weighted intra prediction mode.
12. The non-transitory computer-readable medium of claim 11 , wherein the context model determination includes a context initialization,
wherein the context initialization is performed on a first Coding Tree Unit (CTU) of a horizontal line of CTUs, and
wherein the context initialization is performed using information of a block which is adjacent to an upper side of the first CTU.