Video encoding and decoding method, device and storage medium
By introducing adaptive block vector resolution and precise calculation rounding methods into video coding technology, the problem of low coding efficiency caused by the diversity of intra-frame prediction directions is solved and the overall performance of video compression is improved.
Patent Information
- Application Number
- CN202210285558.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2018-11-07
- Filing Date
- 2019-03-06
- Publication Date
- 2024-08-23
- Estimated Expiration
- 2039-03-06
AI Technical Summary
Existing video coding technology cannot effectively utilize the diversity of intra-frame prediction directions when compressing video signals, resulting in low coding efficiency. Especially for unlikely prediction directions, the number of coding bits increases, which affects the video compression effect.
By introducing adaptive block vector resolution in the intra-frame block copy mode, the appropriate resolution is selected according to the size of the block vector prediction value, the coding efficiency of the block vector difference is improved, and the accurate calculation and rounding of the block vector is realized in the processing circuit. input to optimize the reconstruction of intra-frame blocks.
It improves the coding efficiency of video encoding, reduces the bit requirements for unlikely prediction directions, reduces the storage and transmission bandwidth of video data, and improves the overall performance of video compression.
Smart Images

Figure CN114666581B_ABST
Abstract
Description
[0001] This application is a divisional application of the Chinese patent application submitted to the China Patent Office on November 6, 2019, with application number 201980002280.0 and invention name “Video Coding Method and Device”.
[0002] Incorporated herein by reference
[0003] The present disclosure claims priority to U.S. Provisional Application No. 62 / 639,862, filed on March 7, 2018, entitled “Methods for Adaptive Motion and Block Vector Resolution in Image and Video Compression,” and U.S. Patent Application No. 16 / 182,788, filed on November 7, 2018, entitled “Methods and Apparatus for Video Coding,” the entire contents of which are incorporated herein by reference. Technical Field
[0004] The present disclosure relates to video coding and decoding technology, and in particular to a method and device for video coding and decoding. Background Art
[0005] The background description provided herein is intended to present the background of the present disclosure as a whole. The extent to which the work of the presently named inventors described in the background section and various aspects of this specification is performed does not indicate that it is prior art at the time of filing this disclosure, and it is never explicitly or implicitly admitted that it is prior art to the present disclosure.
[0006] Video encoding and decoding are made possible by inter-picture prediction techniques with motion compensation. An uncompressed digital video may include a series of pictures, each picture having a spatial dimension of, for example, 1920×1080 luminance samples and associated chrominance samples. The series of pictures has a fixed or variable picture rate (also informally referred to as a frame rate), for example, 60 pictures per second or 60Hz. Uncompressed video has very large bitrate requirements. For example, 1080p60 4:2:0 video (1920x1080 luminance sample resolution, 60Hz frame rate) with 8 bits per sample requires close to 1.5Gbit / s bandwidth. One hour of such video requires more than 600GB of storage space.
[0007] One goal of video encoding and decoding is to reduce redundant information in the input video signal through compression. Video compression can help reduce the bandwidth or storage space requirements mentioned above, in some cases by two or more orders of magnitude. Both lossless and lossy compression, as well as combinations of the two, can be used. Lossless compression refers to techniques that reconstruct an exact replica of the original signal from the compressed original signal. When lossy compression is used, the reconstructed signal may not be exactly the same as the original signal, but the distortion between the original and the reconstructed signal is small enough that the reconstructed signal can be used for the intended application. Lossy compression is widely used in video. The amount of distortion allowed depends on the application. For example, users of some consumer streaming applications may tolerate higher distortion than users of television applications. The achievable compression ratio reflects that higher allowed / tolerable distortion results in higher compression ratios.
[0008] Video encoders and decoders may utilize several broad categories of techniques including, for example: motion compensation, transforms, quantization, and entropy coding.
[0009] Video codec techniques may include known intra-frame coding techniques. In intra-frame coding, sample values are represented without reference to samples or other data of previously reconstructed reference pictures. In some video codecs, pictures are spatially subdivided into sample blocks. When all sample blocks are encoded in intra-frame mode, the picture can be an intra-frame picture. Intra-frame pictures and their derivatives (such as independent decoder refresh pictures) can be used to reset decoder states, and can therefore be used as the first picture in a coded video bitstream and video session, or as a still image. Samples of intra-frame blocks can be used for transformation, and transform coefficients can be quantized before entropy coding. Intra-frame prediction can be a technique to minimize sample values in the pre-transform domain. In some cases, the smaller the DC value after transformation and the smaller the AC coefficient, the fewer bits are needed to represent the block after entropy coding at a given quantization step size.
[0010] Conventional intra-frame coding, as known from coding techniques such as MPEG-2, does not use intra-frame prediction. However, some newer video compression techniques include techniques that attempt to derive data blocks from, for example, surrounding sample data and / or metadata that are obtained during encoding / decoding of spatially neighboring blocks and before the decoding order. Such techniques have subsequently been referred to as "intra-frame prediction" techniques. It should be noted that, at least in some cases, intra-frame prediction uses only reference data of the current picture being reconstructed, and not reference data of reference pictures.
[0011] There can be many different forms of intra-frame prediction. When more than one such technique can be used in a given video coding technique, the techniques used can be encoded as intra-frame prediction modes. In some cases, a mode can have sub-modes and / or parameters, and these modes can be encoded separately or contained in a mode codeword. Which codeword is used for a given mode / sub-mode / parameter combination affects the coding efficiency gain through intra-frame prediction, and therefore the entropy coding technique used to convert the codeword into a bitstream.
[0012] H.264 introduced an intra prediction mode, which was improved in H.265 and further improved in newer coding techniques such as the Joint Exploitation Mode (JEM), Versatile Video Coding (VVC), Benchmark Sets (BMS), etc. A prediction block can be formed by using neighboring sample values belonging to samples that are already available. The sample values of neighboring samples are copied into the prediction block in a certain direction. A reference to the direction used can be encoded in the bitstream or can itself be predicted.
[0013] Reference Figure 1 , the lower right depicts a set of nine known prediction directions from the 35 possible prediction directions from H.265. The point (101) where the arrows converge represents the sample being predicted. The arrows represent the direction in which the sample is being predicted. For example, arrow (102) indicates that sample (101) is predicted based on one or more samples at a 45 degree angle to the horizontal direction at the upper right. Similarly, arrow (103) indicates that sample (101) is predicted based on one or more samples at a 22.5 degree angle to the horizontal direction at the lower left.
[0014] Still reference Figure 1 , a square block (104) consisting of 4×4 samples is shown in the upper left (indicated by the thick dashed line). The square block (104) consists of 16 samples, each of which is labeled with "S" and its position in the Y dimension (e.g., row index) and its position in the X dimension (e.g., column index). For example, sample S21 is the second sample in the Y dimension (starting from the top) and the first sample in the X dimension (starting from the left). Similarly, sample S44 is the fourth sample in the block (104) in both the Y dimension and the X dimension. Since the block is a 4×4 size sample, S44 is located in the lower right corner. Reference samples following a similar numbering scheme are also shown. Reference samples are labeled with "R" and their Y position (e.g., row index) and X position (e.g., column index) relative to the block (104). In H.264 and H.265, the prediction samples are adjacent to the block being reconstructed, so there is no need to use negative values.
[0015] Intra-picture prediction can be performed by copying reference sample values from neighboring samples occupied by the signaled prediction direction. For example, assume that the encoded video bitstream includes signaling that, for this block, indicates a prediction direction consistent with arrow (102), that is, the sample is predicted based on one or more prediction samples at a 45 degree angle to the horizontal direction to the upper right. In this case, samples S41, S32, S23, and S14 are predicted based on the same sample R05. Then, sample S44 is predicted based on sample R08.
[0016] In some cases, for example by interpolation, the values of multiple reference samples may be combined in order to calculate the reference sample, particularly when the direction is not divisible by 45 degrees.
[0017] As video coding techniques have evolved, the number of possible directions has increased. In H.264 (2003), nine different directions could be represented. This increased to 33 in H.265 (2013) and JEM / VVC / BMS, and at the time of this disclosure, up to 65 directions can be supported. Experiments have been conducted to identify the most likely directions, and certain techniques in entropy coding are used to represent those possible directions using a small number of bits, accepting some penalty for less likely directions. In addition, the direction itself can sometimes be predicted based on neighboring directions used in adjacent, already decoded blocks.
[0018] Figure 2 is a schematic diagram (201) depicting 65 intra prediction directions according to JEM to illustrate the increase in the number of prediction directions over time.
[0019] The mapping of the bit representing the direction from the intra-frame prediction direction to the coded video bit stream can be different because of the difference of video coding technology, and, for example, can be from the simple direct mapping of the prediction direction of the intra-frame prediction mode to the codeword, to the complicated adaptive scheme including the most likely mode and similar technology.Those skilled in the art are easily familiar with those technologies.However, in all cases, there may be certain directions in the video content, which are less likely to occur than other directions statistically.Because the purpose of video compression is to reduce redundancy, in the video coding technology that runs well, those unlikely directions will use more number of bits to represent compared with more likely directions. Summary of the invention
[0020] Aspects of the present disclosure provide methods and devices for video encoding and decoding. In some embodiments, a device includes a processing circuit for video decoding. The processing circuit decodes prediction information of a current block from a coded video bitstream, the prediction information indicating an intra-frame block copy mode. The processing circuit determines a block vector prediction value of the current block based on the prediction information; determines a block vector difference of the current block based on the prediction information; when it is determined that the first size of the first component of the block vector prediction value is greater than a threshold, selects a first candidate resolution as the first resolution of the first component of the block vector difference; when it is determined that the first size of the first component of the block vector prediction value is not greater than the threshold, selects a second candidate resolution as the first resolution of the first component of the block vector difference, the second candidate resolution is a resolution with higher accuracy than the first candidate resolution; determines a block vector of the current block according to the block vector prediction value, the block vector difference and the first resolution of the first component of the block vector difference. Then, the processing circuit reconstructs at least one sample of the current block according to the block vector.
[0021] In some embodiments, when it is determined that the second size of the second component of the block vector prediction value is greater than the threshold, the first candidate resolution is selected as the second resolution of the second component of the block vector difference; and when it is determined that the second size of the second component of the block vector prediction value is not greater than the threshold, the second candidate resolution is selected as the second resolution of the second component of the block vector difference.
[0022] In some embodiments, the first candidate resolution is 1 pixel resolution and the second candidate resolution is 1 / 4 pixel resolution.
[0023] In some embodiments, the first candidate resolution is a 4-pixel resolution and the second candidate resolution is a 1-pixel resolution.
[0024] In some embodiments, the threshold is 5 pixels.
[0025] In one embodiment, when the block vector prediction value uses a resolution different from the first resolution, the processing circuit adds the block vector difference to the block vector prediction value without rounding the block vector prediction value to calculate the block vector. In another embodiment, when the block vector prediction value has a resolution different from the first resolution, the processing circuit rounds the block vector prediction value of the current block to the first resolution and adds the block vector difference to the rounded block vector prediction value to calculate the block vector.
[0026] In some embodiments, the processing circuitry modifies at least one of the block vector difference and the block vector prediction value to constrain the block vector to be within a valid region.
[0027] In some embodiments, a method for video decoding includes: decoding prediction information of a current block from an encoded video bitstream, the prediction information indicating an intra-frame block copy mode; determining a block vector prediction value of the current block based on the prediction information; determining a block vector difference of the current block based on the prediction information; when it is determined that the first size of the first component of the block vector prediction value is greater than a threshold, selecting a first candidate resolution as the first resolution of the first component of the block vector difference; when it is determined that the first size of the first component of the block vector prediction value is not greater than the threshold, selecting a second candidate resolution as the first resolution of the first component of the block vector difference, the second candidate resolution being a resolution with higher accuracy than the first candidate resolution; determining a block vector of the current block based on the block vector prediction value, the block vector difference and the first resolution of the first component of the block vector difference; and reconstructing at least one sample of the current block based on the block vector.
[0028] Aspects of the present disclosure also provide a non-volatile computer-readable storage medium storing instructions, which, when executed by a computer for video decoding, enable the computer to perform the video decoding method. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] Other features, properties and various advantages of the disclosed subject matter will become further apparent from the following detailed description and accompanying drawings, in which:
[0030] Figure 1 is a schematic diagram of a subset of intra prediction modes according to H.265;
[0031] Figure 2 It is a schematic diagram of the intra prediction direction according to JEM;
[0032] Figure 3 is a schematic diagram of a simplified block diagram of a communication system according to an embodiment;
[0033] Figure 4 is a schematic diagram of a simplified block diagram of a communication system according to an embodiment;
[0034] Figure 5 is a schematic illustration of a simplified block diagram of a decoder according to an embodiment;
[0035] Figure 6 is a schematic illustration of a simplified block diagram of an encoder according to an embodiment;
[0036] Figure 7 shows a block diagram of an encoder according to another embodiment;
[0037] Figure 8 shows a block diagram of a decoder according to another embodiment;
[0038] Fig. 9 An example of intra block copying according to an embodiment of the present disclosure is shown.
[0039] Fig.10 A flow chart of an overview process according to an embodiment of the present disclosure is shown.
[0040] Fig.11 is a schematic diagram of a computer system according to an embodiment. DETAILED DESCRIPTION
[0041] Figure 3 3 is a simplified block diagram of a communication system (300) according to an embodiment of the present disclosure. The communication system (300) includes a plurality of terminal devices that can communicate with each other via, for example, a network (350). For example, the communication system (300) includes a first terminal device (310) and a second terminal device (320) interconnected via the network (350). Figure 3 In an embodiment of the present invention, the first terminal device (310) and the second terminal device (320) perform unidirectional data transmission. For example, the first terminal device (310) may encode video data (e.g., a video picture stream collected by the terminal device (310)) for transmission to the second terminal device (320) via the network (350). The encoded video data is transmitted in the form of one or more encoded video code streams. The second terminal device (320) may receive the encoded video data from the network (350), decode the encoded video data to restore the video data, and display the video picture based on the restored video data. Unidirectional data transmission is more common in applications such as media services.
[0042] In another embodiment, the communication system (300) includes a third terminal device (330) and a fourth terminal device (340) that perform bidirectional transmission of encoded video data, which can occur, for example, during a video conference. For bidirectional data transmission, each of the third terminal device (330) and the fourth terminal device (340) can encode video data (e.g., a video picture stream collected by the terminal device) to transmit to the other terminal device of the third terminal device (330) and the fourth terminal device (340) through a network (350). Each of the third terminal device (330) and the fourth terminal device (340) can also receive the encoded video data transmitted by the other terminal device of the third terminal device (330) and the fourth terminal device (340), and can decode the encoded video data to restore the video data, and can display the video picture on an accessible display device based on the restored video data.
[0043] exist Figure 3In an embodiment of the present disclosure, the first terminal device (310), the second terminal device (320), the third terminal device (330) and the fourth terminal device (340) may be servers, personal computers and smart phones, but the principles of the present disclosure may not be limited thereto. Embodiments of the present disclosure are applicable to laptop computers, tablet computers, media players and / or dedicated video conferencing equipment. The network (350) represents any number of networks that transmit encoded video data between the first terminal device (310), the second terminal device (320), the third terminal device (330) and the fourth terminal device (340), including, for example, wired (wired) and / or wireless communication networks. The communication network (350) may exchange data in circuit switching and / or packet switching channels. The network may include a telecommunications network, a local area network, a wide area network and / or the Internet. For the purposes of the present disclosure, unless explained below, the architecture and topology of the network (350) may be irrelevant to the operation of the present disclosure.
[0044] As an example, Figure 4 The placement of the video encoder and video decoder in a streaming environment is shown. The disclosed subject matter is equally applicable to other video-enabled applications including, for example, video conferencing, digital TV, storing compressed video on digital media including CDs, DVDs, memory sticks, etc., and the like.
[0045] The streaming system may include an acquisition subsystem (413), which may include a video source (401) such as a digital camera, which creates an uncompressed video picture stream (402). In an embodiment, the video picture stream (402) includes samples taken by a digital camera. Compared to the encoded video data (404) (or the encoded video bitstream), the video picture stream (402) is depicted as a thick line to emphasize the high data volume of the video picture stream, and the video picture stream (402) can be processed by an electronic device (420), which includes a video encoder (403) coupled to the video source (401). The video encoder (403) may include hardware, software, or a combination of hardware and software to implement or implement various aspects of the disclosed subject matter as described in more detail below. Compared to the video picture stream (402), the encoded video data (404) (or the encoded video bitstream (404)) is depicted as a thin line to emphasize the lower amount of data of the encoded video data (404) (or the encoded video bitstream (404)), which can be stored on the streaming server (405) for future use. One or more streaming client subsystems, such as Figure 4The client subsystem (406) and the client subsystem (408) in the video transmission system can access the streaming server (405) to retrieve the copy (407) and the copy (409) of the encoded video data (404). The client subsystem (406) may include, for example, a video decoder (410) in the electronic device (430). The video decoder (410) decodes the incoming copy (407) of the encoded video data and generates an output video picture stream (411) that can be presented on a display (412) (e.g., a display screen) or another presentation device (not depicted). In some streaming transmission systems, the encoded video data (404), the video data (407), and the video data (409) (e.g., a video bitstream) can be encoded according to certain video encoding / compression standards. Examples of these standards include ITU-T H.265. In an embodiment, the video coding standard under development is informally referred to as Versatile Video Coding (VVC), and the present disclosure can be used in the context of the VVC standard.
[0046] It should be noted that the electronic device (420) and the electronic device (430) may include other components (not shown). For example, the electronic device (420) may include a video decoder (not shown), and the electronic device (430) may also include a video encoder (not shown).
[0047] Figure 5 is a block diagram of a video decoder (510) according to an embodiment of the present disclosure. The video decoder (510) may be provided in an electronic device (530). The electronic device (530) may include a receiver (531) (e.g., a receiving circuit). The video decoder (510) may be used to replace Figure 4 A video decoder (410) of an embodiment.
[0048] The receiver (531) may receive one or more encoded video sequences to be decoded by the video decoder (510); in the same or another embodiment, one encoded video sequence is received at a time, wherein the decoding of each encoded video sequence is independent of the other encoded video sequences. The encoded video sequence may be received from a channel (501), which may be a hardware / software link to a storage device storing the encoded video data. The receiver (531) may receive the encoded video data as well as other data, such as encoded audio data and / or auxiliary data streams that may be forwarded to their respective consuming entities (not shown). The receiver (531) may separate the encoded video sequence from the other data. To prevent network jitter, a buffer memory (515) may be coupled between the receiver (531) and the entropy decoder / parser (520) (hereinafter referred to as "parser (520)"). In some applications, the buffer memory (515) is part of the video decoder (510). In other cases, the buffer memory (515) may be provided external to the video decoder (510) (not shown). In other cases, a buffer memory (not shown) is provided outside the video decoder (510) to prevent network jitter, for example, and another buffer memory (515) may be configured inside the video decoder (510) to handle broadcast timing, for example. When the receiver (531) receives data from a storage / forward device with sufficient bandwidth and controllability or from an isochronous network, it may not be necessary to configure the buffer memory (515), or the buffer memory may be made smaller. Of course, in order to use on a service packet network such as the Internet, a buffer memory (515) may also be required, and the buffer memory may be relatively large and have an adaptive size, and may be at least partially implemented in an operating system or a similar element (not shown) outside the video decoder (510).
[0049] The video decoder (510) may include a parser (520) to reconstruct symbols (521) from the encoded video sequence. The types of symbols include information used to manage the operation of the video decoder (510) and potential information used to control a display device such as a display device (512) (e.g., a display screen) that is not part of the electronic device (530) but can be coupled to the electronic device (530), such as Figure 5As shown in . The control information for the display device may be a parameter set fragment (not indicated) of Supplemental Enhancement Information (SEI message) or Video Usability Information (VUI). The parser (520) may parse / entropy decode the received coded video sequence. The encoding of the coded video sequence may be performed according to a video coding technique or standard, and may follow various principles, including variable length coding, Huffman coding, arithmetic coding with or without context sensitivity, and the like. The parser (520) may extract a subgroup parameter set of at least one subgroup of the subgroups of pixels in the video decoder from the coded video sequence based on at least one parameter corresponding to the group. The subgroup may include a Group of Pictures (GOP), a picture, a tile, a slice, a macroblock, a Coding Unit (CU), a block, a Transform Unit (TU), a Prediction Unit (PU), and the like. The parser (520) may also extract information from the encoded video sequence, such as transform coefficients, quantizer parameter values, motion vectors, and so on.
[0050] The parser (520) may perform entropy decoding / parsing operations on the video sequence received from the buffer memory (515), thereby creating symbols (521).
[0051] Depending on the type of coded video picture or portion of coded video picture (e.g., inter- and intra-pictures, inter- and intra-blocks) and other factors, the reconstruction of the symbol (521) may involve multiple different units. Which units are involved and how they are involved may be controlled by subgroup control information parsed by the parser (520) from the coded video sequence. For the sake of brevity, such subgroup control information flow between the parser (520) and the multiple units below is not described.
[0052] In addition to the functional blocks already mentioned, the video decoder (510) can be conceptually subdivided into several functional units as described below. In a practical embodiment operating under commercial constraints, many of these units interact closely with each other and can be integrated with each other. However, for the purpose of describing the disclosed subject matter, the conceptual subdivision into the following functional units is appropriate.
[0053] The first unit is a sealer / inverse transform unit (551). The sealer / inverse transform unit (551) receives quantized transform coefficients as symbols (521) from the parser (520) and control information, including which transform method to use, block size, quantization factor, quantization scaling matrix, etc. The sealer / inverse transform unit (551) can output a block including sample values, which can be input into an aggregator (555).
[0054] In some cases, the output samples of the scaler / inverse transform unit (551) may belong to an intra-coded block; that is, a block that does not use predictive information from a previously reconstructed picture, but may use predictive information from a previously reconstructed portion of the current picture. Such predictive information may be provided by an intra-picture prediction unit (552). In some cases, the intra-picture prediction unit (552) generates surrounding blocks of the same size and shape as the block being reconstructed using reconstructed information extracted from a current picture buffer (558). For example, the current picture buffer (558) buffers a partially reconstructed current picture and / or a fully reconstructed current picture. In some cases, the aggregator (555) adds the prediction information generated by the intra-prediction unit (552) to the output sample information provided by the scaler / inverse transform unit (551) on a per-sample basis.
[0055] In other cases, the output samples of the scaler / inverse transform unit (551) may belong to an inter-frame coded and potentially motion compensated block. In this case, the motion compensated prediction unit (553) may access the reference picture memory (557) to extract samples for prediction. After the extracted samples are motion compensated according to the symbols (521), these samples may be added to the output of the scaler / inverse transform unit (551) (in this case referred to as residual samples or residual signals) by the aggregator (555) to generate output sample information. The acquisition of the predicted samples by the motion compensated prediction unit (553) from the address in the reference picture memory (557) may be controlled by a motion vector, and the motion vector is provided to the motion compensated prediction unit (553) in the form of the symbols (521), for example, including X, Y and reference picture components. Motion compensation may also include interpolation of sample values extracted from the reference picture memory (557) when using sub-sample accurate motion vectors, motion vector prediction mechanisms, and the like.
[0056] The output samples of the aggregator (555) may be employed by various loop filtering techniques in a loop filter unit (556). The video compression techniques may include in-loop filter techniques controlled by parameters included in the encoded video sequence (also referred to as the encoded video bitstream) and available to the loop filter unit (556) as symbols (521) from the parser (520). However, in other embodiments, the video compression techniques may also be responsive to meta-information obtained during decoding of a previous (in decoding order) portion of an encoded picture or encoded video sequence, as well as to previously reconstructed and loop filtered sample values.
[0057] The output of the loop filter unit (556) may be a sample stream that may be output to a display device (512) and stored in a reference picture memory (557) for subsequent inter-picture prediction.
[0058] Once fully reconstructed, certain coded pictures may be used as reference pictures for future prediction. For example, once the coded picture corresponding to the current picture is fully reconstructed, and the coded picture is identified as a reference picture (e.g., by the parser (520)), the current picture buffer (558) may become part of the reference picture memory (557), and a new current picture buffer may be reallocated before starting to reconstruct a subsequent coded picture.
[0059] The video decoder (510) may perform decoding operations according to a predetermined video compression technique, such as in the ITU-T H.265 standard. The encoded video sequence may conform to the syntax specified by the video compression technique or standard used in the sense that the encoded video sequence follows the syntax of the video compression technique or standard and the profile recorded in the video compression technique or standard. Specifically, the profile may select certain tools from all the tools available in the video compression technique or standard as the only tools available for use under the profile. For compliance, the complexity of the encoded video sequence is also required to be within the range defined by the hierarchy of the video compression technique or standard. In some cases, the hierarchy limits the maximum picture size, the maximum frame rate, the maximum reconstruction sampling rate (measured in, for example, mega samples per second), the maximum reference picture size, etc. In some cases, the limits set by the hierarchy may be further limited by the Hypothetical Reference Decoder (HRD) specification and the metadata of the HRD buffer management signaled in the encoded video sequence.
[0060] In an embodiment, the receiver (531) may receive additional (redundant) data along with the encoded video. The additional data may be part of the encoded video sequence. The additional data may be used by the video decoder (510) to properly decode the data and / or more accurately reconstruct the original video data. The additional data may be in the form of, for example, temporal, spatial or signal-to-noise ratio (SNR) enhancement layers, redundant slices, redundant pictures, forward error correction codes, etc.
[0061] Figure 6 6 is a block diagram of a video encoder (603) according to an embodiment of the present disclosure. The video encoder (603) is disposed in an electronic device (620). The electronic device (620) includes a transmitter (640) (e.g., a transmission circuit). The video encoder (603) can be used to replace Figure 4 A video encoder (403) in an embodiment.
[0062] The video encoder (603) can be used to obtain the video source (601) (not Figure 6 In another embodiment, the video source (601) is a part of the electronic device (620) to receive video samples, and the video source can collect video images to be encoded by the video encoder (603). In another embodiment, the video source (601) is a part of the electronic device (620).
[0063] The video source (601) may provide a source video sequence in the form of a digital video sample stream to be encoded by the video encoder (603), wherein the digital video sample stream may have any suitable bit depth (e.g., 8-bit, 10-bit, 12-bit, ...), any color space (e.g., BT.601 Y CrCB, RGB, ...), and any suitable sampling structure (e.g., Y CrCb 4:2:0, Y CrCb 4:4:4). In a media service system, the video source (601) may be a storage device storing previously prepared videos. In a video conferencing system, the video source (601) may be a camera that captures local image information as a video sequence. The video data may be provided as a plurality of separate pictures that are given motion when viewed sequentially. The pictures themselves may be constructed as a spatial pixel array, wherein each pixel may include one or more samples depending on the sampling structure, color space, etc. used. The relationship between pixels and samples may be easily understood by those skilled in the art. The following description focuses on samples.
[0064] According to an embodiment, the video encoder (603) may encode and compress pictures of a source video sequence into an encoded video sequence (643) in real time or under any other time constraints required by the application. Implementing an appropriate encoding speed is a function of the controller (650). In some embodiments, the controller (650) controls other functional units as described below and is functionally coupled to these units. For the sake of simplicity, coupling is not indicated in the figure. The parameters set by the controller (650) may include rate control related parameters (picture skipping, quantizer, lambda value of rate distortion optimization technology, etc.), picture size, group of pictures (GOP) layout, maximum motion vector search range, etc. The controller (650) can be used to have other suitable functions that are related to the video encoder (603) optimized for a certain system design.
[0065] In some embodiments, the video encoder (603) operates in an encoding loop. As a simple description, in embodiments, the encoding loop may include a source encoder (630) (e.g., responsible for creating symbols, such as a symbol stream, based on an input picture to be encoded and a reference picture) and a (local) decoder (633) embedded in the video encoder (603). The decoder (633) reconstructs the symbols to create sample data in a manner similar to that of the (remote) decoder to create sample data (because in the video compression techniques considered in the present disclosure, any compression between the symbols and the encoded video code stream is lossless). The reconstructed sample stream (sample data) is input to a reference picture memory (634). Since the decoding of the symbol stream produces bit-accurate results that are independent of the decoder location (local or remote), the contents of the reference picture memory (634) are also bit-accurately corresponding between the local encoder and the remote encoder. In other words, the reference picture samples "seen" by the prediction part of the encoder are exactly the same as the sample values that the decoder will "see" when using the prediction during decoding. This basic principle of reference picture synchronization (and the drift that occurs when synchronization cannot be maintained, eg due to channel errors) is also used in some related techniques.
[0066] The operation of the "local" decoder (633) can be combined with the above Figure 5 The "remote" decoder described in detail for the video decoder (510) is identical. However, additional brief reference is made to Figure 5 , when symbols are available and the entropy encoder (645) and parser (520) are capable of losslessly encoding / decoding the symbols into an encoded video sequence, the entropy decoding portion of the video decoder (510), including the buffer memory (515) and the parser (520), may not be fully implemented in the local decoder (633).
[0067] At this point, it can be observed that any decoder technology other than the parsing / entropy decoding present in the decoder must also be present in the corresponding encoder in substantially the same functional form. For this reason, the present disclosure focuses on decoder operation. The description of encoder technology can be simplified because encoder technology is mutually inverse to the decoder technology described comprehensively. A more detailed description is only needed in certain areas and is provided below.
[0068] During operation, in some embodiments, the source encoder (630) may perform motion compensated predictive coding. The motion compensated predictive coding predictively encodes an input picture with reference to one or more previously encoded pictures from a video sequence designated as "reference pictures." In this manner, the encoding engine (632) encodes the differences between pixel blocks of the input picture and pixel blocks of a reference picture that may be selected as a prediction reference for the input picture.
[0069] The local video decoder (633) may decode the encoded video data that may be designated as a reference picture based on the symbol created by the source encoder (630). The operation of the encoding engine (632) may be a lossy process. When the encoded video data is available at the video decoder ( Figure 6 When the video sequence is decoded at a remote location (not shown), the reconstructed video sequence may typically be a copy of the source video sequence with some errors. The local video decoder (633) replicates the decoding process that may be performed by the video decoder on the reference picture and may cause the reconstructed reference picture to be stored in the reference picture cache (634). In this way, the video encoder (603) may store a copy of the reconstructed reference picture locally that has common content (absent transmission errors) with the reconstructed reference picture to be obtained by the remote video decoder.
[0070] The predictor (635) may perform a prediction search for the encoding engine (632). That is, for a new picture to be encoded, the predictor (635) may search the reference picture memory (634) for sample data (as candidate reference pixel blocks) or certain metadata, such as reference picture motion vectors, block shapes, etc., that may serve as appropriate prediction references for the new picture. The predictor (635) may operate pixel-by-pixel based on sample blocks to find a suitable prediction reference. In some cases, based on the search results obtained by the predictor (635), it may be determined that the input picture may have prediction references taken from a plurality of reference pictures stored in the reference picture memory (634).
[0071] The controller (650) may manage encoding operations of the source encoder (630), including, for example, setting parameters and subgroup parameters for encoding video data.
[0072] The outputs of all the above functional units may be entropy encoded in an entropy encoder (645). The entropy encoder (645) performs lossless compression on the symbols generated by the various functional units according to techniques known to those skilled in the art, such as Huffman coding, variable length coding, arithmetic coding, etc., thereby converting the symbols into a coded video sequence.
[0073] The transmitter (640) may buffer the encoded video sequence created by the entropy encoder (645) in preparation for transmission over a communication channel (660), which may be a hardware / software link to a storage device where the encoded video data will be stored. The transmitter (640) may combine the encoded video data from the video encoder (603) with other data to be transmitted, such as encoded audio data and / or ancillary data streams (source not shown).
[0074] The controller (650) may manage the operation of the video encoder (603). During encoding, the controller (650) may assign a certain coded picture type to each coded picture, but this may affect the coding techniques that can be applied to the corresponding picture. For example, a picture may generally be assigned to any of the following picture types:
[0075] An intra picture (I picture) may be a picture that can be encoded and decoded without using any other picture in the sequence as a prediction source. Some video codecs allow different types of intra pictures, including, for example, Independent Decoder Refresh ("IDR") pictures. Those skilled in the art are aware of the variations of I pictures and their corresponding applications and features.
[0076] A predictive picture (P picture) may be a picture that can be encoded and decoded using intra prediction or inter prediction, which uses at most one motion vector and a reference index to predict sample values for each block.
[0077] Bidirectional predictive pictures (B pictures), which can be pictures that can be encoded and decoded using intra prediction or inter prediction, which uses up to two motion vectors and reference indices to predict the sample values of each block. Similarly, multiple predictive pictures can use more than two reference pictures and associated metadata for reconstruction of a single block.
[0078] The source picture may typically be spatially subdivided into blocks of samples (e.g., blocks of 4×4, 8×8, 4×8, or 16×16 samples), and coded block by block. These blocks may be predictively coded with reference to other (already coded) blocks, which are determined according to the coding allocation applied to the block's corresponding picture. For example, blocks of an I picture may be non-predictively coded, or the blocks may be predictively coded (spatial prediction or intra prediction) with reference to already coded blocks of the same picture. Blocks of pixels of a P picture may be predictively coded by spatial prediction with reference to one previously coded reference picture or by temporal prediction. Blocks of a B picture may be predictively coded by spatial prediction with reference to one or two previously coded reference pictures or by temporal prediction.
[0079] The video encoder (603) may perform encoding operations according to a predetermined video encoding technique or standard, such as ITU-T H.265 Recommendation. In operation, the video encoder (603) may perform various compression operations, including predictive encoding operations that exploit temporal and spatial redundancy in an input video sequence. Thus, the encoded video data may conform to the syntax specified by the video encoding technique or standard used.
[0080] In an embodiment, the transmitter (640) may transmit additional data when transmitting the encoded video. The source encoder (630) may include such data as part of the encoded video sequence. The additional data may include other forms of redundant data such as temporal / spatial / SNR enhancement layers, redundant pictures and slices, SEI messages, VUI parameter set fragments, etc.
[0081] The captured video may be taken as a plurality of source pictures (video pictures) in a temporal sequence. Intra-picture prediction (often simplified to intra-prediction) exploits spatial correlations in a given picture, while inter-picture prediction exploits (temporal or other) correlations between pictures. In an embodiment, a particular picture being encoded / decoded is divided into blocks, and the particular picture being encoded / decoded is referred to as the current picture. When a block in the current picture is similar to a reference block in a reference picture that was previously encoded in the video and is still buffered, the block in the current picture may be encoded by a vector called a motion vector. The motion vector points to a reference block in a reference picture, and in the case where multiple reference pictures are used, the motion vector may have a third dimension that identifies the reference picture.
[0082] In some embodiments, bidirectional prediction techniques may be used in inter-picture prediction. According to the bidirectional prediction technique, two reference pictures are used, for example, a first reference picture and a second reference picture that are both before the current picture in the video in decoding order (but may be in the past and future in display order, respectively). A block in the current picture may be encoded by a first motion vector pointing to a first reference block in the first reference picture and a second motion vector pointing to a second reference block in the second reference picture. Specifically, the block may be predicted by a combination of the first reference block and the second reference block.
[0083] In addition, merge mode technology can be used in inter-picture prediction to improve coding efficiency.
[0084] According to some embodiments of the present disclosure, predictions such as inter-picture prediction and intra-picture prediction are performed in blocks. For example, according to the HEVC standard, pictures in a video picture sequence are divided into coding tree units (CTUs) for compression, and the CTUs in the pictures have the same size, such as 64×64 pixels, 32×32 pixels, or 16×16 pixels. In general, a CTU includes three coding tree blocks (CTBs), which are a luminance CTB and two chrominance CTBs. Furthermore, each CTU can be split into one or more coding units (CUs) using a quadtree. For example, a 64×64 pixel CTU can be split into a 64×64 pixel CU, or 4 32×32 pixel CUs, or 16 16×16 pixel CUs. In an embodiment, each CU is analyzed to determine the prediction type for the CU, such as an inter-prediction type or an intra-prediction type. In addition, depending on temporal and / or spatial predictability, the CU is split into one or more prediction units (PUs). Typically, each PU includes a luma prediction block (PB) and two chroma PBs. In an embodiment, the prediction operation in encoding (encoding / decoding) is performed in units of prediction blocks. Taking the luma prediction block as an example of a prediction block, the prediction block includes a matrix of pixel values (e.g., luma values), such as 8×8 pixels, 16×16 pixels, 8×16 pixels, 16×8 pixels, and the like.
[0085] Figure 7 is a diagram of a video encoder (703) according to another embodiment of the present disclosure. The video encoder (703) is configured to receive a processed block (e.g., a prediction block) of sample values within a current video picture in a video picture sequence and encode the processed block into an encoded picture that is part of an encoded video sequence. In this embodiment, the video encoder (703) is configured to replace Figure 4 A video encoder (403) in an embodiment.
[0086] In an HEVC embodiment, a video encoder (703) receives a matrix of sample values for a processing block, such as a prediction block of 8×8 samples. The video encoder (703) uses, for example, rate-distortion (RD) optimization to determine whether to use intra mode, inter mode, or bidirectional prediction mode to encode the processing block. When encoding the processing block in intra mode, the video encoder (703) may use intra prediction techniques to encode the processing block into an encoded picture; and when encoding the processing block in inter mode or bidirectional prediction mode, the video encoder (703) may use inter prediction or bidirectional prediction techniques to encode the processing block into an encoded picture, respectively. In some video encoding techniques, the merge mode may be an inter-picture prediction submode, in which a motion vector is derived from one or more motion vector predictors without the aid of an encoded motion vector component external to the predictor. In some other video encoding techniques, there may be a motion vector component applicable to the subject block. In an embodiment, the video encoder (703) includes other components, such as a mode decision module (not shown) for determining the processing block mode.
[0087] exist Figure 7 In an embodiment of the present invention, the video encoder (703) includes: Figure 7 Shown are an inter-frame encoder (730), an intra-frame encoder (722), a residual calculator (723), a switch (726), a residual encoder (724), a general controller (721), and an entropy encoder (725) coupled together.
[0088] The inter-frame encoder (730) is used to receive samples of a current block (e.g., a processing block), compare the block with one or more reference blocks in a reference picture (e.g., blocks in a previous picture and a subsequent picture), generate inter-frame prediction information (e.g., redundant information description according to an inter-frame coding technique, motion vectors, merge mode information), and calculate an inter-frame prediction result (e.g., a predicted block) based on the inter-frame prediction information using any suitable technique. In some embodiments, the reference picture is a decoded reference picture decoded based on the encoded video information.
[0089] The intra encoder (722) is used to receive samples of a current block (e.g., a processing block), compare the block with an encoded block in the same picture in some cases, generate quantization coefficients after transformation, and in some cases also generate intra prediction information (e.g., intra prediction direction information according to one or more intra coding techniques). In some embodiments, the intra encoder (722) also calculates an intra prediction result (e.g., a prediction block) based on the intra prediction information and a reference block in the same picture.
[0090] The general controller (721) is used to determine the general control data and control other components of the video encoder (703) based on the general control data. In an embodiment, the general controller (721) determines the mode of the block and provides a control signal to the switch (726) based on the mode. For example, when the mode is intra mode, the general controller (721) controls the switch (726) to select the intra mode result for use by the residual calculator (723) and controls the entropy encoder (725) to select intra prediction information and add the intra prediction information to the bitstream; and when the mode is inter mode, the general controller (721) controls the switch (726) to select the inter prediction result for use by the residual calculator (723) and controls the entropy encoder (725) to select the inter prediction information and add the inter prediction information to the bitstream.
[0091] The residual calculator (723) is used to calculate the difference (residual data) between the received block and the prediction result selected from the intra-frame encoder (722) or the inter-frame encoder (730). The residual encoder (724) is used to operate based on the residual data to encode the residual data to generate a transform coefficient. In an embodiment, the residual encoder (724) is used to convert the residual data in the frequency domain and generate a transform coefficient. The transform coefficient is then quantized to obtain a quantized transform coefficient. In various embodiments, the video encoder (703) also includes a residual decoder (728). The residual decoder (728) is configured to perform an inverse transform and generate decoded residual data. The decoded residual data can be used appropriately by the intra-frame encoder (722) and the inter-frame encoder (730). For example, the inter-frame encoder (730) can generate a decoded block based on the decoded residual data and the inter-frame prediction information, and the intra-frame encoder (722) can generate a decoded block based on the decoded residual data and the intra-frame prediction information. The decoded blocks are processed appropriately to generate a decoded picture, and the decoded picture may be cached in a memory circuit (not shown) and used as a reference picture in some examples.
[0092] The entropy encoder (725) is used to format the code stream to produce an encoded block. The entropy encoder (725) generates various information according to a suitable standard such as the HEVC standard. In an embodiment, the entropy encoder (725) is used to obtain general control data, selected prediction information (such as intra-frame prediction information or inter-frame prediction information), residual information, and other suitable information in the code stream. It should be noted that according to the disclosed subject matter, when the block is encoded in the inter-frame mode or the merge sub-mode of the bidirectional prediction mode, there is no residual information.
[0093] Figure 8FIG. 8 is a diagram of a video decoder (810) according to another embodiment of the present disclosure. The video decoder (810) is configured to receive an encoded image as part of an encoded video sequence and decode the encoded image to generate a reconstructed picture. In an embodiment, the video decoder (810) is configured to replace Figure 4 A video decoder (410) of an embodiment.
[0094] exist Figure 8 In one embodiment, the video decoder (810) includes: Figure 8 An entropy decoder (871), an inter-frame decoder (880), a residual decoder (873), a reconstruction module (874) and an intra-frame decoder (872) coupled together are shown in FIG.
[0095] The entropy decoder (871) may be used to reconstruct certain symbols from the encoded picture, which represent syntax elements constituting the encoded picture. Such symbols may include, for example, a mode for encoding the block (e.g., intra mode, inter mode, bidirectional prediction mode, a merged sub-mode of the latter two, or another sub-mode), prediction information (e.g., intra prediction information or inter prediction information) that may identify certain samples or metadata for prediction by the intra decoder (872) or the inter decoder (880), respectively, residual information in the form of, for example, quantized transform coefficients, and the like. In an embodiment, when the prediction mode is inter or bidirectional prediction mode, the inter prediction information is provided to the inter decoder (880); and when the prediction type is an intra prediction type, the intra prediction information is provided to the intra decoder (872). The residual information may be inverse quantized and provided to the residual decoder (873).
[0096] The inter-frame decoder (880) is used to receive the inter-frame prediction information and generate an inter-frame prediction result based on the inter-frame prediction information.
[0097] The intra-frame decoder (872) is used to receive intra-frame prediction information and generate a prediction result based on the intra-frame prediction information.
[0098] The residual decoder (873) is used to perform inverse quantization to extract dequantized transform coefficients, and process the dequantized transform coefficients to convert the residual from the frequency domain to the spatial domain. The residual decoder (873) may also require some control information (to obtain the quantizer parameter QP), and this information can be provided by the entropy decoder (871) (the data path is not indicated because this is only low-volume control information).
[0099] The reconstruction module (874) is used to combine the residual output by the residual decoder (873) with the prediction result that can be output by the inter-frame prediction module or the intra-frame prediction module in the spatial domain to form a reconstructed block, which can be part of a reconstructed picture, which in turn can be part of a reconstructed video. It should be noted that other suitable operations such as deblocking operations can be performed to improve visual quality.
[0100] It should be noted that the video encoder (403), video encoder (603) and video encoder (703) and video decoder (410), video decoder (510) and video decoder (810) may be implemented using any suitable technology. In an embodiment, the video encoder (403), video encoder (603) and video encoder (703) and video decoder (410), video decoder (510) and video decoder (810) may be implemented using one or more integrated circuits. In another embodiment, the video encoder (403), video encoder (603) and video encoder (703) and video decoder (410), video decoder (510) and video decoder (810) may be implemented using one or more processors that execute software instructions.
[0101] Aspects of the present disclosure provide techniques for intra picture block compensation.
[0102] Block-based compensation from different pictures is called motion compensation. Similarly, block compensation can also be performed from previously reconstructed areas within the same picture. Block-based compensation from reconstructed areas within the same picture is called intra-picture block compensation or intra-block copying. The displacement vector indicating the offset between the current block and the reference block in the same picture is called a block vector (or BV for short). Unlike the motion vector in motion compensation, which can be any value (positive or negative, in the x or y direction), the block vector has some constraints to ensure that the reference block is available and has been reconstructed. Moreover, in some examples, some reference areas that are tile boundaries or wavefront trapezoid boundaries are excluded for parallel processing considerations.
[0103] The encoding of block vectors can be explicit or implicit. In explicit mode, the difference between the block vector and its prediction value is signaled; in implicit mode, the block vector is recovered from the prediction value (called the block vector prediction value) in a similar way to motion vectors in merge mode. In some embodiments, the resolution of block vectors is restricted to integer positions; in other systems, block vectors are allowed to point to fractional positions.
[0104] In some embodiments, a reference index method may be used to signal the use of intra block copying at the block level. The current picture being decoded is then considered a reference picture. In one example, such a reference picture is placed at the last position of the reference picture list. This special reference picture is also managed with other temporal reference pictures in a buffer, such as a decoded picture buffer (DPB).
[0105] There are also some variations of intra block copying, such as flipped intra block copying (the reference block is flipped horizontally or vertically before being used to predict the current block), or row-based intra block copying (each compensation unit within an M×N coding block is an M×1 or 1×N row).
[0106] Fig. 9 An example of intra-block copying according to an embodiment of the present application is shown. A current picture 900 is being decoded. The current picture 900 includes a reconstructed area 910 (gray area) and an area to be decoded 920 (white area). A current block 930 is being reconstructed in a decoder. The current block 930 can be reconstructed based on a reference block 940 in the reconstructed area 910. The position offset between the reference block 940 and the current block 930 is referred to as a block vector 950 (or BV 950).
[0107] Traditionally, the motion vector resolution is a fixed value, for example, 1 / 4 pixel accuracy in H.264 / AVC and HEVC Main Profile, or 1 / 8 pixel accuracy, etc. In HEVC SCC, the resolution of the motion vector can be selected to be 1 integer pixel or 1 / 4 pixel. The switching occurs on each slice. In other words, the resolution of all motion vectors in a slice will be the same.
[0108] In some later developments, the resolution of motion vectors can be 1 / 4 pixel, 1 integer pixel, or 4 integer pixels. In the example of 4 integer pixels, each cell represents 4 integer pixels. Therefore, there are 4 integer pixel distances between the symbols "0" and "1". In addition, adaptability occurs at the block level - the motion vector can choose different resolutions block by block.
[0109] Aspects of the present disclosure provide methods for adaptive motion vector resolution and block vector resolution in image and video compression.
[0110] Block vectors are usually signaled at integer resolutions. Therefore, when intra block copying is extended to the full frame range, all reconstructed areas of the current decoded picture can be used as references, but encoding block vector differences for distant references will be expensive. Adaptive block vector difference resolution can be used to improve the encoding of block vector differences.
[0111] In some embodiments, multiple block vector resolutions are used for encoding of block vectors, and the block vector resolutions can be switched at the block level. In addition, when more than two possible resolutions are used, a signaling flag that may include more than 1-bin (binary bit) is used to tell which of the multiple block vector resolutions is used for the block vector difference of the current block. Possible resolutions include, but are not limited to, 1 / 8 pixel, 1 / 4 pixel, 1 / 2 pixel, 1 integer pixel, 2 integer pixels, 4 integer pixels, 8 integer pixels, etc. X integer pixels represent that each minimum unit of a symbol represents X integer positions. For example, 2 integer pixels represent that each minimum unit of a symbol represents 2 integer positions, 4 integer pixels represent that each minimum unit of a symbol represents 4 integer positions, and 8 integer pixels represent that each minimum unit of a symbol represents 8 integer positions.
[0112] In one embodiment, a set of resolutions may be used, and a flag may be signaled to indicate which of the set of resolutions to use. In one example, the block vector difference resolution set includes two resolutions, such as 1 integer pixel and 2 integer pixels. Then, a 1-bin (1 binary) flag is signaled to select one of the two possible resolutions. In another example, the block vector resolution set includes 1 integer pixel and 4 integer pixels. Then, a 1-bin flag is signaled to select one of the two possible resolutions.
[0113] In another example, the block vector difference resolution set includes 1 integer pixel, 2 integer pixels, and 4 integer pixels. A 1-bin flag is signaled to indicate whether 1 integer pixel resolution is used. If 1 integer pixel is not used, another 1-bin flag is signaled to indicate whether 4 integer pixel resolution is selected. Different binarization embodiments can be derived in a similar manner to use 1-bin or 2-bin to indicate resolution selection from 3 possible resolutions.
[0114] In another example, the block vector difference resolution set includes 1 integer pixel, 4 integer pixels, and 8 integer pixels. A 1-bin flag is signaled to indicate whether 1 integer pixel resolution is used. If 1 integer pixel is not used, another 1-bin flag is signaled to indicate whether 4 integer pixel resolution is selected. Different binarization embodiments can be derived in a similar manner to use 1-bin or 2-bin to indicate resolution selection from 3 possible resolutions.
[0115] In another embodiment, the x and y components of the block vector difference may use different resolutions. For example, the x component of the block vector difference is at 1 integer pixel resolution, while the y component is at 4 integer pixel resolution. The resolution for each component may be selected by explicit signaling (1 flag per component) or by inference. For example, the size of the block vector prediction value of the current block may be used to infer the resolution. In one example, when the size of a component of the block vector prediction value is greater than a threshold, the block vector difference resolution of that component will use a larger step resolution, such as 4 integer pixel resolution; otherwise, the component will use a smaller step resolution, such as 1 integer pixel resolution.
[0116] In another embodiment, the x and y components of the block vector difference may use different resolutions. By default, the two components will use a fixed resolution, such as 1 integer pixel resolution. Component conditions are set for each component to determine the resolution. For example, when certain component conditions are met, each component can be switched to a different resolution by inference. The components of the prediction value will also be quantized to the corresponding resolution, or simply keep their original resolution unchanged. For example, a component condition is related to the size of the block vector prediction value of the current block. By evaluating the size of each component in the block vector prediction value of the current block, the resolution of the component can be inferred. For example, when the size of the component of the block vector prediction value is greater than a threshold, the block vector difference resolution of the component will use a larger step resolution, such as 4 integer pixel resolution; otherwise, the component will use a default step resolution, such as 1 integer pixel resolution. In a specific example, the default resolution is 1 integer pixel. The block vector prediction value is set to (-21, -3), and for each component, the threshold of using 4 integer pixel resolution is 20. The decoded block vector difference symbol is (2, 2). According to the rule, the x component will use 4 integer pixel resolution, and the y component will use 1 integer pixel resolution. Then, the prediction value will become (-20, -3) (-21 is rounded to -20), and the block vector difference will become (8, 2) (due to 4 integer pixels for the x component and 1 integer pixel for the y component). In this example, the final decoded block vector is (-12, -1).
[0117] Similar derivations in the above embodiments may be used to derive similar embodiments. In one embodiment, a set of possible resolutions is formed and one or more signaling flags are used to indicate the selection of resolutions on a block-by-block basis. Also in the above embodiments, the bins of the signaling flag may be context coded or bypass coded. If context coding is used, the block vector resolutions of the spatially neighboring blocks of the current block may be used for context modeling. Alternatively, the resolution of the last coded block vector may be used.
[0118] According to another aspect of the present disclosure, a block vector predictor is typically derived from a previously encoded block vector of a neighboring block to a current block. When used as a predictor, the previously decoded block vector may have a different resolution than that in the current block. The present disclosure provides a method for solving this problem.
[0119] In one embodiment, the original resolution of the block vector predictor remains unchanged. The decoded block vector difference, at its target resolution, will be added to the block vector predictor to obtain the final decoded block vector. Therefore, the final decoded block vector will have the higher resolution of the two resolutions (the original resolution of the block vector predictor and the target resolution of the decoded block vector difference). For example, the block vector predictor is a vector (-11, 0) with a resolution of 1 integer pixel. The decoded block vector difference is a vector (-4, 0) with a resolution of 4 integer pixels. The decoded block vector will be a vector (-15, 0) with a resolution of 1 integer pixel.
[0120] In another embodiment, the original resolution of the block vector prediction value is rounded to the target resolution of the current block. The decoded block vector difference, at its target resolution, will be added to the block vector prediction value. Therefore, the final decoded block vector will have the lower precision resolution of the two resolutions. For example, the block vector prediction value is a vector (-11, 0) with a resolution of 1 integer pixel. The decoded block vector difference is a vector (-4, 0) with a resolution of 4 integer pixels. Before being added to the decoded block vector difference, the block vector prediction value will first be rounded to a vector (-12, 0) with a resolution of 4 integer pixels. The decoded block vector will be a vector (-16, 0) with a resolution of 4 integer pixels.
[0121] Different rounding techniques may be used. In one example, the vector may be rounded to the nearest integer (corresponding to an integer sign value) based on the difference value. For example, (-11, 0) with 1 integer pixel resolution is rounded to (-12, 0) with 4 integer pixel resolution, and (-13, 0) with 1 integer pixel resolution is also rounded to (-12, 0) with 4 integer pixel resolution.
[0122] In another example, a round-up operation is applied to the vector to round to the nearest integer (corresponding to an integer sign value) that is not less than the current value. For example, (-11, 0) with 1 integer pixel resolution is rounded to (-8, 0) with 4 integer pixel resolution, and (-13, 0) with 1 integer pixel resolution is also rounded to (-12, 0) with 4 integer pixel resolution.
[0123] In another example, a floor operation is applied to the vector to round to the nearest integer (corresponding to an integer sign value) that is not greater than the current value. For example, (-11, 0) with 1 integer pixel resolution is rounded to (-12, 0) with 4 integer pixel resolution, and (-13, 0) with 1 integer pixel resolution is also rounded to (-16, 0) with 4 integer pixel resolution.
[0124] In another example, the vector is rounded towards zero. For example, (-11, 0) with 1 integer pixel resolution is rounded to (-8, 0) with 4 integer pixel resolution, and (11, -5) with 1 integer pixel resolution is rounded to (8, -4) with 4 integer pixel resolution.
[0125] Aspects of the present disclosure also provide techniques for handling boundary constraints with multiple resolutions. In one example, a block vector is constrained to point to a reference region that allows the use of intra-picture block compensation. The constraints may include picture / strip / tile and wavefront boundaries of the allowed reference region. When using multiple resolutions, particularly when using resolutions greater than 1 integer pixel, boundary constraints should be handled correctly.
[0126] In one embodiment, when the block vector (block vector prediction value + difference value) points to a position outside the reference area boundary, a modification operation is performed to modify one or two components of the block vector back to the edge of the boundary so that the modified block vector is valid. The modification operation can be performed without considering the resolution of the decoded block vector. Therefore, after the modification, the resolution of the block vector can be different from the resolution before the modification.
[0127] In another embodiment, when the block vector (block vector prediction value + difference value) points to a position outside the reference area boundary, a modification operation is performed to modify one or two components of the block vector back to the edge of the boundary so that the modified block vector is valid. The modification operation can be performed taking into account the resolution of the decoded block vector. Therefore, after the modification, the resolution of the block vector remains the same as before the modification.
[0128] In another embodiment, when the block vector (block vector prediction value+difference value) points to a position outside the boundary of the reference area, the pixels outside the boundary may be represented by horizontally or vertically extending the pixels at the boundary.
[0129] In another embodiment, when the block vector (block vector prediction value + difference value) points to a location outside the reference area boundary, the resolution of the block vector difference will be changed to the highest possible precision. For example, the block vector prediction value is the vector (0, 0), and the block vector difference is the symbol (-5, 0) of 4 integer pixel resolution. The highest possible precision is 1 integer pixel. When the decoded block vector is at 4 integer pixel resolution, the block vector will be (-20, 0). If (-20, 0) points to a location outside the left picture boundary, the decoded block vector difference will be changed to 1 integer pixel resolution, so that the decoded block vector is (-5, 0), which is a valid vector in this case. This change can help move the block vector within the boundary.
[0130] According to another aspect of the present disclosure, the technique of processing multiple resolutions in a block vector for intra-frame picture block compensation can be equally applied to motion vectors for inter-frame picture block compensation. In some embodiments, multiple motion vector resolutions are used for encoding of motion vectors, and the motion vector resolutions can be switched at the block level. In addition, when more than two possible resolutions are used, a signaling flag that may include more than 1-bin is used to inform which of the multiple motion vector resolutions is used for the motion vector difference of the current block. Possible resolutions include, but are not limited to, 1 / 8 pixel, 1 / 4 pixel, 1 / 2 pixel, 1 integer pixel, 2 integer pixels, 4 integer pixels, 8 integer pixels, and the like. X integer pixels represent that each minimum unit of a symbol represents X integer positions. For example, 2 integer pixels represent that each minimum unit of a symbol represents 2 integer positions, 4 integer pixels represent that each minimum unit of a symbol represents 4 integer positions, and 8 integer pixels represent that each minimum unit of a symbol represents 8 integer positions.
[0131] In one embodiment, the x and y components of the motion vector difference may use different resolutions. For example, the x component of the motion vector difference is at 1 integer pixel resolution, while the y component is at 4 integer pixel resolution. The resolution may be selected for each component by explicit signaling (1 flag per component) or by inference. For example, the size of the motion vector prediction value of the current block may be used to infer the resolution. In one example, when the size of a component of the motion vector prediction value is greater than a threshold, the motion vector difference resolution of that component will use a larger step resolution, such as 4 integer pixel resolution; otherwise, the component will use a smaller step resolution, such as 1 integer pixel resolution.
[0132] In another embodiment, the x and y components of the motion vector difference may use different resolutions. By default, the two components will use a fixed resolution, such as a 1 / 4 pixel resolution. Component conditions are set for each component to determine the resolution. For example, when certain component conditions are met, each component can be switched to a different resolution by inference. The components of the predicted value will also be quantized to the corresponding resolution, or simply keep their original resolution unchanged. For example, a component condition is related to the size of the motion vector predicted value of the current block. By evaluating the size of the motion vector predicted value of the current block in each component, the resolution of the component can be inferred. For example, when the size of the component of the motion vector predicted value is greater than a threshold, the motion vector difference resolution of the component will use a larger step resolution, such as 4 integer pixel resolution; otherwise, the component will use a default step resolution, such as 1 / 4 pixel resolution. In a specific example, the default resolution is 1 / 4 pixel. The motion vector predicted value is set to (-20.75, -3.75), and the threshold value of using 1 integer pixel resolution for each component is 5. The decoded motion vector difference symbol is (2, 2). According to the rule, the x component will use 1 integer pixel resolution, and the y component will use 1 / 4 pixel resolution. Then, the motion vector prediction value will become (-20, -3.75) (for example, -20.75 is rounded to -20 towards zero), and the block vector difference will become (2, 0.5) (due to 1 integer pixel of the x component and 1 / 4 pixel of the y component). In this example, the final decoded block vector is (-18, -3.25).
[0133] Fig.10 A flow chart of an overview process (1000) according to an embodiment of the present disclosure is shown. The process (1000) can be used for reconstruction of a block encoded in intra-frame mode to generate a prediction block for the block being reconstructed. In various embodiments, the process (1000) is performed by a processing circuit, such as a processing circuit in a terminal device (310), (320), (330) and (340), a processing circuit that performs the functions of a video encoder (403), a processing circuit that performs the functions of a video decoder (410), a processing circuit that performs the functions of a video decoder (510), a processing circuit that performs the functions of an intra-frame prediction module (552), a processing circuit that performs the functions of a video encoder (603), a processing circuit that performs the functions of a predictor (635), a processing circuit that performs the functions of an intra-frame encoder (722), a processing circuit that performs the functions of an intra-frame decoder (872), etc. In some embodiments, the process (1000) is implemented by software instructions, so when the processing circuit executes the software instructions, the processing circuit performs the process (1000). The process starts at (S1001) and is executed at (S1010).
[0134] At (S1010), prediction information of a current block is decoded from a coded video bitstream. The prediction information indicates an intra block copy mode.
[0135] At (S1020), a resolution of a block vector difference of the current block is selected from a set of a plurality of candidate resolutions. In one embodiment, a resolution flag is received and the resolution is selected based on the flag. In another embodiment, the resolution is determined based on inference.
[0136] At (S1030), a block vector of the current block is determined according to the selected resolution of the block vector difference and the block vector prediction value of the current block.
[0137] At (S1040), the samples of the current block are constructed according to the determined block vector. Then, the process executes (S1099) and ends.
[0138] The above techniques may be implemented as computer software via computer-readable instructions and physically stored in one or more computer-readable media. Fig.11 A computer system (1100) is shown that is suitable for implementing certain embodiments of the disclosed subject matter.
[0139] The computer software may be encoded in any suitable machine code or computer language, and may be assembled, compiled, linked, or the like to create a code comprising instructions, which may be directly executed by one or more computer central processing units (CPUs), graphics processing units (GPUs), etc., or executed by decoding, microcode, or the like.
[0140] The instructions may be executed on various types of computers or components thereof, including, for example, personal computers, tablet computers, servers, smartphones, gaming devices, IoT devices, etc.
[0141] Fig.11 The components shown for the computer system (1100) are exemplary in nature and are not intended to impose any limitations on the scope of use or functionality of computer software implementing the disclosed embodiments. Nor should the configuration of the components be interpreted as having any dependency or requirement on any one or combination of components shown in the exemplary embodiment of the computer system (1100).
[0142] The computer system (1100) may include certain human-computer interface input devices. Such human-computer interface input devices may respond to input from one or more human users through tactile input (e.g., keyboard input, sliding, data glove movement), audio input (e.g., sound, applause), visual input (e.g., gestures), and olfactory input (not shown). The human-computer interface devices may also be used to capture certain media that are not necessarily directly related to conscious human input, such as audio (e.g., speech, music, ambient sound), images (e.g., scanned images, photographic images obtained from a still image camera), and videos (e.g., two-dimensional video, three-dimensional video including stereoscopic video).
[0143] The human-computer interface input device may include one or more of the following (only one of which is drawn): keyboard (1101), mouse (1102), touchpad (1103), touch screen (1110), data gloves (not shown), joystick (1105), microphone (1106), scanner (1107), camera (1108).
[0144] The computer system (1100) may also include certain human-computer interface output devices. Such human-computer interface output devices may stimulate one or more human user senses through, for example, tactile output, sound, light, and smell / taste. Such human-computer interface output devices may include tactile output devices (e.g., tactile feedback through a touch screen (1110), a data glove (not shown), or a joystick (1105), but there may also be tactile feedback devices that are not used as input devices), audio output devices (e.g., speakers (1109), headphones (not shown)), visual output devices (e.g., screens (1110) including cathode ray tube screens, liquid crystal screens, plasma screens, organic light emitting diode screens, each of which has or does not have a touch screen input function, each of which has or does not have a tactile feedback function - some of which may output two-dimensional visual output or output of more than three dimensions through means such as stereoscopic image output; virtual reality glasses (not shown), holographic displays, and smoke boxes (not shown)) and printers (not shown).
[0145] The computer system (1100) may also include human-accessible storage devices and their associated media, such as optical media including high-density read-only / rewritable optical disks (CD / DVD ROM / RW) (1120) with CD / DVD or similar media (1121), thumb drives (1122), removable hard disk drives or solid state drives (1123), traditional magnetic media such as tapes and floppy disks (not shown), special-purpose ROM / ASIC / PLD-based devices such as security software protectors (not shown), and the like.
[0146] Those skilled in the art should also understand that the term "computer-readable media" used in connection with the disclosed subject matter does not include transmission media, carrier waves, or other transient signals.
[0147] The computer system (1100) may also include an interface to one or more communication networks. For example, the network may be wireless, wired, or optical. The network may also be a local area network, a wide area network, a metropolitan area network, an in-vehicle network, an industrial network, a real-time network, a delay-tolerant network, and the like. The network also includes local area networks such as Ethernet, wireless local area networks, cellular networks (GSM, 3G, 4G, 5G, LTE, etc.), television wired or wireless wide area digital networks (including cable television, satellite television, and terrestrial broadcast television), in-vehicle and industrial networks (including CANBus), and the like. Some networks typically require an external network interface adapter for connecting to some universal data ports or peripheral buses (1149) (e.g., a USB port of the computer system (1100)); other systems are typically integrated into the core of the computer system (1100) by connecting to a system bus as described below (e.g., an Ethernet interface integrated into a PC computer system or a cellular network interface integrated into a smart phone computer system). By using any of these networks, the computer system (1100) can communicate with other entities. The communication can be one-way, for receiving only (e.g., wireless television), one-way for sending only (e.g., CAN bus to certain CAN bus devices), or two-way, such as to other computer systems via a local or wide area digital network. Each of the above networks and network interfaces can use certain protocols and protocol stacks.
[0148] The above-mentioned human-machine interface devices, human-accessible storage devices, and network interfaces may be connected to the core (1140) of the computer system (1100).
[0149] The core (1140) may include one or more central processing units (CPUs) (1141), graphics processing units (GPUs) (1142), dedicated programmable processing units in the form of field programmable gate arrays (FPGAs) (1143), hardware accelerators for specific tasks (1144), etc. These devices, as well as read-only memory (ROM) (1145), random access memory (1146), internal mass storage (e.g., internal non-user accessible hard disk drives, solid-state drives, etc.) (1147), etc., may be connected via a system bus (1148). In some computer systems, the system bus (1148) may be accessed in the form of one or more physical plugs so that it can be expanded by additional central processing units, graphics processing units, etc. Peripheral devices may be directly attached to the core's system bus (1148), or connected via a peripheral bus (1149). The architecture of the peripheral bus includes PCI, USB, etc.
[0150] The CPU (1141), GPU (1142), FPGA (1143) and accelerator (1144) can execute certain instructions, which can be combined to form the above-mentioned computer code. The computer code can be stored in ROM (1145) or RAM (1146). Transition data can also be stored in RAM (1146), while permanent data can be stored in, for example, internal mass storage (1147). Fast storage and retrieval of any memory device can be achieved by using a cache memory, which can be closely associated with one or more CPUs (1141), GPUs (1142), mass storage (1147), ROMs (1145), RAMs (1146), etc.
[0151] The computer readable medium may have computer code thereon for performing various computer-implemented operations. The medium and computer code may be specially designed and constructed for the purposes of the present disclosure, or may be the medium and code well known and available to those skilled in the art of computer software.
[0152] As an example and not a limitation, a computer system having the architecture (1100), in particular the core (1140), can provide the function of executing software contained in one or more tangible computer-readable media as a processor (including a CPU, GPU, FPGA, accelerator, etc.). Such a computer-readable medium can be a medium associated with the above-mentioned user-accessible mass storage, as well as a specific memory of the core (1140) having non-volatility, such as a core internal mass storage (1147) or ROM (1145). Software implementing various embodiments of the present disclosure can be stored in such a device and executed by the core (1140). Depending on specific needs, the computer-readable medium may include one or more storage devices or chips. The software can enable the core (1140), in particular the processor therein (including a CPU, GPU, FPGA, etc.) to perform a specific process or a specific part of a specific process described herein, including defining a data structure stored in the RAM (1146) and modifying such a data structure according to a software-defined process. Additionally or alternatively, the computer system may provide functionality hardwired in logic or otherwise contained in circuitry (e.g., accelerator (1144)) that may operate in place of or in conjunction with software to perform specific processes or specific portions of specific processes described herein. Where appropriate, references to software may include logic and vice versa. Where appropriate, references to computer-readable media may include circuitry (e.g., integrated circuits (ICs)) storing executing software, circuitry containing executing logic, or both. The present disclosure includes any suitable combination of hardware and software.
[0153] Appendix: Acronyms
[0154] JEM: Joint Development Model
[0155] VVC: Versatile Video Coding
[0156] BMS: Benchmark Collection
[0157] MV: Motion Vector
[0158] HEVC: High Efficiency Video Coding
[0159] SEI: Supplemental Enhancement Information
[0160] VUI: Video Availability Information
[0161] GOP: Group of Pictures
[0162] TU: Transform Unit
[0163] PU: prediction unit
[0164] CTU: Coding Tree Unit
[0165] CTB: Coding Tree Block
[0166] PB: prediction block
[0167] HRD: Hypothesized Reference Decoder
[0168] SNR: Signal to Noise Ratio
[0169] CPU: Central Processing Unit
[0170] GPU: Graphics Processing Unit
[0171] CRT: cathode ray tube
[0172] LCD: Liquid Crystal Display
[0173] OLED: Organic Light Emitting Diode
[0174] CD: compact disc
[0175] DVD: Digital Video Disc
[0176] ROM: Read Only Memory
[0177] RAM: Random Access Memory
[0178] ASIC: Application-Specific Integrated Circuit
[0179] PLD: Programmable Logic Device
[0180] LAN: Local Area Network
[0181] GSM: Global System for Mobile Communications
[0182] LTE: Long Term Evolution
[0183] CANBus: Controller Area Network Bus
[0184] USB: Universal Serial Bus
[0185] PCI: Peripheral Component Interconnect
[0186] FPGA: Field Programmable Gate Array
[0187] SSD: Solid State Drive
[0188] IC: Integrated Circuit
[0189] CU: Coding Unit
[0190] Although the present disclosure has described a number of exemplary embodiments, various changes, arrangements and various equivalent substitutions of the embodiments are within the scope of the present disclosure. It should therefore be understood that those skilled in the art are capable of designing a variety of systems and methods, which, although not explicitly shown or described herein, embody the principles of the present disclosure and are therefore within the spirit and scope of the present disclosure.
Claims
1. A video decoding method, characterized in that: include: Decoding prediction information of a current block from a coded video bitstream, the prediction information indicating an intra block copy mode; Determining a block vector prediction value of the current block based on the prediction information; Determining a block vector difference of the current block based on the prediction information; When it is determined that the first size of the first component of the block vector prediction value is greater than a threshold, selecting a first candidate resolution as the first resolution of the first component of the block vector difference; When it is determined that the first magnitude of the first component of the block vector prediction value is not greater than the threshold, selecting a second candidate resolution as the first resolution of the first component of the block vector difference, the second candidate resolution being a resolution having higher accuracy than the first candidate resolution; determining a block vector of the current block according to the block vector prediction value, the block vector difference and a first resolution of a first component of the block vector difference; as well as At least one sample of the current block is reconstructed according to the block vector.
2. The method according to claim 1, characterized in that Further including: When it is determined that the second magnitude of the second component of the block vector prediction value is greater than the threshold, selecting the first candidate resolution as the second resolution of the second component of the block vector difference; as well as When it is determined that the second size of the second component of the block vector prediction value is not greater than the threshold, the second candidate resolution is selected as the second resolution of the second component of the block vector difference.
3. The method according to claim 1, characterized in that The first candidate resolution is 1 pixel resolution, and the second candidate resolution is 1 / 4 pixel resolution.
4. The method according to claim 1, characterized in that The first candidate resolution is a 4-pixel resolution, and the second candidate resolution is a 1-pixel resolution.
5. The method according to claim 1, characterized in that The threshold is 5 pixels.
6. The method according to any one of claims 1 to 5, characterized in that: Further including: When the block vector prediction value uses a resolution different from the first resolution, the block vector difference is added to the block vector prediction value without rounding the block vector prediction value to calculate the block vector.
7. The method according to any one of claims 1 to 5, characterized in that: Further including: When the block vector prediction value has a resolution different from the first resolution, rounding the block vector prediction value of the current block to another vector having the first resolution; as well as The block vector difference is added to the rounded block vector prediction value to calculate the block vector.
8. The method according to any one of claims 1 to 5, characterized in that: Further including: At least one of the block vector difference and the block vector prediction value is modified to constrain the block vector within a valid region.
9. A video encoding method for generating a video bit stream, characterized in that: include: Determining a block vector prediction value of the current block based on prediction information of the current block, the prediction information indicating that the current block is encoded in an intra block copy mode; Determining a block vector difference of the current block based on the prediction information; When it is determined that the first size of the first component of the block vector prediction value is greater than a threshold, selecting a first candidate resolution as the first resolution of the first component of the block vector difference; When it is determined that the first magnitude of the first component of the block vector prediction value is not greater than the threshold, selecting a second candidate resolution as the first resolution of the first component of the block vector difference, the second candidate resolution being a resolution having higher accuracy than the first candidate resolution; determining a block vector of the current block according to the block vector prediction value, the block vector difference and a first resolution of a first component of the block vector difference; as well as At least one sample of the current block is encoded according to the block vector to generate the video bitstream.
10. A video decoding device, characterized in that: include: Processing circuitry for: Decoding prediction information of a current block from a coded video bitstream, the prediction information indicating an intra block copy mode; Determining a block vector prediction value of the current block based on the prediction information; Determining a block vector difference of the current block based on the prediction information; When it is determined that the first size of the first component of the block vector prediction value is greater than a threshold, selecting a first candidate resolution as the first resolution of the first component of the block vector difference; When it is determined that the first magnitude of the first component of the block vector prediction value is not greater than the threshold, selecting a second candidate resolution as the first resolution of the first component of the block vector difference, the second candidate resolution being a resolution having higher accuracy than the first candidate resolution; determining a block vector of the current block according to the block vector prediction value, the block vector difference and a first resolution of a first component of the block vector difference; as well as At least one sample of the current block is reconstructed according to the block vector.
11. The device according to claim 10, characterized in that The processing circuit is further configured to: When it is determined that the second magnitude of the second component of the block vector prediction value is greater than the threshold, selecting the first candidate resolution as the second resolution of the second component of the block vector difference; as well as When it is determined that the second size of the second component of the block vector prediction value is not greater than the threshold, the second candidate resolution is selected as the second resolution of the second component of the block vector difference.
12. The device according to claim 10, characterized in that The first candidate resolution is 1 pixel resolution, and the second candidate resolution is 1 / 4 pixel resolution.
13. The device according to claim 10, characterized in that The first candidate resolution is a 4-pixel resolution, and the second candidate resolution is a 1-pixel resolution.
14. The device according to claim 10, characterized in that The threshold is 5 pixels.
15. The device according to any one of claims 10 to 14, characterized in that: The processing circuit is further configured to: When the block vector prediction value uses a resolution different from the first resolution, the block vector difference is added to the block vector prediction value without rounding the block vector prediction value to calculate the block vector.
16. The device according to any one of claims 10 to 14, characterized in that: The processing circuit is further configured to: When the block vector prediction value has a resolution different from the first resolution, rounding the block vector prediction value of the current block to another vector having the first resolution; and The block vector difference is added to the rounded block vector prediction value to calculate the block vector.
17. The device according to any one of claims 10 to 14, characterized in that: The processing circuit is further configured to: At least one of the block vector difference and the block vector prediction value is modified to constrain the block vector within a valid region.
18. A video encoding device for generating a video bit stream, characterized in that: include: Processing circuitry for: Determining a block vector prediction value of the current block based on prediction information of the current block, the prediction information indicating that the current block is encoded in an intra block copy mode; Determining a block vector difference of the current block based on the prediction information; When it is determined that the first size of the first component of the block vector prediction value is greater than a threshold, selecting a first candidate resolution as the first resolution of the first component of the block vector difference; When it is determined that the first magnitude of the first component of the block vector prediction value is not greater than the threshold, selecting a second candidate resolution as the first resolution of the first component of the block vector difference, the second candidate resolution being a resolution having higher accuracy than the first candidate resolution; determining a block vector of the current block according to the block vector prediction value, the block vector difference and a first resolution of a first component of the block vector difference; as well as At least one sample of the current block is encoded according to the block vector to generate the video bitstream.
19. A non-volatile computer-readable storage medium, characterized in that: The device stores instructions, which, when executed by a computer for video decoding and / or encoding, enable the computer to execute the method according to any one of claims 1 to 9.
