Coding method, decoding method, code stream, coder, decoder and storage medium

AE202602304AUndeterminedGUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
AE202602304
Authority / Receiving Office
AE · AE
Patent Type
Applications
Current Assignee / Owner
Filing Date
2024-01-10

Smart Images

  • Figure ABST_ABST
    Figure ABST_ABST
Patent Text Reader

Abstract

  Disclosed in the present application are a coding method, a decoding method, a code stream, a coder, a decoder and a storage medium. The decoding method comprises: determining a prediction mode of the current block; when the prediction mode of the current block meets a first condition, determining a first candidate list of the current block, wherein the first candidate list indicates at least two candidate transformation kernel groups; according to the first candidate list, determining a transformation kernel of the current block; and determining a transformation coefficient of the current block and, on the basis of the transformation kernel, performing inverse transformation on the transformation coefficient of the current block, so as to determine a residual block of the current block. Thus, compression efficiency can be improved, thereby improving coding and decoding performance.Figure 26
Need to check novelty before this filing date? Find Prior Art

Description

Full specificationCODING METHOD, DECODING METHOD, CODE STREAM, CODER, DECODER AND STORAGE MEDIUM TECHNICAL FIELD[ %3] Embodiments of the present disclosure relate to the technical field of video encoding and decoding, and particularly relate to an encoding and decoding method, a bitstream, an encoder, a decoder, and a storage medium. BACKGROUND[ %3] With the improvement of people's requirements for video display quality, high-resolution videos such as high-definition and ultra-high-definition videos have emerged. However, high-resolution videos typically contain more information and therefore require more bandwidth. To reduce bandwidth requirements, video coding standards involving video compression have been introduced.[ %3] In video coding standards, each intra prediction mode corresponds to a transform kernel set, so a block can derive a texture feature index for determining the transform kernel set. However, for more complex intra prediction modes, these intra prediction modes can perform weighted calculation on the prediction values of two or more intra prediction modes. For such a block that requires weighting of the prediction values of two or more intra prediction modes, the current transform process is not comprehensive, resulting in low compression efficiency. SUMMARY[ %3] Embodiments of the present disclosure provide a method for encoding, a method for decoding, a bitstream, an encoder, a decoder, and a storage medium, which can improve compression efficiency, thereby enhancing encoding and decoding performance.[ %3] Technical solutions of the present disclosure may be implemented as follows.[ %3] According to a first aspect, an embodiment of the present disclosure provides a method for decoding, which is applied to a decoder, and includes the following operations.[ %3] A prediction mode of a current block is determined.[ %3] A first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] A transform kernel of the current block is determined according to the first candidate list.[ %3] Transform coefficients of the current block are determined, and inverse transform is performed on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] According to a second aspect, an embodiment of the present disclosure provides a method for encoding, which is applied to an encoder, and includes the following operations.[ %3] A prediction mode of a current block is determined.[ %3] A first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] A transform kernel of the current block is determined according to the first candidate list.[ %3] A residual block of the current block is determined, and the residual block of the current block is transformed according to the transform kernel to determine transform coefficients of the current block.[ %3] The transform coefficients of the current block are encoded, and obtained encoded bits are signalled in a bitstream.[ %3] According to a third aspect, an embodiment of the present disclosure provides a bitstream, which is generated by bit encoding according to to-be-encoded information, where the to-be-encoded information includes at least one of: quantization coefficients of a current block, a transform kernel index number of the current block, a feature index number of the current block, a prediction mode of the current block, or a value of a first syntax element, where the first syntax element indicates whether the current block uses a first transform mode and a transform kernel index number used for the first transform mode.[ %3] According to a fourth aspect, an embodiment of the present disclosure provides an encoder, which includes a first determination unit, a first transform unit, and an encoding unit.[ %3] The first determination unit is configured to: determine a prediction mode of a current block; and determine a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] The first determination unit is further configured to determine a transform kernel of the current block according to the first candidate list.[ %3] The first transform unit is configured to determine a residual block of the current block, and transform the residual block of the current block according to the transform kernel to determine transform coefficients of the current block.[ %3] The encoding unit is configured to encode the transform coefficients of the current block, and signal the obtained encoded bits in the bitstream.[ %3] According to a fifth aspect, an embodiment of the present disclosure provides an encoder, which includes a first memory and a first processor.[ %3] The first memory is configured to store a computer program executable on the first processor.[ %3] The first processor is configured to perform the method as described in the second aspect when it executes the computer program.[ %3] According to a sixth aspect, an embodiment of the present disclosure provides a decoder, which includes a second determination unit and a second transform unit.[ %3] The second determination unit is configured to: determine a prediction mode of a current block; and determine a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] The second determination unit is further configured to determine a transform kernel of the current block according to the first candidate list.[ %3] The second transform unit is configured to determine transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block.[ %3] According to a seventh aspect, an embodiment of the present disclosure provides an decoder, which includes a second memory and a second processor.[ %3] The second memory is configured to store a computer program executable on second first processor.[ %3] The second processor is configured to perform the method as described in the first aspect when it executes the computer program.[ %3] According to an eighth aspect, an embodiment of the present disclosure provides a computer-readable storage medium storing a computer program that, when executed by at least one processor, implements the method according to the first aspect or the method according to the second aspect.[ %3] The embodiment of the present disclosure provides a method for encoding, a method for decoding, a bitstream, an encoder, a decoder, and a storage medium, at the coding end, a prediction mode of a current block is determined; a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; a transform kernel of the current block is determined according to the first candidate list; and a residual block of the current block is determined, and the residual block of the current block is transformed according to the transform kernel to determine transform coefficients of the current block; and the transform coefficients of the current block are encoded, and obtained encoded bits are signalled in a bitstream. At the coding end, a prediction mode of a current block is determined; a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; a transform kernel of the current block is determined according to the first candidate list; and transform coefficients of the current block are determined, and inverse transform is performed on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block. In this way, both the encoding end and the decoding end first determine the prediction mode of the current block, and when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance. BRIEF DESCRIPTION OF THE DRAWINGS[ %3] FIG. 1 is a schematic flowchart of a hybrid coding framework.[ %3] FIG. 2 is a schematic diagram of template matching of a current block.[ %3] FIG. 3 is a schematic diagram of a reference sample of a current block.[ %3] FIG. 4 is a schematic diagram of multiple reference lines of a current block.[ %3] FIG. 5 is a first schematic diagram of multiple prediction modes corresponding intra prediction.[ %3] FIG. 6 is a second schematic diagram of multiple prediction modes corresponding intra prediction.[ %3] FIG. 7 is a third schematic diagram of multiple prediction modes corresponding intra prediction.[ %3] FIG. 8 is a fourth schematic diagram of multiple prediction modes corresponding intra prediction.[ %3] FIG. 9 is a schematic diagram of screen content encoding.[ %3] FIG. 10 is a schematic diagram of a prediction process of a Matrix-based Intra Prediction (MIP) mode.[ %3] FIG. 11 is a schematic diagram of a template and a template reference area of a current block.[ %3] FIG. 12 is a schematic bar diagram of a gradient and intra prediction mode.[ %3] FIG. 13 is a schematic diagram of a weighted merge of three intra prediction modes.[ %3] FIG. 14 is a schematic diagram of a search range of a Intra Template Matching Prediction (ITMP) mode.[ %3] FIG. 15 is a schematic diagram of multiple mode weights in a GPM mode.[ %3] FIG. 16 is a schematic diagram of DCT transform.[ %3] FIG. 17 is a schematic diagram of a base picture of a DCT transform.[ %3] FIG. 18 is a schematic flowchart without LFNST transform.[ %3] FIG. 19 is a schematic flowchart with LFNST transform.[ %3] FIG. 20 is a detailed schematic flowchart with LFNST transform.[ %3] FIG. 21 is a schematic diagram of a base picture of multiple transform kernel sets.[ %3] FIG. 22 is a schematic diagram of a base picture of NSPT transform.[ %3] FIG. 23 is a schematic diagram of network architecture of video encoding and decoding according to an embodiment of the present disclosure.[ %3] FIG. 24 is a schematic block diagram of a system composition of an encoder according to an embodiment of the present disclosure.[ %3] FIG. 25 is a schematic block diagram of a system composition of a decoder according to an embodiment of the present disclosure.[ %3] FIG. 26 is a first schematic flowchart of a method for decoding according to an embodiment of the present disclosure.[ %3] FIG. 27 is a second schematic flowchart of a method for decoding according to an embodiment of the present disclosure.[ %3] FIG. 28 is a third schematic flowchart of a method for decoding according to an embodiment of the present disclosure.[ %3] FIG. 29 is a fourth schematic flowchart of a method for decoding according to an embodiment of the present disclosure.[ %3] FIG. 30 is a fifth schematic flowchart of a method for decoding according to an embodiment of the present disclosure.[ %3] FIG. 31 is a first schematic flowchart of a method for encoding according to an embodiment of the present disclosure.[ %3] FIG. 32 is a second schematic flowchart of a method for encoding according to an embodiment of the present disclosure.[ %3] FIG. 33 is a schematic structural diagram of an encoder according to an embodiment of the present disclosure.[ %3] FIG. 34 is a schematic diagram of a hardware structure of an encoder according to an embodiment of the present disclosure.[ %3] FIG. 35 is a schematic structural diagram of a decoder according to an embodiment of the present disclosure.[ %3] FIG. 36 is a schematic diagram of a hardware structure of a decoder according to an embodiment of the present disclosure.[ %3] FIG. 37 is a schematic structural diagram of an encoding and decoding system according to an embodiment of the present disclosure. DETAILED DESCRIPTION[ %3] In order to understand characteristics and technical contents of the embodiments of the disclosure more thoroughly, implementations of the embodiments of the disclosure will be described in detail below with reference to the drawings. The drawings are only for the purpose of reference and explanation, and are not intended to limit the embodiments of the disclosure.[ %3] Unless otherwise defined, all technical and scientific terms used here have the same meanings as those usually understood by technicians in the technical field to which the disclosure belongs. The terms used here are only for the purpose of describing the embodiments of the disclosure, and are not intended to limit the disclosure.[ %3] In the following descriptions, reference is made to "some embodiments" which describe a subset of all possible embodiments; however, it may be understood that "some embodiments" may be the same or different subsets of all possible embodiments, and may be combined with each other without conflict.[ %3] It should also be pointed out that terms "first\second\third" involved in the embodiments of the disclosure are only intended to distinguish similar objects and do not represent a specific sequence of the objects. It may be understood that "first\second\third" may be interchanged in a specific order or sequence if allowable, such that the embodiments of the disclosure described here may be implemented in an order besides that illustrated or described here.[ %3] It may be understood that in a video picture, a Coding Block (CB) is usually characterized by using a first colour component, a second colour component, and a third colour component. The three colour components are a luma component, a blue chroma component, and a red chroma component respectively. Specifically, the luma component is usually represented by a symbol Y, the blue chroma component is usually represented by a symbol Cb or U, and the red chroma component is usually represented by a symbol Cr or V; in this way, the video picture may be represented in a YCbCr format or a YUV format.[ %3] Nouns and terms involved in the embodiments of the disclosure are described first before further describing the embodiments of the disclosure in detail. The nouns and terms involved in the embodiments of the disclosure are applicable to the following explanations:[ %3] H.265 / High Efficiency Video Coding (HEVC);[ %3] H.266 / Versatile Video Coding (VVC);[ %3] VVC Test Model (VTM), a reference software testing platform for VVC;[ %3] Enhanced Compression Model (ECM), a platform for improving compression performance beyond VVC;[ %3] Joint Video Experts Team (JVET);[ %3] Coding Unit (CU);[ %3] Coding Tree Unit (CTU);[ %3] Largest Coding Unit (LCU);[ %3] Motion Vector (MV);[ %3] Prediction Unit (PU);[ %3] Transform Unit (TU);[ %3] Merge;[ %3] Skip;[ %3] Quantization Parameter (QP);[ %3] Merge with Motion Vector Difference (MMVD);[ %3] Motion Vector Prediction (MVP);[ %3] Temporal Motion Vector Prediction (TMVP);[ %3] Subblock-based Temporal Motion Vector Prediction (SbTMVP);[ %3] Discrete Cosine Transform (DCT);[ %3] Discrete Sine Transform (DST);[ %3] Multiple Transform Selection (MTS);[ %3] Low Frequency Non-Separable Transform (LFNST);[ %3] Non-Separable Primary Transform (NSPT);[ %3] Context-based Adaptive Binary Arithmetic Coding (CABAC).[ %3] At present, general video encoding and decoding standards adopt a block-based hybrid coding framework. Each picture or sub-picture or frame in a video is partitioned into largest coding units or coding tree units of squares of the same size (such as 256 × 256, 128 × 128, 64 × 64, etc.). Each largest coding unit or coding tree unit may be partitioned into rectangular coding units according to rules. The coding unit may be further partitioned into prediction units, transform units, and the like. The hybrid coding framework includes a Prediction module, a Transform module, a Quantization module, an Entropy Coding module, an Inverse Quantization (Inv.quantization) module, an Inverse Transform (Inv.transform) module, a In Loop Filter module and other modules. The prediction module may include Intra Prediction and Inter Prediction, and the Inter Prediction may include Motion Estimation and Motion Compensation. Because there is a strong correlation between neighbouring samples one picture of the video, the spatial redundancy between the neighbouring samples can be eliminated by using the intra prediction method in video encoding and decoding technologies. In addition, due to the strong similarity between neighbouring pictures in the video, the temporal redundancy between the neighbouring pictures is eliminated by using the inter prediction method in video encoding and decoding technologies, so that the coding efficiency can be improved.[ %3] The basic flow of the video codec is as follows: at the encoding end, a picture is partitioned into blocks, intra prediction or inter prediction is performed on the current block to generate a prediction block of the current block, the prediction block is subtracted from the original block of the current block to obtain a residual block, the residual block is transformed and quantized to obtain a quantization coefficient matrix, and the quantization coefficient matrix is entropy encoded and output to a bitstream. At the decoding end, intra prediction or inter prediction is performed on the current block to generate a prediction block of the current block, on the other hand, a bitstream is parsed to obtain a quantization coefficient matrix, the quantization coefficient matrix is inversely quantized and inversely transformed to obtain a residual block, and the prediction block and the residual block are added to obtain a reconstructed block. The reconstructed block constitutes a reconstructed picture, and picture-based or block-based in loop filtering is performed on the reconstructed picture to obtain a decoded picture. The encoding end also needs similar operations as the decoding end to obtain the decoded picture. The decoded picture may be used as a reference picture for inter prediction for subsequent pictures. Block partitioning information, as well as mode information or parameter information such as prediction information, transform information, quantization information, entropy coding information, in-loop filtering information, etc. determined by the encoding end need to be output to the bitstream if necessary. The decoding end, by parsing the bitstream and analyzing existing information, determines the same block partition information, as well as mode information or parameter information such as prediction information, transform information, quantization information, entropy coding information, in-loop filtering information, etc. as those at the encoding end, so as to ensure that the decoded picture obtained by the encoding end is the same as the decoded picture obtained by the decoding end. The decoded picture obtained by the encoding end is usually referred to as the reconstructed picture. The current block may be partitioned into prediction units during predicting, the current block may be partitioned into transform units during transforming, and the partitioning of the prediction unit and the transform unit may be different. The above is the basic flow of the video codec under the block-based hybrid coding framework. With the development of the technology, some modules or steps of the framework or the flow may be optimized. The embodiments of the present disclosure are applicable to, but are not limited to, the basic flow of the video codec under the block-based hybrid coding framework.[ %3] In addition, in the embodiments of the present disclosure, the Current Block (CB) may be a current coding unit, a current prediction unit, a current transform unit, or the like. Due to the needs of parallel processing, a picture can be partitioned into slices, etc. The slices in the same picture can be processed in parallel, that is to say, there is no data dependence between them. The term "frame" is a common expression, generally understood as one frame being one picture. The frame described in the embodiments of the present disclosure may also be replaced with a picture, a slice, or the like.[ %3] The following provides a detailed introduction to related solutions for prediction technologies.[ %3] (1) Inter prediction.[ %3] The method of Template Matching (TM) was first used in inter prediction, and it uses the correlation between neighbouring samples to use some areas around the current block as templates. When the current block is encoded / decoded, the left and top sides of the current block have already been encoded / decoded according to the coding order. Certainly, when the existing hardware decoder is implemented, it may not be guaranteed that when the current block starts decoding, the left and top sides of the current block have already been decoded. Here, we are talking about inter blocks. For example, in HEVC, the inter-coded block does not require the surrounding reconstructed samples when generating a prediction block, so the prediction process of the inter block can be performed in parallel. However, an intra-coded block must require the reconstructed samples on the left and top sides as reference samples. Theoretically, the left and top sides are available, which means that corresponding adjustments to the hardware design can be achieved. Relatively speaking, the right and bottom sides are not available under the coding order of current standards such as VVC.[ %3] As shown in FIG. 2, the rectangular areas on the left side and the top side of the current block are set as templates, and the height of the template portion on the left side is generally the same as the height of the current block, and the width of the template portion on the top side is generally the same as the width of the current block, but it is needless to say, they may be different. The best matching position of the template is sought in the reference picture to determine the motion information or motion vector of the current block. This process can be roughly described as starting from a starting position in a certain reference picture (Ref0) and searching within a certain surrounding range. Search rules can be predefined, such as search range and step size, etc. For each moved position, the matching degree between the template corresponding to the position and the template around the current block is calculated. The so-called matching degree can be measured by some distortion costs, such as the Sum of Absolute Differences (SAD), the Sum of Absolute Transformed Differences (SATD), Mean-Square Error (MSE), etc. Generally, the transform used for SATD is Hadamard transform, and smaller SAD, SATD, MSE values indicate higher matching degree. The cost is calculated with the prediction block of the template corresponding to the position and the reconstructed block of the template around the current block. In addition to the search for the integer sample position, the search for the fractional sample position may be performed, and the motion information of the current block may be determined according to the searched position with the highest matching degree. With the correlation between neighbouring samples, the motion information appropriate for the template may also be the motion information appropriate for the current block. Certainly, the template matching method may not be applicable to all blocks, so some methods can be used to determine whether the current block uses the above template matching method, such as using a control switch to indicate whether the template matching method is used in the current block. One name for this template matching method is Decoder side Motion Vector Derivation (DMVD). Both the encoder and the decoder can use the template to search to derive motion information or find better motion information on the basis of the original motion information. It does not need to transport specific motion vectors or motion vector differences, but both the encoder and the decoder search under the same rule to ensure the consistency of encoding and decoding. The template matching method can improve the compression performance, but it needs to "search" on the decoder side, which brings a certain degree of complexity on the decoder side.[ %3] (2) Intra prediction.[ %3] It can be understood that there is a strong spatial correlation between neighbouring parts or neighbouring samples in a picture. Intra prediction is a prediction method that uses the spatial correlation between the encoded / decoded samples around the current block and the samples inside the current block. Exemplarily, as shown in FIG. 3, 4 × 4 white-filled samples are the current block, and grid-filled samples on the left column and the top row of the current block are reference samples of the current block, and intra prediction uses these reference samples to predict the current block. These reference samples may already be all available, i.e., all have been encoded / decoded. There may also be some parts that are not available, for example, if the current block is the leftmost side of the entire frame, then the reference sample on the left side of the current block is not available. Or when encoding / decoding the current block, the bottom-left part of the current block has not been encoded / decoded, so the reference sample at the bottom-left is not available. In the case where the reference sample is not available, the reference sample or certain values or certain methods that are available may be used for padding, or no padding may be applied.[ %3] The Multiple reference line (MRL) intra prediction method can use more reference samples to improve coding efficiency. As shown in FIG. 4, here is a schematic diagram using four reference rows / columns.[ %3] There are multiple prediction modes for intra prediction, and as shown in FIG. 5, there are nine modes for intra prediction of 4 × 4 blocks in H.264. Where mode 0 (vertical mode) copies the samples above the current block to the current block in the vertical direction as the prediction value, mode 1 (horizontal mode) copies the left reference sample to the current block in the horizontal direction as the prediction value, mode 2 (DC mode) copies the average value of eight points A to D and I to L as the prediction value of all points, and modes 3 to 8 copy reference samples to the corresponding position of the current block according to a certain angle respectively. Since some positions in the current block may not exactly correspond to reference samples, it may be necessary to use a weighted average of the reference sample, or fractional samples of the interpolated reference sample.[ %3] In addition, there are PLANE, PLANAR and other modes, and with the development of technology and the expansion of blocks, there are more and more angular prediction modes. For example, the intra prediction modes used by HEVC include PLANAR, DC and 33 angle modes, a total of 35 prediction modes, as shown in FIG. 6 for details. The intra modes used by VVC include PLANAR, DC and 65 angle modes, a total of 67 prediction modes, as shown in FIG. 7 for details. Certainly, in addition to the above 67 modes, VVC also provides wide-angle modes for some rectangular blocks with large differences in length and width. For example, the modes indicated by the dotted lines in FIG. 8 are -14 ~-1 and 67 ~ 80. They will replace some conventional modes, as shown in FIG. 8 for details.[ %3] It is also understood that Intra Block Copy (IBC) can significantly improve the compression efficiency of Screen Content Coding (SCC), and thus IBC is used for SCC from HEVC to VVC. Screen content is different from camera captured content. It is generated by a computer. The screen content has no noise, contains text, computer graphics, etc., and has clear boundaries. There is a lot of repetitive content in the screen content, as shown in FIG. 9.[ %3] In the embodiment of the present disclosure, it can be considered that IBC applies the inter prediction method to intra prediction. Where the inter prediction uses a reference block on a reference picture to generate a prediction block of the current block, the reference picture is not the current picture. IBC finds reference blocks from already encoded / decoded parts (or reconstructed parts) of the current picture to generate the prediction block of the current block. IBC may also be referred to as intra picture block compensation or Current Picture Referencing (CPR).[ %3] The IBC can use a block vector (BV) to represent the position difference between the current block and the reference block, which is similar to the inter prediction MV. The encoder determines the best matching block of the current block through the block matching method within the search range, and encodes the BV. There are many methods for encoding the BV, for example, the merge mode can be used, which is similar to inter prediction, and will not be repeated here.[ %3] IBC can be regarded as an intra prediction method, or it can be regarded as another kind of prediction method independent of intra prediction and inter prediction. IBC is highly efficient for screen content coding and also improves compression efficiency for natural sequences captured by cameras.[ %3] It is also understood that this is a special intra prediction mode for Matrix-based Intra Prediction (MIP), which may also be referred to as Matrix weighted Intra Prediction in some places.[ %3] As shown in FIG. 10, in order to predict a block with a width W and a height H, the MIP requires H reconstructed samples in the left column of the current block and W reconstructed samples in the top row of the current block as inputs. The MIP generates the prediction block in three operations: (a) reference sample Averaging, (b) Matrix Vector Multiplication, and (c) Interpolation. The core of MIP is considered here to be matrix multiplication. It can be considered as a process of generating the prediction block with input samples (reference samples) in a matrix multiplication manner. MIP provides a variety of matrices, and the difference of prediction modes is reflected in the difference of matrices. The same input sample will get different results using different matrices. The process of reference sample averaging and interpolation is a compromise between performance and complexity. For larger blocks, an approximate downsampling effect can be achieved by reference sample averaging, so that the input can be adapted to a smaller matrix, while interpolation achieves an upsampling effect. In this way, it is not necessary to provide a matrix of MIP for each block size, but only one or several matrices of specific sizes. With the increasing demand for compression performance and the improvement of hardware capability, more complex MIP may appear in the next generation of standards.[ %3] MIP is somewhat similar to PLANAR, but obviously MIP is more complex and more flexible than PLANAR.[ %3] It will also be understood that for Template-based Intra Mode Derivation (TIMD), as shown in FIG. 11, for the current block, an area on its left and top sides is used as a template. Except for the boundary case, when encoding and decoding the current block, the reconstructed values can theoretically be obtained on the left and top sides of the current block. This is also the basis for numerous template adaptation methods. TIMD takes the slash-filled area as shown in FIG. 11 as a template, and the Reference of the template in FIG. 11 is the reference samples (grid-filled area) of the template. The decoder may use a certain intra prediction mode to predict on the template, and compare the prediction value with the reconstructed value to obtain the cost of the intra prediction mode on the template. For example, SAD, SATD, SSE, etc. Since the template and the current block are adjacent, they have correlation, the performance of a prediction mode on the template can be used to estimate its performance on the current block. TIMD predicts some candidate intra prediction modes on the template, gets their costs on the template, and selects one or two intra prediction modes with the lowest cost as the intra prediction value of the current block.[ %3] Studies have found that if the costs of two intra prediction modes on the template are close, weighted averaging of the prediction values of the two modes can improve compression performance. The weights of the prediction values of the two prediction modes are related to the above costs. In the current version, this weight is inversely proportional to the cost.[ %3] In summary, TIMD uses the prediction effect of the intra prediction mode on the template to filter the intra prediction mode, and can weight two intra prediction modes according to the costs on the template. The advantage of TIMD is that if the current block selects the TIMD mode, it does not need to indicate which intra prediction mode is used, but is derived by the decoder itself through the above process, which saves overhead to a certain extent.[ %3] It is also understood that for Decoder-side Intra Mode Derivation (DIMD), the DIMD derives a prediction mode using the reconstructed samples on the left and top sides of the current block, but instead of predicting on the template, it analyzes the gradient of the reconstructed samples.[ %3] As shown in FIG. 12, DIMD analyzes the gradients of black points, such as horizontal gradients and vertical gradients, adapts an intra prediction mode according to its gradients, and analyzes all the points to be checked to obtain a result similar to the following histogram. That is, the statistics of the number of points matched by each intra prediction mode. Certainly, the so-called histogram is only to help understand, and the specific implementation can be implemented in many simple forms. The current DIMD selects the two highest intra prediction modes in the histogram, plus the PLANAR mode, and weights the prediction values of the three intra prediction modes. The weights are related to the analysis results. Exemplarily, as illustrated in FIG. 13, the three intra prediction modes include an M1 mode, an M2 mode, and a PLANAR mode. The prediction values obtained by the three intra prediction modes are respectively set to , , , and the weight values of the three intra prediction modes are respectively set to , , , and the specific calculation formulas are as follows:[ %3] (1)[ %3] (2)[ %3] (3)[ %3] The final prediction block may be as follows:[ %3] (4)[ %3] In summary, DIMD uses gradient analysis of reconstructed samples to screen intra prediction modes, and two intra prediction modes plus planar can be weighted according to the analysis results. The advantage of DIMD is that if the current block selects the DIMD mode, it does not need to indicate which intra prediction mode is used, but is derived by the decoder itself through the above process, which saves overhead to a certain extent.[ %3] It can also be understood that the method of Template Matching (TM) was first used in inter prediction, and it uses the correlation between neighbouring samples to use some areas around the current block as templates. When the current block is encoded / decoded, the left and top sides of the current block have already been encoded / decoded according to the coding order. Certainly, when the existing hardware decoder is implemented, it may not be guaranteed that when the current block starts decoding, the left and top sides of the current block have already been decoded. Here, we are talking about inter blocks. For example, in HEVC, the inter-coded block does not require the surrounding reconstructed samples when generating a prediction block, so the prediction process of the inter block can be performed in parallel. However, an intra-coded block must require the reconstructed samples on the left and top sides as reference samples. Theoretically, the left and top sides are available, which means that corresponding adjustments to the hardware design can be achieved. Relatively speaking, the right and bottom sides are not available under the coding order of current standards such as VVC.[ %3] As shown in the aforementioned FIG. 2, the rectangular areas on the left side and the top side of the current block are set as templates, and the height of the template portion on the left side is generally the same as the height of the current block, and the width of the template portion on the top side is generally the same as the width of the current block, but it is needless to say, they may be different. The best matching position of the template is sought in the reference picture to determine the motion information or motion vector of the current block. This process can be roughly described as starting from a starting position in a certain reference picture (Ref0) and searching within a certain surrounding range. Search rules can be predefined, such as search range and step size, etc. Every time you move to a position, the matching degree of the template corresponding to the position and the template around the current block is calculated. The so-called matching degree can be measured by some distortion cost, such as SAD, SATD (for which the Hadamard transform is generally used), MSE, etc. The smaller the value of SAD, SATD, MSE, etc., the higher the matching degree. The cost is calculated with the prediction block of the template corresponding to the position and the reconstructed block of the template around the current block. In addition to the search for the integer sample position, the search for the fractional sample position may be performed, and the motion information of the current block may be determined according to the searched position with the highest matching degree. With the correlation between neighbouring samples, the motion information appropriate for the template may also be the motion information appropriate for the current block. Certainly, the template matching method may not be applicable to all blocks, so some methods can be used to determine whether the current block uses the above template matching method, such as using a control switch to indicate whether the template matching method is used in the current block. A classic template matching technique is called Decoder side Motion Vector Derivation (DMVD). Both the encoder and the decoder can use the template to search to derive motion information or find better motion information on the basis of the original motion information. It does not need to transmit specific motion vectors or motion vector differences, but both the encoder and the decoder search under the same rule to ensure the consistency of encoding and decoding. The template matching method can improve the compression performance, but it needs to "search" in the decoder, which brings a certain degree of complexity on the decoder.[ %3] It will also be appreciated that for Intra Template Matching Prediction (ITMP), ITMP can be considered as a technique combining IBC and TM. It has been mentioned above that the application of TM to the inter can reduce the overhead of encoding the MV, and similarly, the use of TM on the IBC can reduce the overhead of encoding the BV. One example is to directly take the matching block found by the TM as the prediction block of the ITMP mode of the current block without encoding the BV.[ %3] An example of ITMP is shown in FIG. 14. An inverted L-shaped area in the top-left corner of the current block is used as a template, and searching is performed within a dot-filled search range, and the search range is a reconstructed area. The dot-filled area shown in FIG. 14 includes the current CTU of R1, the CTU of the top-left side of R2, the CTU of the top side of R3, and the CTU of the left side of R4. This is an example, and the search range is different in practical application. This example finds the best matching block in R2.[ %3] It will also be understood that for Spatial Geometric Partitioning Mode (SGPM), in the VVC video encoding and decoding standard, there is an inter prediction mode called the Geometric Partitioning Mode (GPM). In the AVS3 video encoding and decoding standard, there is an inter prediction mode called the Angular Weighted Prediction (AWP). Although these two modes have different names and specific implementation forms, they share common principles.[ %3] Conventional unidirectional prediction only finds one reference block with the same size as the current block, while the conventional bidirectional prediction uses two reference blocks with the same size as the current block, and the sample value of each point of the prediction block is the average value of the corresponding positions of the two reference blocks, that is, all points of each reference block account for 50%. The bidirectional weighted prediction allows the proportions of two reference blocks to be different. For example, all points in the first reference block may account for 75% and all points in the second reference block may account for 25%. But all points in the same reference block have the same proportion. Some other optimization methods such as Decoder side Motion Vector Refinement (DMVR) and Bi-directional Optical Flow (BIO) may cause some changes in the reference sample or the prediction sample, but they are independent of the principle described above. BIO may also be abbreviated as BDOF. GPM or AWP also uses two reference blocks of the same size as the current block, but some sample positions use the sample values of the corresponding positions of the first reference block 100%, some sample positions use the sample values of the corresponding positions of the second reference block 100%, while in the boundary area or blending area, the sample values of the corresponding positions of these two reference blocks are used according to a certain proportion. The weight of the boundary area is also gradually transitioned. How these weights are assigned is determined by the mode of GPM or AWP. The weight of each sample position is determined according to the mode of GPM or AWP. Certainly, in some cases, such as when the block size is very small, some GPM or AWP modes may not guarantee that some sample positions will 100% use the sample value of the position corresponding to the first reference block, and some sample positions will 100% use the sample value of the position corresponding to the second reference block. It may also be considered that GPM or AWP uses two reference blocks that are different in size from the current block, that is, each takes a desired part as the reference block. That is, a part with a weight other than 0 is taken as a reference block, and a part with a weight of 0 is removed.[ %3] As shown in FIG. 15, it is a diagram of the weights of 64 modes of GPM on square blocks in VVC. Black indicates that the weight value of the position corresponding to the first reference block is 0%, white indicates that the weight value of the position corresponding to the first reference block is 100%, and gray area indicates that the weight value of the position corresponding to the first reference block is a certain weight value greater than 0% and less than 100% according to different colour depths. The weight value of the position corresponding to the second reference block is 100% minus the weight value of the position corresponding to the first reference block.[ %3] The weight derivation methods of GPM and AWP are different. The GPM determines the angle and offset according to each mode, and then calculates the weight matrix for each mode. AWP first makes one-dimensional weighted lines, and then spreads one-dimensional weighted lines across the entire matrix using a method similar to intra angular prediction.[ %3] It should be noted that in the previous encoding and decoding standard, only a rectangular partition mode exists, whether it is a partition of CU, PU, or TU. However, GPM and AWP achieve the predicted non-rectangular partition effect without partitioning. GPM and AWP use masks of the weights of two reference blocks, namely the weight map or weight matrix described above. This mask determines the weights of the two reference blocks when the prediction block is generated, or it can be understood simply that part of the position of the prediction block comes from the first reference block and part of the position comes from the second reference block, and the blending area is weighted with the corresponding positions of the two reference blocks, thereby making the transition smoother. GPM and AWP do not partition the current block into two CUs or PUs according to the partition line. Thus, after prediction, operations such as transform, quantization, inverse transform, and inverse quantization on the residual are performed on the current block as a whole.[ %3] It should also be noted that GPM is an inter technique in VVC, but it can also use intra prediction. The two prediction modes of GPM may both be inter prediction modes, one may be inter prediction mode and the other may be intra prediction mode, or both may be intra prediction modes.[ %3] The SGPM mode in ECM uses this weight mask or weight matrix in intra prediction. It uses the weight matrix to combine the prediction values of two intra prediction modes into the prediction values of SGPM, so that more complex textures can be produced than a single prediction mode.[ %3] Since one “partitioning" mode and two intra prediction modes are to be used, the general logic is that syntax elements indicating these three modes, namely partition_mode_idx, intra_pred_mode0_idx, and intra_pred_mode1_idx as shown in Table 1, are signalled in the bitstream, respectively, as in Table 1. However, in order to reduce the overhead of these information, SGPM uses the templates around the current block to sort the combinations of three modes to obtain a candidate list of combined modes, and only the candidate index of SGPM needs to be signalled in the bitstream. At the decoding end, SGPM can construct the candidate list of combined modes, and derive one "partitioning" mode and two intra prediction modes (partition_mode_idx, intra_pred_mode0_idx, and intra_pred_mode1_idx) according to the candidate index of SGPM, such as sgpm_cand_idx in Table 2.Table 1If( cu_sgpm_flag ){partition_mode_idxintra_pred_mode0_idxintra_pred_mode1_idx} Table 2If( cu_sgpm_flag ){sgpm_cand_idx} [ %3] Here, for sgpm_cand_idx, .[ %3] Further, the transform technology will be described below.[ %3] During coding, the current general hybrid coding framework performs prediction first. Prediction exploits spatial or temporal correlation to obtain a picture identical or similar to the current block. For a block, it is possible for the prediction block to be exactly the same as the current block, but it is difficult to guarantee this for all blocks in a video, especially for natural or camera-captured videos. It is difficult to completely predict the irregular motion, distortion, occlusion, brightness and other changes in the video. Therefore, the hybrid coding framework will subtract the predicted picture from the original picture of the current block to obtain the residual picture, or subtract the prediction block from the current block to obtain the residual block. The residual block is usually much simpler than the original picture, so prediction can significantly improve the compression efficiency. The residual block is also not directly encoded, but usually transformed first. Transform is to transform the residual picture from the spatial domain to the frequency domain, and remove the correlation of the residual picture. After the residual picture is transformed into the frequency domain, because the energy is mostly concentrated in the low frequency area, the transformed non-zero coefficients are mostly concentrated in the top-left corner. Quantization is then used for further compression. Moreover, since the human eye is insensitive to high frequencies, larger quantization step sizes can be used in high frequency areas.[ %3] FIG. 16 is a schematic diagram of DCT transform. As shown in FIG. 16, only the top-left corner area of the original picture has non-zero coefficients after DCT transform. Certainly, this example performs DCT transform on the entire picture. In video encoding and decoding, the picture is partitioned into blocks for processing, so the transform is also block-based.[ %3] Transform is very useful in common video compression, but not all blocks have to be transformed. In some cases, not transforming yields better compression effect. Therefore, in some standards such as VVC, the encoder can choose whether to use transform for the current block. Where a DCT2 type (DCT-II) is the most commonly used transform in video compression standards, and its transformed base picture is shown in FIG. 17.[ %3] In addition, a DCT8 type (DCT-VIII) and a DST7 type (DST-VII) can also be used in VVC. The basic formulas of these transforms are shown in Table 3, where the basic transform formulas of DCT2, DCT8, and DST7 for N point inputs are shown.Table 3Transform TypeBasis function Ti(j), i, j= 0, 1,…, N−1DCT-II where,DCT-VIII DST-VII  [ %3] Since the pictures are all two-dimensional, and the calculation amount and memory overhead of directly performing two-dimensional transform are unacceptable to the hardware conditions at that time, the above-mentioned DCT2, DCT8, and DST7 transforms used in the standard are split into two steps of one-dimensional transforms in horizontal and vertical directions. For example, the horizontal direction transform is performed first and then the vertical direction transform is performed, or the vertical direction transform is performed first and then the horizontal direction transform is performed.[ %3] (1) Multiple Transform Selection (MTS).[ %3] VVC supports transform kernels such as DCT2, DCT8, DST7, etc. The transform kernels such as DCT2, DCT8, DST7 used in VVC are horizontally and numerically separable transform kernels, which can be applied separately to transform in horizontal or vertical directions. For a block, the encoder can select an appropriate transform kernel and transmit the index to the bitstream. The decoder determines the transform kernel of the inverse transform according to the index. Different transform kernels can be selected for the horizontal direction and the vertical direction, such as DCT8 for the horizontal direction and DST7 for the vertical direction. This technique is generally referred to as MTS.[ %3] VVC uses a syntax element mts_idx to determine the transform kernel of the primary transform. As shown in Table 4 below, where trTypeHor represents a transform kernel of horizontal transform, trTypeVer represents a transform kernel of vertical transform, 0 of trTypeHor and trTypeVer represents a DCT2-type transform, 1 represents a DST7-type transform, and 2 represents a DCT8-type transform. If mts_idx does not exist, the value of mts_idx is inferred to be 0.Table 4mts_idx01234trTypeHor01212trTypeVer01122 [ %3] (2) Low frequency non-separable transform (LFNST).[ %3] The above transform method is more effective for horizontal and vertical textures, but the effect on oblique textures will be worse. Indeed, horizontal and vertical textures are the most common, so the above transform methods are very useful to improve compression efficiency. As the demand for compression efficiency continues to increase, if the oblique texture can be processed more effectively, the compression efficiency can be further improved.[ %3] To handle the residuals of oblique textures more efficiently, the LFNST transform is used in VVC. The above transforms such as DCT2, DCT8, and DST7 are referred to as primary transforms. At the encoding end of VVC, LFNST is used after DCT2 transform and before quantization. At the decoding end of VVC, LFNST is used after inverse quantization and before DCT2 inverse transform. Because it is transformed on the basis of DCT2 (primary transform), LFNST is a secondary transform. FIG. 18 is a schematic flowchart of encoding and decoding without LFNST (secondary transform), and FIG. 19 is a schematic flowchart ofencoding and decoding with LFNST (secondary transform). Certainly, the encoder can directly inverse quantize the stored quantization coefficients without entropy decoding, because entropy coding is lossless.[ %3] FIG. 20 is a detailed schematic flowchart of encoding and decoding with LFNST (secondary transform). At the encoding end, the LFNST performs a secondary transform on the low frequency coefficients in the top-left corner after the primary transform. The primary transform concentrates energy to the top-left corner by decorrelating the picture. The secondary transform decorrelates the low frequency coefficients of the primary transform, and the result is intuitively shown in FIG. 20. At the encoding end, 16 coefficients are input to the 4×4 LFNST, and the output is 8 coefficients; 48 coefficients are input to the 8×8 LFNST, 8 coefficients are output for the 8×8 block, and 16 coefficients are output for the other blocks. At the decoding end, 8 coefficients are input to the 4×4 inverse LFNST, and the output is 16 coefficients; 8 coefficients are input to the 8×8 block, 16 coefficients are input to the other blocks, and input the coefficients to the 8×8 inverse LFNST, the output is 48 coefficients.[ %3] FIG. 21 shows some base pictures of LFNST in VVC. Only the two base pictures of the lowest frequency of each transform kernel in each transform kernel set are shown in FIG. 21. Some obvious oblique textures can be observed. LFNST not only has transform kernels optimized for some oblique textures, but also has transform kernels optimized for flat gradient textures, such as transform kernel set 0 of LFNST in VVC.[ %3] LFNST is applied only to intra-encoded blocks. Angular prediction tiles the reference samples to the current block according to the specified angle as the prediction value, which means that the prediction block will have obvious directional texture, and the residual error of the current block after angular prediction will also show obvious angular characteristics statistically. Therefore, the transform kernel selected by LFNST can be bound to the intra prediction mode, that is, after the intra prediction mode is determined, LFNST can only use a set of transform kernels corresponding to the intra prediction mode.[ %3] Specifically, LFNST in VVC has a total of 4 sets of transform kernels, and 2 transform kernels can be selected for each set. Table 5 shows the correspondence between the intra prediction mode and the transform kernel set. Note that the cross-component prediction modes used in chroma intra prediction are 81 to 83, but luma intra prediction does not have these modes. The transform kernels of the LFNST can be transposed to let one transform kernel set handle more angles correspondingly. Exemplarily, modes 13 to 23 and 45 to 55 all correspond to transform kernel set 2, but 13 to 23 are clearly close to the horizontal mode and 45 to 55 are clearly close to the vertical mode.Table 5IntraPredModeTr. set indexIntraPredMode < 010 <= IntraPredMode <= 102 <= IntraPredMode <= 12113 <= IntraPredMode <= 23224 <= IntraPredMode <= 44345 <= IntraPredMode <= 55256 <= IntraPredMode<= 80181 <= IntraPredMode<= 830 [ %3] The LFNST of the VVC has a total of four sets of transform kernels, and which set is used for the LFNST is specified according to the intra prediction mode. This takes advantage of the correlation between the intra prediction mode and the transform kernel of the LFNST, thereby reducing the transmission of the transform kernel selecting the LFNST in the bitstream. Whether the current block will use LFNST, and if LFNST is used, whether to use the first or second in a set needs to be determined by the bitstream and some conditions.[ %3] In the subsequent evolution of ECM technology, LFNST is further expanded. LFNST has more transform kernel sets (35 sets in ECM). The correspondence between the transform kernel set index (LFNST set index) and the intra prediction mode (Intra pred. mode) is shown in Table 6. Each transform kernel set is more efficient for the texture of the corresponding angle. Here, 3 transform kernels can be selected for each transform kernel set.Table 6 [ %3] (3) Non-separable primary transform (NSPT).[ %3] LFNST is a horizontal and vertical non-separable transform, and DCT2 can be referred to as a primary transform because there is a secondary transform. In this way, it can be said that it is a compromise between performance and complexity to go through DCT2 first and then LFNST, because directly performing inseparable primary transform is more efficient, but it has higher complexity, for example, the amount of calculation and the storage space of the transform kernel are higher.[ %3] In ECM10, some small blocks can use NSPT, while large blocks still use DCT2+LFNST. For example, the sizes of small blocks include 4 × 4, 4 × 8, 8 × 4, 8 × 8, 4 × 16, 16 × 4, 8 × 16, 16 × 8, 8 × 32, 32 × 8. In the ECM 10, the NSPT also matches the transform kernel set according to the intra prediction mode. The matching method can refer to the method of LFNST, and each transform kernel set has three transform kernels to select. As an example, an 8 × 8 base picture of the NSPT in the ECM 10 is shown in FIG. 22, which corresponds to the inter angular prediction mode 7, and it can be seen that it is better to process the texture of the corresponding angle. It should be noted that NSPT is only applied to intra-coded blocks.[ %3] In summary, it can be seen that both NSPT and LFNST are transforms that process textures of various angles. They may have multiple transform kernels, and one transform kernel may be specially optimized for a specific angle texture. In addition to angular textures, NSPT and LFNST also include transform kernels that handle gradient textures. In fact, these transform kernels can also be said to be trained Karhunen-Loeve Transform (KLT). It can also be summarized that both NSPT and LFNST have multiple transform kernels, and each transform kernel is designed for a specific texture, which includes angular texture, gradient texture, etc. Certainly, the gradient texture can be further expanded such as horizontal gradient texture, vertical gradient texture, oblique gradient texture, etc. They have multiple transform kernel sets, and each intra prediction mode may correspond to one transform kernel set. Each intra prediction mode actually also represents a texture feature. Therefore, the intra prediction mode index is also a texture feature index.[ %3] In VVC and the current ECM, a block (CU or TU) can only derive one texture feature index for deriving the LFNST / NSPT transform kernel set, thereby deriving a unique LFNST / NSPT transform kernel set. This texture feature can be said to be a link using LFNST / NSPT. For blocks using ordinary intra prediction modes, i.e., DC, PLANAR, and various angular modes, this texture feature index is the intra prediction mode used by the current block. But for special intra prediction modes such as DIMD, TIMD, MIP, SGPM, ITMP, and IBC, it is not so straightforward. Here, both DIMD and TIMD can weight the prediction values of two or more intra prediction modes, SGPM weights the prediction values of two intra prediction modes with a weight matrix, MIP predicts according to a matrix operation, ITMP and IBC predict based on copying a reconstructed block, and they are not simple texture features like ordinary intra prediction modes. For example, a block weighted with the prediction values of two or more intra prediction modes indicates that its texture may contain two or more texture features, and its residual after prediction may exhibit the texture features of the first prediction mode or the texture features of the second prediction mode. It can be seen that for such a block that requires weighting of the prediction values of two or more intra prediction modes, the current transform process is not comprehensive, resulting in low compression efficiency.[ %3] Based on this, an embodiment of the present disclosure provides an encoding method for determining a prediction mode of a current block; determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; determining a transform kernel of the current block according to the first candidate list; and determining a residual block of the current block, and transforming the residual block of the current block according to the transform kernel to determine transform coefficients of the current block; and encoding the transform coefficients of the current block, and signalling obtained encoded bits in a bitstream. The embodiment of the present disclosure also provides a decoding method for determining a prediction mode of a current block; determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; determining a transform kernel of the current block according to the first candidate list; and determining transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] In this way, both the encoding end and the decoding end first determine the prediction mode of the current block, and when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance.[ %3] Hereinafter, the embodiments of the present disclosure will be described in detail with reference to the drawings.[ %3] FIG. 23 is a schematic diagram of network architecture of video encoding and decoding according to an embodiment of the present disclosure. As shown in FIG. 23, the network architecture includes one or more electronic devices 13 to 1N and a communication network 01, here the electronic devices 13 to 1N may perform video interaction through the communication network 01. The electronic devices may be various types of devices with video encoding and decoding functions during implementation, for example, the electronic devices may include a 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, or the like, which is not limited in the embodiments of the disclosure.[ %3] In an embodiment of the present disclosure, a network architecture of a video encoding and decoding system including a decoding method and an encoding method is provided herein. Where the decoder or encoder in the embodiment of the present disclosure may be the electronic device described above. That is, the electronic device in the embodiment of the present disclosure has a video encoding and decoding function, and generally includes a video encoder (that is, an encoder) and a video decoder (that is, a decoder).[ %3] FIG. 24 is a schematic block diagram of a system composition of an encoder according to an embodiment of the present disclosure. As shown in FIG. 24, the encoder 100 may include a partitioning unit 101, a prediction unit 102, a first adder 107, a transform unit 108, a quantization unit 109, an inverse quantization unit 110, an inverse transform unit 111, a second adder 112, a filtering unit 113, a Decoded Picture Buffer (DPB) unit 114, and an entropy coding unit 115. Here, the input of the encoder 100 may be a video composed of a series of pictures or one still picture, and the output of the encoder 100 may be a bit stream (which may also be referred to as a "bitstream") for representing a compressed version of the input video.[ %3] Here, the partitioning unit 101 partitions the pictures in the input video into one or more Coding Tree Units (CTUs). The partitioning unit 101 partitions a picture into multiple tiles, and may further partition a tile into one or more bricks, where one or more complete and / or partial CTUs may be included in a tile or a brick. In addition, the partitioning unit 101 may form one or more slices, and one slice may include one or more tiles arranged in a raster order in a picture, or cover one or more tiles of the rectangular area in the picture. The partitioning unit 101 may also form one or more sub-pictures, where one sub-picture may include one or more slices, tiles, or bricks.[ %3] In the encoding process of the encoder 100, the partitioning unit 101 transmits the CTU to the prediction unit 102. Generally, the prediction unit 102 may be composed of a block partitioning unit 103, a Motion Estimation (ME) unit 104, a Motion Compensation (MC) unit 105, and an intra prediction unit 106. Specifically, the block partitioning unit 103 further partitions the input CTU into smaller Coding Units (CUs) iteratively using quadtree partitioning, binary tree partitioning, and ternary tree partitioning. The prediction unit 102 may acquire an inter prediction block of the CU using the ME unit 104 and the MC unit 105. The intra prediction unit 106 may acquire the intra prediction block of the CU using various intra prediction modes including the MIP mode. In an example, a motion estimation manner of rate distortion optimization may be invoked by the ME unit 104 and the MC unit 105 to obtain an inter prediction block, and a mode determination manner of rate distortion optimization may be invoked by the intra prediction unit 106 to obtain an intra prediction block. The prediction unit 102 outputs the prediction block of the CU, and the first adder 107 calculates the difference between the CU and the prediction block of the CU in the output of the partitioning unit 101, that is, the residual CU. The transform unit 108 reads the residual CU and performs one or more transform operations on the residual CU to acquire coefficients. The quantization unit 109 quantizes the coefficients and outputs quantization coefficients (i.e., levels). The inverse quantization unit 110 performs a scaling operation on the quantization coefficients to output the reconstructed coefficients. The inverse transform unit 111 performs one or more inverse transforms corresponding to the transform in the transform unit 108 and outputs the reconstructed residual. The second adder 112 calculates the reconstructed CU by adding the reconstructed residual and the prediction block of the CU from the prediction unit 102. The second adder 112 also sends its output to the prediction unit 102 for use as an intra prediction reference. After all the CUs in the picture or sub-picture are reconstructed, the filtering unit 113 performs loop filtering on the reconstructed picture or sub-picture. Here, the filtering unit 113 includes one or more filters such as a de-blocking filter, a Sample Adaptive Offset (SAO) filter, an Adaptive Loop Filter (ALF), a Luma Mapping with Chroma Scaling (LMCS) filter, a neural network-based filter, and the like. Alternatively, when the filtering unit 113 determines that the CU is not used as a reference when encoding other CUs, the filtering unit 113 performs loop filtering on one or more target samples in the CU. The output of the filtering unit 113 is a decoded picture or sub-picture, which is buffered to the DPB unit 114. The DPB unit 114 outputs a decoded picture or a sub-picture according to the timing and control information. Here, the picture stored in the DPB unit 114 may also be used as a reference for the prediction unit 102 to perform inter prediction or intra prediction. Finally, the entropy coding unit 115 converts parameters necessary for decoding pictures from the encoder 100 (such as control parameters and supplementary information, etc.) into binary forms, and signals such binary forms into the bitstream according to the syntax structure of each data unit, that is, the encoder 100 finally outputs the bitstream.[ %3] Further, the encoder 100 may include a first processor and a first memory in which a computer program is recorded. When the first processor reads and runs the computer program, the encoder 100 reads the input video and generates a corresponding bitstream. Additionally, the encoder 100 may also be a computing device having one or more chips. These units, which are implemented on-chip as integrated circuits, have connection and data exchange functions similar to the corresponding units in FIG. 24.[ %3] FIG. 25 is a schematic block diagram of a system composition of a decoder according to an embodiment of the present disclosure. As shown in FIG. 25, the decoder 200 may include a parsing unit 201, a prediction unit 202, an inverse quantization unit 205, an inverse transform unit 206, an adder 207, a filtering unit 208, and a decoded picture buffer unit 209. Here, the input of the decoder 200 is a bit stream representing a compressed version of a video or a still picture, and the output of the decoder 200 may be a decoded video composed of a series of pictures or a decoded still picture.[ %3] The input bitstream of the decoder 200 may be a bitstream generated by the encoder 100. The parsing unit 201 parses the input bitstream and acquires the value of the syntax element from the input bitstream. The parsing unit 201 converts the binary representation of the syntax element into a digital value and transmits the digital value to a unit in the decoder 200 to acquire one or more decoded pictures. The parsing unit 201 may also parse one or more syntax elements from the input bitstream to display the decoded picture.[ %3] In the decoding process of the decoder 200, the parsing unit 201 transmits the value of the syntax element and one or more variables for acquiring one or more decoded pictures set or determined according to the value of the syntax element to the unit in the decoder 200. The prediction unit 202 determines a prediction block of a current decoded block (e.g., CU). Here, the prediction unit 202 may include a motion compensation unit 203 and an intra prediction unit 204. Specifically, when the inter decoding mode is indicated for decoding the current decoded block, the prediction unit 202 passes the relevant parameters from the parsing unit 201 to the motion compensation unit 203 to acquire the inter prediction block. When an intra prediction mode (including a MIP mode indicated based on the MIP mode index value) is indicated for decoding the current decoded block, the prediction unit 202 transmits the relevant parameters from the parsing unit 201 to the intra prediction unit 204 to acquire the intra prediction block. The inverse quantization unit 205 has the same function as the inverse quantization unit 110 in the encoder 100. The inverse quantization unit 205 performs a scaling operation on the quantization coefficients (i.e., levels) from the parsing unit 201 to obtain the reconstructed coefficients. The inverse transform unit 206 has the same function as the inverse transform unit 111 in the encoder 100. The inverse transform unit 206 performs one or more transform operations (i.e., the inverse of the one or more transform operations performed by the inverse transform unit 111 in the encoder 100) to obtain the reconstructed residual. The adder 207 performs an addition operation on its inputs (the prediction block from the prediction unit 202 and the reconstructed residual from the inverse transform unit 206) to obtain the reconstructed block of the current decoded block. The reconstructed block is also transmitted to the prediction unit 202 to serve as a reference for other blocks encoded in the intra prediction mode.[ %3] After all the CUs in the picture or sub-picture are reconstructed, the filtering unit 208 performs loop filtering on the reconstructed picture or sub-picture. The filtering unit 208 includes one or more filters, such as a de-blocking filter, a sample adaptive compensation filter, an adaptive loop filter, a luma mapping with chroma scaling filter, a neural network-based filter, and the like. Alternatively, when the filtering unit 208 determines that the reconstructed block is not used as a reference when decoding other blocks, the filtering unit 208 performs loop filtering on one or more target samples in the reconstructed block. Here, the output of the filtering unit 208 is a decoded picture or sub-picture, which is buffered to the DPB unit 209. The DPB unit 209 outputs a decoded picture or a sub-picture according to the timing and control information. The pictures stored in the DPB unit 209 may also be used as references for performing inter prediction or intra prediction by the prediction unit 202.[ %3] Further, the encoder 200 may include a second processor and a second memory in which a computer program is recorded. When the first processor reads and runs the computer program, the decoder 200 reads the input bitstream and generates the corresponding decoded video. Additionally, the decoder 200 may also be a computing device having one or more chips. These units, which are implemented on-chip as integrated circuits, have connection and data exchange functions similar to the corresponding units in FIG. 25.[ %3] It should also be noted that when the embodiments of the present disclosure are applied to the encoder 100, the "current block" specifically refers to a block currently to be encoded in a video picture (which may also be simply referred to as a "encoding block"). When the embodiments of the present disclosure are applied to the decoder 200, the "current block" specifically refers to a block currently to be decoded in a video picture (which may also be simply referred to as a "decoding block").[ %3] In an embodiment of the present disclosure, FIG. 26 is a first schematic flowchart of a method for decoding according to an embodiment of the present disclosure. As shown in FIG. 26, the method may include the following operations.[ %3] At S2601, a prediction mode of a current block is determined.[ %3] It should be noted that, in the embodiment of the present disclosure, the method is applied to a decoder. Specifically, based on the composition structure of the decoder 200 shown in FIG. 25, the method for decoding according to the embodiment of the present disclosure is mainly applied to the intra prediction block. Here, when the current block adopts the intra prediction mode, here is mainly the optimization scheme proposed for NSPT and LFNST transform in the intra prediction mode, so as to improve the compression efficiency.[ %3] It should also be noted that in the embodiment of the present disclosure, both NSPT and LFNST are transforms that process textures of various angles. They may have multiple transform kernels, and one transform kernel may be specially optimized for a specific angle texture. In addition to angular textures, NSPT and LFNST also include transform kernels that handle gradient textures. In fact, these transform kernels can also be said to be the trained Karhunen-Loeve (KL) Transform (KLT). That is, both NSPT and LFNST have multiple transform kernels, and each transform kernel is designed for a specific texture, which includes angular texture, gradient texture, etc. In addition, the gradient texture can be further expanded such as horizontal gradient texture, vertical gradient texture, oblique gradient texture, etc. Further, this scheme is not limited to non-separable transforms such as NSPT and LFNST, and can also be applied to separable transforms optimized for specific textures.[ %3] It should also be noted that in the intra prediction block, they have multiple transform kernel sets, and each intra prediction mode may correspond to one transform kernel set. In other words, each intra prediction mode actually represents a texture feature. Therefore, the intra prediction mode index is also a texture feature index. For example, DC and PLANAR correspond to the gradient texture features, and a certain angular prediction mode corresponds to the texture feature of this angle. On the one hand, the texture feature index can avoid the appearance of the intra prediction mode in "inter" situations; on the other hand, it is more conducive to possible expansions. For example, one intra prediction mode can correspond to a variety of texture features, such as DC mode may correspond to horizontal gradient texture, vertical gradient texture, oblique gradient texture, etc.[ %3] In the embodiment of the present disclosure, it is considered that some intra prediction modes do not have simple texture features but may include two or more types of texture features. Therefore, the prediction mode of the current block needs to be determined first. In some embodiments, the method may include decoding the bitstream to determine the prediction mode of the current block.[ %3] In the embodiment of the present disclosure, mode indication information (or mode flag bits) in the form of syntax elements may be signalled in the bitstream. In this way, the prediction mode of the current block can be determined by parsing the value of the mode indication information (or the mode flag bits) in the bitstream.[ %3] At S2602, a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] It should be noted that in the embodiments of the present disclosure, the prediction mode of the current block meets the first condition, and may include that the prediction mode of the current block is one of the first prediction mode set.[ %3] It should be noted that in the embodiments of the present disclosure, the first prediction mode set includes at least a DIMD mode, a TIMD mode, an SGPM, an MIP mode, an ITMP mode, and an IBC mode.[ %3] It should also be noted that, in the embodiment of the present disclosure, the mode in the first prediction pattern set is a relatively complex prediction mode, and the corresponding texture thereof may contain two or more texture features. For example, both DIMD mode and TIMD mode can weight the prediction values of two or more intra prediction modes, SGPM mode weights the prediction values of two intra prediction modes with a weight matrix, MIP mode predicts according to a matrix operation, ITMP mode and IBC mode predict based on copying a reconstructed reference block, and their texture features are not as simple as the DC mode, the PLANAR mode, etc., so it is necessary to determine a first candidate list here. Here, the first candidate list may include at least two candidate texture feature indices, or the first candidate list may include at least two transform kernel sets. Here, each candidate texture feature index corresponds to a transform kernel set. Thus, it can be said that the first candidate list indicates at least two candidate transform kernel sets.[ %3] In some embodiments, determining a first candidate list for a current block, the method may include: determining candidate samples for deriving a texture feature index; determining one or more candidate transform kernel sets of the current block according to the candidate samples; and adding the one or more candidate transform kernel sets to the first candidate list. Here, when the one or more candidate transform kernel sets of the current block are determined according to the candidate samples, one or more candidate texture feature indices of the current block may be determined first according to the candidate samples, and then the one or more candidate transform kernel sets of the current block may be determined according to the one or more candidate texture feature indices.[ %3] It should also be noted that, in general, one candidate texture feature index corresponds to one candidate transform kernel set. However, in some cases, multiple similar candidate texture feature indices may correspond to the same transform kernel set. For example, multiple intra prediction modes of similar angles correspond to the same transform kernel set. In the embodiment of the present disclosure, if multiple neighbouring intra prediction modes (or candidate texture feature indices) correspond to one transform kernel set, when determining the candidate transform kernel sets, it is necessary to ensure that the candidate texture feature indices are not mapped to the same transform kernel set.[ %3] In one possible implementation, for the candidate samples, the method may include: determining a prediction block of the current block; and taking at least some samples in the prediction block as the candidate samples.[ %3] In the embodiment of the present disclosure, if a certain texture exists in the prediction block, it may be considered that a texture having the same feature exists in the residual block. As described above, the candidate samples used for inter derivation of the candidate texture feature index may be all samples in the prediction block or some samples in the prediction block.[ %3] In another possible implementation, for the candidate samples, the method may include: determining neighbouring samples of a reconstructed area of the current block; and taking the neighbouring samples of the reconstructed area as the candidate samples.[ %3] In the embodiment of the present disclosure, the candidate samples used for inter derivation of the candidate texture feature index may be neighbouring samples in the reconstructed area of the current block, for example, the reconstructed areas on the left and right sides of the current block. Because the reconstructed areas on the left and top sides are not the current block but are adjacent to the current block, for example, the texture may be continuous, so they can be used to estimate the texture of the current block to a certain extent.[ %3] In yet another possible implementation, considering the use of more samples, for candidate samples, neighbouring samples of the reconstructed area and at least some samples in the prediction block may be taken together as the candidate samples.[ %3] In the embodiment of the present disclosure, the candidate samples used for inter derivation of the candidate texture feature index may also be both the prediction block of the current block and the reconstructed areas on the left and top sides of the current block. This provides more samples for deriving the candidate texture feature index, making the derived candidate texture feature index more accurate.[ %3] Further, in the embodiment of the present disclosure, the number of candidate samples for deriving the candidate texture feature index may be at least one, for example, 1, 2, 3, or more.[ %3] In some embodiments, the method may further include determining a number of the candidate samples according to a size parameter of the current block.[ %3] That is, when deriving one or more candidate texture feature indices according to the candidate samples, how many candidate samples to use may be determined by the size parameter of the current block. For example, if the size of the current block is small, then all available samples may be counted; if the size of the current block is large, the current block may be downsampled for statistics, such as taking statistics from one sample out of every 2, 4, or 8 samples in the horizontal and / or vertical direction. Alternatively, if the size of the current block in either horizontal or vertical direction is less than or equal to 8, then all available samples in that direction are counted. Otherwise, if the size of the current block in either horizontal or vertical direction is less than or equal to 16, then one sample out of every 2 samples in that direction is counted. Otherwise, one sample out of every 4 samples in this direction is counted, which is not particularly limited here.[ %3] In some embodiments, determining the candidate texture feature list of the current block according to the candidate samples may include: determining horizontal gradient values and vertical gradient values of the candidate samples; determining, according to the horizontal gradient values and the vertical gradient values of the candidate samples, a texture feature index and a gradient magnitude value corresponding to each of the candidate samples; constructing a texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples; and determining the candidate texture feature list of the current block according to the texture feature statistical table.[ %3] It should be noted that, in the embodiment of the present disclosure, when determining the texture feature index and the gradient magnitude value corresponding to the candidate sample according to the horizontal gradient value and the vertical gradient value of the candidate sample, the method may include: performing angular mapping according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the texture feature index corresponding to the candidate sample; and performing gradient magnitude calculation according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the gradient magnitude value corresponding to the candidate sample.[ %3] In a specific embodiment, performing angular mapping according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the texture feature index corresponding to the candidate sample may include: determining the texture feature index corresponding to the candidate sample by using a preset lookup table according to the horizontal gradient value and the vertical gradient value of the candidate sample.[ %3] In the embodiment of the present disclosure, the horizontal gradient value of the candidate sample may be expressed by , and the vertical gradient value of the candidate sample may be expressed by . In this way, deriving the texture feature index (or "virtual intra prediction mode") according to and can be achieved via table lookup.[ %3] For example, if is equal to 0 and is not equal to 0, then there is a horizontal direction texture, corresponding to intra prediction mode 18 in VVC. If is equal to 0 and is not equal to 0, then there is a vertical direction texture, corresponding to intra prediction mode 50 in VVC. In the case that both are not equal to 0, if is equal to , and and have the same sign, that corresponds to intra prediction mode 34 in VVC. If is equal to twice , and and have the same sign, that corresponds to intra prediction mode 40 in VVC. In addition, other cases can be determined by looking up the table according to the same principle.[ %3] In a specific embodiment, performing gradient magnitude calculation according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the gradient magnitude value corresponding to the candidate sample may include: adding the absolute value of the horizontal gradient value and the absolute value of the vertical gradient value to determine the gradient magnitude value corresponding to the candidate sample.[ %3] Here, the gradient magnitude value corresponding to the candidate sample may be denoted as amp. Exemplarily, amp = .[ %3] In the embodiment of the present disclosure, the horizontal gradient value and the vertical gradient value for the candidate sample can be calculated using a sobel operator. Exemplarily, for the sobel operator, the specifics are as follows.[ %3] Operator for the horizontal gradient value:-101-202-101[ %3] Operator for the vertical gradient value:-1-2-1000121[ %3] Thus, assuming that the sample value at the sample position of (x, y) is , the horizontal gradient value and the vertical gradient value are calculated as follows.(5)(6)[ %3] It should also be noted that in the embodiment of the present disclosure, the candidate samples may be set to exclude the samples in the outermost row and column on each of the top, bottom, left, and right sides of the current block. Here, considering that the sobel operator needs to use the samples in the row and column on each of the top, bottom, left, and right sides of the current sample, the embodiments of the present disclosure may be set not to calculate the gradients of the samples in the outermost row and column on each of the top, bottom, left, and right sides of the current block.[ %3] In some embodiments, constructing the texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples may include: in a case that a number of the candidate samples is at least one, determining at least one texture feature index and at least one gradient magnitude value corresponding to the at least one texture feature index; determining at least one reference texture feature index having mutually distinct properties according to the at least one texture feature index, and performing an accumulation calculation on gradient magnitude values belonging to a same reference texture feature index according to the at least one gradient magnitude value to determine a gradient magnitude accumulation value corresponding to the at least one reference texture feature index; and constructing the texture feature statistical table according to the at least one reference texture feature index and the gradient magnitude accumulation value corresponding to the at least one reference texture feature index.[ %3] That is, in the embodiment of the present disclosure, taking at least some samples in the prediction block as candidate samples as an example, and calculating gradients for all or some samples in the prediction block, generally speaking, horizontal gradient values and vertical gradient values can be calculated, and here, a sobel operator can be used to calculate gradient values. For a certain sample, the texture direction of the sample can be inferred from its horizontal gradient value and vertical gradient value. For example, if the horizontal gradient value is non-zero and the vertical gradient value is zero, then the texture of the sample is vertical. Conversely, if the horizontal gradient value is zero and the vertical gradient value is non-zero, then the texture of the sample is horizontal. For example, if the horizontal gradient value and the vertical gradient value are equal and not zero, the texture of the sample is 45 degrees. Certainly, there are many other cases in which the horizontal gradient value and the vertical gradient value are not zero in the embodiment of the present disclosure, and the direction of the texture of the sample can be determined according to their ratio. In this way, the gradient magnitude value of each sample may correspond to the corresponding texture feature index. Thereby constructing a texture feature statistical table, accumulating the gradient magnitude value of each calculated sample into the corresponding texture feature index item in the statistical table to obtain a final texture feature statistical table, and then determining a candidate texture feature list of the current block according to the texture feature statistical table.[ %3] In some embodiments, determining the candidate texture feature list of the current block according to the texture feature statistical table, the method may include: sorting the texture feature statistical table in descending order of gradient magnitude accumulation values, and determining N reference texture feature indices, each corresponding to a respective one of N gradient magnitude accumulation values ranked at the front; and adding the N reference texture feature indices to the candidate texture feature list of the current block. Here, N is a positive integer.[ %3] That is, in the embodiments of the present disclosure, after the texture feature statistical table is constructed, in order to reduce complexity, the texture feature statistical table can also be sorted in descending order of accumulated gradient magnitude accumulation values, and only the N reference texture feature indices ranked at the front are selected. Here, for complexity considerations, it is possible to maintain only a single candidate texture feature list of length N, and the candidate texture feature list is sorted in descending order of gradient magnitude accumulation values.[ %3] It should also be noted that in the embodiment of the present disclosure, the value of N may be 2, 3, 4, 5, ... , 10, or the like, and the value of N is not specifically limited here.[ %3] It can be understood that in the embodiment of the present disclosure, considering that the angles of some neighbouring intra prediction modes are very close, in order to exclude intra prediction modes that are too close, the method may further include: pruning N reference texture feature indices in the candidate texture feature list to determine the one or more candidate transform kernel sets of the current block.[ %3] In some embodiments, pruning the N reference texture feature indices in the candidate texture feature list to determine the one or more candidate transform kernel sets of the current block may include: determining a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; and in a case that a second condition is met between another reference texture feature index other than the reference texture feature index at the first position in the candidate texture feature list and an i-th candidate transform kernel set, determining an (i+1)-th candidate transform kernel set according to the another reference texture feature index to determine the one or more candidate transform kernel sets of the current block, where i is an integer greater than zero and less than N.[ %3] Note that, in the embodiment of the present disclosure, the second condition may include: the difference between the i-th candidate texture feature index and the (i+1)-th candidate texture feature index meets a preset threshold, i.e., there is a certain difference between two neighbouring candidate texture feature indices. Alternatively, when each candidate texture feature index corresponds to a candidate transform kernel set, it may also be said that the difference between the i-th candidate transform kernel set and the (i+1)-th candidate transform kernel set meets a preset threshold.[ %3] Note that, in the embodiment of the present disclosure, the N reference texture feature indices are sorted in descending order of gradient magnitude accumulation values. In this case, determining the first candidate transform kernel set according to the reference texture feature index at the first position in the candidate texture feature list may include: determining the first candidate transform kernel set according to the reference texture feature index having the largest gradient magnitude accumulation value in the candidate texture feature list.[ %3] It should also be noted that, in the embodiment of the present disclosure, the preset threshold may be represented by THR, the i-th candidate texture feature index may be represented by candFeature(i), and the (i+1)-th candidate texture feature index may be represented by candFeature(i +1). In a specific embodiment, the difference between the i-th candidate texture feature index and the (i+1)-th candidate texture feature index meets a preset threshold may include: candFeature (i+1)+ THR < candFeature(i) || candFeature(i+1) - THR > candFeature(i).[ %3] It should also be noted that in the embodiment of the present disclosure, the value of THR may be 3, 4, 5, 6, or the like. In this way, this pruning method will preferentially select the candidate texture feature index with a certain discrimination degree for the case where multiple neighbouring angles have high accumulation values.[ %3] It is also understandable that in the embodiments of the present disclosure, the above method does not take into account the intra prediction modes derived by modes such as DIMD, TIMD, SGPM themselves. Accordingly, in some embodiments, the method may further include: determining one or more intra prediction modes derived from the prediction mode of the current block; and determining one or more candidate transform kernel sets according to the one or more intra prediction modes and adding the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the method further includes: determining a preset texture feature index of the current block in a case that the first candidate list is not full filled; and determining one or more candidate transform kernel sets according to the preset texture feature index and adding the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the method further includes: determining candidate samples for deriving a texture feature index in a case that the first candidate list is not full filled; determining a candidate texture feature list of the current block according to the candidate samples; and determining one or more candidate transform kernel sets according to the candidate texture feature list, and adding the one or more candidate transform kernel sets to the first candidate list.[ %3] That is to say, in the embodiment of the present disclosure, considering some modes derived by DIMD, TIMD, SGPM and other modes themselves, for example, DIMD itself will derive one or several intra prediction modes for weighting, and TIMD itself will also derive one or several intra prediction modes for weighting, SGPM not only has two intra prediction modes, but also has a “partitioning" mode to find the corresponding intra prediction mode, and the residual often appears at the boundary area of the "partition". Therefore, one possible implementation is to determine the first candidate list according to the intra prediction mode derived by DIMD, TIMD, SGPM and other modes themselves and the candidate texture feature index derived by the method described above. Alternatively, another possible implementation is to determine the first candidate list according to the intra prediction mode derived by DIMD, TIMD, SGPM and other modes themselves and the default texture feature index.[ %3] In addition, in the embodiment of the present disclosure, since DIMD, TIMD, and SGPM can all derive more than one intra prediction mode, multiple modes derived by each mode can also be preferentially used to determine the candidate texture feature indices for these modes. When the modes derived by each mode cannot fill all the candidate texture feature indices, one possible method is to add a default texture feature index, and one possible method is to determine the candidate texture feature indices using the sorted intra prediction mode list of length N described above.[ %3] For example, when the prediction mode of the current block is the DIMD mode, if it is weighted using the prediction values of multiple intra prediction modes during prediction, those multiple intra prediction modes used for weighting may be sequentially attempted as candidate texture feature indices.[ %3] For example, when the prediction mode of the current block is the TIMD mode, if it is weighted using the prediction values of multiple intra prediction modes during prediction, those multiple intra prediction modes used for weighting may be sequentially attempted as candidate texture feature indices.[ %3] For example, when the prediction mode of the current block is the SGPM mode, the intra prediction mode corresponding to the "partitioning" mode derived therefrom and the two intra prediction modes used for prediction may be sequentially attempted as candidate texture feature indices.[ %3] In yet another possible implementation, for determining the first candidate list of the current block, the method may include: determining a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; in a case that a second condition is not met between all reference texture feature indices other than the reference texture feature index at the first position in the candidate texture feature list and the first candidate transform kernel set, determining a second candidate transform kernel set according to a reference texture feature index at a second position in the candidate texture feature list; and determining the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] Note that, in the embodiment of the present disclosure, determining the first candidate transform kernel set according to the reference texture feature index at the first position in the candidate texture feature list may specifically include: determining the first candidate transform kernel set according to the reference texture feature index having the largest gradient magnitude accumulation value in the candidate texture feature list.[ %3] It should also be noted that, in the embodiment of the present disclosure, taking the first candidate list indicating two candidate transform kernel sets as an example, the first candidate transform kernel set may be represented by candFeature0, and the second candidate transform kernel set may be represented by candFeature1. For example, if the intra prediction mode with the largest gradient magnitude accumulation value is the first candidate transform kernel set candFeature0, when selecting the second candidate transform kernel set candFeature1, it is necessary that there is a certain difference between candFeature1 and candFeature0, for example, candFeature1 + THR < candFeature0 || candFeature1 - THR > candFeature0. If after checking all the N-1 reference texture feature indices, there is still no one that meets the requirements, then the second candidate transform kernel set candFeature1 can be determined according to the reference texture feature index at the second position among the N reference texture feature indices. That is, at this time, the candidate transform kernel sets corresponding to the first two reference texture feature indices with the largest gradient magnitude accumulation values can be added to the first candidate list.[ %3] In yet another possible implementation, for determining the first candidate list of the current block, the method may include: determining a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; in a case that a second condition is not met between all reference texture feature indices other than the reference texture feature index at the first position in the candidate texture feature list and the first candidate transform kernel set, determining a second candidate transform kernel set according to a preset texture feature index; and determining the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] It should be noted that in the embodiment of the present disclosure, if there is still no one meeting the requirements after checking all the N-1 reference texture feature indices, the default texture feature index of the current block may also be determined, and then the candidate transform kernel sets corresponding to the reference texture feature index with the largest gradient magnitude accumulation value and the default texture feature index may be added to the first candidate list.[ %3] In yet another possible implementation, for determining the first candidate list of the current block, the method may include: determining a first candidate transform kernel set according to a first intra prediction mode derived from the prediction mode of the current block; in a case that a second condition is met between a first reference texture feature index in the candidate texture feature list and the first candidate transform kernel set, determining a second candidate transform kernel set according to the first reference texture feature index; and determining the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] Note that, in the embodiment of the present disclosure, the first candidate list considers not only the candidate texture feature index derived from the horizontal gradient value and the vertical gradient value of the candidate samples, but also the intra prediction mode derived from the prediction mode itself of the current block. The following is described in detail with several examples.[ %3] For example, when the prediction mode of the current block is the DIMD mode, the first intra prediction mode derived from the DIMD mode is used as candFeature0.[ %3] For example, when the prediction mode of the current block is the TIMD mode, the first intra prediction mode derived from the TIMD mode is used as candFeature0.[ %3] For example, when the prediction mode of the current block is the SGPM mode, the intra prediction mode corresponding to the SGPM "partitioning" mode is used as candFeature0.[ %3] Then, candFeature1 is determined according to the above method. For instance, among the N reference texture feature indices, starting from the first position, if a certain reference texture feature index meets the restriction of THR, it can be used as candFeature1.[ %3] It should also be noted that in the embodiment of the present disclosure, for modes such as IBC and ITMP, a prediction block or a prediction block plus a template may be used to derive a candidate texture feature index (or an intra prediction mode).[ %3] It should also be noted that in the embodiment of the present disclosure, if the candidate samples used by the embodiment of the present disclosure to derive the N reference texture feature indices are the same as the candidate samples used by the DIMD mode, the first intra prediction mode derived by the DIMD and the first reference texture feature index derived by the embodiment of the present disclosure are the same.[ %3] At S2603, a transform kernel of the current block is determined according to the first candidate list.[ %3] Note that, after the first candidate list is constructed, the transform kernel of the current block can be further determined.[ %3] In a possible implementation, for determining the transform kernel of the current block, the first candidate list indicates the transform kernels included in the at least two transform kernel sets. In this case, referring to FIG. 27, the method may include operations as follows.[ %3] At S2701, a transform kernel index number of the current block is determined.[ %3] At S2702, the transform kernel of the current block is determined according to a first candidate list and a transform kernel index number of the current block.[ %3] In the embodiment of the present disclosure, assuming that the first candidate list indicates transform kernels included in two candidate transform kernel sets, if the first candidate transform kernel set includes 3 candidate transform kernels and the second candidate transform kernel set includes 2 candidate transform kernels, the first candidate list may indicate 5 candidate transform kernels; if the first candidate transform kernel set includes 3 candidate transform kernels and the second candidate transform kernel set includes 3 candidate transform kernels, the first candidate list may indicate 6 candidate transform kernels.[ %3] In the embodiment of the present disclosure, the transform kernel index number of the current block is first determined, and then the transform kernel of the current block is determined in the first candidate list according to the transform kernel index number.[ %3] Note that, in the embodiment of the present disclosure, the transform kernel index number of the current block may be a positive integer, for example, 1, 2, 3, 4, 5, 6, or the like. The transform kernel index number of the current block may be determined by decoding the bitstream directly, or may be determined by decoding the value of the first syntax element.[ %3] Exemplarily, one possible implementation is to decode the bitstream to determine the transform kernel index number of the current block. Alternatively, another possible implementation is: decoding a bitstream to determine a value of a first syntax element; and in a case that the first syntax element indicates that the current block uses a first transform mode, determining the transform kernel index number of the current block according to the value of the first syntax element.[ %3] It should also be noted that, in the embodiment of the present disclosure, the first transform mode may be LFNST / NSPT, and the first syntax element may be represented by lfnst_idx. Here, the first syntax element may indicate whether the current block uses the first transform mode, and a corresponding transform kernel index number when the current block uses the first transform mode.[ %3] It should also be noted that in the embodiment of the present disclosure, if the value of the first syntax element is the first value, it is determined that the current block does not use the first transform mode; if the value of the first syntax element is the second value, it is determined that the current block uses the first transform mode and the corresponding transform kernel index number. Here, the first value may be set to 0, and the second value may be set to a non-zero value, such as 1, 2, 3, 4, 5, 6, etc.[ %3] That is, in the embodiment of the present disclosure, for the LFNST / NSPT, the transform kernel index number of the current block may be indicated by lfnst_idx. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST / NSPT. In ECM, each transform kernel set of LFNST / NSPT has 3 transform kernels, so lfnst_idx equal to 1, 2, or 3 indicates that the current block uses the 1st, 2nd, or 3rd transform kernel of the selected transform kernel set for LFNST / NSPT, respectively.[ %3] In the embodiment of the present disclosure, if the prediction mode of the current block is a certain special intra prediction mode, it may select more than one transform kernel set. For example, if it has 2 optional transform kernel sets, then the possible values of lfnst_idx are 0, 1, 2, 3, 4, 5, 6. Here, 1, 2, 3 correspond to the 3 transform kernels of the first transform kernel set, and 4, 5, 6 correspond to the 3 transform kernels of the second transform kernel set.[ %3] In a specific embodiment, the binary symbol correspondence table of lfnst_idx is shown in Table 7.Table 7lfnst_idx valueBinIdx012000 110020103110410150116111 [ %3] Here, the third binary symbol, that is, the binary symbol in which BinIdx is 2, can also be understood as selecting the first candidate transform kernel set or the second candidate transform kernel set.[ %3] In another possible implementation, for determining the transform kernel of the current block, referring to FIG. 28, the method may include operations as follows.[ %3] At S2801, a bitstream is decoded to determine a feature index number of the current block.[ %3] At S2802, a transform kernel set of the current block is determined according to the first candidate list and the feature index number.[ %3] At S2803, the transform kernel of the current block is determined according to the transform kernel set and the transform kernel index number of the current block.[ %3] In the embodiment of the present disclosure, the transform kernel set here is one of the at least two candidate transform kernel sets indicated by the first candidate list, and here may be the transform kernel set determined by the texture feature index of the current block. In some embodiments, for determining a set of transform kernels for the current block, the method may include: determining a texture feature index of the current block according to a first candidate list and a feature index number; and determining the transform kernel set of the current block according to the texture feature index.[ %3] Note that, in the embodiment of the present disclosure, the feature index number of the current block indicates a number of the transform kernel set of the current block in the first candidate list, and the feature index number may be represented by lfnst_feature_idx. Here, the feature index number of the current block may be an integer greater than or equal to zero, such as 0, 1, 2, 3, 4, and the like. For example, if the first candidate list indicates two candidate transform kernel sets, then lfnst_feature_idx indicates which candidate transform kernel set is specifically selected. For example, if the value of lfnst_feature_idx is equal to 0, it indicates that the first candidate transform kernel set indicated by the first candidate list is selected; if the value of lfnst_feature_idx is equal to 1, it indicates that the second candidate transform kernel set indicated by the first candidate list is selected.[ %3] It should be noted that after the transform kernel set of the current block is determined, the transform kernel of the current block may be determined according to the transform kernel set. Specifically, the transform kernel index number of the current block is first determined, and then the transform kernel of the current block is determined according to the transform kernel set and the transform kernel index number.[ %3] In the embodiment of the present disclosure, the transform kernel index number of the current block may be a positive integer, for example, 1, 2, 3, 4, 5, 6, or the like. The transform kernel index number of the current block may be determined by decoding the bitstream directly, or may be determined by decoding the value of the first syntax element.[ %3] Exemplarily, one possible implementation is to decode the bitstream to determine the transform kernel index number of the current block. Alternatively, another possible implementation is: decoding a bitstream to determine a value of a first syntax element; and in a case that the first syntax element indicates that the current block uses a first transform mode, determining the transform kernel index number of the current block according to the value of the first syntax element.[ %3] It should also be noted that, in the embodiment of the present disclosure, the first transform mode may be LFNST / NSPT, and the first syntax element may be represented by lfnst_idx. Here, the first syntax element may indicate whether the current block uses the first transform mode, and a corresponding transform kernel index number when the current block uses the first transform mode. For example, in this case, for LFNST / NSPT, the transform kernel index number of the current block may also be represented by lfnst_idx. In VVC, lfnst_idx may have 3 values, namely 0, 1, and 2. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST. In VVC, each transform kernel set of LFNST has 2 transform kernels, so lfnst_idx equal to 1 or 2 indicates that the current block uses the 1st or 2nd transform kernel of the selected transform kernel set for LFNST, respectively. In the existing ECM, lfnst_idx may have 4 values, namely 0, 1, 2, and 3. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST / NSPT. In ECM, each transform kernel set of LFNST / NSPT has 3 transform kernels, so lfnst_idx equal to 1, 2, or 3 indicates that the current block uses the 1st, 2nd, or 3rd transform kernel of the selected transform kernel set for LFNST / NSPT, respectively.[ %3] In a specific embodiment, the binary symbol correspondence table of lfnst_idx is shown in Table 8.Table 8Lfnst_idx valueBinIdx01000110201311 [ %3] It should also be noted that in the embodiment of the present disclosure, when decoding the bitstream to determine the feature index number of the current block, the method may further include: in a case that the current block uses the first transform mode, decoding the bitstream to determine the feature index number of the current block. That is, when the prediction mode of the current block meets the first condition and lfnst_idx>0, the operation of decoding the bitstream to determine the feature index number of the current block is performed.[ %3] At S2604, transform coefficients of the current block are determined, and inverse transform is performed on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] It should be noted that in the embodiment of the present disclosure, determining the transform coefficients of the current block may include: decoding a bitstream to determine quantization coefficients of the current block; and performing inverse quantization on the quantization coefficients of the current block to determine the transform coefficients of the current block.[ %3] It should also be noted that in the embodiment of the present disclosure, when performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block, the method may include: performing inverse transform of non-separable primary transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block; or performing inverse transform of low frequency non-separable transform on the transform coefficients of the current block according to the transform kernel to determine a transform block of the current block; and performing inverse transform of discrete cosine transform on the transform block of the current block to determine the residual block of the current block.[ %3] In a specific embodiment, if the size parameter of the current block meets the first condition, inverse transform of non-separable primary transform is performed on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block. If the size parameter of the current block meets the second condition, inverse transform of low frequency non-separable transform is performed on the transform coefficients of the current block according to the transform kernel to determine a transform block of the current block; and inverse transform of discrete cosine transform is performed on the transform block of the current block to determine the residual block of the current block.[ %3] Here, the size parameter of the current block meets the first condition, which includes that the size parameter of the current block is relatively small, for example, the size parameter of the current block is less than a certain threshold. That is, for a block with a smaller size, the transform kernel of NSPT is used here, that is, inverse NSPT transform is performed on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block.[ %3] Here, the size parameter of the current block meets the second condition, which includes that the size parameter of the current block is relatively large, for example, the size parameter of the current block is larger than a certain threshold. That is to say, for a block of a larger size, the LFNST transform kernel is used here, i.e., inverse LFNST transform is performed on the transform coefficients of the current block according to the transform kernel to determine the transform block of the current block; and inverse DCT2 transform is performed on the transform block of the current block to determine the residual block of the current block.[ %3] It should also be noted that, in the embodiment of the present disclosure, the "inverse transform" of the transform coefficients by the decoding end may also be referred to as "transform" in the standard text. "Transform" and "inverse transform" herein correspond to two opposite processes. For example, "transform" converts values in the spatial domain into coefficients in the frequency domain, and then "inverse transform" converts coefficients in the frequency domain into values in the spatial domain. “Inverse" is relative to "forward", and they are essentially transforms. It should be noted that if the standard only specifies decoding, then the "transform" in the standard text is the part of decoding, specifically referring to the "inverse transform" herein. The "inverse transform" of the transform coefficients by the decoding end may also be referred to as a "transform" in the standard text.[ %3] In some embodiments, referring to FIG. 29, after operation S2604, the method may further include operations as follows.[ %3] At S2901, intra prediction is performed on the current block to determine a prediction block of the current block.[ %3] At S2902, a reconstructed block of the current block is determined according to the prediction block of the current block and the residual block of the current block.[ %3] Note that, in the embodiment of the present disclosure, the operation S2901 may be operated in parallel with the operations S2601 to S2603, or may be executed before the operations S2601 to S2603, and the order of the operations is not specifically limited here.[ %3] It should also be noted that in the embodiment of the present disclosure, after determining the prediction block of the current block, an addition operation may be performed on the prediction block of the current block and the residual block of the current block to determine the reconstructed block of the current block.[ %3] Briefly, after determining the prediction block, the decoder derives a candidate texture feature index according to the prediction block, and then determines the transform kernel set of NSPT / LFNST according to the candidate texture feature index. If a transform kernel set has multiple selectable transform kernels, the decoder determines the transform kernel by decoding lfnst_nspt_idx in the bitstream. There is no dependence between the process of decoding lfnst_nspt_idx in the bitstream and the process of determining the transform kernel set. The quantization coefficients are decoded from the bitstream by entropy decoding.[ %3] If it is the NSPT transform, inverse quantization is performed on the quantization coefficients to obtain decoded transform coefficients, then inverse NSPT transform is performed on the decoded transform coefficients to obtain a decoded residual block, and finally the reconstructed block is obtained according to the decoded residual block and the prediction block.[ %3] If it is the LFNST transform, inverse quantization is performed on the quantization coefficients to obtain decoded transform coefficients, then inverse LFNST transform is performed on the decoded transform coefficients, followed by inverse DCT2 transform to obtain a decoded residual block, and finally the reconstructed block is obtained based on the decoded residual block and the prediction block.[ %3] Additionally, in some embodiments, referring to FIG. 30, after operation S2601, the method may further include operations as follows.[ %3] At S3001, a texture feature index of the current block is determined in a case that the prediction mode of the current block does not meet the first condition.[ %3] At S3002, the transform kernel of the current block is determined according to the texture feature index.[ %3] At S3003, transform coefficients of the current block are determined, and inverse transform is performed on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] Note that, in the embodiment of the present disclosure, determining the transform kernel of the current block according to the texture feature index may include: determining a transform kernel set of the current block according to the texture feature index; decoding a bitstream to determine a transform kernel index number of the current block; and determining the transform kernel of the current block according to the transform kernel set and the transform kernel index number.[ %3] Note that, in the embodiment of the present disclosure, the prediction mode of the current block not meeting the first condition may include: the prediction mode of the current block is a prediction mode other than those in a first prediction mode set. Alternatively, it may be said that the prediction mode of the current block not meeting the first condition may include: the prediction mode of the current block is one of prediction modes in a second prediction mode set.[ %3] Note that, in the embodiment of the present disclosure, the second prediction mode set includes at least a Direct Current (DC) mode, a PLANAR mode, an angular prediction mode, and a cross-component prediction mode.[ %3] It should also be noted that in the embodiment of the present disclosure, the modes in the second prediction mode set are relatively simple prediction modes. For example, a classification may be made, where the DC mode, the PLANAR mode, and the various angular prediction modes are classified into a first prediction mode set, and the DIMD mode, the TIMD mode, the MIP mode, the SGPM mode, the ITMP mode, and the IBC mode, etc., are classified into a second prediction mode set.[ %3] Exemplarily, the second prediction mode set may also include only one or more of a DIMD mode, the TIMD mode, the MIP mode, the SGPM mode, the ITMP mode, and the IBC mode. For example, the second prediction mode set includes the DIMD mode, the TIMD mode, and the SGPM mode. The other modes all belong to the first prediction mode set. The encoding method of the lfnst_idx of the first prediction mode set is the same as the method of the related art, while the encoding method of the lfnst_idx of the second prediction mode set is different from the method of the related art.[ %3] Exemplarily, each transform kernel set of the LFNST / NSPT has 3 transform kernels. A block using the first prediction mode set can only select one transform kernel set, while a block using the second prediction mode set can select two transform kernel sets, each having 3 transform kernels. If the prediction mode of the current block belongs to the first prediction mode set, it is only possible to select one texture feature index, then the possible values of lfnst_idx are 0, 1, 2, 3. If the prediction mode of the current block belongs to the second prediction mode set, then the possible values of lfnst_idx are 0, 1, 2, 3, 4, 5, 6. Here, 1, 2, 3 correspond to the 3 transform kernels of the transform kernel set corresponding to the first texture feature index, and 4, 5, 6 correspond to the 3 transform kernels of the transform kernel set corresponding to the second texture feature index. Here, the binary symbol correspondence table of the lfnst_idx of the block using the first prediction mode set is shown in Table 8, and the binary symbol correspondence table of the lfnst_idx of the block using the second prediction mode set is shown in Table 7.[ %3] The embodiment of the present disclosure provides a decoding method, in particular an intra LFNST / NSPT multi-angle selection scheme. First, a prediction mode of a current block is determined; a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; then, a transform kernel of the current block is determined according to the first candidate list; and transform coefficients of the current block are determined, and inverse transform is performed on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block. In this way, when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance.[ %3] In another embodiment of the present disclosure, FIG. 31 is a first schematic flowchart of a method for encoding according to an embodiment of the present disclosure. As shown in FIG. 31, the method may include the following operations.[ %3] At S3101, a prediction mode of a current block is determined.[ %3] It should be noted that, in the embodiment of the present disclosure, the method is applied to an encoder. Specifically, based on the composition structure of the encoder 200 shown in FIG. 24, the method for encoding according to the embodiment of the present disclosure is mainly applied to the intra prediction block. Here, when the current block adopts the intra prediction mode, here is mainly the optimization scheme proposed for NSPT and LFNST transform in the intra prediction mode, so as to improve the compression efficiency.[ %3] It should also be noted that in the embodiment of the present disclosure, both NSPT and LFNST are transforms that process textures of various angles. They may have multiple transform kernels, and one transform kernel may be specially optimized for a specific angle texture. In addition to angular textures, NSPT and LFNST also include transform kernels that handle gradient textures. In fact, these transform kernels can also be said to be the trained Karhunen-Loeve (KL) Transform (KLT). That is, both NSPT and LFNST have multiple transform kernels, and each transform kernel is designed for a specific texture, which includes angular texture, gradient texture, etc. In addition, the gradient texture can be further expanded such as horizontal gradient texture, vertical gradient texture, oblique gradient texture, etc. Further, this scheme is not limited to non-separable transforms such as NSPT and LFNST, and can also be applied to separable transforms optimized for specific textures.[ %3] It should also be noted that in the intra prediction block, they have multiple transform kernel sets, and each intra prediction mode may correspond to one transform kernel set. In other words, each intra prediction mode actually represents a texture feature. Therefore, the intra prediction mode index is also a texture feature index. For example, DC and PLANAR correspond to the gradient texture features, and a certain angular prediction mode corresponds to the texture feature of this angle. On the one hand, the texture feature index can avoid the appearance of the intra prediction mode in "inter" situations; on the other hand, it is more conducive to possible expansions. For example, one intra prediction mode can correspond to a variety of texture features, such as DC mode may correspond to horizontal gradient texture, vertical gradient texture, oblique gradient texture, etc.[ %3] In the embodiment of the present disclosure, it is considered that some intra prediction modes do not have simple texture features but may include two or more types of texture features. Therefore, the prediction mode of the current block needs to be determined first. In some embodiments, the method may include: determining multiple candidate prediction modes; performing coding cost calculation on the current block according to the multiple candidate prediction modes to determine cost results, each corresponding to a respective one of the multiple candidate prediction modes; determining a minimum cost result among the cost results; and determining a candidate prediction mode corresponding to the minimum cost result as the prediction mode of the current block.[ %3] Further, in some embodiments, the method may further include encoding the prediction mode of the current block, and signalling obtained encoded bits in a bitstream.[ %3] That is, in the embodiment of the present disclosure, after the prediction mode of the current block is determined, mode indication information (or mode flag bits) in the form of syntax elements may be signalled in the bitstream. In this way, the prediction mode of the current block can be determined by parsing the value of the mode indication information (or the mode flag bits) in the bitstream.[ %3] At S3102, a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] It should also be noted that, in the embodiment of the present disclosure, the mode in the first prediction pattern set is a relatively complex prediction mode, and the corresponding texture thereof may contain two or more texture features. For example, both DIMD mode and TIMD mode can weight the prediction values of two or more intra prediction modes, SGPM mode weights the prediction values of two intra prediction modes with a weight matrix, MIP mode predicts according to a matrix operation, ITMP mode and IBC mode predict based on copying a reconstructed reference block, and their texture features are not as simple as the DC mode, the PLANAR mode, etc., so it is necessary to determine a first candidate list here. Here, the first candidate list may include at least two candidate texture feature indices, or the first candidate list may include at least two transform kernel sets. Here, each candidate texture feature index corresponds to a transform kernel set. Thus, it can be said that the first candidate list indicates at least two candidate transform kernel sets.[ %3] In some embodiments, determining a first candidate list for a current block, the method may include: determining candidate samples for deriving a texture feature index; determining one or more candidate transform kernel sets of the current block according to the candidate samples; and adding the one or more candidate transform kernel sets to the first candidate list. Here, when the one or more candidate transform kernel sets of the current block are determined according to the candidate samples, one or more candidate texture feature indices of the current block may be determined first according to the candidate samples, and then the one or more candidate transform kernel sets of the current block may be determined according to the one or more candidate texture feature indices.[ %3] It should also be noted that, in general, one candidate texture feature index corresponds to one candidate transform kernel set. However, in some cases, multiple similar candidate texture feature indices may correspond to the same transform kernel set. For example, multiple intra prediction modes of similar angles correspond to the same transform kernel set. In the embodiment of the present disclosure, if multiple neighbouring intra prediction modes (or candidate texture feature indices) correspond to one transform kernel set, when determining the candidate transform kernel sets, it is necessary to ensure that the candidate texture feature indices are not mapped to the same transform kernel set.[ %3] In one possible implementation, for the candidate samples, the method may include: determining a prediction block of the current block; and taking at least some samples in the prediction block as the candidate samples.[ %3] In the embodiment of the present disclosure, if a certain texture exists in the prediction block, it may be considered that a texture having the same feature exists in the residual block. As described above, the candidate samples used for inter derivation of the candidate texture feature index may be all samples in the prediction block or some samples in the prediction block.[ %3] In another possible implementation, for the candidate samples, the method may include: determining neighbouring samples of a reconstructed area of the current block; and taking the neighbouring samples of the reconstructed area as the candidate samples.[ %3] In the embodiment of the present disclosure, the candidate samples used for inter derivation of the candidate texture feature index may be neighbouring samples in the reconstructed area of the current block, for example, the reconstructed areas on the left and right sides of the current block. Because the reconstructed areas on the left and top sides are not the current block but are adjacent to the current block, for example, the texture may be continuous, so they can be used to estimate the texture of the current block to a certain extent.[ %3] In yet another possible implementation, considering the use of more samples, for candidate samples, neighbouring samples of the reconstructed area and at least some samples in the prediction block may be taken together as the candidate samples.[ %3] In the embodiment of the present disclosure, the candidate samples used for inter derivation of the candidate texture feature index may also be both the prediction block of the current block and the reconstructed areas on the left and top sides of the current block. This provides more samples for deriving the candidate texture feature index, making the derived candidate texture feature index more accurate.[ %3] Further, in the embodiment of the present disclosure, the number of candidate samples for deriving the candidate texture feature index may be at least one, for example, 1, 2, 3, or more.[ %3] In some embodiments, the method may further include determining a number of the candidate samples according to a size parameter of the current block.[ %3] That is, when deriving one or more candidate texture feature indices according to the candidate samples, how many candidate samples to use may be determined by the size parameter of the current block. For example, if the size of the current block is small, then all available samples may be counted; if the size of the current block is large, the current block may be downsampled for statistics, such as taking statistics from one sample out of every 2, 4, or 8 samples in the horizontal and / or vertical direction. Alternatively, if the size of the current block in either horizontal or vertical direction is less than or equal to 8, then all available samples in that direction are counted. Otherwise, if the size of the current block in either horizontal or vertical direction is less than or equal to 16, then one sample out of every 2 samples in that direction is counted. Otherwise, one sample out of every 4 samples in this direction is counted, which is not particularly limited here.[ %3] In some embodiments, determining the candidate texture feature list of the current block according to the candidate samples may include: determining horizontal gradient values and vertical gradient values of the candidate samples; determining, according to the horizontal gradient values and the vertical gradient values of the candidate samples, a texture feature index and a gradient magnitude value corresponding to each of the candidate samples; constructing a texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples; and determining the candidate texture feature list of the current block according to the texture feature statistical table.[ %3] It should be noted that, in the embodiment of the present disclosure, when determining the texture feature index and the gradient magnitude value corresponding to the candidate sample according to the horizontal gradient value and the vertical gradient value of the candidate sample, the method may include: performing angular mapping according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the texture feature index corresponding to the candidate sample; and performing gradient magnitude calculation according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the gradient magnitude value corresponding to the candidate sample.[ %3] In a specific embodiment, performing angular mapping according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the texture feature index corresponding to the candidate sample may include: determining the texture feature index corresponding to the candidate sample by using a preset lookup table according to the horizontal gradient value and the vertical gradient value of the candidate sample.[ %3] In the embodiment of the present disclosure, the horizontal gradient value of the candidate sample may be expressed by , and the vertical gradient value of the candidate sample may be expressed by . In this way, deriving the texture feature index (or "virtual intra prediction mode") according to and can be achieved via table lookup.[ %3] For example, if is equal to 0 and is not equal to 0, then there is a horizontal direction texture, corresponding to intra prediction mode 18 in VVC. If is equal to 0 and is not equal to 0, then there is a vertical direction texture, corresponding to intra prediction mode 50 in VVC. In the case that both are not equal to 0, if is equal to , and and have the same sign, that corresponds to intra prediction mode 34 in VVC. If is equal to twice , and and have the same sign, that corresponds to intra prediction mode 40 in VVC. In addition, other cases can be determined by looking up the table according to the same principle.[ %3] In a specific embodiment, performing gradient magnitude calculation according to the horizontal gradient value and the vertical gradient value of the candidate sample to determine the gradient magnitude value corresponding to the candidate sample may include: adding the absolute value of the horizontal gradient value and the absolute value of the vertical gradient value to determine the gradient magnitude value corresponding to the candidate sample.[ %3] Here, the gradient magnitude value corresponding to the candidate sample may be denoted as amp. Exemplarily, amp = .[ %3] In the embodiment of the present disclosure, the horizontal gradient value and the vertical gradient value for the candidate sample can be calculated using a sobel operator. Exemplarily, for the sobel operator, the specifics are as follows.[ %3] Operator for the horizontal gradient value:-101-202-101[ %3] Operator for the vertical gradient value:-1-2-1000121[ %3] Thus, assuming that the sample value at the sample position of (x, y) is , the horizontal gradient value and the vertical gradient value are calculated as follows.(7)(8)[ %3] It should also be noted that in the embodiment of the present disclosure, the candidate samples may be set to exclude the samples in the outermost row and column on each of the top, bottom, left, and right sides of the current block. Here, considering that the sobel operator needs to use the samples in the row and column on each of the top, bottom, left, and right sides of the current sample, the embodiments of the present disclosure may be set not to calculate the gradients of the samples in the outermost row and column on each of the top, bottom, left, and right sides of the current block.[ %3] In some embodiments, constructing the texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples may include: in a case that a number of the candidate samples is at least one, determining at least one texture feature index and at least one gradient magnitude value corresponding to the at least one texture feature index; determining at least one reference texture feature index having mutually distinct properties according to the at least one texture feature index, and performing an accumulation calculation on gradient magnitude values belonging to a same reference texture feature index according to the at least one gradient magnitude value to determine a gradient magnitude accumulation value corresponding to the at least one reference texture feature index; and constructing the texture feature statistical table according to the at least one reference texture feature index and the gradient magnitude accumulation value corresponding to the at least one reference texture feature index.[ %3] That is, in the embodiment of the present disclosure, taking at least some samples in the prediction block as candidate samples as an example, and calculating gradients for all or some samples in the prediction block, generally speaking, horizontal gradient values and vertical gradient values can be calculated, and here, a sobel operator can be used to calculate gradient values. For a certain sample, the texture direction of the sample can be inferred from its horizontal gradient value and vertical gradient value. For example, if the horizontal gradient value is non-zero and the vertical gradient value is zero, then the texture of the sample is vertical. Conversely, if the horizontal gradient value is zero and the vertical gradient value is non-zero, then the texture of the sample is horizontal. For example, if the horizontal gradient value and the vertical gradient value are equal and not zero, the texture of the sample is 45 degrees. Certainly, there are many other cases in which the horizontal gradient value and the vertical gradient value are not zero in the embodiment of the present disclosure, and the direction of the texture of the sample can be determined according to their ratio. In this way, the gradient magnitude value of each sample may correspond to the corresponding texture feature index. Thereby constructing a texture feature statistical table, accumulating the gradient magnitude value of each calculated sample into the corresponding texture feature index item in the statistical table to obtain a final texture feature statistical table, and then determining a candidate texture feature list of the current block according to the texture feature statistical table.[ %3] In some embodiments, determining the candidate texture feature list of the current block according to the texture feature statistical table, the method may include: sorting the texture feature statistical table in descending order of gradient magnitude accumulation values, and determining N reference texture feature indices, each corresponding to a respective one of N gradient magnitude accumulation values ranked at the front; and adding the N reference texture feature indices to the candidate texture feature list of the current block. Here, N is a positive integer.[ %3] That is, in the embodiments of the present disclosure, after the texture feature statistical table is constructed, in order to reduce complexity, the texture feature statistical table can also be sorted in descending order of accumulated gradient magnitude accumulation values, and only the N reference texture feature indices ranked at the front are selected. Here, for complexity considerations, it is possible to maintain only a single candidate texture feature list of length N, and the candidate texture feature list is sorted in descending order of gradient magnitude accumulation values.[ %3] It should also be noted that in the embodiment of the present disclosure, the value of N may be 2, 3, 4, 5, ... , 10, or the like, and the value of N is not specifically limited here.[ %3] It can be understood that in the embodiment of the present disclosure, considering that the angles of some neighbouring intra prediction modes are very close, in order to exclude intra prediction modes that are too close, the method may further include: pruning N reference texture feature indices in the candidate texture feature list to determine the one or more candidate transform kernel sets of the current block.[ %3] In some embodiments, pruning the N reference texture feature indices in the candidate texture feature list to determine the one or more candidate transform kernel sets of the current block may include: determining a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; and in a case that a second condition is met between another reference texture feature index other than the reference texture feature index at the first position in the candidate texture feature list and an i-th candidate transform kernel set, determining an (i+1)-th candidate transform kernel set according to the another reference texture feature index to determine the one or more candidate transform kernel sets of the current block, where i is an integer greater than zero and less than N.[ %3] Note that, in the embodiment of the present disclosure, the second condition may include: the difference between the i-th candidate texture feature index and the (i+1)-th candidate texture feature index meets a preset threshold, i.e., there is a certain difference between two neighbouring candidate texture feature indices. Alternatively, when each candidate texture feature index corresponds to a candidate transform kernel set, it may also be said that the difference between the i-th candidate transform kernel set and the (i+1)-th candidate transform kernel set meets a preset threshold.[ %3] Note that, in the embodiment of the present disclosure, the N reference texture feature indices are sorted in descending order of gradient magnitude accumulation values. In this case, determining the first candidate transform kernel set according to the reference texture feature index at the first position in the candidate texture feature list may include: determining the first candidate transform kernel set according to the reference texture feature index having the largest gradient magnitude accumulation value in the candidate texture feature list.[ %3] It should also be noted that, in the embodiment of the present disclosure, the preset threshold may be represented by THR, the i-th candidate texture feature index may be represented by candFeature(i), and the (i+1)-th candidate texture feature index may be represented by candFeature(i +1). In a specific embodiment, the difference between the i-th candidate texture feature index and the (i+1)-th candidate texture feature index meets a preset threshold may include: candFeature (i+1)+ THR < candFeature(i) || candFeature(i+1) - THR > candFeature(i).[ %3] It should also be noted that in the embodiment of the present disclosure, the value of THR may be 3, 4, 5, 6, or the like. In this way, this pruning method will preferentially select the candidate texture feature index with a certain discrimination degree for the case where multiple neighbouring angles have high accumulation values.[ %3] It is also understandable that in the embodiments of the present disclosure, the above method does not take into account the intra prediction modes derived by modes such as DIMD, TIMD, SGPM themselves. Accordingly, in some embodiments, the method may further include: determining one or more intra prediction modes derived from the prediction mode of the current block; and determining one or more candidate transform kernel sets according to the one or more intra prediction modes and adding the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the method further includes: determining a preset texture feature index of the current block in a case that the first candidate list is not full filled; and determining one or more candidate transform kernel sets according to the preset texture feature index and adding the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the method further includes: determining candidate samples for deriving a texture feature index in a case that the first candidate list is not full filled; determining a candidate texture feature list of the current block according to the candidate samples; and determining one or more candidate transform kernel sets according to the candidate texture feature list, and adding the one or more candidate transform kernel sets to the first candidate list.[ %3] That is to say, in the embodiment of the present disclosure, considering some modes derived by DIMD, TIMD, SGPM and other modes themselves, for example, DIMD itself will derive one or several intra prediction modes for weighting, and TIMD itself will also derive one or several intra prediction modes for weighting, SGPM not only has two intra prediction modes, but also has a “partitioning" mode to find the corresponding intra prediction mode, and the residual often appears at the boundary area of the "partition". Therefore, one possible implementation is to determine the first candidate list according to the intra prediction mode derived by DIMD, TIMD, SGPM and other modes themselves and the candidate texture feature index derived by the method described above. Alternatively, another possible implementation is to determine the first candidate list according to the intra prediction mode derived by DIMD, TIMD, SGPM and other modes themselves and the default texture feature index.[ %3] In addition, in the embodiment of the present disclosure, since DIMD, TIMD, and SGPM can all derive more than one intra prediction mode, multiple modes derived by each mode can also be preferentially used to determine the candidate texture feature indices for these modes. When the modes derived by each mode cannot fill all the candidate texture feature indices, one possible method is to add a default texture feature index, and one possible method is to determine the candidate texture feature indices using the sorted intra prediction mode list of length N described above.[ %3] For example, when the prediction mode of the current block is the DIMD mode, if it is weighted using the prediction values of multiple intra prediction modes during prediction, those multiple intra prediction modes used for weighting may be sequentially attempted as candidate texture feature indices.[ %3] For example, when the prediction mode of the current block is the TIMD mode, if it is weighted using the prediction values of multiple intra prediction modes during prediction, those multiple intra prediction modes used for weighting may be sequentially attempted as candidate texture feature indices.[ %3] For example, when the prediction mode of the current block is the SGPM mode, the intra prediction mode corresponding to the "partitioning" mode derived therefrom and the two intra prediction modes used for prediction may be sequentially attempted as candidate texture feature indices.[ %3] In yet another possible implementation, for determining the first candidate list of the current block, the method may include: determining a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; in a case that a second condition is not met between all reference texture feature indices other than the reference texture feature index at the first position in the candidate texture feature list and the first candidate transform kernel set, determining a second candidate transform kernel set according to a reference texture feature index at a second position in the candidate texture feature list; and determining the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] Note that, in the embodiment of the present disclosure, determining the first candidate transform kernel set according to the reference texture feature index at the first position in the candidate texture feature list may specifically include: determining the first candidate transform kernel set according to the reference texture feature index having the largest gradient magnitude accumulation value in the candidate texture feature list.[ %3] It should also be noted that, in the embodiment of the present disclosure, taking the first candidate list indicating two candidate transform kernel sets as an example, the first candidate transform kernel set may be represented by candFeature0, and the second candidate transform kernel set may be represented by candFeature1. For example, if the intra prediction mode with the largest gradient magnitude accumulation value is the first candidate transform kernel set candFeature0, when selecting the second candidate transform kernel set candFeature1, it is necessary that there is a certain difference between candFeature1 and candFeature0, for example, candFeature1 + THR < candFeature0 || candFeature1 - THR > candFeature0. If after checking all the N-1 reference texture feature indices, there is still no one that meets the requirements, then the second candidate transform kernel set candFeature1 can be determined according to the reference texture feature index at the second position among the N reference texture feature indices. That is, at this time, the candidate transform kernel sets corresponding to the first two reference texture feature indices with the largest gradient magnitude accumulation values can be added to the first candidate list.[ %3] In yet another possible implementation, for determining the first candidate list of the current block, the method may include: determining a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; in a case that a second condition is not met between all reference texture feature indices other than the reference texture feature index at the first position in the candidate texture feature list and the first candidate transform kernel set, determining a second candidate transform kernel set according to a preset texture feature index; and determining the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] It should be noted that in the embodiment of the present disclosure, if there is still no one meeting the requirements after checking all the N-1 reference texture feature indices, the default texture feature index of the current block may also be determined, and then the candidate transform kernel sets corresponding to the reference texture feature index with the largest gradient magnitude accumulation value and the default texture feature index may be added to the first candidate list.[ %3] In yet another possible implementation, for determining the first candidate list of the current block, the method may include: determining a first candidate transform kernel set according to a first intra prediction mode derived from the prediction mode of the current block; in a case that a second condition is met between a first reference texture feature index in the candidate texture feature list and the first candidate transform kernel set, determining a second candidate transform kernel set according to the first reference texture feature index; and determining the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] Note that, in the embodiment of the present disclosure, the first candidate list considers not only the candidate texture feature index derived from the horizontal gradient value and the vertical gradient value of the candidate samples, but also the intra prediction mode derived from the prediction mode itself of the current block. The following is described in detail with several examples.[ %3] For example, when the prediction mode of the current block is the DIMD mode, the first intra prediction mode derived from the DIMD mode is used as candFeature0.[ %3] For example, when the prediction mode of the current block is the TIMD mode, the first intra prediction mode derived from the TIMD mode is used as candFeature0.[ %3] For example, when the prediction mode of the current block is the SGPM mode, the intra prediction mode corresponding to the SGPM "partitioning" mode is used as candFeature0.[ %3] Then, candFeature1 is determined according to the above method. For instance, among the N reference texture feature indices, starting from the first position, if a certain reference texture feature index meets the restriction of THR, it can be used as candFeature1.[ %3] It should also be noted that in the embodiment of the present disclosure, for modes such as IBC and ITMP, a prediction block or a prediction block plus a template may be used to derive a candidate texture feature index (or an intra prediction mode).[ %3] It should also be noted that in the embodiment of the present disclosure, if the candidate samples used by the embodiment of the present disclosure to derive the N reference texture feature indices are the same as the candidate samples used by the DIMD mode, the first intra prediction mode derived by the DIMD and the first reference texture feature index derived by the embodiment of the present disclosure are the same.[ %3] At S3103, a transform kernel of the current block is determined according to the first candidate list.[ %3] Note that, after the first candidate list is constructed, the transform kernel of the current block can be further determined.[ %3] In a possible implementation, for determining the transform kernel of the current block, the first candidate list indicates the transform kernels included in the at least two transform kernel sets. In this case, the transform kernel of the current block can be determined directly from the first candidate list according to the cost calculation.[ %3] In the embodiment of the present disclosure, assuming that the first candidate list indicates transform kernels included in two candidate transform kernel sets, if the first candidate transform kernel set includes 3 candidate transform kernels and the second candidate transform kernel set includes 2 candidate transform kernels, the first candidate list may indicate 5 candidate transform kernels; if the first candidate transform kernel set includes 3 candidate transform kernels and the second candidate transform kernel set includes 3 candidate transform kernels, the first candidate list may indicate 6 candidate transform kernels.[ %3] In some embodiments, determining the transform kernel of the current block according to the first candidate list may include: determining at least two candidate transform kernels indicated by the first candidate list; performing coding cost calculation on the current block according to the at least two candidate transform kernels to determine cost results, each corresponding to a respective one of the at least two candidate transform kernels; and determining a minimum cost result among the cost results, and determining a candidate transform kernel corresponding to the minimum cost result as the transform kernel of the current block.[ %3] Note that, in the embodiment of the present disclosure, the cost calculation here may be determined according to a cost result of Rate Distortion Optimization (RDO), a cost result of Sum of Absolute Difference (SAD), or even a cost result of Sum of Absolute Transformed Difference (SATD), but no limitation is made herein.[ %3] In a specific embodiment, performing coding cost calculation on the current block according to the at least two candidate transform kernels to determine the cost results, each corresponding to the respective one of the at least two candidate transform kernels may include: performing transform and quantization on the residual block of the current block based on a first candidate transform kernel to determine a first candidate quantization coefficient of the current block, and performing entropy coding on the first candidate quantization coefficient to determine a first cost value of the first candidate transform kernel; performing inverse quantization and inverse transform on the first candidate quantization coefficient to determine a first candidate residual block of the current block, and determining a first candidate prediction block of the current block according to the first candidate residual block; performing cost calculation according to the first candidate prediction block and an original picture of the current block to determine a second cost value of the first candidate transform kernel; and determining a cost result corresponding to the first candidate transform kernel according to the first cost value and the second cost value of the first candidate transform kernel, where the first candidate transform kernel is any one of the at least two candidate transform kernels.[ %3] In the embodiment of the present disclosure, for the transform kernel index number of the current block, the transform kernel index number may indicate the number of the transform kernel of the current block in the first candidate list. Here, the transform kernel index number of the current block may be a positive integer, for example, 1, 2, 3, 4, 5, 6, or the like. The transform kernel index number may be signalled directly in the bitstream, or may be signalled in the bitstream through the value of the first syntax element.[ %3] In one possible implementation, the transform kernel index number of the current block is determined. The transform kernel index number of the current block is encoded, and the obtained encoded bits are signalled in the bitstream.[ %3] In another possible implementation, the value of the first syntax element is determined, where the first syntax element indicates whether the current block uses a first transform mode and a transform kernel index number used for the first transform mode. The value of the first syntax element is encoded, and the obtained encoded bits are signalled in the bitstream.[ %3] It should also be noted that, in the embodiment of the present disclosure, the first transform mode may be LFNST / NSPT, and the first syntax element may be represented by lfnst_idx. Here, the first syntax element may indicate whether the current block uses the first transform mode, and a corresponding transform kernel index number when the current block uses the first transform mode. In this case, the value of the first syntax element may be 0, 1, 2, 3, 4, 5, 6, or the like.[ %3] In a specific embodiment, if the value of the first syntax element is the first value, it is determined that the current block does not use the first transform mode; if the value of the first syntax element is the second value, it is determined that the current block uses the first transform mode and the transform kernel index number used for the first transform mode. Here, the first value may be set to 0, and the second value may be set to a non-zero value, such as 1, 2, 3, 4, 5, 6, etc.[ %3] That is, in the embodiment of the present disclosure, for the LFNST / NSPT, the transform kernel index number of the current block may be indicated by lfnst_idx. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST / NSPT. In ECM, each transform kernel set of LFNST / NSPT has 3 transform kernels, so lfnst_idx equal to 1, 2, or 3 indicates that the current block uses the 1st, 2nd, or 3rd transform kernel of the selected transform kernel set for LFNST / NSPT, respectively.[ %3] In the embodiment of the present disclosure, if the prediction mode of the current block is a certain special intra prediction mode, it may select more than one transform kernel set. For example, if it has 2 optional transform kernel sets, then the possible values of lfnst_idx are 0, 1, 2, 3, 4, 5, 6. Here, 1, 2, 3 correspond to the 3 transform kernels of the first transform kernel set, and 4, 5, 6 correspond to the 3 transform kernels of the second transform kernel set.[ %3] In a specific embodiment, the binary symbol correspondence table of lfnst_idx is shown in the above-mentioned Table 7. Here, the third binary symbol, that is, the binary symbol in which BinIdx is 2, can also be understood as selecting the first candidate transform kernel set or the second candidate transform kernel set.[ %3] In another possible implementation, determining the transform kernel of the current block according to the first candidate list, the method may include: determining a transform kernel set of the current block according to the first candidate list; and determining the transform kernel of the current block according to the transform kernel set.[ %3] In the embodiment of the present disclosure, the transform kernel set here is one of the at least two candidate transform kernel sets indicated by the first candidate list, and here may be the transform kernel set determined by the texture feature index of the current block. In some embodiments, for determining the transform kernel set of the current block, the method may include: performing coding cost calculation on the current block according to the at least two candidate transform kernel sets indicated by the first candidate list to determine cost results, each corresponding to a respective one of the at least two candidate transform kernel sets; and determining a minimum cost result among the cost results, and determining a candidate transform kernel set corresponding to the minimum cost result as the transform kernel set of the current block.[ %3] Further, in some embodiments, the method further includes: determining a feature index number of the current block; and encoding the feature index number of the current block, and signalling obtained encoded bits in a bitstream.[ %3] Note that, in the embodiment of the present disclosure, the feature index number may indicate a number of the transform kernel set of the current block in the first candidate list. Here, the feature index number of the current block may be represented by lfnst_feature_idx. Here, the feature index number of the current block may be an integer greater than or equal to zero, such as 0, 1, 2, 3, 4, and the like. For example, if the first candidate list indicates two candidate transform kernel sets, then lfnst_feature_idx indicates which candidate transform kernel set is specifically selected. For example, if the value of lfnst_feature_idx is equal to 0, it indicates that the first candidate transform kernel set indicated by the first candidate list is selected; if the value of lfnst_feature_idx is equal to 1, it indicates that the second candidate transform kernel set indicated by the first candidate list is selected.[ %3] In some embodiments, after the transform kernel set of the current block is determine, determining the transform kernel of the current block may include: determining at least two candidate transform kernels included in the transform kernel set; performing coding cost calculation on the current block according to the at least two candidate transform kernels to determine cost results, each corresponding to a respective one of the at least two candidate transform kernels; and determining a minimum cost result among the cost results, and determining a candidate transform kernel corresponding to the minimum cost result as the transform kernel of the current block.[ %3] In a specific embodiment, performing coding cost calculation on the current block according to the at least two candidate transform kernels to determine the cost results, each corresponding to the respective one of the at least two candidate transform kernels may include: performing transform and quantization on the residual block of the current block based on a first candidate transform kernel to determine a first candidate quantization coefficient of the current block, and performing entropy coding on the first candidate quantization coefficient to determine a first cost value of the first candidate transform kernel; performing inverse quantization and inverse transform on the first candidate quantization coefficient to determine a first candidate residual block of the current block, and determining a first candidate prediction block of the current block according to the first candidate residual block; performing cost calculation according to the first candidate prediction block and an original picture of the current block to determine a second cost value of the first candidate transform kernel; and determining a cost result corresponding to the first candidate transform kernel according to the first cost value and the second cost value of the first candidate transform kernel, where the first candidate transform kernel is any one of the at least two candidate transform kernels.[ %3] In the embodiment of the present disclosure, for the transform kernel index number of the current block, the transform kernel index number may indicate the number of the transform kernel of the current block in the transform kernel set of the current block. Here, the transform kernel index number of the current block may be a positive integer, for example, 1, 2, 3, or the like. The transform kernel index number may be signalled directly in the bitstream, or may be signalled in the bitstream through the value of the first syntax element.[ %3] In one possible implementation, the transform kernel index number of the current block is determined. The transform kernel index number of the current block is encoded, and the obtained encoded bits are signalled in the bitstream.[ %3] In another possible implementation, the value of the first syntax element is determined, where the first syntax element indicates whether the current block uses a first transform mode and a transform kernel index number used for the first transform mode. The value of the first syntax element is encoded, and the obtained encoded bits are signalled in the bitstream.[ %3] It should also be noted that, in the embodiment of the present disclosure, the first transform mode may be LFNST / NSPT, and the first syntax element may be represented by lfnst_idx. Here, the first syntax element may indicate whether the current block uses the first transform mode, and a corresponding transform kernel index number when the current block uses the first transform mode. In this case, the value of the first syntax element may be 0, 1, 2, 3, or the like.[ %3] For example, in this case, for LFNST / NSPT, the transform kernel index number of the current block may also be represented by lfnst_idx. In VVC, lfnst_idx may have 3 values, namely 0, 1, and 2. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST. In VVC, each transform kernel set of LFNST has 2 transform kernels, so lfnst_idx equal to 1 or 2 indicates that the current block uses the 1st or 2nd transform kernel of the selected transform kernel set for LFNST, respectively. In the existing ECM, lfnst_idx may have 4 values, namely 0, 1, 2, and 3. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST / NSPT. In ECM, each transform kernel set of LFNST / NSPT has 3 transform kernels, so lfnst_idx equal to 1, 2, or 3 indicates that the current block uses the 1st, 2nd, or 3rd transform kernel of the selected transform kernel set for LFNST / NSPT, respectively.[ %3] In a specific embodiment, the binary symbol correspondence table of lfnst_idx is shown in the above-mentioned Table 8.[ %3] It should also be noted that in the embodiment of the present disclosure, when encoding the feature index number of the current block, the method may further include: in a case that the current block uses the first transform mode, encoding the feature index number of the current block and signalling obtained encoded bits in a bitstream. That is, when the prediction mode of the current block meets the first condition and lfnst_idx>0, the operation of encoding the feature index number of the current block and signalling the obtained encoded bits in the bitstream is performed.[ %3] At S3104, a residual block of the current block is determined, and the residual block of the current block is transformed according to the transform kernel to determine transform coefficients of the current block.[ %3] At S3105, the transform coefficients of the current block are encoded, and obtained encoded bits are signalled in a bitstream.[ %3] Note that, in the embodiment of the present disclosure, when encoding the transform coefficients of the current block, the method may include: quantizing the transform coefficients of the current block to determine quantization coefficients of the current block; and encoding the quantization coefficients of the current block, and signalling the obtained encoded bits in the bitstream.[ %3] It should also be noted that in the embodiment of the present disclosure, the "transform" of the residual block at the encoding end may also be referred to as "forward transform", and specifically refers to the transform from the spatial domain to the frequency domain to remove the correlation of the residual. It should be noted that if the standard only specifies decoding, then the "transform" in the standard text is the part of decoding, specifically referring to the "inverse transform" herein.[ %3] It should also be noted that, in the embodiment of the present disclosure, referring to FIG. 32, for operation S3104, the method may include operations as follows.[ %3] At S3201, intra prediction is performed on the current block to determine a prediction block of the current block.[ %3] At S3202, the residual block of the current block is determined according to an original block of the current block and the prediction block of the current block.[ %3] At S3203, the residual block of the current block is transformed according to the transform kernel to determine transform coefficients of the current block.[ %3] Note that, in the embodiment of the present disclosure, operations S3201 to S3202 may be operated in parallel with operations S3101 to S3103, may be executed before operations S3101 to S3103, or may be executed after operations S3101 to S3103, and the order of the operations is not specifically limited here.[ %3] It should also be noted that, in the embodiment of the present disclosure, after the prediction block of the current block is determined, a subtraction operation may be performed on the original block of the current block and the prediction block of the current block to determine the residual block of the current block.[ %3] It should also be noted that, in the embodiment of the present disclosure, when transforming the residual block of the current block according to the transform kernel to determine the transform coefficients of the current block, the method may include: performing non-separable primary transform on the residual block of the current block according to the transform kernel to determine the transform coefficients of the current block; or performing discrete cosine transform on the residual block of the current block to determine a transform block of the current block; and performing low frequency non-separable transform on the transform block of the current block according to the transform kernel to determine the transform coefficients of the current block.[ %3] In a specific embodiment, if the size parameter of the current block meets the first condition, non-separable primary transform is performed on the residual block of the current block according to the transform kernel to determine the transform coefficients of the current block. If the size parameter of the current block meets the second condition, discrete cosine transform is performed on the residual block of the current block to determine a transform block of the current block; and low frequency non-separable transform is performed on the transform block of the current block according to the transform kernel to determine the transform coefficients of the current block.[ %3] Here, the size parameter of the current block meets the first condition, which includes that the size parameter of the current block is relatively small, for example, the size parameter of the current block is less than a certain threshold. That is, for a block with a smaller size, the transform kernel of NSPT is used here, that is, NSPT transform is performed on the residual block of the current block according to the transform kernel to determine the transform coefficients of the current block.[ %3] Here, the size parameter of the current block meets the second condition, which includes that the size parameter of the current block is relatively large, for example, the size parameter of the current block is larger than a certain threshold. That is, for a larger-sized block, the transform kernel of LFNST is used here, that is, primary transform of DCT2 is performed on the residual block of the current block first, and then LFNST transform is performed on the transform block of the current block according to the transform kernel to determine the transform coefficients of the current block.[ %3] Briefly, after determining the prediction block, the encoder derives a candidate texture feature index according to the prediction block, and then determines the transform kernel set of NSPT / LFNST according to the candidate texture feature index. If a transform kernel set has multiple selectable transform kernels, the encoder attempts each of the transform kernels in the transform kernel set.[ %3] If it is the NSPT transform, NSPT may be applied to perform a forward transform on the residual block to obtain transform coefficients, the transform coefficients are quantized to obtain quantization coefficients, and then entropy coding is performed on the quantization coefficients. The cost of overhead in the bitstream under the transform kernel can be obtained through entropy coding. Inverse quantization is performed on the quantization coefficients to obtain decoded transform coefficients, and then inverse NSPT transform is performed on the decoded transform coefficients to obtain a decoded residual block. The decoded transform coefficients and the original transform coefficients may be different because the quantization is lossy, and likewise the decoded residual block and the original residual block may be different. A reconstructed block is obtained according to the decoded residual block and the prediction block. The cost of distortion can be obtained according to the reconstructed block and the original picture of the current block. The cost of encoding using the transform kernel of the current NSPT is the cost of overhead plus the cost of distortion. The costs of several transform kernels are compared, and the smallest one is selected as the best choice of NSPT of the current block.[ %3] If it is the LFNST transform, DCT2 may be applied to perform a forward transform on the residual block, then LFNST is applied to perform a forward transform to obtain transform coefficients, the transform coefficients are quantized to obtain quantization coefficients, and then entropy coding is performed on the quantization coefficients. The cost of overhead in the bitstream under the transform kernel can be obtained through entropy coding. Inverse quantization is performed on the quantization coefficients to obtain decoded transform coefficients, and then inverse LFNST transform is performed on the decoded transform coefficients, followed by inverse DCT2 transform to obtain a decoded residual block. The decoded transform coefficients and the original transform coefficients may be different because the quantization is lossy, and likewise the decoded residual block and the original residual block may be different. A reconstructed block is obtained according to the decoded residual block and the prediction block. The cost of distortion can be obtained according to the reconstructed block and the original picture of the current block. The cost of encoding using the transform kernel of the current NSPT is the cost of overhead plus the cost of distortion. The costs of several transform kernels are compared, and the smallest one is selected as the best choice of NSPT of the current block.[ %3] Additionally, in some embodiments, after operation S3101, the method may further include: determining a texture feature index of the current block in a case that the prediction mode of the current block does not meet the first condition; determining the transform kernel of the current block according to the texture feature index; and determining transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] Note that, in the embodiment of the present disclosure, determining the transform kernel of the current block according to the texture feature index may include: determining a transform kernel set of the current block according to the texture feature index; and determining the transform kernel of the current block according to the transform kernel set.[ %3] Note that, in the embodiment of the present disclosure, the prediction mode of the current block not meeting the first condition may include: the prediction mode of the current block is a prediction mode other than those in a first prediction mode set. Alternatively, it may be said that the prediction mode of the current block not meeting the first condition may include: the prediction mode of the current block is one of prediction modes in a second prediction mode set.[ %3] Note that, in the embodiment of the present disclosure, the second prediction mode set includes at least a DC mode, a PLANAR mode, an angular prediction mode, and a cross-component prediction mode.[ %3] It should also be noted that in the embodiment of the present disclosure, the modes in the second prediction mode set are relatively simple prediction modes. For example, a classification may be made, where the DC mode, the PLANAR mode, and the various angular prediction modes are classified into a first prediction mode set, and the DIMD mode, the TIMD mode, the MIP mode, the SGPM mode, the ITMP mode, and the IBC mode, etc., are classified into a second prediction mode set.[ %3] Exemplarily, the second prediction mode set may also include only one or more of a DIMD mode, the TIMD mode, the MIP mode, the SGPM mode, the ITMP mode, and the IBC mode. For example, the second prediction mode set includes the DIMD mode, the TIMD mode, and the SGPM mode. The other modes all belong to the first prediction mode set. The encoding method of the lfnst_idx of the first prediction mode set is the same as the method of the related art, while the encoding method of the lfnst_idx of the second prediction mode set is different from the method of the related art.[ %3] Exemplarily, each transform kernel set of the LFNST / NSPT has 3 transform kernels. A block using the first prediction mode set can only select one transform kernel set, while a block using the second prediction mode set can select two transform kernel sets, each having 3 transform kernels. If the prediction mode of the current block belongs to the first prediction mode set, it is only possible to select one texture feature index, then the possible values of lfnst_idx are 0, 1, 2, 3. If the prediction mode of the current block belongs to the second prediction mode set, then the possible values of lfnst_idx are 0, 1, 2, 3, 4, 5, 6. Here, 1, 2, 3 correspond to the 3 transform kernels of the transform kernel set corresponding to the first texture feature index, and 4, 5, 6 correspond to the 3 transform kernels of the transform kernel set corresponding to the second texture feature index. Here, the binary symbol correspondence table of the lfnst_idx of the block using the first prediction mode set is shown in Table 8, and the binary symbol correspondence table of the lfnst_idx of the block using the second prediction mode set is shown in Table 7.[ %3] In yet another embodiment of the present disclosure, an embodiment of the present disclosure provides a bitstream, where the bitstream is generated by bit encoding according to to-be-encoded information, where the to-be-encoded information may include at least one of: quantization coefficients of a current block, a transform kernel index number of the current block, a feature index number of the current block, a prediction mode of the current block, or a value of a first syntax element.[ %3] In the embodiment of the present disclosure, the first syntax element indicates whether the current block uses a first transform mode and a transform kernel index number used for the first transform mode. That is, the transform kernel index number of the current block may be determined by the value of the first syntax element. Here, if the value of the first syntax element is 0, it is determined that the current block does not use the first transform mode; if the value of the first syntax element is a non-zero value, it is determined that the current block uses the first transform mode and the transform kernel index number used for the first transform mode. For example, if the value of the first syntax element is 1, it is determined that the current block uses the first transform kernel. If the value of the first syntax element is 2, it is determined that the current block uses the second transform kernel. If the value of the first syntax element is 4, it is determined that the current block uses the fourth transform kernel or the like, and no limitation is made here.[ %3] The embodiment of the present disclosure provides an encoding method, in particular an intra LFNST / NSPT multi-angle selection scheme. First, a prediction mode of a current block is determined; a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; then, a transform kernel of the current block is determined according to the first candidate list; and a residual block of the current block is determined, and the residual block of the current block is transformed according to the transform kernel to determine transform coefficients of the current block; and the transform coefficients of the current block are encoded, and obtained encoded bits are signalled in a bitstream. In this way, when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance.[ %3] In yet another embodiment of the present disclosure, the LFNST / NSPT transform kernel index may be represented by a syntax element lfnst_idx in VVC and ECM based on the encoding and decoding method described in the above embodiments. In VVC, lfnst_idx may have 3 values, namely 0, 1, and 2. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST. In VVC, each transform kernel set of LFNST has 2 transform kernels, so lfnst_idx equal to 1 or 2 indicates that the current block uses the 1st or 2nd transform kernel of the selected transform kernel set for LFNST, respectively. In current ECM, lfnst_idx may have 4 values, namely 0, 1, 2, and 3. Here, lfnst_idx equal to 0 indicates that the current block does not use LFNST / NSPT. In ECM, each transform kernel set of LFNST / NSPT has 3 transform kernels, so lfnst_idx equal to 1, 2, or 3 indicates that the current block uses the 1st, 2nd, or 3rd transform kernel of the selected transform kernel set for LFNST / NSPT, respectively.[ %3] In the embodiment of the present disclosure, if the intra prediction mode of the current block is a certain special intra prediction mode, it may select more than one transform kernel set. One example is that it has 2 optional transform kernel sets. These particular intra prediction modes include, but are not limited to, DIMD, TIMD, MIP, SGPM, ITMP, IBC, and the like.[ %3] In a specific embodiment, a classification is made here, DC, PLANAR, various angular prediction modes are classified as a first prediction mode set, and DIMD, TIMD, MIP, SGPM, ITMP, IBC, etc., are classified as a second prediction mode set.[ %3] Each transform kernel set of the LFNST / NSPT has 3 transform kernels. A block using the first prediction mode set can only select one transform kernel set, while a block using the second prediction mode set can select two transform kernel sets, each having 3 transform kernels. If the prediction mode of the current block belongs to the first prediction mode set, it is only possible to select one texture feature, then the possible values of lfnst_idx are 0, 1, 2, 3. If the prediction mode of the current block belongs to the second prediction mode set, then the possible values of lfnst_idx are 0, 1, 2, 3, 4, 5, 6. Here, 1, 2, 3 correspond to the 3 transform kernels of the transform kernel set corresponding to the first texture feature index, and 4, 5, 6 correspond to the 3 transform kernels of the transform kernel set corresponding to the second texture feature index.[ %3] In the embodiment of the present disclosure, the binary symbol correspondence table of the lfnst_idx of the block using the first prediction mode set is shown in the above-described Table 8, and the binary symbol correspondence table of the lfnst_idx of the block using the second prediction mode set is shown in the above-described Table 7. Here, the third binary symbol, that is, the binary symbol whose BinIdx is 2, can also be understood as selecting the first candidate texture feature index or the second candidate texture feature index, or selecting the first candidate transform kernel set or the second candidate transform kernel set.[ %3] In another specific embodiment, the second prediction mode set may also include only one or several of DIMD, TIMD, MIP, SGPM, ITMP, and IBC. For example, the second prediction mode set includes DIMD, TIMD, and SGPM. The other modes all belong to the first prediction mode set. The encoding method of the lfnst_idx of the first prediction mode set is the same as the method of the related art, while the encoding method of the lfnst_idx of the second prediction mode set is different from the method of the related art.[ %3] It should also be noted that in the embodiment of the present disclosure, a special syntax element (such as lfnst_feature_idx) may be set, and the possible value of lfnst_feature_idx is 0 or 1, indicating which candidate texture feature or which candidate transform kernel set to be selected. If the intra prediction mode of the current block belongs to the second prediction mode set, and lfnst_idx>0, the lfnst_feature_idx is parsed, and the result is equivalent to the above-described implementation.[ %3] It can be understood that for the derivation of the candidate texture feature index, the embodiment of the present disclosure may use the reconstructed areas on the left and top sides of the current block to derive the candidate texture feature index, similar to the existing practice of DIMD. Because the reconstructed areas on the left and top sides are not the current block but are adjacent to the current block, for example, the texture may be continuous, so they can be used to estimate the texture of the current block to a certain extent. Another possibility is to use the prediction block of the current block to derive the candidate texture feature index, and another possibility is to use the prediction block of the current block and the reconstructed areas on the left and top sides of the current block simultaneously, so that more samples can be used to derive the candidate texture feature index.[ %3] In the embodiment of the present disclosure, the candidate texture feature index (or the candidate texture feature) herein may also be directly referred to as a candidate transform kernel set.[ %3] One derivation mode is to calculate gradients for all or some of the samples in the selected area. Generally, horizontal and vertical gradients can be calculated, and the sobel operator can be used to calculate the gradient. For a certain sample, the texture direction of the sample can be inferred from its horizontal and vertical gradients. For example, if the horizontal gradient is non-zero and the vertical gradient is zero, then the texture of the sample is vertical. Conversely, if the horizontal gradient is zero and the vertical gradient is non-zero, then the texture of the sample is horizontal. For example, if the horizontal gradient and the vertical gradient are equal and not zero, the texture of the sample is 45 degrees. Certainly, there are many other cases in which the horizontal gradient and the vertical gradient are not zero, and the direction of the texture of the sample can be determined according to their ratio. This can correspond to the corresponding intra prediction mode according to the gradient. An intra prediction mode statistical table is constructed, and the gradient magnitude of each calculated sample is accumulated into the corresponding intra prediction mode item in the statistical table. After the gradient statistics are completed, the intra prediction modes are sorted in descending order of the accumulated gradient magnitude. For the sake of complexity, it is possible to maintain only a single candidate texture feature list of length N, and the length of N may be 2, 3, 4, 5, ..., 10, etc.[ %3] In one possible implementation, an example of a sobel operator is as follows.[ %3] Operator for horizontal gradient:-101-202-101[ %3] Operator for vertical gradient:-1-2-1000121[ %3] Assuming the sample value at position (x, y) of the prediction block is , the horizontal gradient and vertical gradient are calculated as follows.(9)(10)[ %3] An example in which the gradient magnitude is denoted as amp is .[ %3] Deriving a virtual intra prediction mode from and can be achieved through table lookup. For example, if is equal to 0 and is not equal to 0, then there is a horizontal direction texture, corresponding to intra prediction mode 18 in VVC. If is equal to 0 and is not equal to 0, then there is a vertical direction texture, corresponding to intra prediction mode 50 in VVC. In the case that both are not equal to 0, if is equal to , and and have the same sign, that corresponds to intra prediction mode 34 in VVC. If is equal to twice , and and have the same sign, that corresponds to intra prediction mode 40 in VVC.[ %3] Other cases can be determined by looking up the table according to the same principle. DIMD also performs similar statistics to derive intra prediction modes. In implementation, some logic can be reused with DIMD.[ %3] According to the above method, a sorted intra prediction mode list of length N can be obtained. A candidate texture feature list is then generated. One optional operation is to prune the N intra prediction modes, i.e., to exclude intra prediction modes that are too close to each other. Taking the intra prediction mode in VVC as an example, the angles of some neighbouring intra prediction modes are very close. If two candidate texture features choose two very close angles, their differences are not obvious. Therefore, a threshold can be set, which represents the difference between the two intra prediction modes. For example, if the intra prediction mode with the largest gradient magnitude accumulation value is the first candidate texture feature candFeature0, when selecting the second candidate texture feature candFeature1, there needs to be a certain difference between candFeature1 and candFeature0, such as candFeature1 + THR < candFeature0 || candFeature1 - THR > candFeature0. If after checking all N-1 intra prediction modes, there is still no one meeting the requirements, one possible approach is to go back and set the second intra prediction mode in the sorted intra prediction mode list of length N to candFeature1. One possible approach is to add a default texture feature index. The THR may be 3, 4, 5, 6, etc. For the case where multiple neighbouring angles have high accumulation values, this method will preferentially select the angle with a certain degree of discrimination.[ %3] The above method does not consider some modes derived by DIMD, TIMD, SGPM, etc., themselves. For example, DIMD itself will derive one or several intra prediction modes for weighting, and TIMD itself will also derive one or several intra prediction modes for weighting, SGPM not only has two intra prediction modes, but also has a “partitioning" mode to find the corresponding intra prediction mode, and the residual often appears at the boundary area of the "partition". One possible method is to determine the candidate texture feature indices based on the modes derived by DIMD, TIMD, SGPM, etc., themselves and the modes derived by the above method.[ %3] In a specific embodiment, as follows.[ %3] For the DIMD mode, the first intra prediction mode derived by the DIMD is used as candFeature0.[ %3] For the TIMD mode, the first intra prediction mode derived by the TIMD is used as candFeature0.[ %3] For the SGPM mode, the intra prediction mode corresponding to the SGPM "partitioning" mode is used as candFeature0.[ %3] Then, candFeature1 is determined according to the above method. That is, among the intra prediction modes in the sorted intra prediction mode list of length N, starting from the first intra prediction mode, if a certain intra prediction mode meets the restriction of THR, it can be used as candFeature1.[ %3] For IBC, ITMP, etc., the prediction block, or the prediction block plus the template may be used to derive the candidate texture feature index.[ %3] If the samples used for deriving the list of N sorted intra prediction modes in the embodiment of the present disclosure are the same as the samples used by the DIMD, then the first intra prediction mode derived by the DIMD is the same as the first intra prediction mode derived by the embodiment of the present disclosure.[ %3] In another specific embodiment, as follows.[ %3] Since DIMD, TIMD, and SGPM can all derive more than one intra prediction mode, multiple modes derived by each mode can also be preferentially used to determine the candidate texture feature indices for these modes. When the modes derived by each mode cannot fill all the candidate texture feature indices, one possible method is to add a default texture feature index, and one possible method is to determine the candidate texture feature indices using the sorted intra prediction mode list of length N described above.[ %3] For example, for the DIMD mode, if it is weighted using the prediction values of multiple intra prediction modes during prediction, those multiple intra prediction modes used for weighting may be sequentially attempted as candidate texture feature indices.[ %3] For example, for the TIMD mode, if it is weighted using the prediction values of multiple intra prediction modes during prediction, those multiple intra prediction modes used for weighting may be sequentially attempted as candidate texture feature indices.[ %3] For example, for the SGPM mode, the intra prediction mode corresponding to the "partitioning" mode derived therefrom and the two intra prediction modes used for prediction may be sequentially attempted as candidate texture feature indices.[ %3] It should also be noted that LFNST / NSPT in the existing ECM has many transform kernel sets, so that neighbouring intra prediction modes all correspond to different transform kernel sets. A compromise in future standards is to appropriately reduce the number of transform kernel sets so that multiple intra prediction modes correspond to one transform kernel set. This is similar to VVC which uses 4 transform kernel sets, where multiple intra prediction modes with similar angles correspond to the same transform kernel set. The number of transform kernel sets in the subsequent standards may be 4 or other, such as 8, 12, etc. In the embodiment of the present disclosure, if multiple neighbouring intra prediction modes correspond to one transform kernel set, when determining the candidate texture features, it is necessary to ensure that the candidate texture features are not mapped to the same transform kernel set.[ %3] That is to say, the texture feature index described herein is to determine the transform kernel set, and the texture feature index can be used for easy understanding, or the transform kernel set can be directly used instead of the texture feature index.[ %3] It should also be noted that the number of samples for which gradients are calculated can be determined according to the size of the current block. Since the sobel operator needs to use the samples in the row and column on each of the top, bottom, left, and right sides of the current sample, it is possible to set not to calculate the gradients of the samples in the outermost row and column on each of the top, bottom, left, and right sides of the current block. If the current block is small, all samples for which gradients can be calculated are counted. If the current block is large, downsampling can be used for statistics, e.g., one sample out of every 2, 4, or 8 samples in the horizontal and / or vertical direction.[ %3] Exemplarily, if the size of the current block in either the horizontal or vertical direction is less than or equal to 8, gradient statistics are performed for all available samples in that direction. Otherwise, if the size of the current block in either the horizontal or vertical direction is less than or equal to 16, gradient statistics are performed for one out of every 2 samples in that direction. Otherwise, gradient statistics are performed for one out of every 4 samples in that direction.[ %3] In the embodiment of the present disclosure, the specific implementation of the aforementioned embodiment is described in detail through the aforementioned embodiment, and it can be seen from it that according to the technical solution of the aforementioned embodiment, the candidate texture feature index is provided for the block predicted by some special intra prediction mode here, and a "pruning" operation is also performed to exclude intra prediction modes that are too close to each other. In this way, for blocks predicted using certain special intra prediction modes among intra coded blocks, their prediction residual texture features are not as clear as those of ordinary intra prediction modes. Using the present technical solution to derive multiple candidate texture features to guide the transform can improve compression efficiency, thereby enhancing encoding and decoding performance.[ %3] In still another embodiment of the present disclosure, based on the same inventive concept as the above embodiments, FIG. 33 is a schematic structural diagram of an encoder provided by an embodiment of the present disclosure. As shown in FIG. 33, the encoder 330 may include a first determination unit 3301, a first transform unit 3302, and an encoding unit 3303.[ %3] The first determination unit 3301 is configured to: determine a prediction mode of a current block; and determine a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] The first determination unit 3301 is further configured to determine a transform kernel of the current block according to the first candidate list.[ %3] The first transform unit 3302 is configured to determine a residual block of the current block, and transform the residual block of the current block according to the transform kernel to determine transform coefficients of the current block.[ %3] The encoding unit 3303 is configured to encode the transform coefficients of the current block, and signal the obtained encoded bits in the bitstream.[ %3] In some embodiments, the prediction mode of the current block meeting the first condition includes: the prediction mode of the current block is one of a first prediction mode set; and the first prediction mode set includes at least a DIMD mode, a TIMD mode, an SGPM mode, a MIP mode, an ITMP mode, and an IBC mode.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine multiple candidate prediction modes; perform coding cost calculation on the current block according to the multiple candidate prediction modes to determine cost results, each corresponding to a respective one of the multiple candidate prediction modes; determine a minimum cost result among the cost results; and determine a candidate prediction mode corresponding to the minimum cost result as the prediction mode of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine one or more intra prediction modes derived from the prediction mode of the current block; and determine one or more candidate transform kernel sets according to the one or more intra prediction modes and add the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine a preset texture feature index of the current block in a case that the first candidate list is not full filled; and determine one or more candidate transform kernel sets according to the preset texture feature index and add the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine candidate samples for deriving a texture feature index in a case that the first candidate list is not full filled; determine a candidate texture feature list of the current block according to the candidate samples; and determine one or more candidate transform kernel sets according to the candidate texture feature list, and add the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine horizontal gradient values and vertical gradient values of the candidate samples; determine, according to the horizontal gradient values and the vertical gradient values of the candidate samples, a texture feature index and a gradient magnitude value corresponding to each of the candidate samples; construct a texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples; and determine the candidate texture feature list of the current block according to the texture feature statistical table.[ %3] In some embodiments, the first determination unit 3301 is further configured to determine the number of candidate samples according to the size parameter of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to determine a prediction block of the current block; and take at least some samples in the prediction block as the candidate samples.[ %3] In some embodiments, the first determination unit 3301 is further configured to determine neighbouring samples of a reconstructed area of the current block; and take the neighbouring samples of the reconstructed area as the candidate samples.[ %3] In some embodiments, the first determination unit 3301 is further configured to take the neighbouring samples of the reconstructed area and the at least some samples in the prediction block as the candidate samples.[ %3] In some embodiments, the first determination unit 3301 is further configured to: in a case that a number of the candidate samples is at least one, determine at least one texture feature index and at least one gradient magnitude value corresponding to the at least one texture feature index; determine at least one reference texture feature index having mutually distinct properties according to the at least one texture feature index, and perform an accumulation calculation on gradient magnitude values belonging to a same reference texture feature index according to the at least one gradient magnitude value to determine a gradient magnitude accumulation value corresponding to the at least one reference texture feature index; and construct the texture feature statistical table according to the at least one reference texture feature index and the gradient magnitude accumulation value corresponding to the at least one reference texture feature index.[ %3] In some embodiments, the first determination unit 3301 is further configured to: sort the texture feature statistical table in descending order of gradient magnitude accumulation values, and determine N reference texture feature indices, each corresponding to a respective one of N gradient magnitude accumulation values ranked at the front, where N is a positive integer; and add the N reference texture feature indices to the candidate texture feature list of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to prune N reference texture feature indices in the candidate texture feature list to determine the one or more candidate transform kernel sets of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; and in a case that a second condition is met between another reference texture feature index other than the reference texture feature index at the first position in the candidate texture feature list and an i-th candidate transform kernel set, determine an (i+1)-th candidate transform kernel set according to the another reference texture feature index to determine the one or more candidate transform kernel sets of the current block, where i is an integer greater than zero and less than N.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; in a case that a second condition is not met between all reference texture feature indices other than the reference texture feature index at the first position in the candidate texture feature list and the first candidate transform kernel set, determine a second candidate transform kernel set according to a reference texture feature index at a second position in the candidate texture feature list; and determine the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine a first candidate transform kernel set according to a first intra prediction mode derived from the prediction mode of the current block; in a case that a second condition is met between a first reference texture feature index in the candidate texture feature list and the first candidate transform kernel set, determine a second candidate transform kernel set according to the first reference texture feature index; and determine the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] In some embodiments, the first candidate list indicates the transform kernels included in the at least two transform kernel sets.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine at least two candidate transform kernels indicated by the first candidate list; perform coding cost calculation on the current block according to the at least two candidate transform kernels to determine cost results, each corresponding to a respective one of the at least two candidate transform kernels; and determine a minimum cost result among the cost results, and determine a candidate transform kernel corresponding to the minimum cost result as the transform kernel of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine a transform kernel set of the current block according to the first candidate list, where the transform kernel set is one of the at least two candidate transform kernel sets indicated by the first candidate list; and determine the transform kernel of the current block according to the transform kernel set.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine at least two candidate transform kernels included in the transform kernel set; perform coding cost calculation on the current block according to the at least two candidate transform kernels to determine cost results, each corresponding to a respective one of the at least two candidate transform kernels; and determine a minimum cost result among the cost results, and determine a candidate transform kernel corresponding to the minimum cost result as the transform kernel of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to: perform transform and quantization on the residual block of the current block based on a first candidate transform kernel to determine a first candidate quantization coefficient of the current block, and perform entropy coding on the first candidate quantization coefficient to determine a first cost value of the first candidate transform kernel; perform inverse quantization and inverse transform on the first candidate quantization coefficient to determine a first candidate residual block of the current block, and determine a first candidate prediction block of the current block according to the first candidate residual block; perform cost calculation according to the first candidate prediction block and an original picture of the current block to determine a second cost value of the first candidate transform kernel; and determine a cost result corresponding to the first candidate transform kernel according to the first cost value and the second cost value of the first candidate transform kernel, where the first candidate transform kernel is any one of the at least two candidate transform kernels.[ %3] In some embodiments, the first determination unit 3301 is further configured to determine a transform kernel index number of the current block, where the transform kernel index number indicates a number of the transform kernel of the current block in the first candidate list or a transform kernel set of the current block. The encoding unit 3303 is further configured to encode the transform kernel index number of the current block, and signal obtained encoded bits in a bitstream.[ %3] In some embodiments, the first determination unit 3301 is further configured to determine a value of a first syntax element, where the first syntax element indicates whether the current block uses a first transform mode and a transform kernel index number used for the first transform mode, and the transform kernel index number indicates a number of the transform kernel of the current block in the first candidate list or a transform kernel set of the current block. The encoding unit 3303 is further configured to encode the value of the first syntax element, and signal obtained encoded bits in a bitstream.[ %3] In some embodiments, the first determination unit 3301 is further configured to: perform coding cost calculation on the current block according to the at least two candidate transform kernel sets in the first candidate list to determine cost results, each corresponding to a respective one of the at least two candidate transform kernel sets; and determine a minimum cost result among the cost results, and determine a candidate transform kernel set corresponding to the minimum cost result as the texture feature index of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to determine a feature index number of the current block, where the feature index number indicates a number of the transform kernel set of the current block in the first candidate list. The encoding unit 3303 is further configured to encode the feature index number of the current block, and signal obtained encoded bits in a bitstream.[ %3] In some embodiments, the first determination unit 3301 is further configured to: determine a texture feature index of the current block in a case that the prediction mode of the current block does not meet the first condition; determine the transform kernel of the current block according to the texture feature index. The first transform unit 3302 is further configured to determine transform coefficients of the current block, and perform inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] In the embodiment of the present disclosure, the prediction mode of the current block not meeting the first condition includes: the prediction mode of the current block is a prediction mode other than those in a first prediction mode set.[ %3] In some embodiments, the prediction mode of the current block not meeting the first condition includes: the prediction mode of the current block is one of prediction modes in a second prediction mode set; and the second prediction mode set includes at least a DC mode, a PLANAR mode, an angular prediction mode, and a cross-component prediction mode.[ %3] In some embodiments, the first determination unit 3301 is further configured to perform intra prediction on the current block to determine a prediction block of the current block; and determine the residual block of the current block according to an original block of the current block and the prediction block of the current block.[ %3] In some embodiments, the first determination unit 3301 is further configured to quantize the transform coefficients of the current block to determine the quantization coefficients of the current block. The encoding unit 3303 is further configured to encode the quantization coefficients of the current block, and signal the obtained encoded bits in the bitstream.[ %3] In some embodiments, the first transform unit 3302 is further configured to: perform non-separable primary transform on the residual block of the current block according to the transform kernel to determine the transform coefficients of the current block; or perform discrete cosine transform on the residual block of the current block to determine a transform block of the current block; and perform low frequency non-separable transform on the transform block of the current block according to the transform kernel to determine the transform coefficients of the current block.[ %3] In some embodiments, the encoding unit 3303 is further configured to encode the prediction mode of the current block, and signal the obtained encoded bits in the bitstream.[ %3] It may be understood that in the embodiment of the disclosure, the "unit" may be a part of a circuit, a part of a processor, a part of a program or software, etc. Certainly, the "unit" may be a module, or may be non-modular. Furthermore, various components in the embodiment may be integrated into a processing unit, or each unit may physically exist separately, or two or more units may be integrated into a unit. The above integrated unit may be implemented in a form of hardware or in a form of software functional module.[ %3] If the integrated unit is implemented in a form of software functional module and is not sold or used as an independent product, the integrated unit may be stored in a computer-readable storage medium. Based on such understanding, the technical solution of the embodiment substantially, or parts making contributions to the related art, or all or part of the technical solution may be embodied in a form of software product, and the computer software product is stored in a storage medium, and includes several instructions configured to enable a computer device (which may be a personal computer, a server, a network device, etc.) or a processor to perform all or part of operations of the method described in the embodiment. The foregoing storage medium includes various media capable of storing program codes, such as a U disk, a mobile hard disk, a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk, etc.[ %3] Therefore, an embodiment of the disclosure provides a computer-readable storage medium, the computer-readable storage medium is applied to the encoder 330. The computer-readable storage medium has stored thereon a computer program, and when the computer program is executed by a first processor, the method described in any one of the foregoing embodiments is implemented.[ %3] Based on the composition of the encoder 330 and the computer-readable storage medium, FIG. 34 is a schematic diagram of a specific hardware structure of an encoder provided by an embodiment of the present disclosure. As shown in FIG. 34, the encoder 330 may include a first communication interface 3401, a first memory 3402 and a first processor 3403, various components are coupled together through a first bus system 3404. It may be understood that the first bus system 3404 is configured to achieve connection and communication between these components. The first bus system 3404 includes a power bus, a control bus and a status signal bus, besides a data bus. However, for the sake of clear explanations, various buses are marked as the first bus system 3404 in FIG. 34. Where[ %3] The first communication interface 3401 is configured to receive and send signals in a process of receiving / sending information from / to other external network elements.[ %3] The first memory 3402 is configured to store a computer program executable on the first processor 3403.[ %3] The first processor 3403 is configured to: when it executes the computer program, perform operations of: determining a prediction mode of a current block; determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; determining a transform kernel of the current block according to the first candidate list; and determining a residual block of the current block, and transforming the residual block of the current block according to the transform kernel to determine transform coefficients of the current block; and encoding the transform coefficients of the current block, and signalling obtained encoded bits in a bitstream.[ %3] It may be understood that the first memory 3402 in the embodiment of the disclosure may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memories. The non-volatile memory may be Read-Only Memory (ROM), Programmable ROM (PROM), Erasable PROM (EPROM), Electrically EPROM (EEPROM), or flash memory. The volatile memory may be a Random Access Memory (RAM) which serves as an external cache. Through an exemplary rather than limiting description, many forms of RAMs are available, such as a Static RAM (SRAM), a Dynamic RAM (DRAM), a Synchronous DRAM (SDRAM), a Double Data Rate SDRAM (DDRSDRAM), an Enhanced SDRAM (ESDRAM), a Synchlink DRAM (SLDRAM), and a Direct Rambus RAM (DRRAM). The first memory 3402 of the system and method described in the disclosure is intended to include, but is not limited to these memories and any other suitable types of memories.[ %3] The first processor 3403 may be an integrated circuit chip with a signal processing capability. During implementation, each operation of the above method may be completed by an integrated logical circuit in a form of hardware in the first processor 3403 or instructions in a form of software. The above first processor 3403 may be a general purpose processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logical devices, a discrete gate or transistor logical device, a discrete hardware component, etc. Various methods, operations and logic block diagrams disclosed in the embodiments of the disclosure may be implemented or performed. The general purpose processor may be a microprocessor, or the processor may be any conventional processor, etc. Operations in the methods disclosed in combination with the embodiments of the disclosure may be directly embodied as being performed and completed by a hardware decoding processor, or performed and completed by a combination of hardware in the decoding processor and software modules. The software modules may be located in random memory, flash memory, read-only memory, programmable read-only memory or electrically erasable programmable memory, registers and other storage medium mature in the art. The storage medium is located in the first memory 3402, and the first processor 3403 reads information in the first memory 3402, and completes the operations in the above methods in combination with the hardware thereof.[ %3] It may be understood that these embodiments described in the disclosure may be implemented by hardware, software, firmware, middleware, microcode or a combination thereof. As to implementation by hardware, the processing unit may be implemented in one or more ASICs, DSPs, DSP Devices (DSPDs), Programmable Logic Devices (PLDs), FPGAs, general purpose processors, controllers, microcontrollers, microprocessors, other electronic units configured to perform functions described in the disclosure, or combinations thereof. As to implementation by software, technologies described in the disclosure may be implemented by modules (such as processes, functions, etc.) performing the functions described in the disclosure. Software codes may be stored in a memory and executed by a processor. The memory may be implemented in or out of the processor.[ %3] Optionally, as another embodiment, the first processor 3403 is further configured to perform the method described in any one of the foregoing embodiments when it executes the computer program.[ %3] The present embodiment provides an encoder for which, both the encoding end and the decoding end first determine the prediction mode of the current block, and when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance.[ %3] In still another embodiment of the present disclosure, based on the same inventive concept as the above embodiments, FIG. 35 is a schematic structural diagram of a decoder provided by an embodiment of the present disclosure. As shown in FIG. 35, the decoder 350 may include a second determination unit 3501 and a second transform unit 3502.[ %3] The second determination unit 3501 is configured to: determine a prediction mode of a current block; and determine a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets.[ %3] The second determination unit 3501 is further configured to determine a transform kernel of the current block according to the first candidate list.[ %3] The second transform unit 3502 is configured to determine transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block.[ %3] In some embodiments, the prediction mode of the current block meeting the first condition includes: the prediction mode of the current block is one of a first prediction mode set; and the first prediction mode set includes at least a DIMD mode, a TIMD mode, an SGPM mode, a MIP mode, an ITMP mode, and an IBC mode.[ %3] In some embodiments, referring to FIG. 35, the decoder 350 further includes a decoding unit 3503 configured to decode the bitstream to determine the prediction mode of the current block.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine one or more intra prediction modes derived from the prediction mode of the current block; and determine one or more candidate transform kernel sets according to the one or more intra prediction modes and add the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine a preset texture feature index of the current block in a case that the first candidate list is not full filled; and determine one or more candidate transform kernel sets according to the preset texture feature index and add the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine candidate samples for deriving a texture feature index in a case that the first candidate list is not full filled; determine a candidate texture feature list of the current block according to the candidate samples; and determine one or more candidate transform kernel sets according to the candidate texture feature list, and add the one or more candidate transform kernel sets to the first candidate list.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine horizontal gradient values and vertical gradient values of the candidate samples; determine, according to the horizontal gradient values and the vertical gradient values of the candidate samples, a texture feature index and a gradient magnitude value corresponding to each of the candidate samples; construct a texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples; and determine the candidate texture feature list of the current block according to the texture feature statistical table.[ %3] In some embodiments, the second determination unit 3501 is further configured to determine the number of candidate samples according to the size parameter of the current block.[ %3] In some embodiments, the second determination unit 3501 is further configured to determine a prediction block of the current block; and take at least some samples in the prediction block as the candidate samples.[ %3] In some embodiments, the second determination unit 3501 is further configured to determine neighbouring samples of a reconstructed area of the current block; and take the neighbouring samples of the reconstructed area as the candidate samples.[ %3] In some embodiments, the second determination unit 3501 is further configured to take the neighbouring samples of the reconstructed area and the at least some samples in the prediction block as the candidate samples.[ %3] In some embodiments, the second determination unit 3501 is further configured to: in a case that a number of the candidate samples is at least one, determine at least one texture feature index and at least one gradient magnitude value corresponding to the at least one texture feature index; determine at least one reference texture feature index having mutually distinct properties according to the at least one texture feature index, and perform an accumulation calculation on gradient magnitude values belonging to a same reference texture feature index according to the at least one gradient magnitude value to determine a gradient magnitude accumulation value corresponding to the at least one reference texture feature index; and construct the texture feature statistical table according to the at least one reference texture feature index and the gradient magnitude accumulation value corresponding to the at least one reference texture feature index.[ %3] In some embodiments, the second determination unit 3501 is further configured to: sort the texture feature statistical table in descending order of gradient magnitude accumulation values, and determine N reference texture feature indices, each corresponding to a respective one of N gradient magnitude accumulation values ranked at the front, where N is a positive integer; and add the N reference texture feature indices to the candidate texture feature list of the current block.[ %3] In some embodiments, the second determination unit 3501 is further configured to prune N reference texture feature indices in the candidate texture feature list to determine the one or more candidate transform kernel sets of the current block.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; and in a case that a second condition is met between another reference texture feature index other than the reference texture feature index at the first position in the candidate texture feature list and an i-th candidate transform kernel set, determine an (i+1)-th candidate transform kernel set according to the another reference texture feature index to determine the one or more candidate transform kernel sets of the current block, where i is an integer greater than zero and less than N.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine a first candidate transform kernel set according to a reference texture feature index at a first position in the candidate texture feature list; in a case that a second condition is not met between all reference texture feature indices other than the reference texture feature index at the first position in the candidate texture feature list and the first candidate transform kernel set, determine a second candidate transform kernel set according to a reference texture feature index at a second position in the candidate texture feature list; and determine the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine a first candidate transform kernel set according to a first intra prediction mode derived from the prediction mode of the current block; in a case that a second condition is met between a first reference texture feature index in the candidate texture feature list and the first candidate transform kernel set, determine a second candidate transform kernel set according to the first reference texture feature index; and determine the first candidate list according to the first candidate transform kernel set and the second candidate transform kernel set.[ %3] In some embodiments, the first candidate list indicates the transform kernels included in the at least two transform kernel sets.[ %3] In some embodiments, the second determination unit 3501 is further configured to determine the transform kernel index number of the current block; and determine the transform kernel of the current block according to the first candidate list and the transform kernel index number.[ %3] In some embodiments, the decoding unit 3503 is further configured to decode a bitstream to determine a feature index number of the current block. The second determination unit 3501 is further configured to determine a transform kernel set of the current block according to the first candidate list and the feature index number, where the transform kernel set is one of the at least two candidate transform kernel sets indicated by the first candidate list; and determine the transform kernel of the current block according to the transform kernel set.[ %3] In some embodiments, the second determination unit 3501 is further configured to determine the transform kernel index number of the current block; and determine the transform kernel of the current block according to the transform kernel set and the transform kernel index number.[ %3] In some embodiments, the decoding unit 3503 is further configured to decode the bitstream to determine the transform kernel index number of the current block.[ %3] In some embodiments, the decoding unit 3503 is further configured to decode the bitstream to determine the value of the first syntax element. The second determination unit 3501 is further configured to determine the transform kernel index number of the current block according to the value of the first syntax element in a case that the first syntax element indicates that the current block uses a first transform mode.[ %3] In some embodiments, the second determination unit 3501 is further configured to: determine a texture feature index of the current block in a case that the prediction mode of the current block does not meet the first condition; determine the transform kernel of the current block according to the texture feature index. The second transform unit 3502 is further configured to determine transform coefficients of the current block, and perform inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] In some embodiments, the second determination unit 3501 is further configured to determine a transform kernel set of the current block according to the texture feature index; decode a bitstream to determine a transform kernel index number of the current block; and determine the transform kernel of the current block according to the transform kernel set and the transform kernel index number.[ %3] In the embodiment of the present disclosure, the prediction mode of the current block not meeting the first condition includes: the prediction mode of the current block is a prediction mode other than those in a first prediction mode set.[ %3] In some embodiments, the prediction mode of the current block not meeting the first condition includes: the prediction mode of the current block is one of prediction modes in a second prediction mode set; and the second prediction mode set includes at least a DC mode, a PLANAR mode, an angular prediction mode, and a cross-component prediction mode.[ %3] In some embodiments, the decoding unit 3503 is further configured to decode a bitstream to determine quantization coefficients of the current block. The second determination unit 3501 is further configured to perform inverse quantization on the quantization coefficients of the current block to determine the transform coefficients of the current block.[ %3] In some embodiments, the second transform unit 3502 is further configured to: perform inverse transform of non-separable primary transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block; or perform inverse transform of low frequency non-separable transform on the transform coefficients of the current block according to the transform kernel to determine a transform block of the current block; and perform inverse transform of discrete cosine transform on the transform block of the current block to determine the residual block of the current block.[ %3] In some embodiments, the second determination unit 3501 is further configured to perform intra prediction on the current block to determine a prediction block of the current block; and determine a reconstructed block of the current block according to the prediction block of the current block and the residual block of the current block.[ %3] It may be understood that in the embodiment, the "unit" may be a part of a circuit, a part of a processor, a part of a program or software, etc. Of course, the "unit" may be a module, or may be non-modular. Furthermore, various components in the embodiment may be integrated into a processing unit, or each unit may physically exist separately, or two or more units may be integrated into a unit. The above integrated unit may be implemented in a form of hardware or in a form of software functional module.[ %3] If the integrated unit is implemented in a form of software functional module and is not sold or used as an independent product, the integrated unit may be stored in a computer-readable storage medium. Based on such understanding, the embodiment provides a computer-readable storage medium, the computer-readable storage medium is applied to the decoder 350. The computer-readable storage medium has stored thereon a computer program, and when the computer program is executed by a second processor, the method described in any one of the foregoing embodiments is implemented.[ %3] Based on the composition of the decoder 350 and the computer-readable storage medium, FIG. 36 is a schematic diagram of a specific hardware structure of a decoder provided by an embodiment of the present disclosure. As shown in FIG. 36, the decoder 350 may include a second communication interface 3601, a second memory 3602 and a second processor 3603, various components are coupled together through a second bus system 3604. It may be understood that the second bus system 3604 is configured to achieve connection and communication between these components. The second bus system 3604 includes a power bus, a control bus and a status signal bus, besides a data bus. However, for the sake of clear explanations, various buses are marked as the second bus system 3604 in FIG. 36. Where[ %3] The second communication interface 3601 is configured to receive and send signals in a process of receiving / sending information from / to other external network elements.[ %3] The second memory 3602 is configured to store a computer program executable on the second processor 3603.[ %3] The second processor 3603 is configured to: when it executes the computer program, perform operations of: determining a prediction mode of a current block; determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; determining a transform kernel of the current block according to the first candidate list; and determining transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block.[ %3] Optionally, as another embodiment, the second processor 3603 is further configured to perform the method described in any one of the foregoing embodiments when it executes the computer program.[ %3] It may be understood that hardware functions of the second memory 3602 are similar to those of the first memory 3402, and hardware functions of the second processor 3603 are similar to those of the first processor 3403, which will not be described in detail here.[ %3] The present embodiment provides a decoder for which, both the encoding end and the decoding end first determine the prediction mode of the current block, and when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance.[ %3] In yet another embodiment of the disclosure, FIG. 37 is a schematic structural diagram of an encoding and decoding system according to an embodiment of the present disclosure. As shown in FIG. 37, the encoding and decoding system 370 may include an encoder 3701 and a decoder 3702.[ %3] In the embodiment of the disclosure, the encoder 3701 may be the encoder described in any one of the foregoing embodiments, and the decoder 3702 may be the decoder described in any one of the foregoing embodiments.[ %3] It should be noted that in the disclosure, terms "include", "include" or any other variants thereof are intended to encompass a non-exclusive inclusion, such that a process, method, article or apparatus including a series of elements includes not only those elements, but also other elements which are not explicitly listed, or elements inherent to such process, method, article or apparatus. Without further limitation, an element defined by a statement "including a..." does not preclude presence of additional identical elements in a process, method, article or apparatus including the element.[ %3] The above serial numbers of the embodiments of the disclosure are only for the purpose of descriptions, and do not represent advantages and disadvantages of the embodiments.[ %3] The methods disclosed in several method embodiments provided in the disclosure may be arbitrarily combined without conflict, to obtain new method embodiments.[ %3] The features disclosed in several product embodiments provided in the disclosure may be arbitrarily combined without conflict, to obtain new product embodiments.[ %3] The features disclosed in several method or device embodiments provided in the disclosure may be arbitrarily combined without conflict, to obtain new method or device embodiments.[ %3] The above descriptions are only specific implementations of the disclosure, however, the scope of protection of the disclosure is not limited thereto. Variation or replacement easily conceived by any technician familiar with this technical field within the technical scope disclosed in the disclosure, should fall within the scope of protection of the disclosure. Therefore, the scope of protection of the disclosure should be subject to the scope of protection of the claims. Industrial Applicability[ %3] In the embodiments of the present disclosure, at the coding end, a prediction mode of a current block is determined; a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; a transform kernel of the current block is determined according to the first candidate list; and a residual block of the current block is determined, and the residual block of the current block is transformed according to the transform kernel to determine transform coefficients of the current block; and the transform coefficients of the current block are encoded, and obtained encoded bits are signalled in a bitstream. At the coding end, a prediction mode of a current block is determined; a first candidate list of the current block is determined in a case that a prediction mode of the current block meets a first condition, where the first candidate list indicates at least two candidate transform kernel sets; a transform kernel of the current block is determined according to the first candidate list; and transform coefficients of the current block are determined, and inverse transform is performed on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block. In this way, both the encoding end and the decoding end first determine the prediction mode of the current block, and when the prediction mode of the current block meets the first condition, it is necessary to determine a first candidate list indicating at least two candidate transform kernel sets at this time, and then determine the transform kernel of the current block according to the at least two candidate transform kernel sets. That is, for the current block predicted using certain intra prediction modes, when determining the transform kernel of the current block, the transform kernel of the current block is no longer determined according to only one transform kernel set, but is determined using at least two candidate transform kernel sets, which improves the accuracy of the transform, thereby improving the compression efficiency and further improving the encoding and decoding performance.

Claims

1. A method for decoding, applied to a decoder, the method comprising:determining a prediction mode of a current block;determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, wherein the first candidate list indicates at least two candidate transform kernel sets;determining a transform kernel of the current block according to the first candidate list; anddetermining transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block. 2. The method of claim 1, wherein the prediction mode of the current block meeting the first condition comprises: the prediction mode of the current block is one of a first prediction mode set; andthe first prediction mode set comprises at least one of: a Decoder-side Intra Mode Derivation (DIMD) mode, a Template-based Intra Mode Derivation (TIMD) mode, a Spatial Geometric Partitioning Mode (SGPM), a Matrix-based Intra Prediction (MIP) mode, an Intra Template Matching Prediction (ITMP) mode, or an Intra Block Copy (IBC) mode. 3. The method of claim 1, wherein determining the first candidate list of the current block comprises:determining one or more intra prediction modes derived from the prediction mode of the current block; anddetermining one or more candidate transform kernel sets according to the one or more intra prediction modes and adding the one or more candidate transform kernel sets to the first candidate list. 4. The method of claim 3, further comprising:determining a preset texture feature index of the current block in a case that the first candidate list is not full filled; anddetermining one or more candidate transform kernel sets according to the preset texture feature index and adding the one or more candidate transform kernel sets to the first candidate list. 5. The method of claim 3, further comprising:determining candidate samples for deriving a texture feature index in a case that the first candidate list is not full filled;determining a candidate texture feature list of the current block according to the candidate samples; anddetermining one or more candidate transform kernel sets according to the candidate texture feature list, and adding the one or more candidate transform kernel sets to the first candidate list. 6. The method of claim 5, wherein determining the candidate texture feature list of the current block according to the candidate samples comprises:determining horizontal gradient values and vertical gradient values of the candidate samples;determining, according to the horizontal gradient values and the vertical gradient values of the candidate samples, a texture feature index and a gradient magnitude value corresponding to each of the candidate samples;constructing a texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples; anddetermining the candidate texture feature list of the current block according to the texture feature statistical table. 7. The method of claim 5, further comprising:determining a number of the candidate samples according to a size parameter of the current block. 8. The method of claim 5, further comprising:determining a prediction block of the current block; andtaking at least some samples in the prediction block as the candidate samples. 9. The method of claim 8, further comprising:determining neighbouring samples of a reconstructed area of the current block; andtaking the neighbouring samples of the reconstructed area as the candidate samples. 10. The method of claim 6, wherein constructing the texture feature statistical table according to the texture feature index and the gradient magnitude value corresponding to each of the candidate samples comprises:in a case that a number of the candidate samples is at least one, determining at least one texture feature index and at least one gradient magnitude value corresponding to the at least one texture feature index;determining at least one reference texture feature index having mutually distinct properties according to the at least one texture feature index, and performing an accumulation calculation on gradient magnitude values belonging to a same reference texture feature index according to the at least one gradient magnitude value to determine a gradient magnitude accumulation value corresponding to the at least one reference texture feature index; andconstructing the texture feature statistical table according to the at least one reference texture feature index and the gradient magnitude accumulation value corresponding to the at least one reference texture feature index. 11. The method of claim 10, wherein determining the candidate texture feature list of the current block according to the texture feature statistical table comprises:sorting the texture feature statistical table in descending order of gradient magnitude accumulation values, and determining N reference texture feature indices, each corresponding to a respective one of N gradient magnitude accumulation values ranked at the front, wherein N is a positive integer; andadding the N reference texture feature indices to the candidate texture feature list of the current block. 12. The method of claim 1, wherein the first candidate list indicates transform kernels comprised in the at least two candidate transform kernel sets. 13. The method of claim 12, wherein determining the transform kernel of the current block according to the first candidate list comprises:determining a transform kernel index number of the current block; anddetermining the transform kernel of the current block according to the first candidate list and the transform kernel index number. 14. The method of claim 1, wherein determining the transform kernel of the current block according to the first candidate list comprises:decoding a bitstream to determine a feature index number of the current block;determining a transform kernel set of the current block according to the first candidate list and the feature index number, wherein the transform kernel set is one of the at least two candidate transform kernel sets indicated by the first candidate list; anddetermining the transform kernel of the current block according to the transform kernel set. 15. The method of claim 1, further comprising:determining a texture feature index of the current block in a case that the prediction mode of the current block does not meet the first condition;determining the transform kernel of the current block according to the texture feature index; anddetermining transform coefficients of the current block, and performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine a residual block of the current block. 16. The method of claim 15, wherein determining the transform kernel of the current block according to the texture feature index comprises:determining a transform kernel set of the current block according to the texture feature index;decoding a bitstream to determine a transform kernel index number of the current block; anddetermining the transform kernel of the current block according to the transform kernel set and the transform kernel index number. 17. The method of claim 15, wherein the prediction mode of the current block not meeting the first condition comprises: the prediction mode of the current block is one of prediction modes in a second prediction mode set; andthe second prediction mode set comprises at least one of: a Direct Current (DC) mode, a PLANAR mode, an angular prediction mode, or a cross-component prediction mode. 18. The method of claim 1, wherein performing inverse transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block comprises:performing inverse transform of non-separable primary transform on the transform coefficients of the current block according to the transform kernel to determine the residual block of the current block; orperforming inverse transform of low frequency non-separable transform on the transform coefficients of the current block according to the transform kernel to determine a transform block of the current block; and performing inverse transform of discrete cosine transform on the transform block of the current block to determine the residual block of the current block. 19. A method for encoding, applied to an encoder, the method comprising:determining a prediction mode of a current block;determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, wherein the first candidate list indicates at least two candidate transform kernel sets;determining a transform kernel of the current block according to the first candidate list; anddetermining a residual block of the current block, and transforming the residual block of the current block according to the transform kernel to determine transform coefficients of the current block; andencoding the transform coefficients of the current block, and signalling obtained encoded bits in a bitstream. 20. A computer-readable storage medium, having a computer program and a bitstream stored thereon, wherein the computer program, when executed by a processor, enables the processor to perform operations to generate the bitstream, wherein the operations comprise:determining a prediction mode of a current block;determining a first candidate list of the current block in a case that a prediction mode of the current block meets a first condition, wherein the first candidate list indicates at least two candidate transform kernel sets;determining a transform kernel of the current block according to the first candidate list; anddetermining a residual block of the current block, and transforming the residual block of the current block according to the transform kernel to determine transform coefficients of the current block; andencoding the transform coefficients of the current block, and signalling obtained encoded bits in the bitstream.