Vvc video coding standard based on variable cnn qp adaptive loop filtering method

By using a lightweight CTU quality three-classification network and CNN filtering networks of varying complexity, the problem of high resource consumption in existing technologies is solved, and adaptive filtering under different QPs is achieved, thereby improving video compression quality and efficiency.

CN116347107BActive Publication Date: 2025-11-28BEIJING UNIV OF TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310250176.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-15
Publication Date
2025-11-28
Estimated Expiration
2043-03-15

AI Technical Summary

Technical Problem

Existing CNN-based VVC loop filters require training different models for different quantization parameters (QP), resulting in high resource consumption and excessive memory burden on video codecs.

Method used

We employ a lightweight CTU-quality tri-classification network and three CNN filtering networks of varying complexity. By training on classification and filtering datasets, we achieve adaptive filtering of encoded videos under different QPs, reducing model training resource consumption and improving filtering performance.

Benefits of technology

It improves video compression quality and efficiency, reduces model training resource consumption, and enhances the performance of video codecs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116347107B_ABST
    Figure CN116347107B_ABST
Patent Text Reader

Abstract

The application discloses a VVC video coding standard-based QP adaptive loop filtering method based on a variable CNN, and belongs to the technical field of video coding. The method comprises the following steps: constructing a lightweight CTU quality three-classification network; constructing three CNN filtering networks with different complexities; constructing filtering and classification data sets; training a lightweight CTU quality three-classification network model and three CNN filtering network models with different complexities; coupling the lightweight CTU quality three-classification network and the three CNN filtering networks with different complexities, and integrating the coupled network into a VTM6.0 of the VVC standard. The application makes full use of the advantages of deep learning in image filtering and denoising, improves the performance of the loop filter in the video encoder, and effectively improves the overall video quality and compression efficiency.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the field of video compression encoding, and relates to a loop filtering method in the VVC encoding standard. BACKGROUND

[0002] In recent years, video services have developed rapidly, and the demand for high resolution and high definition has been increasing. In particular, emerging video applications such as 8K video, panoramic video, virtual reality (VR) video, etc. have brought great challenges to video encoding and transmission. In the video encoding process, block-based video encoding standards represented by H.264, HEVC, and VVC often produce compression noise due to the use of lossy compression techniques, causing output frame distortion, which is manifested as picture blurring, ringing, and blocking effects, etc. As a follow-up standard of High Efficiency Video Coding (HEVC), the new generation of multi-functional video coding standard (VVC) was determined by the JVET group established by VCEG and MPEG in July 2020, and the VVC test model VTM6.0 was released, with a coding performance improvement of more than 30% compared to HEVC. In order to reduce the compression noise of the output frame, VVC uses three loop filters after the Luminance Mapping and Chrominance Scaling (LMCS) process: namely the Deblocking Filter (DBF), the Sample Adaptive Offset (SAO) filter, and the Adaptive Loop Filter (ALF). Although the new generation of multi-functional video coding standard VVC has surpassed the previous High Efficiency Video Coding standard HEVC in terms of coding performance, and has added the Adaptive Loop Filter (ALF) to the existing loop filters in HEVC, the loop filtering performance has been improved, but the output frame is still affected by block-based encoding and lossy compression techniques, and the problems of blurring, ringing, and blocking effects in the output frame still exist.

[0003] With the rapid development of deep learning, convolutional neural network (CNN) shows good performance in image super-resolution, image restoration and image classification, which promotes its application in coding optimization. In recent years, researchers actively explore video coding methods that integrate deep learning. Among them, the CNN-based loop filter has been proposed to replace or partially replace the loop filter in the coding standard to reduce compression noise. Compared with the loop filter in the VVC standard, the subjective quality of the output frame is greatly improved, and the overall coding efficiency of the encoder is also improved. Since different quantization steps (QPs) have a direct impact on video compression quality in video coding, most current CNN-based loop filter research needs to train and deploy different models for different quantization parameters QP, which undoubtedly greatly increases the resource consumption of training models and the memory burden of video encoders and decoders, making it difficult to deploy CNN-based loop filter encoders in practical applications. A large amount of data shows that even in a frame of image with the same QP value, the compression quality of different CTU blocks is quite different due to uneven distribution of texture information, which in turn leads to large differences in filtering difficulty. If different compression quality, i.e. different filtering difficulty, of CTU blocks can be distinguished and processed, the performance of CNN-based loop filter will be greatly improved. Classification task is a common task in image processing in deep learning, and CNN-based classification model can classify CTU blocks with different filtering difficulties through supervised training, so as to better perform subsequent filtering tasks. In the above background, the present application proposes a QP adaptive loop filtering method based on variable CNN for VVC video coding standard, which includes a lightweight CTU quality three-classification network and three CNN filtering networks with different complexities. Compared with the VVC standard and existing CNN-based loop filtering video coding methods, the method maintains better filtering performance for encoded videos under different QPs. SUMMARY

[0004] The technical problem to be solved by the present application is that the existing CNN-based coding method for improving the VVC loop filter needs to train and deploy different models for different quantization parameters QP, resulting in large model training resource consumption and excessive memory burden of video encoders and decoders.

[0005] A QP adaptive loop filtering method based on variable CNN for VVC video coding standard is proposed, which can effectively process encoded videos with different quantization steps QP through a lightweight CTU quality three-classification network and three CNN filtering networks with different complexities. The method can effectively improve the compression video quality and improve the video compression efficiency.

[0006] To achieve the above purpose, the present application adopts the following technical solutions:

[0007] The VVC video coding standard based on variable CNN QP adaptive loop filtering method contains the following contents:

[0008] Step 1: Construct a lightweight CTU quality three-classification network;

[0009] The lightweight CTU quality three-classification network only contains five convolutional layers, one average pooling layer and one fully connected layer. The convolutional layer is responsible for feature extraction, and the pooling layer and fully connected layer output a probability vector.

[0010] Step 2: Construct three CNN filtering networks with different complexities;

[0011] The network model is constructed based on the "Encoder-Decoder" idea. By capturing features at different levels, the features are integrated in a feature stacking manner, so that the image can be better filtered. The model structure includes an encoding part and a decoding part. The encoder consists of three convolutional operations and three downsampling operations. The input image is subjected to convolution operation and then downsampling each time. The convolutional layer is used to extract features, and the downsampling can increase the robustness of some small disturbances of the input image, such as image translation, rotation, etc., reduce the risk of overfitting, reduce the amount of calculation, and increase the size of the receptive field. The decoder consists of three convolutional operations and three upsampling operations, as well as a skip connection. The convolutional operation is used to extract some deeper features, and the upsampling can restore the abstract features to the size of the original image. The skip connection fuses the position information at the bottom layer with the semantic information at the deep layer through splicing to obtain a more rich feature map. Finally, a convolutional layer is used to obtain the filtered image.

[0012] On the basis of the constructed network framework, in view of the problems of insufficient feature capturing ability of ordinary convolutional layer and insufficient non-linear mapping ability of skip connection. By designing a convolutional block instead of a convolutional layer to improve the network's ability to capture features, and adding the same convolutional block in the skip connection to improve the network's non-linear mapping ability, the robustness of the filtering network is increased.

[0013] Step 3: Construct a classification and filtering dataset;

[0014] The data set comes from the public data set DIV2K for super-resolution reconstruction, which contains 1000 2k high-resolution images, of which 800 are used as a training set, 100 as a validation set, and 100 as a test set. Convert the 1000 images to YUV420 format and encode them by VTM-6.0 in full intra configuration, randomly select QP from [27, 42], turn off DBF, SAO and ALF during compression, and extract the encoded images. Cut the encoded images and the corresponding original images into 128x128 sub-images, and discard the sub-images that are not 128x128. Cut the original images and the corresponding encoded images into 128x128 sub-images to form a sub-image pair. Calculate the peak signal-to-noise ratio (PSNR) of the obtained sub-image pair, and sort the sub-image pairs according to the PSNR from low to high.

[0015] For the classification data set: divide the sub-images of the original image into three equal parts according to the low, medium and high PSNR of the sub-image pair, and label them as filter difficulty simple, medium and difficult.

[0016] For the filter data set: take the sub-image pair of the original image as the true value, and form a sub-image pair with the corresponding sub-image pair of the encoded image. Divide the sub-image pair into three equal parts according to the low, medium and high PSNR of the sub-image pair, and use them as data sets for three CNN filter networks of different complexity.

[0017] Step 4: Train the lightweight CTU quality three-classification network model and the three CNN filter network models of different complexity;

[0018] When training the lightweight CTU quality three-classification network, the batch_size of network training is set to 32, the epoch is set to 100000, NLLLoss is selected as the loss function, the optimization algorithm is the stochastic gradient descent algorithm, the momentum is 0.9, the weight decay is 0.0001, the initial learning rate is 0.001, and in the preheating stage of training (i.e. the first 10 iterations) the learning rate is increased linearly to 0.001, and then the learning rate is decayed by an exponential factor of 0.95. When the loss on the validation set no longer decreases, stop training the model to prevent overfitting.

[0019] When training the three CNN filter networks of different complexity, the batch_size of network training is set to 32, the epoch is set to 100000, the MSE loss function is selected, and the cosine annealing learning strategy is used to adjust the learning rate. The initial learning rate is set to 1e-3, the minimum value is set to 1e-7, and the cosine period is 500k iterations.

[0020] Step 5: Coupling and integration of the lightweight CTU quality three-classification network and the three CNN filter networks of different complexity into VTM6.0;

[0021] After the CTU is entropy decoded, it will pass through a lightweight CTU quality three-classification network, output three different PSNR level CTU blocks, and then select into the corresponding complexity CNN filtering network for filtering. The classification model and the filtering model are integrated into VTM6.0 through libtorch inference, replacing DB, SAO and ALF in VTM6.0.

[0022] Compared with the prior art, the present application has the following advantages:

[0023] 1. The method of convolutional neural network replaces the traditional loop filtering method in VTM6.0, and compared with

[0024] VVC standard and existing CNN-based loop filtering video encoding method, the encoding video under different QP values maintains more excellent filtering performance.

[0025] 2. The lightweight CNN quality three-classification network and the three different complexity CNN filtering networks realize the loop filtering of the variable QP value coding frame, and avoid the disadvantages of training and deploying the filtering network for a specific QP value. BRIEF DESCRIPTION OF DRAWINGS

[0026] Figure 1 is a flowchart of the adaptive QP adaptive loop filtering method of the present application;

[0027] Figure 2 is a network structure schematic diagram of the lightweight CTU quality three-classification network of the present application;

[0028] Figure 3 is a network structure schematic diagram of the three different complexity CNN filtering networks of the present application;

[0029] Figure 4 is a VTM6.0 schematic diagram of the QP adaptive loop filtering method based on convolutional neural network provided by the present application. DETAILED DESCRIPTION

[0030] The present application mainly realizes the QP adaptive loop filtering method based on convolutional neural network in the VVC video encoding standard. The specific method adopted by the present application will be described in detail below with reference to the drawings.

[0031] Specifically, the flow of the QP adaptive loop filtering method based on convolutional neural network in the VVC video encoding standard is as follows Figure 1As shown, the method comprises the following steps: S1: constructing a lightweight CTU quality three-classification network; S2: constructing three CNN filtering networks with different complexities; S3: constructing classification and filtering datasets; S4: training the lightweight CTU quality three-classification network model and the three CNN filtering network models with different complexities; and S5: coupling the lightweight CTU quality three-classification network with the three CNN filtering networks with different complexities and integrating the coupled network into VTM6.0.

[0032] For S1: constructing a lightweight CTU quality three-classification network

[0033] In the present application, the network structure design of the lightweight CTU quality three-classification network is as shown in Figure 2 The network structure mainly comprises five convolution layer modules, one global average pooling layer and one full connection layer. The five convolution layer modules: the first convolution layer adopts a 3x3 size convolution kernel, and the output is 128 channels. The next four 1x1 convolution modules are sequentially connected, wherein each convolution layer is followed by a nonlinear activation layer (LeakyRelu layer) in sequence, and the last 1x1 convolution is not followed by a nonlinear activation layer.

[0034] The average pooling layer and the full connection layer: the lightweight CTU quality three-classification network is finally connected with a global average pooling layer and a full connection layer. The kernel size of the global average pooling is 2x2, and the purpose is to compress the matrix output by the front-end network to 1x1 size, then expand and input it to the full connection layer. The full connection layer is an implementation of a softmax function, which maps a high-dimensional vector to a low-dimensional vector of a given class, and the sum of the elements of the low-dimensional vector is 1. The value of each element represents the probability size of its corresponding class.

[0035] For S2: constructing three CNN filtering networks with different complexities

[0036] In the present application, the network structure design of the three CNN filtering networks with different complexities is as shown in Figure 3 The three CNN filtering networks with different complexities all adopt the same network structure, and the complexity of the network is controlled by controlling the size of the channel number, as shown in Figure 3 The initial channel numbers of the three networks are 8, 16 and 32 respectively. The overall structure of the network comprises a down-sampling part Figure 3 (left half of the network structure diagram) and an up-sampling part Figure 3The right half of the network structure diagram) is composed of two parts, which are connected through a convolution block. The input image is down-sampled to extract important features of the image, and the up-sampling part is used to map these features to the resolution of the original image. Finally, a 3x3 convolution kernel is used to output the filtered image. The essence of the network structure is to capture important details in the image through down-sampling and up-sampling, and to combine these details with the resolution of the original image through the convolution block connecting the down-sampling and up-sampling parts. The convolution block is in the shape of a residual structure, with two 3x3 convolutions on the left, each followed by a non-linear activation layer (LeakyRelu layer), and a 1x1 convolution layer on the right connecting the input of the convolution block and the output of the two 3x3 convolution layers.

[0037] For S3: Constructing classification and filtering dataset

[0038] The dataset is derived from the public dataset DIV2K for super-resolution reconstruction, which contains 1000 2k high-resolution images, of which 800 are used as the training set, 100 as the validation set, and 100 as the test set. The 1000 images are converted to YUV420 format and encoded by VTM-6.0 in full-frame configuration, with QP randomly selected from [27, 42], and DBF, SAO and ALF turned off during compression. The encoded image is extracted. The encoded image and the corresponding original image are cut into 128x128 sub-images, and the part that is not enough for 128x128 is discarded. The original image and the corresponding encoded image are cut into 128x128 sub-images to form a sub-image pair. The PSNR of the obtained sub-image pair is calculated, and the sub-image pair is sorted according to the PSNR from low to high. For the classification dataset: the sub-images of the original image are divided into three equal parts according to the low, medium and high PSNR of the sub-image pair, and are labeled as filter difficulty simple, medium and difficult. For the filtering dataset: the sub-image pair of the original image is taken as the true value, and the sub-image pair of the corresponding encoded image is formed to form a sub-image pair, which is divided into three equal parts according to the low, medium and high PSNR of the sub-image pair, and is used as the dataset of the three different complexity filtering networks.

[0039] For S4: Training lightweight CTU quality three-classification network model and three different complexity CNN filtering network model

[0040] In training the lightweight CTU quality three-classification network model, the batch_size of network training is set to 32, the epoch is set to 100000, the NLLLoss is selected as the loss function, the stochastic gradient descent algorithm is selected as the optimization algorithm, the momentum is 0.9, the weight decay is 0.0001, the initial learning rate is 0.001, the learning rate is linearly increased to 0.001 in the preheating stage (i.e. the first 10 iterations), and then the learning rate is exponentially decayed by a factor of 0.95, when the loss on the validation set no longer decreases, the training of the model is stopped to prevent overfitting. In training the filtering network, the batch_size of network training is set to 32, the epoch is set to 100000, the MSE loss function is selected, and the cosine annealing learning strategy is used to adjust the learning rate. The initial learning rate is set to 1-3e, the minimum value is set to 1-7e, and the cosine period is 500k iterations. During the training, the test set is used to adjust the iteration times, data batches and other hyperparameters, and when the loss of the network no longer decreases, the test set is used to evaluate the performance of the network.

[0041] For S5: coupling the lightweight CTU quality three-classification network with three CNN filtering networks of different complexity, and integrating it into VTM6.0

[0042] The processed image is input into the trained lightweight CTU quality three-classification network and the corresponding class is output, after the processed image is inferred by the trained lightweight CTU quality three-classification network, it is input into the corresponding filtering network and the filtered image is output. The trained model is integrated into the encoder VTM6.0 using libtorch, replacing the loop filter in VTM6.0.

[0043] The above specific embodiments are only used to illustrate the technical solutions of the present application, and not to limit it. Those skilled in the art should understand that the above embodiments do not limit the present application in any form, and any similar technical solutions obtained by equivalent replacement or equivalent transformation, etc. belong to the protection scope of the present application.

Claims

1. A method for QP adaptive loop filtering based on variable CNN for VVC video coding standard, characterized in that, Comprising the following steps, Step 1: Constructing a lightweight CTU quality three-classification network; The lightweight CTU quality three-classification network only contains five convolutional layers, one average pooling layer and one fully connected layer; the convolutional layer is responsible for feature extraction, and the pooling layer and the fully connected layer output a probability vector; Step 2: Constructing three CNN filtering networks with different complexities; The CNN filtering network structure includes an encoder and a decoder; the encoder consists of three convolutional operations and three downsampling operations; the input image is subjected to convolutional operation and then downsampling each time; the decoder consists of three convolutional operations, three upsampling operations and a skip connection; a filtered image is obtained after a convolutional layer; the design of the convolutional block improves the feature capturing ability of the CNN filtering network; Step 3: Constructing classification and filtering datasets; Convert the images in the test set to YUV420 format and encode them under full intra-frame configuration by VTM-6.0, randomly select QP from [27, 42], turn off DBF, SAO and ALF during compression, and extract the encoded images; cut the encoded images and the corresponding original images into 128x128 sub-images; Cut the 128x128 sub-images obtained from the original images and the corresponding encoded images to form a sub-image pair; calculate the peak signal-to-noise ratio (PSNR) of the obtained sub-image pair, and sort the sub-image pairs according to the PSNR from low to high; Step 4: Training the lightweight CTU quality three-classification network and the three CNN filtering networks with different complexities; Step 5: Coupling the lightweight CTU quality three-classification network with the three CNN filtering networks with different complexities and integrating them into VTM6.0; After the CTU is entropy decoded, it will pass through the lightweight CTU quality three-classification network, output three CTU blocks with different PSNR levels, and then select to enter the corresponding complexity CNN filtering network for filtering.

2. The VVC video coding standard based on variable CNNs for QP adaptive loop filtering method of claim 1, wherein, In step 3, for the classification dataset: divide the original image sub-images into three equal parts according to the low, medium and high PSNR of the sub-image pair, and label them; the label is filter difficulty easy, medium and difficult; For the filtering dataset: take the original image sub-image pair as the true value, form a sub-image pair with the corresponding encoded image sub-image pair, and divide the sub-image pair into three equal parts according to the low, medium and high PSNR of the sub-image pair, respectively as the dataset of the three filtering networks with different complexities.

3. The VVC video coding standard based on variable CNNs for QP adaptive loop filtering method of claim 1, wherein, In step 4, when training the lightweight CTU quality three-classification network, the batch_size of network training is set to 32, the epoch is set to 100000, NLLLoss is selected as the loss function, the optimization algorithm is the stochastic gradient descent algorithm, the momentum is 0.9, the weight decay is 0.0001, the initial learning rate is 0.001, the learning rate is linearly increased to 0.001 in the preheating stage of training, then the learning rate is decayed by an exponential factor of 0.95, when the loss on the validation set no longer decreases, the training of the model is stopped to prevent overfitting; when training three CNN filtering networks with different complexities, the batch_size of network training is set to 32, the epoch is set to 100000, the MSE loss function is selected, and the cosine annealing learning strategy is used to adjust the learning rate; the initial learning rate is set to 1e-3, the minimum value is set to 1e-7, and the cosine period is 500k iterations.

4. The VVC video coding standard based on variable CNNs for QP adaptive loop filtering method of claim 1, wherein, The overall structure of the QP adaptive loop filtering method based on variable CNN in the VVC coding standard is a lightweight CTU quality three-classification network plus three CNN filtering networks with different complexities, which forms the entire QP adaptive loop filtering method based on variable CNN through classification and filtering; the lightweight CTU quality three-classification network divides the CTU into three categories according to the filtering difficulty, and inputs the output of the classifier into the corresponding three CNN filtering networks with different complexities according to the classification results to deal with loop filtering of different QP values.

5. The VVC video coding standard based on variable CNNs for QP adaptive loop filtering method of claim 1, wherein, The network structure design of the lightweight CTU quality classification network mainly includes 5 convolution layer modules, 1 global average pooling layer, and 1 fully connected layer; the 5 convolution layer modules: the first convolution layer uses a 3x3 size convolution kernel, with an output of 128 channels; the next four 1x1 convolution modules are sequentially connected, each of which is followed by a nonlinear activation layer, and the last 1x1 convolution is not followed by a nonlinear activation layer; the average pooling layer and the fully connected layer: the lightweight CTU quality three-classification network finally has a global average pooling layer and a fully connected layer; the kernel size of the global average pooling is 2x2, which aims to compress the matrix output by the front-end network to 1x1 size, then expand it and input it to the fully connected layer; the fully connected layer is a softmax function, the sum of the elements of the low-dimensional vector is 1, and the value of each element represents the probability size of its corresponding category.

6. The VVC video coding standard oriented variable CNN based QP adaptive loop filtering method of claim 1, wherein, The three CNN filtering networks with different complexities all use the same network structure, and the initial channel numbers of the three network structures are 8, 16, and 32 respectively; the network structure is composed of a downsampling part and an upsampling part, and connected through convolution blocks; the input image extracts important features of the image through the downsampling part, and the upsampling part is used to map these features to the resolution of the original image, and finally outputs the filtered image through a 3x3 convolution kernel; each convolution layer of the convolution block is followed by a nonlinear activation layer, and the input of the convolution block is connected to the output of the two 3x3 convolution layers through a 1x1 convolution layer on the right.