WO2019075638A1 - Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations - Google Patents

Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations Download PDF

Info

Publication number
WO2019075638A1
WO2019075638A1 PCT/CN2017/106547 CN2017106547W WO2019075638A1 WO 2019075638 A1 WO2019075638 A1 WO 2019075638A1 CN 2017106547 W CN2017106547 W CN 2017106547W WO 2019075638 A1 WO2019075638 A1 WO 2019075638A1
Authority
WO
WIPO (PCT)
Prior art keywords
mode
target
coding
decoding
binarized
Prior art date
Application number
PCT/CN2017/106547
Other languages
English (en)
Chinese (zh)
Inventor
张贤国
范娟婷
朱政
张二丽
金星
Original Assignee
北京金山云网络技术有限公司
北京金山云科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京金山云网络技术有限公司, 北京金山云科技有限公司 filed Critical 北京金山云网络技术有限公司
Priority to CN201780006030.5A priority Critical patent/CN108702521B/zh
Priority to PCT/CN2017/106547 priority patent/WO2019075638A1/fr
Publication of WO2019075638A1 publication Critical patent/WO2019075638A1/fr

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/90Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using coding techniques not provided for in groups H04N19/10-H04N19/85, e.g. fractals
    • H04N19/96Tree coding, e.g. quad-tree coding
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/102Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or selection affected or controlled by the adaptive coding
    • H04N19/124Quantisation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/136Incoming video signal characteristics or properties
    • H04N19/14Coding unit complexity, e.g. amount of activity or edge presence estimation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • H04N19/176Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object the region being a block, e.g. a macroblock
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/186Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a colour or a chrominance component
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/44Decoders specially adapted therefor, e.g. video decoders which are asymmetric with respect to the encoder
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/60Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding
    • H04N19/61Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding in combination with predictive coding
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/80Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation
    • H04N19/82Details of filtering operations specially adapted for video compression, e.g. for pixel interpolation involving filtering within a prediction loop
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/85Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression
    • H04N19/86Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using pre-processing or post-processing specially adapted for video compression involving reduction of coding artifacts, e.g. of blockiness
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/90Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using coding techniques not provided for in groups H04N19/10-H04N19/85, e.g. fractals
    • H04N19/91Entropy coding, e.g. variable length coding [VLC] or arithmetic coding

Definitions

  • the present application relates to the field of video coding technologies, and in particular, to an SAO type coding and decoding method, apparatus, encoder, decoder, and storage medium.
  • SAO Sample Adaptive Offset
  • HEVC High Efficiency Video Coding
  • the SAO types include: skip mode, EO (Edge Offset) mode, and BO (Band Offset) mode. Since a CTU (Coding Tree Unit) includes a luma coding tree block and a plurality of chroma coding tree blocks, the coding of the SAO type for the CTU in the related art can be understood as each of the CTUs. Coding performed by a coding tree block (CTB, Coding Tree Block).
  • CTB Coding Tree Block
  • the encoder determines the SAO type applied by a CTB, it needs to encode the determined SAO type, and then add the encoded SAO type to the video code stream.
  • the SAO type is encoded in the related art, there is still a problem that the video coding efficiency is low in the related art.
  • the application provides an encoding and decoding method, device, encoder, decoder and storage medium to improve video encoding efficiency.
  • an embodiment of the present application provides an SAO type encoding method, where the method includes:
  • the target binarization corresponding to the target SAO type is determined according to the correspondence between each SAO type and the binarized character string recorded in the preset first coding rule. a string in which the first encoding rule records each SAO type and two The correspondence between the valued strings and the entropy encoding of the binarized strings;
  • the first coding rule is determined according to any one of the following coding principles:
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy coding mode for distinguishing the bits corresponding to the binarized character string of the EO mode and the BO mode respectively is based on the context model The encoding method.
  • the first coding rule is determined according to any one of a first coding principle, a second coding principle, and a third coding principle;
  • the third coding principle is that the entropy coding mode of each bit in the binarized character string is an equal probability coding mode.
  • the foregoing method also includes:
  • the preset execution condition is: a condition for indicating that the prediction transform accuracy of the target coding tree unit CTU to which the target CTB belongs is low;
  • the step of determining the target binarized character string corresponding to the target SAO type according to the correspondence between each SAO type and the binarized character string recorded in the preset first encoding rule is performed.
  • the foregoing step of determining whether the preset execution condition is met includes:
  • the target image is an image in which the target CTU is located.
  • the foregoing step of determining, according to the target image, whether the preset execution condition is met includes:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the foregoing step of determining whether the preset execution condition is met includes:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the step of determining whether the preset execution condition is met, according to at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs includes:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the foregoing step of determining whether the preset execution condition is met includes:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • the first coding rule determined according to the first coding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized string is based on the context model. the way.
  • the first coding rule determined according to the first coding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • the first coding rule determined according to the first coding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each binarized string, the first bit of the binarized string.
  • the coding mode is equal probability coding.
  • the binarized character string further includes the second bit, the coding mode of the second bit of the binarized character string is based on the context model. .
  • the first coding rule determined according to the second coding principle includes:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is based on the context model. the way.
  • an embodiment of the present application provides a method for decoding an SAO type, where the method includes:
  • the target SAO type corresponding to the target binarized character string is determined according to the correspondence between each SAO type and the binarized character string recorded in the first decoding rule.
  • the first decoding rule is determined according to any one of the following decoding principles:
  • the first decoding principle the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode;
  • the second decoding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy decoding method for distinguishing the bits corresponding to the encoded binarized character string respectively for the EO mode and the BO mode is based on The way the context model is decoded.
  • the first decoding rule is determined according to any one of a first decoding principle, a second decoding principle, and a third decoding principle;
  • the third decoding principle is that the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode.
  • the encoded binarized string recorded in the foregoing first decoding rule according to the preset further includes:
  • the preset execution condition being: indicating the prediction transformation accuracy of the target coding tree unit CTU to which the target CTB belongs Low condition
  • entropy decoding mode of the encoded binarized character string recorded in the preset first decoding rule If the entropy decoding mode of the encoded binarized character string recorded in the preset first decoding rule is performed, entropy decoding the encoded target binarized character string corresponding to the target coding tree block CTB is performed. The step of the target binarizing the string.
  • the foregoing step of determining whether the preset execution condition is met includes:
  • the target image is an image in which the target CTU is located.
  • the foregoing step of determining, according to the target image, whether the preset execution condition is met includes:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the foregoing step of determining whether the preset execution condition is met includes:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the step of determining whether the preset execution condition is met, according to at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs includes:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the foregoing step of determining whether the preset execution condition is met includes:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • the first decoding rule determined according to the first decoding principle includes:
  • Decoding rules the binarized strings corresponding to EO mode, skip mode and BO mode are 0, 10, 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model The way to decode.
  • the first decoding rule determined according to the first decoding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. The way.
  • the first decoding rule determined according to the first decoding principle includes:
  • Decoding rules the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each encoded binarized string, the encoded binary string is
  • the decoding mode of one bit is a method of equal probability decoding, and in the case where the encoded binarized character string further includes the second bit, the decoding of the second bit of the encoded binarized character string
  • the mode is a context model based decoding method.
  • the first decoding rule determined according to the second decoding principle includes:
  • Decoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model. The way to decode.
  • an SAO type encoding apparatus where the apparatus includes:
  • a first determining module configured to: according to the target SAO type of the target coding tree block CTB, according to the correspondence between each SAO type and the binarized character string recorded in the preset first coding rule, Determining a target binarized character string corresponding to the target SAO type, wherein the first encoding rule records a correspondence between each SAO type and the binarized character string, and an entropy encoding mode of the binarized character string;
  • An entropy coding module configured to perform entropy coding on a target binarized character string according to an entropy coding manner of the binarized character string recorded in the first coding rule, to obtain an encoding result corresponding to the target SAO type;
  • the first coding rule is determined according to any one of the following coding principles:
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy coding mode for distinguishing the bits corresponding to the binarized character string of the EO mode and the BO mode respectively is based on the context model The encoding method.
  • the first coding rule is determined according to any one of a first coding principle, a second coding principle, and a third coding principle;
  • the third coding principle is that the entropy coding mode of each bit in the binarized character string is an equal probability coding mode.
  • the foregoing apparatus further includes:
  • a first determining module configured to determine whether a preset execution condition is met after determining a target SAO type of the target coding tree block CTB, where the preset execution condition is: a prediction used to indicate a target coding tree unit CTU to which the target CTB belongs a condition with low conversion accuracy;
  • the first determining module is specifically configured to:
  • the target binarization corresponding to the target SAO type is determined according to the correspondence between each SAO type and the binarized character string recorded in the preset first encoding rule. String.
  • the foregoing first determining module is specifically configured to:
  • the target image is an image in which the target CTU is located.
  • the foregoing first determining module is specifically configured to:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the foregoing first determining module is specifically configured to:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the foregoing first determining module is specifically configured to:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the foregoing first determining module is specifically configured to:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • the first coding rule determined according to the first coding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized string is based on the context model. the way.
  • the first coding rule determined according to the first coding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • the first coding rule determined according to the first coding principle includes:
  • the binarized strings corresponding to EO mode, skip mode, and BO mode are 0, respectively. 10, 11; and for each binarized string, the first bit of the binarized string is encoded in an equal probability encoding manner, and the binarized string further includes a second bit In the case of the second bit of the binarized character string, the encoding method based on the context model is used.
  • the first coding rule determined according to the second coding principle includes:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is based on the context model. the way.
  • an embodiment of the present application provides a decoding apparatus of the SAO type, where the apparatus includes:
  • An entropy decoding module configured to entropy decode the encoded target binarized character string corresponding to the target coding tree block CTB according to an entropy decoding manner of the encoded binarized character string recorded in the preset first decoding rule, Obtaining a target binarized character string; wherein the first decoding rule records an entropy decoding manner of the encoded binarized character string, and a correspondence relationship between each SAO type and the binarized character string;
  • the second determining module is configured to determine, according to the correspondence between each SAO type and the binarized character string recorded in the first decoding rule, the target SAO type corresponding to the target binarized character string.
  • the first decoding rule is determined according to any one of the following decoding principles:
  • the first decoding principle the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode;
  • the second decoding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy decoding method for distinguishing the bits corresponding to the encoded binarized character string respectively for the EO mode and the BO mode is based on The way the context model is decoded.
  • the first decoding rule is determined according to any one of a first decoding principle, a second decoding principle, and a third decoding principle;
  • the third decoding principle is that the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode.
  • the foregoing apparatus further includes:
  • a second determining module configured to determine, according to the target binarized character string corresponding to the target coding tree block CTB, whether the preset execution condition is met, and the preset execution condition is: used to represent the target CTB a condition that the prediction transform accuracy of the associated target coding tree unit CTU is low;
  • the above entropy decoding module is specifically configured to:
  • the target coded tree block corresponding to the target coding tree block CTB is encoded.
  • the valued string is entropy decoded to obtain the target binarized string.
  • the foregoing second determining module is specifically configured to: determine, according to the target image, whether the preset execution condition is met; wherein the target image is an image in which the target CTU is located.
  • the foregoing second determining module is specifically configured to:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the foregoing second determining module is specifically configured to:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the foregoing second determining module is specifically configured to:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the foregoing second determining module is specifically configured to:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is met; otherwise, It is determined that the preset execution condition is not satisfied.
  • the first decoding rule determined according to the first decoding principle includes:
  • Decoding rules the binarized strings corresponding to EO mode, skip mode and BO mode are 0, 10, 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model The way to decode.
  • the first decoding rule determined according to the first decoding principle includes:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. The way.
  • the first decoding rule determined according to the first decoding principle includes:
  • Decoding rules the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each encoded binarized string, the encoded binary string is
  • the decoding mode of one bit is a method of equal probability decoding, and in the case where the encoded binarized character string further includes the second bit, the decoding of the second bit of the encoded binarized character string
  • the mode is a context model based decoding method.
  • the first decoding rule determined according to the second decoding principle includes:
  • Decoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model. The way to decode.
  • an encoder including a first processor and a first memory, where
  • a first memory for storing a computer program
  • the first processor is configured to implement the method steps described in any of the SAO type encoding methods when executing the program stored on the first memory.
  • an embodiment of the present application provides a decoder, including a second processor and a second memory, where
  • a second memory for storing a computer program
  • the second processor is configured to implement any of the above SAOs when executing the program stored on the second memory Type of decoding method described method steps.
  • the embodiment of the present application provides a computer readable storage medium, where the computer readable storage medium stores a computer program, and when the computer program is executed by the processor, implements the coding method of any of the above SAO types. Method steps.
  • the embodiment of the present application provides another computer readable storage medium, where the computer readable storage medium stores a computer program, and when the computer program is executed by the processor, the decoding method of any of the above SAO types is implemented. Method steps.
  • an embodiment of the present application provides a computer program product comprising instructions, when executed on a computer, causing a computer to perform the method steps described in any of the above-described SAO type encoding methods.
  • the embodiment of the present application provides another computer program product comprising instructions, which when executed on a computer, causes the computer to perform the method steps described in any of the above SAO type decoding methods.
  • an embodiment of the present application provides a computer program that, when run on a computer, causes the computer to perform the method steps described in any of the SAO-type encoding methods described above.
  • an embodiment of the present application provides a computer program that, when run on a computer, causes the computer to perform the method steps described in any of the SAO-type decoding methods described above.
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; And the entropy coding method for distinguishing the bits corresponding to the binarized character strings respectively in the EO mode and the BO mode is a context model based coding mode.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to two.
  • the entropy coding result of the valued string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode is much more probable than the BO mode.
  • the probability even when it is greater than the use probability of the skip mode; the scheme provided by the embodiment of the present application can improve the video coding efficiency when the first coding rule determined according to the first coding principle performs the coding of the SAO type.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode.
  • the compression ratio is high, so when the first encoding rule determined by the second coding principle is used to perform the SAO type encoding, the solution provided by the embodiment of the present application can also improve the video encoding efficiency.
  • 1 is a general frame diagram of a video codec corresponding to the latest video coding standard HEVC;
  • FIG. 2 is a frame diagram of an interface interface of the SAO decoding end in the latest video coding standard HEVC;
  • FIG. 3 is a schematic diagram of four different sets of adjacent pixels of the EO mode in the SAO of the latest video coding standard HEVC;
  • FIG. 4 is a schematic diagram of a merge mode in the SAO in the latest video coding standard HEVC;
  • FIG. 5 is a schematic flowchart of a coding method of an SAO type according to an embodiment of the present disclosure
  • FIG. 6 is a schematic flowchart of a coding method of an SAO type according to another embodiment of the present disclosure.
  • FIG. 7 is a schematic flowchart of a method for decoding an SAO type according to an embodiment of the present disclosure
  • FIG. 8 is a schematic flowchart of a method for decoding an SAO type according to another embodiment of the present disclosure.
  • FIG. 9 is a schematic flowchart of an SAO type encoding apparatus according to an embodiment of the present disclosure.
  • FIG. 10 is a schematic flowchart of an SAO type encoding apparatus according to another embodiment of the present disclosure.
  • FIG. 11 is a schematic flowchart of a SAO type decoding apparatus according to an embodiment of the present disclosure.
  • FIG. 12 is a schematic flowchart of a SAO type decoding apparatus according to another embodiment of the present disclosure.
  • FIG. 13 is a schematic structural diagram of an encoder according to an embodiment of the present disclosure.
  • FIG. 14 is a schematic structural diagram of a decoder according to an embodiment of the present application.
  • Video coding also known as video compression, is designed to eliminate redundant information that exists between video signals.
  • video compression is designed to eliminate redundant information that exists between video signals.
  • the mainstream video coding standards use a hybrid coding framework based on block-based prediction and transformation.
  • Figure 1 shows the video corresponding to the latest video coding standard HEVC.
  • the overall frame diagram of the codec the input video signal is processed by coding techniques such as block structure division, prediction, transform, quantization, entropy coding, etc., and finally the bit stream is output.
  • a video encoder divides a video frame into blocks for encoding, such as an H.264/AVC (Advanced Video Coding) video coding standard, which divides a video frame into equal parts.
  • Small 16x16 macroblocks (Macro Block, MB) are not covered by each other, while HEVC divides the video frame into uniform equal-sized Coding Tree Units (CTUs).
  • the size of the CTU can be in the encoder configuration file. Set in the middle, usually in 64 x 64 size.
  • HEVC supports dividing the coding tree unit into smaller coding units (CUs) according to the quadtree structure, and the 64 ⁇ 64 CTU can be divided into four 32 ⁇ 32 CUs of the same size.
  • a 32x32 CU can be quadruple divided into four 16x16 CUs or not divided, and so on until the minimum allowed CU size is divided.
  • the CU is a basic unit of coding, and is generally a 2N ⁇ 2N block, and the size does not exceed the size of the CTU.
  • the size of the CU may be 8 ⁇ 8, 16 ⁇ 16, 32 ⁇ 32, 64 ⁇ 64, and the like.
  • the CU may be divided into prediction units (PUs) of different sizes and different shapes, and the prediction unit PU is a basic unit of prediction, and the size of the prediction unit cannot exceed the size of the CU where the CU is located.
  • the CU can also be recursively divided into transform units (TUs) of different sizes for transforming the residual block obtained after the prediction.
  • the TU is the basic unit of the transform, and the size of the TU cannot exceed the size of the CU.
  • the size is 4 ⁇ 4, 8 ⁇ 8, 16 ⁇ 16, 32 ⁇ 32, and the like.
  • the video sequence image is first divided into equal-sized CTUs, and the CTU can be divided into different sizes of CUs.
  • the encoder is coded in units of CU, and then divided into different PUs based on the CU.
  • the prediction is performed in units of PUs, and the prediction block is obtained.
  • the prediction block is compared with the original block to obtain a prediction residual block, and the prediction residual block is transformed to obtain a transform coefficient block, and then a one-dimensional array input quantization is formed by a specific scanning manner.
  • the scalar quantization is performed, and finally the quantized coefficients are input to the entropy encoder to be encoded to form a final code stream.
  • the encoded video sequence reconstructed frame/block will be used as a reference frame/block for subsequent frames so that it results in a more accurate prediction block with inter/intra prediction.
  • the reconstructed data obtained from the original data and the predicted, transformed, quantized, inverse quantized and inverse transformed may have certain errors, which causes distortion of the final reconstructed video.
  • In-loop filtering such as De-block Filter (DF) and SAO can effectively reduce distortion and improve subjective/objective quality.
  • FIG. 2 is a frame diagram of the SAO decoding end interface in the latest video coding standard HEVC, and the input is the deblocked filtered data of the reconstructed data and the SAO decoded by the entropy decoder. Information, the output is the final reconstructed signal (input to the reference frame list buffer for subsequent Video frame reference).
  • the syntax element sample_adaptive_offset_enabled_flag in the Sequence Parameter Set is true, and the syntax elements slice_sao_luma_flag and slice_sao_chroma_flag in the slice-level header information are true.
  • the SAO type in the HEVC standard, is identified by sao_type_idx, and the SAO type includes three types: skip mode, EO mode, and BO mode. It is well known to those skilled in the art that a CTU includes a luma coding tree block and a plurality of chroma coding tree blocks. Therefore, in the video encoding and decoding process, the encoding and decoding of the SAO type performed by the encoder and the decoder can be understood as Editing and decoding the luma coding tree block and each chroma coding tree block in the CTU.
  • the encoder may encode a tree block for the luma of the CTU, and select the SAO type of the luma coding tree block with the least cost penalty from the three SAO types; if the CTU has a chroma component (That is, the color space format is not 4:0:0), then the SAO type of the chroma coding tree block is selected in the same manner, and if there are multiple chroma components, the SAO type decision selection needs to be separately performed.
  • the EO mode is a process of calculating a suitable offset value offset according to the relationship between adjacent pixels in the CTB and the current pixel, and applying the calculated offset value to the current pixel.
  • the specific operation mode is as follows: EO mode is usually The current pixel is compared with a set of adjacent pixels, and according to the relationship between the current pixel and the adjacent pixel shown in Table 1, the current pixel is divided into five different types, wherein a group of adjacent pixels (a, b) The selection method is as shown in FIG. 3, where a and b respectively represent adjacent pixels, and c represents the current pixel.
  • the current pixel of the class will not be c has any operations; if the other four cases are satisfied, an offset value is assigned to each class and added to the current pixel c. Also, for classes 1 and 2, the offset value offset must be a positive integer, and for the 3rd and 4th classes, the offset value offset must be a negative integer to avoid encoding the offset sign bit resulting in an increase in the coded bits.
  • Table 1 EO mode pixel classification mapping table
  • the BO mode classifies all pixel values according to the size of all pixel values in the CTB, and sets an appropriate offset value for each class, and finally applies the offset value to the pixels of the corresponding category.
  • the specific operation mode is as follows: BO All pixels of different sizes are divided into 32 bands that are not inter-interleaved, that is, each band contains corresponding 8 pixel values, similar to a statistical histogram, and the range of the first band containing values belongs to [0, 7] 8 pixels, and so on, the 32nd band contains values of 8 pixels belonging to [248, 255].
  • the offset offset is calculated as follows: Calculate the average value R of all the pixels in each band after the CTB is divided into 32 bands before entering the SAO and the average of all the pixels in each band after the CTB original pixel is divided into 32 bands.
  • the value S, the offset value is (SR).
  • FIG. 4 is a schematic diagram of a merge mode in a SAO in the latest video coding standard HEVC.
  • the merge mode refers to an SAO parameter including a CTU that is inherited and used, including SAO parameters of the luma coding tree unit and all chroma coding.
  • the SAO parameter of the tree unit may be used to determine whether to adopt the SAO merge mode, including sao_merge_left_flag (left merge mode) and sao_merge_up_flag (up merge mode).
  • embodiments of the present application provide an encoding and decoding method, apparatus, encoder, decoder, and storage medium.
  • an SAO type encoding method provided by an embodiment of the present application may be applied to an encoder.
  • the encoder may be a physical device, and may also be a video encoding function.
  • the program is reasonable, and the embodiment of the present application does not limit the specific form of the encoder.
  • an embodiment of the present application provides an SAO type encoding method, where the method includes:
  • S101 After determining the target SAO type of the target coding tree block CTB, determining the target corresponding to the target SAO type according to the correspondence between each SAO type and the binarized character string recorded in the preset first coding rule. a valued string in which each SAO is recorded in the first encoding rule The correspondence between the type and the binarized string, and the entropy encoding of the binarized string.
  • a CTU may include a luma coding tree block and a plurality of chroma coding tree blocks. Therefore, the target coding tree block CTB described in this embodiment may be either a luma coding tree block or a chroma. Encoding tree blocks, this is all reasonable. In addition, the target CTB does not specifically refer to a CTB, and any CTB in the video sequence image may be used as the target CTB.
  • the above-described correspondence relationship includes the binarized character strings corresponding to the skip mode, the EO mode, and the BO mode, respectively.
  • the correspondence relationship is a correspondence relationship table.
  • the binarized strings corresponding to the skip mode, the EO mode, and the BO mode are: a binarized string x, a binarized string y, and The binarized character string z; in this case, assuming that the target SAO type determined above is the EO mode, the target binarized character string can be determined as the binarized character string y according to the correspondence relationship table.
  • the entropy coding manner of the binarized character string recorded in the first coding rule can be understood as a specific entropy coding mode adopted by each binarized bit (abbreviated as a bit) in the binarized character string.
  • a bit a specific entropy coding mode adopted by each binarized bit (abbreviated as a bit) in the binarized character string.
  • the coding method based on the context model and the equal-probability coding method are all well-known technologies, and the specific implementation methods of the two coding modes are not described in detail herein. However, it is well known to those skilled in the art that if the bits in the binarized character string are entropy encoded using a context model based coding scheme, the code compression ratio of the bit is high; and if the bits in the binarized string are binarized When the bit is entropy encoded by the equal probability coding method, the coding speed of the bit is high.
  • S102 Entropy coding the target binarized character string according to the entropy coding manner of the binarized character string recorded in the first coding rule, to obtain an encoding result corresponding to the target SAO type.
  • the first coding rule is determined according to any one of the following coding principles:
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy coding mode for distinguishing the bits corresponding to the binarized character string of the EO mode and the BO mode respectively is based on the context model The encoding method.
  • the first encoding rule in the embodiment of the present application is preset, but does not represent the first encoding.
  • the code rules are randomly set, and the first coding rule needs to be set according to any of the first coding principle and the second coding principle described above.
  • the first encoding rule used in the encoding process of the video is the same.
  • the coding principle used to determine the first coding rule may be information according to a coding parameter of a current image, an encoding parameter of a current coding unit (for example, an encoding parameter of a current coding CTU), and the like in a video coding process. And selecting the first coding principle and the second coding principle, and then determining the specific rule content of the first coding rule according to the selected coding principle, so that when the encoder encodes the SAO type in the video coding process, The first coding rule adopted is more flexible and is more conducive to improving video coding efficiency.
  • the binarized character strings respectively corresponding to the skip mode, the EO mode, and the BO mode are selected among the three binarized strings of 0, 10, and 11, and of course, It can be selected in the three binary strings of 1, 00, and 01.
  • the first coding principle stipulates that the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode, that is, the EO mode corresponds to
  • the length of the binarized string is less than the length of the binarized string corresponding to the BO mode, or the length of the binarized string corresponding to the EO mode is less than the length of the binarized string corresponding to the BO mode.
  • the length of the binarized character string may be the number of bits of the bit string included in the binarized character string. For example, the binarized character string corresponding to the skip mode and the EO mode is 0, 10, respectively, due to the binarized character.
  • the bit number of the string 10 is greater than the binarized character string 0, and the length of the binarized character string corresponding to the EO mode is smaller than the length of the binarized character string corresponding to the skip mode.
  • the first coding principle only limits the correspondence between each SAO type and the binarized character string, and the entropy coding manner of the binary string is not limited, so different codes determined according to the first coding principle are used.
  • the same bit in the binarized character string is set to be entropy encoded by the equal probability coding method, and some bits are set to be entropy coded by the context model based coding mode.
  • the first coding rule determined according to the first coding principle may be:
  • Coding rules the binarized strings corresponding to EO mode, skip mode and BO mode are 0, 10, 11 respectively; and the entropy coding mode of each bit of the binarized string is based on the context model The encoding method.
  • each SAO type and the binarized character string recorded in the first encoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively. 11;
  • the entropy coding mode of the recorded binarized character string is: the entropy coding mode of each bit of the binarized character string is a coding mode based on a context model.
  • the encoder determines, according to the above correspondence, that the binarized character string corresponding to the EO mode is 0, and then uses the context-based model for the binarized character string 0.
  • the encoding method is entropy encoded to obtain the encoding result corresponding to the EO mode.
  • the encoder determines, according to the above correspondence, that the binary character string corresponding to the BO mode is 11, and then the first bit in the binarized character string 11 Bit 1, using the context model based coding method for entropy coding; for the second bit 1 in the binarized character string 11, the entropy coding is also performed by using the context model based coding method, and finally the BO mode is correspondingly obtained.
  • the entropy coding is also performed by using the context model based coding method, and finally the BO mode is correspondingly obtained.
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codeword, that is, the encoder can perform the EO mode.
  • the compression ratio of the SAO type is high. The inventors have found through a large number of experiments that the probability of using the EO mode is much larger than that of the BO mode in the video coding process, and even greater than the use probability of the skip mode in some cases. Therefore, when the SAO type encoding is performed according to the first encoding rule in this implementation manner, the video encoding efficiency can be improved.
  • the entropy coding mode of each bit of the binarized character string is based on the context model coding mode, and the coding ratio of the coding performed by the encoder on various SAO types is high, thereby further improving the video coding efficiency.
  • the first coding rule determined according to the first coding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • each SAO type and the binarized character string recorded in the first encoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are respectively 0, 10, 11;
  • the entropy coding mode of the recorded binarized character string is: the entropy coding mode of each bit of the binarized character string is a method of equal probability coding.
  • the encoder determines, according to the above correspondence, that the binarized character string corresponding to the EO mode is 0, and then uses the equal probability coding for the binarized character string 0.
  • the entropy coding is performed to obtain the coding result corresponding to the EO mode.
  • the encoder determines, according to the above correspondence, that the binary character string corresponding to the BO mode is 11, and then the first bit in the binarized character string 11 Bit 1, using entropy coding based on equal probability coding; for the second bit 1 in the binarized character string 11, the entropy coding is also performed by means of equal probability coding, and finally the coding corresponding to the BO mode is obtained. result.
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codeword, that is, the encoder can perform the EO mode.
  • the SAO type encodes a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than the BO mode, and sometimes even greater than the skip mode. Therefore, according to this implementation When the first encoding rule performs SAO type encoding, video encoding efficiency can be improved.
  • the entropy coding mode of each bit of the binarized character string is an encoding method of equal probability coding, and the encoding speed of the encoder for various SAO types is fast, so according to this implementation manner
  • the video encoding speed can also be improved.
  • the first coding rule determined according to the first coding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each binarized string, the first bit of the binarized string.
  • the coding mode is equal probability coding.
  • the binarized character string further includes the second bit, the coding mode of the second bit of the binarized character string is based on the context model. .
  • the correspondence between each SAO type and the binarized character string recorded in the first encoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively. , 11; the entropy encoding of the recorded binarized string is: for each binarized character a string, the first bit of the binarized string is encoded in an equal probability encoding manner, and in the case where the binarized string further includes a second bit, the second digit of the binary string The encoding of the two bits is based on the context model.
  • the encoder determines, according to the above correspondence, that the binarized character string corresponding to the EO mode is 0, and then uses the equal probability coding for the binarized character string 0.
  • the entropy coding is performed to obtain the coding result corresponding to the EO mode.
  • the encoder determines, according to the above correspondence, that the binary character string corresponding to the skip mode is 10, and then the first one of the binarized character strings 10 Bit 1 is entropy encoded by means of equal probability coding; for the second bit 0 in the binarized string 10, entropy coding is performed using a context model based coding method, and finally a skip mode is obtained. Corresponding coding result.
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codeword, that is, the encoder can perform the EO mode.
  • the SAO type encodes a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than the BO mode, and sometimes even greater than the skip mode. Therefore, according to this implementation When the first encoding rule performs SAO type encoding, video encoding efficiency can be improved.
  • the first coding rule determined according to the foregoing first coding principle is not limited to the foregoing three implementation manners, and may be other first coding rules.
  • the first encoding rule determined according to the first encoding principle may also be:
  • Encoding rules the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 11, and 10, respectively; and for each binarized string, the first bit of the binarized string.
  • the coding mode is a context model based coding mode.
  • the coding mode of the second bit of the binarized character string is an equal probability coding mode. .
  • the first encoding rule determined according to the first encoding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 11, and 10, respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • the second coding principle stipulates that the EO mode and the BO mode respectively have the same length of the binarized character string; and are used to distinguish the EO mode and the BO mode respectively corresponding to the bits of the binarized character string.
  • the entropy coding method is a coding method based on a context model.
  • the entropy coding mode for distinguishing the bits corresponding to the binarized character string respectively of the EO mode and the BO mode is a context model based coding mode, and the encoder pair
  • the coding ratios of the two types of SAOs, the EO mode and the BO mode, are high, so that the SAO type coding method is performed by using the first coding rule determined according to the second coding principle, and the video coding efficiency can be improved.
  • the first coding rule determined according to the second coding principle may be:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is based on the context model. the way.
  • each SAO type and the binarized character string recorded in the first encoding rule is: the binarized character strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, respectively.
  • the entropy coding mode of the binarized character string recorded in 11 is: the entropy coding mode of each bit of the binarized character string is a coding mode based on a context model.
  • the encoder determines, according to the above correspondence, that the binarized character string corresponding to the EO mode is 11, and then the first one of the binarized character strings 1
  • the bit 1 and the first bit 1 are both entropy encoded using a context model based coding method to obtain an encoding result corresponding to the EO mode.
  • the encoder determines, according to the above correspondence, that the binary character string corresponding to the skip mode is 10, and then the first one of the binarized character strings 1 is The bit 1 and the first bit 0 are both entropy encoded using a context model based coding method to obtain a coding result corresponding to the BO mode.
  • the first coding rule determined according to the foregoing second coding principle is not limited to the foregoing implementation manner, and may be other first coding rules.
  • the first encoding rule determined according to the second encoding principle may also be:
  • Encoding rules the binarized strings corresponding to skip mode, BO mode, and EO mode are respectively 0, 11, 10; and the entropy coding mode of each bit of the binarized character string is based on the context model.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to two.
  • the entropy coding result of the valued string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode is much more probable than the BO mode.
  • the probability even when it is greater than the use probability of the skip mode; the scheme provided by the embodiment of the present application can improve the video coding efficiency when the first coding rule determined according to the first coding principle performs the coding of the SAO type.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode.
  • the compression ratio is high, so when the first encoding rule determined by the second coding principle is used to perform the SAO type encoding, the solution provided by the embodiment of the present application can also improve the video encoding efficiency.
  • the first coding rule may be determined according to any one of a first coding principle, a second coding principle, and a third coding principle;
  • the third coding principle is that the entropy coding mode of each bit in the binarized character string is an equal probability coding mode.
  • the coding principle for determining the first coding rule may be pre-selected, or may be selected in real time according to the coding parameters in the video coding process, which is reasonable, and the embodiment of the present application is here.
  • the selection of the coding principle for determining the first coding rule is not limited.
  • the third coding principle only limits the entropy coding mode of the binarized character string, and the correspondence relationship between each SAO type and the binarized character string is not limited.
  • the first coding rule determined according to the third coding principle may be:
  • Encoding rules the binarized strings corresponding to skip mode, BO mode, and EO mode are respectively 0, 10, 11; and the entropy coding mode of each bit of the binarized character string is an equal probability coding mode.
  • each SAO type and the binarized character string recorded in the first encoding rule is: the binarized character strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, respectively. 11;
  • the entropy coding mode of the recorded binarized character string is: the entropy coding mode of each bit of the binarized character string is an equal probability coding mode.
  • the encoder determines, according to the above correspondence, that the binarized character string corresponding to the EO mode is 11, and then the first bit of the binarized character string 11 Bit 1 and the second bit 1 are both entropy encoded using an equal probability coding method to obtain an encoding result corresponding to the EO mode.
  • the first coding rule determined according to the first coding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • each SAO type and the binarized character string recorded in the first encoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively. 11;
  • the entropy coding mode of the recorded binarized character string is: the entropy coding mode of each bit of the binarized character string is a method of equal probability coding.
  • the encoder determines, according to the above correspondence, that the binarized character string corresponding to the EO mode is 0, and then uses the equal probability coding for the binarized character string 0.
  • the entropy coding is performed to obtain the coding result corresponding to the EO mode.
  • the encoder determines, according to the above correspondence, that the binary character string corresponding to the BO mode is 11, and then the first bit in the binarized character string 11 Bit 1, using entropy coding based on equal probability coding; for the second bit 1 in the binarized character string 11, the entropy coding is also performed by means of equal probability coding, and finally the coding corresponding to the BO mode is obtained. result.
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codeword, that is, the encoder can perform the EO mode.
  • the SAO type encodes a high compression ratio; since the video coding process, the EO mode The usage probability of the formula is much larger than the usage probability of the BO mode, and is sometimes greater than the use probability of the skip mode; therefore, when the first encoding rule in this implementation manner performs the SAO type encoding, the video encoding efficiency can be improved.
  • the entropy coding mode of each bit of the binarized character string is an encoding method of equal probability coding, and the encoding speed of the encoder for various SAO types is fast, so according to this implementation manner
  • the video encoding speed can also be improved.
  • the first coding rule determined according to the foregoing third coding principle is not limited to the foregoing two implementation manners, and may be other first coding rules.
  • the first encoding rule determined according to the third encoding principle may also be:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 11, and 10, respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding mode.
  • the entropy coding mode of each bit in the binarized character string is an equal probability coding mode
  • the SAO type coding process does not Using any context model can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the target SAO type is determined according to the correspondence between each SAO type and the binarized character string recorded in the preset first encoding rule.
  • the above method can also be packaged before the step of the corresponding target binarization string include:
  • the preset execution condition is: a condition for indicating that the prediction transform accuracy of the target coding tree unit CTU to which the target CTB belongs is low;
  • the step of determining the target binarized character string corresponding to the target SAO type according to the correspondence between each SAO type and the binarized character string recorded in the preset first encoding rule is performed.
  • the first coding rule may be determined according to the first coding principle or the second coding principle, or may be determined according to any one of the first to third coding principles.
  • the foregoing SAO type encoding method includes:
  • the preset execution condition is: indicating that the prediction transform accuracy of the target coding tree unit CTU to which the target CTB belongs is low. condition.
  • the encoder may perform the determination according to different information, and then determine whether the preset execution condition is met.
  • the step of determining whether the preset execution condition is met may include :
  • the target image is an image in which the target CTU is located.
  • the above target CTU is in the target image, so some image information of the target image can represent that the prediction transform accuracy of the target CTU is low.
  • the step of determining whether the preset execution condition is met based on the target image may include:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries target identifier information, where the target identifier information indicates
  • the SAO type corresponding to all CTBs in the target image needs identification information that is encoded according to the foregoing first coding rule;
  • the target image is not a bidirectional predicted image.
  • the target image is an intra prediction image, that is, the target image is an I frame.
  • the quantization parameter used by the target image is greater than the first preset threshold. It can be understood that the quantization parameter used by the target image is used by the encoder in performing the quantization operation on the target image.
  • the first preset threshold may be preset based on actual conditions, for example, the first preset threshold is set to 25.
  • the header information of the target image carries the target identification information. It can be understood that the header information of the target image is additionally provided with a flag bit, which is used to identify whether the SAO type corresponding to all CTBs in the image needs to be in accordance with the
  • the information encoded by an encoding rule indicates that the SAO type corresponding to all CTBs in the image needs to be encoded according to the first encoding rule.
  • the corresponding identification information can be set according to a preset rule.
  • the target image is not a bi-predictive image, that is, the target image is not a B frame, and may be an I frame or a P frame.
  • the encoder finds that the target image is an intra prediction image, it can directly determine that the preset execution condition is satisfied.
  • the step of determining whether the preset execution condition is met may include:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the encoder may use only the quantization information of the target CTU itself to determine whether the preset execution condition is met, or may use only the prediction information of the target CTU itself to determine whether the preset execution condition is met, or may only utilize the transformation of the target CTU itself.
  • the information is used to determine whether the preset execution condition is met; and any combination of the quantized information, the predicted information, and the transformed information of the target CTU itself can be used to determine whether the preset execution condition is satisfied.
  • the step of determining whether the preset execution condition is met is performed according to at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold, for example, the quantization parameter used by the target CTU is greater than 30;
  • the average size of all transform units in the target CTU is smaller than a third preset threshold, for example, the average size of all transform units in the target CTU is less than 8 ⁇ 8;
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold, for example, the average size of all coding units in the target CTU is less than 16 ⁇ 16.
  • the encoder finds that the quantization parameter used by the target CTU is 40, it can directly determine that the preset execution condition is satisfied.
  • the step of determining whether the preset execution condition is met may include:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • the encoder can know the loop filtering strength value when performing deblocking filtering on the target CTU, for example, the fifth preset threshold is 1.
  • the encoder directly determines that the preset execution condition is satisfied when the loop filter strength value when the target CTU is found to perform deblocking filtering is greater than one.
  • step S202 is performed to determine the target binarized character corresponding to the target SAO type according to the correspondence between each SAO type and the binarized character string recorded in the preset first encoding rule. a string, wherein the first encoding rule records a correspondence between each SAO type and a binarized character string, and an entropy encoding manner of the binarized character string.
  • the encoder may not encode the target CTB according to the first coding rule set in the embodiment of the present application, and may directly follow the coding rules specified in the existing HEVC standard.
  • the target CTB is encoded.
  • S203 Entropy coding the target binarized character string according to the entropy coding manner of the binarized character string recorded in the first coding rule, to obtain an encoding result corresponding to the target SAO type.
  • the first coding rule is determined according to any one of the following coding principles:
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy coding mode for distinguishing the bits corresponding to the binarized character string of the EO mode and the BO mode respectively is based on the context model The encoding method.
  • steps S202 and S203 are the same as the steps S101 and S102 in the method embodiment shown in FIG. 5, and the related content and explanation of the steps S202 and S203 can be referred to the method embodiment shown in FIG. The example is not described in detail here.
  • the embodiment of the present application further provides a decoding method of the SAO type.
  • the decoding method can be applied to a decoder.
  • the decoder can be an entity.
  • the device may also be a program that can implement the video decoding function, which is reasonable.
  • the embodiment of the present application does not limit the specific form of the decoder.
  • the decoding method includes:
  • S301 Entropy decoding the encoded target binarized character string corresponding to the target coding tree block CTB according to an entropy decoding manner of the encoded binarized character string recorded in the preset first decoding rule, to obtain a target binary value.
  • the first decoding rule records an entropy decoding manner of the encoded binarized character string, and a correspondence between each SAO type and the binarized character string.
  • the target binarized character string corresponding to the target CTB that can be obtained by the decoder that is, the target SAO type involved in the method embodiment of the foregoing SAO type decoding method is corresponding.
  • the result of the encoding is corresponding.
  • the entropy decoding mode of the encoded binarized character string recorded in the first decoding rule can be understood as: the specific entropy decoding method used by each bit in the encoded binarized character string. formula. There are two types of decoding methods for each of the above bits: a context model based decoding method and an equal probability decoding method.
  • the decoding method based on the context model and the equal-probability decoding method are all well-known technologies, and the specific implementation methods of the two decoding methods are not described in detail herein. However, it is well known to those skilled in the art that if the bits in the encoded binarized character string are entropy decoded using a context model based decoding method, the decoding efficiency of the bit is high; and if the binarized string is encoded The bit in the bit is entropy decoded by the equal probability decoding method, and the decoding speed of the bit is high.
  • S302 Determine, according to the correspondence between each SAO type and the binarized character string recorded in the first decoding rule, the target SAO type corresponding to the target binarized character string.
  • the first decoding rule is determined according to any one of the following decoding principles:
  • the first decoding principle the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode;
  • the second decoding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy decoding method for distinguishing the bits corresponding to the encoded binarized character string respectively for the EO mode and the BO mode is based on The way the context model is decoded.
  • the first decoding rule in the embodiment of the present application is also preset, but does not mean that the first decoding rule is randomly set, and the first decoding rule needs to be in accordance with the foregoing first decoding principle and the second decoding principle. Any one of them is set. Moreover, when any one video is decoded after the first decoding rule is set, the first decoding rule used in the decoding process of the video is the same.
  • the decoding principle used to determine the first decoding rule may be: according to the encoding parameter of the current image, the encoding parameter of the current coding unit, and the like in the video decoding process, from the foregoing first decoding principle. And selecting the second decoding principle, and then determining the specific rule content of the first decoding rule according to the selected decoding principle.
  • the first decoding rule applied by the encoder and the first decoding applied by the decoder may be preset. Corresponding to the rules.
  • the first decoding principle specifies that the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode; that is, the EO mode corresponds to The length of the binarized string is less than the length of the binarized string corresponding to the BO mode.
  • the length of the binary string corresponding to the degree or the EO mode is smaller than the length of the binarized string corresponding to the BO mode.
  • the first decoding principle only limits the correspondence between each SAO type and the binarized character string, and the entropy decoding manner of the encoded binary string is not limited, so it is determined according to the first decoding principle.
  • the same bit in the binarized string is set, and some bits are set to be entropy decoded by equal probability decoding, and some bits are set to be entropy decoded by using a context model based decoding method. .
  • the first decoding rule determined according to the first decoding principle may be:
  • Decoding rules the binarized strings corresponding to EO mode, skip mode and BO mode are 0, 10, 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model The way to decode.
  • each SAO type and the binarized character string recorded in the first decoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively.
  • the entropy decoding mode of the recorded binarized character string is: the entropy decoding mode of each bit of the binarized character string is a decoding mode based on the context model.
  • the decoder first performs entropy decoding on the two bits in the encoded binarized character string by using a context model based decoding manner to obtain a target binarized character string 11; Then, according to the above correspondence, it is determined that the SAO type corresponding to the target binarized character string 11 is the BO mode.
  • the first encoding rule corresponding to the first decoding rule is:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized string is based on the context model. the way.
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode is The codeword is less, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the EO mode is more likely to be used in the video encoding process than the BO mode, even larger than Skip mode usage probability; so the first encoding rule performs SAO When coding of a type, video coding efficiency can be improved.
  • the entropy coding mode of each bit of the binarized character string is a coding mode based on a context model, and the coding ratio of the coding performed by the encoder on various SAO types is high. Further improve the video coding efficiency.
  • the first decoding rule determined according to the first decoding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. The way.
  • each SAO type and the binarized character string recorded in the first decoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively.
  • the entropy decoding mode of the recorded binarized character string is as follows: the entropy coding mode of each bit of the encoded binarized character string is a method of equal probability decoding.
  • the decoder first performs entropy decoding on the two bits in the encoded binarized character string by using a context model based decoding manner to obtain a target binarized character string 10 Then, according to the above correspondence, it is determined that the SAO type corresponding to the target binarized character string 10 is the skip mode.
  • the first encoding rule corresponding to the first decoding rule is:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode is The codeword is less, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the EO mode is more likely to be used in the video encoding process than the BO mode, even larger than The probability of use of the skip mode; therefore, when the SAO type encoding is performed according to the first encoding rule in this implementation manner, the video encoding efficiency can be improved.
  • the entropy encoding mode of each bit of the binarized character string is an encoding method of equal probability encoding, and the encoding speed of the encoder for various SAO types is fast, so according to this Implementer
  • the first encoding rule under the formula performs SAO type encoding, the video encoding speed can also be improved.
  • the first decoding rule determined according to the first decoding principle may also be:
  • Decoding rules the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each encoded binarized string, the encoded binary string is
  • the decoding mode of one bit is a method of equal probability decoding, and in the case where the encoded binarized character string further includes the second bit, the decoding of the second bit of the encoded binarized character string
  • the mode is a context model based decoding method.
  • the correspondence between each SAO type and the binarized character string recorded in the first decoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively.
  • the entropy decoding manner of the recorded binarized character string is: for each binarized character string, the decoding manner of the first bit of the binarized character string is a method of equal probability decoding, In the case where the binarized character string further includes the second bit, the encoding mode of the second bit of the binarized character string is a context model based decoding mode.
  • the decoder finds that the encoded binary string has only one bit, and firstly uses the equal probability decoding method for the bits in the encoded binarized string. Entropy decoding obtains the target binarized string 0; then, according to the above correspondence, it is determined that the SAO type corresponding to the target binarized string 0 is the EO mode.
  • the first encoding rule corresponding to the first decoding rule is:
  • Encoding rules the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 11, and 10, respectively; and for each binarized string, the first bit of the binarized string.
  • the coding mode is a context model based coding mode.
  • the coding mode of the second bit of the binarized character string is an equal probability coding mode. .
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode is The codeword is less, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the EO mode is more likely to be used in the video encoding process than the BO mode, even larger than Skip mode usage probability; so follow the first in this implementation
  • the encoding rule performs the encoding of the SAO type, the video encoding efficiency can be improved.
  • the first decoding rule determined according to the foregoing first decoding principle is not limited to the foregoing three implementation manners, and may be other first decoding rules.
  • the first decoding rule determined according to the first decoding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 11, and 10, respectively; and for each of the encoded binarized strings, the encoded binary string is
  • the decoding mode of one bit is a context mode based decoding mode, and in the case where the encoded binarized character string further includes a second bit, the second bit of the encoded binarized character string
  • the decoding method is a method of equal probability decoding.
  • the first decoding rule determined according to the first decoding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 11, and 10, respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. The way.
  • the second decoding principle stipulates that the EO mode and the BO mode respectively have the same length of the binarized character string; and are used to distinguish the EO mode and the BO mode respectively corresponding to the bits of the encoded binary string.
  • the entropy decoding mode of the bit is a decoding method based on the context model.
  • the first decoding rule corresponding to the first decoding principle is used to distinguish the EO mode and the BO mode respectively corresponding to the binarized character string.
  • the entropy coding method is a coding mode based on the context model, and the encoder has a high compression ratio for the coding of the two types of SAOs, the EO mode and the BO mode, so that the coding method of the SAO type according to the first coding rule can be improved. Video coding efficiency.
  • the first decoding rule determined according to the second decoding principle may be:
  • Decoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model. The way to decode.
  • the decoder first performs entropy decoding on the two bits in the encoded binarized character string by using a context model based decoding manner to obtain a target binarized character string 10 Then, according to the above correspondence, the target binarization string 10 is determined.
  • the corresponding SAO type is BO mode.
  • the first encoding rule corresponding to the first decoding rule is:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is based on the context model. the way.
  • the first decoding rule determined according to the foregoing second decoding principle is not limited to the foregoing implementation manner, and may be other first decoding rules.
  • the first decoding rule determined according to the second decoding principle may also be:
  • Decoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 11, and 10, respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model. The way to decode.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, because the solution provided by the embodiment of the present application
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codeword, that is, the first coding rule applied to match the first decoding rule.
  • the encoder can encode the SAO type of EO mode with a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than that of the BO mode, and sometimes even greater than the skip mode. Probability; Therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the solution provided by the embodiment of the present application can improve the video coding efficiency.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, which is used in the solution provided by the embodiment of the present application.
  • the entropy coding method for distinguishing the bits of the binarized character string corresponding to the EO mode and the BO mode respectively is a coding mode based on the context model, so the encoder pair is used to distinguish the EO mode and the BO mode respectively corresponding to the binarized character string.
  • the compression ratio of the entropy coding performed by the bit is high, that is, the compression ratio of the encoding of the two types of SAOs of the EO mode and the BO mode is high, so the scheme provided by the embodiment of the present application can also improve the video coding efficiency.
  • the first decoding rule It may also be determined according to any one of the first decoding principle, the second decoding principle, and the third decoding principle;
  • the third decoding principle is that the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode.
  • the decoding principle for determining the first decoding rule may be pre-selected, or may be selected in real time according to the encoding parameters in the video decoding process, which is reasonable, and the embodiment of the present application is This does not limit the way in which the decoding principles for determining the first decoding rule are determined.
  • the first decoding rule determined according to the third decoding principle may be:
  • Decoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. the way.
  • the decoder first performs entropy decoding on the two bits in the encoded binarized character string by using an equal probability decoding manner to obtain a target binarized character string 10; According to the above correspondence, it is determined that the SAO type corresponding to the target binarized character string 10 is the BO mode.
  • the first encoding rule corresponding to the first decoding rule is:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding mode.
  • the first decoding rule determined according to the first decoding principle may also be:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. The way.
  • each SAO type and the binarized character string recorded in the first decoding rule is: the binarized character strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, respectively.
  • the entropy coding mode of the recorded binarized character string is as follows: the entropy coding mode of each bit of the coded binarized character string is a method of equal probability decoding.
  • the decoder first targets the encoded binarized word.
  • the two bits in the character string are entropy decoded by using the context model based decoding method to obtain the target binarized character string 10; then, according to the above correspondence, the SAO type corresponding to the target binarized character string 10 is determined as Skip mode.
  • the first encoding rule corresponding to the first decoding rule is:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode is The codeword is less, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the EO mode is more likely to be used in the video encoding process than the BO mode, even larger than The probability of use of the skip mode; therefore, when the SAO type encoding is performed according to the first encoding rule in this implementation manner, the video encoding efficiency can be improved.
  • the entropy encoding mode of each bit of the binarized character string is an encoding method of equal probability encoding, and the encoding speed of the encoder for various SAO types is fast, so according to this
  • the first encoding rule in the implementation mode performs the SAO type encoding, the video encoding speed can also be improved.
  • the first decoding rule determined according to the foregoing third decoding principle is not limited to the foregoing two implementation manners, and may be other first decoding rules.
  • the first decoding rule determined according to the third decoding principle may also be:
  • Encoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 11, and 10, respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. the way.
  • the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode
  • SAO The type decoding process does not use any context model, which saves the decoder's operation of updating the context model and the buffering cost, ensures the low complexity of the decoder, and speeds up the video decoding speed.
  • the encoder performs SAO type encoding by using the first encoding rule matched with the first decoding rule, binarization
  • the entropy coding mode of each bit in the string is an equal probability coding mode.
  • the SAO type coding process does not use any context model, which can save the operation of the encoder update context model and the buffer cost, and ensure the encoder. Low complexity while speeding up video encoding.
  • the target coded tree block corresponding to the target coding tree block CTB is encoded.
  • the method further includes:
  • the preset execution condition being: indicating the prediction transformation accuracy of the target coding tree unit CTU to which the target CTB belongs Low condition
  • entropy decoding mode of the encoded binarized character string recorded in the preset first decoding rule If the entropy decoding mode of the encoded binarized character string recorded in the preset first decoding rule is performed, entropy decoding the encoded target binarized character string corresponding to the target coding tree block CTB is performed. The step of the target binarizing the string.
  • the first decoding rule may be determined according to the first decoding principle or the second decoding principle, or may be determined according to any one of the first to third decoding principles.
  • the foregoing SAO type decoding method includes:
  • the preset execution condition is a condition for indicating that the prediction conversion accuracy of the target coding tree unit CTU to which the target CTB belongs is low.
  • the encoder can judge according to different information, and then determine whether the preset execution condition is met, and the information according to the encoder is usually present in the video bitstream, so the decoder can also be based on the The different information described is judged to determine whether the preset execution condition is satisfied.
  • the step of determining whether the preset execution condition is met may include:
  • the target image is an image in which the target CTU is located.
  • the step of determining whether the preset execution condition is met based on the target image may include:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the step of determining whether the preset execution condition is met may include:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the step of determining whether the preset execution condition is met, according to at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs may include:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the step of determining whether the preset execution condition is met may include:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • step S402 is executed: the target binary value corresponding to the target coding tree block CTB is encoded according to the entropy decoding mode of the encoded binarized character string recorded in the preset first decoding rule. Entropy decoding of the character string to obtain a target binarized character string; wherein, the first decoding rule records an entropy decoding mode of the encoded binarized character string, and a correspondence relationship between each SAO type and the binarized character string;
  • the decoder may not decode the encoded binary string according to the first decoding rule set in the embodiment of the present application, which may directly follow the existing HEVC standard.
  • the decoding rule specified in the decoding of the encoded binarized character string may directly follow the existing HEVC standard.
  • S403 Determine, according to the correspondence between each SAO type and the binarized character string recorded in the first decoding rule, the target SAO type corresponding to the target binarized character string.
  • the first decoding rule is determined according to any one of the following decoding principles:
  • the first decoding principle the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode;
  • the second decoding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy decoding method for distinguishing the bits corresponding to the encoded binarized character string respectively for the EO mode and the BO mode is based on The way the context model is decoded.
  • steps S402 and S403 are respectively the same as the steps S301 and S302 in the method embodiment shown in FIG. 7.
  • the related content and explanation of the steps S402 and S403 can be referred to the method embodiment shown in FIG. The example is not described in detail here.
  • the embodiment of the present application provides an SAO type encoding device.
  • the device includes:
  • the first determining module 510 is configured to determine, according to the target SAO type of the target coding tree block CTB, the target SAO according to the correspondence between each SAO type and the binarized character string recorded in the preset first coding rule. a target binarized character string corresponding to the type, wherein the first encoding rule records a correspondence between each SAO type and the binarized character string, and an entropy encoding mode of the binarized character string;
  • the entropy coding module 520 is configured to perform entropy coding on the target binarized character string according to the entropy coding manner of the binarized character string recorded in the first coding rule, to obtain an encoding result corresponding to the target SAO type;
  • the first coding rule is determined according to any one of the following coding principles:
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy coding mode for distinguishing the bits corresponding to the binarized character string of the EO mode and the BO mode respectively is based on the context model The encoding method.
  • the first coding rule may be determined according to any one of a first coding principle, a second coding principle, and a third coding principle;
  • the third coding principle is that the entropy coding mode of each bit in the binarized character string is an equal probability coding mode.
  • the foregoing apparatus may further include:
  • the first determining module 530 is configured to determine whether the preset execution condition is met after the target SAO type of the target coding tree block CTB is determined, where the preset execution condition is: used to indicate the target coding tree unit CTU to which the target CTB belongs Predicting the condition that the transformation accuracy is low;
  • the first determining module 510 can be specifically configured to:
  • the target binary value corresponding to the target SAO type is determined according to the correspondence between each SAO type and the binarized character string recorded in the preset first encoding rule. String.
  • the foregoing first determining module 530 may be specifically configured to:
  • the target image is an image in which the target CTU is located.
  • the foregoing first determining module 530 may be specifically configured to:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the foregoing first determining module 530 may be specifically configured to:
  • Whether the preset execution condition is satisfied is determined based on at least one of the quantization information, the prediction information, and the transformation information of the target coding tree unit CTU of the target CTB to which the target CTB belongs.
  • the foregoing first determining module 530 may be specifically configured to:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the foregoing first determining module 530 may be specifically configured to:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • the first coding rule determined according to the first coding principle may include:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized string is based on the context model. the way.
  • the first coding rule determined according to the first coding principle may include:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is an equal probability coding method. .
  • the first coding rule determined according to the first coding principle may include:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each binarized string, the first bit of the binarized string.
  • the coding mode is equal probability coding.
  • the binarized character string further includes the second bit, the coding mode of the second bit of the binarized character string is based on the context model. .
  • the first coding rule determined according to the second coding principle may include:
  • the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy coding mode of each bit of the binarized character string is based on the context model. the way.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to two.
  • the entropy coding result of the valued string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode
  • the usage probability of the formula is much larger than the usage probability of the BO mode, and is even greater than the use probability of the skip mode in some cases; therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the embodiment of the present application provides The solution can improve the efficiency of video coding.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode.
  • the compression ratio is high, so when the first encoding rule determined by the second coding principle is used to perform the SAO type encoding, the solution provided by the embodiment of the present application can also improve the video encoding efficiency.
  • the entropy coding mode of each bit in the binarized character string is an equal probability coding mode, and the SAO type coding process is performed.
  • the use of no context model can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the embodiment of the present application provides a SAO type decoding apparatus.
  • the decoding apparatus includes:
  • the entropy decoding module 610 is configured to perform entropy decoding on the encoded target binarized character string corresponding to the target coding tree block CTB according to the entropy decoding manner of the encoded binarized character string recorded in the preset first decoding rule. Obtaining a target binarized character string; wherein, the first decoding rule records an entropy decoding manner of the encoded binarized character string, and a correspondence relationship between each SAO type and the binarized character string;
  • the second determining module 620 is configured to determine, according to the correspondence between each SAO type and the binarized character string recorded in the first decoding rule, the target SAO type corresponding to the target binarized character string.
  • the first decoding rule is determined according to any one of the following decoding principles:
  • the first decoding principle the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode;
  • the second decoding principle the EO mode and the BO mode respectively have the same length of the binarized character string; and are used to distinguish the EO mode and the BO mode respectively corresponding to the bits of the encoded binarized character string
  • the entropy decoding method is a decoding method based on a context model
  • the first decoding rule may be determined according to any one of a first decoding principle, a second decoding principle, and a third decoding principle;
  • the third decoding principle is that the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode.
  • the foregoing decoding apparatus may further include:
  • the second judging module 630 is configured to determine, according to the target binarized character string corresponding to the target coding tree block CTB, whether the preset execution condition is met, and the preset execution condition is: indicating the target coding tree to which the target CTB belongs a condition that the prediction conversion accuracy of the unit CTU is low;
  • the entropy decoding module 610 may be specifically configured to:
  • the target target corresponding to the target coding tree block CTB is encoded.
  • the binarized string is entropy decoded to obtain the target binarized string.
  • the foregoing second determining module 630 may be specifically configured to:
  • the target image is an image in which the target CTU is located.
  • the foregoing second determining module 630 may be specifically configured to:
  • the target image is an intra prediction image
  • the quantization parameter used by the target image is greater than the first preset threshold
  • the header information of the target image carries the target identifier information, where the target identifier information is identifier information indicating that the SAO types corresponding to all CTBs in the target image need to be encoded according to the first encoding rule.
  • the target image is not a bidirectional predicted image.
  • the foregoing second determining module 630 may be specifically configured to:
  • Quantization information and prediction information based on the target coding tree unit CTU of the target CTB At least one of the transformation information is used to determine whether the preset execution condition is satisfied.
  • the foregoing second determining module 630 may be specifically configured to:
  • All prediction units in the target CTU are intra prediction units
  • the quantization parameter used by the target CTU is greater than a second preset threshold
  • the average size of all transform units in the target CTU is less than a third preset threshold
  • the average size of all coding units in the target CTU is less than a fourth predetermined threshold.
  • the foregoing second determining module 630 may be specifically configured to:
  • Determining whether the loop filter strength value when performing deblocking filtering on the target coding tree unit CTU to which the target CTB belongs is greater than a fifth preset threshold; if greater than, determining that the preset execution condition is satisfied; otherwise, determining that the preset execution condition is not met .
  • the first decoding rule determined according to the first decoding principle may include:
  • Decoding rules the binarized strings corresponding to EO mode, skip mode and BO mode are 0, 10, 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model The way to decode.
  • the first decoding rule determined according to the first decoding principle may include:
  • the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is equal probability decoding. The way.
  • the first decoding rule determined according to the first decoding principle may include:
  • Decoding rules the binarized strings corresponding to the EO mode, the skip mode, and the BO mode are 0, 10, and 11 respectively; and for each encoded binarized string, the encoded binary string is
  • the decoding mode of one bit is a method of equal probability decoding, and in the case where the encoded binarized character string further includes the second bit, the decoding of the second bit of the encoded binarized character string the way It is a context model based decoding method.
  • the first decoding rule determined according to the second decoding principle may include:
  • Decoding rules the binarized strings corresponding to the skip mode, the BO mode, and the EO mode are 0, 10, and 11 respectively; and the entropy decoding mode of each bit of the encoded binarized string is based on the context model. The way to decode.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, because the solution provided by the embodiment of the present application
  • the length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codeword, that is, the first coding rule applied to match the first decoding rule.
  • the encoder can encode the SAO type of EO mode with a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than that of the BO mode, and sometimes even greater than the skip mode. Probability; Therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the solution provided by the embodiment of the present application can improve the video coding efficiency.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, which is used in the solution provided by the embodiment of the present application.
  • the entropy coding method for distinguishing the bits of the binarized character string corresponding to the EO mode and the BO mode respectively is a coding mode based on the context model, so the encoder pair is used to distinguish the EO mode and the BO mode respectively corresponding to the binarized character string.
  • the compression ratio of the entropy coding performed by the bit is high, that is, the compression ratio of the encoding of the two types of SAOs of the EO mode and the BO mode is high, so the scheme provided by the embodiment of the present application can also improve the video coding efficiency.
  • the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode, and the SAO type decoding process is performed.
  • the use of no context model does not save the decoder's operation of updating the context model and the buffering cost, ensuring low complexity of the decoder while speeding up video decoding.
  • the encoder performs SAO type encoding by using the first encoding rule matched with the first decoding rule, binarization
  • the entropy coding mode of each bit in the string is an equal probability coding method.
  • the SAO type encoding process does not use any context model, which can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the embodiment of the present application further provides an encoder, as shown in FIG. 13, including a first processor 710 and a first memory 720, wherein
  • a first memory 720 configured to store a computer program
  • the target binarization corresponding to the target SAO type is determined according to the correspondence between each SAO type and the binarized character string recorded in the preset first coding rule. a string, wherein the first encoding rule records a correspondence between each SAO type and a binarized string, and an entropy encoding manner of the binarized string;
  • the first coding rule is determined according to any one of the following coding principles:
  • the first coding principle the length of the binarized string corresponding to the EO mode is less than at least one of the lengths of the binarized strings respectively corresponding to the BO mode and the skip mode;
  • the second coding principle the EO mode and the BO mode respectively correspond to the same length of the binarized character string; and the entropy coding mode for distinguishing the bits corresponding to the binarized character string of the EO mode and the BO mode respectively is based on the context model The encoding method.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to the binary value.
  • the entropy coding result of the character string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode usage probability is much larger than the BO mode usage probability. Even at times when it is larger than the skip mode The probability of the video coding efficiency can be improved by the scheme provided by this embodiment when the first coding rule determined by the first coding principle is used for the coding of the SAO type.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode.
  • the compression ratio is high, so when the first coding rule determined by the second coding principle is used to perform the SAO type coding, the solution provided by this embodiment can also improve the video coding efficiency.
  • the entropy coding mode of each bit in the binarized character string is an equal probability coding mode, and the SAO type coding process is performed.
  • the use of no context model can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the embodiment of the present application further provides a decoder, as shown in FIG. 14, including a second processor 810 and a second memory 820, wherein
  • a second memory 820 configured to store a computer program
  • the second processor 810 is configured to perform the following steps when executing the program stored on the second memory 820:
  • the target SAO type corresponding to the target binarized character string is determined according to the correspondence between each SAO type and the binarized character string recorded in the first decoding rule.
  • the first decoding rule is determined according to any one of the following decoding principles:
  • the first decoding principle the length of the binarized character string corresponding to the EO mode is less than at least one of the lengths of the binarized character strings respectively corresponding to the BO mode and the skip mode;
  • the second decoding principle the EO mode and the BO mode respectively correspond to the length of the binarized string
  • the entropy decoding method for distinguishing the bits corresponding to the encoded binary string respectively in the EO mode and the BO mode is a context model based decoding mode.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, because the solution provided by this embodiment is The length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codewords, that is, the first coding rule applied to match the first decoding rule.
  • the encoder can encode the SAO type of the EO mode with a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than that of the BO mode, and sometimes even greater than the skip mode. Therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the solution provided by this embodiment can improve the video coding efficiency.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, and the scheme provided in this embodiment is used to distinguish
  • the entropy coding mode of the bit corresponding to the binarized character string in the EO mode and the BO mode is the context mode-based coding mode, so the encoder pairs the bits corresponding to the binarized character string for distinguishing the EO mode and the BO mode, respectively.
  • the compression ratio of the entropy coding performed by the bit is high, that is, the coding ratio of the coding performed by the AO mode and the BO mode is high, so the scheme provided by this embodiment can also improve the video coding efficiency.
  • the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode
  • the SAO type is in the decoding process.
  • the encoder performs SAO type encoding by using the first encoding rule matched with the first decoding rule, binarization
  • the entropy coding mode of each bit in the string is an equal probability coding mode.
  • the SAO type coding process does not use any context model, which can save the operation of the encoder update context model and the buffer cost, and ensure the encoder. Low complexity while speeding up the video Coding speed.
  • Both the encoder and the decoder described above may be provided with a communication interface for realizing communication between the above self and other devices.
  • the above-mentioned processor, communication interface, and memory complete communication with each other through a communication bus.
  • the communication bus mentioned here may be a Peripheral Component Interconnect (PCI) bus or an extended industry standard structure (Extended Industry) Standard Architecture, EISA) bus, etc.
  • PCI Peripheral Component Interconnect
  • EISA Extended Industry Standard Architecture
  • the communication bus can be divided into an address bus, a data bus, a control bus, and the like.
  • the memory may include a random access memory (RAM), and may also include a non-volatile memory (NVM), such as at least one disk storage.
  • RAM random access memory
  • NVM non-volatile memory
  • the memory may also be at least one storage device located away from the aforementioned processor.
  • the above processor may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; or may be a digital signal processing (DSP), dedicated integration.
  • CPU central processing unit
  • NP network processor
  • DSP digital signal processing
  • ASIC Application Specific Integrated Circuit
  • FPGA Field-Programmable Gate Array
  • the embodiment of the present application further provides a computer readable storage medium, where the computer readable storage medium stores a computer program, and the computer program is implemented by the processor to implement the foregoing.
  • the method steps described for any SAO type encoding method are described for any SAO type encoding method.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to the binary value.
  • the entropy coding result of the character string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode usage probability is much larger than the BO mode usage probability. Even when it is greater than the use probability of the skip mode, the scheme provided by this embodiment can improve the video coding efficiency when the first coding rule determined according to the first coding principle performs the coding of the SAO type.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode.
  • the compression ratio is high, so when the first coding rule determined by the second coding principle is used to perform the SAO type coding, the solution provided by this embodiment can also improve the video coding efficiency.
  • the entropy coding mode of each bit in the binarized character string is an equal probability coding mode, and the SAO type coding process is performed.
  • the use of no context model can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the embodiment of the present application provides another computer readable storage medium, where the computer readable storage medium stores a computer program, and the computer program is implemented by the processor to implement the foregoing.
  • the method steps described in the decoding method of any SAO type are described in the decoding method of any SAO type.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, because the solution provided by this embodiment is The length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codewords, that is, the first coding rule applied to match the first decoding rule.
  • the encoder can encode the SAO type of the EO mode with a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than that of the BO mode, and sometimes even greater than the skip mode. Therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the solution provided by this embodiment can improve the video coding efficiency.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, and the scheme provided in this embodiment is used to distinguish
  • the entropy coding method corresponding to the bits of the binarized character string in the EO mode and the BO mode respectively is the coding mode based on the context model, so the encoder pair is used to distinguish the EO mode and
  • the compression ratio of the entropy coding of the bit corresponding to the binarized character string is high, that is, the coding ratio of the coding of the two types of SAOs of the EO mode and the BO mode is high, so the present embodiment provides The scheme can also improve the video coding efficiency.
  • the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode
  • the SAO type is in the decoding process.
  • the encoder performs SAO type encoding by using the first encoding rule matched with the first decoding rule, binarization
  • the entropy coding mode of each bit in the string is an equal probability coding mode.
  • the SAO type coding process does not use any context model, which can save the operation of the encoder update context model and the buffer cost, and ensure the encoder. Low complexity while speeding up video encoding.
  • the embodiment of the present application provides a computer program product including instructions, when it is run on a computer, causing the computer to execute the coding method of any of the above SAO types. Method steps.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to the binary value.
  • the entropy coding result of the character string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode usage probability is much larger than the BO mode usage probability. Even when it is greater than the use probability of the skip mode, the scheme provided by this embodiment can improve the video coding efficiency when the first coding rule determined according to the first coding principle performs the coding of the SAO type.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode. The compression ratio is high, so according to the second coding principle When the first coding rule is used to perform the coding of the SAO type, the solution provided by this embodiment can also improve the video coding efficiency.
  • the entropy coding mode of each bit in the binarized character string is an equal probability coding mode, and the SAO type coding process is performed.
  • the use of no context model can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the embodiment of the present application provides another computer program product including instructions, when it is run on a computer, causing the computer to perform the decoding method of any of the above SAO types. Method steps.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, because the solution provided by this embodiment is The length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codewords, that is, the first coding rule applied to match the first decoding rule.
  • the encoder can encode the SAO type of the EO mode with a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than that of the BO mode, and sometimes even greater than the skip mode. Therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the solution provided by this embodiment can improve the video coding efficiency.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, and the scheme provided in this embodiment is used to distinguish
  • the entropy coding mode of the bit corresponding to the binarized character string in the EO mode and the BO mode is the context mode-based coding mode, so the encoder pairs the bits corresponding to the binarized character string for distinguishing the EO mode and the BO mode, respectively.
  • the compression ratio of the entropy coding performed by the bit is high, that is, the coding ratio of the coding performed by the AO mode and the BO mode is high, so the scheme provided by this embodiment can also improve the video coding efficiency.
  • the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode, and the SAO type
  • the encoder performs SAO type encoding by using the first encoding rule matched with the first decoding rule, binarization
  • the entropy coding mode of each bit in the string is an equal probability coding mode.
  • the SAO type coding process does not use any context model, which can save the operation of the encoder update context model and the buffer cost, and ensure the encoder. Low complexity while speeding up video encoding.
  • the embodiment of the present application provides a computer program that, when run on a computer, causes the computer to execute the method steps described in any of the above-described SAO type encoding methods.
  • the length of the binary string corresponding to the EO mode is small, so the EO mode corresponds to the binary value.
  • the entropy coding result of the character string occupies less codeword, that is, the encoder can encode the SAO type of the EO mode with a higher compression ratio; since the video coding process, the EO mode usage probability is much larger than the BO mode usage probability. Even when it is greater than the use probability of the skip mode, the scheme provided by this embodiment can improve the video coding efficiency when the first coding rule determined according to the first coding principle performs the coding of the SAO type.
  • the encoder When the first coding rule determined according to the second coding principle performs the SAO type coding, the entropy coding mode for distinguishing the bits corresponding to the binarized character strings respectively of the EO mode and the BO mode is a context model based coding mode. Therefore, the encoder has a high compression ratio for entropy coding of the bits corresponding to the binarized character strings respectively for distinguishing the EO mode and the BO mode, that is, the encoder encodes the two SAO types, EO mode and BO mode.
  • the compression ratio is high, so when the first coding rule determined by the second coding principle is used to perform the SAO type coding, the solution provided by this embodiment can also improve the video coding efficiency.
  • the entropy coding mode of each bit in the binarized character string is an equal probability coding mode, and the SAO type coding process is performed.
  • No context model is used, which saves the encoder update context model Operation and buffer cost ensure low complexity of the encoder and speed up video encoding.
  • the embodiment of the present application provides a computer program that, when run on a computer, causes the computer to execute the method steps described in any of the SAO-type decoding methods described above.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, because the solution provided by this embodiment is The length of the binarized character string corresponding to the EO mode is small, so the entropy coding result of the binarized character string corresponding to the EO mode occupies less codewords, that is, the first coding rule applied to match the first decoding rule.
  • the encoder can encode the SAO type of the EO mode with a high compression ratio; since the EO mode is used in the video encoding process, the probability of use is much larger than that of the BO mode, and sometimes even greater than the skip mode. Therefore, when the first coding rule determined according to the first coding principle performs the coding of the SAO type, the solution provided by this embodiment can improve the video coding efficiency.
  • the encoder performs the SAO type encoding by using the first encoding rule that matches the first decoding rule, and the scheme provided in this embodiment is used to distinguish
  • the entropy coding mode of the bit corresponding to the binarized character string in the EO mode and the BO mode is the context mode-based coding mode, so the encoder pairs the bits corresponding to the binarized character string for distinguishing the EO mode and the BO mode, respectively.
  • the compression ratio of the entropy coding performed by the bit is high, that is, the coding ratio of the coding performed by the AO mode and the BO mode is high, so the scheme provided by this embodiment can also improve the video coding efficiency.
  • the entropy decoding mode of each bit in the encoded binarized character string is an equal probability decoding mode
  • the SAO type is in the decoding process.
  • the encoder performs SAO type encoding by using the first encoding rule matched with the first decoding rule, binarization
  • the entropy coding mode of each bit in the string is an equal probability coding method.
  • the SAO type encoding process does not use any context model, which can save the operation of the encoder update context model and the buffer cost, ensure the low complexity of the encoder, and speed up the video encoding speed.
  • the various embodiments in the present specification are described in a related manner, and the same or similar parts between the various embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments.
  • the embodiments of the apparatus, the encoder, the decoder, the computer readable storage medium, the computer program product containing the instructions, and the computer program are relatively simple and relevant in that they are substantially similar to the method embodiment. See the partial description of the method embodiment.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

L'invention porte sur un procédé et sur un appareil de codage, sur un codeur, sur un décodeur et sur un support d'informations. Le procédé consiste : dans un processus de codage de type de SAO, à déterminer d'abord une chaîne de caractères binaires correspondant au type de SAO selon une première règle de codage et, ensuite, à effectuer un codage entropique sur la chaîne de caractères binaires pour obtenir le résultat de codage entropique, la première règle de codage étant déterminée selon l'un quelconque des principes de codage suivants : le premier principe de codage : la longueur de la chaîne de caractères binaires correspondant à un mode EO étant inférieure à la longueur de la chaîne de caractères binaires correspondant au mode BO et à la longueur de la chaîne de caractères binaires correspondant à un mode de saut ; et un second principe de codage : la longueur d'une chaîne de caractères binaires correspondant au mode EO étant égale à la longueur d'une chaîne de caractères binaires correspondant au mode BO, et une manière de codage entropique de bits correspondants utilisés pour distinguer le mode EO et le mode BO étant une manière de codage basée sur un modèle de contexte.
PCT/CN2017/106547 2017-10-17 2017-10-17 Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations WO2019075638A1 (fr)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201780006030.5A CN108702521B (zh) 2017-10-17 2017-10-17 编码和解码方法、装置、编码器、解码器及存储介质
PCT/CN2017/106547 WO2019075638A1 (fr) 2017-10-17 2017-10-17 Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2017/106547 WO2019075638A1 (fr) 2017-10-17 2017-10-17 Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations

Publications (1)

Publication Number Publication Date
WO2019075638A1 true WO2019075638A1 (fr) 2019-04-25

Family

ID=63844087

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/106547 WO2019075638A1 (fr) 2017-10-17 2017-10-17 Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations

Country Status (2)

Country Link
CN (1) CN108702521B (fr)
WO (1) WO2019075638A1 (fr)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115422115B (zh) * 2022-11-01 2023-02-24 山东云海国创云计算装备产业创新中心有限公司 一种基于总线的编码方法、系统、存储介质及设备

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130188741A1 (en) * 2012-01-21 2013-07-25 General Instrument Corporation Devices and methods for sample adaptive offset coding and/or selection of band offset parameters
CN103391440A (zh) * 2013-07-19 2013-11-13 华为技术有限公司 语法信息的二值化编码处理方法及装置
CN104303506A (zh) * 2012-05-29 2015-01-21 联发科技股份有限公司 自适应采样点偏移信息的编解码装置及方法
CN104396146A (zh) * 2012-07-02 2015-03-04 索尼公司 对于高效率视频编码器(hevc)的采样自适应偏移(sao)的解耦增强

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
BR112014012351A2 (pt) * 2011-11-08 2017-05-30 Motorola Mobility Llc dispositivos e métodos para codificação e/ou de sinalização de deslocamento adaptado de amostra
US9716882B2 (en) * 2012-01-05 2017-07-25 Google Technology Holdings LLC Devices and methods for sample adaptive offset coding and/or selection of edge offset parameters
AU2013290950B2 (en) * 2012-07-16 2016-10-20 Samsung Electronics Co., Ltd. Video encoding method and video encoding apparatus and video decoding method and video decoding apparatus for signaling SAO parameter
CN104486630B (zh) * 2014-12-16 2017-10-20 北京金山云网络技术有限公司 H.265视频编码中sao模式下偏移量的统计方法

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20130188741A1 (en) * 2012-01-21 2013-07-25 General Instrument Corporation Devices and methods for sample adaptive offset coding and/or selection of band offset parameters
CN104303506A (zh) * 2012-05-29 2015-01-21 联发科技股份有限公司 自适应采样点偏移信息的编解码装置及方法
CN104396146A (zh) * 2012-07-02 2015-03-04 索尼公司 对于高效率视频编码器(hevc)的采样自适应偏移(sao)的解耦增强
CN103391440A (zh) * 2013-07-19 2013-11-13 华为技术有限公司 语法信息的二值化编码处理方法及装置

Also Published As

Publication number Publication date
CN108702521A (zh) 2018-10-23
CN108702521B (zh) 2020-03-31

Similar Documents

Publication Publication Date Title
WO2020253828A1 (fr) Procédé et dispositif de codage et de décodage et support de stockage
US10523966B2 (en) Coding transform blocks
TWI499285B (zh) 判定視訊寫碼之解塊濾波之邊界強度值
US10742984B2 (en) Method and apparatus for multi-table based context adaptive binary arithmetic coding
TW201334543A (zh) 判定用於視訊寫碼之解塊濾波的量化參數
CN113812155B (zh) 多种帧间编解码方法之间的交互
TW202007171A (zh) 跨分量編碼順序導出
US9112526B2 (en) Binarization of DQP using separate absolute value and sign (SAVS) in CABAC
WO2019085942A1 (fr) Procédé de prise de décision de mode sao, appareil, dispositif électronique et support de stockage lisible
CN113711597B (zh) 上下文建模和多重变换矩阵的选择
US11350131B2 (en) Signaling coding of transform-skipped blocks
CN110024385B (zh) 影像编码/解码方法、装置以及对比特流进行存储的记录介质
US11695962B2 (en) Encoding and decoding methods and corresponding devices
WO2019086033A1 (fr) Procédé et dispositif de décodage de données vidéo
WO2022116317A1 (fr) Procédés de prédiction intra-image, codeur, décodeur et support de stockage
KR20220036982A (ko) 비디오 인코딩 및 디코딩을 위한 이차 변환
JP2024045346A (ja) ループ内フィルタリングの方法及び装置
CN112369026A (zh) 用于基于一个或多个参考线编码视频数据的设备和方法
US20240040129A1 (en) Residual and coefficients coding for video coding
JP2022521933A (ja) 符号化方法、復号化方法、デコーダ、エンコーダー及び記憶媒体
WO2019075638A1 (fr) Procédé et appareil de codage et de décodage, codeur, décodeur et support d'informations
WO2022227082A1 (fr) Procédés de division de bloc, codeurs, décodeurs et support de stockage informatique
WO2023083239A1 (fr) Procédé et appareil de décodage d'image, et procédé et appareil de codage d'image
CN115398911A (zh) 变换与系数信令的方法和装置
CN115299047A (zh) 使用调色板模式的视频编解码的方法和装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17929038

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17929038

Country of ref document: EP

Kind code of ref document: A1