WO2025007263A1 - 编解码方法、码流、编码器、解码器以及存储介质 - Google Patents
编解码方法、码流、编码器、解码器以及存储介质 Download PDFInfo
- Publication number
- WO2025007263A1 WO2025007263A1 PCT/CN2023/105611 CN2023105611W WO2025007263A1 WO 2025007263 A1 WO2025007263 A1 WO 2025007263A1 CN 2023105611 W CN2023105611 W CN 2023105611W WO 2025007263 A1 WO2025007263 A1 WO 2025007263A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- block
- transformation model
- model
- syntax element
- transformation
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/46—Embedding additional information in the video signal during the compression process
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/70—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by syntax aspects related to video coding, e.g. related to compression standards
Definitions
- the present application relates to the field of video coding and decoding technology, and in particular to a coding and decoding method, a bit stream, an encoder, a decoder and a storage medium.
- Intra Block Copy (IBC) technology is an intra prediction technology based on block matching to obtain predicted pixels. Similar to inter prediction, prediction is achieved through a block vector pointing from the current block to the reference block. The difference is that the reference block of inter prediction comes from the encoded reconstructed frame, while the reference block of IBC comes from the reconstructed part of the current frame.
- Local Illumination Compensation (LIC) technology is a block-level linear transformation technology. The LIC method characterizes that there is a linear relationship between the current coding block and the reference block.
- IBC technology can determine the reference block from the current frame by block compensation. On this basis, IBC technology can be combined with LIC technology to perform linear transformation on the reference block to determine the prediction block, thereby improving the accuracy of prediction.
- linear transformation parameters in the LIC technology are derived from the adjacent reconstructed pixels of the current block and the reference block, which cannot provide a variety of parameter choices and has limitations, affecting the encoding and decoding performance.
- the present application provides a coding and decoding method, a bit stream, an encoder, a decoder and a storage medium, which can improve the diversity of prediction and thus improve the coding and decoding performance.
- an embodiment of the present application provides a decoding method, which is applied to a decoder, and the method includes:
- the constructed transformation model list includes at least two types of transformation models
- a prediction block of a current block is determined.
- an embodiment of the present application provides an encoding method, which is applied to an encoder, and the method includes:
- a first transformation model is obtained from the constructed transformation model list;
- the constructed transformation model list includes at least two types of transformation models;
- an embodiment of the present application provides a code stream, which is generated by bit encoding according to information to be encoded; wherein the information to be encoded includes at least one of the following:
- the first syntax element is used to indicate a prediction mode of a current block using an intra-block copy technology
- the second syntax element is used to indicate whether the current block is predicted using a transform model list
- the third syntax element is used to indicate whether to use a transform technique for prediction
- the fourth syntax element is used to indicate a model index of the transformation model in the transformation model list
- the fifth syntax element is used to indicate the index of the local compensation model when using the multi-mode local compensation technology
- the sixth syntax element is used to indicate index information of a reference block.
- an embodiment of the present application provides a decoder, including:
- the decoding part is configured to obtain relevant syntax elements of the current block; wherein the relevant syntax elements are used to indicate whether the current block is predicted using an intra-block copy technology combined with a transform model list;
- a first determining part is configured to determine a reference block obtained by using the intra-block copying technology for a current block
- the constructed transformation model list includes at least two types of transformation models
- the first prediction part is configured to determine a prediction block of a current block based on the reference block and the first transform model.
- an embodiment of the present application provides a decoder, comprising a first memory and a first processor; wherein:
- a first memory for storing a computer program that can be run on the first processor
- the first processor is used to execute the decoding method as described in the first aspect when running a computer program.
- an encoder including:
- the second determining part is configured to determine a candidate block vector list of the current block; determine a reference block vector based on the candidate block vector list; determine a reference block based on the reference block vector; when determining that the prediction mode of the current block is the intra block copy technology combined with the transformation model list for prediction, obtain a first transformation model from the constructed transformation model list; the constructed transformation model list includes at least two types of transformation models;
- a second prediction part is configured to determine a prediction block of a current block based on the reference block and the first transformation model
- the encoding part is configured to encode the relevant syntax elements of the current block, and write the obtained encoding bits into the bitstream through the writing part; wherein the relevant syntax elements are used to indicate whether the current block is predicted using the intra-frame block copy technology combined with the transformation model list.
- an encoder including a second memory and a second processor; wherein:
- a second memory for storing a computer program that can be run on a second processor
- the second processor is used to execute the encoding method as described in the second aspect when running the computer program.
- an embodiment of the present application provides a computer-readable storage medium, which stores a computer program.
- the computer program When the computer program is executed by a first processor, it implements the decoding method as described in the first aspect, or when it is executed by a second processor, it implements the encoding method as described in the second aspect.
- the embodiment of the present application provides a coding and decoding method, a bit stream, an encoder, a decoder and a storage medium.
- the decoder or the encoder can select a first transformation model from a transformation model list including at least two types of transformation models; the selected first transformation model is used to transform the reference block, and then the prediction block is determined. Therefore, in the process of coding and decoding implementation, the first transformation model used to implement the transformation can be selected and determined from the transformation model list, which can ensure the diversity of selection, thereby making the possibility in the prediction process higher, improving the diversity of prediction, and ultimately improving the coding and decoding performance.
- Figure 1 is a schematic diagram of the prediction process of an Intra TMP technology
- FIG2 is a schematic diagram of a matching block of the Intra TMP technology
- FIG3 is a schematic diagram of a template type of Intra TMP technology
- FIG4A is a schematic diagram of a rough search process of template matching in the Intra TMP technology
- FIG4B is a schematic diagram of a detailed search process of template matching in the Intra TMP technology
- FIG5 is a schematic diagram of weighted fusion of an IntraTMP fusion prediction technology
- FIG6A is a schematic diagram of a filter shape
- FIG6B is a schematic diagram of a filter coefficient derivation method
- FIG7 is a schematic diagram of a coding block vertical and horizontal division method
- Fig. 8 is a schematic diagram of the position
- FIG9A is a schematic block diagram of a composition of an encoder provided in an embodiment of the present application.
- FIG9B is a schematic block diagram of a decoder provided in an embodiment of the present application.
- FIG10 is a schematic diagram of a network architecture of a coding and decoding system provided in an embodiment of the present application.
- FIG11 is a schematic diagram of a flow chart of a decoding method provided in an embodiment of the present application.
- FIG12 is a schematic diagram of a flow chart of an encoding method provided in an embodiment of the present application.
- FIG13 is a schematic diagram of the structure of a decoder provided in an embodiment of the present application.
- FIG14 is a schematic diagram of a specific hardware structure of a decoder provided in an embodiment of the present application.
- FIG15 is a schematic diagram of the structure of an encoder provided in an embodiment of the present application.
- FIG16 is a schematic diagram of a specific hardware structure of an encoder provided in an embodiment of the present application.
- CU Coding Unit
- CTU Coding Tree Unit
- MSE Mean Square Error
- ECM Enhanced Compression Model
- JVET Joint Video Experts Team
- BDPCM Block Differential Pulse Coded Modulation
- IBC Intra Block Copy
- LIC Local Illumination Compensation
- a first color component, a second color component, and a third color component are generally used to represent a coding block.
- the three color components are a brightness component, a blue chroma component, and a red chroma component.
- the brightness component is usually represented by the symbol Y
- the blue chroma component is usually represented by the symbol Cb or U
- the red chroma component is usually represented by the symbol Cr or V; in this way, the video image can be represented in the YCbCr format or the YUV format.
- Intra TMP technology is a special intra-frame prediction technology, referred to as IntraTMP technology, which is a special intra-frame prediction coding tool, mainly used for screen content coding.
- IntraTMP is mainly implemented through the following process: select some reconstructed pixels adjacent to the current coding block as templates, search for the most similar template in the given reconstructed area of the current frame, and use the reconstructed block corresponding to the most similar template as a matching block, which is used as the prediction block of the current coding block.
- the template of the coding block usually selects the adjacent reconstructed area of the current coding block.
- the area filled with a grid represents the reconstructed area
- R1, R2, R3 and R4 in the reconstructed area are search areas, and R1 to R4 are searched in turn to find matching blocks.
- the adjacent area of the current block is the first template (T); and the adjacent area of the matching block (also referred to as the "reference block") is the second template (i.e., the "reference block template” or "matching template", T_BEST).
- both the encoder and the decoder search the template (T) of the coding block in the predefined search range in the current image to determine the matching template (T_BEST) with the smallest template error value, and then use the corresponding reconstructed block (Ref Block) of the matching template as the prediction block of the current coding block (Cur Block).
- the similarity between templates is represented by the size of the template error value. The smaller the template error value, the higher the similarity.
- the template error value can be the absolute error and SAD, the absolute transformation difference and SATD, the mean square error MSE, the error square sum SSD, the mean absolute difference MAD, the mean error square sum MSD, the normalized correlation coefficient NCC, etc., which is not specifically limited here.
- the template error value at this time is as follows:
- Ti is the template in the search process
- M represents the number of pixels in the template.
- the Intra TMP technology uses the adjacent reconstructed pixels of the current block as templates to search for matching templates in a predefined search area, where the adjacent reconstructed pixels can be the upper reference pixel, upper left reference pixel, upper right reference pixel, left reference pixel and lower left reference pixel of the current block, etc. Therefore, the template type can be classified and the corresponding template type can be determined according to the availability of the adjacent reconstructed pixels.
- FIG. 3 shows a schematic diagram of the template type of the Intra TMP technology. As shown in Figure 3, the block filled with a grid is the current block, and the adjacent area of the current block is the template T. Six template types are shown here.
- the six template types are as follows:
- the value of refTemplateType is 1, and the template shape is as shown in (a) of FIG. 3 ;
- the codec uses the flag intra_tmp_flag to indicate whether the current coding block is encoded using the IntraTMP mode. If so, the same template matching process is performed on the decoding end to obtain the same prediction block on the decoding end, without the need to additionally encode the block vector information from the current coding block to the matching block.
- the Intra TMP technology uses the flag intra_tmp_flag to indicate whether the current coding block is encoded using the IntraTMP mode. If so, the same template matching process is performed on the decoding end to obtain the same prediction block on the decoding end, without the need to additionally encode the block vector information from the current coding block to the matching block.
- IntraTMP adaptation for camera-captured content is based on the original IntraTMP technology. It proposes to perform template matching with a step size of S (i.e., every S points in the horizontal and vertical directions, S>1) (as shown in Figure 4A). For example, in the search area, instead of searching for matching blocks point by point according to the raster scan, the search area is searched at every other point in the horizontal and vertical directions. For example, if the current block vector for template matching is (X0, Y0), the next block vector for template matching should be (X0+S, Y0), and the vertical coordinate of the block vector for template matching in the downstream should be Y0+S.
- the best matching block is refined within a certain range (as shown in Figure 4B, template matching is performed with a smaller step size S') to optimize the matching result.
- This technology effectively reduces the complexity of the IntraTMP mode while maintaining good coding efficiency.
- IntraTMP multi-candidate technology obtains N candidate matching blocks in the reference area through the template matching process, or builds a candidate block list of length N.
- the candidate matching blocks in the list can be sorted according to the template error value between the current block and the current block.
- a candidate block in the list is selected as the final prediction block by index.
- intra_tmp_flag For the coded block using IntraTMP multi-candidate technology, after decoding the IntraTMP flag intra_tmp_flag as true, continue to decode intra_tmp_idx, and the intra_tmp_idx syntax element can represent the index of the selected candidate block.
- a template matching process for constructing a candidate block list is as follows:
- the first step is to perform the first search with a certain step size, for example, the horizontal step size and the vertical step size are both 4. N optimal matching blocks with a certain spacing are obtained (the first N with the smallest template error value);
- a second search is performed in the N neighboring areas of the matching blocks obtained in the first step. These neighboring areas can be set to multiple non-overlapping areas according to the step size in the first step. M optimal matching blocks (which may include the matching blocks obtained in the first step) are obtained from these areas.
- the same construction process is used at the encoding and decoding ends to obtain a consistent list of candidate blocks.
- Intra_tmp_idx can use fixed-length encoding or variable-length encoding, for example, truncated binary encoding.
- a variable length encoding method is:
- a shorter codeword can be set for a smaller intra_tmp_idx. For example, as shown in Table 1:
- IntraTMP fusion prediction technology also known as IntraTMP multi-matching block fusion technology
- the template error values of the reconstructed block and the current coding block at different positions can be obtained.
- These reconstructed blocks can be represented by the block vectors of the current coding block pointing to the reconstructed blocks; a candidate block vector list is constructed to record the block vectors with smaller template error values in the template matching process; one or more block vectors are selected from the candidate block vector list according to conditions such as the block vector spacing and the template error value, and the reconstructed blocks pointed to are used as matching blocks of the current coding block; a weight value is determined for each matching block; these matching blocks are weighted and fused according to their weight values to obtain the final prediction block, thus realizing the IntraTMP combined fusion prediction.
- the process is shown in Figures 5A and 5B.
- the weight of each matching block can be determined by using a preset fixed value, calculating according to a template error value, or deducing according to a template.
- the matching block (also called reference block) obtained by intra-frame template matching is usually directly used as the prediction block of the current block.
- the prediction block can be filtered to improve the prediction effect.
- a block-level flag can be used to indicate whether the current block uses the filtering process on the prediction block.
- C is the pixel to be filtered
- N is the pixel above it
- S is the pixel below it
- W is the pixel on the left
- E is the pixel on the right, as shown in FIG6A.
- B (Bias) is a fixed value, for example, B is the median of the pixel range.
- c0 to c5 are filter coefficients.
- One method of determining the filter coefficients is to train the filter coefficients using the reference block template and the current block template.
- the template area is the reconstruction area of the upper 4 rows and the left 4 columns of the current block.
- an additional row of areas on the upper, lower, left and right sides of the template area is also required as a reference. As shown in FIG6B , if part of the additional area is not encoded, it can be copied from the template area.
- One method for training filter coefficients is to calculate a set of coefficients so that the template error value between the filtered reference block template and the current block template is minimized.
- a method for filtering the prediction block directly obtained from the reference block is to filter each pixel in order from left to right and from top to bottom, and use the filtered value as the prediction value.
- IntraTMP fusion prediction can obtain multiple reference blocks through the intra-frame template matching process and perform weighted fusion on these reference blocks.
- the weight value is usually obtained by using a predefined fixed value or calculating based on the template error of each reference block.
- n is the total number of reference blocks
- Wi is the weight value corresponding to the reference block with a template error value of SADi.
- the form of the prediction block after weighted fusion can be as shown in formula (6):
- the template-derived IntraTMP fusion method uses a method similar to filter coefficient training to obtain weights for fusion prediction based on the reference block template and the current block template. For example, using 5 reference blocks for weighted fusion, the form is shown in formula (7):
- One weighted method is to calculate a set of coefficients so that the template error between the reference block template and the current block template is minimized.
- the template-based intra mode derivation (TIMD) technology uses the reconstructed pixels of the L-shaped part adjacent to the current coding block as a template, and calculates the predicted pixels of the template area under different intra prediction modes by traversing the MPM list.
- the template error values of the predicted pixels and reconstructed pixels under different intra prediction modes are obtained, which are represented by the Sum of Absolute Transformed Difference (SATD).
- SATD Sum of Absolute Transformed Difference
- the optimal intra prediction mode is selected according to the template error value.
- the intra prediction mode is obtained by the same derivation method, thereby reducing the coding bits of the mode information.
- CIIP Combined Inter and Intra Prediction
- ECM ECM
- CIIP is combined with template-based prediction technology, and different weight values are assigned to different regions, which further improves the accuracy of prediction.
- its intra prediction block pred_intra is obtained by TIMD mode
- the inter prediction block pred_inter is obtained by template-based Merge mode.
- the weight values wIntra and wInter are determined.
- wIntra and wInter are determined according to the intra prediction mode intra_dir derived from TIMD.
- 2 ⁇ intra_dir ⁇ 34 the current coding block is divided into four equal parts vertically;
- the weight values of each region wIntra and wInter are shown in Table 3:
- indexes of each region under vertical or horizontal quadrisection are shown in Figure 7.
- intra_dir is equal to 0 or 1
- the sub-region is not divided, and wIntra and wInter are selected from (3,1), (2,2), (1,3) according to the coding type (intra-frame or inter-frame) of the two coding blocks located on the left and on the top.
- Intra Block Copy (IBC) technology is an intra prediction technology based on block matching to obtain predicted pixels. Similar to inter prediction, prediction is achieved through the block vector pointing from the current block to the reference block. The difference is that the reference block of inter prediction comes from the encoded reconstructed frame, while the reference block of IBC comes from the reconstructed part of the current frame. Block vector information needs to be transmitted by the bitstream, so similar to intra prediction, there are IBC-AMVP mode and IBC-Merge mode.
- the IBC-AMVP mode obtains the predicted block vector by constructing a list of candidate block vectors. Based on the predicted block vector, the reference block of the current block and the corresponding final block vector are obtained through hash search, full search and other processes. The final block vector is encoded according to the predicted block vector to improve coding efficiency.
- the IBC-Merge mode predicts by constructing a list of candidate block vectors, and selects the best block vector in the list as the final block vector through SATD, RDO and other encoding processes, and uses the reconstructed block it points to as the reference block to complete the prediction.
- the index of the block vector in the list is encoded instead of the block vector itself, which improves the encoding efficiency.
- the candidate block vector list may be composed of coding information such as block vectors of adjacent coded blocks, historically coded block vectors, and average block vectors.
- the candidate block vector list may include information such as a local illumination compensation LIC flag. If the LIC flag of a candidate is true, when the current block selects the candidate block vector, the LIC flag of the current block is set to true.
- Local illumination compensation technology is a block-level linear transformation technology.
- ⁇ and ⁇ can be derived from pixels in a reconstructed area adjacent to the current coding block and pixels in a reconstructed area adjacent to the reference block, and obtained by a least square method or the like.
- a threshold value can be set, and different linear parameters can be selected according to the size relationship between the reference block pixels and the threshold value, which can be expressed as formula (10):
- the inter-frame coding block in Merge mode can add non-adjacent candidates when constructing the Merge List.
- each non-adjacent point is selected and the merge candidate is attempted to be constructed.
- the pixel positions of the non-adjacent points and the current block are shown in FIG8 .
- the positions marked 1-5 in FIG8 are called candidates for adjacent positions, and the rest are called candidates for non-adjacent positions.
- the multi-mode IBC-LIC technique divides the IBC-LIC method into multiple sub-methods according to the template area used to derive the linear parameters and the number of linear transformation models.
- One example is to divide IBC-LIC into the following four methods:
- a specific IBC-LIC sub-method can be selected by means of a coding index.
- IBC technology can obtain a reference block from the current frame by means of block compensation.
- IBC technology can be combined with LIC technology to perform a linear transformation on the reference block, thereby improving the accuracy of prediction.
- LIC technology is that its linear transformation parameters are derived from the reconstructed pixels adjacent to the current block and the reference block, and cannot provide a variety of parameter options.
- This application proposes a method for constructing a list of candidate transformation models for a current coding block based on the transformation models used by the coded blocks, which can improve the diversity of predictions.
- the coding end makes a decision to select the optimal transformation model for the current coding block, thereby improving coding efficiency.
- the encoder 100 may include a transform and quantization unit 101, an intra-frame estimation unit 102, an intra-frame prediction unit 103, a motion compensation unit 104, a motion estimation unit 105, an inverse transform and inverse quantization unit 106, a filter control analysis unit 107, a filtering unit 108, an encoding unit 109, and a decoded image cache unit 110, etc.
- the filtering unit 108 may implement deblocking filtering and sample adaptive offset (Sample Adaptive Offset, SAO) filtering
- the encoding unit 109 may implement header information encoding and context-based adaptive binary arithmetic coding (Context-based Adaptive Binary Arithmetic Coding, CABAC).
- a video coding block can be obtained by dividing the coding tree unit (CTU), and then the residual pixel information obtained after intra-frame or inter-frame prediction is transformed by the transformation and quantization unit 101 to transform the video coding block, including transforming the residual information from the pixel domain to the transform domain, and quantizing the obtained transform coefficients to further reduce the bit rate;
- the intra-frame estimation unit 102 and the intra-frame prediction unit 103 are used to perform intra-frame prediction on the video coding block; specifically, the intra-frame estimation unit 102 and the intra-frame prediction unit 103 are used to determine the intra-frame prediction mode to be used to encode the video coding block;
- the motion compensation unit 104 and the motion estimation unit 105 are used to perform inter-frame prediction coding of the received video coding block relative to one or more blocks in one or more reference frames to provide temporal prediction information;
- the motion estimation performed by the motion estimation unit 105 is a process of generating a motion vector, and the motion vector can estimate the motion of the video coding block, and then
- the motion vector determined by the motion estimation unit 105 performs motion compensation; after determining the intra-frame prediction mode, the intra-frame prediction unit 103 is also used to provide the selected intra-frame prediction data to the encoding unit 109, and the motion estimation unit 105 also sends the calculated and determined motion vector data to the encoding unit 109; in addition, the inverse transform and inverse quantization unit 106 is used to reconstruct the video coding block, reconstruct the residual block in the pixel domain, and the reconstructed residual block is removed by the filter control analysis unit 107 and the filtering unit 108.
- the encoding unit 109 is used to encode various coding parameters and quantized transform coefficients.
- the context content can be based on adjacent coding blocks and can be used to encode information indicating the determined intra-frame prediction mode and output the code stream of the video signal; and the decoded image buffer unit 110 is used to store the reconstructed video coding block for prediction reference. As the video image encoding proceeds, new reconstructed video encoding blocks are continuously generated, and these reconstructed video encoding blocks are stored in the decoded image buffer unit 110 .
- the decoder 200 includes a decoding unit 201, an inverse transform and inverse quantization unit 202, an intra-frame prediction unit 203, a motion compensation unit 204, a filtering unit 205, and a decoded image cache unit 206, etc., wherein the decoding unit 201 can implement header information decoding and CABAC decoding, and the filtering unit 205 can implement deblocking filtering and SAO filtering.
- the decoding unit 201 can implement header information decoding and CABAC decoding
- the filtering unit 205 can implement deblocking filtering and SAO filtering.
- a code stream of the video signal is output; the code stream is input to the decoder 200, and first passes through the decoding unit 201 to obtain the decoded transform coefficients; the transform coefficients are processed by the inverse transform and inverse quantization unit 202 to generate residual blocks in the pixel domain; the intra-frame prediction unit 203 can be used to generate prediction data for the current video decoding block based on the determined intra-frame prediction mode and the data from the previously decoded blocks of the current frame or picture; the motion compensation unit 204 is to determine the prediction information for the video decoding block by analyzing the motion vector and other associated syntax elements, and use The prediction information is used to generate a predictive block of the video decoding block being decoded; a decoded video block is formed by summing the residual block from the inverse transform and inverse quantization unit 202 and the corresponding predictive block generated by the intra-frame prediction unit 203 or the motion compensation unit 204; the decoded video signal passes through the filtering unit 205 to remove the block effect artifacts
- the embodiment of the present application also provides a network architecture of a codec system including an encoder and a decoder, wherein Figure 10 shows a schematic diagram of the network architecture of a codec system provided by the embodiment of the present application.
- the network architecture includes one or more electronic devices 13 to 1N and a communication network 01, wherein the electronic devices 13 to 1N can perform video interaction through the communication network 01.
- the electronic device can be various types of devices with video codec functions during implementation, for example, the electronic device can include a smart phone, a tablet computer, a personal computer, a personal digital assistant, a navigator, a digital phone, a video phone, a television, a sensor device, a server, etc., which are not specifically limited here.
- the decoder or encoder described in the embodiment of the present application can be the above-mentioned electronic device.
- the method of the embodiment of the present application is mainly applied to the intra-estimation unit 102 and the intra-prediction unit 103 as shown in FIG9A and the intra-prediction unit 203 as shown in FIG9B . That is to say, the embodiment of the present application can be applied to both the encoder and the decoder, and can even be applied to both the encoder and the decoder at the same time, but the embodiment of the present application is not specifically limited.
- the "current block” specifically refers to the coding block currently to be intra-frame predicted; when applied to the intra-frame prediction unit 203, the "current block” specifically refers to the decoding block currently to be intra-frame predicted.
- FIG11 a schematic flow chart of a decoding method provided by an embodiment of the present application is shown. As shown in FIG11, the method may include:
- S104 Determine a prediction block of the current block based on the reference block and the first transformation model.
- the decoding method is applied in the scenario for the intra-frame block copy technology.
- the reference block can be transformed before determining the prediction block of the current block, or the reference block can be not transformed to achieve the determination of the prediction block.
- the embodiment of the present application proposes a method for transforming a reference block and then predicting it, which can be implemented based on a constructed transformation model list.
- transforming the reference block may include: implementing based on the selection of a transform model in a transform model list.
- the transform of the reference block may also be implemented based on one of a preset LIC transform, a multi-model LIC transform, or a filter transform.
- the transform model list includes at least two types of transform models.
- the reference block can be transformed to obtain the prediction block.
- the transformation of the reference block can be in the following ways:
- Multi-model LIC transformation The relationship between the predicted block pixel Pred(x, y) and the reference block pixel ref(x, y) is as shown in formula (12):
- threshold is the reference pixel threshold, and different parameters are used to perform linear transformation on the reference block pixels that exceed the threshold.
- Pred(x,y) c0C+c1N+c2S+c3E+c4W+c5B
- C is the reference block pixel at (x, y)
- N is the pixel above it
- S is the pixel below it
- W is the pixel to the left
- E is the pixel to the right, as shown in the figure below.
- B (Bias) is a fixed value, for example, B is the median of the pixel range.
- c0 to c5 are filter coefficients.
- the filter transforms the reference pixels in a certain area
- some pixels outside the area will be used as input, and the pixels inside the area can be used to fill the part outside the area.
- the pixels outside the area have been reconstructed, the reconstructed values are directly used.
- the required parameter information (such as ⁇ i , ⁇ i , c i , threshold, etc.) can be saved as the parameter information and model type corresponding to the position of the codec block, which is used when the subsequent IBC codec block constructs the transformation model candidate list.
- a code stream may be acquired or parsed to obtain relevant syntax elements of the current block, and the relevant syntax elements are used to indicate whether the current block is predicted using an intra-block copy technology combined with a transform model list.
- the relevant syntax element information may include multiple syntax elements.
- the relevant syntax elements include at least: a second syntax element.
- the second syntax element is used to indicate whether the current block is predicted using a transform model list.
- the decoder can use one of the existing preset LIC transforms, multi-model LIC transforms, or filter transforms to implement the transform of the reference block, or does not transform the reference block, which is not limited in the embodiments of the present application.
- the second syntax element may be represented by cu_ibc_model_merge_flag, representing a merge flag in the IBC mode.
- the relevant syntax elements may further include: a first syntax element; the first syntax element is used to indicate a prediction mode of the current block using an intra-block copy technology.
- the first syntax element may be represented by pu_merge_flag, which indicates a prediction mode flag bit that the current block uses the intra-block copy technology.
- the prediction mode using the intra-block copy technology may include: optimized motion vector prediction (IBC-AMVP) mode or merge mode (IBC-Merge).
- the decoder parses the bitstream to obtain the encoding information of the block vector, and based on the candidate block vector list constructed based on the candidate block, it can determine the reference block of the current block when using the intra-frame block copy technology.
- the decoder determines that the current decoding uses prediction based on the transform model list based on the relevant syntax elements
- the first transform model can be determined from the transform model list based on the relevant syntax elements.
- the decoder transforms the reference block based on the first transform model to obtain the prediction block of the current block, and then determines the prediction value of the prediction block.
- the decoder parses the coding residual in the bitstream, it determines the reconstruction value of the current block based on the prediction value and the coding residual, and completes the decoding process of the current block.
- the decoder parses the bitstream and decodes the first syntax element; determines the prediction mode of the current block using the intra-block copy technology according to the first syntax element, and decodes the second syntax element.
- the value of the decoded first syntax element when the value of the decoded first syntax element is a first value, it indicates that the prediction mode of the current block using the intra-block copy technology is an optimized motion vector prediction mode, and when the value of the decoded first syntax element is a second value, it indicates that the prediction mode of the current block using the intra-block copy technology is a merge mode.
- the manner of decoding the second syntax element may be different.
- the value of the decoded second syntax element when the value of the decoded second syntax element is a first value, it indicates that the current block is predicted using the transformation model list, and when the value of the decoded second syntax element is a second value, it indicates that the current block is not predicted using the transformation model list.
- the first value is different from the second value, and the first value and the second value can be in parameter form or in digital form.
- the first identification information can be a parameter written in the profile or a flag value, which is not specifically limited here.
- the first value can be set to 1 and the second value can be set to 0; or, the first value can be set to 0 and the second value can be set to 1; or, the first value can be set to true and the second value can be set to false; or, the first value can be set to false and the second value can be set to true; but this is not specifically limited here.
- the value of the second syntax element is 0 (false)
- it can be determined that the prediction method of the transform model list is not used for the current block that is, the decoding method based on the transform model list proposed in the present application is not used
- the value of the first identification information is 1 (true)
- it can be determined that the prediction method of the transform model list is used for the current block that is, the decoding method based on the transform model list proposed in the present application is used.
- the embodiment of the present application does not limit the expression form of the first value and the second value.
- the first value is 0 (false) and the second value is 1 (true) as an example for description.
- the decoder determines whether to use the transformation model list for prediction based on the value of the decoded second syntax element, and can further determine which is the first transformation model for prediction and whether transformation processing is required.
- the transformation model list contains multiple transformation models. In the process of encoding each block, a different transformation model can be selected each time. This can increase the diversity of predictions and choose a suitable method for transformation for each block, instead of using a unified preset transformation model for the same transformation processing, thereby improving decoding performance.
- a flowchart of an optional decoding method provided by the basic application embodiment may include:
- the decoding process of S201 is consistent with the process in the aforementioned embodiment and will not be repeated here.
- the first syntax element is represented by pu_merge_flag
- pu_merge_flag indicates that the prediction mode is a merge model.
- the pu_merge_flag decoded by the decoder is the first value, that is, false
- the decoder can determine that the current block uses an optimized motion vector prediction mode.
- the decoder continues to parse the bitstream and can decode the third syntax element.
- the relevant syntax elements include: the third syntax element.
- the third syntax element indicates whether to use the transform technology for prediction.
- cu_ibc_lic_flag may be used to represent the third syntax element.
- cu_ibc_lic_flag indicates whether a transform is used to process the reference block for prediction. If the third syntax element is true, the transform is used; if the third syntax element is false, the transform is not used. However, even if a transform is used to process the reference block, it is necessary to further determine whether the transform model list is used for the transform, because the same preset transform model may be used to perform the same transform on all blocks.
- the value of the third syntax element can also be the first value, the second value, etc., which is the same as the setting expression of the first syntax element and the second syntax element, and will not be repeated here.
- the fourth syntax element is used to indicate the model index of the transformation model in the transformation model list;
- the related syntax element information also includes: the fourth syntax element;
- the decoder may decode the third syntax element as the first value (false) or the second value (true).
- the decoded third syntax element is the second value, it indicates that the current block is predicted by transforming the reference block, and the decoder needs to continue decoding the second syntax element to see whether to select a transform model suitable for the current block by using a transform model list or directly use a preset single transform model for transformation.
- the decoder in the process of decoding the second syntax element, when the decoder decodes the value of the second syntax element as the second value (true), indicating that the current block is predicted using the transformation model list, the decoder can continue to parse the bitstream, decode the fourth syntax element included in the relevant syntax element, and obtain the index information of the transformation model in the transformation model list.
- the fourth syntax element is used to indicate the model index of the transformation model in the transformation model list.
- the decoder may use cu_ibc_model_merge_idx to represent the fourth syntax element.
- S205 Determine a first transformation model in the constructed transformation model list based on the index information of the transformation model.
- S206 Determine a prediction block of the current block based on the reference block and the first transformation model.
- the decoder when the decoder decodes the fourth syntax element, it can determine the first transformation model corresponding to the index information of the transformation model represented by the fourth syntax element from the constructed transformation model list. In other words, during the prediction process of the current block, the decoder determines the first transformation model adapted to the current block from the transformation model list. In this way, the decoder can implement the transformation processing of the reference block based on the first transformation model, thereby obtaining the prediction block of the current block, and then perform subsequent decoding processing based on the prediction block.
- a candidate list of transformation models is constructed for the current block, and the prediction mode and transformation model of the current block are determined by writing the block-level mode flags (first syntax element, second syntax element, third syntax element) and the candidate index (fourth syntax element) of the bitstream.
- the syntax elements are as follows:
- the decoding process is as follows: Decode IBC prediction mode related elements. Decode cu_ibc_lic_flag. If cu_ibc_lic_flag is true, it indicates that the reference block of the coding block needs to be transformed. Further decode cu_ibc_model_merge_flag. If cu_ibc_model_merge_flag is true, it indicates that the transformation model is determined by building a transformation model candidate list. Further decode cu_ibc_model_merge_idx to determine which transformation model in the list is used. If cu_ibc_model_merge_flag is false, it indicates that the coding block uses the IBC-LIC method. If cu_ibc_lic_flag is false, it indicates that other IBC-based prediction methods are used.
- cu_ibc_lic_flag and cu_ibc_model_merge_flag can adopt an entropy coding method based on a context model.
- the value range of cu_ibc_model_merge_idx can be less than or equal to the maximum transform model candidate list length, and variable length coding can be used. The smaller the index, the shorter the corresponding codeword.
- the value range of cu_ibc_model_merge_idx is n, and truncated binary code coding is used.
- the codewords are shown in Table 4 below, and each bit under different codewords in Table 4 can use context model coding (Intra_tmp_idx) or equal probability coding.
- the decoder determines the first transformation model in the constructed transformation model list based on the index information of the transformation model, and the process may also include: if the fourth syntax element of the transformation model is a third value, indicating at least one other transformation model in the transformation model list, wherein the other transformation models are transformation methods corresponding to other reference blocks.
- the reference block transformation methods of other IBCs can also be used as model candidates in the transformation model list, and these methods and the inherited available transformation models can be encoded through a unified syntax element.
- a syntax element is used to represent the index of the transformation method transmission corresponding to other reference blocks, and the value of the index may indicate the selection of other LIC models, etc., to achieve multiplexing on the syntax element.
- the decoding method further includes:
- whether to decode the second syntax element can be determined by changing the meaning of the third syntax element. For example, when the third syntax element is true, it indicates that the reference block is not processed by transformation. When the third syntax element is false, it indicates that the reference block is processed by transformation.
- the decoder can decode the second syntax element when the value of the third syntax element is the first value (false).
- S207 is an alternative implementation method to S203, and the embodiment of the present application does not limit this.
- syntax elements are as follows:
- cu_ibc_lic_flag Decode cu_ibc_lic_flag. If cu_ibc_lic_flag is true, it indicates that the coding block uses the IBC-LIC method. If cu_ibc_lic_flag is false, further decode cu_ibc_model_merge_flag. If cu_ibc_model_merge_flag is true, it indicates that the transformation model is determined by building a transformation model candidate list. Further decode cu_ibc_model_merge_idx to determine which transformation model in the list is used. If cu_ibc_model_merge_flag is false, it indicates that other IBC-based prediction methods are used.
- the decoder when the decoder decodes the second syntax element as true, it indicates that the current block is predicted by using a transformation model list, and then the transformation model list needs to be constructed.
- the process of constructing the transformation model list by the decoder includes: sequentially adding at least one different transformation model to the initial transformation model list to obtain the transformation model list;
- the at least one transformation model includes at least one of the following:
- a third transformation model corresponding to pixels at at least one non-adjacent position of the current block
- At least one different transformation model is sequentially added to the initial transformation model list.
- the order of adding the models can be any order between the second transformation model, the third transformation model, the fourth transformation model, the available transformation model in the time domain, and the preset transformation model.
- any type of transformation model can include multiple.
- the order of adding at least one transformation model when constructing the transformation model candidate list may be different, for example, adding historical available transformation models first, and then adding non-adjacent available transformation models, etc., which is not limited in the embodiment of the present application.
- transformation model list has a maximum length, which is not limited in the embodiments of the present application.
- a transform model candidate list is constructed for the current coding block, with a maximum length of N.
- the list may be composed of the following candidates in order:
- the available transformation model of the adjacent position (the second transformation model).
- the default transformation model may include: a LIC transformation model with parameters ⁇ 0 , ⁇ 0 , and a transformation model obtained by adjusting the existing transformation models in the list.
- redundancy determination may be performed. For example, a transformation model to be added is added to the list only if it is different from all candidates in the list.
- variable model candidates in the time domain may be added.
- the list is constructed in the following order:
- the preset transformation model includes: a model corresponding to the preset model parameters or a model obtained by offsetting at least one of the second transformation model, the third transformation model and the fourth transformation model, the model corresponding to the preset model parameters and the available transformation model in the time domain.
- the offset refers to the offset of any parameter in any transformation model.
- a new transformation model can be obtained by performing some offsets on the existing candidate transformation model parameters and added to the transformation model list.
- the transformation model in the time domain is obtained by checking multiple adjacent points in the same frame in the reference frame list.
- the variable model candidates in the time domain after translation can also be added.
- the list is constructed in the following order:
- the motion vector for translation is first obtained based on the neighboring blocks of the current block, and then the vector is applied to each checkpoint of the temporal candidate as a new checkpoint to obtain the available transformation model of the temporal domain after translation.
- the above temporal candidate acquisition process can refer to the temporal candidate acquisition process in inter-frame prediction.
- the prediction type of the block corresponding to the second transformation model, the third transformation model and the fourth transformation model included in the transformation model list is any one of intra-frame simulation matching prediction and intra-frame block copy technology.
- the second transformation model, the third transformation model and the fourth transformation model can be from the IBC or IntraTMP intra-frame simulation matching prediction block, or only the transformation model from IBC or only the transformation model from IntraTMP can be used, which is not limited in the embodiments of the present application.
- the process of acquiring at least one transformation model to be added to the transformation model list can be obtained only when the transformation condition is met.
- a transformation condition includes at least one of the following:
- the block where the pixel is located uses the intra-block copy technology, the transformation model flag is valid, and the size of the block where the pixel is located meets the first preset size.
- the judgment of whether the above-mentioned at least one transformation model can be obtained can be: if the codec unit at the position is encoded and decoded by IBC mode or IntraTMP mode, and its prediction block is obtained by transforming the reference block, whether there is a transformation model, there is a transformation model flag (similar to the LIC flag) flag is valid, then the transformation model is obtained, and the transformation type is saved as a flag, which is convenient for checking the flag when the subsequent block construction list is constructed, but it is not transmitted by the encoder (the encoder transmission flag is also possible, different syntax elements), then the model used for transformation belongs to at least one transformation model. In addition, it is determined whether the codec unit at the position meets the predefined size limit to determine at least one transformation model.
- the at least one different transformation model includes at least one of the following: at least one transformation model has a different transformation type, has different model parameters, and uses different template areas under the same transformation type.
- transformation types are different, they are different, and the LIC transformations using different template regions are treated as different types;
- the decoder sequentially adds at least one different transformation model to the initial transformation model list, and the process of obtaining the transformation model list may be:
- the decoder sequentially adds at least one different transformation model to the initial transformation model list to obtain an intermediate transformation model list; and reorders the intermediate transformation model list to obtain a transformation model list.
- the order of adding the at least one transformation model added in sequence is not limited.
- the reordering process is optional and is not limited in the embodiment of the present application.
- the decoder reorders the intermediate transformation model list to obtain the transformation model list, including:
- the template error values of each transformation model are from small to large, and the index information of the corresponding transformation model list is from small to large.
- the error value is determined to be the maximum value.
- the offset value offset is calculated according to the current block template and the reference block template for the subsequent prediction value calculation; here, all transformation models need to be traversed to calculate the offset of each transformation model. It should be noted that if there is no reordering, only the offset of the selected transformation model can be calculated, and it is not necessary to calculate the offset for all candidates.
- the N rows above the current block and the M columns on the left are used as the current block template, and the corresponding adjacent area of the reference block is the reference block template.
- the transformation model list For a certain transformation model in the transformation model list, it is applied to the reference block template to obtain the prediction of the reference block template, and then the error value between the reference block template prediction and the current block template is obtained.
- the error value can be calculated by SAD, and the offset value is added to obtain the template error value; finally, the list is reordered according to the template error value corresponding to each transformation model. For example, the smaller the template error value of the transformation model, the smaller the corresponding model index; when the reference block template is not available, the SAD is set to the maximum value, such as the maximum value of the integer.
- each transformation model of different transformation types corresponds to a different reference block template area; and each transformation model error value is an average template error value of the number of pixels in the respective reference block template.
- the template error value of each transformation model can use different template areas, and the average template error value can be calculated according to the number of pixels of the template for comparison. It can also be extended to the scene of calculating offest, and different template areas can be used with different transformation types. For example, if the transformation type is LIC transformation using the left template, the left template can be used when calculating offset.
- first position information (upper left corner coordinates) of the current block and the current size of the current block are obtained;
- At least one adjacent position of the current block and at least one non-adjacent position of the current block are determined based on the first position information and the current size.
- the adjacent position and the non-adjacent position can be determined according to the position and size of the current block. For example, if the coordinates of the upper left corner of the current block are (X, Y), and the width and height are (W, H), then the adjacent positions can be (X-1, Y+H-1), (X+W-1, Y-1), (X-1, Y+H), (X-1, Y-1).
- the derived local compensation model is obtained, and the local compensation model is added to the transformation model list.
- the historical available transformation model may overlap with the available transformation model of the adjacent position and the available transformation model of the non-adjacent position, but the historical available transformation model corresponds to more areas, and the historical available transformation model saves the most recent historical transformation model of the most recent codec block in the coding and decoding order.
- the decoder maintains a list of historical transformation models, and removes duplicates from this list of historical transformation models in turn and then adds them to the list of candidate transformation models.
- a historical transformation model used in the decoding process is obtained; when the same model exists in the historical transformation model and in the historical transformation model list, the same model in the historical transformation model list is removed, and the historical transformation model is added to the first sequence position of the historical transformation model list; when the same model does not exist in the historical transformation model and in the historical transformation model list, the historical transformation model is added to the first sequence position of the historical transformation model list.
- the process of adding a historical transformation model to the first sequence position of a historical transformation model list is: when the historical transformation model list meets a first preset list length, the transformation model at the last sequence position in the historical transformation model list is removed, and then the historical transformation model is added to the first sequence position of the historical transformation model list.
- the fourth transformation model is determined sequentially from the historical transformation models in the order from the first sequence digit to the last sequence digit of the historical transformation models.
- a list consisting of transformation models of encoded and decoded blocks can be maintained during the encoding and decoding process, which can be called a historical transformation model list, and is used to add candidates for historical transformation models (i.e., the fourth transformation model) when constructing a transformation model list for subsequent encoding and decoding blocks.
- the historical coding model list has a maximum length K and is a first-in-first-out list. That is, the transformation model added first is at the bottom of the list, and the transformation model added last is at the top of the list.
- the transformation model can be added to the historical list. When adding, determine whether the same model exists in the list.
- the historical transformation model list is updated based on the historical transformation model.
- a fifth syntax element is decoded; the fifth syntax element is used to indicate an index of a local compensation model when using a multi-mode local compensation technology;
- a prediction block of the current block is determined.
- the fifth syntax element is used to indicate the index of the local compensation model when using the multi-mode local compensation technology
- a prediction block of the current block is determined.
- the fifth syntax element can be expressed by cu_ibc_lic_idc.
- cu_ibc_lic_idc represents the index of the IBC-LIC sub-method under the multi-mode IBC-LIC technology.
- cu_ibc_lic_idc indicates the index of the LIC sub-method under the multi-mode IBC-LIC.
- the transformation model list includes multiple transformation models. In the process of encoding each block, a different transformation model can be selected each time, which can increase the diversity of prediction and select a suitable method for each block to transform, rather than using a unified preset transformation model for the same transformation processing, thereby improving the decoding performance.
- the transformation model list is not used for transformation, the LIC transformation model or the multi-mode IBC-LIC can also be used to implement the transformation processing to ensure decoding efficiency.
- the present application provides a flowchart of an optional decoding method, which may include:
- the decoding process of S201 is consistent with the process in the aforementioned embodiment and will not be repeated here.
- the decoder when the first syntax element is represented by pu_merge_flag, it indicates that the prediction mode is a merge model. Then, when the pu_merge_flag decoded by the decoder is the second value, that is, true, the decoder can determine that the current block adopts the optimized merge mode. At this time, the decoder continues to parse the bitstream and can decode the second syntax element.
- the fourth syntax element (cu_ibc_model_merge_idx), determines the index information of the transformation model, and skips the process of the current block inheriting the local compensation flag from the merge candidate block; the fourth syntax element is used to indicate the model index of the transformation model in the transformation model list; the related syntax element information also includes: the fourth syntax element;
- S304 Determine a first transformation model in the constructed transformation model list based on the index information of the transformation model.
- the decoding process of S303-S305 is consistent with the process of S204-S206 in the aforementioned embodiment, and will not be repeated here.
- a transformation model candidate list is constructed for the current coding block, and the prediction mode and transformation model of the current coding block are determined by writing the block-level mode flag (first syntax element, second syntax element) and the candidate index (fourth syntax element) of the bitstream.
- the syntax elements are as follows:
- the reference block is transformed according to the transformation model selected by cu_ibc_mdel_merge_idx.
- the decoding process is the same as the above embodiment.
- the process of the decoder determining the prediction block of the current block based on the reference block and the first transformation model is:
- the reference block is transformed by using the first transformation model, and the first offset value is compensated in the transformation result corresponding to each pixel to obtain a prediction block of the current block; or, the first offset value is used to compensate the parameters in the first transformation model to obtain an updated first transformation model, and then the updated first transformation model is used to transform the reference block.
- the first transformation model is an LIC model or a multi-mode LIC
- using the first offset value to compensate the parameters in the first transformation model is to compensate for ⁇ in the transformation model, thereby obtaining an updated first transformation model with updated ⁇ .
- the offset value offset can be calculated according to the pixel values of the current block and the reference block template area (matching template) to adjust the predicted value, for example:
- the final prediction value can be the transformed prediction value plus the offset block.
- Pred(x,y) ⁇ ref(x,y)+ ⁇ +offset (30)
- the calculation in the embodiment of the present application can be implemented by integer-based addition, multiplication and shift operations (rounding can be performed during shift operations), and the embodiment of the present application is not limited.
- the first transformation model is a local compensation model
- the method for calculating the offset can use the parameter derivation method of the LIC technology (derive ⁇ and ⁇ based on the template area, derive ⁇ based on the minimum error, and then derive ⁇ based on ⁇ and the pixel value in the area). That is, the LIC technology can be deduced to obtain ⁇ and ⁇ .
- the local compensation flag (LIC flag) of the current block is determined to be a second value.
- the IBC coding block constructs the Merge list, it refers to a certain position PU to construct the merge candidate. If the cu_ibc_model_merge_flag of the PU is true, then the next block, such as the next block on the right, can set the LIC flag of the merge candidate to true as the candidate for the Merge list of the next block.
- the process of the decoder determining the prediction block of the current block based on the reference block and the first transformation model is to use the first transformation model and the local compensation transformation model indicated by the local compensation flag to perform secondary transformation on the reference block in turn to determine the prediction block of the current block.
- the reference block is transformed according to the local compensation transformation model derived from the current block template and the reference block template to determine the prediction block of the current block.
- the LIC flag is true and cu_ibc_model_merge_flag is also true, two transformations can be performed at the same time, and the execution order is not limited. If the IBC coding block selects the merge candidate, the LIC flag of the coding block is true, and the LIC transformation should be performed on the reference block.
- the linear parameters are derived from the current block template and the reference block template.
- the local compensation flag (LIC flag) of the current block is determined to be a first value.
- IBC coding blocks construct Merge list, they refer to a certain position PU to construct merge candidates, and the cu_ibc_model_merge_flag of the PU can be ignored, that is, the cu_ibc_model_merge_flag of the PU is not used to determine whether the merge candidate undergoes LIC transformation. Whether the encoding and decoding of the subsequent blocks are transformed may have nothing to do with cu_ibc_model_merge_flag. That is, if cu_ibc_model_merge_flag is true, the LIC flag of the merge candidate can be set to false.
- the decoder may further decode the second syntax element according to the decoded information during the process of decoding the second syntax element, wherein the decoded information includes at least one of the following:
- the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block is the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block.
- the first decoding condition includes at least one of the following:
- the value of the CIIP flag is the first value (false);
- the value of the GPM flag is the first value (false);
- the MBVD flag is the first value (false);
- the skip flag is the first value (false);
- the TM_merge flag is the first value
- the size of the current block is smaller than the third preset size
- the area of the current block is greater than a first preset area threshold.
- the flag cu_ibc_model_merge_flag it is possible to determine whether to decode the flag cu_ibc_model_merge_flag only when the width and height of the current block meet a certain range and some limiting conditions according to the existing codec information. If the conditions are not met, cu_ibc_model_merge_flag is false and cu_ibc_model_merge_idx is not decoded. For example, the CIIP flag, GPM flag, MBVD flag, TM_merge flag and skip flag of the current block.
- the decoding process can be:
- decode cu_ibc_model_merge_flag may depend on other decoded mode flags, which is not limited in the embodiment of the present application.
- a second syntax element when at least one of a sequence-level syntax element, a frame-level syntax element, a slice-level syntax element, and a size of a current block satisfies a second decoding condition, a second syntax element is decoded.
- cu_ibc_model_merge_flag and cu_ibc_model_merge_idx can be determined based on conditions such as frame level, slice level flag, block size, etc.
- sequence-level flag sps_ibc_model_merge_enable_flag there is a sequence-level flag sps_ibc_model_merge_enable_flag, and the decoding process may be:
- a reference block for the current block is determined, and at least one prediction based on intra-frame block copy technology-intra-frame/inter-frame joint prediction, intra-frame block copy technology-geometric partitioning mode and intra-frame block copy technology-reconstruction value reordering is performed to obtain a reference prediction block of the reference block; the reference prediction block is used to update the reference block.
- the aforementioned reference block may also be a prediction block obtained by technologies such as IBC-CIIP, IBC-GPM, and RRIBC.
- update parameters of the multi-mode local compensation model are recalculated based on the current block template and the reference block template; and the first transformation model is updated based on the updated parameters.
- the threshold can be recalculated based on the templates of the current block and the reference block.
- the threshold in the transformation model list is available, but it can also be recalculated and used to transform the reference block.
- many decoding methods may be used to decode the second syntax element, which is not limited by the embodiments of the present application.
- cu_ibc_model_merge_flag can use multiple context models for joint encoding and decoding, select the context model according to the encoding and decoding information of adjacent blocks, or use equal probability encoding and decoding.
- decoding the fourth syntax element and determining the index information of the transformation model includes at least one of the following:
- the fourth grammatical element is decoded by partially adopting a decoding method of the second context model and partially adopting an equal probability decoding method to determine index information of the transformation model.
- each bit of cu_ibc_model_merge_idx can use context model coding and decoding, or use equal probability coding and decoding, or partially use context model coding and decoding and partially use equal probability coding and decoding.
- the relationship between the first context model for decoding the second syntax element information and the first context model for decoding the second syntax element information when the prediction mode of the current block using the intra-frame block copy technology is the merge mode includes: the same or different.
- the second context model for decoding the fourth syntax element information when the prediction mode of the current block using the intra-frame block copy technology is the optimized motion vector prediction mode, the second context model for decoding the fourth syntax element information, and when the prediction mode of the current block using the intra-frame block copy technology is the merge mode, the relationship between the second context model for decoding the fourth syntax element information includes: the same or different.
- cu_ibc_model_merge_flag and cu_ibc_model_merge_idx in IBC-AMVP mode and IBC-Merge mode can be encoded and decoded using different context models, or can be encoded and decoded using the same context model.
- the same context model can be used to encode and decode cu_ibc_model_merge_flag or cu_ibc_model_merge_idx.
- cu_ibc_model_merge_flag can use multiple context models for encoding and decoding, and select which context model to use based on the encoded and decoded information of the adjacent blocks. For example, when three context models are used, if the cu_ibc_model_merge_flag of the left block and the upper block are both true, context model 1 is used; if only one of the cu_ibc_model_merge_flag of the left block and the upper block is true, context model 2 is used; otherwise, context model 3 is used, etc., which is not limited in the embodiments of the present application.
- the present application provides a flowchart of an optional decoding method, which may include:
- the decoder when determining the reference block, can also decode and obtain the sixth syntax element of the reference block of the current block, which is used to indicate the index information of the reference block. In this way, the decoder can determine the reference block obtained by the intra-block copy technology for the current block in the Merge list based on the sixth syntax element.
- the decoder can determine the reference block of IBC according to the IBC-Merge related elements. For example, a Merge list is constructed for the current block, a merge candidate is determined according to the Merge index, and information such as the block vector and block vector accuracy of the current block is obtained, thereby obtaining the reference block of the current block through motion compensation.
- the decoder obtains the second syntax element of the merge candidate block of the reference information source corresponding to the reference block, that is, the cu_ibc_model_merge_flag of the decoded merge candidate block. If the cu_ibc_model_merge_flag of the merge candidate block of the current block is true, then the cu_ibc_model_merge_flag of the current block can be directly true, and the first transform model of the current block can be determined according to the transform model of the reference corresponding to the merge candidate block, instead of parsing the second syntax element of the current block from the bitstream, thereby reducing the transmission codewords.
- a merge candidate is constructed with reference to a certain position PU. If the cu_ibc_model_merge_flag of the candidate PU is true, the cu_ibc_model_merge_flag of the current coding block is set to true, and the transformation model of the PU is set to the transformation model of the current coding block.
- a transformation model candidate list is constructed for the current block, and the prediction mode and transformation model of the current block are determined according to the encoding and decoding information of the Merge candidates. There is no need to encode cu_ibc_model_merge_flag or cu_ibc_model_merge_idx, that is, cu_ibc_model_merge_flag is not transmitted.
- determining the first transform model of the current block based on the transform model of the reference corresponding to the merge candidate block includes at least one of the following:
- the reference transformation model is used as the first transformation model.
- a first transformation model type of a reference transformation model is determined; and a first transformation model consistent with the first transformation type is re-derived according to the reference block template and the current block template.
- S406 Determine a prediction block of the current block based on the reference block and the first transformation model.
- the decoding process of S406 is consistent with the process of S206 in the aforementioned embodiment, and will not be repeated here.
- the cu_ibc_model_merge_flag flag of the merge candidate it is determined whether the current block transforms the reference block. If cu_ibc_model_merge_flag is true, the first transformation model is used to calculate the offset value offset according to the reference pixels of the current block and the reference block template area, and the reference block of the current block is transformed to obtain the final prediction block, thereby completing the encoding and decoding of the current block.
- the historical transformation model list is updated based on the first transformation model.
- the first transformation model used by the current block is saved and added to the historical transformation model list for use in constructing the transformation model list of subsequent blocks.
- a prediction block of the current block is determined based on the reference block
- a fifth transform model of the current block is constructed in the template area or within the block for use in a subsequent decoding process.
- the second syntax element of the current block is the first value, indicating that the prediction method of the transform model list is not applicable
- the second syntax element of the merged candidate block of the current block is the first value, indicating that the second syntax element is the first value.
- one implementation is to indicate that the reference block is not processed using the transform technology, so the decoder can determine the prediction block of the current block based on the reference block.
- a transformation model is derived based on the reconstructed pixel values (template area or block) after coding and decoding, which is used for the subsequent transformation model list construction and inheritance of the method of this application.
- a corresponding transformation model is also constructed, so that the subsequent blocks can inherit it when the coded block is used as a reference block.
- the decoding method further includes:
- the method further includes:
- the seventh transformation model is used to replace the first transformation model, and the transformation model list is updated; or,
- the seventh transformation model is adopted and the transformation model list is updated.
- a transformation model is derived in the template area or block for subsequent transformation model list construction and inheritance of the method of this application.
- a transformation model (the type can be consistent with the original one) can be re-derived based on the reconstructed value of the current code block (intra-block area or template area) to directly replace the first transformation model used in the prediction process (update the model in the transformation model list).
- it is determined based on the error value such as SAD whether to replace the original transformation model in the transformation model list, leaving the model with a small error, or saving both models.
- the decoding method provided in the present application can be implemented based on inter-frame prediction or IntraTMP prediction, that is, the IBC coding block in the scheme is replaced by an Inter coding block or an IntraTMP coding block, and the embodiments of the present application are not limited thereto.
- FIG. 12 a flow chart of an encoding method provided in an embodiment of the present application is shown. As shown in FIG. 12 , the method may include:
- a first transformation model is obtained from the constructed transformation model list;
- the constructed transformation model list includes at least two types of transformation models;
- S506 encode relevant syntax elements of the current block, and write the obtained coded bits into the bitstream; wherein the relevant syntax elements are used to indicate whether the current block is predicted using the intra-block copy technology combined with the transformation model list.
- the related syntax elements include at least: a second syntax element (cu_ibc_model_merge_flag);
- the second syntax element is used to indicate whether the current block is predicted using a transform model list
- the related syntax elements further include: a first syntax element (pu_merge_flag), and the first syntax element is used to indicate a prediction mode of the current block using an intra block copy technology.
- a first syntax element (pu_merge_flag)
- the first syntax element is used to indicate a prediction mode of the current block using an intra block copy technology.
- the prediction modes of the intra block copy technology include: a merge mode and an optimized motion vector prediction mode; the method further includes:
- the value of the first syntax element is encoded as a first value, and a third syntax element is encoded; the third syntax element is used to indicate whether to use the transformation technology for prediction; the third syntax element belongs to the related syntax element;
- the method further includes:
- the prediction mode of the current block using the intra block copy technology is the merge mode
- the value of the first syntax element is encoded as a second value
- the second syntax element is encoded.
- the method further includes:
- the second syntax element is encoded as a second value
- the index information of the first transformation model in the transformation model list is encoded as a fourth syntax element
- the fourth syntax element is used to indicate the model index of the transformation model in the transformation model list
- the related syntax element information also includes: the fourth syntax element.
- the method further includes:
- the transformation model list is constructed.
- the step of constructing the transformation model list includes:
- the at least one transformation model comprises at least one of the following:
- a third transformation model corresponding to pixels at at least one non-adjacent position of the current block
- the preset transformation model includes: a model corresponding to the preset model parameters or a model obtained by offsetting at least one of the second transformation model, the third transformation model and the fourth transformation model, the model corresponding to the preset model parameters and the available transformation model in the time domain.
- the method further includes:
- a transformation condition includes at least one of the following:
- the block where the pixel is located uses the intra-block copy technology, the transform model flag is valid, and the size of the block where the pixel is located meets the first preset size.
- the at least one different transformation model includes at least one of the following: the at least one transformation model has a different transformation type, has different model parameters, and uses different template areas under the same transformation type.
- the step of sequentially adding at least one different transformation model to the initial transformation model list to obtain the transformation model list includes:
- the intermediate transformation model list is reordered to obtain the transformation model list.
- the reordering of the intermediate transformation model list to obtain the transformation model list includes:
- each of the transformation models respectively predicting the reference block template, and determining the reference block template prediction of each transformation model
- the transformation models are reordered according to the template error values of the transformation models to obtain the transformation model list.
- the template error values of the transformation models are arranged from small to large, and the index information of the corresponding transformation model list is arranged from small to large.
- the error value is determined to be a maximum value.
- first position information (upper left corner coordinates) of the current block and the current size of the current block are obtained;
- At least one adjacent position of the current block and at least one non-adjacent position of the current block are determined based on the first position information and the current size.
- a historical transformation model used in the encoding process is obtained
- the historical transformation model is added to the first order position of the historical transformation model list.
- the adding the historical transformation model to the first order position of the historical transformation model list includes:
- the historical transformation model list meets the first preset list length, after the transformation model at the last order in the historical transformation model list is removed, the historical transformation model is added to the first order in the historical transformation model list.
- the fourth transformation model is determined sequentially from the historical transformation models in the order of the historical transformation models from the first sequence position to the last sequence position.
- the historical transformation model list is updated based on the historical transformation model.
- determining a prediction block of a current block based on the reference block and the first transformation model includes:
- the reference block is transformed by using the first transformation model, and the first offset value is compensated in the transformation result corresponding to each pixel to obtain a prediction block of the current block; or, the parameters in the first transformation model are compensated by using the first offset value to obtain an updated first transformation model, and then the updated first transformation model is used to transform the reference block.
- the local compensation flag (LIC flag) of the current block is determined to be a second value
- the step of determining a prediction block of a current block based on the reference block and the first transformation model comprises:
- the first transformation model and the transformation model of local compensation indicated by the local compensation flag are used to perform secondary transformation on the reference block in sequence to determine the prediction block of the current block.
- the reference block is transformed according to the transformation model of local compensation derived from the current block template and the reference block template to determine the prediction block of the current block.
- encoding the second syntax element includes:
- the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block is the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block.
- encoding the second syntax element according to the encoded information includes:
- the first encoding condition includes at least one of the following:
- the value of the CIIP flag is a first value (false);
- the value of the GPM flag is a first value (false);
- the MBVD flag is a first value (false);
- the skip flag is a first value (false);
- the TM_merge flag bit is a first value
- the size of the current block is smaller than a third preset size
- the area of the current block is greater than a first preset area threshold.
- each transformation model of different transformation types corresponds to a different reference block template area
- the error value of each transformation model is an average template error value of the number of pixels in the respective reference block template.
- a sixth transform model is determined
- the third syntax element is encoded as the first value or the second value, and a fifth syntax element is encoded; the fifth syntax element is used to indicate an index of a local compensation model when a multi-mode local compensation technology is used.
- the local compensation flag (LIC flag) of the current block is determined to be a first value.
- encoding the second syntax element includes:
- the second syntax element is encoded.
- the fourth syntax element is encoded as a third value, wherein the other transformation model is a transformation mode corresponding to other reference blocks.
- the step of constructing the transformation model list includes:
- the derived local compensation model is obtained, and the local compensation model is added to the transformation model list.
- a reference block of the current block is determined to be predicted based on at least one of intra-frame block copy technology-intra-frame/inter-frame joint prediction, intra-frame block copy technology-geometric partition mode, and intra-frame block copy technology-reconstruction value reordering to obtain a reference prediction block of the reference block;
- the reference block is updated using the reference prediction block.
- update parameters of the multi-mode local compensation model are recalculated based on the current block template and the reference block template;
- the first transformation model is updated.
- encoding the second syntax element includes:
- the second syntax element is encoded by adopting an equal probability encoding method.
- encoding the index information of the first transformation model in the transformation model list as a fourth syntax element includes at least one of the following:
- the index information of the first transformation model in the transformation model list is encoded as a fourth syntax element by partially adopting the encoding method of the second context model and partially adopting the equal probability encoding method.
- the relationship between the first context model for encoding the second syntax element information and the first context model for encoding the second syntax element information when the prediction mode of the current block using the intra-frame block copy technology is the merge mode includes: the same or different.
- the relationship between the second context model for encoding the fourth syntax element information includes: the same or different.
- index information of a reference block is determined, and the index information of the reference block is encoded as a sixth syntax element, where the sixth syntax element is used to indicate the index information of the reference block.
- the method further includes:
- a first transformation model of the current block is determined.
- determining the first transform model of the current block based on the reference transform model corresponding to the merge candidate block includes:
- the reference transformation model is used as the first transformation model.
- determining the first transform model of the current block based on the reference transform model corresponding to the merge candidate block includes:
- the first transform model consistent with the first transform type is re-derived according to the reference block template and the current block template.
- determining the first transform model of the current block based on the reference transform model corresponding to the merge candidate block includes:
- a first transformation model of the current block is determined based on a reference transformation model corresponding to the merged candidate block.
- the method further includes:
- a fifth transform model of the current block is constructed in the template area or within the block for use in a subsequent encoding process.
- the method further includes:
- the seventh transformation model is adopted to update the transformation model list.
- the method further includes:
- the first transformation model is a local compensation model, obtaining pixel values of a first reconstructed region adjacent to the current coding block and pixel values of a second reconstructed region adjacent to the reference block;
- the prediction type of the block corresponding to the second transformation model, the third transformation model and the fourth transformation model included in the transformation model list is any one of intra-frame template matching prediction and intra-frame block copy technology.
- the historical transformation model list is updated based on the first transformation model.
- the first syntax element is encoded as a first value.
- the encoder can select a first transform model from a transform model list including at least two types of transform models; use the selected first transform model to transform the reference block, and then determine the prediction block. Therefore, in the process of encoding implementation, the first transform model used to implement the transformation can be selected and determined from the transform model list, which can ensure the diversity of selection, thereby making the possibility of the prediction process higher, improving the diversity of prediction, and ultimately improving the encoding performance.
- the embodiment of the present application provides a code stream, wherein the code stream is generated by bit encoding according to information to be encoded; wherein the information to be encoded includes at least one of the following: a first syntax element, a second syntax element, a third syntax element, a fourth syntax element, a fifth syntax element, a sixth syntax element, a size of a current block, a CIIP flag bit of the current block, a GPM flag bit, an MBVD flag bit, a skip flag bit, a TM_merge flag bit and a context model; wherein,
- the first syntax element is used to indicate a prediction mode of a current block using an intra-block copy technology
- the second syntax element is used to indicate whether the current block is predicted using a transform model list
- the third syntax element is used to indicate whether to use a transform technique for prediction
- the fourth syntax element is used to indicate a model index of the transformation model in the transformation model list
- the fifth syntax element is used to indicate the index of the local compensation model when using the multi-mode local compensation technology
- the sixth syntax element is used to indicate index information of a reference block.
- an embodiment of the present application provides a decoder 1, comprising:
- the decoding part 11 is configured to obtain relevant syntax elements of the current block; wherein the relevant syntax elements are used to indicate whether the current block is predicted using an intra-block copy technology combined with a transform model list;
- a first determining part 12 is configured to determine a reference block obtained by using the intra-block copying technique for a current block
- the constructed transformation model list includes at least two types of transformation models
- the first prediction part 13 is configured to determine a prediction block of a current block based on the reference block and the first transform model.
- the relevant syntax elements include at least: a second syntax element
- the second syntax element is used to indicate whether the current block is predicted using a transform model list.
- the related syntax elements also include: a first syntax element; the first syntax element is used to indicate a prediction mode of the current block using an intra-block copy technology.
- the decoding part 11 is further configured to decode the first syntax element
- a prediction mode of the current block using the intra block copy technology is determined, and the second syntax element is decoded.
- the first determining part 12 is further configured to determine that the prediction mode of the current block using the intra block copy technology is an optimized motion vector prediction mode when the value of the first syntax element is a first value;
- the decoding part 11 is further configured to decode a third syntax element, the third syntax element is used to indicate whether to use a transform technique for prediction; the third syntax element belongs to the related syntax element;
- the second syntax element is decoded.
- the first determining part 12 is further configured to determine that the prediction mode of the current block using the intra block copy technology is an optimized motion vector prediction mode when the value of the first syntax element is the first value, and the decoding part 11 is further configured to decode the second syntax element;
- the first determination part 12 is further configured to determine that the prediction mode of the current block using the intra-block copy technology is a merge mode when the value of the first syntax element is a second value, and the decoding part 11 is further configured to decode the second syntax element.
- the decoding part 11 is further configured to, when the value of the second syntax element is the second value, indicate that the current block uses the transformation model list for prediction, decode the fourth syntax element, determine the index information of the transformation model, and skip the process of the current block inheriting the local compensation flag from the merged candidate block; the fourth syntax element is used to indicate the model index of the transformation model in the transformation model list; the related syntax element information also includes: the fourth syntax element;
- the first determining part 12 is further configured to determine the first transformation model in the constructed transformation model list based on the index information of the transformation model.
- the first determining part 12 is further configured to construct the transformation model list when the value of the second syntax element is a second value.
- the first determining part 12 is further configured to sequentially add at least one different transformation model to the initial transformation model list to obtain the transformation model list;
- the at least one transformation model comprises at least one of the following:
- a third transformation model corresponding to pixels at at least one non-adjacent position of the current block
- the preset transformation model includes: a model corresponding to the preset model parameters or a model obtained by offsetting at least one of the second transformation model, the third transformation model and the fourth transformation model, the model corresponding to the preset model parameters and the available transformation model in the time domain.
- the first determining part 12 is further configured to obtain, for a pixel at any adjacent position of the current block or a pixel at any non-adjacent position of the current block, a second transformation model of the adjacent position of the current block if the pixel satisfies a transformation condition, or obtain a third transformation model corresponding to a pixel at any non-adjacent position of the current block; wherein the transformation condition includes at least one of the following:
- the block where the pixel is located uses the intra-block copy technology, the transform model flag is valid, and the size of the block where the pixel is located meets the first preset size.
- the at least one different transformation model includes at least one of the following: at least one transformation model has a different transformation type, has different model parameters, and uses different template areas under the same transformation type.
- the first determining part 12 is further configured to sequentially add at least one different transformation model to the initial transformation model list to obtain an intermediate transformation model list;
- the intermediate transformation model list is reordered to obtain the transformation model list.
- the first determining part 12 is further configured to traverse each transformation model in the intermediate transformation model list to determine the offset value of each transformation model;
- each of the transformation models respectively predicting the reference block template, and determining the reference block template prediction of each transformation model
- the transformation models are reordered according to the template error values of the transformation models to obtain the transformation model list.
- the template error values of the respective transformation models are from small to large, and the index information of the corresponding transformation model list is from small to large.
- the error value is determined to be a maximum value.
- the first determining part 12 is further configured to obtain first position information of the current block and a current size of the current block;
- At least one adjacent position of the current block and at least one non-adjacent position of the current block are determined based on the first position information and the current size.
- the first determining part 12 is further configured to obtain a historical transformation model to be used in the decoding process
- the historical transformation model is added to the first order position of the historical transformation model list.
- the first determination part 12 is further configured to, when the historical transformation model list meets a first preset list length, remove the transformation model in the last sequence position in the historical transformation model list and then add the historical transformation model to the first sequence position of the historical transformation model list.
- the fourth transformation model is determined sequentially from the historical transformation models in the order of the first sequence bit to the last sequence bit of the historical transformation models.
- the historical transformation model list is updated based on the historical transformation model.
- the first prediction part 13 is further configured to use the first transformation model to predict the reference block template of the current block and determine the predicted value of the pixel of the reference block template; determine the total error value between the predicted value of each pixel and the pixel of the current block template; based on the total error value, average each pixel to obtain a first offset value; use the first transformation model to transform the reference block, and compensate the first offset value in the transformation result corresponding to each pixel to obtain the predicted block of the current block; or, use the first offset value to compensate the parameters in the first transformation model to obtain an updated first transformation model, and then use the updated first transformation model to transform the reference block.
- the first determining part 12 is further configured to determine that the local compensation flag of the current block is a second value when the second syntax element corresponding to the merge candidate block of the current block is predicted using the transform model list;
- the first prediction part 13 is further configured to adopt the first transformation model and the local compensation transformation model indicated by the local compensation flag to perform secondary transformation on the reference block in sequence to determine the prediction block of the current block.
- the decoding part 11 is further configured to decode the second syntax element according to the decoded information, wherein the decoded information includes at least one of the following:
- the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block is the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block.
- the decoding part 11 is further configured to decode the second syntax element when the decoded information satisfies a first decoding condition
- the first decoding condition includes at least one of the following:
- the value of the CIIP flag bit is a first value
- the value of the GPM flag is a first value
- the MBVD flag bit is a first value
- the skip flag bit is a first value
- the TM_merge flag bit is a first value
- the size of the current block is smaller than a third preset size
- the area of the current block is greater than a first preset area threshold.
- each transformation model of different transformation types corresponds to a different reference block template area
- the error value of each transformation model is an average template error value of the number of pixels in the respective reference block template.
- the decoding part 11 is further configured to decode a fifth syntax element when the value of the third syntax element is the first value and after decoding the second syntax element, when the value of the third syntax element is the second value; the fifth syntax element is used to indicate an index of a local compensation model when using a multi-mode local compensation technology;
- the first determining part 12 is further configured to determine a sixth transformation model based on the fifth syntax element
- the first prediction part 13 is further configured to determine a prediction block of the current block based on the reference block and the sixth transformation model.
- the first determination part 12 is further configured to determine that the local compensation flag of the current block is a first value when the second syntax element corresponding to the merge candidate block of the current block is predicted using the transformation model list.
- the decoding part 11 is further configured to decode the second syntax element when at least one of the sequence-level syntax elements, frame-level syntax elements, slice-level syntax elements, and the size of the current block meets the second decoding condition.
- the decoding part 11 is further configured to decode a fifth syntax element when the value of the third syntax element is the second value and after decoding the second syntax element, when the value of the third syntax element is the first value; the fifth syntax element is used to indicate an index of a local compensation model when using a multi-mode local compensation technology;
- the first determining part 12 is further configured to determine a sixth transformation model based on the fifth syntax element
- the first prediction part 13 is further configured to determine a prediction block of the current block based on the reference block and the sixth transformation model.
- the first determination part 12 is further configured to indicate at least one other transformation model in the transformation model list if the fourth syntax element of the transformation model is a third value, wherein the other transformation model is a transformation mode corresponding to other reference blocks.
- the first determining part 12 is further configured to obtain a derived local compensation model and add the local compensation model to the transformation model list.
- the first determining part 12 is further configured to determine a reference block of the current block, and perform at least one prediction based on intra-frame block copy technology-intra-frame/inter-frame joint prediction, intra-frame block copy technology-geometric partition mode and intra-frame block copy technology-reconstruction value reordering to obtain a reference prediction block of the reference block;
- the reference block is updated using the reference prediction block.
- the first determining part 12 is further configured to recalculate update parameters of the multi-mode local compensation model based on the current block template and the reference block template when the first transformation model is a local compensation model using a multi-mode local compensation technology;
- the first transformation model is updated.
- the decoding part 11 is further configured to determine a first context model from at least one context model based on the decoding information of the adjacent blocks;
- the second syntax element is decoded by using an equal probability decoding method.
- the decoding part 11 is further configured to include at least one of the following:
- Decoding the fourth syntax element by using an equal probability decoding method to determine the index information of the transformation model
- the fourth syntax element is decoded by partially adopting a decoding method of the second context model and partially adopting an equal probability decoding method to determine the index information of the transformation model.
- the relationship between the first context model for decoding the second syntax element information and the first context model for decoding the second syntax element information when the prediction mode of the current block using the intra-frame block copy technology is the merge mode includes: the same or different.
- the second context model for decoding the fourth syntax element information when the prediction mode of the current block using the intra-frame block copy technology is the optimized motion vector prediction mode, the second context model for decoding the fourth syntax element information, and when the prediction mode of the current block using the intra-frame block copy technology is the merge mode, the relationship between the second context model for decoding the fourth syntax element information includes: the same or different.
- the decoding part 11 is further configured to obtain a sixth syntax element of a reference block of the current block, where the sixth syntax element is used to indicate index information of the reference block;
- the first determining part 12 is further configured to determine, based on the sixth syntax element, a reference block obtained by using the intra block copy technology for the current block.
- the first determining part 12 is further configured to obtain a second syntax element of a merge candidate block of the current block after determining the reference block obtained by the current block using the intra block copy technology;
- a first transformation model of the current block is determined.
- the first determining part 12 is further configured to use the reference transformation model as the first transformation model.
- the first determining part 12 is further configured to determine a first transformation model type of the reference transformation model
- the first transform model consistent with the first transform type is re-derived according to the reference block template and the current block template.
- the first determining part 12 is further configured to obtain a flip reference block flag of the merge candidate block
- a first transformation model of the current block is determined based on a reference transformation model corresponding to the merged candidate block.
- the first determining part 12 is further configured to determine the prediction block of the current block based on the reference block when the second syntax element of the current block is a first value, or when the second syntax element of the merge candidate block of the current block is a first value;
- a fifth transform model of the current block is constructed in the template area or within the block for use in a subsequent decoding process.
- the first determining part 12 is further configured to determine the reconstructed pixel value of the current block based on the prediction block of the current block after determining the prediction block of the current block based on the reference block and the first transformation model;
- the seventh transformation model is adopted to update the transformation model list.
- the first determining part 12 is further configured to obtain pixel values of a first reconstructed region adjacent to the current coding block and pixel values of a second reconstructed region adjacent to the reference block when the first transformation model is a local compensation model;
- the first prediction part 13 is further configured to transform the reference block using the third transformation model to obtain a prediction block of the current block.
- the prediction type of the block corresponding to the second transformation model, the third transformation model and the fourth transformation model included in the transformation model list is any one of intra-frame template matching prediction and intra-frame block copy technology.
- the historical transformation model list is updated based on the first transformation model.
- each functional unit of the decoder also executes the decoding method described in any one of the aforementioned embodiments.
- a "unit” may be a part of a circuit, a part of a processor, a part of a program or software, etc., and of course, it may be a module, or it may be non-modular.
- the components in the present embodiment may be integrated into a processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
- the above-mentioned integrated unit may be implemented in the form of hardware or in the form of a software functional module.
- the integrated unit is implemented in the form of a software function module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium.
- the technical solution of this embodiment is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product.
- the computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) or a processor to perform all or part of the steps of the method described in this embodiment.
- the aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc., various media that can store program codes.
- an embodiment of the present application provides a computer-readable storage medium, which is applied to the decoder 170.
- the computer-readable storage medium stores a computer program, and when the computer program is executed by the first processor, it implements the decoding method described in any one of the aforementioned embodiments.
- the decoder 170 may include: a first communication interface 1801, a first memory 1802 and a first processor 1803; each component is coupled together through a first bus system 1804. It can be understood that the first bus system 1804 is used to achieve connection and communication between these components.
- the first bus system 1804 also includes a power bus, a control bus and a status signal bus.
- various buses are labeled as the first bus system 1804 in Figure 14. Among them,
- the first communication interface 1801 is used for receiving and sending signals during the process of sending and receiving information with other external network elements;
- a first memory 1802 used for storing a computer program that can be run on the first processor 1703;
- the first processor 1803 is configured to decode a method when running the computer program.
- the first memory 1802 in the embodiment of the present application can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories.
- the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory.
- the volatile memory can be a random access memory (RAM), which is used as an external cache.
- RAM static RAM
- DRAM dynamic RAM
- SDRAM synchronous DRAM
- DDRSDRAM double data rate synchronous DRAM
- ESDRAM enhanced synchronous DRAM
- SLDRAM synchronous link DRAM
- DRRAM direct RAM bus RAM
- the first processor 1803 may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by the hardware integrated logic circuit or software instructions in the first processor 1803.
- the above-mentioned first processor 1803 can be a general-purpose processor, a digital signal processor (Digital Signal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.
- DSP Digital Signal Processor
- ASIC Application Specific Integrated Circuit
- FPGA Field Programmable Gate Array
- the methods, steps and logic block diagrams disclosed in the embodiments of the present application can be implemented or executed.
- the general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc.
- the steps of the method disclosed in the embodiments of the present application can be directly embodied as a hardware decoding processor to execute, or the hardware and software modules in the decoding processor can be executed.
- the software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc.
- the storage medium is located in the first memory 1802, and the first processor 1803 reads the information in the first memory 1802 and completes the steps of the above method in combination with its hardware.
- the processing unit can be implemented in one or more application specific integrated circuits (Application Specific Integrated Circuits, ASIC), digital signal processors (Digital Signal Processing, DSP), digital signal processing devices (DSP Device, DSPD), programmable logic devices (Programmable Logic Device, PLD), field programmable gate arrays (Field-Programmable Gate Array, FPGA), general processors, controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in this application or a combination thereof.
- ASIC Application Specific Integrated Circuits
- DSP Digital Signal Processing
- DSP Device digital signal processing devices
- PLD programmable logic devices
- FPGA field programmable gate array
- general processors controllers, microcontrollers, microprocessors, other electronic units for performing the functions described in this application or a combination thereof.
- the technology described in this application can be implemented by a module (such as a process, function, etc.) that performs the functions described in this application.
- the software code can be stored in a memory and executed by a processor.
- the memory can be implemented in the processor or outside the processor.
- the first processor 1803 is further configured to execute the decoding method described in any one of the aforementioned embodiments when running the computer program.
- This embodiment provides a decoder, for which the decoder can select a first transformation model from a transformation model list including at least two types of transformation models; the selected first transformation model is used to transform the reference block, and then the prediction block is determined. Therefore, in the decoding implementation process, the first transformation model used to implement the transformation can be selected and determined from the transformation model list, which can ensure the diversity of selection, thereby making the possibility in the prediction process higher, improving the diversity of prediction, and ultimately improving the decoding performance.
- FIG. 15 a schematic diagram of the composition structure of an encoder 2 provided in an embodiment of the present application is shown.
- the encoder 2 comprises:
- the second determining part 20 is configured to determine a candidate block vector list of the current block; determine a reference block vector based on the candidate block vector list; determine a reference block based on the reference block vector; when determining that the prediction mode of the current block is the intra block copy technology combined with the transformation model list for prediction, obtain a first transformation model from the constructed transformation model list; the constructed transformation model list includes at least two types of transformation models;
- a second prediction part 21 is configured to determine a prediction block of a current block based on the reference block and the first transformation model
- the encoding part 22 is configured to encode the relevant syntax elements of the current block, and write the obtained encoding bits into the bitstream through the writing part 23; wherein the relevant syntax elements are used to indicate whether the current block is predicted using the intra-frame block copy technology combined with the transformation model list.
- the relevant syntax elements include at least: a second syntax element
- the second syntax element is used to indicate whether the current block is predicted using a transform model list
- the related syntax elements further include: a first syntax element, and the first syntax element is used to indicate a prediction mode of the current block using an intra-block copy technology.
- the prediction modes of the intra-block copying technique include: a merge mode and an optimized motion vector prediction mode;
- the encoding part 22 is further configured to encode the value of the first syntax element as a first value when the prediction mode of the current block using the intra-block copy technology is an optimized motion vector prediction mode, and encode a third syntax element; the third syntax element is used to indicate whether to use the transformation technology for prediction; the third syntax element belongs to the related syntax element;
- the encoding part 22 is further configured to encode the value of the first syntax element as a second value and encode the second syntax element when the prediction mode of the current block using the intra-block copy technology is a merge mode.
- the encoding part 22 is further configured as
- the second syntax element is encoded as a second value
- the index information of the first transformation model in the transformation model list is encoded as a fourth syntax element
- the fourth syntax element is used to indicate the model index of the transformation model in the transformation model list
- the related syntax element information also includes: the fourth syntax element.
- the second determining part 20 is further configured to construct the transformation model list when the current block is predicted using the transformation model list.
- the second determining part 20 is further configured to sequentially add at least one different transformation model to the initial transformation model list to obtain the transformation model list;
- the at least one transformation model includes at least one of the following:
- a third transformation model corresponding to pixels at at least one non-adjacent position of the current block
- the preset transformation model includes: a model corresponding to the preset model parameters or a model obtained by offsetting at least one of the second transformation model, the third transformation model and the fourth transformation model, the model corresponding to the preset model parameters and the available transformation model in the time domain.
- the second determining part 20 is further configured to obtain, for a pixel at any adjacent position of the current block or a pixel at any non-adjacent position of the current block, a second transformation model of the adjacent position of the current block if the pixel satisfies a transformation condition, or obtain a third transformation model corresponding to a pixel at any non-adjacent position of the current block; wherein the transformation condition includes at least one of the following:
- the block where the pixel is located uses the intra-block copy technology, the transform model flag is valid, and the size of the block where the pixel is located meets the first preset size.
- the at least one different transformation model includes at least one of the following: at least one transformation model has a different transformation type, has different model parameters, and uses different template areas under the same transformation type.
- the second determining part 20 is further configured to sequentially add at least one different transformation model to the initial transformation model list to obtain an intermediate transformation model list;
- the intermediate transformation model list is reordered to obtain the transformation model list.
- the second determining part 20 is further configured to traverse each transformation model in the intermediate transformation model list to determine the offset value of each transformation model;
- each of the transformation models respectively predicting the reference block template, and determining the reference block template prediction of each transformation model
- the transformation models are reordered according to the template error values of the transformation models to obtain the transformation model list.
- the template error values of the respective transformation models are from small to large, and the index information of the corresponding transformation model list is from small to large.
- the error value is determined to be a maximum value.
- the second determining part 20 is further configured to obtain first position information of the current block and a current size of the current block;
- At least one adjacent position of the current block and at least one non-adjacent position of the current block are determined based on the first position information and the current size.
- the second determining part 20 is further configured to obtain a historical transformation model to be used in the encoding process
- the historical transformation model is added to the first order position of the historical transformation model list.
- the second determination part 20 is further configured to, when the historical transformation model list meets a first preset list length, remove the transformation model in the last sequence position in the historical transformation model list and then add the historical transformation model to the first sequence position of the historical transformation model list.
- the fourth transformation model is determined sequentially from the historical transformation models in the order of the first sequence bit to the last sequence bit of the historical transformation models.
- the second determining part 20 is further configured to update the historical transformation model list based on the historical transformation model when the size of the block corresponding to the historical transformation model to be added meets a second preset size.
- the second prediction part 21 is further configured to use the first transformation model to predict the reference block template of the current block to determine the predicted value of the pixel of the reference block template;
- the reference block is transformed by using the first transformation model, and the first offset value is compensated in the transformation result corresponding to each pixel to obtain a prediction block of the current block; or, the parameters in the first transformation model are compensated by using the first offset value to obtain an updated first transformation model, and then the updated first transformation model is used to transform the reference block.
- the second determining part 20 is further configured to determine that the local compensation flag of the current block is a second value when the second syntax element corresponding to the merge candidate block of the current block is predicted using the transform model list;
- the second prediction part 21 is further configured to adopt the first transformation model and the local compensation transformation model indicated by the local compensation flag to perform secondary transformation on the reference block in sequence to determine the prediction block of the current block.
- the encoding part 22 is further configured to encode the second syntax element according to the encoded information, wherein the encoded information includes at least one of the following:
- the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block is the size of the current block, the CIIP flag, GPM flag, MBVD flag, skip flag and TM_merge flag of the current block.
- encoding the second syntax element according to the encoded information includes:
- the first encoding condition includes at least one of the following:
- the value of the CIIP flag bit is a first value
- the value of the GPM flag is a first value
- the MBVD flag bit is a first value
- the skip flag bit is a first value
- the TM_merge flag bit is a first value
- the size of the current block is smaller than a third preset size
- the area of the current block is greater than a first preset area threshold.
- each transformation model of different transformation types corresponds to a different reference block template area
- the error value of each transformation model is an average template error value of the number of pixels in the respective reference block template.
- the encoding part 22 is further configured to determine a sixth transform model when the current block is predicted using a transform technique and a non-transform model list;
- the second prediction part 21 is further configured to determine a prediction block of the current block based on the reference block and the sixth transformation model;
- the encoding part 22 is further configured to encode the third syntax element as the first value or the second value, and encode the fifth syntax element; the fifth syntax element is used to indicate the index of the local compensation model when using the multi-mode local compensation technology.
- the local compensation flag of the current block is determined to be a first value.
- the encoding part 22 is further configured to encode the second syntax element when at least one of the sequence-level syntax elements, frame-level syntax elements, slice-level syntax elements, and the size of the current block meets the second encoding condition.
- the fourth syntax element is encoded as a third value, wherein the other transformation model is a transformation mode corresponding to other reference blocks.
- the second determining part 20 is further configured to obtain a derived local compensation model and add the local compensation model to the transformation model list.
- the second determining part 20 is further configured to determine the reference block of the current block, and perform at least one prediction based on the intra-frame block copy technology-intra-frame/inter-frame joint prediction, the intra-frame block copy technology-geometric partition mode and the intra-frame block copy technology-reconstruction value reordering to obtain a reference prediction block of the reference block;
- the reference block is updated using the reference prediction block.
- the second determining part 20 is further configured to recalculate update parameters of the multi-mode local compensation model based on the current block template and the reference block template when the first transformation model is a local compensation model using a multi-mode local compensation technology;
- the first transformation model is updated.
- the encoding part 22 is further configured to determine a first context model from at least one context model according to encoding information of adjacent blocks;
- the second syntax element is encoded by adopting an equal probability encoding method.
- the encoding part 22 is further configured to include at least one of the following:
- the index information of the first transformation model in the transformation model list is encoded as a fourth syntax element by partially adopting the encoding method of the second context model and partially adopting the equal probability encoding method.
- the relationship between the first context model for encoding the second syntax element information includes: the same or different.
- the relationship between the second context model for encoding the fourth syntax element information includes: the same or different.
- index information of a reference block is determined, and the index information of the reference block is encoded as a sixth syntax element, where the sixth syntax element is used to indicate the index information of the reference block.
- the second determining part 20 is further configured to obtain a second syntax element of the reference block after determining the reference block based on the reference block vector;
- a first transformation model of the current block is determined.
- the second determining part 20 is further configured to use the reference transformation model as the first transformation model.
- the second determining part 20 is further configured to determine a first transformation model type of the reference transformation model
- the first transform model consistent with the first transform type is re-derived according to the reference block template and the current block template.
- the second determining part 20 is further configured to obtain a flip reference block flag of the merge candidate block
- a first transformation model of the current block is determined based on a reference transformation model corresponding to the merged candidate block.
- the second determining part 20 is further configured to determine the prediction block of the current block based on the reference block when the second syntax element of the current block is a first value, or when the second syntax element of the merge candidate block of the current block is a first value;
- a fifth transform model of the current block is constructed in the template area or within the block for use in a subsequent encoding process.
- the second determining part 20 is further configured to determine the reconstructed pixel value of the current block based on the prediction block of the current block after determining the prediction block of the current block based on the reference block and the first transformation model;
- the seventh transformation model is adopted to update the transformation model list.
- the second determining part 20 is further configured to obtain pixel values of a first reconstructed region adjacent to the current coding block and pixel values of a second reconstructed region adjacent to the reference block when the first transformation model is a local compensation model;
- the reference block is transformed using the third transformation model to obtain a prediction block of the current block.
- the prediction type of the block corresponding to the second transformation model, the third transformation model and the fourth transformation model included in the transformation model list is any one of intra-frame template matching prediction and intra-frame block copy technology.
- the second determining part 20 is further configured to update the historical transformation model list based on the first transformation model.
- the encoding part 22 is further configured to encode the first syntax element as a first value when it is determined that the prediction mode of the current block is predicted using a non-intra block copy technology.
- each functional unit of the encoder also executes the encoding method described in any one of the aforementioned embodiments.
- the integrated unit is implemented in the form of a software function module and is not sold or used as an independent product, it can be stored in a computer-readable storage medium.
- this embodiment provides a computer-readable storage medium, which is applied to the encoder 190, and the computer-readable storage medium stores a computer program. When the computer program is executed by the second processor, the encoding method described in any one of the above embodiments is implemented.
- the encoder 190 may include: a second communication interface 2001, a second memory 2002 and a second processor 2003; each component is coupled together through a second bus system 2004. It can be understood that the second bus system 2004 is used to achieve connection and communication between these components.
- the second bus system 2004 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, various buses are marked as the second bus system 2004 in Figure 16. Among them,
- the second communication interface 2001 is used for receiving and sending signals during the process of sending and receiving information with other external network elements;
- the second memory 2002 is used to store a computer program that can be run on the second processor 2003;
- the second processor 2003 is configured to execute the encoding method when running the computer program.
- the second processor 2003 is further configured to execute the encoding method described in any one of the aforementioned embodiments when running the computer program.
- This embodiment provides an encoder, for which the encoder can select a first transformation model from a transformation model list including at least two types of transformation models; the selected first transformation model is used to transform the reference block, and then the prediction block is determined. Therefore, in the process of encoding implementation, the first transformation model used to implement the transformation can be selected and determined from the transformation model list, which can ensure the diversity of selection, thereby making the possibility in the prediction process higher, improving the diversity of prediction, and ultimately improving the encoding performance.
- the embodiment of the present application provides a coding and decoding method, a bit stream, an encoder, a decoder and a storage medium.
- the decoder or the encoder can select a first transformation model from a transformation model list including at least two types of transformation models; the selected first transformation model is used to transform the reference block, and then the prediction block is determined. Therefore, in the process of coding and decoding implementation, the first transformation model used to implement the transformation can be selected and determined from the transformation model list, which can ensure the diversity of selection, thereby making the possibility in the prediction process higher, improving the diversity of prediction, and ultimately improving the coding and decoding performance.
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
PredC=c0C+c1N+c2S+c3E+c4W+c5B (2)
SADi=(SADi==0)?1:SADi (3)
Wi=(SUM-SADi)/((n-1)*SUM) (5)
Pred=(wIntra*pred_intra+wInter*pred_inter+4)>>3 (8)
Pred=α·ref+β (9)
Pred(x,y)=α·ref(x,y)+β (11)
Pred(x,y)=c0C+c1N+c2S+c3E+c4W+c5B (2)
a0i=(X-W*i-1,Y+H*(i+1)-1),1<=i<=7 (13)
a1i=(X+W*(i+1)-1,Y-H*i-1),1<=i<=7 (14)
a4i=(X-W*i-1,Y-H*i-1),1<=i<=7 (17)
a5i=(X-1,Y+H*(i+1)-1),2<=i<=7 (18)
a6i=(X+W*(i+1)-1,Y-1),2<=i<=7 (19)
b0i=(X-W*i-1,Y+offsetY),1<=i<=7 (24)
b1i=(X+offsetX,Y-H*i-1),1<=i<=7 (25)
totalDiff=∑(Rec-Pred) (28)
offset=totalDiff/N (29)
Pred(x,y)=α·ref(x,y)+β+offset (30)
Claims (99)
- 一种解码方法,应用于解码器,所述方法包括:获取当前块的相关语法元素;其中,所述相关语法元素用于指示当前块是否使用基于帧内块复制技术结合变换模型列表进行预测;确定当前块使用所述帧内块复制技术得到的参考块;根据所述相关语法元素,确定基于构建的变换模型列表得到的第一变换模型;所述构建的变换模型列表包括至少两种类型的变换模型;基于所述参考块和所述第一变换模型,确定当前块的预测块。
- 根据权利要求1所述的方法,其中,所述相关语法元素至少包括:第二语法元素;其中,所述第二语法元素用于指示当前块是否使用变换模型列表进行预测。所述相关语法元素还包括:第一语法元素;所述第一语法元素用于指示当前块使用帧内块复制技术的预测模式。
- 根据权利要求2所述的方法,其中,所述获取当前块的相关语法元素,包括:解码所述第一语法元素;根据所述第一语法元素,确定当前块使用帧内块复制技术的预测模式,并解码所述第二语法元素。
- 根据权利要求3所述的方法,其中,所述根据所述第一语法元素,确定当前块使用帧内块复制技术的预测模式,并解码所述第二语法元素,包括:在所述第一语法元素的取值为第一值时,确定当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式,并解码第三语法元素,所述第三语法元素用于指示是否使用变换技术进行预测;所述第三语法元素属于所述相关语法元素;在所述第三语法元素的取值为第二值时,解码所述第二语法元素;或,在所述第三语法元素的取值为第一值时,解码所述第二语法元素。或者,在所述第一语法元素的取值为第一值时,确定当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式,并解码第二语法元素;在所述第二语法元素的取值为第一值时,解码第三语法元素。
- 根据权利要求3所述的方法,其中,所述根据所述第一语法元素,确定当前块使用帧内块复制技术的预测模式,并解码所述第二语法元素,包括:在所述第一语法元素的取值为第二值时,确定当前块使用帧内块复制技术的预测模式为合并模式,并解码所述第二语法元素。
- 根据权利要求3至5任一项所述的方法,其中,所述根据所述相关语法元素,确定基于构建的变换模型列表得到的第一变换模型,包括:在所述第二语法元素的取值为第二值时,表征当前块使用变换模型列表进行预测,解码第四语法元素,确定变换模型的索引信息,并跳过当前块从合并候选块继承局部补偿标志位的过程;所述第四语法元素用于指示变换模型在所述变换模型列表中的模型索引;所述相关语法元素信息还包括:所述第四语法元素;基于所述变换模型的索引信息,在构建的所述变换模型列表中,确定所述第一变换模型。
- 根据权利要求2至6任一项所述的方法,其中,所述方法还包括:在所述第二语法元素的取值为第二值时,构建所述变换模型列表。
- 根据权利要求7所述的方法,其中,所述构建所述变换模型列表,包括:依次将不同的至少一种变换模型,添加至初始变换模型列表中,得到所述变换模型列表;所述至少一种变换模型包括以下至少一种:当前块的至少一个相邻位置的像素对应的第二变换模型;当前块的至少一个非相邻位置的像素对应的第三变换模型;历史解码过程中使用的第四变换模型;时域的可用变换模型;所述预设变换模型。
- 根据权利要求8所述的方法,其中,所述预设变换模型包括:预设模型参数对应的模型或对第二变换模型、第三变换模型和第四变换模型、预设模型参数对应的模型和时域的可用变换模型中的至少一种进行偏移得到的模型。
- 根据权利要求8或9所述的方法,其中,所述方法还包括:针对当前块的任一相邻位置的像素或者当前块的任一非相邻位置的像素,若该像素满足变换条件,则获取当前块的该相邻位置的第二变换模型,或者,获取当前块的任一非相邻位置的像素对应的第三变换模型;其中,所述变换条件包括以下至少一种:该像素所在块使用帧内块复制技术、变换模型标志位为有效和该像素所在块的大小满足第一预设尺寸。
- 根据权利要求8或9所述的方法,其中,不同的至少一种变换模型包括以下至少一种:至少一种变换模型的变换类型不同、存在不同的模型参数,同一变换类型下使用不同模板区域。
- 根据权利要求8至11任一项所述的方法,其中,所述依次将不同的至少一种变换模型,添加至初始变换模型列表中,得到所述变换模型列表,包括:依次将不同的至少一种变换模型,添加至初始变换模型列表中,得到中间变换模型列表;对所述中间变换模型列表进行重排序,得到所述变换模型列表。
- 根据权利要求12所述的方法,其中,所述对所述中间变换模型列表进行重排序,得到所述变换模型列表,包括:遍历所述中间变换模型列表中的各个变换模型,确定所述各个变换模型的偏移值;采用所述各个变换模型,分别对参考块模板进行预测,确定各个变换模型各自的参考块模板预测;确定每个变换模型的参考块模板预测和当前块模板之间的误差值;基于每个变换模型的误差值,以及其对应的偏移值,确定所述各个变换模型的模板误差值;根据各个变换模型的模板误差值,对所述各个变换模型进行重排序,得到所述变换模型列表。
- 根据权利要求13所述的方法,其中,所述各个变换模型的模板误差值由小到大,对应所述变换模型列表的索引信息由小到大。
- 根据权利要求13或14所述的方法,其中,所述方法还包括:在参考块模板不可用时,确定所述误差值为最大值。
- 根据权利要求8至15任一项所述的方法,其中,所述方法还包括:获取当前块所在的第一位置信息和当前块的当前尺寸;基于所述第一位置信息和所述当前尺寸,确定当前块的至少一个相邻位置和当前块的至少一个非相邻位置。
- 根据权利要求8至16任一项所述的方法,其中,所述方法还包括:获取将解码过程中的使用的历史变换模型;在所述历史变换模型与历史变换模型列表中存在相同模型时,则将所述历史变换模型列表中的相同模型移除,将所述历史变换模型添加至所述历史变换模型列表的第一顺序位;在所述历史变换模型与历史变换模型列表中不存在相同模型时,则将所述历史变换模型添加至所述历史变换模型列表的第一顺序位。
- 根据权利要求17所述的方法,其中,所述将所述历史变换模型添加至所述历史变换模型列表的第一顺序位,包括:在所述历史变换模型列表满足第一预设列表长度时,将所述历史变换模型列表中的最后顺序位的变换模型移除后,将所述历史变换模型添加至所述历史变换模型列表的第一顺序位。
- 根据权利要求17或18所述的方法,其中,所述第四变换模型是按照所述历史变换模型的由第一顺序位至最后顺序位的顺序,从所述历史变换模型中依次确定的。
- 根据权利要求17至19任一项所述的方法,其中,所述方法还包括:待添加的所述历史变换模型对应的块的尺寸在满足第二预设尺寸的情况下,基于所述历史变换模型更新所述历史变换模型列表。
- 根据权利要求1至20任一项所述的方法,其中,所述基于所述参考块和所述第一变换模型,确定当前块的预测块,包括:采用所述第一变换模型,对当前块的参考块模板进行预测,确定参考块模板的像素的预测值;确定各个像素的预测值和当前块模板的像素之间的总误差值;基于总误差值,对各个像素进行平均,得到第一偏移值;采用所述第一变换模型对所述参考块进行变换,并在每个像素对应的变换结果补偿所述第一偏移值,得到所述当前块的预测块;或者,采用所述第一偏移值对所述第一变换模型中的参数进行补偿,得到更新的第一变换模型,再采用所述更新后的第一变换模型对所述参考块进行变换。
- 根据权利要求3、5或6所述的方法,其中,所述方法还包括:在所述当前块的合并候选块对应的第二语法元素使用变换模型列表进行预测时,确定当前块的局部补偿标志位为第二值;所述基于所述参考块和所述第一变换模型,确定当前块的预测块,包括:采用所述第一变换模型和所述局部补偿标志位指示的局部补偿的变换模型,依次对所述参考块进行二次变换,确定所述当前块的预测块;或者,根据当前块模板和参考块模板推岛的局部补偿的变换模型,对参考块进行变换,确定所述当前块的预测块。
- 根据权利要求3、5或6所述的方法,其中,所述解码所述第二语法元素,包括:根据已解码信息,解码所述第二语法元素,其中,所述已解码信息包括以下至少一种:当前块的尺寸、当前块的CIIP标志位、GPM标志位、MBVD标志位、skip标志位和TM_merge标志位。
- 根据权利要求23所述的方法,其中,所述根据已解码信息,解码所述第二语法元素,包括:在所述已解码信息满足第一解码条件时,解码所述第二语法元素;所述第一解码条件包括以下至少一个:所述CIIP标志位的取值为第一值;所述GPM标志位的取值为为第一值;所述MBVD标志位为第一值;所述skip标志位为第一值;所述TM_merge标志位为第一值;所述当前块的尺寸小于第三预设尺寸;所述当前块的面积大于第一预设面积阈值。
- 根据权利要求13至15任一项所述的方法,其中,不同变换类型的各个变换模型,对应不同的参考块模板区域;各个变换模型所述误差值为各自的参考块模板中的像素数的平均的模板误差值。
- 根据权利要求4所述的方法,其中,所述在所述第三语法元素的取值为第一值,解码所述第二语法元素之后,所述方法还包括:在所述第三语法元素的取值为第二值时,解码第五语法元素;所述第五语法元素用于指示在使用多模式局部补偿技术时的局部补偿模型的索引;基于所述第五语法元素,确定第六变换模型;基于所述参考块和所述第六变换模型,确定当前块的预测块。
- 根据权利要求3、5或6所述的方法,其中,所述方法还包括:在所述当前块的合并候选块对应的第二语法元素使用变换模型列表进行预测时,确定当前块的局部补偿标志位为第一值。
- 根据权利要求3至5任一项所述的方法,其中,所述解码所述第二语法元素,包括:在序列级的语法元素、帧级的语法元素、片级语法元素、当前块的尺寸中的至少一个满足第二解码条件时,解码所述第二语法元素。
- 根据权利要求4所述的方法,其中,所述在所述第三语法元素的取值为第二值,解码所述第二语法元素之后,所述方法还包括:在所述第三语法元素的取值为第一值时,解码第五语法元素;所述第五语法元素用于指示在使用多模式局部补偿技术时的局部补偿模型的索引;基于所述第五语法元素,确定第六变换模型;基于所述参考块和所述第六变换模型,确定当前块的预测块。
- 根据权利要求6所述的方法,其中,所述基于所述变换模型的索引信息,在构建的所述变换模型列表中,确定所述第一变换模型,包括:若变换模型的所述第四语法元素为第三值,则在所述变换模型列表指示至少一个其他变换模型,其中,其他变换模型为其他参考块对应的变换方式。
- 根据权利要求7或8所述的方法,其中,所述构建所述变换模型列表,包括:获取推导出的局部补偿模型,将所述局部补偿模型添加至所述变换模型列表。
- 根据权利要求1所述的方法,其中,所述方法还包括:确定对当前块的参考块,进行基于帧内块复制技术-帧内/帧间联合预测、帧内块复制技术-几何划分模式和帧内块复制技术-重建值重排序中的至少一种预测,得到参考块的参考预测块;采用所述参考预测块对所述参考块进行更新。
- 根据权利要求1所述的方法,其中,所述方法还包括:所述第一变换模型为使用多模式局部补偿技术时的局部补偿模型时,基于当前块模板和参考块模板重新计算多模式局部补偿模型的更新参数;基于所述更新参数,更新所述第一变换模型。
- 根据权利要求3至7任一项所述的方法,其中,所述解码所述第二语法元素,包括:根据相邻块的解码信息,从至少一个上下文模型中,确定第一上下文模型;基于所述第一上下文模型,解码所述第二语法元素;或者,采用等概率解码方式,解码所述第二语法元素。
- 根据权利要求6所述的方法,其中,所述解码第四语法元素,确定变换模型的索引信息,包括以下至少一种:采用等概率解码方式,解码所述第四语法元素,确定变换模型的所述索引信息;采用第二上下文模型的解码方式,解码所述第四语法元素,确定变换模型的所述索引信息;部分采用第二上下文模型的解码方式,结合部分采用等概率解码方式,解码所述第四语法元素,确定变换模型的所述索引信息。
- 根据权利要求34所述的方法,其中,当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式时,解码第二语法元素信息的第一上下文模型,与当前块使用帧内块复制技术的预测模式为合并模式时,解码第二语法元素信息的第一上下文模型的关系包括:相同或不相同。
- 根据权利要求35所述的方法,其中,当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式时,解码第四语法元素信息的第二上下文模型,与当前块使用帧内块复制技术的预测模式为合并模式时,解码第四语法元素信息的第二上下文模型的关系包括:相同或不相同。
- 根据权利要求1所述的方法,其中,所述获取当前块的相关语法元素,包括:获取当前块的参考块的第六语法元素,所述第六语法元素用于指示参考块的索引信息;所述确定当前块使用所述帧内块复制技术得到的参考块,包括:基于所述第六语法元素,确定当前块使用所述帧内块复制技术得到的参考块。
- 根据权利要求38所述的方法,其中,所述确定当前块使用所述帧内块复制技术得到的参考块之后,所述方法还包括:获取当前块的合并候选块的第二语法元素;在所述合并候选块的第二语法元素的取值为第二值时,确定所述当前块的第二语法元素为第二值;基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型。
- 根据权利要求39所述的方法,其中,所述基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型,包括:将所述参考的变换模型,作为所述第一变换模型。
- 根据权利要求39所述的方法,其中,所述基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型,包括:确定所述参考的变换模型的第一变换模型类型;根据参考块模板和当前块模板,重新推导与所述第一变换类型一致的所述第一变换模型。
- 根据权利要求39所述的方法,其中,所述基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型,包括:获取合并候选块的翻转参考块标志位;在所述翻转参考块标志位的取值为第二值时,基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型。
- 根据权利要求2-42任一项所述的方法,其中,所述方法还包括:在当前块的所述第二语法元素为第一值时,或者,在当前块的合并候选块的第二语法元素为第一值时,基于所述参考块,确定所述当前块的预测块;基于当前块的预测块,确定当前块的重建像素值;基于当前块的重建像素值和参考块的重建像素值,在模板区域或在块内,构建当前块的第五变换模型,供后续解码过程使用。
- 根据权利要求2-42任一项所述的方法,其中,所述基于所述参考块和所述第一变换模型,确定当前块的预测块之后,所述方法还包括:基于当前块的预测块,确定当前块的重建像素值;基于当前块的重建像素值和参考块的重建像素值,在模板区域或在块内,构建当前块的第七变换模型;采用所述第七变换模型代替所述第一变换模型,更新变换模型列表;或者,采用所述第七变换模型和所述第一变换模型中误差值最小的变换模型,更新变换模型列表;或者,采用所述第七变换模型,更新变换模型列表。
- 根据权利要求1所述的方法,其中,所述方法还包括:当第一变换模型为局部补偿模型时,获取当前编码块相邻的第一已重建区域像素值和参考块相邻的第二已重建区域像素值;基于所述第一已重建区域像素值和所述第二已重建区域像素值,推导所述局部补偿模型的第一参数,并由第一参数确定其第二参数;采用局部补偿模型的原始第一参数,和所述第二参数,确定第三变换模型;采用所述第三变换模型对所述参考块进行变换,得到所述当前块的预测块。
- 根据权利要求8至11任一项所述的方法,其中,所述变换模型列表中包含的第二变换模型、第三变换模型和第四变换模型对应的块的预测类型为帧内模板匹配预测和帧内块复制技术中的任意一种。
- 根据权利要求1至44任一项所述的方法,其中,所述方法还包括:基于所述第一变换模型更新历史变换模型列表。
- 一种编码方法,应用于编码器,所述方法包括:确定当前块的候选块向量列表;基于所述候选块向量列表,确定参考块向量;基于所述参考块向量,确定参考块;在确定当前块的预测模式为帧内块复制技术结合变换模型列表进行预测时,从构建的变换模型列表得到的第一变换模型;所述构建的变换模型列表包括至少两种类型的变换模型;基于所述参考块和所述第一变换模型,确定当前块的预测块;编码当前块的相关语法元素,将所得到的编码比特写入码流;其中,所述相关语法元素用于指示当前块是否使用基于帧内块复制技术结合变换模型列表进行预测。
- 根据权利要求48所述的方法,其中,所述相关语法元素至少包括:第二语法元素;其中,所述第二语法元素用于指示当前块是否使用变换模型列表进行预测;所述相关语法元素还包括:第一语法元素,所述第一语法元素用于指示当前块使用帧内块复制技术的预测模式。
- 根据权利要求49所述的方法,其中,所述帧内块复制技术的预测模式包括:合并模式和优化的运动矢量预测模式;所述方法还包括:当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式时,编码所述第一语法元素的取值为第一值,以及编码第三语法元素;所述第三语法元素用于指示是否使用变换技术进行预测;所述第三语法元素属于所述相关语法元素;编码所述第三语法元素的取值为第二值时,编码所述第二语法元素;或,编码所述第三语法元素的取值为第一值,编码所述第二语法元素;或者,编码所述第一语法元素的取值为第一值时,编码第二语法元素;编码所述第二语法元素的取值为第一值时,编码所述第三语法元素。
- 根据权利要求49所述的方法,其中,所述方法还包括:当前块使用帧内块复制技术的预测模式为合并模式时,编码所述第一语法元素的取值为第二值,以及编码第二语法元素。
- 根据权利要求49至51任一项所述的方法,其中,所述方法还包括:在当前块使用变换模型列表进行预测时,编码所述第二语法元素为第二值,并将所述第一变换模型在所述变换模型列表中的索引信息,编码为第四语法元素;所述第四语法元素用于指示变换模型在所述变换模型列表中的模型索引;所述相关语法元素信息还包括:所述第四语法元素。
- 根据权利要求49至52任一项所述的方法,其中,所述方法还包括:在当前块使用变换模型列表进行预测时,构建所述变换模型列表。
- 根据权利要求49至53任一项所述的方法,其中,所述构建所述变换模型列表,包括:依次将不同的至少一种变换模型,添加至初始变换模型列表中,得到所述变换模型列表;所述至少一种变换模型包括以下至少一种:当前块的至少一个相邻位置的像素对应的第二变换模型;当前块的至少一个非相邻位置的像素对应的第三变换模型;历史编码过程中使用的第四变换模型;时域的可用变换模型;所述预设变换模型。
- 根据权利要求54所述的方法,其中,所述预设变换模型包括:预设模型参数对应的模型或对第二变换模型、第三变换模型和第四变换模型、预设模型参数对应的模型和时域的可用变换模型中的至少一种进行偏移得到的模型。
- 根据权利要求54或55所述的方法,其中,所述方法还包括:针对当前块的任一相邻位置的像素或者当前块的任一非相邻位置的像素,若该像素满足变换条件,则获取当前块的该相邻位置的第二变换模型,或者,获取当前块的任一非相邻位置的像素对应的第三变换模型;其中,所述变换条件包括以下至少一种:该像素所在块使用帧内块复制技术、变换模型标志位为有效和该像素所在块的大小满足第一预设尺寸。
- 根据权利要求54或55所述的方法,其中,不同的至少一种变换模型包括以下至少一种:至少一种变换模型的变换类型不同、存在不同的模型参数,同一变换类型下使用不同模板区域。
- 根据权利要求54至58任一项所述的方法,其中,所述依次将不同的至少一种变换模型,添加至初始变换模型列表中,得到所述变换模型列表,包括:依次将不同的至少一种变换模型,添加至初始变换模型列表中,得到中间变换模型列表;对所述中间变换模型列表进行重排序,得到所述变换模型列表。
- 根据权利要求58所述的方法,其中,所述对所述中间变换模型列表进行重排序,得到所述变换模型列表,包括:遍历所述中间变换模型列表中的各个变换模型,确定所述各个变换模型的偏移值;采用所述各个变换模型,分别对参考块模板进行预测,确定各个变换模型各自的参考块模板预测;确定每个变换模型的参考块模板预测和当前块模板之间的误差值;基于每个变换模型的误差值,以及其对应的偏移值,确定所述各个变换模型的模板误差值;根据各个变换模型的模板误差值,对所述各个变换模型进行重排序,得到所述变换模型列表。
- 根据权利要求59所述的方法,其中,所述各个变换模型的模板误差值由小到大,对应所述变换模型列表的索引信息由小到大。
- 根据权利要求59或60所述的方法,其中,在参考块模板不可用时,确定所述误差值为最大值。
- 根据权利要求54至61任一项所述的方法,其中,所述方法还包括:获取当前块所在的第一位置信息和当前块的当前尺寸;基于所述第一位置信息和所述当前尺寸,确定当前块的至少一个相邻位置和当前块的至少一个非相邻位置。
- 根据权利要求54至62任一项所述的方法,其中,所述方法还包括:获取将编码过程中的使用的历史变换模型;在所述历史变换模型与历史变换模型列表中存在相同模型时,则将所述历史变换模型列表中的相同模型移除,将所述历史变换模型添加至所述历史变换模型列表的第一顺序位;在所述历史变换模型与历史变换模型列表中不存在相同模型时,则将所述历史变换模型添加至所述历史变换模型列表的第一顺序位。
- 根据权利要求63所述的方法,其中,所述将所述历史变换模型添加至所述历史变换模型列表的第一顺序位,包括:在所述历史变换模型列表满足第一预设列表长度时,将所述历史变换模型列表中的最后顺序位的变换模型移除后,将所述历史变换模型添加至所述历史变换模型列表的第一顺序位。
- 根据权利要求63或64所述的方法,其中,所述第四变换模型是按照所述历史变换模型的由第一顺序位至最后顺序位的顺序,从所述历史变换模型中依次确定的。
- 根据权利要求63至65任一项所述的方法,其中,所述方法还包括:待添加的所述历史变换模型对应的块的尺寸在满足第二预设尺寸的情况下,基于所述历史变换模型更新所述历史变换模型列表。
- 根据权利要求48至66任一项所述的方法,其中,所述基于所述参考块和所述第一变换模型,确定当前块的预测块,包括:采用所述第一变换模型,对当前块的参考块模板进行预测,确定参考块模板的像素的预测值;确定各个像素的预测值和当前块模板的像素之间的总误差值;基于总误差值,对各个像素进行平均,得到第一偏移值;采用所述第一变换模型对所述参考块进行变换,并在每个像素对应的变换结果补偿所述第一偏移值,得到所述当前块的预测块;或者,采用所述第一偏移值对所述第一变换模型中的参数进行补偿,得到更新的第一变换模型,再采用所述更新后的第一变换模型对所述参考块进行变换。
- 根据权利要求51所述的方法,其中,所述方法还包括:在所述当前块的合并候选块对应的第二语法元素使用变换模型列表进行预测时,确定当前块的局部补偿标志位为第二值;所述基于所述参考块和所述第一变换模型,确定当前块的预测块,包括:采用所述第一变换模型和所述局部补偿标志位指示的局部补偿的变换模型,依次对所述参考块进行二次变换,确定所述当前块的预测块,或者,;或者,根据当前块模板和参考块模板推岛的局部补偿的变换模型,对参考块进行变换,确定所述当前块的预测块。
- 根据权利要求50或51所述的方法,其中,所述编码所述第二语法元素,包括:根据已编码信息,编码所述第二语法元素,其中,所述编码信息包括以下至少一种:当前块的尺寸、当前块的CIIP标志位、GPM标志位、MBVD标志位、skip标志位和TM_merge标志位。
- 根据权利要求69所述的方法,其中,所述根据已编码信息,编码所述第二语法元素,包括:在所述已编码信息满足第一编码条件时,编码所述第二语法元素;所述第一编码条件包括以下至少一个:所述CIIP标志位的取值为第一值;所述GPM标志位的取值为为第一值;所述MBVD标志位为第一值;所述skip标志位为第一值;所述TM_merge标志位为第一值;所述当前块的尺寸小于第三预设尺寸;所述当前块的面积大于第一预设面积阈值。
- 根据权利要求59至61任一项所述的方法,其中,不同变换类型的各个变换模型,对应不同的参考块模板区域;各个变换模型所述误差值为各自的参考块模板中的像素数的平均的模板误差值。
- 根据权利要求50所述的方法,其中,所述方法还包括:在当前块使用变换技术,非变换模型列表进行预测时,确定第六变换模型;基于所述参考块和所述第六变换模型,确定当前块的预测块;编码第三语法元素为第一值或第二值,并编码第五语法元素;所述第五语法元素用于指示在使用多模式局部补偿技术时的局部补偿模型的索引。
- 根据权利要求50或51所述的方法,其中,所述方法还包括:在所述当前块的合并候选块对应的第二语法元素使用变换模型列表进行预测时,确定当前块的局部补偿标志位为第一值。
- 根据权利要求50或51所述的方法,其中,所述编码所述第二语法元素,包括:在序列级的语法元素、帧级的语法元素、片级语法元素、当前块的尺寸中的至少一个满足第二编码条件时,编码所述第二语法元素。
- 根据权利要求48所述的方法,其中,所述方法还包括:若所述第一变换模型为在所述变换模型列表指示的至少一个其他变换模型,则将第四语法元素编码为第三值,其中,其他变换模型为其他参考块对应的变换方式。
- 根据权利要求54或55所述的方法,其中,所述构建所述变换模型列表,包括:获取推导出的局部补偿模型,将所述局部补偿模型添加至所述变换模型列表。
- 根据权利要求48所述的方法,其中,所述方法还包括:确定对当前块的参考块,进行基于帧内块复制技术-帧内/帧间联合预测、帧内块复制技术-几何划分模式和帧内块复制技术-重建值重排序中的至少一种预测,得到参考块的参考预测块;采用所述参考预测块对所述参考块进行更新。
- 根据权利要求48所述的方法,其中,所述方法还包括:所述第一变换模型为使用多模式局部补偿技术时的局部补偿模型时,基于当前块模板和参考块模板重新计算多模式局部补偿模型的更新参数;基于所述更新参数,更新所述第一变换模型。
- 根据权利要求50或51所述的方法,其中,所述编码所述第二语法元素,包括:根据相邻块的编码信息,从至少一个上下文模型中,确定第一上下文模型;基于所述第一上下文模型,编码所述第二语法元素;或者,采用等概率编码方式,编码所述第二语法元素。
- 根据权利要求52所述的方法,其中,所述将所述第一变换模型在所述变换模型列表中的索引信息,编码为第四语法元素,包括以下至少一种:采用等概率编码方式,将所述第一变换模型在所述变换模型列表中的索引信息,编码为第四语法元素;采用第二上下文模型的编码方式,将所述第一变换模型在所述变换模型列表中的索引信息,编码为第四语法元素;部分采用第二上下文模型的编码方式,结合部分采用等概率编码方式,将所述第一变换模型在所述变换模型列表中的索引信息,编码为第四语法元素。
- 根据权利要求79所述的方法,其中,当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式时,编码第二语法元素信息的第一上下文模型,与当前块使用帧内块复制技术的预测模式为合并模式时,编码第二语法元素信息的第一上下文模型的关系包括:相同或不相同。
- 根据权利要求80所述的方法,其中,当前块使用帧内块复制技术的预测模式为优化的运动矢量预测模式时,编码第四语法元素信息的第二上下文模型,与当前块使用帧内块复制技术的预测模式为合并模式时,编码第四语法元素信息的第二上下文模型的关系包括:相同或不相同。
- 根据权利要求1所述的方法,其中,所述方法还包括:确定参考块的索引信息,将所述参考块的索引信息编码为第六语法元素,所述第六语法元素用于指示参考块的索引信息。
- 根据权利要求83所述的方法,其中,基于所述参考块向量,确定参考块之后,所述方法还包括:获取所述参考块的第二语法元素;在当前块的合并候选块的第二语法元素的取值为第二值时,确定所述当前块的第二语法元素为第二值;基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型。
- 根据权利要求84所述的方法,其中,所述基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型,包括:将所述参考的变换模型,作为所述第一变换模型。
- 根据权利要求84所述的方法,其中,所述基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型,包括:确定所述参考的变换模型的第一变换模型类型;根据参考块模板和当前块模板,重新推导与所述第一变换类型一致的所述第一变换模型。
- 根据权利要求84所述的方法,其中,所述基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型,包括:获取合并候选块的翻转参考块标志位;在所述翻转参考块标志位的取值为第二值时,基于所述合并候选块对应的参考的变换模型,确定当前块的第一变换模型。
- 根据权利要求49-87任一项所述的方法,其中,所述方法还包括:在当前块的所述第二语法元素为第一值时,或者,在当前块的合并候选块的第二语法元素为第一值时,基于所述参考块,确定所述当前块的预测块;基于当前块的预测块,确定当前块的重建像素值;基于当前块的重建像素值和参考块的重建像素值,在模板区域或在块内,构建当前块的第五变换模型,供后续编码过程使用。
- 根据权利要求49-87任一项所述的方法,其中,所述基于所述参考块和所述第一变换模型,确定当前块的预测块之后,所述方法还包括:基于当前块的预测块,确定当前块的重建像素值;基于当前块的重建像素值和参考块的重建像素值,在模板区域或在块内,构建当前块的第七变换模型;采用所述第七变换模型代替所述第一变换模型,更新变换模型列表;或者,采用所述第七变换模型和所述第一变换模型中误差值最小的变换模型,更新变换模型列表;或者,采用所述第七变换模型,更新变换模型列表。
- 根据权利要求48所述的方法,其中,所述方法还包括:当第一变换模型为局部补偿模型时,获取当前编码块相邻的第一已重建区域像素值和参考块相邻的第二已重建区域像素值;基于所述第一已重建区域像素值和所述第二已重建区域像素值,推导所述局部补偿模型的第一参数,并由第一参数确定其第二参数;采用局部补偿模型的原始第一参数,和所述第二参数,确定第三变换模型;采用所述第三变换模型对所述参考块进行变换,得到所述当前块的预测块。
- 根据权利要求54至57任一项所述的方法,其中,所述变换模型列表中包含的第二变换模型、第三变换模型和第四变换模型对应的块的预测类型为帧内模板匹配预测和帧内块复制技术中的任意一种。
- 根据权利要求48至88任一项所述的方法,其中,所述方法还包括:基于所述第一变换模型更新历史变换模型列表。
- 根据权利要求49所述的方法,其中,所述方法还包括:在确定当前块的预测模式为非帧内块复制技术进行预测时,编码所述第一语法元素为第一值。
- 一种码流,其中,所述码流是根据待编码信息进行比特编码生成的;其中,所述待编码信息包括下述至少一项:第一语法元素、第二语法元素、第三语法元素、第四语法元素、第五语法元素、第六语法元素、当前块的尺寸、当前块的CIIP标志位、GPM标志位、MBVD标志位、skip标志位、TM_merge标志位和上下文模型;其中,所述第一语法元素用于用于指示当前块使用帧内块复制技术的预测模式;所述第二语法元素用于指示当前块是否使用变换模型列表进行预测;所述第三语法元素用于指示是否使用变换技术进行预测;所述第四语法元素用于指示变换模型在所述变换模型列表中的模型索引;所述第五语法元素用于指示在使用多模式局部补偿技术时的局部补偿模型的索引;所述第六语法元素用于指示参考块的索引信息。
- 一种解码器,其中,包括:解码部分,被配置为获取当前块的相关语法元素;其中,所述相关语法元素用于指示当前块是否使用基于帧内块复制技术结合变换模型列表进行预测;第一确定部分,被配置为确定当前块使用所述帧内块复制技术得到的参考块;根据所述相关语法元素,确定基于构建的变换模型列表得到的第一变换模型;所述构建的变换模型列表包括至少两种类型的变换模型;第一预测部分,被配置为基于所述参考块和所述第一变换模型,确定当前块的预测块。
- 一种解码器,包括第一存储器和第一处理器;其中:所述第一存储器,用于存储能够在所述第一处理器上运行的计算机程序;所述第一处理器,用于在运行所述计算机程序时,执行如权利要求1至47中任一项所述的方法。
- 一种编码器,其中,包括:第二确定部分,被配置为确定当前块的候选块向量列表;基于所述候选块向量列表,确定参考块向量;基于所述参考块向量,确定参考块;在确定当前块的预测模式为帧内块复制技术结合变换模型列表进行预测时,从构建的变换模型列表得到的第一变换模型;所述构建的变换模型列表包括至少两种类型的变换模型;第二预测部分,被配置为基于所述参考块和所述第一变换模型,确定当前块的预测块;编码部分,被配置为编码当前块的相关语法元素,通过写入部分将所得到的编码比特写入码流;其中,所述相关语法元素用于指示当前块是否使用基于帧内块复制技术结合变换模型列表进行预测。
- 一种编码器,包括第二存储器和第二处理器;其中,所述第二存储器,用于存储能够在所述第二处理器上运行的计算机程序;所述第二处理器,用于在运行所述计算机程序时,执行如权利要求48至93中任一项所述的方法。
- 一种计算机可读存储介质,其中,所述计算机可读存储介质存储有计算机程序,所述计算机程序被第一处理器执行时实现如权利要求1至47中任一项所述的方法、或者被第二处理器执行时实现如权利要求48至93中任一项所述的方法。
Priority Applications (3)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/CN2023/105611 WO2025007263A1 (zh) | 2023-07-03 | 2023-07-03 | 编解码方法、码流、编码器、解码器以及存储介质 |
| CN202380099990.6A CN121488481A (zh) | 2023-07-03 | 2023-07-03 | 编解码方法、码流、编码器、解码器以及存储介质 |
| MX2025015516A MX2025015516A (es) | 2023-07-03 | 2025-12-18 | Metodo de codificacion, flujo de bits, codificador, decodificador y medio de almacenamiento |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| PCT/CN2023/105611 WO2025007263A1 (zh) | 2023-07-03 | 2023-07-03 | 编解码方法、码流、编码器、解码器以及存储介质 |
Related Child Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| US19/434,575 Continuation US20260129181A1 (en) | 2025-12-29 | Coding method, decoder, and storage medium |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2025007263A1 true WO2025007263A1 (zh) | 2025-01-09 |
Family
ID=94171092
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/CN2023/105611 Ceased WO2025007263A1 (zh) | 2023-07-03 | 2023-07-03 | 编解码方法、码流、编码器、解码器以及存储介质 |
Country Status (3)
| Country | Link |
|---|---|
| CN (1) | CN121488481A (zh) |
| MX (1) | MX2025015516A (zh) |
| WO (1) | WO2025007263A1 (zh) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN121691725A (zh) * | 2026-02-12 | 2026-03-17 | 深圳传音控股股份有限公司 | 处理方法、处理设备及存储介质 |
Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112135134A (zh) * | 2019-06-24 | 2020-12-25 | 腾讯美国有限责任公司 | 视频解码方法、装置、计算机设备和存储介质 |
| CN112868238A (zh) * | 2018-10-23 | 2021-05-28 | 北京字节跳动网络技术有限公司 | 局部照明补偿和帧间预测编解码之间的并置 |
| US20210360232A1 (en) * | 2019-02-01 | 2021-11-18 | Beijing Bytedance Network Technology Co., Ltd. | Harmonization between different video process mode |
| CN114402616A (zh) * | 2019-09-27 | 2022-04-26 | Oppo广东移动通信有限公司 | 当前块的预测方法及装置、设备、存储介质 |
| WO2022167322A1 (en) * | 2021-02-08 | 2022-08-11 | Interdigital Vc Holdings France, Sas | Spatial local illumination compensation |
| WO2023093863A1 (en) * | 2021-11-26 | 2023-06-01 | Mediatek Singapore Pte. Ltd. | Local illumination compensation with coded parameters |
-
2023
- 2023-07-03 WO PCT/CN2023/105611 patent/WO2025007263A1/zh not_active Ceased
- 2023-07-03 CN CN202380099990.6A patent/CN121488481A/zh active Pending
-
2025
- 2025-12-18 MX MX2025015516A patent/MX2025015516A/es unknown
Patent Citations (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN112868238A (zh) * | 2018-10-23 | 2021-05-28 | 北京字节跳动网络技术有限公司 | 局部照明补偿和帧间预测编解码之间的并置 |
| US20210360232A1 (en) * | 2019-02-01 | 2021-11-18 | Beijing Bytedance Network Technology Co., Ltd. | Harmonization between different video process mode |
| CN112135134A (zh) * | 2019-06-24 | 2020-12-25 | 腾讯美国有限责任公司 | 视频解码方法、装置、计算机设备和存储介质 |
| CN114402616A (zh) * | 2019-09-27 | 2022-04-26 | Oppo广东移动通信有限公司 | 当前块的预测方法及装置、设备、存储介质 |
| WO2022167322A1 (en) * | 2021-02-08 | 2022-08-11 | Interdigital Vc Holdings France, Sas | Spatial local illumination compensation |
| WO2023093863A1 (en) * | 2021-11-26 | 2023-06-01 | Mediatek Singapore Pte. Ltd. | Local illumination compensation with coded parameters |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN121691725A (zh) * | 2026-02-12 | 2026-03-17 | 深圳传音控股股份有限公司 | 处理方法、处理设备及存储介质 |
Also Published As
| Publication number | Publication date |
|---|---|
| CN121488481A (zh) | 2026-02-06 |
| MX2025015516A (es) | 2026-02-03 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN110933412B (zh) | 用于帧内块复制的基于历史的运动矢量预测值 | |
| TWI887420B (zh) | 幀間預測方法、編碼器、解碼器以及電腦儲存媒介 | |
| TWI888505B (zh) | 編碼方法、解碼方法、編碼器、解碼器以及儲存媒介 | |
| TWI886282B (zh) | 幀間預測方法、編碼器、解碼器以及電腦儲存媒介 | |
| WO2025007263A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2024197748A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| CN116711304A (zh) | 预测方法、编码器、解码器以及存储介质 | |
| WO2024000768A1 (zh) | 视频编、解码方法及装置、码流、解码器、编码器、存储介质 | |
| CN120548703A (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| US20260025516A1 (en) | Method for decoding, method for encoding, decoder, and storage medium | |
| WO2024197752A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2025065610A1 (zh) | 编解码方法、记录方法、编解码器以及存储介质 | |
| WO2025129626A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2025065590A1 (zh) | 编解码方法、编解码器以及存储介质 | |
| WO2025213394A1 (zh) | 编解码方法、编码器、解码器以及存储介质 | |
| WO2025138025A1 (zh) | 编解码方法、码流、解码器、编码器以及存储介质 | |
| WO2025065420A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2025213371A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| TW202429888A (zh) | 解碼方法、編碼方法、解碼器、編碼器、電子設備、儲存媒介、電腦程式產品和碼流 | |
| WO2025007272A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2024207136A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2025145426A1 (zh) | 编解码方法、编码器、解码器以及存储介质 | |
| WO2025043408A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 | |
| WO2024197744A9 (zh) | 解码方法、编码方法、解码器和编码器 | |
| WO2024229745A1 (zh) | 编解码方法、码流、编码器、解码器以及存储介质 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 23943997 Country of ref document: EP Kind code of ref document: A1 |
|
| WWE | Wipo information: entry into national phase |
Ref document number: MX/A/2025/015516 Country of ref document: MX |
|
| WWE | Wipo information: entry into national phase |
Ref document number: 202617008414 Country of ref document: IN |
|
| WWE | Wipo information: entry into national phase |
Ref document number: 2023943997 Country of ref document: EP |
|
| WWP | Wipo information: published in national office |
Ref document number: MX/A/2025/015516 Country of ref document: MX |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| ENP | Entry into the national phase |
Ref document number: 2023943997 Country of ref document: EP Effective date: 20260203 |
|
| WWP | Wipo information: published in national office |
Ref document number: 202617008414 Country of ref document: IN |