# US 2020/0404340 A1 · Multi-frame quality enhancement method and device for lossy compressed video

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2020/0404340 A1
- Document ID: US20200404340A1
- Status: Published application
- Kind: A1
- Application number: 16/968,409
- Filed: 2019-01-28
- Published: 2020-12-24
- Earliest claimed: 2018-02-08
- Assignees: Beihang University
- Applicants: Beihang University
- Inventors: Mai Xu; Ren Yang; Tie Liu; Tianyi Li; Zhaoji Fang
- Web page: https://patentgrep.com/patent/US20200404340A1

## CPC

- G06N 3/08: Learning methods
- G06F 18/214: Generating training patterns; Bootstrap methods, e.g. bagging or boosting
- G06N 3/045: Combinations of networks
- G06N 3/0464: Convolutional networks [CNN, ConvNet]
- G06N 3/09: Supervised learning
- G06V 10/764: using classification, e.g. of video objects
- G06V 10/82: using neural networks
- G06V 20/40: in video content (extracting overlay text G06V20/62; video retrieval G06F16/70; processing of video elementary streams in video servers H04N21/234; processing of video elementary streams in video clients H04N21/44)
- G06V 20/46: {Extracting features or characteristics from the video content, e.g. video fingerprints, representative shots or key frames}
- H04N 9/87: Regeneration of colour television signals (H04N9/80 takes precedence)
- H04N 19/154: Measured or subjectively estimated visual quality after decoding, e.g. measurement of distortion (use of rate-distortion criteria H04N19/147)
- H04N 19/172: the region being a picture, frame or field
- H04N 19/51: Motion estimation or motion compensation
- H04N 19/577: Motion compensation with bidirectional frame interpolation, i.e. using B-pictures
- H04N 19/86: involving reduction of coding artifacts, e.g. of blockiness
- G06N 20/10: using kernel methods, e.g. support vector machines [SVM]
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- G06V: IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- H04N: PICTORIAL COMMUNICATION, e.g. TELEVISION

## Abstract

The present application provides a multi-frame quality enhancement method and device for a lossily compressed video. The method comprises: performing quality enhancement on the i-th frame of a decompressed video stream using m frames correlated with the i-th frame to play the i-th frame with enhanced quality. The m frames are frames in the video stream. The number of the same pixels or corresponding pixels of each of the m frames and the i-th frame is greater than a preset threshold. m is a natural number greater than 1. In an implementation, a non-peak-quality frame positioned between two peak quality frames may be enhanced using the peak quality frames. The method may mitigate the quality fluctuation across a plurality of frames for providing playback of the video stream and may improve the quality of all frames in the video after the lossy compression.

## Claims

### Claim 1

A method of multi-frame quality enhancement for lossily compressed video, comprising:
performing quality enhancement on a current frame of a lossily compressed video stream using a plurality of frames of the lossily compressed video stream that are correlated with the current frame for playback of the current frame with enhanced quality, wherein the number of the same pixels or corresponding pixels of each of the plurality of frames and the current frame is greater than a preset threshold, and wherein performing quality enhancement on the current frame using the plurality of frames correlated with the current frame of the lossily compressed video stream comprises:
identifying peak quality frames and non-peak-quality frames in the lossily compressed video stream;
determining that the current frame is a non-peak-quality frame, and
performing quality enhancement on the current frame using a first peak quality frame Fp1 and a second peak quality frame Fp2 of the peak quality frames, wherein the first peak quality frame Fp1 is a previous frame of the current frame, and wherein the second peak quality frame Fp2 is a subsequent frame of the current frame.

### Claim 2

(canceled)

### Claim 3 (depends on 1)

The method according to claim 1, wherein identifying the peak quality frames and the non-peak-quality frames in the lossily compressed video stream comprises:
identifying the peak quality frames and the non-peak-quality frames in the lossily compressed video stream using a trained support vector machine (SVM).

### Claim 4 (depends on 3)

The method according to claim 3, further comprising:
providing a plurality of training videos, wherein each frame in each of the training videos is a training sample;
performing lossy compression on the training videos to generate a plurality of compressed training videos, and calculating a peak signal-to-noise ratio for each frame in each of the compressed training videos with respect to a corresponding frame in one of the training videos;
determining whether each frame in each of the training videos is a peak quality frame based on the peak signal-to-noise ratio corresponding to the frame;
extracting a plurality of pixel distribution features from each frame in each of the training videos; and
training the SVM using a plurality of training features and a plurality of labels of the training samples, wherein the training features of an i-th training sample of the training samples comprise the pixel distribution features of the i-th frame in one of the training videos and adjacent frames of the i-th frame, and wherein the i-th training sample is associated with one of the plurality of labels indicating whether the i-th training sample is a peak quality frame.

### Claim 5 (depends on 1)

The method according to claim 1, wherein performing quality enhancement on the current frame using the first peak quality frame Fp1 and the second peak quality frame Fp2 of the peak quality frames comprises:
inputting the current frame, the first peak quality frame Fp1, and the second peak quality frame Fp2 into a multi-frame convolutional neural network structure,
performing motion compensation on the first peak quality frame Fp1, and the second peak quality frame Fp2 using a motion compensation subnet in the multi-frame convolutional neural network structure to obtain a first compensated peak quality frame Fp1′ and a second compensated peak quality frame Fp2′;
performing quality enhancement on the current frame using a quality enhancement subnet in the multi-frame convolutional neural network structure; and
outputting, by the quality enhancement subnet, a quality enhanced frame representing the current frame with enhanced quality, wherein the quality enhanced frame is represented as Fnp+Rnp(θqe), wherein Fnp represents the current frame, and wherein Rnp(θqe) represents a residual reconstructed according to a trainable parameter θqe.

### Claim 6 (depends on 5)

The method according to claim 5, wherein the multi-frame convolutional neural network structure comprises: the motion compensation subnet configured to compensate temporal motion between adjacent frames and the quality enhancement subnet configured to fuse features of temporal-motion-compensated frames produced by the motion compensation subnet.

### Claim 7 (depends on 6)

The method according to claim 6, comprising:
training the motion compensation subnet and the quality enhancement subnet in the multi-frame convolutional neural network structure before inputting the current frame, the first peak quality frame Fp1, and the second peak quality frame Fp2 into the multi-frame convolutional neural network structure.

### Claim 8 (depends on 4)

The method according to claim 4, wherein determining whether each frame in each of the training videos is a peak quality frame based on the peak signal-to-noise ratio corresponding to the frame comprises:
in response to determining that a first peak signal-to-noise ratio of a first frame in a first compressed training video of the compressed training videos with respect to a first frame in a first training video of the training videos is greater than a second peak signal-to-noise ratio of a second frame in the first compressed video with respect to a second frame in the first training video and that the first peak signal-to-noise ratio is greater than a third peak signal-to-noise ratio of a third frame in the first compressed video with respect to a third frame in the first training video, determining that the first frame in the first compressed video is a peak quality frame, wherein the second frame is a previous frame of the first frame, and wherein the third frame is a subsequent frame of the first frame; and
identifying non-peak-quality frames of the training videos in view of a determination that the non-peak-quality frames are not peak quality frames.

### Claim 9

An apparatus for multi-frame enhancement for lossily compressed video, comprising:
a memory, and
a processor communicably coupled to the memory, the processor to:
perform quality enhancement on a current frame of a lossily compressed video stream using a plurality of frames of the lossily compressed video stream that are correlated with the current frame for playback of the current frame with enhanced quality, wherein the number of the same pixels or corresponding pixels of each of the plurality of frames and the current frame is greater than a preset threshold, and wherein, to perform quality enhancement on the current frame using the plurality of frames correlated with the current frame of the lossily compressed video stream, the processor is further to:
identify peak quality frames and non-peak-quality frames in the lossily compressed video stream;
determine that the current frame is a non-peak-quality frame, and
perform quality enhancement on the current frame using a first peak quality frame Fp1 and a second peak quality frame Fp2 of the peak quality frames, wherein the first peak quality frame Fp1 is a previous frame of the current frame, and wherein the second peak quality frame Fp2 is a subsequent frame of the current frame.

### Claim 10

A non-transitory computer storage medium storing a computer program, wherein the program, when executed by a processor, cause the processor to:
perform quality enhancement on a current frame of a lossily compressed video stream using a plurality of frames of the lossily compressed video stream that are correlated with the current frame for playback of the current frame with enhanced quality, wherein the number of the same pixels or corresponding pixels of each of the plurality of frames and the current frame is greater than a preset threshold, and wherein, to perform quality enhancement on the current frame using the plurality of frames correlated with the current frame of the lossily compressed video stream, the processor is further to:
identify peak quality frames and non-peak-quality frames in the lossily compressed video stream;
determine that the current frame is a non-peak-quality frame, and
perform quality enhancement on the current frame using a first peak quality frame Fp1 and a second peak quality frame Fp2 of the peak quality frames, wherein the first peak quality frame Fp1 is a previous frame of the current frame, and wherein the second peak quality frame Fp2 is a subsequent frame of the current frame.

### Claim 11 (depends on 9)

The apparatus of claim 9, wherein to identify the peak quality frames and the non-peak-quality frames in the lossily compressed video stream, the processor is further to:
identify the peak quality frames and the non-peak-quality frames in the lossily compressed video stream using a trained support vector machine (SVM).

### Claim 12 (depends on 9)

The apparatus of claim 9, wherein the processor is further to:
provide a plurality of training videos, wherein each frame in each of the training videos is a training sample;
perform lossy compression on the training videos to generate a plurality of compressed training videos, and calculating a peak signal-to-noise ratio for each frame in each of the compressed training videos with respect to a corresponding frame in one of the training videos;
determine whether each frame in each of the training videos is a peak quality frame based on the peak signal-to-noise ratio corresponding to the frame;
extract a plurality of pixel distribution features from each frame in each of the training videos; and
train the SVM using a plurality of training features and a plurality of labels of the training samples, wherein the training features of an i-th training sample of the training samples comprise the pixel distribution features of the i-th frame in one of the training videos and adjacent frames of the i-th frame, and wherein the i-th training sample is associated with one of the plurality of labels indicating whether the i-th training sample is a peak quality frame.

### Claim 13 (depends on 9)

The apparatus of claim 9, wherein to perform quality enhancement on the current frame using the first peak quality frame Fp1 and the second peak quality frame Fp2 of the peak quality frames, the processor is further to:
input the current frame, the first peak quality frame Fp1, and the second peak quality frame Fp2 into a multi-frame convolutional neural network structure,
perform motion compensation on the first peak quality frame Fp1 and the second peak quality frame Fp2 using a motion compensation subnet in the multi-frame convolutional neural network structure to obtain a first compensated peak quality frame Fp1′ and a second compensated peak quality frame Fp2′;
perform quality enhancement on the current frame using a quality enhancement subnet in the multi-frame convolutional neural network structure; and
output, by the quality enhancement subnet, a quality enhanced frame representing the current frame with enhanced quality, wherein the quality enhanced frame is represented as Fnp+Rnp(θqe), wherein Fnp represents the current frame, and wherein Rnp(θqe) represents a residual reconstructed according to a trainable parameter.

### Claim 14 (depends on 13)

The apparatus of claim 13, wherein the multi-frame convolutional neural network structure comprises: the motion compensation subnet configured to compensate temporal motion between adjacent frames and the quality enhancement subnet configured to fuse features of temporal-motion-compensated frames produced by the motion compensation subnet.

### Claim 15 (depends on 14)

The apparatus of claim 14, wherein the processor is further to:
train the motion compensation subnet and the quality enhancement subnet in the multi-frame convolutional neural network structure before inputting the current frame, the first peak quality frame Fp1, and the second peak quality frame Fp2 into the multi-frame convolutional neural network structure.

### Claim 16 (depends on 12)

The apparatus of claim 12, wherein, to determine whether each frame in each of the training videos is a peak quality frame based on the peak signal-to-noise ratio corresponding to the frame, the processor is further to:
in response to determining that a first peak signal-to-noise ratio of a first frame in a first compressed training video of the compressed training videos with respect to a first frame in a first training video of the training videos is greater than a second peak signal-to-noise ratio of a second frame in the first compressed video with respect to the a second frame in the first training video and that the first peak signal-to-noise ratio is greater than a third peak signal-to-noise ratio of a third frame in the first compressed video with respect to a third frame in the first training video, determine that the first frame in the first compressed video is a peak quality frame, wherein the second frame is a previous frame of the first frame, and wherein the third frame is a subsequent frame of the first frame; and
identify non-peak-quality frames of the training videos in view of a determination that the non-peak-quality frames are not peak quality frames.

### Claim 17 (depends on 10)

The non-transitory computer storage medium of claim 10, wherein to identify the peak quality frames and the non-peak-quality frames in the lossily compressed video stream, the processor is further to:
identify the peak quality frames and the non-peak-quality frames in the lossily compressed video stream using a trained support vector machine (SVM).

### Claim 18 (depends on 10)

The non-transitory computer storage medium of claim 10, wherein the processor is further to:
provide a plurality of training videos, wherein each frame in each of the training videos is a training sample;
perform lossy compression on the training videos to generate a plurality of compressed training videos, and calculating a peak signal-to-noise ratio for each frame in each of the compressed training videos with respect to a corresponding frame in one of the training videos;
determine whether each frame in each of the training videos is a peak quality frame based on the peak signal-to-noise ratio corresponding to the frame;
extract a plurality of pixel distribution features from each frame in each of the training videos; and
train the SVM using a plurality of training features and a plurality of labels of the training samples, wherein the training features of an i-th training sample of the training samples comprise the pixel distribution features of the i-th frame in one of the training videos and adjacent frames of the i-th frame, and wherein the i-th training sample is associated with one of the plurality of labels indicating whether the i-th training sample is a peak quality frame.

### Claim 19 (depends on 10)

The non-transitory computer storage medium of claim 10, wherein to perform quality enhancement on the current frame using the first peak quality frame Fp1 and the second peak quality frame Fp2 of the peak quality frames, the processor is further to:
input the current frame, the first peak quality frame Fp1, and the second peak quality frame Fp2 into a multi-frame convolutional neural network structure,
perform motion compensation on the first peak quality frame Fp1 and the second peak quality frame Fp2 using a motion compensation subnet in the multi-frame convolutional neural network structure to obtain a first compensated peak quality frame Fp1′ and a second compensated peak quality frame Fp2′;
perform quality enhancement on the current frame using a quality enhancement subnet in the multi-frame convolutional neural network structure; and
output, by the quality enhancement subnet, a quality enhanced frame representing the current frame with enhanced quality, wherein the quality enhanced frame is represented as Fnp+Rnp(θqe), wherein Fnp represents the current frame, and wherein Rnp(θqe) represents a residual reconstructed according to a trainable parameter.

### Claim 20 (depends on 19)

The non-transitory computer storage medium of claim 19, wherein the multi-frame convolutional neural network structure comprises: the motion compensation subnet configured to compensate temporal motion between adjacent frames and the quality enhancement subnet configured to fuse features of temporal-motion-compensated frames produced by the motion compensation subnet.

### Claim 21 (depends on 20)

The non-transitory computer storage medium of claim 20, wherein the processor is further to:
train the motion compensation subnet and the quality enhancement subnet in the multi-frame convolutional neural network structure before inputting the current frame, the first peak quality frame Fp1, and the second peak quality frame Fp2 into the multi-frame convolutional neural network structure.
