Resetting of historical motion vector prediction
By using reset list technology in video encoding, the problem of low accuracy in block motion prediction in the left area of the frame is solved, and the compression performance of video encoding is improved.
Patent Information
- Application Number
- CN202411587347.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2019-08-29
- Filing Date
- 2019-08-30
- Publication Date
- 2025-04-04
AI Technical Summary
The existing video encoding technology has low block motion prediction accuracy in the left area of the frame, resulting in low compression efficiency.
Using reset list technology, the reset list is used in the left area of the frame to reset the historical motion vector prediction value list to improve the accuracy of motion vector prediction.
By improving the accuracy of motion vector prediction, the compression performance of video encoding is enhanced, especially in the left area of the frame.
Smart Images

Figure CN119767028A_ABST
Abstract
Description
[0001] This application is a divisional application of the invention application with application date of August 30, 2019, application number 201980051840.1 (international application number PCT / US2019 / 049232), and invention name “Historical motion vector prediction using reset list”.
[0002] [Cross-reference to related applications]
[0003] This application is a continuation-in-suit application, and is entitled to and claims the benefit of priority under 35 U.S. Patent Act, Section 120, to prior U.S. Application No. 16 / 555,961, filed on August 29, 2019, which is entitled to and claims the benefit of priority to U.S. Provisional Application No. 62 / 726,121, filed on August 31, 2018. The contents of these applications are hereby incorporated by reference in their entirety for all purposes. [Background technology]
[0004] In the video coding framework, video content is compressed via a set of processes: prediction, transform, quantization, and entropy coding. One prediction method is inter prediction, which identifies temporal redundancy between adjacent video frames. Inter prediction then aims to remove temporal redundancy between adjacent video frames to reduce the number of bits sent in the encoded bitstream. For example, when temporal redundancy is identified, only the difference between blocks in adjacent video frames needs to be sent.
[0005] To perform inter-frame prediction, video frames are divided into blocks and motion compensation based on motion vectors (MVs) is applied. Part of motion compensation is the selection of motion vectors. A motion vector can be a two-dimensional value that indicates the offset (e.g., in two-dimensional pixel positions) between the current block and its matching block in an adjacent frame. The value can include position offsets in horizontal and vertical coordinates. Motion vectors are generated by the transcoder via various motion search algorithms and sent to the decoder, which uses the motion vectors in the decoding process.
Brief Description of the Drawings
[0006] Figure 1 A simplified system for performing motion prediction according to some implementations is depicted.
[0007] Figure 2 An inter-coded frame with coding blocks according to some embodiments is depicted.
[0008] Figure 3Depicted is an example of a row-by-row raster scan order for processing a current frame in accordance with some implementations.
[0009] Figure 4 Depicted is an example of a transcoder motion prediction block when using historical motion vector prediction according to some implementations.
[0010] Figure 5 An example of a problem when encoding the current block C is illustrated.
[0011] Figure 6 Depicted is an example of transcoding frames while using a reset list in accordance with some implementations.
[0012] Figure 7 Depicted is a simplified flow diagram of a process for storing motion vectors in a historical motion vector predictor list in accordance with some embodiments.
[0013] Figure 8 Depicted is a simplified flow diagram of a process for storing motion vectors in a historical motion vector predictor list using a reset list in accordance with some embodiments.
[0014] Fig. 9A An example of wavefront encoding is depicted.
[0015] Fig. 9B Depicted is an example of wavefront encoding using a reset list in accordance with some implementations.
[0016] Fig.10 An example of a transcoding system according to some implementations is depicted.
[0017] Fig.11 An example of a decoding system according to some implementations is depicted. [Specific implementation method]
[0018] This article describes techniques for video encoding systems. In the following description, for the purpose of illustration, numerous examples and specific details are set forth in order to provide a thorough understanding of some embodiments. Some embodiments defined by the claims may include some or all of the features in these examples alone or in combination with other features described below, and may also include modifications and equivalents of the features and concepts described herein.
[0019] Some methods of motion vector prediction include: spatial motion vector prediction, temporal motion vector prediction, and historical motion vector prediction. Spatial motion vector prediction uses the motion vectors of neighboring blocks as predictors; temporal motion vector prediction uses the motion vectors of blocks in neighboring frames as predictors; and historical motion vector prediction utilizes a list of previously encoded motion vectors as predictors.
[0020] The motion vectors (MVs) of neighboring blocks may be similar to each other. The transcoder may use this property during motion vector prediction to further reduce the overhead for representing motion vectors in the encoded bitstream. The transcoder may perform motion vector prediction based on the following formula, although other calculations may be used:
[0021] MV = MV predicted value (MVP) + MV difference (MVD),
[0022] Where MV is the motion vector position, the motion vector predictor (MVP) is the previously encoded motion vector, and the motion vector difference (MVD) is the residual value sent by the transcoder in the encoded bitstream. The residual value can be the change from the motion vector predictor to the motion vector of the current block. The transcoder can encode the residual value using a number of bits corresponding to the residual value. As the magnitude of the value increases, the number of bits required to encode the residual value increases. Since the magnitude of the motion vector difference should be smaller than the original motion vector, the number of bits used when encoding the motion vector can be reduced. That is, when the transcoder sends the motion vector difference instead of the original motion vector, the transcoder uses fewer bits in the encoded bitstream.
[0023] Some embodiments enhance the historical motion vector prediction process by using an additional list called a reset list during the transcoding process. When transcoding certain blocks in a frame (e.g., blocks at the beginning of each coding block row), the transcoder can use a reset list. The transcoder can use a double buffer model to implement the process. For example, the transcoder uses a reset buffer to store historical motion vector prediction values from blocks at the beginning of each coding block row. When the transcoder encodes the blocks at the beginning of each coding block row, the transcoder inserts these historical motion vector prediction values into the historical motion vector prediction value buffer. The inserted historical motion vector prediction value can be more similar to the motion vector of the block at the beginning of each row, as will be described in more detail below. Using more similar historical motion vector prediction values can enhance historical motion vector prediction by improving the accuracy of motion vector prediction, especially at the beginning of each coding block row. Finally, since historical motion vector prediction is more effective, the compression performance of the transcoder can be improved by inserting fewer bits in the encoded bit stream.
[0024] System Overview
[0025] Figure 1A simplified system 100 for performing motion prediction according to some embodiments is depicted. The system 100 transcodes a source video asset, which may be any type of video, such as for a television program, a movie, or a video clip. The source video may need to be transcoded into one or more formats, such as formats at one or more bit rates. In some embodiments, a server system 102 sends an encoded bitstream to a client 104. For example, the server system 102 may send the video to the client 104 for playback.
[0026] The server system 102 includes a transcoder 106 that transcodes a video into an encoded bit stream. The transcoder 106 can be a software video processor / transcoder configured on a central processing unit (CPU), a hardware accelerated video processor / transcoder with a graphics processing unit (GPU), a field programmable gate array (FPGA), and / or a hardware processor / transcoder implemented in an application specific integrated circuit (ASIC). Transcoding can be a conversion from one digital format to another digital format. Transcoding can involve decoding the source format and encoding the source video into another digital format, or converting the source content into a video with a specific resolution, frame rate, bit rate, codec, etc. Moreover, encoding can be converting analog source content into a digital format. As used, the term transcoding can include encoding.
[0027] During the transcoding process, the transcoder motion prediction block 108 performs motion prediction on a current block of a current frame. During motion prediction, when transcoding the current block, the transcoder motion prediction block 108 may generate and use a reset list, which will be described in more detail below.
[0028] The transcoder 106 sends the resulting encoded bit stream to the decoder 112 via a network or other type of communication medium. The decoder 112 receives the encoded bit stream, and the decoder motion prediction block 110 performs motion prediction during the decoding process. During motion prediction, the decoder motion prediction block 110 can generate and use a list of historical motion predictions when performing decoding, which will be described in more detail below. Given a coding block, the decoder motion prediction block 110 selects a motion vector prediction value from the list and receives a motion vector difference from the bit stream. For example, the decoder motion prediction block 110 adds the difference to the motion vector prediction value to generate the motion vector of the current block. In order to ensure that the transcoder 106 and the decoder 110 work in a consistent manner and generate the same video, the following description of the process is applied to both the transcoder 106 and the decoder 110.
[0029] Historical Motion Vector Prediction
[0030] Figure 2An inter-coded frame 200 with coded blocks 202 is depicted according to some embodiments. Each coded block 202 may have one or more motion vectors 204 pointing to a location in another frame. That is, Figure 2 The arrows in are motion vectors and point to a location in another frame in the video (not shown). Although one arrow is shown per block, each block may include multiple motion vectors.
[0031] The historical motion vector prediction maintains a first buffer, such as a first-in-first-out (FIFO) buffer, having a list storing historical motion vector predictors (HMVPs) that can be used as motion vector predictor candidates for a current coding block. Figure 3 An example of a row-by-row raster scan order for processing a current frame according to some embodiments is depicted. The processing order shown starts at block 0 at 302, and the transcoder motion prediction block 108 processes coded blocks 1, 2, .... to block 23 at 304. The transcoder motion prediction block 108 can process the coded blocks sequentially. Although this scan order is described, other scan orders are contemplated.
[0032] In a raster scan, the transcoder motion prediction block 108 subdivides the image into a sequence of rows that are scanned from left to right in a direction such as horizontally. When encoding a block, the transcoder motion prediction block 108 can use previous motion vectors from blocks that have been encoded in the motion prediction process. Using block #16 as the current encoding block, the transcoder motion prediction block 108 has already encoded the previous blocks #0 to #15, and the transcoder motion prediction block 108 has stored the corresponding motion vectors. The transcoder motion prediction block 108 can use these motion vectors as historical motion vector prediction values for block #16. However, in actual use, the transcoder motion prediction block 108 cannot store all corresponding motion vectors of previously encoded blocks. For example, the transcoder motion prediction block 108 may have storage limitations that prevent the storage of all previous motion vectors of previously encoded blocks.
[0033] The above limitations are described in more detail below. Figure 4An example of the transcoder motion prediction block 108 when using historical motion vector prediction according to some embodiments is depicted. When the transcoder motion prediction block 108 processes the current coding block C, the transcoder motion prediction block 108 loads the historical motion vector prediction value candidates from the historical motion vector prediction value list storage 402 (e.g., a buffer). The transcoder motion prediction block 108 uses the historical motion vector prediction values as possible motion vector prediction values during the transcoding process of the current block C. That is, the transcoder motion prediction block 108 can select one of the historical motion vector prediction values, such as the historical motion vector prediction value that is closest in value to the current motion vector of the current block. The transcoder motion prediction block 108 then calculates the motion vector difference between the historical motion vector prediction value and the current motion vector.
[0034] When the process of encoding the block is completed, the transcoder motion prediction block 108 stores the resulting motion vector in the historical motion vector prediction value list storage 402 to update the historical motion vector prediction value list. The size of the historical motion vector prediction value list can always be fixed; thus, when the transcoder motion prediction block 108 adds a new motion vector prediction value to the historical motion vector prediction value list, if the FIFO buffer is full, the older motion vector prediction value, such as the oldest prediction value, can be removed. The selection of the list size is a trade-off factor between complexity and coding efficiency. Larger historical motion vector prediction value lists require more memory and are more complex to maintain, but can improve coding efficiency because the probability that the best motion vector prediction value exists in the historical motion vector prediction value list will be higher. However, a smaller list will be easier to maintain and take less time to search. In some cases, the size of the historical motion vector prediction value list is equal to between four and ten motion vectors.
[0035] In some cases, such as when encoding the first N blocks of each coding block row, using only a single list of historical motion vector predictors may not be efficient. Figure 5 An example of a problem when encoding the current block C at 502 is illustrated. Frame 500 includes a block that has been previously encoded at 504 (shaded block) and a block that has not yet been encoded at 506. Although the first block of a row is discussed, the first N blocks of a row may experience similar problems. However, the first block may not have a left neighbor, so the use of a reset list may be more beneficial for the first block of a row than the second block of a row from the left. That is, the second block in a row has the first block as a left neighbor. However, the first block is at the leftmost edge of the row and has no left neighbor.
[0036] When the transcoder motion prediction block 108 encodes block P at 508, the motion vector from the previous block at 510 adjacent to block P is available in the historical motion vector predictor list and may be similar to the motion vector of block P. This similarity will improve coding efficiency compared to using motion vectors that may not be so similar (e.g., from the block at 512). However, when the transcoder motion prediction block 108 starts processing the current block C, depending on the size of the historical motion vector predictor list, the historical motion vector predictor list may only include the motion vector from block P at 508. For example, block P may already have ten motion vectors stored in the historical motion vector predictor list, which causes all other motion vectors to be removed from the historical motion vector predictor list. Since the spatial distance between block C and block P is large (e.g., block C is on the left side of the image, and block P is on the right side of the image), the possibility that the motion of block C and block P is completely independent may be high. If the blocks are adjacent to each other, this may be different. Considering the positions of block C and block P, the motion vector in the historical motion vector predictor list may not be related to the current block C. That is, if the size of the historical motion vector predictor list is not large enough, there may be no available historical motion vector predictor candidates in the historical motion vector predictor list of the current block C. Therefore, the motion prediction accuracy of the blocks in the first coding block column in the frame is lower than that of other blocks in the frame 500, and the compression efficiency of the blocks in this area may be worse.
[0037] To solve the above problem, when processing some blocks in an area of a frame (e.g., the left side of the frame), the transcoder motion prediction block 108 uses a reset list to reset the historical motion vector prediction value list. For example, the transcoder motion prediction block 108 uses a dual list storage model including a conventional historical motion vector prediction value list and a reset list. The conventional historical motion vector prediction value list is a list retrieved during transcoding of the current block and is updated after processing of the coded block as described above. The reset list stores motion vectors from N blocks on the left side of the previously coded frame for use when the blocks on the left side of the frame are currently being coded.
[0038] Historical motion vector prediction using reset list
[0039] Figure 6 An example of transcoding a frame 500 when using a reset list is depicted according to some embodiments. In each coding block row, after processing the first N coding blocks (e.g., T0, T1, ..., TN) from the left side of the row, the transcoder motion prediction block 108 copies and stores at least a portion of the entries in the regular historical motion vector predictor list from the first N coding blocks into the reset list.
[0040] Then, later in the encoding process, when the transcoder motion prediction block 108 encodes the blocks at the beginning of each coding block row, such as encoding at the coding unit C at 502, the transcoder motion prediction block 108 can copy and store at least some entries in the reset list into the regular historical motion vector prediction value list. For example, the transcoder motion prediction block 108 copies the motion vectors of the blocks T0 at 602 and T1 to TN at 604 from the reset list into the regular historical motion vector prediction value list. Then, the blocks in the first coding block column in the frame 500 can use the motion vectors from the top neighboring blocks to perform historical motion vector prediction. Compared with the motion vectors from the rightmost blocks of the frame, the motion vectors from the top neighboring blocks can be more similar to the motion vector of the current block C at 502, because the top neighboring blocks are adjacent to the current block C, such as adjacent to the top edge of the current block C, or closer to the current block C than the rightmost blocks in the frame. These blocks are more likely to contain similar content than the rightmost blocks or other blocks that are farther away from the current block C. Thereby, motion prediction accuracy and coding efficiency can be improved.
[0041] Moreover, in some embodiments, the transcoder motion prediction block 108 may store other types of motion vectors in the reset list, such as motion vectors having horizontal and vertical components equal to zero, or global motion vectors that track the overall motion of the video content, etc. These motion vectors may be default motion vectors or predefined motion vectors. Moreover, the transcoder motion prediction block 108 may analyze the characteristics of the video and store certain motion vectors in the reset list, for example, when the motion moves horizontally, the transcoder motion prediction block 108 stores horizontal motion vectors in the reset list. Moreover, the conventional historical motion vector prediction value list of the current block C may be initialized to have predefined entries, which may also improve motion prediction accuracy.
[0042] Figure 7 A simplified flow chart of a process 700 for storing motion vectors in a historical motion vector predictor list according to some embodiments is depicted. At 702, the transcoder motion prediction block 108 begins transcoding the frame 500. At 704, the transcoder motion prediction block 108 initializes the historical motion vector predictor list.
[0043] At 706, the transcoder motion prediction block 108 begins encoding the current block C 502. At 708, the transcoder motion prediction block 108 retrieves the historical motion vector predictor from the historical motion vector predictor list. Then, at 710, the transcoder motion prediction block 108 transcodes the current block using the motion vector from the historical motion vector predictor list. After transcoding the current block, at 712, the transcoder motion prediction block 108 updates the historical motion vector predictor list with the resulting motion vector from the current block. At 714, the transcoder motion prediction block 108 determines whether there are more blocks to process in the current frame. If so, the process repeats to 706 to process another block. If not, at 716, the transcoder motion prediction block 108 ends processing the current frame 500.
[0044] Reset List
[0045] When processing some blocks of the current frame 500 in the first portion of the current frame 500, such as blocks on the right side of the current frame 500, the transcoder motion prediction block 108 may use Figure 7 However, when processing some blocks in the second portion of the current frame 500, such as blocks in the first column of the current frame 500 or on the left side of the current frame 500, the transcoder motion prediction block 108 uses the reset list. Figure 8 A simplified flow chart of a process 800 for storing motion vectors in a historical motion vector predictor list using a reset list according to some embodiments is depicted. At 802, the transcoder motion prediction block 108 begins encoding a current frame 500. At 804, the transcoder motion prediction block 108 initializes a historical motion vector predictor list and a reset list.
[0046] At 806, the transcoder motion prediction block 108 begins encoding the current block C 502. At 808, the transcoder motion prediction block 108 determines whether the current block is the first block of the row (or a block in the second part of the reset list). If this is the first block of the row, then at 810, the transcoder motion prediction block 108 copies at least a portion of the reset list to the historical motion vector predictor list. This can reset the historical motion vector predictor list. Depending on the size of the historical motion vector predictor list, all existing motion vectors in the historical motion vector predictor list can be replaced by motion vectors from the reset list, or only some of the existing motion vectors in the historical motion vector predictor list can be replaced. Alternatively, the transcoder motion prediction block 108 can use the reset list instead of the historical motion vector predictor list. Alternatively, the transcoder motion prediction block 108 can retrieve motion vector predictors from both lists. Then, at 812, the transcoder motion prediction block 108 retrieves the historical motion vector predictor from the historical motion vector predictor list. At 814 , the transcoder motion prediction block 108 processes the current block C 502 using the historical motion vector predictor list.
[0047] When the transcoding of the current block C 502 is completed, the transcoder motion prediction block 108 stores the motion vector from the transcoding in the historical motion vector predictor list. The motion vector stored in the reset list is the motion vector of the block from the left side of the frame. Therefore, at 818, the transcoder motion prediction block 108 determines whether the current block C that has just been transcoded is one of the N coded blocks from a row. If so, then at 820, the transcoder motion prediction block 108 stores the motion vector from the historical motion vector predictor list in the reset list. Alternatively, the transcoder motion prediction block 108 stores the motion vector from the current block C in the reset list. At 822, the transcoder motion prediction block 108 determines whether there are more blocks to be processed in the current frame. If so, the process repeats to 806 to process another block. If not, then at 824, the transcoder motion prediction block 108 ends processing the current frame 500.
[0048] Therefore, when the current block is one of the first N coded blocks of the frame, the historical motion vector predictor list includes motion vectors from other blocks on the left side of the frame. However, when the current block is not in the leftmost N blocks of the frame, the historical motion vector predictor list includes typical motion vectors previously stored from adjacent blocks. When the N coded blocks starting from the left are transcoded, the transcoder motion prediction block 108 stores the motion vectors in the historical motion vector predictor list as well as the reset list. When blocks other than the N coded blocks starting from the left side of the row are transcoded, the transcoder motion prediction block 108 stores the motion vectors only in the historical motion vector predictor list.
[0049] In another example, when performing wavefront parallel encoding of parallel processing block rows, it may be difficult to use the existing single historical motion vector predictor table approach. Fig. 9A An example of wavefront encoding is depicted. The encoding of the block at the beginning of row N must wait for the end of the block in row N1. That is, thread #1 at 902 cannot start encoding the block in row N until thread #0 at 904 processes the entire row of blocks. However, the efficiency of wavefront encoding can be improved by using a reset list, which allows encoding to be performed in parallel. Fig. 9B An example of wavefront coding using a reset list according to some embodiments is depicted. For example, once the reset list for row N1 (the row before row N) is filled with motion vectors at 906, thread #1 can immediately start encoding row N because some motion vectors for the first N blocks are already stored in the reset list.
[0050] Decoder-side motion prediction
[0051] When the decoder motion prediction block 110 receives the encoded bitstream, the decoder motion prediction block 110 decodes the current block. To determine the motion vector of the current block, the decoder motion prediction block 110 uses the historical motion vector prediction value list with the reset list. Once the motion vector and reference block have been determined, the decoder motion prediction block 110 uses the residual in the encoded bitstream and the value of the reference block to decode the current block.
[0052] Implementation
[0053] In some embodiments, a method includes the following steps: selecting, by a computing device, a current block in a frame; determining, by the computing device, whether the current block is in a first set of positions in the frame; when the current block is in the first set of positions: loading, by the computing device, a first set of motion vectors from a first list as historical motion vector prediction values, wherein one or more motion vectors are from one or more blocks in the first set of positions in the frame; and transcoding the current block using the first set of motion vectors by the computing device; and when the current block is not in the first set of positions, using a second set of motion vectors from a second list by the computing device.
[0054] In some implementations, the first set of positions in the frame includes N blocks starting from the left side of the frame.
[0055] In some implementations, the first set of positions in the frame includes the leftmost block starting from the left side of the frame.
[0056] In some implementations, the one or more blocks include a block adjacent to the current block on a top edge of the current block.
[0057] In some embodiments, loading the first set of motion vectors from the first list as historical motion vector predictors includes loading the first set of motion vectors into a second list.
[0058] In some implementations, when the current block is in the first set of positions, the motion vectors in the second list are used to transcode the current block.
[0059] In some embodiments, loading the first set of motion vectors into the second list removes some existing motion vectors in the second list.
[0060] In some embodiments, the second list stores historical motion vector prediction values from blocks that were sequentially transcoded before the current block.
[0061] In some implementations, the first list is not used when transcoding chunks outside of the first set of chunks.
[0062] In some embodiments, the method further comprises the steps of: selecting one of the historical motion vector predictors; calculating a difference between one of the historical motion vector predictors and the motion vector of the current block; and including the difference in the encoded bitstream.
[0063] In some embodiments, the method further comprises the step of storing a motion vector of the current block in a first list, wherein the motion vector may be used as a historical motion vector predictor for another block in the first set of positions.
[0064] In some embodiments, the first list includes motion vectors from blocks in the first set of positions.
[0065] In some implementations, when the current block is in the first set of positions: the current block is transcoded before completing transcoding of blocks in a previous row.
[0066] In some embodiments, a non-transitory computer-readable storage medium having computer-executable instructions stored thereon, which, when executed by a computing device, causes the computing device to: select a current block in a frame; determine whether the current block is in a first set of positions in the frame; when the current block is in the first set of positions: load a first set of motion vectors from a first list as historical motion vector prediction values, wherein one or more motion vectors are from one or more blocks in the first set of positions in the frame; and use the first set of motion vectors to transcode the current block; and when the current block is not in the first set of positions, use a second set of motion vectors from a second list.
[0067] In some implementations, the first set of positions in the frame includes N blocks starting from the left side of the frame.
[0068] In some implementations, the first set of positions in the frame includes the leftmost block starting from the left side of the frame.
[0069] In some implementations, the one or more blocks include a block adjacent to the current block on a top edge of the current block.
[0070] In some embodiments, loading the first set of motion vectors from the first list as historical motion vector predictors includes loading the first set of motion vectors into a second list.
[0071] In some implementations, the first list is not used when transcoding chunks outside of the first set of chunks.
[0072] In some embodiments, a device includes: one or more computer processors; and a computer-readable storage medium, the computer-readable storage medium including instructions for controlling the one or more computer processors to be operable to: select a current block in a frame; determine whether the current block is in a first set of positions in the frame; when the current block is in the first set of positions: load a first set of motion vectors from a first list as historical motion vector prediction values, wherein one or more motion vectors are from one or more blocks in the first set of positions in the frame; and use the first set of motion vectors to transcode the current block; and when the current block is not in the first set of positions, use a second set of motion vectors from a second list.
[0073] system
[0074] Fig.10 An example of a transcoding system according to some embodiments is depicted.A video codec framework includes a set of basic components: block partitioning, inter- and intra-frame prediction, transform and quantization, and entropy coding.
[0075] The transcoder 106 receives a video frame, which is first divided into non-overlapping coding blocks for further processing. In order to cope with different video content characteristics, complex areas will be covered by partitions with smaller sizes, while simple areas will be covered by larger partitions. Multiple block modes and shapes can be used together, for example, quadtree mode, ternary tree mode and binary tree mode can be used together, and square blocks and rectangular blocks can also be used together.
[0076] Prediction is used to remove redundancy of the video signal. By subtracting the predicted pixel value from the pixel being processed, the amplitude of the residual signal can be significantly reduced, thereby reducing the resulting bitstream size. The intra-frame prediction block 1010 using reference pixels in the current frame is intended to reduce spatial redundancy within the frame. The inter-frame prediction block 1012 using reference pixels from adjacent frames attempts to remove temporal redundancy between frames. The motion estimation and compensation block 1016 can be a submodule of inter-frame prediction on the transcoder side, which captures the motion trajectory of objects between adjacent frames and generates reference pixels for inter-frame prediction.
[0077] The transform and quantization block 1004 uses the remaining pixels after intra-frame or inter-frame prediction. The transform and quantization block 1004 performs a transform operation to represent the residual signal in the frequency domain. Considering that the human visual system is more sensitive to low-frequency components of video signals than high-frequency components, quantization is designed to further compress the residual signal by reducing the accuracy of high-frequency signals.
[0078] To avoid desynchronization issues between the transcoder 106 and the decoder 112, the transcoder 106 includes a decoding module to ensure that both the transcoder 106 and the decoder 112 use the same mathematical processing. Thus, the inverse transform and inverse quantization block 1008 is similar to the same block on the decoder side. The inverse transform and inverse quantization block 1008 uses intra-frame and inter-frame prediction to reconstruct pixels.
[0079] An in-loop filter 1014 removes any visual artifacts introduced by the above process. Various filtering methods are applied to the reconstructed frame in a cascaded manner to reduce different artifacts, including but not limited to blocking artifacts, mosquito artifacts, color banding effects, etc.
[0080] The entropy coding module 1006 may further compress the bitstream using a model-based approach. The transcoder 106 sends the resulting encoded bitstream to the decoder 112 via a network or other type of medium.
[0081] Fig.11 An example of a decoding system according to some embodiments is depicted. The decoder 112 receives the encoded bitstream and inputs it into the entropy decoding block 1102 to recover the information required for the decoding process. As described above, the decoded frame can be decoded by using the inverse transform and inverse quantization block 1104, the intra-frame prediction block 1106 or the inter-frame prediction block 1108, the motion compensation block 1110 and the in-loop filtering block 1112 in the same manner as constructing the decoded frame.
[0082] Some embodiments may be implemented in a non-transitory computer-readable storage medium for use with or in conjunction with an instruction execution system, device, system, or machine. The computer-readable storage medium contains instructions for controlling a computer system to perform the methods described in some embodiments. The computer system may include one or more computing devices. When executed by one or more computer processors, the instructions may be configured or operable to perform the operations described in some embodiments.
[0083] As used in the description herein and throughout the appended claims, "a", "an", and "the" include plural references unless the context clearly dictates otherwise. Also, as used in the description herein and throughout the appended claims, the meaning of "in" includes "in" and "on", unless the context clearly dictates otherwise.
[0084] The above description illustrates various embodiments and examples of how aspects of some embodiments may be implemented. The above examples and embodiments should not be considered to be the only embodiments, and are presented to illustrate the flexibility and advantages of some embodiments as defined by the appended claims. Based on the above disclosure and the appended claims, other arrangements, embodiments, implementations and equivalents may be adopted without departing from the scope of the invention as defined by the claims.
Claims
1. A method comprising: maintaining, by a computing device, a first list storing motion vectors from one or more blocks previously processed in a frame; When the current block is located at the first set of positions in the frame: resetting the first list by the computing device; and Due to the resetting of the first list, the computing device transcodes the current block using a motion vector from a second list; and When the current block is not in the first set of positions, the current block is transcoded by the computing device using a motion vector from a first list.
2. The method according to claim 1, wherein: The first set of positions in the frame includes N blocks starting from an edge of the frame.
3. The method according to claim 1, wherein: The first set of positions in the frame includes a first block on an edge of the frame.
4. The method according to claim 1, wherein: The first set of positions in the frame includes the leftmost block starting from the left edge of the frame or the highest block starting from the top edge of the frame.
5. The method according to claim 1, wherein: The second list includes motion vectors from blocks neighboring the current block on an edge of the current block.
6. The method according to claim 1, wherein: Using the motion vector from the second list includes: The motion vectors are loaded into the first list.
7. The method according to claim 1, wherein: The current block is transcoded using the motion vectors in the second list only when the current block is located at the first set of positions.
8. The method according to claim 1, wherein: Resetting the first list includes: Existing motion vectors in the first list are removed.
9. The method according to claim 1, wherein: The first list stores historical motion vector prediction values from blocks that were sequentially transcoded before the current block.
10. The method according to claim 1, wherein: When transcoding blocks outside the first set of blocks, the second list is not used.
11. The method according to claim 1, further comprising: When the current block is located at a first set of positions in the frame, a motion vector of the transcoded current block is stored in the second list.
12. The method according to claim 1, further comprising: When the current block is not in the first set of locations in the frame, the transcoded motion vector of the current block is stored in the first list instead of the second list.
13. The method according to claim 1, wherein: The second list includes only motion vectors from blocks in the first set of positions.
14. The method according to claim 1, further comprising: A motion vector that is not based on transcoding the current block is added to the second list.
15. The method according to claim 14, wherein: The motion vectors added to the second list include motion vectors having a horizontal motion vector or a vertical motion vector equal to zero.
16. The method according to claim 14, wherein: The motion vectors added to the second list include predefined motion vectors.
17. A non-transitory computer-readable storage medium having computer-executable instructions stored thereon, which when executed by a computing device, cause the computing device to: maintaining a first list storing motion vectors from one or more blocks previously processed in a frame; When the current block is located at the first set of positions in the frame: Resetting the first list; and Due to the resetting of the first list, transcoding the current block using the motion vector from the second list; and When the current block is not in the first set of positions, the current block is transcoded using a motion vector from a first list.
18. The non-transitory computer-readable storage medium of claim 17, wherein: Resetting the first list includes: Existing motion vectors in the first list are removed.
19. The non-transitory computer-readable storage medium of claim 17, further operable to: A motion vector that is not based on transcoding the current block is added to the second list.
20. An apparatus comprising: one or more computer processors; and A computer readable storage medium comprising instructions for controlling the one or more computer processors to be operable to: maintaining a first list storing motion vectors from one or more blocks previously processed in a frame; When the current block is located at the first set of positions in the frame: Resetting the first list; and Due to the resetting of the first list, transcoding the current block using the motion vector from the second list; and When the current block is not in the first set of positions, the current block is transcoded using a motion vector from a first list.