System and Method for Intranet Template Matching

Intra template matching prediction methods enhance video encoding and decoding efficiency by optimizing intra prediction processes, addressing inefficiencies in existing technologies and improving computational performance.

JP2026514007APending Publication Date: 2026-05-01GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
JP · JP
Patent Type
Applications
Current Assignee / Owner
GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
Filing Date
2024-04-12
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing video encoding and decoding technologies face inefficiencies in intra prediction methods, particularly in handling intra template matching prediction, which can lead to suboptimal performance and increased computational complexity.

Method used

The implementation of intra template matching prediction (intraTMP) methods that involve decoding and encoding syntax elements to determine fusion weights and reference blocks, enhancing prediction accuracy and efficiency by analyzing bitstreams and applying intraTMP fusion modes.

Benefits of technology

Improves video encoding and decoding processes by optimizing intra prediction, reducing computational complexity, and enhancing prediction accuracy through intraTMP fusion modes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure 2026514007000001_ABST
    Figure 2026514007000001_ABST
Patent Text Reader

Abstract

According to one aspect of the present disclosure, a decoding method is provided which is performed by a decoder. The method may include a processor decoding a plurality of syntax elements associated with intra-template matching predictions (intraTMP) by analyzing a bitstream. The method may include the processor decoding a first syntax element from the bitstream. The method may include the processor determining, based on the first syntax element, whether or not the intraTMP mode is enabled for the current block. The method may include the processor decoding a second syntax element from the bitstream, having determined that the intraTMP mode is enabled for the current block. The method may include the processor determining, based on the second syntax element, whether or not the intraTMP prediction value for the current block is determined by the intraTMP fusion mode. The method may include the processor decoding the current block based on the intraTMP prediction value.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] [Cross - Reference to Related Applications] This invention claims the benefit of priority of U.S. Provisional Application No. 63 / 459,236, titled "SYSTEMS AND METHODS FOR TNTRA TEMPLATE MATCHING", filed on April 13, 2023, and U.S. Provisional Application No. 63 / 459,550, titled "SYSTEMS AND METHODS FOR INTRA TEMPLATE MATCHING", filed on April 14, 2023. The entire contents of these two U.S. provisional applications are incorporated herein by reference.

[0002] Embodiments of the present disclosure relate to video encoding and decoding.

Background Art

[0003] Digital video has already become mainstream and is used in various applications including digital television, video telephony, and videoconferencing. These digital video applications are made possible due to the progress of computing and communication technologies and the efficiency of video encoding technologies. Since video data can be compressed using various video encoding technologies, it is possible to encode video data using one or more video encoding standards. Exemplary video encoding standards may include, but are not limited to, General Video Coding (H.266 / VVC), High Efficiency Video Coding (H.265 / HEVC), Advanced Video Coding (H.264 / AVC), Moving Picture Expert Group (MPEG) coding, Enhanced Video Coding Model (ECM), etc.

Summary of the Invention

Means for Solving the Problems

[0004] According to one aspect of the present disclosure, a decoding method executed by a decoder is provided. The method may include a processor decoding a plurality of syntax elements associated with intra template matching prediction (intraTMP) by analyzing a bitstream. The method may include the processor decoding a first syntax element from the bitstream. The method may include the processor determining whether an intraTMP mode is enabled for a current block based on the first syntax element. The method may include the processor decoding a second syntax element from the bitstream in response to the intraTMP mode being enabled for the current block. The method may include the processor determining whether an intraTMP prediction value of the current block is determined by an intraTMP fusion mode based on the second syntax element. The method may include the processor decoding a third syntax element and a fourth syntax element from the bitstream in response to the determination that the intraTMP prediction value is determined by the intraTMP fusion mode. The method may include the processor determining a set of fusion weights based on the fourth syntax element. The method may include the processor determining the intraTMP prediction value based on the set of fusion weights and a set of reference blocks indicated by the third syntax element. The method may include the processor decoding the current block based on the intraTMP prediction value.

[0005] In other aspects of the present disclosure, a decoder is provided. The decoder may include a processor and a memory storing instructions. The memory stores instructions, which, when executed by the processor, can cause the processor to decode a plurality of syntax elements associated with intraTMP by analyzing a bitstream. The memory stores instructions, which, when executed by the processor, can cause the processor to decode a first syntax element from the bitstream. The memory stores instructions, which, when executed by the processor, can cause the processor to determine, based on the first syntax element, whether intraTMP mode is enabled for the current block. The memory stores instructions, which, when executed by the processor, can cause the processor to decode a second syntax element from the bitstream, based on the determination that intraTMP mode is enabled for the current block. The memory stores an instruction, and when the instruction is executed by the processor, the processor can be made to perform the operation of determining whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, based on the second syntax element. The memory stores an instruction, and when the instruction is executed by the processor, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the processor can be made to perform the operation of decoding the third syntax element and the fourth syntax element from the bitstream. The memory stores an instruction, and when the instruction is executed by the processor, the processor can be made to perform the operation of determining the fusion weight set based on the fourth syntax element.Instructions are stored in the memory, and when an instruction is executed by the processor, it can cause the processor to perform the operation of determining the intraTMP predicted value based on the fused weight set and the reference block set indicated by the third syntax element. Instructions are stored in the memory, and when an instruction is executed by the processor, it can cause the processor to perform the operation of decoding the current block based on the intraTMP predicted value.

[0006] According to another aspect of the present disclosure, a non-temporary computer-readable medium is provided which stores instructions for a decoder. The memory stores instructions that, when executed by the decoder's processor, cause the decoder's processor to perform the operation of decoding a plurality of syntax elements associated with intraTMP by parsing a bitstream. The memory stores instructions that, when executed by the decoder's processor, cause the decoder's processor to perform the operation of decoding a first syntax element from the bitstream. The memory stores instructions that, when executed by the decoder's processor, cause the decoder's processor to perform the operation of determining whether intraTMP mode is enabled for the current block based on the first syntax element. The memory stores instructions that, when executed by the processor, cause the processor to decode a second syntax element from the bitstream, based on the determination that intraTMP mode is enabled for the current block. The memory stores instructions, and when the decoder's processor executes these instructions, it can cause the decoder's processor to perform the operation of determining whether the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, based on the second syntax element. The memory stores instructions, and when the processor executes these instructions, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, it can cause the processor to perform the operation of decoding the third syntax element and the fourth syntax element from the bitstream. The memory stores instructions, and when the decoder's processor executes these instructions, it can cause the decoder's processor to perform the operation of determining the fusion weight set based on the fourth syntax element.The memory stores instructions, and when executed by the decoder's processor, these instructions can cause the decoder's processor to perform the operation of determining the intraTMP predicted value based on the fused weight set and the reference block set indicated by the third syntax element. The memory also stores instructions, and when executed by the decoder's processor, these instructions can cause the decoder's processor to perform the operation of decoding the current block based on the intraTMP predicted value.

[0007] A further aspect of this disclosure provides an encoding method performed by an encoder. The method may include a processor encoding a current block with intraTMP enabled. The method may include the processor encoding a first syntax element into a bitstream. The method may include the processor determining, based on the first syntax element, whether or not the intraTMP mode is enabled for the current block. The method may include the processor encoding a second syntax element into the bitstream, having determined that the intraTMP mode is enabled for the current block. The method may include the processor determining, based on the second syntax element, whether or not the intraTMP prediction for the current block is determined by the intraTMP fusion mode. The method may include the processor encoding a third syntax element and a fourth syntax element into the bitstream, having determined that the intraTMP prediction is determined by the intraTMP fusion mode. The method may include the processor determining the fusion weight set based on the fourth syntax element. The method may include the processor determining the intraTMP predicted value based on the fused weight set and the reference block set indicated by the third syntax element. The method may also include the processor encoding the current block based on the intraTMP predicted value.

[0008] In yet another aspect of the present disclosure, an encoder is provided. The encoder may include a processor and a memory storing instructions. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of enabling intraTMP and encoding the current block. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of encoding a first syntax element into a bitstream. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of determining whether intraTMP mode is enabled for the current block based on the first syntax element. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of encoding a second syntax element into the bitstream, based on the determination that intraTMP mode is enabled for the current block. The memory stores an instruction, and when the instruction is executed by the processor, it can cause the processor to perform the operation of determining whether the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, based on the second syntax element. The memory stores an instruction, and when the instruction is executed by the processor, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, it can cause the processor to perform the operation of encoding the third syntax element and the fourth syntax element into the bitstream. The memory stores an instruction, and when the instruction is executed by the processor, it can cause the processor to perform the operation of determining the fusion weight set based on the fourth syntax element. The memory stores an instruction, and when the instruction is executed by the processor, it can cause the processor to perform the operation of determining the intraTMP predicted value based on the fusion weight set and the reference block set indicated by the third syntax element.Instructions are stored in the memory, and when an instruction is executed by the processor, the processor is instructed to perform the operation of encoding the current block based on the intraTMP predicted value.

[0009] A further aspect of the present disclosure provides a non-temporary computer-readable medium storing instructions for an encoder. When executed by the encoder's processor, the instructions can cause the encoder's processor to perform the operation of enabling intraTMP and encoding the current block. When executed by the encoder's processor, the instructions can cause the encoder's processor to perform the operation of encoding a first syntax element into a bitstream. When executed by the encoder's processor, the instructions can cause the encoder's processor to perform the operation of determining, based on the first syntax element, whether or not intraTMP mode is enabled for the current block. The memory stores instructions, and when executed by the processor, the instructions can cause the processor to perform the operation of encoding a second syntax element into the bitstream, based on the determination that intraTMP mode is enabled for the current block. When executed by the encoder's processor, the instructions can cause the encoder's processor to perform the operation of determining, based on the second syntax element, whether or not the intraTMP predicted value of the current block is determined by intraTMP fusion mode. The memory stores an instruction, and when the instruction is executed by the processor, it determines that the intraTMP predicted value is determined by the intraTMP fusion mode, and causes the processor to perform the operation of encoding the third syntax element and the fourth syntax element into the bitstream. When the instruction is executed by the encoder's processor, it causes the encoder's processor to perform the operation of determining the fusion weight set based on the fourth syntax element. When the instruction is executed by the encoder's processor, it causes the encoder's processor to perform the operation of determining the intraTMP predicted value based on the fusion weight set and the reference block set indicated by the third syntax element.When the aforementioned instruction is executed by the encoder's processor, it causes the encoder's processor to perform the operation of encoding the current block based on the intraTMP predicted value.

[0010] These descriptive examples are not intended to limit or restrict the disclosure, but rather to provide examples that may help in understanding the disclosure. Descriptions of other embodiments for carrying out the invention are provided below, and further explanations are provided later. [Brief explanation of the drawing]

[0011] The drawings incorporated herein and forming part of the specification illustrate embodiments of the present disclosure and are used together with the specification to further illustrate the principles of the present disclosure and to enable those skilled in the art to implement and use the present disclosure.

[0012] [Figure 1] The following are block diagrams illustrating exemplary coding systems according to some embodiments of the present disclosure. [Figure 2] The following are block diagrams illustrating exemplary decoding systems according to some embodiments of the present disclosure. [Figure 3] A detailed block diagram of an exemplary encoder in the encoding system of Figure 1 according to some embodiments of this disclosure is shown. [Figure 4] A detailed block diagram of an exemplary decoder in the decoding system of Figure 2 according to some embodiments of the present disclosure is shown. [Figure 5] The following are illustrative images of coding tree units (CTUs) divided according to some embodiments of the present disclosure. [Figure 6] The following are exemplary coding units (CUs) divided into coding units according to some embodiments of the present disclosure. [Figure 7] The diagrams show a current CU block according to some embodiments of this disclosure, and schematic representations of spatially adjacent and spatially non-adjacent reconstructed samples of the current block. [Figure 8] Schematic diagrams of the angular modes of VVC according to some embodiments of this disclosure are shown. [Figure 9A] The following are schematic diagrams of the intra-template matching prediction (intraTMP) search area according to some embodiments of this disclosure. [Figure 9B] The following are schematic diagrams of the intraTMP extended search area according to some embodiments of this disclosure. [Figure 10] The spatial components of intraTMP filters according to some embodiments of this disclosure are shown. [Figure 11] The reference region used to obtain the filter coefficients of intraTMP in some embodiments of this disclosure is shown. [Figure 12] The diagram shows the adjacent half-pixel positions used for intraTMP in some embodiments of this disclosure. [Figure 13] The diagrams show various template shapes used for intraTMP in some embodiments of this disclosure. [Figure 14] The diagram shows fractional block vector positions used for intraTMP in some embodiments of this disclosure. [Figure 15A] A flowchart illustrating an exemplary method of video decoding according to some embodiments of this disclosure is shown. [Figure 15B] A flowchart illustrating an exemplary method of video decoding according to some embodiments of this disclosure is shown. [Figure 15C] A flowchart illustrating an exemplary method of video decoding according to some embodiments of this disclosure is shown. [Figure 15D] A flowchart illustrating an exemplary method of video decoding according to some embodiments of this disclosure is shown. [Figure 16A] A flowchart illustrating an exemplary method of video encoding according to some embodiments of this disclosure is shown. [Figure 16B] A flowchart illustrating an exemplary method of video encoding according to some embodiments of this disclosure is shown. [Figure 16C]A flowchart illustrating an exemplary method of video encoding according to some embodiments of this disclosure is shown. [Figure 16D] A flowchart illustrating an exemplary method of video encoding according to some embodiments of this disclosure is shown. [Modes for carrying out the invention]

[0013] Embodiments of this disclosure will be described with reference to the drawings.

[0014] While several configurations and arrangements are discussed, it should be understood that these are for illustrative purposes only. Those skilled in the art will recognize that other configurations and arrangements are usable without departing from the spirit and scope of this disclosure. It will also be apparent to those skilled in the art that this disclosure may be used for a variety of other purposes.

[0015] Furthermore, the specification refers to "one embodiment," "example," "exemplary embodiment," "several embodiments," and "some embodiments," indicating that the described embodiments may include certain features, structures, or properties, but each embodiment does not necessarily include such specific features, structures, or properties. Moreover, these phrases do not necessarily refer to the same embodiment. In addition, when describing a particular feature, structure, or property in conjunction with one embodiment, realizing such feature, structure, or property in conjunction with other embodiments is within the knowledge of a person skilled in the relevant art, whether explicitly stated or not.

[0016] Generally, terms are understandable at least partially depending on their contextual usage. For example, the term "one or more" as used in this paper is at least partially contextually determined and can be used to describe any feature, structure, or characteristic in a singular sense, or a combination of features, structures, or characteristics in a plural sense. Similarly, terms like "one," "one," and "the" are similarly understandable as conveying either a singular or plural usage, which is at least partially contextually determined. Furthermore, the term "based on" is not necessarily intended to convey an exclusive set of factors, but is understandable as allowing for the existence of additional factors that are not necessarily explicitly stated, which is similarly at least partially contextually determined.

[0017] This document describes various aspects of video encoding systems with reference to various devices and methods. These devices and methods are described in the following detailed description and are illustrated in the drawings by various modules, components, circuits, steps, operations, processes, algorithms, etc. (collectively referred to as "elements"). These elements can be implemented as electronic hardware, firmware, computer software, or any combination thereof. Whether such elements are implemented as hardware, firmware, or software depends on the specific application and design constraints imposed on the system as a whole.

[0018] The techniques described in this paper are applicable to a variety of video encoding and decoding applications. As described in this paper, video encoding and decoding include both encoding and decoding of video. Video encoding and decoding can be performed by block units. For example, encoding / decoding processes, such as transformation, quantization, prediction, intra-loop filtering, and reconstruction, can be performed on encoding blocks, transformation blocks, or prediction blocks. As described in this paper, blocks awaiting encoding / decoding are called “current blocks.” For example, current blocks may represent encoding blocks, transformation blocks, or prediction blocks according to the current encoding / decoding process. It should also be understood that the term “unit” as used in this disclosure refers to a basic unit for performing a particular encoding / decoding process, and the term “block” refers to a sample array of a predetermined size. Unless otherwise stated, “block” and “unit” are interchangeable.

[0019] Figure 1 shows a block diagram of an exemplary encoding system 100 according to some embodiments of the present disclosure. Figure 2 shows a block diagram of an exemplary decoding system 200 according to some embodiments of the present disclosure. Each system 100 or 200 can be applied to or integrated into a variety of systems and devices capable of processing data, such as computers and wireless communication devices. For example, system 100 or 200 may be all or part of a mobile phone, desktop computer, notebook computer, tablet, in-vehicle computer, game console, printer, positioning device, wearable electronic device, smart sensor, virtual reality (VR) device, augmented reality (AR) device, or any other suitable electronic device having data processing capabilities. As shown in Figures 7 and 8, system 100 or 200 may include a processor 102, memory 104, and interface 106. These components are shown as being connected to each other via a bus, but other types of connections are permitted. It should be understood that system 100 or 200 may include any other suitable components for performing the functions described herein.

[0020] Processor 102 may include microprocessors such as a graphics processing unit (GPU), image signal processor (ISP), central processing unit (CPU), digital signal processor (DSP), tensor processing unit (TPU), vision processing unit (VPU), neural processing unit (NPU), synergistic processing unit (SPU), or physics processing unit (PPU), a microcontroller unit (MCU), application-specific integrated circuit (ASIC), field-programmable gate array (FPGA), programmable logic device (PLD), state machine, gate control logic, discrete hardware circuitry, and other suitable hardware configured to perform various functions described in each part of this disclosure. Although only one processor is shown in Figures 7 and 8, it can be understood that multiple processors may be included. The processor 102 may be a hardware device having one or more processing cores. The processor 102 can execute software.Whether called software, firmware, middleware, microcode, hardware description language, or otherwise, software should be broadly understood to mean instructions, instruction sets, code, code segments, program code, programs, subprograms, software modules, applications, software applications, software packages, routines, subroutines, objects, executable files, execution threads, processes, functions, etc. Software may also include computer instructions written in interpreted languages, compiled languages, or machine code. Other techniques for directing hardware are also permitted within the broader software category.

[0021] Memory 104 may broadly include memory (also called primary / system memory) and storage (also called secondary memory). For example, memory 104 may include random-access memory (RAM), read-only memory (ROM), static RAM (SRAM), dynamic RAM (DRAM), ferro-electric RAM (FRAM®), electrically erasable programmable ROM (EEPROM), compact disc read-only memory (CD-ROM) or other optical disc memory, hard disk drive (HDD), such as magnetic disk memory or other magnetic storage devices, flash drive, solid-state drive (SSD), or any other medium that can be used to store or contain desired program code in the form of instructions that can be accessed and executed by processor 102. In a broad sense, memory 104 can be implemented by any computer-readable medium, such as non-temporary computer-readable medium. Although Figures 7 and 8 show only one memory location, it can be understood that multiple memory locations may be included.

[0022] Interface 106 may broadly include data and communication interfaces for receiving and transmitting signals in the process of sending and receiving information with other external network elements. For example, interface 106 may include input / output (I / O) devices and wired or wireless transceivers. Although only one memory is shown in Figures 7 and 8, it should be understood that multiple interfaces may be included.

[0023] The processor 102, memory 104, and interface 106 can be implemented in various forms in system 100 or 200 and used to perform video encoding and decoding functions. In some embodiments, the processor 102, memory 104, and interface 106 of system 100 or 200 are implemented (e.g., integrated) in one or more system-on-chip (SoCs). In one example, the processor 102, memory 104, and interface 106 can be integrated into an application processor (AP) SoC, which controls application processing in an operating system (OS) environment that includes applications that perform video encoding and decoding. In another example, the processor 102, memory 104, and interface 106 can be integrated into a dedicated processor chip for video encoding and decoding, such as a GPU or ISP chip dedicated to image and video processing in a real-time operating system (RTOS).

[0024] As shown in Figure 1, in the encoding system 100, the processor 102 may include one or more modules, for example, an encoder 101. Although Figure 1 shows that the encoder 101 is located within a single processor 102, the encoder 101 may include one or more submodules, and it should be understood that these submodules can be implemented in different processors located close to or far from each other. The encoder 101 (and any corresponding submodule or subunit) may be a hardware unit of the processor 102 (e.g., part of an integrated circuit), which is designed to be used in conjunction with other components or software units implemented by the processor 102 by executing at least a portion of a program (e.g., instructions). The program instructions can be stored in a computer-readable medium, for example, memory 104, and when executed by the processor 102, they can perform processes having one or more functions related to video encoding, such as image segmentation, inter-prediction, intra-prediction, transformation, quantization, filtering, and entropy coding, as will be specifically described later.

[0025] Similarly, as shown in Figure 2, in the decoding system 200, the processor 102 may include one or more modules, for example, a decoder 201. Although Figure 2 shows that the decoder 201 is located within a single processor 102, the decoder 201 may include one or more submodules, and it should be understood that these submodules can be implemented in different processors located close to or far from each other. The decoder 201 (and any corresponding submodule or subunit) may be a hardware unit of the processor 102 (e.g., part of an integrated circuit), which is designed to be used in conjunction with other components or software units implemented by the processor 102 by executing at least a portion of a program (e.g., instructions). The program instructions can be stored in a computer-readable medium, for example, memory 104, and when executed by the processor 102, they can perform processes having one or more functions related to video decoding, such as entropy decoding, dequantization, inverse transformation, interpretation, intraprediction, and filtering, as will be specifically described later.

[0026] Figure 3 shows a detailed block diagram of an exemplary encoder 101 in the encoding system 100 of Figure 1 according to several embodiments of the present disclosure. As shown in Figure 3, the encoder 101 may include a splitting module 302, an inter-prediction module 304, an intra-prediction module 306, a conversion module 308, a quantization module 310, an inverse quantization module 312, an inverse conversion module 314, a filtering module 316, a buffer module 318, and an encoding module 320. Each element shown in Figure 3 is shown independently in the video encoder to represent a distinct function, and it should be understood that this does not mean that each component consists of separate hardware or a single software component unit. In other words, for the sake of ease of explanation, each element is listed together as an element, but at least two elements may be combined together to form a single element, or one element may be divided into multiple elements for performing a function. It should also be understood that some elements are not required to perform the functions described in the present disclosure and may be optional elements for performance improvement. It should also be understood that these elements can be implemented by electronic hardware, firmware, computer software, or any combination thereof. Whether such elements are implemented as hardware, firmware, or software is determined by the specific application and design constraints imposed on the encoder 101.

[0027] The splitting module 302 may be configured to split a video input image into at least one processing unit. The image may be a video frame or a video field. In some embodiments, the image includes a monochrome luminance sample array, or a luminance sample array and two corresponding chroma sample arrays. In this case, the processing unit may be a prediction unit (PU), a transform unit (TU), or a coding unit (CU). The splitting module 302 can encode the image by splitting the image into a combination of coding units, prediction units, and transform units, and selecting a combination of coding units, prediction units, and transform units based on a preset standard (e.g., a cost function).

[0028] Similar to H.265 / HEVC, H.266 / VVC is a block-based hybrid spatial and temporal predictive coding scheme. As shown in Figure 5, during the coding period, the input image 500 is first divided into square blocks CTU 502 by the partitioning module 302. For example, a CTU 502 may be a 128 × 128 pixel block. As shown in Figure 6, each CTU 502 in the input image 500 can be divided into one or more CU 602 by the partitioning module 302, and these CU 602 can be used for prediction and transformation. Unlike H.265 / HEVC, in H.266 / VVC, a CU 602 may be rectangular or square and can be coded without requiring further division into prediction units or transformation units. For example, as shown in Figure 6, the division from CTU 502 to CU 602 may include quadtree division (shown by a solid line), binary tree division (shown by a dashed line), and ternary tree division (shown by a dotted line). According to some embodiments, each CU602 may be as large as its root CTU502, or it may be subdivided into smaller 4x4 blocks of the root CTU502.

[0029] Referring to Figure 4, the inter-prediction module 304 may be configured to perform inter-prediction on the prediction unit, and the intra-prediction module 306 may be configured to perform intra-prediction on the prediction unit. The prediction unit can decide whether to use inter-prediction or intra-prediction, and determine specific information (e.g., intra-prediction mode, motion vector, reference image, etc.) according to each prediction method. In this case, the processing unit for performing the prediction may be different from the processing unit for determining the prediction method and specific content. For example, the prediction method and prediction mode can be determined in the prediction unit, and the prediction can be performed in the transformation unit. The residual coefficients in the residual block between the generated prediction block and the original block can be input to the transformation module 308. Furthermore, the encoding module 320 can encode prediction mode information, motion vector information, etc., along with residual coefficients or quantization levels, into a bitstream. It should be understood that in some encoding modes, it is not necessary to generate prediction blocks by the prediction module 304 or 306, and the original block can be encoded directly. It should also be understood that in some encoding modes, prediction, transformation, and / or quantization may be skipped.

[0030] In some embodiments, the interpretation module 304 can predict prediction units based on information about at least one of the preceding or succeeding images of the current image, and optionally, it can predict prediction units based on information about a subset of encoded regions in the current image. The interpretation module 304 may include submodules such as a reference image interpolation module, a motion prediction module, and a motion compensation module (not shown). For example, the reference image interpolation module can receive reference image information from the buffer module 318 and generate pixel information for an integer number of pixels or subpixels based on the reference image. For luminance pixels, pixel information for an integer number of pixels or subpixels in units of 1 / 4 pixels can be generated using an 8-tap interpolation filter with variable filter coefficients based on a discrete cosine transform (DCT). For chrominance signals, pixel information for an integer number of pixels or subpixels in units of 1 / 8 pixels can be generated using a 4-tap interpolation filter with variable filter coefficients based on a DCT. The motion prediction module can perform motion prediction based on the reference image interpolated by the reference image interpolation unit. Various methods can be used to calculate motion vectors, such as the full search-based block matching algorithm (FBMA), the three-step search (TSS), and the new three-step search (NTS) algorithm. Motion vectors may have motion vector values ​​in units of 1 / 2, 1 / 4, or 1 / 16 pixels, or integer pixels, based on interpolated pixels. The motion prediction module can predict the current prediction unit by changing the motion prediction method. Various methods can be used as motion prediction methods, such as the skip method, the merge method, the advanced motion vector prediction (AMVP) method, and the intra-block copy method.

[0031] Continuing to refer to Figure 3, in some embodiments, the intra-prediction module 306 can generate prediction units based on information about reference pixels surrounding the current block, where this information about reference pixels is pixel information in the current image. The reference pixels may be located in reference rows not adjacent to the current block. If a block in the vicinity of the current prediction unit is a block on which inter-prediction has been performed, and therefore a reference pixel is a pixel on which inter-prediction has been performed, then the reference pixels included in the inter-predicted block may be used in place of the reference pixel information of the neighboring block on which intra-prediction has been performed. That is, if a reference pixel is unavailable, at least one of the available reference pixels may be used in place of the unavailable reference pixel information. In intra-prediction, the prediction modes may include an angle prediction mode that uses reference pixel information according to the prediction direction and a non-angle prediction mode that does not use direction information when performing prediction. The mode for predicting luminance information may be different from the mode for predicting chrominance information, and the intra-prediction mode information or predicted luminance signal information for predicting luminance information can be used to predict chrominance information. When performing intraprediction, if the size of the prediction unit is the same as the size of the transformation unit, intraprediction can be performed on the prediction unit based on the leftmost pixel, top-leftmost pixel, and topmost pixel of the prediction unit. However, if the size of the prediction unit is different from the size of the transformation unit when performing intraprediction, intraprediction can be performed using the reference pixels based on the transformation unit.

[0032] The intra-prediction method can generate a prediction block after applying an adaptive intra-smoothing (AIS) filter to a reference pixel according to the prediction mode. The type of AIS filter applied to the reference pixel may vary. To perform the intra-prediction method, the intra-prediction mode of the current prediction unit can be predicted according to the intra-prediction modes of prediction units in the vicinity of the current prediction unit. When predicting the prediction mode of the current prediction unit using mode information predicted according to adjacent prediction units, if the intra-prediction mode of the current prediction unit is the same as the intra-prediction mode of a neighboring prediction unit, information indicating that the prediction mode of the current prediction unit is the same as the prediction mode of a neighboring prediction unit can be transmitted using pre-set flag information. If the prediction mode of the current prediction unit and the prediction mode of a neighboring prediction unit are different, the prediction mode information of the current block can be encoded using additional flag information.

[0033] As shown in Figure 3, predictions can be made based on prediction units generated by prediction modules 304 or 306, and residual blocks can be generated that include prediction units and residual coefficient information (also referred to as "residuals" in this paper) as the difference between the prediction units and the original blocks. The generated residual blocks can be input to the transformation module 308. Further details on residuals and transformations for video encoding are now provided.

[0034] In hybrid video coding systems, redundancy in the video signal is first utilized by applying an inter- or intra-prediction tool to each CU (Critical Unit). The difference between the original sample of a CU and the predicted block of that CU is usually called the residual. Even after prediction, residuals remain strongly spatially correlated. While conditional entropy coding can capture some spatial dependencies between adjacent samples, forming an entropy coding statistical model that fully utilizes the spatial correlations within residuals is computationally impractical. By comparison, transform coding is a practical and efficient method for spatially decorrelating residuals.

[0035] For example, the transformation module 308 can transform residuals using an integer version of the two-dimensional discrete cosine transform (DCT), which is applicable both horizontally and vertically. For an MxN residual sample block (where M is the width of the block and N is the height of the block), the transformation module 308 can obtain intermediate transformation coefficients by applying the MxM DCT to each row to obtain transformation coefficients, and then apply the NxN DCT to each column of these intermediate transformation coefficients.

[0036] For intra-encoded CUs (also referred to as "intraCUs" in this paper), the current block is predicted using spatially adjacent reconstructed samples, and the intra-prediction mode is once signaled for the entire CU. Each CU consists of one or more collated coded blocks (CBs) corresponding to the color components of the video sequence. For example, consumer video typically uses a 4:2:0 chroma format, in which case each CU consists of one luminance CB and two chroma CBs, with the chroma CB having one-quarter the number of samples as the luminance CB. Intra-prediction and transform coding are performed at both the prediction block (PB) level and the transform block (TB) level. Each CB consists of a single TB, excluding intra-subpartition (ISP) mode and implicit partitioning. For luminance CBs, the maximum side length of the TB is 64, and the minimum side length is 4. Furthermore, the luminance TB is specified as a W×H rectangular block with width W and height H, where W,H ∈ {4, 8, 16, 32, 64}. For a chroma CB, the side length of the largest TB is 32, and the chroma TB is a rectangular W×H block with width W and height H. Here, W,H ∈ {2, 4, 8, 16, 32}, but in order to satisfy memory architecture and throughput requirements, blocks with a shape of 2×H and blocks with a shape of 4×2 are excluded.

[0037] Figure 7 shows a schematic diagram 700 of the current CU block 702 and spatially adjacent and spatially non-adjacent reconstruction samples of the current block according to several aspects of the present disclosure. In Figure 7, the numbers 0, 1, 2... indicate the pixel row indices associated with the current CU block 702.

[0038] In VVC, an intra-predictive sample of the current block is generated from reference samples obtained from reconstructed samples of adjacent blocks. For a W×H block, the reference sample consists of a vertical line containing 2·H reconstructed samples that are spatially adjacent to the current block and located to the left of the current block, extending downwards, and a horizontal line containing the upper left reconstructed sample and 2·W reconstructed samples located above the current block, extending to the right. This "L"-shaped sample set may be referred to as a "reference line" in this disclosure. The reference line directly adjacent to the current CU block 702 is shown in Figure 7 as the row with index 0.

[0039] Similar to AVC and HEVC, VVC also supports an angle intra-prediction mode. Angle intra-prediction is a directional intra-prediction method. Compared to HEVC, VVC's angle intra-prediction is improved through enhanced prediction accuracy and adaptation to a new partitioning framework. The former is achieved by increasing the number of angle prediction directions and using more accurate interpolation filters, while the latter is achieved by introducing a wide-angle intra-prediction mode. In VVC, the number of directional modes available for a given block has increased from 33 directions in HEVC to 65 directions. Figure 8 shows the 800 angle modes for VVC.

[0040] Directions with even index numbers between 2 and 66 are equivalent to the angular mode directions supported by HEVC. For rectangular blocks, the same number of angular modes are assigned to the top and left side of the block. On the other hand, rectangular intrablocks, which do not exist in HEVC, are the central part of the VVC division scheme, and additional intraprediction directions are assigned to the long sides of the block. Additional modes assigned along the long sides are called wide-angle intraprediction (WAIP) modes because these additional modes correspond to prediction directions where the angle with respect to the horizontal or vertical mode is greater than 45°. As shown in Figure 8, the WAIP modes for a given mode index are limited in such a way that the original directional mode is mapped to a mode with an index offset equal to 1 that has the opposite direction. For a given rectangular block, the aspect ratio (i.e., the ratio of width to height) determines which angular mode is replaced by the corresponding wide-angle mode.

[0041] In the case of a rectangular block in VVC, predictive samples for each pair of horizontally or vertically adjacent samples are predicted based on the paired adjacent reference samples. Conversely, WAIP extends the angular range of directional prediction to more than 45°, and therefore, for coded blocks predicted in WAIP mode, adjacent predictive samples can be predicted based on non-adjacent reference samples.

[0042] In addition to the directly adjacent rows of neighboring samples, one of the two non-adjacent reference rows (rows 1 and 2) shown in Figure 7 may further contain an input sample for intra-prediction in VVC. In the case of ECM, more non-adjacent reference rows are available. The use of adjacent and non-adjacent reference samples is called multiple reference line (MRL) prediction.

[0043] The intra-modes available for MRL are the DC mode and the angle prediction mode. However, not all of these modes are combinatorial for MRL for a given block. MRL modes are always coupled with modes in the most probable mode (MPM) list in VVC. Such coupling means that if non-adjacent reference rows are used, the intra-prediction mode is one of the MPMs. The design of MRL prediction modes based on such MPMs is inspired by the observation that non-adjacent reference rows are primarily favorable for texture patterns with sharp and highly directional edges. In these cases, MPMs are more frequently chosen because there is usually a strong correlation between the texture patterns of adjacent blocks and the texture patterns of the current block. On the other hand, choosing a non-MPM for intra-prediction can indicate that the edges are not uniformly distributed within adjacent blocks, and therefore, in such cases, the MRL prediction mode is expected to be less useful. It has also been observed that if the intra-prediction mode is a planar mode, MRL does not provide additional coding gain, because this mode is typically used for smoothing regions. Therefore, MRL does not always include the planar mode, which is one of the MPMs. The angle or DC prediction process in MRL is very similar to that in the case of directly adjacent reference rows. However, for angular modes with non-integer slopes, a DCT-based interpolation filter (DCTIF) is always used. The choice of such a design may be demonstrated by experimental results or may be consistent with experience and observation, namely that MRL is mainly favorable for sharp and highly directional edges, and for sharp and highly directional edges, DCTIF is more suitable than some other filters because it can retain more higher frequencies.

[0044] From a hardware design perspective, applying multiple reference rows, as proposed in earlier methods, incurs the cost of an extra row buffer, of which the row buffer is used to store additional reference rows. In typical hardware designs, the row buffer is part of the on-chip memory architecture for image and video encoding, and minimizing the on-chip area of ​​the row buffer is critical. To address this issue, MRLs are prohibited and unsignalized for encoding units attached to the top boundary of the CTU. This scheme constrains the additional buffer for storing non-adjacent reference rows to a maximum unit size width of 128.

[0045] In some known methods, intra-prediction fusion methods have been proposed to improve the accuracy of intra-prediction. More specifically, if the current block is a luminance block, encoded in a non-integer tilt angle mode, not in ISP mode, and the block size (width * height) is greater than 16, then "fusion" is performed on two prediction blocks generated based on two different reference lines, of which the prediction fusion is calculated by the weighted sum of the two prediction blocks. More specifically, in the bitstream, the first reference line (line) whose index is i according to the current signaling transmission method i Specify ) and the prediction block generated based on the reference row by the selected intra prediction mode is p(line i Represented by ), where p(·) represents the operation of generating a prediction block based on the reference row using a given intra prediction mode. In known methods, the reference row line i+1 The second reference row is implicitly selected. That is, the second reference row is an index position that is further from the current block than the first reference row. Similarly, the predicted block generated based on the second reference row is p(line i+1 This is expressed as follows. According to equation (1), a weighted sum of the two prediction blocks is obtained, and this weighted sum is used as the predicted value of the current block. p fusion =w0*p(line i )+w1*p(linei+1 ) (1) Eventually, p fusion The fusion prediction is represented, and w0 and w1 are two weighting factors, which are set to 3 / 4 and 1 / 4 respectively in the experiment.

[0046] Figure 9A shows a schematic diagram of the intraTMP search area 900 according to some embodiments of the present disclosure.

[0047] Intra-template matching prediction (intraTMP) is a special intra-prediction mode that copies the optimal prediction block from the reconstruction portion of the current frame. The L-shaped or other-shaped template of the optimal prediction block matches the current template. Unlike inter-block copy (IBC), block vectors are not signaled in the bitstream. Within a predefined search range, encoder 101 searches the reconstruction portion of the current frame for the template most similar to the current template and uses the corresponding block as the prediction block. Encoder 101 then signals the use of this mode, and the same prediction operation is performed by decoder 201.

[0048] As shown in Figure 9A, a prediction signal is generated by matching the current block's predefined causal neighborhood with another block within a predefined search region consisting of the current CTU, upper-left CTU, top CTU, and left-side CTU.

[0049] The sum of absolute differences (SAD), the sum of absolute transformed differences (SATD), or the hash value comparison between templates are used as the cost function. Within each region, decoder 201 searches for the template with the minimum cost for the current template and uses the corresponding block as the prediction block.

[0050] By setting the size of the entire region (searchRangeWidth, searchRangeHeight) to be proportional to the block size (BlkW, BlkH), a fixed number of SAD comparisons are performed per pixel. For example, searchRangeWidth = a * BlkW and searchRangeHeight = a * BlkH, where "a" is a constant that controls the gain / complexity trade-off. In practice, "a" is equal to 5 in the ECM-7.0 test software.

[0051] To speed up the template matching process, an initial traverse is performed in the search region with an increment of two pixels each time. This is also called the search subsampling factor 2. This reduces the complexity of the template matching search by a quarter. After finding the best match from the initial search, the refinement process is performed. Refinement is completed by a second template matching search that encloses the best match with a smaller range. The range of reduction is defined as min(BlkW,BlkH) / 2, where BlkW and BlkH are the width and height of the current block, respectively.

[0052] Enable the intra-template matching prediction tool for CUs with a width and height of 64 or less. The maximum CU size for intraTMP can be configured. If the decoder-side intra-mode derivation DIMD is not currently used for a CU, a dedicated flag signals the intraTMP mode at the CU level.

[0053] Figure 9B shows a schematic diagram of the intraTMP extended search area 901 according to some embodiments of the present disclosure.

[0054] The original intraTMP method implicitly selects only one block vector by searching for the minimum template matching cost. However, for content captured by a camera, template matching alone cannot find a good prediction. Typically, there are several blocks similar to the current block, and their template matching costs are equivalent. The BV with the minimum template matching cost may not be the best prediction for the current block. To further improve encoding performance, a multiple candidate method can be used in intraTMP. In the multiple candidate method, a list of prediction candidates is constructed using candidate BVs. These candidate BVs are sorted in ascending order of their corresponding template matching costs. This candidate list is constructed by both the encoder 101 and the decoder 201. An index is signaled in the bitstream to indicate which candidate BV has been selected for the current block. This method uses template matching to select a final list of promising candidates from a large number of possible BVs, and then allows the encoder 101 (which can check the actual encoding cost of the current block for each of these candidates) to perform a rate-distortion optimized (RDO) decision from the final candidate list. Compared to RDO in encoders, the complexity of building the candidate list is lower.

[0055] Table 1 below shows the proposed syntax changes.

[0056] [Table 1]

[0057] In Table 1, an intra_tmp_flag equal to 1 indicates that intraTMP is used in the current block, and intra_tmp_idx further indicates which BV in the candidate BV list will be used to mark the predicted block.

[0058] To construct a candidate list, sparse search and refinement search can be used. In sparse search, the subsampling factor is set to 3, and the 30 BVs with the minimum SAD cost after the sparse search are retained. In refinement search, a 3x3 local search is checked around each of the 30 BVs. After the refinement search, the 15 BVs with the minimum SAD cost are selected to form a candidate list.

[0059] The intraTMP fusion method first obtains multiple intraTMP predicted value blocks, and then fuses them to generate a better overall predicted value. These predicted value blocks may also be called "match blocks," "fused blocks," or "predicted values." The intraTMP fusion method is considered advantageous for content captured by a camera. In short, the intraTMP fusion method may include the following four operations.

[0060] In the first operation, the intraTMP fusion method can generate multiple candidate predicted values ​​during the intraTMP search period. For example, first, if the search subsampling factor is 3, a sparse intraTMP search process is performed. After the sparse search, a candidate list is generated with 30 candidate BVs that have the smallest template SAD. Around each candidate BV, a full-pixel refinement search is performed within a small area. The refinement area is a 3x3 region around each of the 30 candidate BVs. Finally, three optimal candidate BVs determined by the template SAD are selected across all refinement areas. The block pointed to by each of these candidate BVs is selected as the candidate predicted value block for intraTMP fusion.

[0061] In the second operation, the intraTMP fusion method can select candidate predicted values ​​for fusion. For example, for each of the three candidate predicted value blocks, a threshold is used to determine whether or not each should be used for fusion, as shown in equation (2) below. Threshold=SAD1<<1 (2) Among them, SAD1 is the minimum template SAD of the three candidate prediction value blocks. Select and fuse the candidate prediction value blocks where SAD <= Threshold. Thereby, the number of candidate prediction value blocks selected for fusion is also determined.

[0062] In the third operation, the intraTMP fusion method can calculate the weighting factors of each prediction value block selected for fusion. For example, once the prediction value blocks waiting for fusion are determined, they are fused by weights. According to the present disclosure, two methods for determining these fusion weights can be used.

[0063] In the first method of the third operation, the fusion weight w1 is calculated based on their SADs. Calculate the fusion weight w1 according to equations (3) and (4).

Equation

[0064] To simplify the implementation, the division operation is replaced with an integer look-up table (LUT). In the second method of the third operation, the complexity is further reduced by a fusion weight with a constant value. The weight is

Equation

[0065] In the fourth operation, the intraTMP fusion method can determine the final fusion prediction value according to equation (5).

Equation

[0066] Continuing to refer to the fourth operation, in the special case where only one prediction value block is retained after the second operation, calculate the final prediction value according to equation (6). p fusion =w1p TMP +w2p intra (6) Eventually, p TMP is a single predicted value block, p intra This is the intra-predicted value obtained by the planar mode. In this special case, the weights are set to w1=7 / 8 and w2=1 / 8.

[0067] A CU level flag can be added to the bitstream to signal whether an intraTMP CU is predicted by the proposed intraTMP fusion method or by the proposed original intraTMP method.

[0068] For small blocks, the search range may be too small, making it difficult to find good matches. For small blocks, an expanded search range is suggested, for example, searchRangeWidth=max(a*BlkW,minSearchRange) and searchRangeHight=max(a*BlkH,minSearchRange), where minSearchRange is set to 128.

[0069] Furthermore, in the original intraTMP, if the left-hand region and top-hand region of a part of the current block approach the current block, the search is not performed on these regions. As shown in Figure 9B, it is proposed to search these regions.

[0070] Figure 10 shows the spatial components of the intraTMP filter 1000 according to some embodiments of this disclosure.

[0071] Referring to Figure 10, further filtering of the blocks selected by intraTMP can provide better predictions. To achieve this objective, a 6-tap filtering process is proposed that includes a 5-tap plus spatial component and a bias term. The inputs to the 5-tap spatial component of the filter consist of the center (C) sample in the reference block and its upper / north (N), lower / south (S), left / west (W), and right / east (E) neighborhoods, of which the center sample is located at the corresponding position of the sample in the current block awaiting prediction.

[0072] Figure 11 shows a reference region 1100 used to obtain the filter coefficient of the intraTMP in some embodiments of the present disclosure.

[0073] Referring to Figure 11, the bias term B represents the scalar offset between the input and output and is set to a moderate luminance value (512 for 10-bit content). The filter output is calculated according to equation (7). predLumaVal=c0C+c1N+c2S+c3E+c4W+c5B (7)

[0074] As shown in Figure 11, the filter coefficient ci can be calculated by minimizing the mean-squared error (MSE) between the filtered reference template and the current template 1. The extended region, shown in dark gray, supports "side samples" for the plus-type spatial filter. If unavailable, pixels within the extended region can be obtained by boundary padding using adjacent BV information, or by boundary padding without it.

[0075] Minimizing the MSE is performed by calculating the autocorrelation matrix between the input of the reference template and the output of the current template. An LDL decomposition is performed on the autocorrelation matrix (where L is a unit lower triangular matrix and D is a diagonal matrix), and the final filter coefficients are calculated using the back substitution method.

[0076] The encoded CU level flag signals the use of filtered intraTMP mode. Filtered intraTMP is considered a submode of intraTMP; that is, the intraTMP filter flag is signaled only if the intraTMP flag is true.

[0077] Furthermore, a filtered intraTMP can be selected from a list of candidate reference blocks awaiting filtering. The candidate list is constructed based on the minimum SAD cost of unfiltered templates. Different filter parameters are calculated for each candidate in the list, and the candidate that shows the best performance in terms of template matching cost for filtering is selected and used as the final candidate. The final prediction of the block is then generated by applying the resulting filter to the optimal candidate.

[0078] Figure 12 shows the adjacent half-pixel positions 1200 in eight directions according to some embodiments of the present disclosure.

[0079] Referring to Figure 12, we propose an intraTMP method with half-pixel accuracy to provide better predictions. More specifically, as shown in Figure 12, eight adjacent half-pixel positions are added in eight directions surrounding the integer pixel position, and the proposed method selects one of the nine positions (one integer pixel position + eight half-pixel positions) by encoder rate distortion optimization (RDO).

[0080] If intraTMP mode is selected for the current block, a flag is signaled to indicate whether to use integer pixel precision or half-pixel precision. If half-pixel precision is used, an index is signaled to indicate the direction of the half-pixel position. For half-pixel interpolation in fractional intraTMP, a 4-tap DCT-IF interpolation filter, i.e., [-5,37,37,-5], is used.

[0081] Inspired by the "Combined Inter-and-Intra-Prediction" CIIP mode, a spatially combined inter-and-intra-prediction (CIIP) mode is proposed as a new intra-prediction mode. When the spatial CIIP mode is selected, prediction value blocks are generated by combining intraTMP prediction values ​​with intra-predictions generated by template-based intra-mode derivation (TIMD). These combinations are weighted by predefined weights. Spatial CIIP can be considered a special case of intraTMP fusion.

[0082] Figure 13 shows diagrams of various template shapes used for intraTMP according to some embodiments of this disclosure.

[0083] Referring to Figure 13, two other template shapes (e.g., left template and top template) used for intraTMP are proposed. The left template and top template are considered two additional intraTMP modes. Furthermore, according to equation (8), the two optimal candidates found by the L-shaped template are saved and linearly merged together as follows to generate a fusion prediction.

number

[0084] To signal the new mode, if intraTMP is currently used in the CU, it will also signal two flags to indicate whether an L-shaped template with fusion, a left template, or an upper template is applied, which are specifically described in detail in Table 2 below.

[0085] [Table 2]

[0086] While each of the above intraTMP methods provides coding gain, combining them is not straightforward or direct. Simultaneously employing and directing the above intraTMP methods without restriction may result in excessive signaling overhead, yet fail to provide sufficient predictive improvement to prove that the bits spent on signaling are reasonable. To overcome these and other challenges, this disclosure describes a combination of efficient signaling schemes that provides cumulative coding gain from the combined intraTMP methods.

[0087] For example, in some implementations, this disclosure proposes that an intraTMP coding tool can be signaled by syntax elements which can be summarized as follows:

number

[0088] First, an intraTMP flag (intra_tmp_flag) can be signaled to indicate whether the current block is predicted by intraTMP. The syntax element may be decoded from the bitstream, or it may have an estimate. For example, if the use of the intraTMP tool is prohibited at a higher syntax level (e.g., sequence parameter set, SPS), the intraTMP flag may have an estimate of 0.

[0089] If a block is currently predicted by intraTMP, an intraTMP fusion flag (intra_tmp_fusion_flag) can be signaled to indicate whether the intraTMP predicted value is determined by fusing multiple reference blocks. Regardless of the value of the intraTMP fusion flag, a sparse search pass and a refinement search pass can be performed to construct a candidate list containing N intraTMP block vectors. From this list, N intraTMP block vectors are selected by choosing block vectors based on the SAD cost calculated in the template region. Additional details of the candidate list construction process are provided below. In this embodiment, N is 15 or greater. Block vectors from the intraTMP candidate list are bv0, bv1, ... bv N-1 Mark it as follows. The reference blocks corresponding to the block vector from the intraTMP candidate list are r0, r1, ... r N-1 Mark it as such.

[0090] If a block is currently predicted by the intraTMP fusion mode (intra_tmp_fusion_flag is 1), both the intraTMP fusion index (intra_tmp_fusion_idx) and the intraTMP fusion weight type (intra_tmp_fusion_weight_type) are signaled in the bitstream. The fusion prediction value is determined according to equation (9).

number

[0091] [Table 3]

[0092] The method for calculating fusion weights is selected by the intraTMP fusion weight type (intra_tmp_fusion_weight_type). intra_tmp_fusion_weight_type is a flag that can take values ​​of 0 or 1. For example, if intra_tmp_fusion_weight_type is 0, the weights can be determined by an algorithm based on SAD (see equations (10) and (11) below). i This represents the SAD cost of the i-th intraTMP candidate.

number

[0093] If intra_tmp_fusion_weight_type is 1, instead, the set of 6 weights {w} is used by minimizing the MSE between the fusion of adjacent template regions of the 5 reference blocks and the adjacent template region of the current block. A ,w A+1 ,...w B ,w N} may be determined. That is, each reference block r i The adjacent template is t i If the adjacent template of the current block is t, then the weight can be determined according to expression (12).

number

[0094] As mentioned above, one way to solve this minimization problem is to decompose it using LDL.

[0095] Currently, if a block is not predicted by intraTMP fusion (intra_tmp_fusion_flag is 0) and is predicted by intraTMP, the intraTMP index is signaled to mark a single block vector from the candidate list. The same candidate list is constructed regardless of whether intraTMP fusion is used or not. However, by modifying the construction of the candidate list compared to the known method described above, we combine the search for multiple candidates by sparse paths and refinement paths with the search for candidates by different template shapes.

[0096] In sparse search, candidate block vectors are searched in parallel, thereby minimizing the SAD cost calculated for L-shaped templates, left-only templates, and top-only templates. The same block vector can be selected, but the SAD costs corresponding to different template shapes cannot be compared. If M candidates are retained for each sparse search, a total of 3xM candidate BVs will be retained after the sparse search. Of these, M candidate BVs exist for each template shape type. In refinement search, a 3x3 local search is performed around each sparse candidate BV, where the corresponding template shape is adopted. In some implementations, the left-only template cost and top-only template cost can be calculated simultaneously with the L-shaped template cost, which can significantly optimize the search algorithm.

[0097] In one configuration, the length of the candidate list can be increased to 19 to accommodate a greater variety of block vectors. Selecting up to 19 block vectors with the lowest SAD cost in an L-shaped template and sorting them in ascending order of SAD cost results in the block vectors with the lowest SAD cost being placed first, with the remaining block vectors sorted in ascending order of their respective associated SAD costs. Similarly, select up to 3 block vectors with the lowest SAD cost in a left-only template and sort them in ascending order, and so on. Assuming all block vectors are unique, the candidate list is constructed with 13 L-shaped template candidates, 3 left-only template candidates, and 3 top-only template candidates. The L-shaped template candidates are placed at the lowest index. This is due to the binarization scheme used to signal the intraTMP index, which means signaling these candidates with less overhead. Block vectors selected by searching using left-only or top-only templates typically have a small template area and therefore a low SAD cost; however, L-template candidate block vectors are still preferred because they are more likely to find good predictions for the current block in L-shaped templates. If any BVs found by searching using different template shapes are all the same, the redundant BV is removed from the top-only or left-only candidates. For example, if only one left-only template candidate is unique and only two top-only template candidates are unique, the final candidate list will consist of 16 L-shaped template candidates, one left-only template candidate, and two top-only template candidates.

[0098] In an alternative configuration, the candidate list length is 19. This selects up to 19 BVs with the lowest SAD cost in L-shaped templates, while simultaneously selecting up to 2 BVs with the lowest SAD cost in left-only templates, and up to 2 BVs with the lowest SAD cost in left-only templates. For example, if all BVs are unique, the candidate list would consist of 15 L-shaped template candidates, 2 left-only template candidates, and 2 top-only template candidates.

[0099] In one configuration, the candidate list is constructed from the following candidate BVs: Candidate BVs from L-shaped template search are listed first, followed by candidates from other template shapes in a fixed order, for example, the one immediately following is a candidate from top-only template search, and the one after that is a candidate from left-only template search.

[0100] In an alternative configuration, the candidate list is constructed using the following candidate BVs: Candidate BVs from the L-shaped template search are listed first, followed by candidates from the template shape with the next largest area, and finally candidates from the template shape with the smallest area. For example, if the area of ​​a top-only template is larger than the area of ​​a left-only template, the candidate list is constructed using the following candidate block vectors: Candidate block vectors from the L-shaped template search are listed first, followed by candidates from the top-only template search, and finally candidates from the left-only template search. The template area is currently determined by the height (h) and width (w) of the block. For example, if h > w, then the area of ​​a left-only template is larger than the area of ​​a top-only template.

[0101] If the length of the candidate list is 19, the range of values ​​for the intra_tmp_idx syntax element may be from 0 to 18, and its binarization is as shown in Table 4, where x represents either 0 or 1.

[0102] [Table 4]

[0103] In other words, if the value of intra_tmp_idx is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by a 4-bit fixed-length code (intra_tmp_idx-2).

[0104] If a block is not currently fused via intraTMP (intra_tmp_fusion_flag is 0) and is predicted by intraTMP, then in addition to the intraTMP index, the intraTMP filter flag (intra_tmp_filter_flag) is used for the selected reference block r i The system signals whether or not to determine the prediction block by filtering. If intra_tmp_filter_flag is 1, the prediction block is determined by filtering with the trained filter c according to equation (13). The trained filter c in equation (13) can be determined by equation (14).

number

number

[0105] If a block is currently predicted by intraTMP and is neither fused nor filtered (intra_tmp_filter_flag is 0), an intraTMP sub-pixel flag (intra_tmp_sub_pel_flag) can be signaled to indicate whether the intraTMP BV should be further refined with fractional precision. If intra_tmp_sub_pel_flag is 0, the intraTMP block vector is not further modified. The predicted block is then the selected reference block r i That is the case.

[0106] If intra_tmp_sub_pel_flag is 1, the intraTMP BV is further refined by signaling the sub-pixel refinement direction (intra_tmp_sub_pel_direction_idx) and sub-pixel refinement phase (intra_tmp_sub_pel_phase_idx).

[0107] Figure 14 shows a diagram of fractional block vector positions 1400 used for intraTMP in some embodiments of the present disclosure.

[0108] Referring to Figure 14, the intraTMP block vectors selected by indexing into the candidate list have integer-level precision. In Figure 14, the black circles represent the coordinate space of the block vectors at integer intervals, and the central circle represents the selected intraTMP block vector bv i This represents the 24 sub-pixel refined block vectors that can be signaled by this embodiment of the signaling mechanism.

[0109] Then, as indicated by the arrows in Figure 14, sub-pixel refinement can be performed along one of eight directions. The sub-pixel refinement direction is signaled by intra_tmp_sub_pel_direction_idx, which takes a value in the range of 0 to 7 (represented by a 3-bit fixed-length code). The sub-pixel refined block vector distance bv is determined by intra_tmp_sub_pel_phase_idx. i The signaling for intra_tmp_sub_pel_phase_idx is such that a value of 0 indicates a 1 / 4 phase, a value of 1 indicates a 1 / 2 phase, and a value of 2 indicates a 3 / 4 phase. The binarization of intra_tmp_sub_pel_phase_idx can be indicated according to Table 5.

[0110] [Table 5]

[0111] Prediction blocks for sub-pixel refinement are determined by applying a one-dimensional interpolation filter in a separable manner, and the desired interpolation is achieved using a 1 / 4, 1 / 2, or 3 / 4 phase interpolation filter. The interpolation filter may be an existing interpolation filter used for motion compensation in ECM, or an existing ECM filter for intra-reference sample interpolation, or an interpolation filter specifically designed for intraTMP.

[0112] The following syntax elements can be signaled in different orders, and these syntax elements are independent of each other. For example, the signaling order of intra_tmp_fusion_idx and intra_tmp_fusion_weight_type may be reversed without changing the coding efficiency of the intraTMP coding tool, or the signaling order of intra_tmp_idx and intra_tmp_filter_flag may be reversed, or the signaling order of intra_tmp_sub_pel_phase_idx and intra_tmp_sub_pel_direction_idx may be reversed. For example, in some implementations, the syntax signaling order may be summarized as follows:

number

[0113] In some implementations, the `intra_tmp_sub_pel_flag` and `intra_tmp_sub_pel_phase_idx` syntax elements can be merged into a single syntax element (`intra_tmp_sub_pel_precision_idx`), and this single syntax element is `bv`. i The distance from the original block vector (BV) due to sub-pixel refinement is signaled. If intra_tmp_sub_pel_precision_idx is 0, the phase is 0, and the original block vector (bv) is signaled. iThis indicates that it is used. In such cases, subpixel block vector refinement is not used, and therefore the subpixel refinement direction is not signaled. If intra_tmp_sub_pel_precision_idx is 1, the phase is 1 / 4. If intra_tmp_sub_pel_precision_idx is 2, the phase is 1 / 2. If intra_tmp_sub_pel_precision_idx is 3, the phase is 3 / 4. The binarization of intra_tmp_sub_pel_precision_idx may be the same as the joining of syntax elements intra_tmp_filter_flag and intra_tmp_sub_pel_phase_idx. The binarization may be as shown in Table 6.

[0114] [Table 6]

[0115] Accordingly, the syntax element dependencies and signaling order may be summarized as follows:

number

[0116] Referring to Figure 3, the conversion module 308 can convert the video signal in the residual block from the pixel domain to the conversion domain (e.g., the frequency domain depending on the conversion method). It should be understood that in some examples, the conversion module 308 may be skipped, and the video signal may not need to be converted to the conversion domain.

[0117] The quantization module 310 may be configured to quantize the coefficients of each position within an encoded block to generate a quantization level of the position. The current block may be a residual block. That is, the quantization module 310 can perform the quantization process on each residual block. A residual block may contain N × M positions (samples), each position associated with a converted or unconverted video signal / data, e.g., luminance and / or chroma information, where N and M are positive integers. In this disclosure, before quantization, the converted or unconverted video signal at a particular position is referred to as a “coefficient”. After quantization, the quantized value of the coefficient is referred to as a “quantization level” or “level”.

[0118] Quantization can be used to reduce the dynamic range of a converted or unconverted video signal so that the video signal is represented with fewer bits. Quantization typically involves division by the quantization step size followed by rounding, while inverse quantization (also called de-quantization) involves multiplication by the quantization step size. The quantization step size can be specified by the quantization parameter (QP). Such a quantization process is called scalar quantization. Quantization of all coefficients within a coding block can be performed independently, and such quantization methods are used in several existing video compression standards, such as H.264 / AVC and H.265 / HEVC. The QP in quantization can affect the bitrate used for the encoded / decoded video image. For example, a higher QP results in a lower bitrate, and a lower QP results in a higher bitrate.

[0119] For an N×M coding block, the two-dimensional (2D) coefficients of the block can be converted to a one-dimensional (1D) order in a specific coding scan order for coefficient quantization and coding. Typically, the coding scan starts from the top-left corner and stops at the bottom-right corner of the coding block or the last non-zero coefficient / level in the bottom-right direction. It should be understood that the coding scan order may include any appropriate order, such as a zigzag scan order, a vertical (column) scan order, a horizontal (row) scan order, a diagonal scan order, or any combination thereof. The quantization of coefficients within the coding block can utilize the coding scan order information. For example, it can be determined by the state of the previous quantization level along the coding scan order. To further improve coding efficiency, the quantization module 310 can use one or more quantizers, for example, two scalar quantizers. Which quantizer to use to quantize the current coefficient can be determined by the previous information of the current coefficient along the coding scan order. Such a quantization process is called dependent quantization.

[0120] Referring to Figure 3, the encoding module 320 may be configured to encode the quantization level at each position within the encoding block into a bitstream. In some embodiments, the encoding module 320 can perform entropy coding on the encoding block. Entropy coding can convert each quantization level into a corresponding binarized representation, such as a binary bin, using various binarization methods, such as Golomb-Rice binarization. The binarized representation can then be further compressed by the entropy coding algorithm. The compressed data can be added to the bitstream. In addition to quantization levels, the encoding module 320 can encode various other information input from prediction modules 304 and 306, such as filtering information, encoding unit block type information, prediction mode information, partition unit information, prediction unit information, transmission unit information, motion vector information, reference frame information, and block interpolation information. In some embodiments, the encoding module 320 can perform residual coding on the encoding block to convert the quantization levels into a bitstream. For example, after quantization, N×M quantization levels may exist for an N×M block. These N × M levels may be zero or non-zero. If the non-zero levels are not binary, they can be further binarized to binary bins, for example, in combined truncated rice (TR) and restricted EGk binarization.

[0121] Non-binary syntax elements can be mapped to binary codewords. A bijective mapping between codewords and symbols, typically using a simple structured code, is also called binarization. The binary symbols (also called binary bins) of both binary syntax elements and codewords for non-binary data can be coded using binary arithmetic coding. The core coding engine of context-adaptive binary arithmetic coding (CABAC) can support two operating modes: a context coding mode that encodes binary bins with an adaptive probabilistic model, and a low-complexity bypass mode that uses a fixed probability of 1 / 2. The adaptive probabilistic model is also called a context, and assigning a probabilistic model to each binary bin is also called context modeling.

[0122] As shown in Figure 3, the inverse quantization module 312 may be configured to inversely quantize the quantization level, and the inverse transformation module 314 may be configured to inversely transform the coefficients transformed by the transformation module 308. The reconstructed residual blocks generated by the inverse quantization module 312 and the inverse transformation module 314 can be combined with the prediction units predicted by the prediction module 304 or 306 to generate a reconstructed block.

[0123] The filtering module 316 may include at least one of a deblocking filter, a sample adaptive offset (SAO), and an adaptive loop filter (ALF). The deblocking filter can remove block distortion that occurs at the boundaries between blocks in the reconstructed image. For videos that have already been deblocked, the SAO module can correct the offset relative to the original video at the pixel unit level. The ALF can be performed based on values ​​obtained by comparing the reconstructed and filtered video with the original video. The buffer module 318 may be configured to store the reconstructed blocks or images calculated by the filtering module 316, and the reconstructed and stored blocks or images can be provided to the interprediction module 304 when interprediction is performed.

[0124] Figure 4 shows a detailed block diagram of an exemplary decoder 201 in the decoding system 200 of Figure 2 according to several embodiments of the present disclosure. As shown in Figure 4, the decoder 201 may include a decoding module 402, an inverse quantization module 404, an inverse transform module 406, an interpretation module 408, an intrapretation module 410, a filtering module 412, and a buffer module 414. Although each element shown in Figure 4 is shown independently in the video decoder to represent a distinct function, it should be understood that this does not mean that each component consists of separate hardware or a single software component unit. That is, for the sake of clarity, each element is listed as an element, but at least two elements may be combined to form a single element, or one element may be divided into multiple elements for performing a function. It should also be understood that some elements are not required to perform the functions described in the present disclosure and may be optional elements for performance improvement. It should also be understood that these elements can be implemented by electronic hardware, firmware, computer software, or any combination thereof. Whether these elements are implemented as hardware, firmware, or software is determined by the specific application and design constraints imposed on the decoder 201.

[0125] When a video bitstream is input from a video encoder (e.g., encoder 101), the input bitstream can be decoded by the decoder 201 following a process in the reverse direction of the video encoder's flow. Therefore, for the sake of simplicity, some of the decoding details described above for encoding can be omitted. The decoding module 402 may be configured to decode the bitstream to obtain various information encoded in the bitstream, such as the quantization level of each position within the encoded block. In some embodiments, the decoding module 402 can perform entropy decoding (decompression) corresponding to the entropy coding (compression) performed by the encoder, such as video local-area network (VideoLAN) coding (VLC), context-adaptive variable-length coding (CAVLC), CABAC, syntax-based binary arithmetic coding (SBAC), PIPE coding, etc., to obtain a binary representation (e.g., binary bin). The decoding module 402 can further convert the binary representation to a quantization level using Golomb-Rice binarization (e.g., EGk binarization and combined TR and restricted EGk binarization). In addition to the quantization level of the position within the conversion unit, the decoding module 402 can further decode various other information such as parameters for Golomb-Rice binarization (e.g., Rice parameters), block type information of the coding unit, prediction mode information, partition unit information, prediction unit information, transmission unit information, motion vector information, reference frame information, block interpolation information, and filtering information. During the decoding process, the decoding module 402 can rearrange the bitstream and reconstruct and rearrange the data from a one-dimensional sequence to a two-dimensional rearranged block using a reverse scanning method based on the coding scan order used by the encoder.

[0126] The inverse quantization module 404 may be configured to inverse quantize the quantization level at each position of an encoded block (e.g., a two-dimensional reconstruction block) to obtain coefficients for each position. In some embodiments, the inverse quantization module 404 may perform dependent inverse quantization based on quantization parameters provided by the encoder. These quantization parameters include information about the quantizer used in the dependent quantization, such as the quantization step size used by each quantizer.

[0127] The inverse transform module 406 may be configured to perform inverse transforms, e.g., inverse DCT, inverse discrete sine transform (DST), and inverse KLT, respectively, on the DCT, DST, and KLT, LFNST, and / or NSPT performed by the encoder, to convert the data back from a transformation region (e.g., coefficients) to a pixel region (e.g., luminance and / or chroma information). In some embodiments, the inverse transform module 406 can selectively perform transform operations (e.g., DCT, DST, KLT, LFNST, NSPT) based on various information such as the prediction method, the current block size, and the prediction direction.

[0128] Additionally and / or alternatively, the inter-prediction module 408 and the intra-prediction module 410 may be configured to generate prediction blocks based on information related to the generation of prediction blocks provided by the decoding module 402 and information on previous decoded blocks or images provided by the buffer module 414. As described above, if the size of the prediction unit is the same as the size of the transform unit when intra-prediction is performed in the same manner as the encoder operation, intra-prediction can be performed on the prediction unit based on the pixels on the left side, the pixels on the upper left side, and the pixels on the top of the prediction unit. However, if the size of the prediction unit is different from the size of the transform unit when intra-prediction is performed, intra-prediction can be performed using reference pixels based on the transform unit.

[0129] For example, the interpretation module 408 may be configured to receive a bitstream from the encoder containing a reference frame, a current frame, and instructions for a weighting factor associated with a multimedia home platform (MHP) flow. The interpretation module 408 may be configured to perform an MHP flow on a CU located in the current frame based on a lookup block in the reference frame (e.g., the reference frame and / or reference template). In some embodiments, to perform an MHP flow, the interpretation module 408 may be configured to perform template matching on a CU located in the current frame based on a lookup block in the reference frame and the weighting factor to obtain motion information. In some embodiments, to perform an MHP flow, the interpretation module 408 may be configured to identify a weighting factor index associated with a weighting factor based on template matching. The interpretation module 408 may be configured to identify a weighting factor symbol for a weighting factor based on instructions contained in the bitstream. The interpretation module 408 may be configured to perform an interpretation process based on the current frame, the reference frame, the weighting factor index, and the weighting factor symbol for a weighting factor to decode the bitstream.

[0130] The reconstructed blocks or images combined by the outputs of the inverse transform module 406 and the prediction module 408 or 410 may be provided to the filtering module 412. The filtering module 412 may include a deblocking filter, an offset correction module, and an ALF. The buffer module 414 stores the reconstructed images or reconstructed blocks and can use them as reference images or reference blocks for the interprediction module 408, and can also output reconstructed images.

[0131] Within the scope of this disclosure, the encoding module 320 and the decoding module 402 may be configured to employ a quantization level binarization scheme having Rice parameters suitable for the bit depth and / or bitrate used to encode the video images, in order to improve encoding efficiency.

[0132] Figures 15A to 15D show flowcharts of exemplary method 1500 for video decoding according to some embodiments of the present disclosure. Method 1500 is executable by a system, some examples of which include a decoding system 200, a decoder 201, or an intra-prediction module 410. Method 1500 may include operations 1502 to 1552 described below. It should be understood that some steps are optional, some steps may be performed simultaneously, or in an order different from the order shown in Figures 15A to 15D.

[0133] Referring to Figure 15A, at 1502, the system can decode multiple syntax elements associated with intraTMP by analyzing the bitstream.

[0134] In 1504, the system can decode a first syntax element from the bitstream. For example, an intraTMP flag (intra_tmp_flag) may be signaled to indicate whether the current block is predicted by intraTMP. This syntax element may be decoded from the bitstream, or it may have an estimate. For example, if the use of the intraTMP tool is prohibited at a higher syntax level (e.g., Sequence Parameter Set (SPS)), the intraTMP flag may have an estimate of 0.

[0135] In 1506, the system can determine whether intraTMP mode is enabled for the current block based on a first syntax element. For example, an intraTMP flag (intra_tmp_flag) can be signaled to indicate whether the current block is predicted by intraTMP. The syntax element may be decoded from the bitstream, or it may have an estimate. For example, if the use of the intraTMP tool is prohibited at a higher syntax level (e.g., Sequence Parameter Set (SPS)), the intraTMP flag may have an estimate of 0.

[0136] In 1508, given that intraTMP mode is enabled for the current block, the system can decode the second syntax element from the bitstream. For example, if the current block is predicted by intraTMP, an intraTMP fusion flag (intra_tmp_fusion_flag) can be signaled to indicate whether the intraTMP prediction value is determined by fusing multiple reference blocks.

[0137] In 1510, the system can determine, based on the second syntax element, whether the intraTMP predicted value of the current block is determined by the intraTMP fusion mode. For example, if the current block is predicted by the intraTMP fusion mode, the value of intra_tmp_fusion_flag can be represented as 1; otherwise, the value can be represented as 0.

[0138] In step 1512, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the system can decode the third and fourth syntax elements from the bitstream. For example, if the current block is predicted by the intraTMP fusion mode (intra_tmp_fusion_flag is 1), the system signals the intraTMP fusion index (intra_tmp_fusion_idx) and intraTMP fusion weight type (intra_tmp_fusion_weight_type) in the bitstream.

[0139] In 1514, the system can determine the fusion weight set based on the fourth syntax element. For example, the method for calculating the fusion weights is selected by the intraTMP fusion weight type (intra_tmp_fusion_weight_type). intra_tmp_fusion_weight_type is a flag that can take values ​​of 0 or 1. For example, if intra_tmp_fusion_weight_type is 0, the weights can be determined by an algorithm based on SAD (see equations (10) and (11) below). i represents the SAD cost of the i-th intraTMP candidate. If intra_tmp_fusion_weight_type is 1, then instead, the set of six weights {w} is used by minimizing the MSE between the fusion of adjacent template regions of the five reference blocks and the adjacent template region of the current block. A ,w A+1 ,...w B ,w N} may be determined. That is, each reference block r i The adjacent template is t i If the adjacent template of the current block is t, then the weight can be determined according to expression (12).

[0140] Referring to Figure 15B, in 1516, the system can determine the intraTMP prediction value based on the fused weight set and the reference block set indicated by the third syntax element. For example, the intraTMP prediction value can be determined based on the fused weights and reference blocks calculated by an algorithm based on SAD or an algorithm based on MSE.

[0141] In step 1518, upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the system can perform sparse and refinement searches to construct a candidate list containing N intraTMP block vectors. For example, if the current block is predicted by intraTMP, an intraTMP fusion flag (intra_tmp_fusion_flag) can be signaled to indicate whether the intraTMP predicted value is determined by fusing multiple reference blocks. Regardless of the value of the intraTMP fusion flag, a sparse search path and a refinement search path can be performed to construct a candidate list containing N intraTMP block vectors. From these, N intraTMP block vectors are selected by choosing block vectors based on the SAD cost calculated in the template region. Further details of the candidate list construction process are provided below. In this embodiment, N is 15 or greater. Block vectors from the intraTMP candidate list are bv0, bv1, ... bv N-1 Mark it as follows. The reference blocks corresponding to the block vector from the intraTMP candidate list are r0, r1, ... r N-1 Mark it as such.

[0142] In 1520, the system can determine the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element. For example, if a block is currently predicted by an intraTMP fusion mode (intra_tmp_fusion_flag is 1), the intraTMP fusion index (intra_tmp_fusion_idx) and intraTMP fusion weight type (intra_tmp_fusion_weight_type) are signaled in the bitstream. The fusion predicted value is determined according to equation (9). Equation (9) determines the reference blocks selected for fusion by the intraTMP fusion index. The values ​​of the intraTMP fusion index may be 0, 1, or 2. If intra_tmp_fusion_idx is 0, then A=0 and B=4. That is, the five reference blocks (r0, r1, r2, r3, r4) corresponding to the first five intraTMP block vectors in the candidate list are selected for fusion. If intra_tmp_fusion_idx is 1, then A=5 and B=9. If intra_tmp_fusion_idx is 2, then A=10 and B=14. midVal is set to the midpoint of the video samples. For example, if the bit depth is B, then midVal=2. B-1 The following is an example of the binarization of intra_tmp_fusion_idx.

[0143] In 1522, given that the fourth syntax element contains the first value, the system can determine the fusion weight set by an algorithm based on SAD. For example, if intra_tmp_fusion_weight_type is 0, the weights can be determined by an algorithm based on SAD (see equations (10) and (11) above). i This represents the SAD cost of the i-th intraTMP candidate.

[0144] In 1524, given that the fourth syntax element contains a second value, the system can determine the fusion weight set by an algorithm based on MSE. For example, if intra_tmp_fusion_weight_type is 1, then instead, the set of six weights {w} can be determined by minimizing the MSE between the fusion of adjacent template regions of the five reference blocks and the adjacent template region of the current block. A ,w A+1 ,...w B ,w N} may be determined. That is, each reference block r i The adjacent template is t i If the adjacent template of the current block is t, then the weight can be determined according to expression (12).

[0145] At 1526, upon receiving the second syntax element indicating that intraTMP fusion is not enabled for the current block, the system can decode the fifth syntax element from the bitstream. For example, if the current block is not intraTMP fused (intra_tmp_fusion_flag is 0) but predicted by intraTMP, the intraTMP index is signaled to mark a single block vector from the candidate list.

[0146] In 1528, the system can identify block vectors from the candidate list based on the fifth syntax element. For example, if a block is currently predicted by intraTMP but not by intraTMP fusion (intra_tmp_fusion_flag is 0), the intraTMP index is signaled to mark a single block vector from the candidate list. The same candidate list is constructed regardless of whether intraTMP fusion is used or not. However, by modifying the construction of the candidate list to the known method described above, the search for multiple candidates by sparse paths and refinement paths is combined with the search for candidates by different template shapes.

[0147] Referring to Figure 15C, at 1530, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the system can decode the sixth syntax element from the bitstream. For example, if the current block is not intraTMP fused (intra_tmp_fusion_flag is 0) and is predicted by intraTMP, then in addition to the intraTMP index, the intraTMP filter flag (intra_tmp_filter_flag) is used for the selected reference block r i The system is signaled to indicate whether or not to determine a prediction block by filtering it.

[0148] In 1532, the system can determine, based on the sixth syntax element, whether the intraTMP prediction value is determined by filtering the selected reference block. For example, if the current block is not intraTMP fused (intra_tmp_fusion_flag is 0) but is predicted by intraTMP, then in addition to the intraTMP index, the intraTMP filter flag (intra_tmp_filter_flag) is used for the selected reference block r i The system is signaled to indicate whether or not to determine a prediction block by filtering it.

[0149] In 1534, given that the sixth syntax element contains the first value, the system can determine the intraTMP predicted value by filtering the selected reference block with a trained filter. For example, if intra_tmp_filter_flag is 1, the predicted block is determined by filtering with trained filter c according to equation (13). The trained filter c in equation (13) can be determined by equation (14).

[0150] In 1536, given that the sixth syntax element contains a second value, the system can decode the seventh syntax element from the bitstream. For example, if the current block is not intraTMP fusion or intraTMP filtering (intra_tmp_filter_flag is 0) and is predicted by intraTMP, an intraTMP sub-pixel flag (intra_tmp_sub_pel_flag) can be signaled to indicate whether the intraTMP BV is further refined with fractional precision.

[0151] In 1538, the system can determine whether the block vector is refined to fractional precision based on the seventh syntax element. For example, if the block is currently predicted by intraTMP and is neither intraTMP fusion nor intraTMP filtering (intra_tmp_filter_flag is 0), the intraTMP sub-pixel flag (intra_tmp_sub_pel_flag) can be signaled to indicate whether the intraTMP BV is further refined to fractional precision.

[0152] At 1540, given that the seventh syntax element contains the first value, the system can determine that the block vector will not be refined to fractional precision by the processor.

[0153] In 1542, given that the seventh syntax element contains a second value, the system can determine that the block vector is refined with fractional precision. For example, if intra_tmp_sub_pel_flag is 0, the intraTMP block vector is not further modified. The predicted block is then the selected reference block r i That is the case.

[0154] Referring to Figure 15D, at 1544, given that the seventh syntax element contains a second value, the system can decode the eighth and ninth syntax elements from the bitstream. For example, if intra_tmp_sub_pel_flag is 1, the intraTMP BV is further refined by signaling the sub-pixel refinement direction (intra_tmp_sub_pel_direction_idx) and sub-pixel refinement phase (intra_tmp_sub_pel_phase_idx).

[0155] In 1546, the system can determine the sub-pixel refinement direction based on the eighth syntax element. For example, sub-pixel refinement may be performed along one of the eight directions indicated by the arrows in Figure 14. intra_tmp_sub_pel_direction_idx indicates the sub-pixel refinement direction by taking a value in the range of 0 to 7 (this value is represented by a 3-bit fixed-length code).

[0156] In 1548, the system can determine the sub-pixel refinement phase based on the 9th syntax element. For example, intra_tmp_sub_pel_phase_idx determines the bv i The distance from the subpixel to the BV due to subpixel refinement is signaled, and intra_tmp_sub_pel_phase_idx represents a value of 0 to indicate 1 / 4 phase, a value of 1 to indicate 1 / 2 phase, and a value of 2 to indicate 3 / 4 phase.

[0157] In 1550, the system can refine the block vector based on the sub-pixel refinement direction and sub-pixel refinement phase. For example, by applying a one-dimensional interpolation filter in a separable manner, the predicted blocks of sub-pixel refinement are determined, and the desired interpolation is achieved using a 1 / 4, 1 / 2, or 3 / 4 phase interpolation filter. The interpolation filter may be an existing interpolation filter used for motion compensation in ECM, or an existing ECM filter for intra-reference sample interpolation, or an interpolation filter specifically designed for intraTMP.

[0158] At 1552, the system can decode the current block based on the intraTMP prediction value. For example, decoder 201 can decode the current block according to the intraTMP prediction value determined based on the various syntax elements analyzed from the bitstream as described above.

[0159] Figures 16A to 16D show flowcharts of exemplary method 1600 for video coding according to some embodiments of the present disclosure. Method 1600 is executable by a system, which may be, for example, an coding system 200, an encoder 101, or an intra-prediction module 410. Method 1600 may include operations 1602 to 1652 described below. It should be understood that some steps are optional, some steps may be performed simultaneously, or the order in which they are performed may differ from the order shown in Figures 16A to 16D.

[0160] Referring to Figure 16A, at 1602, the system can determine that the current block is encoded in intraTMP. For example, encoder 101 can determine that the current block is encoded in intraTMP.

[0161] In 1604, the system can encode a first syntax element into a bitstream. For example, an intraTMP flag (intra_tmp_flag) can be signaled to indicate whether the current block is predicted by intraTMP. The syntax element may be encoded into a bitstream, or it may have an estimate. For example, if the use of the intraTMP tool is prohibited at a higher syntax level (e.g., Sequence Parameter Set (SPS)), the intraTMP flag may have an estimate of 0.

[0162] In 1606, the system can determine whether intraTMP mode is enabled for the current block based on a first syntax element. For example, an intraTMP flag (intra_tmp_flag) can be signaled to indicate whether the current block is predicted by intraTMP. The syntax element may be encoded in a bitstream, or it may have an estimate. For example, if the use of the intraTMP tool is prohibited at a higher syntax level (e.g., Sequence Parameter Set (SPS)), the intraTMP flag may have an estimate of 0.

[0163] In 1608, given that intraTMP mode is enabled for the current block, the system can encode the second syntax element into a bitstream. For example, if the current block is predicted by intraTMP, an intraTMP fusion flag (intra_tmp_fusion_flag) can be signaled to indicate whether the intraTMP prediction value is determined by fusing multiple reference blocks.

[0164] In 1610, the system can determine, based on the second syntax element, whether the intraTMP predicted value of the current block is determined by the intraTMP fusion mode. For example, if the current block is predicted by the intraTMP fusion mode, the value of intra_tmp_fusion_flag can be represented as 1; otherwise, the value can be represented as 0.

[0165] In step 1612, upon determining that the intraTMP prediction value is determined by the intraTMP fusion mode, the system can encode the third and fourth syntax elements into the bitstream. For example, if the current block is predicted by the intraTMP fusion mode (intra_tmp_fusion_flag is 1), the bitstream signals both the intraTMP fusion index (intra_tmp_fusion_idx) and the intraTMP fusion weight type (intra_tmp_fusion_weight_type).

[0166] In 1614, the system can determine the fusion weight set based on the fourth syntax element. For example, the method for calculating the fusion weights is selected by the intraTMP fusion weight type (intra_tmp_fusion_weight_type). intra_tmp_fusion_weight_type is a flag that can take values ​​of 0 or 1. For example, if intra_tmp_fusion_weight_type is 0, the weights can be determined by an algorithm based on SAD (see equations (10) and (11) below). i represents the SAD cost of the i-th intraTMP candidate. If intra_tmp_fusion_weight_type is 1, then instead, the set of six weights {w} is used by minimizing the MSE between the fusion of adjacent template regions of the five reference blocks and the adjacent template region of the current block. A ,w A+1 ,...w B ,w N} may be determined. That is, each reference block r i The adjacent template is t i If the adjacent template of the current block is t, then the weight can be determined according to expression (12).

[0167] Referring to Figure 16B, in 1616, the system can determine the intraTMP prediction value based on the fused weight set and the reference block set indicated by the third syntax element. For example, the intraTMP prediction value can be determined based on the fused weights and reference blocks calculated by an algorithm based on SAD or an algorithm based on MSE.

[0168] In step 1618, upon determining that the current block's intraTMP predicted value is determined by the intraTMP fusion mode, the system can perform sparse and refinement searches to construct a candidate list containing N intraTMP block vectors. For example, if the current block is predicted by intraTMP, an intraTMP fusion flag (intra_tmp_fusion_flag) can be signaled to indicate whether the intraTMP predicted value is determined by fusing multiple reference blocks. Regardless of the value of the intraTMP fusion flag, a sparse search path and a refinement search path can be performed to construct a candidate list containing N intraTMP block vectors. From these, N intraTMP block vectors are selected by choosing block vectors based on the SAD cost calculated in the template region. Further details of the candidate list construction process are provided below. In this embodiment, N is 16 or greater. Block vectors from the intraTMP candidate list are bv0, bv1, ... bv N-1 Mark it as follows. The reference blocks corresponding to the block vector from the intraTMP candidate list are r0, r1, ... r N-1 Mark it as such.

[0169] In 1620, the system can determine the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element. For example, if a block is currently predicted by an intraTMP fusion mode (intra_tmp_fusion_flag is 1), both the intraTMP fusion index (intra_tmp_fusion_idx) and the intraTMP fusion weight type (intra_tmp_fusion_weight_type) are signaled in the bitstream. The fusion predicted value is determined according to equation (9). Equation (9) determines the reference blocks selected for fusion by the intraTMP fusion index. The values ​​of the intraTMP fusion index may be 0, 1, or 2. If intra_tmp_fusion_idx is 0, then A=0 and B=4. That is, the five reference blocks (r0, r1, r2, r3, r4) corresponding to the first five intraTMP block vectors in the candidate list are selected for fusion. If intra_tmp_fusion_idx is 1, then A=5 and B=9. If intra_tmp_fusion_idx is 2, then A=10 and B=14. midVal is set to the midpoint of the video samples. For example, if the bit depth is B, then midVal=2. B-1 The following is an example of the binarization of intra_tmp_fusion_idx.

[0170] In 1622, given that the fourth syntax element contains the first value, the system can determine the fusion weight set by an algorithm based on SAD. For example, if intra_tmp_fusion_weight_type is 0, the weights can be determined by an algorithm based on SAD (see equations (10) and (11) above). i This represents the SAD cost of the i-th intraTMP candidate.

[0171] In 1624, given that the fourth syntax element contains a second value, the system can determine the fusion weight set by an algorithm based on MSE. For example, if intra_tmp_fusion_weight_type is 1, then instead, the set of six weights {w} can be determined by minimizing the MSE between the fusion of adjacent template regions of the five reference blocks and the adjacent template region of the current block. A ,w A+1 ,...w B ,w N} may be determined. That is, each reference block r i The adjacent template is t i If the adjacent template of the current block is t, then the weight can be determined according to expression (12).

[0172] In 1626, upon receiving the second syntax element indicating that intraTMP fusion is not enabled for the current block, the system can encode the fifth syntax element into a bitstream. For example, if the current block is not intraTMP fusion (intra_tmp_fusion_flag is 0) but is predicted by intraTMP, the intraTMP index is signaled to mark a single block vector from the candidate list.

[0173] In 1628, the system can identify block vectors from the candidate list based on the fifth syntax element. For example, if a block is currently predicted by intraTMP but not by intraTMP fusion (intra_tmp_fusion_flag is 0), the intraTMP index is signaled to mark a single block vector from the candidate list. The same candidate list is constructed regardless of whether intraTMP fusion is used or not. However, by modifying the construction of the candidate list to the known method described above, the search for multiple candidates by sparse paths and refinement paths is combined with the search for candidates by different template shapes.

[0174] Referring to Figure 16C, in 1630, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the system can encode the sixth syntax element into a bitstream. For example, if the current block is not intraTMP fused (intra_tmp_fusion_flag is 0) and is predicted by intraTMP, then in addition to the intraTMP index, the intraTMP filter flag (intra_tmp_filter_flag) is used for the selected reference block r i The system is signaled to indicate whether or not to determine a prediction block by filtering it.

[0175] In 1632, the system can determine, based on the sixth syntax element, whether the intraTMP prediction value is determined by filtering the selected reference block. For example, if the current block is not intraTMP fused (intra_tmp_fusion_flag is 0) but is predicted by intraTMP, then in addition to the intraTMP index, the intraTMP filter flag (intra_tmp_filter_flag) is used for the selected reference block r i The system is signaled to indicate whether or not to determine a prediction block by filtering it.

[0176] In 1634, given that the sixth syntax element contains the first value, the system can determine the intraTMP predicted value by filtering the selected reference block with a trained filter. For example, if intra_tmp_filter_flag is 1, the predicted block is determined by filtering with the trained filter c according to equation (13). The trained filter c in equation (13) can be determined by equation (14).

[0177] In 1636, given that the sixth syntax element contains a second value, the system can encode the seventh syntax element into a bitstream. For example, if the current block is not intraTMP fusion or intraTMP filtering (intra_tmp_filter_flag is 0) and is predicted by intraTMP, an intraTMP sub-pixel flag (intra_tmp_sub_pel_flag) can be signaled to indicate whether the intraTMP BV is further refined with fractional precision.

[0178] In 1638, the system can determine, based on the seventh syntax element, whether the block vector is refined to fractional precision. For example, if the block is currently predicted by intraTMP and is neither intraTMP fusion nor intraTMP filtering (intra_tmp_filter_flag is 0), the intraTMP sub-pixel flag (intra_tmp_sub_pel_flag) can be signaled to indicate whether the intraTMP BV is further refined to fractional precision.

[0179] In 1640, given that the seventh syntax element contains the first value, the system can determine that the block vector will not be refined to fractional precision by the processor.

[0180] In 1642, given that the seventh syntax element contains a second value, the system can determine that the block vector is refined with fractional precision. For example, if intra_tmp_sub_pel_flag is 0, the intraTMP block vector is not further modified. The predicted block is then the selected reference block r i That is the case.

[0181] Referring to Figure 16D, in 1644, given that the seventh syntax element contains a second value, the system can encode the eighth and ninth syntax elements into a bitstream. For example, if intra_tmp_sub_pel_flag is 1, the intraTMP BV is further refined by signaling the sub-pixel refinement direction (intra_tmp_sub_pel_direction_idx) and sub-pixel refinement phase (intra_tmp_sub_pel_phase_idx).

[0182] In 1646, the system can determine the sub-pixel refinement direction based on the eighth syntax element. For example, sub-pixel refinement may be performed along one of the eight directions indicated by the arrows in Figure 14. intra_tmp_sub_pel_direction_idx indicates the sub-pixel refinement direction by taking a value in the range of 0 to 7 (this value is represented by a 3-bit fixed-length code).

[0183] In 1648, the system can determine the sub-pixel refinement phase based on the 9th syntax element. For example, intra_tmp_sub_pel_phase_idx determines the bv i The distance from the subpixel to the BV due to subpixel refinement is signaled, and intra_tmp_sub_pel_phase_idx represents a value of 0 to indicate 1 / 4 phase, a value of 1 to indicate 1 / 2 phase, and a value of 2 to indicate 3 / 4 phase.

[0184] In 1650, the system can refine the block vector based on the sub-pixel refinement direction and sub-pixel refinement phase. For example, by applying a one-dimensional interpolation filter in a separable manner, the predicted blocks of sub-pixel refinement are determined, and the desired interpolation is achieved using a 1 / 4, 1 / 2, or 3 / 4 phase interpolation filter. The interpolation filter may be an existing interpolation filter used for motion compensation in ECM, or an existing ECM filter for intra-reference sample interpolation, or an interpolation filter specifically designed for intraTMP.

[0185] In 1652, the system can encode the current block based on the intraTMP predicted value. For example, encoder 101 can encode the current block according to the intraTMP predicted value determined based on the various syntax elements analyzed into the bitstream as described above.

[0186] In each embodiment of this disclosure, the functions described herein can be implemented by hardware, software, firmware, or any combination thereof. When implemented by software, the functions may be stored as instructions in a non-temporary computer-readable medium. The computer-readable medium includes computer storage media. The storage medium may be any available medium accessible to a processor (e.g., processor 102 in Figures 1 and 2). Such computer-readable media may include, but are not limited to, RAM, ROM, EEPROM, CD-ROM or other optical disk memory, HDD, e.g., magnetic disk memory or other magnetic storage device, flash drive, SSD, or any other medium that can be used to mount or store desired program code in the form of instructions or data structures and is accessible to a processing system (e.g., a mobile device or computer). As used herein, magnetic disks and optical disks include CDs, laserdiscs, optical disks, digital video discs (DVDs), and floppy disks, of which disks typically reproduce data magnetically and optical disks reproduce data optically by a laser. Any combination of the above should also be included within the scope of computer-readable media.

[0187] A decoding method performed by a decoder is provided according to one aspect of the present disclosure. The method may include the processor decoding a plurality of syntax elements associated with intraTMP by analyzing a bitstream. The method may include the processor decoding a first syntax element from the bitstream. The method may include the processor determining, based on the first syntax element, whether or not the intraTMP mode is enabled for the current block. The method may include the processor decoding a second syntax element from the bitstream, having determined that the intraTMP mode is enabled for the current block. The method may include the processor determining, based on the second syntax element, whether or not the intraTMP prediction value for the current block is determined by the intraTMP fusion mode. The method may include the processor decoding a third and a fourth syntax element from the bitstream, having determined that the intraTMP prediction value is determined by the intraTMP fusion mode. The method may include the processor determining a fusion weight set based on the fourth syntax element. The method may include the processor determining the intraTMP prediction value based on the fused weight set and the reference block set indicated by the third syntax element. The method may also include the processor decoding the current block based on the intraTMP prediction value.

[0188] In some implementations, upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the method may include the processor performing sparse search and refinement search to select block vectors based on the SAD cost calculated in the template area, thereby constructing a candidate list containing N intraTMP block vectors.

[0189] In some implementations, constructing a candidate list containing N intraTMP block vectors by the processor performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template region may include the processor concurrently identifying a set of sparse candidate block vectors during the sparse search. In some implementations, constructing a candidate list containing N intraTMP block vectors by the processor performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template region may also include the processor constructing the candidate list containing N intraTMP block vectors by performing a search around the sparse candidate block vectors in the selected template shape.

[0190] In some implementations, the method may include the processor determining a set of reference blocks selected to determine the intraTMP prediction value based on the third syntax element.

[0191] In some implementations, given that the fourth syntax element includes a first value, the method may include the processor determining the fused weight set by an algorithm based on SAD. In some implementations, given that the fourth syntax element includes a second value, the method may include the processor determining the fused weight set by an algorithm based on MSE.

[0192] In some implementations, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the method may include the processor decoding a fifth syntax element from the bitstream. In some implementations, the method may include the processor identifying a block vector from the candidate list based on the fifth syntax element.

[0193] In some implementations, the range of possible values ​​for the fifth syntax element is from 0 to 18. In some implementations, if the value of the fifth syntax element is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code.

[0194] In some implementations, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the method may include the processor decoding a sixth syntax element from the bitstream. In some implementations, the processor determines, based on the sixth syntax element, whether the intraTMP prediction is determined by filtering selected reference blocks.

[0195] In some implementations, given that the sixth syntax element includes a first value, the method may also include the processor determining the intraTMP predicted value by filtering the selected reference block with a learned filter.

[0196] In some implementations, given that the sixth syntax element includes a second value, the method may include the processor decoding a seventh syntax element from the bitstream. In some implementations, the method may include the processor determining, based on the seventh syntax element, whether the block vector is refined to fractional precision.

[0197] In some implementations, upon receiving that the seventh syntax element contains a first value, the method may include the processor determining that the block vector is not refined to fractional precision. In some implementations, upon receiving that the seventh syntax element contains a second value, the method may include the processor determining that the block vector is refined to fractional precision.

[0198] In some implementations, given that the seventh syntax element includes a second value, the method may include the processor decoding the eighth and ninth syntax elements from the bitstream. In some implementations, the method may include the processor determining the sub-pixel refinement direction based on the eighth syntax element. In some implementations, the method may include the processor determining the sub-pixel refinement phase based on the ninth syntax element. In some implementations, the method may include the processor refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase.

[0199] A decoder is provided according to another aspect of the present disclosure. The decoder may include a processor and a memory storing instructions. The memory stores instructions, which, when executed by the processor, can cause the processor to perform the operation of decoding a plurality of syntax elements associated with intraTMP by analyzing a bitstream. The memory stores instructions, which, when executed by the processor, can cause the processor to perform the operation of decoding a first syntax element from the bitstream. The memory stores instructions, which, when executed by the processor, can cause the processor to perform the operation of determining whether intraTMP mode is enabled for the current block based on the first syntax element. The memory stores instructions, which, when executed by the processor, can cause the processor to perform the operation of decoding a second syntax element from the bitstream, based on the determination that intraTMP mode is enabled for the current block. The memory stores an instruction, and when the instruction is executed by the processor, the processor can be made to perform the operation of determining whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode based on the second syntax element. The memory stores an instruction, and when the instruction is executed by the processor, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the processor can be made to perform the operation of decoding the third syntax element and the fourth syntax element from the bitstream. The memory stores an instruction, and when the instruction is executed by the processor, the processor can be made to perform the operation of determining the fusion weight set based on the fourth syntax element.The memory stores instructions, and when the instructions are executed by the processor, the processor is instructed to determine the intraTMP predicted value based on the fused weight set and the reference block set indicated by the third syntax element. The memory also stores instructions, and when the instructions are executed by the processor, the processor is instructed to decode the current block based on the intraTMP predicted value.

[0200] In some implementations, instructions are stored in the memory, and when the instructions are executed by the processor, the processor can be instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the SAD cost calculated in the template area, after determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode.

[0201] In some implementations, instructions are stored in memory to construct a candidate list containing N intraTMP block vectors by performing a sparse search and a refinement search and selecting block vectors based on the SAD cost calculated in the template area. When these instructions are executed by the processor, the processor is further instructed to perform the operation of identifying a set of sparse candidate block vectors in parallel during the sparse search period. In some implementations, instructions are stored in memory to construct a candidate list containing N intraTMP block vectors by performing a sparse search and a refinement search and selecting block vectors based on the SAD cost calculated in the template area. When these instructions are executed by the processor, the processor is further instructed to perform the operation of constructing a candidate list containing N intraTMP block vectors by performing a search around the sparse candidate block vectors in the selected template shape.

[0202] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor is further instructed to determine the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element.

[0203] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor can be further instructed to determine the fused weight set using an algorithm based on SAD, upon receiving that the fourth syntax element contains a first value. In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor can further instructed to determine the fused weight set using an algorithm based on MSE, upon receiving that the fourth syntax element contains a second value.

[0204] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to decode a fifth syntax element from the bitstream, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can further instruct to identify a block vector from the candidate list based on the fifth syntax element.

[0205] In some implementations, the range of possible values ​​for the fifth syntax element is from 0 to 18. In some implementations, if the value of the fifth syntax element is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code.

[0206] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to decode a sixth syntax element from the bitstream, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can further instructed to determine, based on the sixth syntax element, whether or not the intraTMP prediction value is determined by filtering selected reference blocks.

[0207] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor can be instructed to perform the operation of determining the intraTMP predicted value by filtering the selected reference block with a learned filter, upon receiving that the sixth syntax element contains a first value.

[0208] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to decode a seventh syntax element from the bitstream, based on the fact that the sixth syntax element contains a second value. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can further instructed to determine whether or not the block vector is refined to fractional precision based on the seventh syntax element.

[0209] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to perform the operation of determining that the block vector is not refined to fractional precision upon receiving that the seventh syntax element contains a first value. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to perform the operation of determining that the block vector is refined to fractional precision upon receiving that the seventh syntax element contains a second value.

[0210] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to decode the eighth and ninth syntax elements from the bitstream, given that the seventh syntax element includes a second value. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to determine the sub-pixel refinement direction based on the eighth syntax element. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to determine the sub-pixel refinement phase based on the ninth syntax element. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be further instructed to refine the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase.

[0211] In another aspect of this disclosure, a non-temporary computer-readable medium storing instructions for a decoder is provided. The memory stores instructions, which, when executed by the decoder's processor, can cause the decoder's processor to decode a plurality of syntax elements associated with intraTMP by parsing a bitstream. The memory stores instructions, which, when executed by the decoder's processor, can cause the decoder's processor to decode a first syntax element from the bitstream. The memory stores instructions, which, when executed by the decoder's processor, can cause the decoder's processor to perform the operation of determining whether intraTMP mode is enabled for the current block based on the first syntax element. The memory stores instructions, which, when executed by the processor, can cause the processor to perform the operation of decode a second syntax element from the bitstream, given that intraTMP mode is enabled for the current block. The memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can be made to perform the operation of determining whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode based on the second syntax element. The memory stores an instruction, and when the instruction is executed by the processor, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the processor can be made to perform the operation of decoding the third syntax element and the fourth syntax element from the bitstream. The memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can be made to perform the operation of determining the fusion weight set based on the fourth syntax element.The memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be made to perform the operation of determining the intraTMP predicted value based on the fused weight set and the reference block set indicated by the third syntax element. The memory also stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be made to perform the operation of decoding the current block based on the intraTMP predicted value.

[0212] In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the SAD cost calculated in the template area, after determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode.

[0213] In some implementations, instructions are stored in memory to construct a candidate list containing N intraTMP block vectors by performing a sparse search and a refinement search and selecting block vectors based on the SAD cost calculated in the template area. When these instructions are executed by the processor, the processor is further instructed to perform the operation of identifying a set of sparse candidate block vectors in parallel during the sparse search period. In some implementations, instructions are stored in memory to construct a candidate list containing N intraTMP block vectors by performing a sparse search and a refinement search and selecting block vectors based on the SAD cost calculated in the template area. When these instructions are executed by the processor, the processor is further instructed to perform the operation of constructing a candidate list containing N intraTMP block vectors by performing a search around the sparse candidate block vectors in the selected template shape.

[0214] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor is further instructed to determine a set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element.

[0215] In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be further instructed to determine the fused weight set using an algorithm based on SAD, upon receiving that the fourth syntax element contains a first value. In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can further instruct to determine the fused weight set using an algorithm based on MSE, upon receiving that the fourth syntax element contains a second value.

[0216] In some implementations, the memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can be further instructed to decode a fifth syntax element from the bitstream, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block. In some implementations, the memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can further instruct to identify a block vector from the candidate list based on the fifth syntax element.

[0217] In some implementations, the range of possible values ​​for the fifth syntax element is from 0 to 18. In some implementations, if the value of the fifth syntax element is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code.

[0218] In some implementations, the memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can be further instructed to decode a sixth syntax element from the bitstream, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block. In some implementations, the memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can further instruct to determine, based on the sixth syntax element, whether or not the intraTMP prediction value is determined by filtering selected reference blocks.

[0219] In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be instructed to further determine the intraTMP predicted value by filtering selected reference blocks using a learned filter, upon receiving that the sixth syntax element contains a first value.

[0220] In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be further instructed to decode a seventh syntax element from the bitstream, based on the sixth syntax element containing a second value. In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can further instruct to determine whether or not the block vector is refined to fractional precision based on the seventh syntax element.

[0221] In some implementations, the memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can be instructed to perform the operation of determining that the block vector is not refined to fractional precision upon finding that the seventh syntax element contains a first value. In some implementations, the memory stores an instruction, and when the instruction is executed by the decoder's processor, the decoder's processor can be instructed to perform the operation of determining that the block vector is refined to fractional precision upon finding that the seventh syntax element contains a second value.

[0222] In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be further instructed to decode the eighth and ninth syntax elements from the bitstream, given that the seventh syntax element includes a second value. In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be further instructed to determine the sub-pixel refinement direction based on the eighth syntax element. In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be further instructed to determine the sub-pixel refinement phase based on the ninth syntax element. In some implementations, the memory stores instructions, and when the instructions are executed by the decoder's processor, the decoder's processor can be further instructed to refine the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase.

[0223] An encoding method implemented by an encoder is provided according to yet another aspect of the present disclosure. The method may include a processor enabling intraTMP and encoding a current block. The method may include the processor encoding a first syntax element into a bitstream. The method may include the processor determining whether the intraTMP mode is enabled for the current block based on the first syntax element. The method may include the processor encoding a second syntax element into the bitstream, having determined that the intraTMP mode is enabled for the current block. The method may include the processor determining whether the intraTMP predicted value for the current block is determined by the intraTMP fusion mode based on the second syntax element. The method may include the processor encoding a third syntax element and a fourth syntax element into the bitstream, having determined that the intraTMP predicted value is determined by the intraTMP fusion mode. The method may include the processor determining a fusion weight set based on the fourth syntax element. The method may include the processor determining the intraTMP predicted value based on the fused weight set and the reference block set indicated by the third syntax element. The method may also include the processor encoding the current block based on the intraTMP predicted value.

[0224] In some implementations, upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the method may include the processor performing sparse search and refinement search to select block vectors based on the SAD cost calculated in the template area, thereby constructing a candidate list containing N intraTMP block vectors.

[0225] In some implementation manners, for the processor to execute sparse search and refinement search, and select block vectors based on the SAD cost calculated in the template region to construct a candidate list including N intraTMP block vectors, it may include that the processor concurrently identifies a set of sparse candidate block vectors during the sparse search. In some implementation manners, for the processor to execute sparse search and refinement search, and select block vectors based on the SAD cost calculated in the template region to construct a candidate list including N intraTMP block vectors, it may include that the processor searches around the sparse candidate block vectors in the selected template shape to construct the candidate list including N intraTMP block vectors.

[0226] In some implementation manners, the method may include that the processor determines the set of reference blocks selected to determine the intraTMP prediction value based on the third syntax element.

[0227] In some implementation manners, in response to the fourth syntax element including a first value, the method may include that the processor determines the set of fusion weights by an algorithm based on SAD. In some implementation manners, in response to the fourth syntax element including a second value, the method may include that the processor determines the set of fusion weights by an algorithm based on MSE.

[0228] In some implementation manners, in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, the method may include that the processor encodes the fifth syntax element into the bitstream. In some implementation manners, the method may include that the processor identifies block vectors from the candidate list based on the fifth syntax element.

[0229] In some implementations, the range of possible values ​​for the fifth syntax element is from 0 to 18. In some implementations, if the value of the fifth syntax element is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code.

[0230] In some implementations, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the method may include the processor encoding a sixth syntax element into the bitstream. In some implementations, the method may include the processor determining, based on the sixth syntax element, whether the intraTMP prediction is determined by filtering selected reference blocks.

[0231] In some implementations, given that the sixth syntax element includes a first value, the method may also include the processor determining the intraTMP predicted value by filtering the selected reference block with a learned filter.

[0232] In some implementations, given that the sixth syntax element includes a second value, the method may include the processor encoding the seventh syntax element into the bitstream. In some implementations, the processor determines, based on the seventh syntax element, whether the block vector is refined with fractional precision.

[0233] In some implementations, upon receiving that the seventh syntax element contains a first value, the method may include the processor determining that the block vector is not refined to fractional precision. In some implementations, upon receiving that the seventh syntax element contains a second value, the method may include the processor determining that the block vector is refined to fractional precision.

[0234] In some implementations, given that the seventh syntax element includes a second value, the method may include the processor encoding the eighth and ninth syntax elements into the bitstream. In some implementations, the method may include the processor determining the sub-pixel refinement direction based on the eighth syntax element. In some implementations, the method may include the processor determining the sub-pixel refinement phase based on the ninth syntax element. In some implementations, the method may include the processor refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase.

[0235] An encoder is provided according to yet another aspect of the present disclosure. The encoder may include a processor and a memory storing instructions. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of enabling intraTMP and encoding the current block. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of encoding a first syntax element into a bitstream. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of determining whether intraTMP mode is enabled for the current block based on the first syntax element. The memory stores instructions that, when executed by the processor, can cause the processor to perform the operation of encoding a second syntax element into the bitstream, based on the determination that intraTMP mode is enabled for the current block. The memory stores an instruction, and when the instruction is executed by the processor, it can cause the processor to perform the operation of determining whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode based on the second syntax element. The memory stores an instruction, and when the instruction is executed by the processor, upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, it can cause the processor to perform the operation of encoding the third syntax element and the fourth syntax element into the bitstream. The memory stores an instruction, and when the instruction is executed by the processor, it can cause the processor to perform the operation of determining the fusion weight set based on the fourth syntax element. The memory stores an instruction, and when the instruction is executed by the processor, it can cause the processor to perform the operation of determining the intraTMP predicted value based on the fusion weight set and the reference block set indicated by the third syntax element.The memory stores instructions, and when an instruction is executed by the processor, it can cause the processor to perform the operation of encoding the current block based on the intraTMP predicted value.

[0236] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor is instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the SAD cost calculated in the template area, upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode.

[0237] In some implementations, instructions are stored in memory to construct a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template area. When these instructions are executed by the processor, the processor is instructed to perform the operation of identifying a set of sparse candidate block vectors in parallel during the sparse search period. In some implementations, instructions are stored in memory to construct a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template area. When these instructions are executed by the processor, the processor is instructed to perform the operation of constructing the candidate list containing N intraTMP block vectors by performing a search around the sparse candidate block vectors in the selected template shape.

[0238] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor can be made to perform the operation of determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element.

[0239] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor can be instructed to determine the fused weight set using an algorithm based on SAD, upon receiving that the fourth syntax element contains a first value. In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor can be instructed to determine the fused weight set using an algorithm based on MSE, upon receiving that the fourth syntax element contains a second value.

[0240] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be prompted to encode a fifth syntax element into the bitstream, upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be prompted to identify a block vector from the candidate list based on the fifth syntax element.

[0241] In some implementations, the range of possible values ​​for the fifth syntax element is from 0 to 18. In some implementations, if the value of the fifth syntax element is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code.

[0242] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be prompted to encode a sixth syntax element into the bitstream, based on the second syntax element indicating that intraTMP fusion is not enabled for the current block. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be prompted to determine, based on the sixth syntax element, whether or not the intraTMP prediction value is determined by filtering the selected reference block.

[0243] In some implementations, the memory stores instructions, and when the instructions are executed by the processor, the processor is instructed to determine the intraTMP predicted value by filtering selected reference blocks using a learned filter, upon receiving that the sixth syntax element contains a first value.

[0244] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to encode the seventh syntax element into the bitstream, based on the fact that the sixth syntax element contains a second value. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to determine whether or not the block vector is refined to fractional precision based on the seventh syntax element.

[0245] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to determine that the block vector is not refined to fractional precision upon finding that the seventh syntax element contains a first value. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to determine that the block vector is refined to fractional precision upon finding that the seventh syntax element contains a second value.

[0246] In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to encode the eighth and ninth syntax elements into the bitstream, upon receiving that the seventh syntax element includes the second value. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to determine the sub-pixel refinement direction based on the eighth syntax element. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to determine the sub-pixel refinement phase based on the ninth syntax element. In some implementations, the memory stores an instruction, and when the instruction is executed by the processor, the processor can be instructed to refine the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase.

[0247] In yet another aspect of the present disclosure, a non-temporary computer-readable medium storing instructions for an encoder is provided. When the instructions are executed by the encoder's processor, they can cause the encoder's processor to enable intraTMP and encode the current block. When the instructions are executed by the encoder's processor, they can cause the encoder's processor to encode a first syntax element into a bitstream. When the instructions are executed by the encoder's processor, they can cause the encoder's processor to determine, based on the first syntax element, whether or not the intraTMP mode is enabled for the current block. When the instructions stored in memory are executed by the processor, they can cause the processor to determine, based on the fact that the intraTMP mode is enabled for the current block, to encode a second syntax element into the bitstream. When the instructions are executed by the encoder's processor, they can cause the encoder's processor to determine, based on the second syntax element, whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode. The memory stores an instruction, and when the instruction is executed by the processor, it determines that the intraTMP predicted value is determined by the intraTMP fusion mode, and the processor is instructed to encode the third syntax element and the fourth syntax element into the bitstream. When the instruction is executed by the encoder's processor, the encoder's processor is instructed to determine the fusion weight set based on the fourth syntax element. When the instruction is executed by the encoder's processor, the encoder's processor is instructed to determine the intraTMP predicted value based on the fusion weight set and the reference block set indicated by the third syntax element.When the command is executed by the processor of the encoder, the processor of the encoder can be made to perform an operation of encoding the current block based on the intraTMP prediction value.

[0248] In some implementation manners, when the command is executed by the processor of the encoder, upon receiving a determination that the intraTMP prediction value of the current block is determined by the intraTMP fusion mode, the processor of the encoder can be made to perform an operation of performing a sparse search and a refinement search, and constructing a candidate list including N intraTMP block vectors by selecting a block vector based on the SAD cost calculated in the template region.

[0249] In some implementation manners, in order to perform a sparse search and a refinement search, and construct a candidate list including N intraTMP block vectors by selecting a block vector based on the SAD cost calculated in the template region, when the command is executed by the processor of the encoder, the processor of the encoder can be made to perform an operation of concurrently identifying a set of sparse candidate block vectors during the sparse search period. In some implementation manners, in order to perform a sparse search and a refinement search, and construct a candidate list including N intraTMP block vectors by selecting a block vector based on the SAD cost calculated in the template region, when the command is executed by the processor of the encoder, the processor of the encoder can be made to perform an operation of constructing the candidate list including N intraTMP block vectors by performing a search around the selected sparse candidate block vectors in the template shape.

[0250] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor can be prompted to determine the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element.

[0251] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor can be instructed to determine the fused weight set using an algorithm based on SAD, upon receiving that the fourth syntax element contains a first value. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor can be instructed to determine the fused weight set using an algorithm based on MSE, upon receiving that the fourth syntax element contains a second value.

[0252] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of encoding the fifth syntax element into the bitstream, in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of identifying a block vector from the candidate list based on the fifth syntax element.

[0253] In some implementations, the range of possible values ​​for the fifth syntax element is from 0 to 18. In some implementations, if the value of the fifth syntax element is within the range of 3 to 18, it is signaled in the bitstream as 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code.

[0254] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of encoding the sixth syntax element into the bitstream, in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of determining, based on the sixth syntax element, whether or not the intraTMP prediction value is determined by filtering the selected reference block.

[0255] In some implementations, when the instruction is executed by the encoder's processor, upon receiving that the sixth syntax element contains a first value, the encoder's processor can be instructed to determine the intraTMP predicted value by filtering the selected reference block using a learned filter.

[0256] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of encoding the seventh syntax element into the bitstream, upon receiving that the sixth syntax element contains a second value. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of determining whether or not the block vector is refined to fractional precision based on the seventh syntax element.

[0257] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of determining that the block vector is not refined to fractional precision upon receiving that the seventh syntax element contains a first value. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of determining that the block vector is refined to fractional precision upon receiving that the seventh syntax element contains a second value.

[0258] In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of encoding the eighth and ninth syntax elements into the bitstream, upon receiving that the seventh syntax element contains the second value. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of determining the sub-pixel refinement direction based on the eighth syntax element. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of determining the sub-pixel refinement phase based on the ninth syntax element. In some implementations, when the instruction is executed by the encoder's processor, the encoder's processor may perform the operation of refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase.

[0259] The above description of the embodiments clarifies the general nature of the disclosure and, without requiring excessive experimentation, can be easily modified and / or adapted to various applications of these embodiments by applying the technical knowledge of the art, without departing from the general concept of the disclosure. Accordingly, such adaptations and modifications are intended to be within the meaning and scope of equivalents of the disclosed embodiments, based on the teachings and guidance provided herein. It should be understood that the phrases or terms in this paper are for illustrative purposes only and not limiting, and therefore, those skilled in the art should interpret the terms or phrases herein in accordance with the teachings and guidance.

[0260] The embodiments of this disclosure are described above using functional structure blocks that show how to implement the specified functions and their relationships. For convenience of description, the boundaries of these functional structure blocks are arbitrarily defined in this paper. Alternative boundaries can be defined if the specified functions and their relationships are properly implemented.

[0261] The summary and abstract of the invention may include one or more exemplary embodiments of the present disclosure as envisioned by the inventors, but these are not all embodiments and are not intended to limit the scope of the present disclosure or the appended claims in any way.

[0262] Various functional blocks, modules, and steps are disclosed above. The arrangements provided are illustrative and not limiting. Accordingly, functional blocks, modules, and steps can be rearranged and combined in ways different from the examples provided above. Similarly, some embodiments include only a subset of functional blocks, modules, and steps, and any such subset is permitted.

[0263] The breadth and scope of this disclosure should not be limited by any exemplary embodiments described above, but should be limited only by the appended claims and their equivalents.

Claims

1. A decoding method performed by a decoder, The processor decodes multiple syntax elements associated with intra-template prediction (intraTMP) by analyzing the bitstream, The processor decodes the first syntax element from the bitstream, The processor determines, based on the first syntax element, whether or not intraTMP mode is enabled for the current block. In response to the fact that the intraTMP mode is enabled for the current block, the processor decodes the second syntax element from the bitstream, The processor determines, based on the second syntax element, whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode. Upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the processor decodes the third syntax element and the fourth syntax element from the bitstream. The processor determines the fused weight set based on the fourth syntax element, The processor determines the intraTMP prediction value based on the fused weight set and the reference block set indicated by the third syntax element, The processor includes decoding the current block based on the intraTMP prediction value, A decoding method characterized by the following:

2. Upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the processor further constructs a candidate list containing N intraTMP block vectors by performing sparse search and refinement search to select block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The method according to feature 1.

3. The processor constructs a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template region. The processor performs the identification of the sparse candidate block vector set in parallel during the sparse search period, The processor constructs a candidate list containing N intraTMP block vectors by performing a search around the sparse candidate block vectors in the selected template shape, The method according to feature 2.

4. The processor further includes determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element, The method according to feature 1.

5. In response to the fact that the fourth syntax element includes a first value, the processor determines the fused weight set by an algorithm based on the sum of absolute differences (SAD), In response to the fourth syntax element containing a second value, the processor further determines the fused weight set using an algorithm based on the mean squared error (MSE), The method according to feature 1.

6. Upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the processor decodes the fifth syntax element from the bitstream. The processor further includes identifying a block vector from the candidate list based on the fifth syntax element, The method according to feature 2.

7. The fifth syntax element is signaled in the bitstream in the form of 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code, when the range of values ​​taken is from 0 to 18 and the value is within the range of 3 to 18. The method according to feature 6.

8. Upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the processor decodes the sixth syntax element from the bitstream, The processor further includes determining whether the intraTMP prediction value is determined by filtering selected reference blocks based on the sixth syntax element, The method according to feature 6.

9. The process further includes the processor determining the intraTMP prediction value by filtering the selected reference block using a learned filter, in response to the sixth syntax element containing a first value. The method according to feature 8.

10. Upon learning that the sixth syntax element contains a second value, the processor decodes the seventh syntax element from the bitstream. The processor further includes determining whether the block vector is refined to fractional precision based on the seventh syntax element. The method according to feature 9.

11. In response to the seventh syntax element containing a first value, the processor determines that the block vector is not refined to fractional precision, The processor further determines, upon learning that the seventh syntax element includes a second value, that the block vector is refined to fractional precision. The method according to the present invention, characterized by the present invention.

12. Upon learning that the seventh syntax element includes the second value, the processor decodes the eighth and ninth syntax elements from the bitstream. The processor determines the sub-pixel refinement direction based on the eighth syntax element, The processor determines the sub-pixel refinement phase based on the ninth syntax element, The processor further includes refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase, The method according to the present invention, characterized by the features described in the present invention.

13. Processor and Includes memory in which instructions are stored, When the aforementioned instruction is executed by the processor, The operation involves decoding multiple syntax elements associated with intra-template prediction (intraTMP) by analyzing the bitstream, The operation of decoding the first syntax element from the bitstream, Based on the first syntax element, the operation of determining whether intraTMP mode is currently enabled for the block, Given that the intraTMP mode is enabled for the current block, the operation involves decoding the second syntax element from the bitstream, Based on the second syntax element, the operation is to determine whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, Upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the operation of decoding the third syntax element and the fourth syntax element from the bitstream is performed. The operation of determining the fusion weight set based on the aforementioned fourth syntax element, The operation of determining the intraTMP predicted value based on the aforementioned fused weight set and the reference block set indicated by the third syntax element, The processor is instructed to perform the operation of decoding the current block based on the intraTMP predicted value. A decoder characterized by the following features.

14. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, further, Upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the processor is instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The decoder according to claim 13.

15. Instructions are stored in the memory to construct a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template area, and when these instructions are executed by the processor, further, The operation involves, in parallel with the sparse search period, identifying a set of sparse candidate block vectors, The processor is instructed to perform the following operations: to construct the candidate list containing N intraTMP block vectors by searching around the sparse candidate block vectors with the selected template shape; The decoder according to feature 14.

16. Instructions are stored in the memory, and when these instructions are executed by the processor, further, The processor is instructed to perform the operation of determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element. The decoder according to claim 13.

17. Instructions are stored in the memory, and when these instructions are executed by the processor, further, Given that the fourth syntax element includes a first value, the operation involves determining the fused weight set using an algorithm based on the sum of absolute differences (SAD), The processor is instructed to perform the following operation: upon receiving that the fourth syntax element includes a second value, the fused weight set is determined by an algorithm based on the mean squared error (MSE). The decoder according to claim 13.

18. Instructions are stored in the memory, and when these instructions are executed by the processor, further, The operation of decoding a fifth syntax element from the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The processor is instructed to perform the operation of identifying a block vector from the candidate list based on the fifth syntax element, The decoder according to feature 14.

19. The fifth syntax element is signaled in the bitstream in the form of 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code, when the range of values ​​taken is from 0 to 18 and the value is within the range of 3 to 18. The decoder according to feature 18.

20. Instructions are stored in the memory, and when these instructions are executed by the processor, further, The operation of decoding the sixth syntax element from the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The processor is instructed to perform the operation of determining whether the intraTMP prediction value is determined by filtering the selected reference block based on the sixth syntax element. The decoder according to feature 18.

21. Instructions are stored in the memory, and when these instructions are executed by the processor, further, Upon receiving that the sixth syntax element contains a first value, the processor is instructed to perform the operation of determining the intraTMP predicted value by filtering the selected reference block using a trained filter. The decoder according to feature 20.

22. Instructions are stored in the memory, and when these instructions are executed by the processor, further, The operation of decoding the seventh syntax element from the bitstream, given that the sixth syntax element contains a second value, The processor is instructed to perform the operation of determining whether or not the block vector is refined to fractional precision based on the seventh syntax element. The decoder according to feature 21.

23. Instructions are stored in the memory, and when these instructions are executed by the processor, further, The operation of determining that the block vector is not refined to fractional precision upon finding that the seventh syntax element contains a first value, The processor is instructed to perform the operation of determining that the block vector is refined to fractional precision upon receiving that the seventh syntax element contains a second value. The decoder according to feature 22.

24. Instructions are stored in the memory, and when these instructions are executed by the processor, further, The operation of decoding the eighth and ninth syntax elements from the bitstream, based on the fact that the seventh syntax element contains the second value, The operation of determining the sub-pixel refinement direction based on the eighth syntax element, The operation of determining the sub-pixel refinement phase based on the ninth syntax element, The processor is instructed to perform the operation of refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase. The decoder according to feature 23.

25. The command is stored, When the aforementioned instruction is executed by the decoder's processor, The operation involves decoding multiple syntax elements associated with intra-template prediction (intraTMP) by analyzing the bitstream, The operation of decoding the first syntax element from the bitstream, Based on the first syntax element, the operation of determining whether intraTMP mode is currently enabled for the block, Given that the intraTMP mode is enabled for the current block, the operation involves decoding the second syntax element from the bitstream, Based on the second syntax element, the operation is to determine whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, Upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the operation of decoding the third syntax element and the fourth syntax element from the bitstream is performed. The operation of determining the fusion weight set based on the aforementioned fourth syntax element, The operation of determining the intraTMP predicted value based on the aforementioned fused weight set and the reference block set indicated by the third syntax element, The decoder's processor is instructed to perform the operation of decoding the current block based on the intraTMP predicted value. A non-temporary computer-readable medium.

26. When the aforementioned instruction is executed by the decoder's processor, Upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the decoder's processor is instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The non-temporary computer-readable medium according to feature 25.

27. The instruction is executed by the decoder's processor to construct a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template region. The operation involves, in parallel with the sparse search period, identifying a set of sparse candidate block vectors, The decoder's processor is instructed to perform the following operations: to construct the candidate list containing N intraTMP block vectors by searching around the sparse candidate block vectors with the selected template shape; The non-temporary computer-readable medium according to feature 26.

28. When the aforementioned instruction is executed by the decoder's processor, The decoder's processor is instructed to perform the operation of determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element. The non-temporary computer-readable medium according to feature 25.

29. When the aforementioned instruction is executed by the decoder's processor, Given that the fourth syntax element includes a first value, the operation involves determining the fused weight set using an algorithm based on the sum of absolute differences (SAD), The decoder's processor is instructed to perform the operation of determining the fused weight set using an algorithm based on the mean squared error (MSE), given that the fourth syntax element includes a second value. The non-temporary computer-readable medium according to feature 25.

30. When the aforementioned instruction is executed by the decoder's processor, The operation of decoding a fifth syntax element from the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The decoder's processor is instructed to perform the operation of identifying a block vector from the candidate list based on the fifth syntax element. The non-temporary computer-readable medium according to feature 26.

31. The fifth syntax element is signaled in the bitstream in the form of 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code, when the range of values ​​taken is from 0 to 18 and the value is within the range of 3 to 18. The non-temporary computer-readable medium according to claim 30.

32. When the aforementioned instruction is executed by the decoder's processor, The operation of decoding the sixth syntax element from the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The decoder's processor is instructed to perform the operation of determining whether the intraTMP prediction value is determined by filtering the selected reference block based on the sixth syntax element. The non-temporary computer-readable medium according to claim 30.

33. When the aforementioned instruction is executed by the decoder's processor, Upon learning that the sixth syntax element contains a first value, the decoder's processor is instructed to perform the operation of determining the intraTMP predicted value by filtering the selected reference block using a trained filter. The non-temporary computer-readable medium according to feature 32.

34. When the aforementioned instruction is executed by the decoder's processor, The operation of decoding the seventh syntax element from the bitstream, given that the sixth syntax element contains a second value, The decoder's processor is instructed to perform the operation of determining whether or not the block vector is refined to fractional precision based on the seventh syntax element. The non-temporary computer-readable medium according to feature 33.

35. When the aforementioned instruction is executed by the decoder's processor, The operation of determining that the block vector is not refined to fractional precision upon finding that the seventh syntax element contains a first value, The decoder's processor is instructed to perform the operation of determining that the block vector is refined to fractional precision, given that the seventh syntax element contains a second value. The non-temporary computer-readable medium according to feature 34.

36. When the aforementioned instruction is executed by the decoder's processor, The operation of decoding the eighth and ninth syntax elements from the bitstream, based on the fact that the seventh syntax element contains the second value, The operation of determining the sub-pixel refinement direction based on the eighth syntax element, The operation of determining the sub-pixel refinement phase based on the ninth syntax element, The decoder's processor is instructed to perform the operation of refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase. The non-temporary computer-readable medium according to feature 35.

37. An encoding method performed by an encoder, The processor enables intra-template prediction (intraTMP) to encode the current block, The processor encodes the first syntax element into a bitstream, The processor determines, based on the first syntax element, whether or not intraTMP mode is enabled for the current block. In response to the fact that the intraTMP mode is enabled for the current block, the processor encodes the second syntax element into the bitstream, The processor determines, based on the second syntax element, whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode. Upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the processor encodes the third syntax element and the fourth syntax element into the bitstream. The processor determines the fused weight set based on the fourth syntax element, The processor determines the intraTMP prediction value based on the fused weight set and the reference block set indicated by the third syntax element, The processor includes encoding the current block based on the intraTMP predicted value, An encoding method characterized by the following.

38. Upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the processor further constructs a candidate list containing N intraTMP block vectors by performing sparse search and refinement search to select block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The method according to feature 37.

39. The processor constructs a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The processor performs the identification of the sparse candidate block vector set in parallel during the sparse search period, The processor constructs a candidate list containing N intraTMP block vectors by performing a search around the sparse candidate block vectors in the selected template shape, The method according to the feature of 38.

40. The processor further includes determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element, The method according to feature 37.

41. In response to the fact that the fourth syntax element includes a first value, the processor determines the fused weight set by an algorithm based on the sum of absolute differences (SAD), In response to the fourth syntax element containing a second value, the processor further determines the fused weight set using an algorithm based on the mean squared error (MSE), The method according to feature 37.

42. Upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the processor encodes the fifth syntax element into the bitstream. The processor further includes identifying a block vector from the candidate list based on the fifth syntax element, The method according to the feature of 38.

43. The fifth syntax element is signaled in the bitstream in the form of 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code, when the range of values ​​taken is from 0 to 18 and the value is within the range of 3 to 18. The method according to 42, characterized by the features described above.

44. Upon receiving that the second syntax element indicates that intraTMP fusion is not enabled for the current block, the processor encodes the sixth syntax element into the bitstream. The processor further includes determining whether the intraTMP prediction value is determined by filtering selected reference blocks based on the sixth syntax element, The method according to 42, characterized by the features described above.

45. The process further includes the processor determining the intraTMP prediction value by filtering the selected reference block using a learned filter, in response to the sixth syntax element containing a first value. The method according to feature 44.

46. In response to the sixth syntax element containing a second value, the processor encodes the seventh syntax element into the bitstream, The processor further includes determining whether the block vector is refined to fractional precision based on the seventh syntax element. The method according to 45, characterized by...

47. In response to the seventh syntax element containing a first value, the processor determines that the block vector is not refined to fractional precision, The processor further determines, upon learning that the seventh syntax element includes a second value, that the block vector is refined to fractional precision. The method according to 46, characterized by...

48. Upon learning that the seventh syntax element includes the second value, the processor encodes the eighth and ninth syntax elements into the bitstream. The processor determines the sub-pixel refinement direction based on the eighth syntax element, The processor determines the sub-pixel refinement phase based on the ninth syntax element, The processor further includes refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase, The method according to feature 47.

49. Processor and Includes memory in which instructions are stored, When the aforementioned instruction is executed by the processor, The operation involves enabling intra-template prediction (intraTMP) and encoding the current block, The operation involves encoding the first syntax element into a bitstream, Based on the first syntax element, the operation of determining whether intraTMP mode is currently enabled for the block, Given that the intraTMP mode is enabled for the current block, the operation involves encoding the second syntax element into the bitstream, Based on the second syntax element, the operation is to determine whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, Upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the operation of encoding the third syntax element and the fourth syntax element into the bitstream is performed. The operation of determining the fusion weight set based on the aforementioned fourth syntax element, The operation of determining the intraTMP predicted value based on the aforementioned fused weight set and the reference block set indicated by the third syntax element, The processor is instructed to perform the operation of encoding the current block based on the intraTMP predicted value. An encoder characterized by the following features.

50. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, Upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the processor is instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The encoder according to feature 49.

51. Instructions are stored in the memory to construct a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template area, and when these instructions are executed by the processor, The operation involves, in parallel with the sparse search period, identifying a set of sparse candidate block vectors, The processor is instructed to perform the following operations: to construct the candidate list containing N intraTMP block vectors by searching around the sparse candidate block vectors with the selected template shape; The encoder according to feature 50.

52. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, The processor is instructed to perform the operation of determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element. The encoder according to feature 49.

53. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, Given that the fourth syntax element includes a first value, the operation involves determining the fused weight set using an algorithm based on the sum of absolute differences (SAD), The processor is instructed to perform the following operation: upon receiving that the fourth syntax element includes a second value, the fused weight set is determined by an algorithm based on the mean squared error (MSE). The encoder according to feature 49.

54. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, The operation of encoding the fifth syntax element into the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The processor is instructed to perform the operation of identifying a block vector from the candidate list based on the fifth syntax element, The encoder according to feature 50.

55. The fifth syntax element is signaled in the bitstream in the form of 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code, when the range of values ​​taken is from 0 to 18 and the value is within the range of 3 to 18. The encoder according to feature 54.

56. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, The operation of encoding the sixth syntax element into the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The processor is instructed to perform the operation of determining whether the intraTMP prediction value is determined by filtering the selected reference block based on the sixth syntax element. The encoder according to feature 54.

57. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, Upon receiving that the sixth syntax element contains a first value, the processor is instructed to perform the operation of determining the intraTMP predicted value by filtering the selected reference block using a trained filter. The encoder according to feature 56.

58. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, The operation of encoding the seventh syntax element into the bitstream, given that the sixth syntax element contains a second value, The processor is instructed to perform the operation of determining whether or not the block vector is refined to fractional precision based on the seventh syntax element. The encoder according to feature 57.

59. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, The operation of determining that the block vector is not refined to fractional precision upon finding that the seventh syntax element contains a first value, The processor is instructed to perform the operation of determining that the block vector is refined to fractional precision upon receiving that the seventh syntax element contains a second value. The encoder according to feature 58.

60. Instructions are stored in the aforementioned memory. When the aforementioned instruction is executed by the processor, The operation of encoding the eighth and ninth syntax elements into the bitstream, in response to the seventh syntax element containing the second value, The operation of determining the sub-pixel refinement direction based on the eighth syntax element, The operation of determining the sub-pixel refinement phase based on the ninth syntax element, The processor is instructed to perform the operation of refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase. The encoder according to feature 59.

61. The command is stored, When the aforementioned instruction is executed by the encoder's processor, The operation involves enabling intra-template prediction (intraTMP) and encoding the current block, The operation involves encoding the first syntax element into a bitstream, Based on the first syntax element, the operation of determining whether intraTMP mode is currently enabled for the block, Given that the intraTMP mode is enabled for the current block, the operation involves encoding the second syntax element into the bitstream, Based on the second syntax element, the operation is to determine whether or not the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, Upon determining that the intraTMP predicted value is determined by the intraTMP fusion mode, the operation of encoding the third syntax element and the fourth syntax element into the bitstream is performed. The operation of determining the fusion weight set based on the aforementioned fourth syntax element, The operation of determining the intraTMP predicted value based on the aforementioned fused weight set and the reference block set indicated by the third syntax element, The encoder's processor is instructed to perform the operation of encoding the current block based on the intraTMP predicted value. A non-temporary computer-readable medium.

62. When the aforementioned instruction is executed by the encoder's processor, Upon determining that the intraTMP predicted value of the current block is determined by the intraTMP fusion mode, the encoder's processor is instructed to perform a sparse search and a refinement search to construct a candidate list containing N intraTMP block vectors by selecting block vectors based on the sum of absolute differences (SAD) cost calculated in the template region. The non-temporary computer-readable medium according to feature 61.

63. To construct a candidate list containing N intraTMP block vectors by performing sparse search and refinement search and selecting block vectors based on the SAD cost calculated in the template region, When the aforementioned instruction is executed by the encoder's processor, The operation involves, in parallel with the sparse search period, identifying a set of sparse candidate block vectors, The encoder's processor is instructed to perform the following operations: to construct the candidate list containing N intraTMP block vectors by searching around the sparse candidate block vectors with the selected template shape; A non-temporary computer-readable medium as described in 62.

64. When the aforementioned instruction is executed by the encoder's processor, The encoder's processor is instructed to perform the operation of determining the set of reference blocks selected to determine the intraTMP predicted value based on the third syntax element. The non-temporary computer-readable medium according to feature 61.

65. When the aforementioned instruction is executed by the encoder's processor, Given that the fourth syntax element includes a first value, the operation involves determining the fused weight set using an algorithm based on the sum of absolute differences (SAD), The encoder's processor is instructed to perform the following operation: In response to the fourth syntax element containing a second value, determine the fused weight set using an algorithm based on the mean squared error (MSE). The non-temporary computer-readable medium according to feature 61.

66. When the aforementioned instruction is executed by the encoder's processor, The operation of encoding the fifth syntax element into the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The encoder's processor is instructed to perform the operation of identifying a block vector from the candidate list based on the fifth syntax element. A non-temporary computer-readable medium as described in 62.

67. The fifth syntax element is signaled in the bitstream in the form of 0 followed by intra_tmp_idx-2, which is represented by a 4-bit fixed-length code, when the range of values ​​taken is from 0 to 18 and the value is within the range of 3 to 18. The non-temporary computer-readable medium according to feature 66.

68. When the aforementioned instruction is executed by the encoder's processor, The operation of encoding the sixth syntax element into the bitstream in response to the second syntax element indicating that intraTMP fusion is not enabled for the current block, The encoder's processor is instructed to perform the operation of determining whether the intraTMP prediction value is determined by filtering the selected reference block based on the sixth syntax element. The non-temporary computer-readable medium according to feature 66.

69. When the aforementioned instruction is executed by the encoder's processor, Upon learning that the sixth syntax element contains a first value, the encoder's processor is instructed to perform the operation of determining the intraTMP predicted value by filtering the selected reference block using a trained filter. A non-temporary computer-readable medium according to feature 68.

70. When the aforementioned instruction is executed by the encoder's processor, The operation of encoding the seventh syntax element into the bitstream, given that the sixth syntax element contains a second value, The encoder's processor is instructed to perform the operation of determining whether or not the block vector is refined to fractional precision based on the seventh syntax element. The non-temporary computer-readable medium according to feature 69.

71. When the aforementioned instruction is executed by the encoder's processor, The operation of determining that the block vector is not refined to fractional precision upon finding that the seventh syntax element contains a first value, The encoder's processor is instructed to perform the operation of determining that the block vector is refined to fractional precision, given that the seventh syntax element contains a second value. A non-temporary computer-readable medium according to the feature of 70.

72. When the aforementioned instruction is executed by the encoder's processor, The operation of encoding the eighth and ninth syntax elements into the bitstream, in response to the seventh syntax element containing the second value, The operation of determining the sub-pixel refinement direction based on the eighth syntax element, The operation of determining the sub-pixel refinement phase based on the ninth syntax element, The encoder's processor is instructed to perform the operation of refining the block vector based on the sub-pixel refinement direction and the sub-pixel refinement phase. The non-temporary computer-readable medium according to feature 71.