CN112203085A - Image processing method, device, terminal and storage medium - Google Patents
Image processing method, device, terminal and storage medium Download PDFInfo
- Publication number
- CN112203085A CN112203085A CN202011060097.7A CN202011060097A CN112203085A CN 112203085 A CN112203085 A CN 112203085A CN 202011060097 A CN202011060097 A CN 202011060097A CN 112203085 A CN112203085 A CN 112203085A
- Authority
- CN
- China
- Prior art keywords
- value
- chrominance
- luminance
- frame
- block
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
- 238000003672 processing method Methods 0.000 title claims abstract description 43
- 238000005286 illumination Methods 0.000 claims abstract description 80
- 238000000034 method Methods 0.000 claims abstract description 63
- 238000012545 processing Methods 0.000 claims abstract description 31
- 241000023320 Luma <angiosperm> Species 0.000 claims description 75
- OSWPMRLSEDHDFF-UHFFFAOYSA-N methyl salicylate Chemical compound COC(=O)C1=CC=CC=C1O OSWPMRLSEDHDFF-UHFFFAOYSA-N 0.000 claims description 75
- 230000008859 change Effects 0.000 claims description 45
- 230000008569 process Effects 0.000 abstract description 22
- 230000006835 compression Effects 0.000 abstract description 11
- 238000007906 compression Methods 0.000 abstract description 11
- 238000005070 sampling Methods 0.000 description 28
- 238000010586 diagram Methods 0.000 description 9
- 230000006870 function Effects 0.000 description 9
- 230000001186 cumulative effect Effects 0.000 description 8
- 238000004590 computer program Methods 0.000 description 7
- 238000004891 communication Methods 0.000 description 5
- 230000003287 optical effect Effects 0.000 description 5
- 238000004364 calculation method Methods 0.000 description 3
- 238000012417 linear regression Methods 0.000 description 3
- 230000002123 temporal effect Effects 0.000 description 3
- 230000009466 transformation Effects 0.000 description 3
- 239000000835 fiber Substances 0.000 description 2
- 230000000644 propagated effect Effects 0.000 description 2
- 239000004065 semiconductor Substances 0.000 description 2
- 238000003491 array Methods 0.000 description 1
- 230000005540 biological transmission Effects 0.000 description 1
- 230000006837 decompression Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000006073 displacement reaction Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 239000013307 optical fiber Substances 0.000 description 1
- 238000009877 rendering Methods 0.000 description 1
- 230000002441 reversible effect Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/50—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
- H04N19/503—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
- H04N19/51—Motion estimation or motion compensation
- H04N19/513—Processing of motion vectors
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/102—Methods 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/103—Selection of coding mode or of prediction mode
- H04N19/109—Selection of coding mode or of prediction mode among a plurality of temporal predictive coding modes
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/169—Methods 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/186—Methods 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
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
技术领域technical field
本公开涉及图像处理技术领域,尤其涉及一种图像处理方法、装置、终端和存储介质。The present disclosure relates to the technical field of image processing, and in particular, to an image processing method, device, terminal, and storage medium.
背景技术Background technique
视频中包括有大量的图像帧,每个图像帧中包含了几万或十几万的像素,每一个像素一般采用24位来进行表示,因此一个视频需要占用大量的存储空间以及传输带宽,为了减少视频占用的空间和带宽,通常会在传输视频时对视频进行压缩,即对视频进行编码,在播放视频前对视频进行解压缩,即对视频进行解码。通常来说,视频的压缩技术包括帧内压缩和帧间压缩,帧内压缩用于去除图像帧中的空域冗余,帧间压缩用于去除图像的时域冗余。A video contains a large number of image frames, each image frame contains tens of thousands or hundreds of thousands of pixels, and each pixel is generally represented by 24 bits, so a video needs to occupy a lot of storage space and transmission bandwidth. To reduce the space and bandwidth occupied by the video, the video is usually compressed when the video is transmitted, that is, the video is encoded, and the video is decompressed before the video is played, that is, the video is decoded. Generally speaking, video compression techniques include intra-frame compression and inter-frame compression. Intra-frame compression is used to remove spatial redundancy in image frames, and inter-frame compression is used to remove temporal redundancy of images.
发明内容SUMMARY OF THE INVENTION
为解决现有问题,本公开提供一种图像处理方法、装置、终端和存储介质。In order to solve the existing problems, the present disclosure provides an image processing method, device, terminal and storage medium.
本公开采用以下的技术方案。The present disclosure adopts the following technical solutions.
在一些实施例中,本公开提供一种图像处理方法,包括:In some embodiments, the present disclosure provides an image processing method, comprising:
确定当前图像块的参考块,其中,当前图像块位于当前帧,参考块位于当前帧的参考帧;Determine the reference block of the current image block, wherein the current image block is located in the current frame, and the reference block is located in the reference frame of the current frame;
确定参考块的亮度重构值和参考块的色度重构值;determining the luma reconstruction value of the reference block and the chroma reconstruction value of the reference block;
对参考块的亮度重构值进行光照补偿,得到参考块的亮度补偿值;Perform illumination compensation on the brightness reconstruction value of the reference block to obtain the brightness compensation value of the reference block;
确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为参考块的亮度补偿值,当前图像块的色度预测值为参考块的色度重构值。Determine the luma predicted value and the chrominance predicted value of the current image block, wherein the luma predicted value of the current image block is the luma compensation value of the reference block, and the chrominance predicted value of the current image block is the chrominance reconstruction value of the reference block.
在一些实施例中,还包括:确定当前帧携带的开关标志位的取值为第一取值。In some embodiments, the method further includes: determining the value of the switch flag bit carried in the current frame to be the first value.
在一些实施例中,当前帧携带的开关标志位的取值是根据当前帧的亮度分量与参考帧的亮度分量的差异,以及当前帧的色度分量与参考帧的色度分量的差异确定的。In some embodiments, the value of the switch flag bit carried by the current frame is determined according to the difference between the luminance component of the current frame and the luminance component of the reference frame, and the difference between the chrominance component of the current frame and the chrominance component of the reference frame .
在一些实施例中,在第一变化值和第二变化值的差值大于差异阈值的情况下,当前帧携带的开关标志位的取值为第一取值,其中,第一变化值为当前帧的亮度分量与参考帧的亮度分量的差值,第二变化值为当前帧的色度分量与参考帧的色度分量的差值。In some embodiments, when the difference between the first change value and the second change value is greater than the difference threshold, the value of the switch flag carried in the current frame is the first value, wherein the first change value is the current The difference between the luminance component of the frame and the luminance component of the reference frame, and the second change value is the difference between the chrominance component of the current frame and the chrominance component of the reference frame.
在一些实施例中,当前图像块的亮度预测值根据公式(1)确定:In some embodiments, the luminance prediction value of the current image block is determined according to formula (1):
其中,为当前图像块的亮度预测值,为参考块的亮度重构值,αY为亮度分量的颜色通道缩放系数,βY为亮度分量的偏移量。in, is the luminance prediction value of the current image block, is the luminance reconstruction value of the reference block, α Y is the color channel scaling factor of the luminance component, and β Y is the offset of the luminance component.
在一些实施例中,所述确定所述当前图像块的亮度预测值和色度预测值,包括:若当前帧携带的开关标志位的取值为第一取值,所述当前图像块的亮度预测值为所述参考块的亮度补偿值,所述当前图像块的色度预测值为所述参考块的色度重构值。In some embodiments, the determining the luma predicted value and the chrominance predicted value of the current image block includes: if the value of the switch flag carried in the current frame is a first value, the luma of the current image block The predicted value is the luminance compensation value of the reference block, and the chrominance predicted value of the current image block is the chrominance reconstruction value of the reference block.
若当前帧携带的开关标志位的取值为第二取值,当前图像块的亮度预测值和色度预测值,分别等于参考块的亮度重构值和色度重构值;或者,当前图像块的亮度预测值和色度预测值,分别等于参考块的亮度补偿值和色度补偿值,色度补偿值是对参考帧的色度重构值进行光照补偿后的值。If the value of the switch flag bit carried in the current frame is the second value, the luma predicted value and the chrominance predicted value of the current image block are respectively equal to the luma reconstruction value and the chrominance reconstruction value of the reference block; or, the current image The luma predicted value and the chrominance predicted value of the block are respectively equal to the luma compensation value and the chrominance compensation value of the reference block, and the chrominance compensation value is a value obtained by performing illumination compensation on the chrominance reconstruction value of the reference frame.
在一些实施例中,本公开提供一种图像处理方法,包括:In some embodiments, the present disclosure provides an image processing method, comprising:
确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,其中,当前图像块位于当前帧,色度分量的运动矢量与同位运动矢量不同,同位运动矢量为亮度分量的运动矢量,或者,同位运动矢量是根据亮度采样率和色度采样率对亮度分量的运动矢量进行缩放后得到的运动矢量;Determine the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, where the current image block is located in the current frame, the motion vector of the chrominance component is different from the co-located motion vector, and the co-located motion vector is the motion vector of the luminance component, or , the co-located motion vector is the motion vector obtained by scaling the motion vector of the luminance component according to the luminance sampling rate and the chrominance sampling rate;
根据当前图像块的亮度分量的运动矢量和色度分量的运动矢量确定当前图像块的亮度分量的亮度参考块和当前图像块的色度分量的色度参考块,其中亮度参考块和色度参考块位于当前帧的参考帧;Determine the luminance reference block of the luminance component of the current image block and the chrominance reference block of the chrominance component of the current image block according to the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, wherein the luminance reference block and the chrominance reference block The block is located in the reference frame of the current frame;
确定亮度参考块的亮度重构值和色度参考块的色度重构值;determining the luma reconstruction value of the luma reference block and the chroma reconstruction value of the chroma reference block;
对亮度参考块的亮度重构值进行光照补偿,得到亮度参考块的亮度补偿值;Perform illumination compensation on the luminance reconstruction value of the luminance reference block to obtain the luminance compensation value of the luminance reference block;
对色度参考块的色度重构值进行光照补偿,得到色度参考块的色度补偿值;Perform illumination compensation on the chrominance reconstruction value of the chrominance reference block to obtain the chrominance compensation value of the chrominance reference block;
确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度补偿值。Determine the luma predicted value and the chrominance predicted value of the current image block, where the luma predicted value of the current image block is the luma compensation value of the luma reference block, and the chrominance predicted value of the current image block is the chrominance compensation value of the chrominance reference block .
在一些实施例中,色度参考块的运动矢量与当前图像块的色度分量的运动矢量相同。In some embodiments, the motion vector of the chroma reference block is the same as the motion vector of the chroma component of the current image block.
在一些实施例中,当前图像块的色度分量的运动矢量为(0,0)。In some embodiments, the motion vector of the chroma component of the current image block is (0,0).
在一些实施例中,当前图像块的色度分量的运动矢量选自矢量候选列表,通过编码色度分量的运动矢量在矢量候选列表中的索引以记录色度分量的运动矢量。In some embodiments, the motion vector of the chrominance component of the current image block is selected from the vector candidate list, and the motion vector of the chrominance component is recorded by encoding the index of the motion vector of the chrominance component in the vector candidate list.
在一些实施例中,采用公式(2)得到当前图像块的亮度预测值:In some embodiments, formula (2) is used to obtain the luminance prediction value of the current image block:
其中,为当前图像块的亮度预测值,为参考块的亮度重构值,αY为亮度分量的颜色通道缩放系数,βY为亮度分量的偏移量;in, is the luminance prediction value of the current image block, is the luminance reconstruction value of the reference block, α Y is the color channel scaling factor of the luminance component, and β Y is the offset of the luminance component;
和/或,and / or,
采用公式(3)和公式(4)得到当前图像块的色度预测值:Use formula (3) and formula (4) to obtain the chrominance prediction value of the current image block:
其中,为当前图像块的色度预测值的U分量,为所述当前图像块的色度预测值的V分量,为色度参考块的色度重构值的U分量,为色度参考块的色度重构值的V分量,αU为U分量的颜色通道缩放系数,αV为V分量的颜色通道缩放系数,βU为U分量的偏移量,βV为V分量的偏移量。in, is the U component of the chroma prediction value of the current image block, is the V component of the chrominance prediction value of the current image block, is the U component of the chrominance reconstruction value of the chrominance reference block, is the V component of the chrominance reconstruction value of the chrominance reference block, α U is the color channel scaling coefficient of the U component, α V is the color channel scaling coefficient of the V component, β U is the offset of the U component, and β V is The offset of the V component.
在一些实施例中,确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,包括:In some embodiments, determining the motion vector of the luminance component and the motion vector of the chrominance component of the current image block includes:
确定所述当前帧携带的开关标志位的取值;Determine the value of the switch flag bit carried by the current frame;
若所述当前帧的开关标志位的取值为第一取值,所述当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度重构值;If the value of the switch flag of the current frame is the first value, the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the luminance compensation value of the chrominance reference block. chrominance reconstruction value;
若所述当前帧的开关标志位的取值为第二取值,所述当前图像块的亮度预测值为所述亮度参考块的亮度补偿值,所述当前图像块的色度预测值为所述色度参考块的色度补偿值。If the value of the switch flag of the current frame is the second value, the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the The chrominance compensation value of the chrominance reference block.
在一些实施例中,当前帧携带的开关标志位的取值是根据当前帧的亮度分量与参考帧的亮度分量的差异,以及当前帧的色度分量与参考帧的色度分量的差异确定的。In some embodiments, the value of the switch flag bit carried by the current frame is determined according to the difference between the luminance component of the current frame and the luminance component of the reference frame, and the difference between the chrominance component of the current frame and the chrominance component of the reference frame .
在一些实施例中,在第一变化值和第二变化值的差值大于差异阈值的情况下,当前帧携带的开关标志位的取值为第一取值,其中,第一变化值为当前帧的亮度分量与参考帧的亮度分量的差值,第二变化值为当前帧的色度分量与参考帧的色度分量的差值。In some embodiments, when the difference between the first change value and the second change value is greater than the difference threshold, the value of the switch flag carried in the current frame is the first value, wherein the first change value is the current The difference between the luminance component of the frame and the luminance component of the reference frame, and the second change value is the difference between the chrominance component of the current frame and the chrominance component of the reference frame.
一些实施例中,本公开提出一种图像处理装置,包括:In some embodiments, the present disclosure provides an image processing apparatus, including:
确定单元,用于确定当前图像块的参考块,其中,当前图像块位于当前帧,参考块位于当前帧的参考帧;A determining unit for determining the reference block of the current image block, wherein the current image block is located in the current frame, and the reference block is located in the reference frame of the current frame;
确定单元,还用于确定参考块的亮度重构值和参考块的色度重构值;a determining unit, further configured to determine the luminance reconstruction value of the reference block and the chrominance reconstruction value of the reference block;
处理单元,用于对参考块的亮度重构值进行光照补偿,得到参考块的亮度补偿值;a processing unit, configured to perform illumination compensation on the luminance reconstruction value of the reference block to obtain the luminance compensation value of the reference block;
确定单元,还用于确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为参考块的亮度补偿值,当前图像块的色度预测值为参考块的色度重构值。The determining unit is further configured to determine the luminance prediction value and the chrominance prediction value of the current image block, wherein the luminance prediction value of the current image block is the luminance compensation value of the reference block, and the chrominance prediction value of the current image block is the color value of the reference block. degree reconstruction value.
在一些实施例中,本公开提出一种图像处理装置,包括:In some embodiments, the present disclosure provides an image processing apparatus, comprising:
确定模块,用于确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,其中,所述当前图像块位于当前帧,所述色度分量的运动矢量与同位运动矢量不同,所述同位运动矢量为所述亮度分量的运动矢量,或者,所述同位运动矢量是根据亮度采样率和色度采样率对所述亮度分量的运动矢量进行缩放后得到的运动矢量;A determination module, configured to determine the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, wherein the current image block is located in the current frame, the motion vector of the chrominance component is different from the co-located motion vector, the The co-located motion vector is the motion vector of the luminance component, or the co-located motion vector is a motion vector obtained by scaling the motion vector of the luminance component according to the luminance sampling rate and the chrominance sampling rate;
所述确定模块,还用于根据所述当前图像块的亮度分量的运动矢量和色度分量的运动矢量确定所述当前图像块的亮度分量的亮度参考块和所述当前图像块的色度分量的色度参考块,其中所述亮度参考块和色度参考块位于所述当前帧的参考帧;The determining module is further configured to determine the luminance reference block of the luminance component of the current image block and the chrominance component of the current image block according to the motion vector of the luminance component and the motion vector of the chrominance component of the current image block The chrominance reference block, wherein the luma reference block and the chrominance reference block are located in the reference frame of the current frame;
所述确定模块,还用于确定所述亮度参考块的亮度重构值和所述色度参考块的色度重构值;The determining module is further configured to determine the luminance reconstruction value of the luminance reference block and the chrominance reconstruction value of the chrominance reference block;
处理模块,用于对所述亮度参考块的亮度重构值进行光照补偿,得到所述亮度参考块的亮度补偿值;a processing module, configured to perform illumination compensation on the luminance reconstruction value of the luminance reference block to obtain the luminance compensation value of the luminance reference block;
处理模块,还用于对所述色度参考块的色度重构值进行光照补偿,得到所述色度参考块的色度补偿值;a processing module, further configured to perform illumination compensation on the chrominance reconstruction value of the chrominance reference block to obtain the chrominance compensation value of the chrominance reference block;
确定模块,还用于确定所述当前图像块的亮度预测值和色度预测值,其中,所述当前图像块的亮度预测值为所述亮度参考块的亮度补偿值,所述当前图像块的色度预测值为所述色度参考块的色度补偿值。The determining module is further configured to determine the luminance prediction value and the chrominance prediction value of the current image block, wherein the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the luminance prediction value of the current image block is a luminance compensation value of the luminance reference block. The chrominance prediction value is the chrominance compensation value of the chrominance reference block.
在一些实施例中,本公开提供一种终端,包括:至少一个存储器和至少一个处理器;In some embodiments, the present disclosure provides a terminal comprising: at least one memory and at least one processor;
其中,存储器用于存储程序代码,处理器用于调用存储器所存储的程序代码执行上述的方法。The memory is used for storing program codes, and the processor is used for calling the program codes stored in the memory to execute the above method.
在一些实施例中,本公开提供一种存储介质,存储介质用于存储程序代码,程序代码用于执行上述的方法。In some embodiments, the present disclosure provides a storage medium for storing program codes for performing the above-described methods.
本公开实施例提供的图像处理方法,通过在帧间预测过程仅对亮度分量进行光照补偿(减少了对色度分量进行光照补偿的步骤),减少了视频编码和视频解码过程中的数据处理量,降低了视频编解码的复杂度。本公开实施例提出的方法还可以提高色度分量预测的准确度,从而减少残差,降低编码码率,因而可以提高编码压缩性能。The image processing method provided by the embodiments of the present disclosure reduces the amount of data processing in the process of video encoding and video decoding by only performing illumination compensation on the luminance component in the inter-frame prediction process (reducing the step of performing illumination compensation on the chrominance component). , reducing the complexity of video encoding and decoding. The methods proposed in the embodiments of the present disclosure can also improve the accuracy of chrominance component prediction, thereby reducing residual errors and reducing the coding rate, thus improving the coding compression performance.
附图说明Description of drawings
结合附图并参考以下具体实施方式,本公开各实施例的上述和其他特征、优点及方面将变得更加明显。贯穿附图中,相同或相似的附图标记表示相同或相似的元素。应当理解附图是示意性的,元件和元素不一定按照比例绘制。The above and other features, advantages and aspects of various embodiments of the present disclosure will become more apparent when taken in conjunction with the accompanying drawings and with reference to the following detailed description. Throughout the drawings, the same or similar reference numbers refer to the same or similar elements. It should be understood that the drawings are schematic and that elements and elements are not necessarily drawn to scale.
图1是本公开实施例的一种图像处理方法的流程图。FIG. 1 is a flowchart of an image processing method according to an embodiment of the present disclosure.
图2是本公开实施例的当前图像块和当前图像块对应的参考块的示意图。FIG. 2 is a schematic diagram of a current image block and a reference block corresponding to the current image block according to an embodiment of the present disclosure.
图3是本公开实施例的另一种图像处理方法的流程图。FIG. 3 is a flowchart of another image processing method according to an embodiment of the present disclosure.
图4是本公开实施例的一种图像处理装置的组成图。FIG. 4 is a composition diagram of an image processing apparatus according to an embodiment of the present disclosure.
图5是本公开实施例的另一种图像处理装置的组成图。FIG. 5 is a composition diagram of another image processing apparatus according to an embodiment of the present disclosure.
图6是本公开实施例的电子设备的结构示意图。FIG. 6 is a schematic structural diagram of an electronic device according to an embodiment of the present disclosure.
具体实施方式Detailed ways
下面将参照附图更详细地描述本公开的实施例。虽然附图中显示了本公开的某些实施例,然而应当理解的是,本公开可以通过各种形式来实现,而且不应该被解释为限于这里阐述的实施例,相反提供这些实施例是为了更加透彻和完整地理解本公开。应当理解的是,本公开的附图及实施例仅用于示例性作用,并非用于限制本公开的保护范围。Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for the purpose of A more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the present disclosure are only for exemplary purposes, and are not intended to limit the protection scope of the present disclosure.
应当理解,本公开的方法实施方式中记载的各个步骤可以按和/或并行执行。此外,方法实施方式可以包括附加的步骤和/或省略执行示出的步骤。本公开的范围在此方面不受限制。It should be understood that the various steps described in the method embodiments of the present disclosure may be performed in sequence and/or in parallel. Furthermore, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this regard.
本文使用的术语“包括”及其变形是开放性包括,即“包括但不限于”。术语“基于”是“至少部分地基于”。术语“一个实施例”表示“至少一个实施例”;术语“另一实施例”表示“至少一个另外的实施例”;术语“一些实施例”表示“至少一些实施例”。其他术语的相关定义将在下文描述中给出。As used herein, the term "including" and variations thereof are open-ended inclusions, ie, "including but not limited to". The term "based on" is "based at least in part on." The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Relevant definitions of other terms will be given in the description below.
需要注意,本公开中提及的“第一”、“第二”等概念仅用于对不同的装置、模块或单元进行区分,并非用于限定这些装置、模块或单元所执行的功能的顺序或者相互依存关系。It should be noted that concepts such as "first" and "second" mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not used to limit the order of functions performed by these devices, modules or units or interdependence.
需要注意,本公开中提及的“一个”的修饰是示意性而非限制性的,本领域技术人员应当理解,除非在上下文另有明确指出,否则应该理解为“一个或多个”。It should be noted that the modification of "a" mentioned in the present disclosure is illustrative rather than restrictive, and those skilled in the art should understand that unless the context clearly indicates otherwise, it should be understood as "one or more".
本公开实施方式中的多个装置之间所交互的消息或者信息的名称仅用于说明性的目的,而并不是用于对这些消息或信息的范围进行限制。The names of messages or information exchanged between multiple devices in the embodiments of the present disclosure are only for illustrative purposes, and are not intended to limit the scope of these messages or information.
随着短视频应用的兴起,越来越多的用户通过手机等移动终端拍摄短视频并进行分享,这类用户生成(UGC,User Generated Content)视频与传统拍摄的视频具有显著区别,UGC视频一般由非专业用户使用非专业设备,在非专业光照场景中拍摄,因此同一视频中的光线变化明显,UGC视频的拍摄设备多样、场景多样、视频内容多样,且UGC视频通常会经过特效以及滤镜的渲染;UGC视频通常由用户通过手持终端设备如手机、平板拍摄,压缩后上传视频平台。UGC视频在拍摄后会进行编码压缩上传,提升视频压缩效率有助于节省流量带宽与计算功耗。With the rise of short video applications, more and more users shoot and share short videos through mobile terminals such as mobile phones. Such User Generated Content (UGC, User Generated Content) videos are significantly different from traditionally shot videos. UGC videos generally Non-professional users use non-professional equipment to shoot in non-professional lighting scenes, so the light in the same video changes significantly. UGC videos are shot with various equipment, scenes, and video content, and UGC videos usually go through special effects and filters. Rendering; UGC videos are usually shot by users through handheld terminal devices such as mobile phones and tablets, and then uploaded to the video platform after being compressed. UGC video will be encoded, compressed and uploaded after shooting. Improving the video compression efficiency will help save traffic bandwidth and computing power consumption.
一些技术中,在对视频进行帧间压缩时,为解决时域相邻帧间的局部光照变化问题,在帧间预测的运动补偿阶段,对当前进行帧间编码的编码单元的亮度分量和色度分量分别进行局部光照补偿,并且亮度编码单元(亮度块)与色度编码单元(色度块)共享运动矢量,然而,对于亮度编码单元和色度编码单元都进行光照补偿可能会降低色度分量的预测性能,并且会增加编码的复杂度。In some technologies, in order to solve the problem of local illumination changes between adjacent frames in the time domain when inter-frame compression is performed on the video, in the motion compensation stage of inter-frame prediction, the luminance component and color of the coding unit currently undergoing inter-frame coding are calculated. The luminance components are separately compensated for local illumination, and the luma coding unit (luma block) shares the motion vector with the chroma coding unit (chroma block), however, the illumination compensation for both the luma coding unit and the chroma coding unit may reduce the chroma Predictive performance of the components, and will increase the complexity of the coding.
为了至少部分解决上述问题,本公开实施例中提出一种图像处理方法,本实施例中的图像可以是视频中的图像,以下将结合附图,对本申请实施例提供的方案进行详细描述。In order to at least partially solve the above problem, an image processing method is proposed in this embodiment of the present disclosure. The image in this embodiment may be an image in a video. The solution provided by the embodiment of the present application will be described in detail below with reference to the accompanying drawings.
如图1所示,图1是本公开实施例的一种图像处理方法的流程图,包括如下步骤。As shown in FIG. 1 , FIG. 1 is a flowchart of an image processing method according to an embodiment of the present disclosure, including the following steps.
S11:确定当前图像块的参考块。S11: Determine the reference block of the current image block.
具体的,当前图像块位于当前帧,参考块位于当前帧的参考帧,在一些实施例中,图像可以是视频中的图像,视频可以是UGC视频,本公开提出的图像处理方法可以用于视频压缩或解压缩的帧间预测过程,视频包括有多个图像帧,当前帧可以是视频中任何需要进行帧间预测的图像帧,当前帧例如可以是P图像或B图像,当前帧包括多个编码单元,此处的当前图像块可以为任一编码单元,对于在进行帧间预测的过程中,当前帧会对应有一个参考帧,也就是用于预测的图像,通常也称为参考图像(Reference Frame),参考帧例如可以是当前帧时域上相邻的前一图像帧或后一图像帧,当前帧的参考帧也包括多个编码单元,与当前图像块对应的编码单元即作为参考块,参考块到当前图像块的位移通常称为运动矢量(Motion Vector,MV),当前图像块与参考块的差值通常称为预测残差(PredictionResidual),在视频编码过程中,确定当前图像块对应的参考块的过程通常称为运动估计(Motion Estimation),本实施例中确定当前图像块对应的参考块的方法可以和现有技术相同,例如可以采用全搜索算法、二维对数搜索算法、三步搜索法等,对此并不做限定。Specifically, the current image block is located in the current frame, and the reference block is located in the reference frame of the current frame. In some embodiments, the image may be an image in a video, and the video may be a UGC video. The image processing method proposed in the present disclosure can be used for video The inter-frame prediction process of compression or decompression. The video includes multiple image frames. The current frame can be any image frame in the video that needs to be inter-predicted. For example, the current frame can be a P image or a B image. The current frame includes multiple image frames. Coding unit, the current image block here can be any coding unit. In the process of inter-frame prediction, the current frame will correspond to a reference frame, that is, the image used for prediction, which is also commonly referred to as a reference image ( Reference Frame), the reference frame can be, for example, the previous image frame or the next image frame adjacent to the current frame time domain, the reference frame of the current frame also includes a plurality of coding units, and the coding unit corresponding to the current image block is used as a reference Block, the displacement from the reference block to the current image block is usually called a motion vector (Motion Vector, MV), and the difference between the current image block and the reference block is usually called the prediction residual (Prediction Residual). The process of the reference block corresponding to the block is usually called motion estimation (Motion Estimation). Algorithms, three-step search methods, etc., are not limited.
S12:确定参考块的亮度重构值和参考块的色度重构值。S12: Determine the luminance reconstruction value of the reference block and the chrominance reconstruction value of the reference block.
S13:对参考块的亮度重构值进行光照补偿,得到参考块的亮度补偿值。S13: Perform illumination compensation on the luminance reconstruction value of the reference block to obtain the luminance compensation value of the reference block.
具体的,亮度补偿值是对亮度重构值进行光照补偿后得到的亮度值。Specifically, the luminance compensation value is a luminance value obtained by performing illumination compensation on the luminance reconstruction value.
S14:确定当前图像块的亮度预测值和色度预测值。S14: Determine the luminance prediction value and the chrominance prediction value of the current image block.
具体的,当前图像块的亮度预测值为参考块的亮度补偿值,当前图像块的色度预测值为参考块的色度重构值。本实施例中对于颜色可采用亮度加色度的颜色空间,即YUV颜色空间,Y表示亮度,也就是灰阶值,U和V表示的是色度。光照补偿是为了解决时域相邻帧间的局部光照变化问题,作用于帧间预测的运动补偿阶段,在现有技术中,确定当前帧的亮度预测值和色度预测值时,采用相同的光照补偿方法,分别对当前图像块对应的参考块的亮度重构值和色度重构值进行光照补偿后的值作为当前图像块的亮度预测值和色度预测值,而在本实施例中,在确定当前图像块的亮度预测值时,用对当前图像块对应的参考块的亮度重构值进行光照补偿后的值作为当前图像块的亮度预测值,直接使用当前图像块对应的参考块的色度重构值作为当前图像块的色度预测值,而无需对色度预测值进行光照补偿,相比于现有技术,本实施例中的图像处理方法在帧间预测过程通过减少了对色度预测值进行光照补偿的步骤,减少了视频编码和视频解码过程中的数据处理量,降低了复杂度,并且当前图像块的色度相对于参考块的色度可能是未变化的,现有技术中对色度预测值进行光照补偿会降低色度分量的预测准确度,例如当本实施例中的视频为连续拍摄的视频时(例如UGC视频),当前图像块的色度分量与参考块的色度分量相近,此时不对色度预测值进行光照补偿减少了数据处理量,降低了编码和解码的复杂度,提高了编码效率并且当前图像块的色度分量的预测更准确。Specifically, the luminance prediction value of the current image block is the luminance compensation value of the reference block, and the chrominance prediction value of the current image block is the chrominance reconstruction value of the reference block. In this embodiment, a color space of luminance and chrominance may be used for the color, that is, the YUV color space, Y represents the luminance, that is, the grayscale value, and U and V represent the chromaticity. Illumination compensation is to solve the problem of local illumination changes between adjacent frames in the time domain, and acts on the motion compensation stage of inter-frame prediction. In the prior art, when determining the luminance prediction value and chrominance prediction value of the current frame, the same In the illumination compensation method, the luminance reconstruction value and the chrominance reconstruction value of the reference block corresponding to the current image block are respectively subjected to illumination compensation as the luminance prediction value and chrominance prediction value of the current image block. , when determining the brightness prediction value of the current image block, the value obtained after performing illumination compensation on the brightness reconstruction value of the reference block corresponding to the current image block is used as the brightness prediction value of the current image block, and the reference block corresponding to the current image block is directly used. The chrominance reconstruction value of the current image block is used as the chrominance prediction value of the current image block, and there is no need to perform illumination compensation on the chrominance prediction value. Compared with the prior art, the image processing method in this embodiment reduces the amount of The step of performing illumination compensation on the chrominance prediction value reduces the amount of data processing in the process of video encoding and video decoding, and reduces the complexity, and the chrominance of the current image block may be unchanged relative to the chrominance of the reference block, Performing illumination compensation on the chrominance predicted value in the prior art will reduce the prediction accuracy of the chrominance component. For example, when the video in this embodiment is a continuously shot video (such as a UGC video), the chrominance component of the current image block and The chrominance components of the reference block are similar, and the illumination compensation of the chrominance prediction value is not performed at this time, which reduces the amount of data processing, reduces the complexity of encoding and decoding, improves the encoding efficiency, and the prediction of the chrominance components of the current image block is more accurate.
在本公开的一些实施例中,采用公式(1)得到当前图像块的亮度预测值:In some embodiments of the present disclosure, formula (1) is used to obtain the luminance prediction value of the current image block:
其中,为当前图像块的亮度预测值,为当前图像块对应的参考块的亮度重构值,αY为亮度分量的颜色通道缩放系数,βY为亮度分量的偏移量。in, is the luminance prediction value of the current image block, is the luminance reconstruction value of the reference block corresponding to the current image block, α Y is the color channel scaling coefficient of the luminance component, and β Y is the offset of the luminance component.
具体的,在一些实施例中,在帧间预测的过程中采用线性光照变换模型对当前图像块对应的参考块的亮度预测值进行光照补偿,其中αY和βY可以根据当前帧中当前图像块的邻近参考像素和对应的参考块的邻近参考像素以线性回归的方式导出,举例而言,请参考图2,图2中的2a为当前图像块和当前图像块的邻近考像素,图2中的2b为当前图像块对应的参考块以及参考块的邻近参考像素,图2中实心的圆为邻近参考像素,可以使用当前图像块的邻近参考像素以及其对应的参考块的邻近参考像素的平方误差来得到参数αY、βY。Specifically, in some embodiments, in the process of inter-frame prediction, a linear illumination transformation model is used to perform illumination compensation on the luminance prediction value of the reference block corresponding to the current image block, wherein α Y and β Y can be based on the current image in the current frame. The adjacent reference pixels of the block and the adjacent reference pixels of the corresponding reference block are derived by linear regression. For example, please refer to FIG. 2. 2a in FIG. 2 is the current image block and the adjacent reference pixels of the current image block, FIG. 2 2b is the reference block corresponding to the current image block and the adjacent reference pixels of the reference block, the solid circle in Fig. 2 is the adjacent reference pixels, the adjacent reference pixels of the current image block and the adjacent reference pixels of the corresponding reference block can be used. Square the error to get the parameters α Y , β Y .
现有技术中,通常对需要进行光照补偿的编码单元的三个颜色分量(Y,U,V)同时进行光照补偿,但是,根据UGC视频的特点,视频的图像帧之间会有光照发生变化,但色度不发生变化或发生的变化较小,也就是亮度发生变化但色度基本不发生变化,因此本公开的一些实施例中只对当前图像块的亮度分量Y进行局部光照补偿,对色度分量(U,V)不进行光照补偿,直接使用当前图像块对应的参考块的色度分量进行预测,即其中是当前图像块的色度分量中U分量的预测值,是当前图像块的色度分量中U分量的重构值,是当前图像块对应的参考帧中参考块的色度分量中U分量的重构值,是当前图像块对应的参考帧中参考块的色度分量中V分量的重构值。通过这种方式,不但降低了数据处理的复杂度,提高了编码解码效率,并且还提高了色度预测值的准确度,还可提高压缩性能。In the prior art, illumination compensation is usually performed simultaneously on the three color components (Y, U, V) of the coding unit that needs illumination compensation. However, according to the characteristics of UGC video, there will be illumination changes between image frames of the video. , but the chromaticity does not change or the change is small, that is, the luminance changes but the chromaticity basically does not change. Therefore, in some embodiments of the present disclosure, only local illumination compensation is performed on the luminance component Y of the current image block. The chrominance components (U, V) do not perform illumination compensation, and directly use the chrominance components of the reference block corresponding to the current image block for prediction, that is in is the predicted value of the U component in the chrominance component of the current image block, is the reconstructed value of the U component in the chroma component of the current image block, is the reconstructed value of the U component in the chrominance component of the reference block in the reference frame corresponding to the current image block, is the reconstructed value of the V component in the chrominance component of the reference block in the reference frame corresponding to the current image block. In this way, not only the complexity of data processing is reduced, the coding and decoding efficiency is improved, but also the accuracy of the chrominance prediction value is improved, and the compression performance is also improved.
在本公开的一些实施例中,所述确定所述当前图像块的亮度预测值和色度预测值,包括:确定当前帧是目标帧或非目标帧,若当前图像帧是目标帧,所述当前图像块的亮度预测值为所述参考块的亮度补偿值,所述当前图像块的色度预测值为所述参考块的色度重构值。In some embodiments of the present disclosure, the determining the luma predicted value and the chrominance predicted value of the current image block includes: determining whether the current frame is a target frame or a non-target frame, and if the current image frame is a target frame, the The luminance prediction value of the current image block is the luminance compensation value of the reference block, and the chrominance prediction value of the current image block is the chrominance reconstruction value of the reference block.
若当前帧是非目标帧,当前图像块的亮度预测值和色度预测值,分别等于参考块的亮度重构值和色度重构值;或者,当前图像块的亮度预测值和色度预测值,分别等于参考块的亮度补偿值和色度补偿值,色度补偿值是对参考帧的色度重构值进行光照补偿后的值。If the current frame is a non-target frame, the luma predicted value and chrominance predicted value of the current image block are respectively equal to the luma reconstruction value and chrominance reconstructed value of the reference block; or, the luma predicted value and chrominance predicted value of the current image block , respectively equal to the luminance compensation value and the chrominance compensation value of the reference block, and the chrominance compensation value is the value obtained by performing illumination compensation on the chrominance reconstruction value of the reference frame.
具体的,在本实施例中,图像分为目标帧和非目标帧,当前帧为目标帧时只对亮度预测值进行光照补偿,当前帧为非目标帧时。确定非目标帧中的图像块的亮度预测值和色度预测值时,可以有两种方式,一种是直接使用参考块的亮度重构值和色度重构值作为亮度预测值和色度预测值,另一种是使用参考块的亮度重构值和色度重构值分别进行光照补偿后的值,即亮度补偿值和色度补偿值。需要注意的是,非目标帧可以采用上述两种确定亮度预测值和色度预测值方式中的任一种,各个非目标帧所采用的方式可以不同。Specifically, in this embodiment, the image is divided into a target frame and a non-target frame. When the current frame is a target frame, only illumination compensation is performed on the brightness prediction value, and when the current frame is a non-target frame. When determining the luma predicted value and chrominance predicted value of the image block in the non-target frame, there are two ways. One is to directly use the luma reconstructed value and the chrominance reconstructed value of the reference block as the luma predicted value and the chrominance predicted value. The predicted value, and the other is the value after illumination compensation is performed using the luminance reconstruction value and the chrominance reconstruction value of the reference block, that is, the luminance compensation value and the chrominance compensation value. It should be noted that the non-target frame may adopt any one of the above two methods for determining the luma predicted value and the chrominance predicted value, and the methods adopted by each non-target frame may be different.
在一些实施例中,确定当前图像块的亮度预测值和色度预测值之前,还包括:确定当前帧携带的开关标志位的取值为第一取值。In some embodiments, before determining the luma predicted value and the chrominance predicted value of the current image block, the method further includes: determining the value of the switch flag bit carried in the current frame to be the first value.
具体的,在本实施例中,在每一个图像帧中设置开关标志位,开关标志位可以作为帧级开关用于确定是否对参考块的色度预测值进行光照补偿,当前帧的开关标志为等于第一取值时,当前图像块的色度预测值为参考块的色度重构值,开关标志位的取值可以随机设置,例如每2帧中选择1帧的开关标志位设置为第一取值,在当前帧的开关标志位的取值为第二取值的情况,可以用参考帧的参考块的亮度补偿值和色度补偿值分别作为当前图像块的亮度预测值和色度预测值,色度补偿值是对参考块的色度重构值进行光照补偿的色度值,开关标志位例如可以是设置在图像头文件中的帧级开关(lic_sep_flag),例如可以在图像头文件中设置开关标志位,可以将目标帧的开关标志位设置为1,将非目标帧的开关标志位设置为0,从而在帧间预测过程中确定图像帧的类型。当本公开提出的图像处理方法用于视频编码时,先确定各个图像帧是目标图像或非目标图像,根据结果为各个图像帧设定对应的开关标志位,当本公开提出的图像处理方法用于视频解码时,先识别图像帧的开关标志位的取值,根据开关标志位的取值决定如何得到当前图像块的亮度预测值和色度预测值。Specifically, in this embodiment, a switch flag is set in each image frame, and the switch flag can be used as a frame-level switch to determine whether to perform illumination compensation on the chrominance prediction value of the reference block. The switch flag of the current frame is: When it is equal to the first value, the chrominance prediction value of the current image block is the chrominance reconstruction value of the reference block, and the value of the switch flag bit can be set randomly. For example, the switch flag bit of one frame selected in every two frames is set to the first When the value of the switch flag of the current frame is the second value, the luminance compensation value and the chrominance compensation value of the reference block of the reference frame can be used as the luminance prediction value and chrominance value of the current image block, respectively. The predicted value, the chrominance compensation value is the chrominance value for illumination compensation of the chrominance reconstruction value of the reference block. The switch flag bit is set in the file, the switch flag bit of the target frame can be set to 1, and the switch flag bit of the non-target frame can be set to 0, so as to determine the type of the image frame during the inter-frame prediction process. When the image processing method proposed in the present disclosure is used for video coding, it is first determined whether each image frame is a target image or a non-target image, and the corresponding switch flag bit is set for each image frame according to the result. During video decoding, the value of the switch flag bit of the image frame is first identified, and how to obtain the luma predicted value and the chrominance predicted value of the current image block is determined according to the value of the switch flag bit.
在本公开的一些实施例中,只在视频的目标帧中设置有开关标志位;具体的,在本实施例中不在非目标帧中设置标识信息,因此只要识别到标识信息即可确定当前帧的图像块的色度预测值等于参考块的色度重构值,类似的,在本公开的一些实施例中,只在视频的非目标帧中设置有开关标志位,此时只要识别不到开关标志位,即可确定当前帧的图像块的色度预测值等于参考块的色度重构值。In some embodiments of the present disclosure, the switch flag is only set in the target frame of the video; specifically, in this embodiment, no identification information is set in the non-target frame, so as long as the identification information is identified, the current frame can be determined The chrominance prediction value of the image block is equal to the chrominance reconstruction value of the reference block. Similarly, in some embodiments of the present disclosure, the switch flag is only set in the non-target frame of the video. By switching the flag bit, it can be determined that the chrominance prediction value of the image block of the current frame is equal to the chrominance reconstruction value of the reference block.
在本公开的一些实施例中,所述当前帧携带的开关标志位的取值是根据所述当前帧的亮度分量与所述参考帧的亮度分量的差异,以及所述当前帧的色度分量与所述参考帧的色度分量的差异确定的。具体的,本公开中当前帧的亮度分量和色度分量与参考帧的亮度分量和色度分量的差异,表明了亮度分量和色度分量相对于参考帧的变化幅度,若两者的变化幅度相似则可以考虑对亮度分量和色度分量采用相似的方式进行计算,否则应该考虑对两者采用不同的方式进行计算。In some embodiments of the present disclosure, the value of the switch flag bit carried by the current frame is based on the difference between the luminance component of the current frame and the luminance component of the reference frame, and the chrominance component of the current frame. is determined by the difference with the chrominance components of the reference frame. Specifically, the difference between the luminance component and chrominance component of the current frame and the luminance component and chrominance component of the reference frame in the present disclosure indicates the magnitude of change of the luminance component and the chrominance component relative to the reference frame. If they are similar, the luma component and the chrominance component can be calculated in a similar way, otherwise, the two should be calculated in different ways.
在本公开的一些实施例中,在第一变化值和第二变化值的差值大于差异阈值的情况下,所述当前帧携带的开关标志位的取值为第一取值,其中,所述第一变化值为所述当前帧的亮度分量与所述参考帧的亮度分量的差值,所述第二变化值为所述当前帧的色度分量与所述参考帧的色度分量的差值。具体的,第一变化值是当前帧和参考帧的亮度分量的差值的绝对值,同样的,第二变化值是当前帧的色度分量和参考帧的色度分量的差的绝对值。In some embodiments of the present disclosure, when the difference between the first change value and the second change value is greater than the difference threshold, the value of the switch flag bit carried in the current frame is the first value, wherein the The first change value is the difference between the luminance component of the current frame and the luminance component of the reference frame, and the second change value is the difference between the chrominance component of the current frame and the chrominance component of the reference frame. difference. Specifically, the first change value is the absolute value of the difference between the luminance components of the current frame and the reference frame. Similarly, the second change value is the absolute value of the difference between the chrominance components of the current frame and the reference frame.
具体的,本实施例明确了是否只对亮度重构值进行光照补偿的确定标准,即如何确定一个图像帧应该是否采用本公开实施例中提出的只对亮度重构值进行光照补偿,不对色度重构值进行光照补偿的方案,本实施例可以用于视频编码过程中,对于任一当前被编码的图像帧,确定该图像帧的第一变化值和第二变化值的差值,再将该差值与差异阈值进行比较,根据比较结果从而设定该图像帧是否采用本公开提出的方案,在差值不大于差异阈值时表明当前进行编码的图像帧的亮度分量和色度分量的变化趋势相近,这时候当前进行编码的当前帧的亮度分量和色度分量的处理方式应当相似,此时应当对亮度分量和色度分量的预测值都进行光照补偿或者都不进行光照补偿,当差值大于差值阈值时说明亮度分量和色度分量的变化趋势相差较大,两者不应当采用相似的处理方式,而通常图像帧的色度并不会发生变化,因此应当只对亮度分量的预测值进行光照补偿,而不对色度分量的预测值进行光照补偿。Specifically, this embodiment clarifies the criterion for determining whether to perform illumination compensation only on the luminance reconstruction value, that is, how to determine whether an image frame should use the illumination compensation for only the luminance reconstruction value proposed in the embodiment of the present disclosure, without color compensation This embodiment can be used in the video encoding process. For any currently encoded image frame, the difference between the first change value and the second change value of the image frame is determined, and then The difference value is compared with the difference threshold value, and according to the comparison result, whether the image frame adopts the solution proposed in the present disclosure is set, and when the difference value is not greater than the difference threshold value, it indicates the difference between the luminance component and the chrominance component of the image frame currently being encoded. The change trend is similar. At this time, the processing methods of the luminance component and chrominance component of the current frame currently being encoded should be similar. At this time, illumination compensation should be performed on the predicted values of the luminance component and chrominance component, or no illumination compensation should be performed. When When the difference is greater than the difference threshold, it means that the change trend of the luminance component and the chrominance component is quite different. The two should not be processed in a similar way. Usually, the chrominance of the image frame does not change, so only the luminance component should be used. Illumination compensation is performed on the predicted value of the chrominance component, but not on the predicted value of the chrominance component.
为了更好地说明本开实施例提出的图像处理方法,以下以本公开提出的图像处理方法用于视频编码端为例提出一个具体的实施例。In order to better illustrate the image processing method proposed by the embodiments of the present disclosure, a specific embodiment is provided below by taking the image processing method proposed in the present disclosure applied to a video encoding end as an example.
在视频编码过程中,将视频的图像帧将分割为等尺寸、无重叠的最大编码单元。随后以最大编码单元为节点,可进行不同种类的递归树划分,例如可以是四叉树、二叉树以及三叉树等,形成编码单元。编码单元是视频编码的基本单元,每个编码单元可以包含一个亮度块(Y)和两个色度块(UV)。视频编码性能来源于数据冗余的去除。帧间模式预测能有效地去除时域冗余,视频前后帧之间内容具有相似性,光照的变化会极大影响帧间编码的效率,在进行帧间预测时,可通过帧级直方图统计对比当前帧与参考帧之间的累积差异。若当前帧与参考帧的亮度分量的变化累积差异与色度分量的变化累积差异近似,则当前帧为非目标帧。反之,若当前帧与参考帧的亮度分量变化的累积差异远远不同于与色度分量的变化累积差异较大,则当前帧为目标帧。通过在各个图像帧中设置一个标识位(开关标志位)确定当前帧是为目标帧还是非目标帧,例如可以通过帧级开关(lic_sep_flag)标识当前帧是否为目标帧。lic_sep_flag可通过当前编码帧与参考帧列表中的所有帧的直方图统计结果确定并作为帧级标志位传递。若当前帧为非目标帧,则lic_sep_flag为0,若当前帧为目标帧,则lic_sep_flag为1。以下具体描述确定亮度预测值和色度预测值的方法,本实施例中,假设当前帧为目标帧,对于当前图像块的亮度预测值采用公式:计算,当前图像块的色度预测值采用公式:此处三个公式中的参数的含义与之前描述的相同,即对于当前图像块对应的参考块的亮度重构值进行线性光照补偿后作为当前图像块的亮度预测值,直接使用当前图像块对应的参考块的色度重构值作为当前图像块的色度预测值。即对于当前图像块只对亮度预测值进行光照补偿,对色度预测值不进行光照补偿,对于视频的非目标帧,则对亮度预测值和色度预测值都进行光照补偿。In the video coding process, the image frames of the video are divided into equal-sized, non-overlapping maximum coding units. Then, with the largest coding unit as a node, different types of recursive tree divisions can be performed, for example, a quad tree, a binary tree, and a ternary tree, etc., to form a coding unit. A coding unit is a basic unit of video coding, and each coding unit may contain one luminance block (Y) and two chrominance blocks (UV). Video coding performance comes from the removal of data redundancy. Inter-frame mode prediction can effectively remove temporal redundancy. The content between the frames before and after the video is similar, and the change of illumination will greatly affect the efficiency of inter-frame coding. When performing inter-frame prediction, frame-level histogram statistics can be used. Compare the cumulative difference between the current frame and the reference frame. If the cumulative difference of the changes of the luminance component between the current frame and the reference frame is similar to the cumulative difference of the changes of the chrominance components, the current frame is a non-target frame. On the contrary, if the cumulative difference between the changes of the luminance component of the current frame and the reference frame is far different from that of the chrominance component, the current frame is the target frame. Whether the current frame is a target frame or a non-target frame is determined by setting a flag (switch flag bit) in each image frame, for example, a frame-level switch (lic_sep_flag) can be used to identify whether the current frame is a target frame. lic_sep_flag can be determined by the histogram statistics of all frames in the current coded frame and the reference frame list and passed as a frame-level flag bit. If the current frame is a non-target frame, lic_sep_flag is 0, and if the current frame is a target frame, lic_sep_flag is 1. The method for determining the luminance prediction value and the chrominance prediction value is described in detail below. In this embodiment, assuming that the current frame is the target frame, the formula is used for the luminance prediction value of the current image block: To calculate, the chrominance prediction value of the current image block adopts the formula: The meanings of the parameters in the three formulas here are the same as those described above, that is, the luminance reconstruction value of the reference block corresponding to the current image block is subjected to linear illumination compensation as the luminance prediction value of the current image block, and the corresponding value of the current image block is directly used. The chrominance reconstruction value of the reference block is used as the chrominance prediction value of the current image block. That is, for the current image block, only illumination compensation is performed for the luminance prediction value, and illumination compensation is not performed for the chrominance prediction value. For non-target frames of the video, illumination compensation is performed for both the luminance prediction value and the chrominance prediction value.
当本公开实施例提出的图像处理方法用于视频解码端时,在视频解码过程中,对于当前帧,先获取当前帧的开关标志位,根据所述开关标志位的取值是否为第一取值确定当前帧是目标帧还是非目标帧,再确定当前帧的亮度预测值和色度预测值,其中确定亮度预测值和色度预测值的方法与上方描述的用于视频编码时的实施例相同,在此不赘述。When the image processing method proposed by the embodiment of the present disclosure is used for the video decoding end, in the video decoding process, for the current frame, the switch flag bit of the current frame is first acquired, and the value of the switch flag bit is the first one according to whether the value of the switch flag bit is the first one. The value determines whether the current frame is a target frame or a non-target frame, and then determines the luma predicted value and the chrominance predicted value of the current frame, wherein the method for determining the luma predicted value and the chrominance predicted value is the same as the above-described embodiment for video coding. The same is not repeated here.
在对视频进行解码和编码时需要进行帧间预测,在进行帧间预测时需要获取编码单元对应的运动矢量,编码单元包括亮度块(即亮度编码单元)和色度块(即色度编码单元),由于亮度采样率和色度采样率不同,因此一个编码单元中亮度块和色度块的个数不一定相同,在现有技术中,确定编码块是先获取亮度分量的运动矢量,再根据亮度采样率和色度采样率对亮度分量的运动矢量进行缩放得到同位运动矢量,作为色度分量的运动矢量,以亮度采样率在水平方向和垂直方向都是色度采样率的一半为例,在420采样格式下,一个编码块中包括一个亮度块(Y分量)和两个色度块(UV分量),亮度分量的运动矢量需要乘以2得到色度分量的运动矢量,即对亮度分量的运动矢量根据采样率进行缩放得到同位运动矢量,然而同位运动矢量不一定是与当前编码块的色度块最匹配的运动矢量,直接将其用作色度分量的运动矢量可能导致色度分量的预测准确度降低,色度失真。Inter-frame prediction needs to be performed when decoding and encoding video, and motion vector corresponding to the coding unit needs to be obtained when performing inter-frame prediction. ), because the luminance sampling rate and the chrominance sampling rate are different, the number of luminance blocks and chrominance blocks in a coding unit is not necessarily the same. In the prior art, it is determined that the coding block is to obtain the motion vector of the luminance component first, The motion vector of the luminance component is scaled according to the luminance sampling rate and the chrominance sampling rate to obtain a co-located motion vector, which is used as the motion vector of the chrominance component. Take the luminance sampling rate as half of the chrominance sampling rate in the horizontal and vertical directions as an example , in the 420-sampling format, a coding block includes one luminance block (Y component) and two chrominance blocks (UV components), and the motion vector of the luminance component needs to be multiplied by 2 to obtain the motion vector of the chrominance component, that is, for luminance The motion vector of the component is scaled according to the sampling rate to obtain the co-located motion vector. However, the co-located motion vector is not necessarily the motion vector that best matches the chroma block of the current coding block. The prediction accuracy of the components is reduced, and the chroma is distorted.
在本公开的一些实施例中,还提出一种图像处理方法,如图3所示,本实施例中的方法包括:In some embodiments of the present disclosure, an image processing method is also proposed. As shown in FIG. 3 , the method in this embodiment includes:
S21:确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量。S21: Determine the motion vector of the luminance component and the motion vector of the chrominance component of the current image block.
具体的,当前图像块位于当前帧,色度分量的运动矢量与同位运动矢量不同,同位运动矢量为亮度分量的运动矢量,或者,同位运动矢量是根据亮度采样率和色度采样率对亮度分量的运动矢量进行缩放后得到的运动矢量量;一些实施例中,当亮度采样率和色度采样率相同时,同位运动矢量等于亮度分量的运动矢量。本实施例中的图像处理方法可以用于视频解码或视频编码的帧间预测过程,当前帧可以是当前正在进行编码或解码的视频中的图像帧,当前图像块可以是当前帧中任一编码单元。在一些实施例中,色度分量的运动矢量与同位运动矢量不同,同位运动矢量是亮度分量的运动矢量根据亮度采样率和色度采样率缩放后得到的运动矢量。本实施例中确定亮度分量的运动矢量的方法可以采用现有技术中的方法,对此不作限定。Specifically, the current image block is located in the current frame, the motion vector of the chrominance component is different from the co-located motion vector, and the co-located motion vector is the motion vector of the luminance component, or the co-located motion vector is based on the luminance sampling rate and the chrominance sampling rate. The motion vector amount obtained by scaling the motion vector; in some embodiments, when the luminance sampling rate and the chrominance sampling rate are the same, the co-located motion vector is equal to the motion vector of the luminance component. The image processing method in this embodiment can be used in an inter-frame prediction process of video decoding or video encoding. The current frame can be an image frame in a video currently being encoded or decoded, and the current image block can be any encoding in the current frame. unit. In some embodiments, the motion vector of the chrominance component is different from the co-located motion vector, which is a motion vector obtained by scaling the motion vector of the luma component according to the luma sampling rate and the chroma sampling rate. The method for determining the motion vector of the luminance component in this embodiment may adopt the method in the prior art, which is not limited.
S22:根据当前图像块的亮度分量的运动矢量和色度分量的运动矢量确定当前图像块的亮度分量的亮度参考块和当前图像块的色度分量的色度参考块。S22: Determine a luminance reference block of the luminance component of the current image block and a chrominance reference block of the chrominance component of the current image block according to the motion vector of the luminance component and the motion vector of the chrominance component of the current image block.
具体的,当前帧对应有参考帧,亮度参考块和色度参考块位于当前帧对应的参考帧。Specifically, the current frame corresponds to a reference frame, and the luminance reference block and the chrominance reference block are located in the reference frame corresponding to the current frame.
S23:对亮度参考块的亮度重构值进行光照补偿,得到亮度参考块的亮度补偿值。S23: Perform illumination compensation on the luminance reconstruction value of the luminance reference block to obtain the luminance compensation value of the luminance reference block.
具体的,亮度补偿值是亮度参考块的亮度重构值进行光照补偿后的亮度值。Specifically, the luminance compensation value is a luminance value obtained by performing illumination compensation on the luminance reconstruction value of the luminance reference block.
S24:对色度参考块的色度重构值进行光照补偿,得到色度参考块的色度补偿值。S24: Perform illumination compensation on the chrominance reconstruction value of the chrominance reference block to obtain the chrominance compensation value of the chrominance reference block.
具体的,色度补偿值是对色度参考块的色度重构值进行光照补偿后的色度值。Specifically, the chrominance compensation value is a chrominance value obtained by performing illumination compensation on the chrominance reconstruction value of the chrominance reference block.
S25:确定当前图像块的亮度预测值和色度预测值,S25: Determine the luminance prediction value and the chrominance prediction value of the current image block,
具体的,当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度补偿值。一些实施例中,本公开实施例提出的方法用在帧间预测过程中,在对编码单元进行亮度分量和色度分量的帧间预测时,先获取亮度分量的运动矢量,然后根据色度采样率和亮度采样率对亮度分量进行缩放得到同位运动矢量(当亮度采样率和色度采样率相同时,亮度分量的运动矢量等于同位运动矢量),用同位运动矢量作为编码单元的色度运动矢量,这种方式默认了亮度块的运动方式与色度块的运动方式相同,但在实际情况中,图像中的亮度块与色度块的运动方式并不一定相同,特别是当视频拍摄过程中光照变化明显时,采用上述方法将导致色度预测值不理想,造成编码或解码过程的色度失真,影响用户的使用体验,因此本实施例中色度分量的运动矢量与同位运动矢量不同,从而避免了因为色度分量的运动矢量选择不当造成的色度失真的问题。Specifically, the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the chrominance compensation value of the chrominance reference block. In some embodiments, the method proposed by the embodiments of the present disclosure is used in the inter-frame prediction process. When performing the inter-frame prediction of the luminance component and the chrominance component on the coding unit, the motion vector of the luminance component is obtained first, and then the chrominance component is sampled according to the The luminance component is scaled with the luminance sampling rate and the luminance sampling rate to obtain the co-located motion vector (when the luminance sampling rate and chrominance sampling rate are the same, the motion vector of the luminance component is equal to the co-located motion vector), and the co-located motion vector is used as the chrominance motion vector of the coding unit. , this method defaults that the motion mode of the luma block is the same as that of the chroma block, but in practice, the motion mode of the luma block and the chroma block in the image is not necessarily the same, especially when the video is shot. When the illumination changes significantly, the above method will lead to unsatisfactory chrominance prediction values, resulting in chrominance distortion in the encoding or decoding process, and affecting the user's experience. Therefore, in this embodiment, the motion vector of the chrominance component is different from the co-located motion vector, Thus, the problem of chrominance distortion caused by improper selection of the motion vector of the chrominance component is avoided.
在本公开的一些实施例中,色度参考块的运动矢量与当前图像块的色度分量的运动矢量相同。具体的,本实施例中单独为当前图像块的色度分量确定对应的运动矢量,而不采用同位运动矢量,其中确定色度参考块的方法可以采用全搜索法(Full Search,FS)。In some embodiments of the present disclosure, the motion vector of the chrominance reference block is the same as the motion vector of the chrominance component of the current image block. Specifically, in this embodiment, the corresponding motion vector is determined solely for the chrominance component of the current image block instead of using the co-located motion vector, and the method for determining the chrominance reference block may use the Full Search (FS) method.
在本公开的一些实施例中,当前图像块的色度分量的运动矢量为(0,0)。具体的,在本实施例中将当前图像块的色度分量的运动矢量默认为(0,0)可以节省运动矢量的编码开销以及编码解码时的算力消耗。In some embodiments of the present disclosure, the motion vector of the chroma component of the current image block is (0,0). Specifically, in this embodiment, the motion vector of the chrominance component of the current image block is set to (0,0) by default, which can save the coding overhead of the motion vector and the computing power consumption during coding and decoding.
在本公开的一些实施例中,当前图像块的色度分量的运动矢量选自矢量候选列表,通过编码色度分量的运动矢量在矢量候选列表中的索引以记录色度分量的运动矢量。具体的,本实施例中单独为色度分量建立了一个矢量候选列表,从而提高色度分量的运动矢量的计算速度,矢量候选列表可以是Skip模式或Merge模式的候选列表。In some embodiments of the present disclosure, the motion vector of the chrominance component of the current image block is selected from the vector candidate list, and the motion vector of the chrominance component is recorded by encoding the index of the motion vector of the chrominance component in the vector candidate list. Specifically, in this embodiment, a vector candidate list is separately established for the chrominance component, thereby improving the calculation speed of the motion vector of the chrominance component, and the vector candidate list may be a candidate list of Skip mode or Merge mode.
在本公开的一些实施例中,当前图像块在目标帧对应的参考帧中对应有亮度参考块;当前图像块的亮度预测值等于对亮度参考块的亮度重构值进行光照补偿后的值。具体的,目标帧对应的参考帧可以是目标帧的相邻帧,例如目标帧在时域上的前一帧或后一帧,亮度参考块可以是参考帧中与当前图像块在亮度分量上最相近的编码块,亮度参考块对应的亮度重构值进行光照补偿后得到当前图像块的亮度预测值。In some embodiments of the present disclosure, the current image block corresponds to a luminance reference block in the reference frame corresponding to the target frame; the luminance prediction value of the current image block is equal to the luminance reconstruction value of the luminance reference block after illumination compensation is performed. Specifically, the reference frame corresponding to the target frame may be an adjacent frame of the target frame, for example, the previous frame or the next frame of the target frame in the time domain, and the luminance reference block may be the luminance component of the reference frame and the current image block. For the closest coding block, the luminance reconstruction value corresponding to the luminance reference block is subjected to illumination compensation to obtain the luminance prediction value of the current image block.
在本公开的一些实施例中,当前图像块在目标帧对应的参考帧中对应有色度参考块;当前图像块的色度预测值等于对色度参考块的色度重构值进行光照补偿后的值,或者,当前图像块的色度预测值等于色度参考块的色度重构值。具体的,对于当前图像块的色度预测值可以同样采用光照补偿的方式获取,也可以直接采用色度参考块的色度重构值,从而减少数据处理量。In some embodiments of the present disclosure, the current image block corresponds to a chrominance reference block in the reference frame corresponding to the target frame; the chrominance prediction value of the current image block is equal to the chrominance reconstruction value of the chrominance reference block after illumination compensation The value of , or the chroma prediction value of the current image block is equal to the chroma reconstruction value of the chroma reference block. Specifically, the chrominance prediction value of the current image block can also be obtained by means of illumination compensation, or the chrominance reconstruction value of the chrominance reference block can be directly used, thereby reducing the amount of data processing.
在本公开的一些实施例中,采用公式(2)得到当前图像块的亮度预测值:In some embodiments of the present disclosure, formula (2) is used to obtain the luminance prediction value of the current image block:
其中,为当前图像块的亮度预测值,为亮度参考块的亮度重构值,αy为亮度分量的颜色通道缩放系数,βY为亮度分量的偏移量。具体的,在本实施例中,在帧间预测的过程中采用线性光照变换模型对亮度参考块的亮度重构值进行光照补偿,其中αY和βY可以根据目标帧中当前图像块的邻近参考像素和对应的参考块的邻近参考像素以线性回归的方式导出。in, is the luminance prediction value of the current image block, is the luminance reconstruction value of the luminance reference block, α y is the color channel scaling factor of the luminance component, and β Y is the offset of the luminance component. Specifically, in this embodiment, in the process of inter-frame prediction, a linear illumination transformation model is used to perform illumination compensation on the luminance reconstruction value of the luminance reference block, wherein α Y and β Y can be determined according to the proximity of the current image block in the target frame. The reference pixels and neighboring reference pixels of the corresponding reference block are derived in a linear regression fashion.
在本公开的一些实施例中,采用如下公式(3)和公式(4)得到当前图像块的色度预测值:In some embodiments of the present disclosure, the following formula (3) and formula (4) are used to obtain the chrominance prediction value of the current image block:
其中,为当前图像块的色度预测值的U分量,为所述当前图像块的色度预测值的V分量,为色度参考块的色度重构值的U分量,为色度参考块的色度重构值的V分量,αU为U分量的颜色通道缩放系数,αV为V分量的颜色通道缩放系数,βU为U分量的偏移量,βV为V分量的偏移量。在一些实施例中,采用线性光照变换模型对参考块的重构值进行光照补偿,其中αU、αV、βU、βV可以根据目标帧中当前图像块的邻近参考像素和对应的参考块的邻近参考像素以线性回归的方式导出。in, is the U component of the chrominance predicted value of the current image block, is the V component of the chrominance predicted value of the current image block, is the U component of the chrominance reconstruction value of the chrominance reference block, is the V component of the chrominance reconstruction value of the chrominance reference block, α U is the color channel scaling coefficient of the U component, α V is the color channel scaling coefficient of the V component, β U is the offset of the U component, and β V is The offset of the V component. In some embodiments, a linear illumination transformation model is used to perform illumination compensation on the reconstructed value of the reference block, wherein α U , α V , β U , β V can be based on the adjacent reference pixels and corresponding reference pixels of the current image block in the target frame Neighboring reference pixels of the block are derived by linear regression.
在本公开的一些实施例中,所述确定所述当前图像块的亮度预测值和色度预测值,包括:确定当前帧是目标帧或非目标帧,若当前图像帧是目标帧,所述当前图像块的亮度预测值为亮度参考块的亮度补偿值,所述当前图像块的色度预测值为色度参考块的色度重构值。In some embodiments of the present disclosure, the determining the luma predicted value and the chrominance predicted value of the current image block includes: determining whether the current frame is a target frame or a non-target frame, and if the current image frame is a target frame, the The luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the chrominance reconstruction value of the chrominance reference block.
若当前帧是非目标帧,当前图像块的亮度预测值和色度预测值,分别等于亮度参考块的亮度重构值和色度参考块的色度重构值;或者,当前图像块的亮度预测值和色度预测值,分别等于亮度参考块的亮度补偿值和色度参考块的色度补偿值,色度补偿值是对参考帧的色度参考块的色度重构值进行光照补偿后的值。。If the current frame is a non-target frame, the luma predicted value and the chrominance predicted value of the current image block are equal to the luma reconstructed value of the luma reference block and the chrominance reconstructed value of the chrominance reference block, respectively; or, the luma predicted value of the current image block Value and chrominance prediction value, respectively equal to the luminance compensation value of the luminance reference block and the chrominance compensation value of the chrominance reference block. The chrominance compensation value is the chrominance reconstruction value of the chroma reference block of the reference frame after illumination compensation value of . .
具体的,在本实施例中,图像帧分为目标帧和非目标帧,在确定非目标帧中的编码块的亮度预测值和色度预测值时,可以有两种方式,一种是直接使用非目标帧中编码块对应的参考块的亮度重构值和色度重构值,另一种是使用非目标帧中编码块对应的参考块的亮度重构值和色度重构值分别进行光照补偿后的值。需要注意的是,非目标帧可以采用上述两种确定亮度预测值和色度预测值方式中的任一种,各个非目标帧所采用的方式可以不同。Specifically, in this embodiment, an image frame is divided into a target frame and a non-target frame. When determining the luminance prediction value and the chrominance prediction value of the coding block in the non-target frame, there may be two methods. One is to directly Use the luminance reconstruction value and chrominance reconstruction value of the reference block corresponding to the coding block in the non-target frame, and the other is to use the luminance reconstruction value and chrominance reconstruction value of the reference block corresponding to the coding block in the non-target frame respectively. The value after lighting compensation. It should be noted that the non-target frame may adopt any one of the above two methods for determining the luma predicted value and the chrominance predicted value, and the methods adopted by each non-target frame may be different.
在本公开的一些实施例中,确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,包括:In some embodiments of the present disclosure, determining the motion vector of the luminance component and the motion vector of the chrominance component of the current image block includes:
确定所述当前帧携带的开关标志位的取值;Determine the value of the switch flag bit carried by the current frame;
若所述当前帧的开关标志位的取值为第一取值,所述当前图像块的亮度预测值为亮度参考块的亮度补偿值,所述当前图像块的色度预测值为色度参考块的色度重构值;If the value of the switch flag of the current frame is the first value, the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the luminance reference value. the chroma reconstruction value of the block;
若所述当前帧的开关标志位的取值为第二取值,所述当前图像块的亮度预测值为所述参考块的亮度补偿值,所述当前图像块的色度预测值为所述参考块的色度补偿值。If the value of the switch flag of the current frame is the second value, the luminance prediction value of the current image block is the luminance compensation value of the reference block, and the chrominance prediction value of the current image block is the luminance compensation value of the current image block. The chroma compensation value of the reference block.
具体的,在一些实施例中,在每一个图像帧中设置开关标志位,开关标志位作为帧级开关用于确定当前图像块的色度预测值和亮度预测值的计算方法,例如可以在视频头文件中设置开关标志位,将第一取值可以为1,第二取值可以为0,从而在帧间预测过程中确定当前图像块的亮度预测值和色度预测值的计算方法。当本公开提出的图像处理方法用于视频编码时,先确定各个图像帧是开关标志位的取值,再确定亮度预测值和色度预测值,其中,亮度预测值等于参考块的亮度补偿值,根据取值结果的不同,色度预测值可以为色度补偿值或色度重构值。Specifically, in some embodiments, a switch flag is set in each image frame, and the switch flag is used as a frame-level switch to determine the calculation method of the chrominance prediction value and the luminance prediction value of the current image block, for example, it can be used in the video The switch flag is set in the header file, and the first value can be 1 and the second value can be 0, so as to determine the calculation method of the luma predicted value and the chrominance predicted value of the current image block during the inter prediction process. When the image processing method proposed in the present disclosure is used for video coding, it is first determined that each image frame is the value of the switch flag, and then the luma predicted value and the chrominance predicted value are determined, wherein the luma predicted value is equal to the luma compensation value of the reference block , and the chrominance prediction value may be a chrominance compensation value or a chrominance reconstruction value according to different value results.
在一些实施例中,所述当前帧携带的开关标志位的取值是根据所述当前帧的亮度分量与所述参考帧的亮度分量的差异,以及所述当前帧的色度分量与所述参考帧的色度分量的差异确定的。具体的,在当前帧与参考帧的亮度分量的差异以及色度分量的差异之间的差异较小时,表明两者的变化趋势相同,可以采用相同的处理方法,否则应该采用不同的处理方法。In some embodiments, the value of the switch flag bit carried by the current frame is based on the difference between the luminance component of the current frame and the luminance component of the reference frame, and the difference between the chrominance component of the current frame and the Determined by the difference of the chrominance components of the reference frame. Specifically, when the difference between the difference between the luminance component and the difference between the chrominance component of the current frame and the reference frame is small, it indicates that the two change trends are the same, and the same processing method can be used; otherwise, different processing methods should be used.
在本公开的一些实施例中,在第一变化值和第二变化值的差值大于差异阈值的情况下,所述当前帧携带的开关标志位的取值为第一取值,其中,所述第一变化值为所述当前帧的亮度分量与所述参考帧的亮度分量的差值,所述第二变化值为所述当前帧的色度分量与所述参考帧的色度分量的差值。In some embodiments of the present disclosure, when the difference between the first change value and the second change value is greater than the difference threshold, the value of the switch flag bit carried in the current frame is the first value, wherein the The first change value is the difference between the luminance component of the current frame and the luminance component of the reference frame, and the second change value is the difference between the chrominance component of the current frame and the chrominance component of the reference frame. difference.
具体的,本实施例明确了开关标志位的取值的确定标准,即如何确定一个图像块的色度预测值是否应当进行光照补偿,本实施例可以用于视频编码过程中,对于任一当前被编码的图像帧,确定该图像帧的第一变化值和第二变化值的差值,再将该差值与差异阈值进行比较,根据比较结果从而设定该图像帧是目标帧还是非目标帧,在差值不大于差异阈值时表明当前进行编码的图像帧的亮度分量和色度分量的变化趋势相近,这时候对亮度分量和色度分量的预测值都进行光照补偿或者都不进行光照补偿,当差值大于差值阈值时说明亮度分量和色度分量的变化趋势相差较大,两者不应当采用相似的处理方式,因此色度分量的运动矢量与同位运动矢量不应相同。Specifically, this embodiment clarifies the standard for determining the value of the switch flag bit, that is, how to determine whether the chrominance prediction value of an image block should be subjected to illumination compensation. This embodiment can be used in the video encoding process. For any current For the encoded image frame, determine the difference between the first change value and the second change value of the image frame, then compare the difference with the difference threshold, and set whether the image frame is a target frame or a non-target frame according to the comparison result frame, when the difference is not greater than the difference threshold, it indicates that the luminance and chrominance components of the currently coded image frame have similar trends. At this time, illumination compensation is performed on the predicted values of the luminance and chrominance components or no illumination is performed. Compensation, when the difference is greater than the difference threshold, it means that the change trends of the luminance component and the chrominance component are quite different, and the two should not adopt similar processing methods, so the motion vector of the chrominance component and the motion vector of the same position should not be the same.
为了更好地说明本开实施例提出的图像处理方法,以下以本公开提出的图像处理方法用于视频编码端为例提出一个具体的实施例。In order to better illustrate the image processing method proposed by the embodiments of the present disclosure, a specific embodiment is presented below by taking the image processing method proposed in the present disclosure applied to a video encoding end as an example.
在视频编码过程中,将视频的图像帧分割为等尺寸、无重叠的最大编码单元。随后以最大编码单元为节点,可进行不同种类的递归树划分,例如以是四叉树、二叉树以及三叉树等,形成编码单元。编码单元是视频编码的基本单元,每个编码单元可以包含一个亮度块(Y)和两个色度块(UV)。视频编码性能来源于数据冗余的去除。帧间模式预测能有效地去除时域冗余,视频前后帧之间内容具有相似性,光照的变化会极大影响帧间编码的效率,在进行帧间预测时,可通过帧级直方图统计对比当前帧与参考帧之间的累积差异。若当前帧与参考帧的亮度分量的变化累积差异与色度分量的变化累积差异近似,则当前帧为非目标帧。反之,若当前帧与参考帧的亮度分量变化的累积差异远远不同于与色度分量的变化累积差异较大,则当前帧为目标帧。通过在各个图像帧中设置一个开关标志位确定当前帧是为目标帧还是非目标帧,例如可以通过帧级开关(lic_sep_flag)作为开关标志位。lic_sep_flag可通过当前编码帧与参考帧列表中的所有帧的直方图统计结果确定并作为帧级标志位传递。若当前帧为非目标帧,则设定lic_sep_flag为0,若当前帧为非目标帧,则设定lic_sep_flag为1。以下具体描述确定亮度预测值和色度预测值的方法,本实施例中,在当前帧的lic_sep_flag为1时,对于当前图像块的亮度预测值,运用运动矢量MV_Y指引的亮度参考块的周边像素与当前图像块的周边参考像素导出线性光照补偿模型(αY,βY)。亮度块经过光照补偿后的亮度预测值将通过公式(2)计算得到:In the video coding process, the image frames of the video are divided into equal-sized, non-overlapping maximum coding units. Then, with the largest coding unit as a node, different types of recursive tree divisions can be performed, for example, a quad tree, a binary tree, and a ternary tree, etc., to form a coding unit. A coding unit is a basic unit of video coding, and each coding unit may contain one luminance block (Y) and two chrominance blocks (UV). Video coding performance comes from the removal of data redundancy. Inter-frame mode prediction can effectively remove temporal redundancy. The content between the frames before and after the video is similar, and the change of illumination will greatly affect the efficiency of inter-frame coding. When performing inter-frame prediction, frame-level histogram statistics can be used. Compare the cumulative difference between the current frame and the reference frame. If the cumulative difference of the changes of the luminance component between the current frame and the reference frame is similar to the cumulative difference of the changes of the chrominance components, the current frame is a non-target frame. On the contrary, if the cumulative difference between the changes of the luminance component of the current frame and the reference frame is far different from that of the chrominance component, the current frame is the target frame. Whether the current frame is a target frame or a non-target frame is determined by setting a switch flag bit in each image frame, for example, a frame-level switch (lic_sep_flag) can be used as a switch flag bit. lic_sep_flag can be determined by the histogram statistics of all frames in the current coded frame and the reference frame list and passed as a frame-level flag bit. If the current frame is a non-target frame, set lic_sep_flag to 0, and if the current frame is a non-target frame, set lic_sep_flag to 1. The method for determining the luma predicted value and the chrominance predicted value will be described in detail below. In this embodiment, when the lic_sep_flag of the current frame is 1, for the luma predicted value of the current image block, the surrounding pixels of the luma reference block indicated by the motion vector MV_Y are used. A linear illumination compensation model (α Y , β Y ) is derived from the surrounding reference pixels of the current image block. The brightness prediction value of the brightness block after illumination compensation will be calculated by formula (2):
色度分量U和V的运动矢量信息可推导为(0,0)或者,色度分量的运动矢量可来自Merge/Skip候选列表,随后按照和亮度分量预测一致的方法导出线性光照补偿模型(αU,βU)和(αV,βV),并根据公式(3)和(4)计算得到:The motion vector information of the chrominance components U and V can be derived as (0, 0) Alternatively, the motion vector of the chrominance components can be obtained from the Merge/Skip candidate list, and then the linear illumination compensation model (α) is derived in the same way as the luma component prediction. U , β U ) and (α V , β V ), and calculated according to formulas (3) and (4):
其中,βV和/或βV可默认推导为1,βV和/或βV可默认推导为0。Wherein, β V and/or β V can be deduced as 1 by default, and β V and/or β V can be deduced as 0 by default.
当本公开实施例提出的图像处理方法用于视频解码端时,在视频解码过程中,对于当前图像帧,先获取当前图像帧的开关标志位的取值,根据开关标志位的取值确定色度分量的预测值等于色度参考块的色度重构值的色度重构值还是等于色度补偿值,亮度预测值等于亮度参考块的亮度补偿值。When the image processing method proposed by the embodiment of the present disclosure is used for the video decoding end, in the video decoding process, for the current image frame, the value of the switch flag bit of the current image frame is obtained first, and the color is determined according to the value of the switch flag bit. Whether the predicted value of the chrominance component is equal to the chrominance reconstructed value of the chrominance reconstructed value of the chrominance reference block or the chrominance compensation value, the luma predicted value is equal to the luma compensation value of the luma reference block.
本公开实施例中提出一种图像处理装置,如图4所示,包括:An image processing apparatus is proposed in an embodiment of the present disclosure, as shown in FIG. 4 , including:
确定单元31,用于确定当前图像块的参考块,其中,所述当前图像块位于当前帧,所述参考块位于所述当前帧的参考帧;a determining unit 31, configured to determine a reference block of the current image block, wherein the current image block is located in the current frame, and the reference block is located in the reference frame of the current frame;
所述确定单元31,还用于确定所述参考块的亮度重构值和所述参考块的色度重构值The determining unit 31 is further configured to determine the luminance reconstruction value of the reference block and the chrominance reconstruction value of the reference block
处理单元32,用于对所述参考块的亮度重构值进行光照补偿,得到所述参考块的亮度补偿值;a processing unit 32, configured to perform illumination compensation on the luminance reconstruction value of the reference block to obtain the luminance compensation value of the reference block;
所述确定单元31,还用于确定所述当前图像块的亮度预测值和色度预测值,其中,所述当前图像块的亮度预测值为所述参考块的亮度补偿值,所述当前图像块的色度预测值为所述参考块的色度重构值。The determining unit 31 is further configured to determine a luminance prediction value and a chrominance prediction value of the current image block, wherein the luminance prediction value of the current image block is a luminance compensation value of the reference block, and the current image block is a luminance compensation value of the reference block. The chroma predicted value of the block is the chroma reconstructed value of the reference block.
本公开实施例中还提出一种图像处理装置,如图5所示,包括:An embodiment of the present disclosure also proposes an image processing apparatus, as shown in FIG. 5 , including:
确定模块41,用于确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,其中,所述当前图像块位于当前帧,所述色度分量的运动矢量与同位运动矢量不同,所述同位运动矢量为所述亮度分量的运动矢量,或者,所述同位运动矢量是根据亮度采样率和色度采样率对所述亮度分量的运动矢量进行缩放后得到的运动矢量;The determining module 41 is configured to determine the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, wherein the current image block is located in the current frame, and the motion vector of the chrominance component is different from the co-located motion vector, so The co-located motion vector is the motion vector of the luminance component, or the co-located motion vector is a motion vector obtained by scaling the motion vector of the luminance component according to the luminance sampling rate and the chrominance sampling rate;
确定模块41,还用于根据所述当前图像块的亮度分量的运动矢量和色度分量的运动矢量确定所述当前图像块的亮度分量的亮度参考块和所述当前图像块的色度分量的色度参考块,其中所述亮度参考块和色度参考块位于所述当前帧的参考帧;The determining module 41 is further configured to determine the difference between the luminance reference block of the luminance component of the current image block and the chrominance component of the current image block according to the motion vector of the luminance component and the motion vector of the chrominance component of the current image block. a chroma reference block, wherein the luma reference block and the chroma reference block are located in a reference frame of the current frame;
确定模块41,还用于确定所述亮度参考块的亮度重构值和所述色度参考块的色度重构值;The determining module 41 is further configured to determine the luminance reconstruction value of the luminance reference block and the chrominance reconstruction value of the chrominance reference block;
处理模块42,用于对亮度参考块的亮度重构值进行光照补偿,得到所述亮度参考块的亮度补偿值;a processing module 42, configured to perform illumination compensation on the luminance reconstruction value of the luminance reference block, to obtain the luminance compensation value of the luminance reference block;
处理模块42,还用于对色度参考块的色度重构值进行光照补偿,得到色度参考块的色度补偿值;The processing module 42 is further configured to perform illumination compensation on the chrominance reconstruction value of the chrominance reference block to obtain the chrominance compensation value of the chrominance reference block;
确定模块41,还用于确定所述当前图像块的亮度预测值和色度预测值,其中,所述当前图像块的亮度预测值为所述参考块的亮度补偿值,所述当前图像块的色度预测值为所述参考块的色度补偿值。The determination module 41 is further configured to determine the luminance prediction value and the chrominance prediction value of the current image block, wherein the luminance prediction value of the current image block is the luminance compensation value of the reference block, and the luminance prediction value of the current image block is The chrominance prediction value is the chrominance compensation value of the reference block.
对于装置的实施例而言,由于其基本对应于方法实施例,所以相关之处参见方法实施例的部分说明即可。以上所描述的装置实施例仅仅是示意性的,其中所述作为分离模块说明的模块可以是或者也可以不是分开的。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。For the embodiments of the apparatus, since they basically correspond to the method embodiments, reference may be made to the partial descriptions of the method embodiments for related parts. The apparatus embodiments described above are merely illustrative, wherein the modules described as separate modules may or may not be separate. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution in this embodiment. Those of ordinary skill in the art can understand and implement it without creative effort.
以上,基于实施例和应用例说明了本公开的方法及装置。此外,本公开还提供一种终端及存储介质,以下说明这些终端和存储介质。In the above, the method and apparatus of the present disclosure have been described based on the embodiments and application examples. In addition, the present disclosure also provides a terminal and a storage medium, which are described below.
下面参考图6,其示出了适于用来实现本公开实施例的电子设备(例如终端设备或服务器)800的结构示意图。本公开实施例中的终端设备可以包括但不限于诸如移动电话、笔记本电脑、数字广播接收器、PDA(个人数字助理)、PAD(平板电脑)、PMP(便携式多媒体播放器)、车载终端(例如车载导航终端)等等的移动终端以及诸如数字TV、台式计算机等等的固定终端。图中示出的电子设备仅仅是一个示例,不应对本公开实施例的功能和使用范围带来任何限制。Referring next to FIG. 6 , it shows a schematic structural diagram of an electronic device (eg, a terminal device or a server) 800 suitable for implementing an embodiment of the present disclosure. Terminal devices in the embodiments of the present disclosure may include, but are not limited to, such as mobile phones, notebook computers, digital broadcast receivers, PDAs (personal digital assistants), PADs (tablets), PMPs (portable multimedia players), vehicle-mounted terminals (eg, mobile terminals such as in-vehicle navigation terminals), etc., and stationary terminals such as digital TVs, desktop computers, and the like. The electronic device shown in the figure is only an example, and should not impose any limitation on the function and scope of use of the embodiments of the present disclosure.
如图6所示,电子设备800可以包括处理装置(例如中央处理器、图形处理器等)801,其可以根据存储在只读存储器(ROM)802中的程序或者从存储装置808加载到随机访问存储器(RAM)803中的程序而执行各种适当的动作和处理。在RAM803中,还存储有电子设备800操作所需的各种程序和数据。处理装置801、ROM 802以及RAM 803通过总线804彼此相连。输入/输出(I/O)接口805也连接至总线804。As shown in FIG. 6 , an
通常,以下装置可以连接至I/O接口805:包括例如触摸屏、触摸板、键盘、鼠标、摄像头、麦克风、加速度计、陀螺仪等的输入装置806;包括例如液晶显示器(LCD)、扬声器、振动器等的输出装置807;包括例如磁带、硬盘等的存储装置808;以及通信装置809。通信装置809可以允许电子设备800与其他设备进行无线或有线通信以交换数据。虽然图中示出了具有各种装置的电子设备800,但是应理解的是,并不要求实施或具备所有示出的装置。可以替代地实施或具备更多或更少的装置。Typically, the following devices may be connected to the I/O interface 805:
特别地,根据本公开的实施例,上文参考流程图描述的过程可以被实现为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在计算机可读介质上的计算机程序,该计算机程序包含用于执行流程图所示的方法的程序代码。在这样的实施例中,该计算机程序可以通过通信装置809从网络上被下载和安装,或者从存储装置808被安装,或者从ROM 802被安装。在该计算机程序被处理装置801执行时,执行本公开实施例的方法中限定的上述功能。In particular, according to embodiments of the present disclosure, the processes described above with reference to the flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program carried on a computer-readable medium, the computer program containing program code for performing the method illustrated in the flowchart. In such an embodiment, the computer program may be downloaded and installed from the network via the
需要说明的是,本公开上述的计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开中,计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读信号介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:电线、光缆、RF(射频)等等,或者上述的任意合适的组合。It should be noted that the computer-readable medium mentioned above in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium, or any combination of the above two. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus or device, or a combination of any of the above. More specific examples of computer readable storage media may include, but are not limited to, electrical connections with one or more wires, portable computer disks, hard disks, random access memory (RAM), read only memory (ROM), erasable Programmable read only memory (EPROM or flash memory), fiber optics, portable compact disk read only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing. In this disclosure, a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In the present disclosure, however, a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave with computer-readable program code embodied thereon. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing. A computer-readable signal medium can also be any computer-readable medium other than a computer-readable storage medium that can transmit, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device . Program code embodied on a computer readable medium may be transmitted using any suitable medium including, but not limited to, electrical wire, optical fiber cable, RF (radio frequency), etc., or any suitable combination of the foregoing.
在一些实施方式中,客户端、服务器可以利用诸如HTTP(HyperText TransferProtocol,超文本传输协议)之类的任何当前已知或未来研发的网络协议进行通信,并且可以与任意形式或介质的数字数据通信(例如,通信网络)互连。通信网络的示例包括局域网(“LAN”),广域网(“WAN”),网际网(例如,互联网)以及端对端网络(例如,ad hoc端对端网络),以及任何当前已知或未来研发的网络。In some embodiments, the client and server can communicate using any currently known or future developed network protocol such as HTTP (HyperText Transfer Protocol), and can communicate with digital data in any form or medium (eg, a communications network) interconnected. Examples of communication networks include local area networks ("LAN"), wide area networks ("WAN"), the Internet (eg, the Internet), and peer-to-peer networks (eg, ad hoc peer-to-peer networks), as well as any currently known or future development network of.
上述计算机可读介质可以是上述电子设备中所包含的;也可以是单独存在,而未装配入该电子设备中。The above-mentioned computer-readable medium may be included in the above-mentioned electronic device; or may exist alone without being assembled into the electronic device.
上述计算机可读介质承载有一个或者多个程序,当上述一个或者多个程序被该电子设备执行时,使得该电子设备执行上述的本公开的方法。The aforementioned computer-readable medium carries one or more programs, which, when executed by the electronic device, cause the electronic device to execute the aforementioned method of the present disclosure.
可以以一种或多种程序设计语言或其组合来编写用于执行本公开的操作的计算机程序代码,上述程序设计语言包括面向对象的程序设计语言—诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言—诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(LAN)或广域网(WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。Computer program code for carrying out operations of the present disclosure may be written in one or more programming languages, including object-oriented programming languages—such as Java, Smalltalk, C++, but also conventional Procedural programming language - such as the "C" language or similar programming language. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer, or entirely on the remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (eg, using an Internet service provider through Internet connection).
附图中的流程图和框图,图示了按照本公开各种实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。The flowchart and block diagrams in the Figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present disclosure. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code that contains one or more logical functions for implementing the specified functions executable instructions. It should also be noted that, in some alternative implementations, the functions noted in the blocks may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It is also noted that each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations, can be implemented in dedicated hardware-based systems that perform the specified functions or operations , or can be implemented in a combination of dedicated hardware and computer instructions.
描述于本公开实施例中所涉及到的单元可以通过软件的方式实现,也可以通过硬件的方式来实现。其中,单元的名称在某种情况下并不构成对该单元本身的限定。The units involved in the embodiments of the present disclosure may be implemented in a software manner, and may also be implemented in a hardware manner. Among them, the name of the unit does not constitute a limitation of the unit itself under certain circumstances.
本文中以上描述的功能可以至少部分地由一个或多个硬件逻辑部件来执行。例如,非限制性地,可以使用的示范类型的硬件逻辑部件包括:现场可编程门阵列(FPGA)、专用集成电路(ASIC)、专用标准产品(ASSP)、片上系统(SOC)、复杂可编程逻辑设备(CPLD)等等。The functions described herein above may be performed, at least in part, by one or more hardware logic components. For example, without limitation, exemplary types of hardware logic components that may be used include: Field Programmable Gate Arrays (FPGAs), Application Specific Integrated Circuits (ASICs), Application Specific Standard Products (ASSPs), Systems on Chips (SOCs), Complex Programmable Logical Devices (CPLDs) and more.
在本公开的上下文中,机器可读介质可以是有形的介质,其可以包含或存储以供指令执行系统、装置或设备使用或与指令执行系统、装置或设备结合地使用的程序。机器可读介质可以是机器可读信号介质或机器可读储存介质。机器可读介质可以包括但不限于电子的、磁性的、光学的、电磁的、红外的、或半导体系统、装置或设备,或者上述内容的任何合适组合。机器可读存储介质的更具体示例会包括基于一个或多个线的电气连接、便携式计算机盘、硬盘、随机存取存储器(RAM)、只读存储器(ROM)、可擦除可编程只读存储器(EPROM或快闪存储器)、光纤、便捷式紧凑盘只读存储器(CD-ROM)、光学储存设备、磁储存设备、或上述内容的任何合适组合。In the context of the present disclosure, a machine-readable medium may be a tangible medium that may contain or store a program for use by or in connection with the instruction execution system, apparatus or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. Machine-readable media may include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, devices, or devices, or any suitable combination of the foregoing. More specific examples of machine-readable storage media would include one or more wire-based electrical connections, portable computer disks, hard disks, random access memory (RAM), read only memory (ROM), erasable programmable read only memory (EPROM or flash memory), fiber optics, compact disk read only memory (CD-ROM), optical storage, magnetic storage, or any suitable combination of the foregoing.
根据本公开的一个或多个实施例,提供了一种图像处理方法,包括:According to one or more embodiments of the present disclosure, an image processing method is provided, including:
确定视频中目标帧的当前图像块在目标帧对应的参考帧中所对应的参考块;Determine the reference block corresponding to the current image block of the target frame in the video in the reference frame corresponding to the target frame;
对当前图像块对应的参考块的亮度重构值进行光照补偿得到当前图像块的亮度预测值,用当前图像块对应的参考块的色度重构值作为当前图像块的色度预测值。Perform illumination compensation on the luminance reconstruction value of the reference block corresponding to the current image block to obtain the luminance prediction value of the current image block, and use the chrominance reconstruction value of the reference block corresponding to the current image block as the chrominance prediction value of the current image block.
根据本公开的一个或多个实施例,在一些实施例中,本公开提供一种图像处理方法,包括:According to one or more embodiments of the present disclosure, in some embodiments, the present disclosure provides an image processing method, comprising:
确定当前图像块的参考块,其中,当前图像块位于当前帧,参考块位于当前帧的参考帧;Determine the reference block of the current image block, wherein the current image block is located in the current frame, and the reference block is located in the reference frame of the current frame;
确定参考块的亮度重构值和参考块的色度重构值;determining the luma reconstruction value of the reference block and the chroma reconstruction value of the reference block;
对参考块的亮度重构值进行光照补偿,得到参考块的亮度补偿值;Perform illumination compensation on the brightness reconstruction value of the reference block to obtain the brightness compensation value of the reference block;
确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为参考块的亮度补偿值,当前图像块的色度预测值为参考块的色度重构值。Determine the luma predicted value and the chrominance predicted value of the current image block, wherein the luma predicted value of the current image block is the luma compensation value of the reference block, and the chrominance predicted value of the current image block is the chrominance reconstruction value of the reference block.
在一些实施例中,还包括:确定当前帧携带的开关标志位的取值为第一取值。In some embodiments, the method further includes: determining the value of the switch flag bit carried in the current frame to be the first value.
在一些实施例中,当前帧携带的开关标志位的取值是根据当前帧的亮度分量与参考帧的亮度分量的差异,以及当前帧的色度分量与参考帧的色度分量的差异确定的。In some embodiments, the value of the switch flag bit carried by the current frame is determined according to the difference between the luminance component of the current frame and the luminance component of the reference frame, and the difference between the chrominance component of the current frame and the chrominance component of the reference frame .
在一些实施例中,在第一变化值和第二变化值的差值大于差异阈值的情况下,当前帧携带的开关标志位的取值为第一取值,其中,第一变化值为当前帧的亮度分量与参考帧的亮度分量的差值,第二变化值为当前帧的色度分量与参考帧的色度分量的差值。In some embodiments, when the difference between the first change value and the second change value is greater than the difference threshold, the value of the switch flag carried in the current frame is the first value, wherein the first change value is the current The difference between the luminance component of the frame and the luminance component of the reference frame, and the second change value is the difference between the chrominance component of the current frame and the chrominance component of the reference frame.
在一些实施例中,当前图像块的亮度预测值根据公式(1)确定:In some embodiments, the luminance prediction value of the current image block is determined according to formula (1):
其中,为当前图像块的亮度预测值,为参考块的亮度重构值,αY为亮度分量的颜色通道缩放系数,αY为亮度分量的偏移量。in, is the luminance prediction value of the current image block, is the luminance reconstruction value of the reference block, α Y is the color channel scaling factor of the luminance component, and α Y is the offset of the luminance component.
在一些实施例中,所述确定所述当前图像块的亮度预测值和色度预测值,包括:确定当前帧是目标帧或非目标帧,若当前图像帧是目标帧,所述当前图像块的亮度预测值为所述参考块的亮度补偿值,所述当前图像块的色度预测值为所述参考块的色度重构值。In some embodiments, the determining the luma predicted value and the chrominance predicted value of the current image block includes: determining whether the current frame is a target frame or a non-target frame, if the current image frame is a target frame, the current image block The luma predicted value of the reference block is the luma compensation value, and the chrominance predicted value of the current image block is the chrominance reconstruction value of the reference block.
若当前帧是非目标帧,当前图像块的亮度预测值和色度预测值,分别等于参考块的亮度重构值和色度重构值;或者,当前图像块的亮度预测值和色度预测值,分别等于参考块的亮度补偿值和色度补偿值,色度补偿值是对参考帧的色度重构值进行光照补偿后的值。If the current frame is a non-target frame, the luma predicted value and chrominance predicted value of the current image block are respectively equal to the luma reconstruction value and chrominance reconstructed value of the reference block; or, the luma predicted value and chrominance predicted value of the current image block , respectively equal to the luminance compensation value and the chrominance compensation value of the reference block, and the chrominance compensation value is the value obtained by performing illumination compensation on the chrominance reconstruction value of the reference frame.
在一些实施例中,本公开提供一种图像处理方法,包括:In some embodiments, the present disclosure provides an image processing method, comprising:
确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,其中,当前图像块位于当前帧,色度分量的运动矢量与同位运动矢量不同,同位运动矢量为亮度分量的运动矢量,或者,同位运动矢量是根据亮度采样率和色度采样率对亮度分量的运动矢量进行缩放后得到的运动矢量;Determine the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, where the current image block is located in the current frame, the motion vector of the chrominance component is different from the co-located motion vector, and the co-located motion vector is the motion vector of the luminance component, or , the co-located motion vector is the motion vector obtained by scaling the motion vector of the luminance component according to the luminance sampling rate and the chrominance sampling rate;
根据当前图像块的亮度分量的运动矢量和色度分量的运动矢量确定当前图像块的亮度分量的亮度参考块和当前图像块的色度分量的色度参考块,其中,亮度参考块和色度参考块位于当前帧的参考帧;The luminance reference block of the luminance component of the current image block and the chrominance reference block of the chrominance component of the current image block are determined according to the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, wherein the luminance reference block and the chrominance reference block are The reference block is located in the reference frame of the current frame;
确定亮度参考块的亮度重构值和色度参考块的色度重构值;determining the luma reconstruction value of the luma reference block and the chroma reconstruction value of the chroma reference block;
对亮度参考块的亮度重构值进行光照补偿,得到亮度参考块的亮度补偿值;Perform illumination compensation on the luminance reconstruction value of the luminance reference block to obtain the luminance compensation value of the luminance reference block;
对色度参考块的色度重构值进行光照补偿,得到色度参考块的色度补偿值;Perform illumination compensation on the chrominance reconstruction value of the chrominance reference block to obtain the chrominance compensation value of the chrominance reference block;
确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度补偿值。Determine the luma predicted value and the chrominance predicted value of the current image block, where the luma predicted value of the current image block is the luma compensation value of the luma reference block, and the chrominance predicted value of the current image block is the chrominance compensation value of the chrominance reference block .
在一些实施例中,本公开提供一种图像处理方法,色度参考块的运动矢量与当前图像块的色度分量的运动矢量相同。In some embodiments, the present disclosure provides an image processing method where the motion vector of a chrominance reference block is the same as the motion vector of a chrominance component of a current image block.
在一些实施例中,本公开提供一种图像处理方法,当前图像块的色度分量的运动矢量为(0,0)。In some embodiments, the present disclosure provides an image processing method, wherein the motion vector of the chrominance component of the current image block is (0,0).
在一些实施例中,本公开提供一种图像处理方法,当前图像块的色度分量的运动矢量是根据矢量候选列表确定的,色度分量的运动矢量在矢量候选列表中的索引用于指示色度分量的运动矢量。In some embodiments, the present disclosure provides an image processing method, the motion vector of the chrominance component of the current image block is determined according to the vector candidate list, and the index of the motion vector of the chrominance component in the vector candidate list is used to indicate the color The motion vector of the degree component.
在一些实施例中,本公开提供一种图像处理方法,采用公式(2)得到当前图像块的亮度预测值:In some embodiments, the present disclosure provides an image processing method, which adopts formula (2) to obtain the luminance prediction value of the current image block:
其中,为所述当前图像块的亮度预测值,为所述亮度参考块的亮度重构值,αY为所述亮度分量的颜色通道缩放系数,βY为所述亮度分量的偏移量;in, is the luminance prediction value of the current image block, is the luminance reconstruction value of the luminance reference block, α Y is the color channel scaling coefficient of the luminance component, and β Y is the offset of the luminance component;
和/或,and / or,
采用公式(3)和公式(4)得到所述当前图像块的色度预测值:Use formula (3) and formula (4) to obtain the chrominance prediction value of the current image block:
其中,为所述当前图像块的色度预测值的U分量,为所述当前图像块的色度预测值的V分量,为所述色度参考块的色度重构值的U分量,为所述色度参考块的色度重构值的V分量,αU为所述U分量的颜色通道缩放系数,αV为所述V分量的颜色通道缩放系数,βU为所述U分量的偏移量,βV为所述V分量的偏移量。in, is the U component of the chrominance prediction value of the current image block, is the V component of the chrominance prediction value of the current image block, is the U component of the chrominance reconstruction value of the chrominance reference block, is the V component of the chrominance reconstruction value of the chrominance reference block, α U is the color channel scaling coefficient of the U component, α V is the color channel scaling coefficient of the V component, and β U is the U component , β V is the offset of the V component.
在一些实施例中,本公开提供一种图像处理方法,确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,包括:In some embodiments, the present disclosure provides an image processing method for determining a motion vector of a luminance component and a motion vector of a chrominance component of a current image block, including:
确定当前帧携带的开关标志位的取值;Determine the value of the switch flag bit carried by the current frame;
若当前帧的开关标志位的取值为第一取值,当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度重构值;If the value of the switch flag of the current frame is the first value, the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the chrominance reconstruction of the chrominance reference block. value;
若当前帧的开关标志位的取值为第二取值,当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度补偿值。If the value of the switch flag of the current frame is the second value, the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the chrominance compensation value of the chrominance reference block. .
在一些实施例中,本公开提供一种图像处理方法,当前帧携带的开关标志位的取值是根据当前帧的亮度分量与参考帧的亮度分量的差异,以及当前帧的色度分量与参考帧的色度分量的差异确定的。In some embodiments, the present disclosure provides an image processing method. The value of a switch flag carried by the current frame is based on the difference between the luminance component of the current frame and the luminance component of the reference frame, and the chrominance component of the current frame and the reference frame. The difference between the chroma components of the frame is determined.
在一些实施例中,本公开提供一种图像处理方法,在第一变化值和第二变化值的差值大于差异阈值的情况下,当前帧携带的开关标志位的取值为第一取值,其中,第一变化值为当前帧的亮度分量与参考帧的亮度分量的差值,第二变化值为当前帧的色度分量与参考帧的色度分量的差值。In some embodiments, the present disclosure provides an image processing method, in the case that the difference between the first change value and the second change value is greater than the difference threshold, the value of the switch flag bit carried in the current frame is the first value , wherein the first change value is the difference between the luminance component of the current frame and the luminance component of the reference frame, and the second change value is the difference between the chrominance component of the current frame and the chrominance component of the reference frame.
一些实施例中,本公开提出一种图像处理装置,包括:In some embodiments, the present disclosure provides an image processing apparatus, including:
确定单元,用于确定当前图像块的参考块,其中,当前图像块位于当前帧,参考块位于当前帧的参考帧;A determining unit for determining the reference block of the current image block, wherein the current image block is located in the current frame, and the reference block is located in the reference frame of the current frame;
确定单元,还用于确定参考块的亮度重构值和参考块的色度重构值;a determining unit, further configured to determine the luminance reconstruction value of the reference block and the chrominance reconstruction value of the reference block;
处理单元,用于对参考块的亮度重构值进行光照补偿,得到参考块的亮度补偿值;a processing unit, configured to perform illumination compensation on the luminance reconstruction value of the reference block to obtain the luminance compensation value of the reference block;
确定单元,还用于确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为参考块的亮度补偿值,当前图像块的色度预测值为参考块的色度重构值。The determining unit is further configured to determine the luminance prediction value and the chrominance prediction value of the current image block, wherein the luminance prediction value of the current image block is the luminance compensation value of the reference block, and the chrominance prediction value of the current image block is the color value of the reference block. degree reconstruction value.
在一些实施例中,本公开提出一种图像处理装置,包括:In some embodiments, the present disclosure provides an image processing apparatus, comprising:
确定模块,用于确定当前图像块的亮度分量的运动矢量和色度分量的运动矢量,其中,当前图像块位于当前帧,色度分量的运动矢量与同位运动矢量不同,同位运动矢量为亮度分量的运动矢量,或者,同位运动矢量是根据亮度采样率和色度采样率对亮度分量的运动矢量进行缩放后得到的运动矢量;The determination module is used to determine the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, wherein the current image block is located in the current frame, the motion vector of the chrominance component is different from the co-located motion vector, and the co-located motion vector is the luminance component The motion vector of , or the co-located motion vector is the motion vector obtained by scaling the motion vector of the luminance component according to the luminance sampling rate and the chrominance sampling rate;
确定模块,还用于根据当前图像块的亮度分量的运动矢量和色度分量的运动矢量确定当前图像块的亮度分量的亮度参考块和当前图像块的色度分量的色度参考块,其中亮度参考块和色度参考块位于当前帧的参考帧;The determining module is further configured to determine the luminance reference block of the luminance component of the current image block and the chrominance reference block of the chrominance component of the current image block according to the motion vector of the luminance component and the motion vector of the chrominance component of the current image block, wherein the luminance The reference block and the chroma reference block are located in the reference frame of the current frame;
确定模块,还用于确定亮度参考块的亮度重构值和色度参考块的色度重构值;a determining module, further configured to determine the luminance reconstruction value of the luminance reference block and the chrominance reconstruction value of the chrominance reference block;
处理模块,用于对亮度参考块的亮度重构值进行光照补偿,得到亮度参考块的亮度补偿值;a processing module, configured to perform illumination compensation on the luminance reconstruction value of the luminance reference block to obtain the luminance compensation value of the luminance reference block;
处理模块,还用于对色度参考块的色度重构值进行光照补偿,得到色度参考块的色度补偿值;The processing module is also used to perform illumination compensation on the chrominance reconstruction value of the chrominance reference block to obtain the chrominance compensation value of the chrominance reference block;
确定模块,还用于确定当前图像块的亮度预测值和色度预测值,其中,当前图像块的亮度预测值为亮度参考块的亮度补偿值,当前图像块的色度预测值为色度参考块的色度补偿值。The determining module is further configured to determine the luminance prediction value and the chrominance prediction value of the current image block, wherein the luminance prediction value of the current image block is the luminance compensation value of the luminance reference block, and the chrominance prediction value of the current image block is the chrominance reference value. The chroma compensation value for the block.
根据本公开的一个或多个实施例,提供了一种终端,包括:至少一个存储器和至少一个处理器;According to one or more embodiments of the present disclosure, there is provided a terminal including: at least one memory and at least one processor;
其中,所述至少一个存储器用于存储程序代码,所述至少一个处理器用于调用所述至少一个存储器所存储的程序代码执行上述中任一项所述的方法。Wherein, the at least one memory is used for storing program codes, and the at least one processor is used for calling the program codes stored in the at least one memory to execute any one of the methods described above.
根据本公开的一个或多个实施例,提供了一种存储介质,所述存储介质用于存储程序代码,所述程序代码用于执行上述的方法。According to one or more embodiments of the present disclosure, there is provided a storage medium for storing a program code for executing the above-described method.
以上描述仅为本公开的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本公开中所涉及的公开范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离上述公开构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本公开中公开的(但不限于)具有类似功能的技术特征进行互相替换而形成的技术方案。The above description is merely a preferred embodiment of the present disclosure and an illustration of the technical principles employed. Those skilled in the art should understand that the scope of the disclosure involved in the present disclosure is not limited to the technical solutions formed by the specific combination of the above-mentioned technical features, and should also cover, without departing from the above-mentioned disclosed concept, the technical solutions formed by the above-mentioned technical features or Other technical solutions formed by any combination of its equivalent features. For example, a technical solution is formed by replacing the above features with the technical features disclosed in the present disclosure (but not limited to) with similar functions.
此外,虽然采用特定次序描绘了各操作,但是这不应当理解为要求这些操作以所示出的特定次序或以顺序次序执行来执行。在一定环境下,多任务和并行处理可能是有利的。同样地,虽然在上面论述中包含了若干具体实现细节,但是这些不应当被解释为对本公开的范围的限制。在单独的实施例的上下文中描述的某些特征还可以组合地实现在单个实施例中。相反地,在单个实施例的上下文中描述的各种特征也可以单独地或以任何合适的子组合的方式实现在多个实施例中。Additionally, although operations are depicted in a particular order, this should not be construed as requiring that the operations be performed in the particular order shown or in a sequential order. Under certain circumstances, multitasking and parallel processing may be advantageous. Likewise, although the above discussion contains several implementation-specific details, these should not be construed as limitations on the scope of the present disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable subcombination.
尽管已经采用特定于结构特征和/或方法逻辑动作的语言描述了本主题,但是应当理解所附权利要求书中所限定的主题未必局限于上面描述的特定特征或动作。相反,上面所描述的特定特征和动作仅仅是实现权利要求书的示例形式。Although the subject matter has been described in language specific to structural features and/or logical acts of method, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are merely example forms of implementing the claims.
Claims (8)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011060097.7A CN112203085B (en) | 2020-09-30 | 2020-09-30 | Image processing method, device, terminal and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011060097.7A CN112203085B (en) | 2020-09-30 | 2020-09-30 | Image processing method, device, terminal and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN112203085A true CN112203085A (en) | 2021-01-08 |
CN112203085B CN112203085B (en) | 2023-10-17 |
Family
ID=74012512
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011060097.7A Active CN112203085B (en) | 2020-09-30 | 2020-09-30 | Image processing method, device, terminal and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112203085B (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN113422959A (en) * | 2021-05-31 | 2021-09-21 | 浙江智慧视频安防创新中心有限公司 | Video encoding and decoding method and device, electronic equipment and storage medium |
WO2022174469A1 (en) * | 2021-02-22 | 2022-08-25 | Oppo广东移动通信有限公司 | Illumination compensation method, encoder, decoder, and storage medium |
CN116708789A (en) * | 2023-08-04 | 2023-09-05 | 湖南马栏山视频先进技术研究院有限公司 | Video analysis coding system based on artificial intelligence |
WO2025007276A1 (en) * | 2023-07-04 | 2025-01-09 | Oppo广东移动通信有限公司 | Coding method, decoding method, bit stream, coder, decoder and storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100183068A1 (en) * | 2007-01-04 | 2010-07-22 | Thomson Licensing | Methods and apparatus for reducing coding artifacts for illumination compensation and/or color compensation in multi-view coded video |
CN105103552A (en) * | 2013-01-10 | 2015-11-25 | 三星电子株式会社 | Method for encoding inter-layer video for compensating luminance difference and device therefor, and method for decoding video and device therefor |
CN109076210A (en) * | 2016-05-28 | 2018-12-21 | 联发科技股份有限公司 | Method and device for current image reference of video coding and decoding |
CN111031319A (en) * | 2019-12-13 | 2020-04-17 | 浙江大华技术股份有限公司 | Local illumination compensation prediction method, terminal equipment and computer storage medium |
-
2020
- 2020-09-30 CN CN202011060097.7A patent/CN112203085B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20100183068A1 (en) * | 2007-01-04 | 2010-07-22 | Thomson Licensing | Methods and apparatus for reducing coding artifacts for illumination compensation and/or color compensation in multi-view coded video |
CN105103552A (en) * | 2013-01-10 | 2015-11-25 | 三星电子株式会社 | Method for encoding inter-layer video for compensating luminance difference and device therefor, and method for decoding video and device therefor |
CN109076210A (en) * | 2016-05-28 | 2018-12-21 | 联发科技股份有限公司 | Method and device for current image reference of video coding and decoding |
CN111031319A (en) * | 2019-12-13 | 2020-04-17 | 浙江大华技术股份有限公司 | Local illumination compensation prediction method, terminal equipment and computer storage medium |
Non-Patent Citations (2)
Title |
---|
QIANG TANG等: "Efficient Chrominance Compensation for MPEG2 to H.264 Transcoding", 《 2007 IEEE INTERNATIONAL CONFERENCE ON ACOUSTICS, SPEECH AND SIGNAL PROCESSING - ICASSP \'07》 * |
SAURAV BANDYOPADHYAY等: "CE10-related: Local illumination compensation simplifications", 《JOINT VIDEO EXPERTS TEAM (JVET) OF ITU-T SG 16 WP 3 AND ISO/IEC JTC 1/SC 29/WG 11 13TH MEETING: MARRAKECH, MA, 9–18JAN. 2019 JVET-M0224-V2 》 * |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2022174469A1 (en) * | 2021-02-22 | 2022-08-25 | Oppo广东移动通信有限公司 | Illumination compensation method, encoder, decoder, and storage medium |
CN113422959A (en) * | 2021-05-31 | 2021-09-21 | 浙江智慧视频安防创新中心有限公司 | Video encoding and decoding method and device, electronic equipment and storage medium |
WO2025007276A1 (en) * | 2023-07-04 | 2025-01-09 | Oppo广东移动通信有限公司 | Coding method, decoding method, bit stream, coder, decoder and storage medium |
CN116708789A (en) * | 2023-08-04 | 2023-09-05 | 湖南马栏山视频先进技术研究院有限公司 | Video analysis coding system based on artificial intelligence |
CN116708789B (en) * | 2023-08-04 | 2023-10-13 | 湖南马栏山视频先进技术研究院有限公司 | Video analysis coding system based on artificial intelligence |
Also Published As
Publication number | Publication date |
---|---|
CN112203085B (en) | 2023-10-17 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN112203085B (en) | Image processing method, device, terminal and storage medium | |
JP7614376B2 (en) | Screen content processing method, device and equipment | |
CN110839155A (en) | Method, apparatus, electronic device, and computer-readable storage medium for motion estimation | |
CN111654696B (en) | An intra-frame multi-reference line prediction method, device, storage medium and terminal | |
CN113473126A (en) | Video stream processing method and device, electronic equipment and computer readable medium | |
WO2021196994A1 (en) | Encoding method and apparatus, terminal, and storage medium | |
CN112203086B (en) | Image processing method, device, terminal and storage medium | |
CN111738951B (en) | Image processing method and device | |
KR102609215B1 (en) | Video encoders, video decoders, and corresponding methods | |
US20050089232A1 (en) | Method of video compression that accommodates scene changes | |
CN111263166B (en) | Video image prediction method and device | |
CN116828180B (en) | Video encoding method, apparatus, electronic device, and computer-readable medium | |
CN118264798A (en) | Video coding method and device, electronic equipment and storage medium | |
CN111738950A (en) | Image processing method and device | |
WO2023185305A1 (en) | Encoding method and apparatus, storage medium and computer program product | |
CN118138770A (en) | Video processing method, device, electronic equipment and storage medium | |
KR102768109B1 (en) | Inter prediction method and device | |
CN113542737A (en) | Coding mode determination method, device, electronic device and storage medium | |
CN113411611B (en) | Video image processing method and device and electronic device | |
CN113630602B (en) | Affine motion estimation method, device, storage medium and terminal for coding unit | |
CN108769695B (en) | Frame type conversion method, system and terminal | |
WO2024149238A1 (en) | Data encoding method, data decoding method, and related apparatuses | |
CN113038277B (en) | Video processing method and device | |
WO2024109790A1 (en) | Video data processing method and apparatus, and display apparatus and storage medium | |
WO2024109816A1 (en) | Video data processing method and device, display device, and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |