CN117319664A - Coding and decoding method and device for alternately coding index representation string group and copying upper string - Google Patents

Coding and decoding method and device for alternately coding index representation string group and copying upper string Download PDF

Info

Publication number
CN117319664A
CN117319664A CN202111283456.XA CN202111283456A CN117319664A CN 117319664 A CN117319664 A CN 117319664A CN 202111283456 A CN202111283456 A CN 202111283456A CN 117319664 A CN117319664 A CN 117319664A
Authority
CN
China
Prior art keywords
strings
string
decoding
unit
compression unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111283456.XA
Other languages
Chinese (zh)
Inventor
林涛
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Individual
Original Assignee
Individual
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Individual filed Critical Individual
Priority to CN202111283456.XA priority Critical patent/CN117319664A/en
Publication of CN117319664A publication Critical patent/CN117319664A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/17Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being an image region, e.g. an object
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/146Data rate or code amount at the encoder output
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/182Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a pixel
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

The present invention provides a method and apparatus for encoding and decoding a set of point vector index representation strings and a unit base vector string automatically and alternately without using a flag bit. When each group of point vector indexes represents strings, firstly, a variable which represents how many point vector indexes of the group represent strings and is called string number and syntax elements thereof are encoded and decoded; the point vector index representing strings in the group are encoded and decoded one by one, and then encoding and decoding of one unit base vector string are automatically started, so that the encoding and decoding are continuously alternated until all strings in the current whole compression unit are encoded and decoded. Therefore, each unit base vector string can omit one bit of a flag bit, and the point prediction coding efficiency is effectively improved.

Description

Coding and decoding method and device for alternately coding index representation string group and copying upper string
Technical Field
The present invention relates to a coding and decoding system for lossy or lossless compression of data, and more particularly, to a coding method and apparatus for compressing data by point prediction and a decoding method and apparatus therefor.
Background
As human society enters the era of artificial intelligence, big data, virtual reality, augmented reality, mixed reality, cloud computing, mobile computing, cloud-mobile computing, ultra-high definition (4K) and ultra-high definition (8K) video image resolution, 4G/5G communication, ultra-high compression ratio and ultra-high quality data compression are indispensable for various data including big data, image data, video data, and various new forms of data.
A data set is a set of data elements (e.g., bytes, bits, pixels, pixel components, spatial sampling points, transform domain coefficients).
When encoding or decoding a data set (simply referred to as "encoding/decoding"), data elements are typically ordered according to a predetermined rule, i.e., a predetermined order, and are encoded/decoded in the order.
When encoding (and correspondingly decoding) data sets (e.g., a one-dimensional data queue, a two-dimensional data file, a frame of image, a video sequence, a transform domain, a transform block, a plurality of transform blocks, a three-dimensional scene, a sequence of continuously changing three-dimensional scenes) arranged in a spatial (one-dimensional, two-dimensional, or multi-dimensional) shape, in particular, two-dimensional or more data sets, the data sets are typically divided into compressed subsets of a predetermined shape and/or size (i.e., number of elements), which are encoded or decoded sequentially, one compression subset after the other, in a predetermined order, in units of compressed subsets.
In encoding or decoding a compressed subset, the compressed subset is typically divided into a number of maximum compression units having a predetermined shape and/or size (i.e., number of elements), and the maximum compression units are sequentially encoded or decoded in a predetermined order, one after the other. The maximum compression units arranged in a row from left to right constitute a maximum compression unit row.
Within a maximum compression unit, this maximum compression unit is further divided into a number of sub-units having a predetermined shape and/or size (i.e., number of elements), called whole compression units, which are encoded or decoded one by one in a predetermined order in units of whole compression units.
In short, the above process ultimately divides the data set into several subsets of predetermined shapes and/or sizes (i.e., numbers of elements), referred to as integer compression units, which are encoded or decoded one by one in a predetermined order, in units of integer compression units.
At any one time, the compressed subset being encoded or decoded is referred to as the current compressed subset. The largest compression unit being encoded or decoded is referred to as the current largest compression unit. The row of the largest compression unit under encoding or decoding is referred to as the current row of the largest compression unit. The integer compression unit being encoded or decoded is referred to as the current integer compression unit. The data element being encoded or decoded (sometimes also simply referred to as an element) is referred to as the current encoded data element or the current decoded data element, collectively referred to as the current data element, simply referred to as the current element. The element is composed of N components (typically 1. Ltoreq.N.ltoreq.5), so the dataset, compressed subset, maximum compression unit, and whole compression unit are also composed of N components. The components of an element are also referred to as component elements.
For example, a compressed subset is a frame of an image whose elements, i.e., pixels, are arranged in a rectangular shape, having a size (resolution) of 3840 (width) x 2160 (height), consisting of 3 components: g (green) component, B (blue) component, R (red) component or Y (luminance) component, U (Cb chrominance) component, V (Cr chrominance) component. One frame image is divided into maximum compression units of 128x128 size. Each maximum compression unit is further divided into square or rectangular whole compression units of varying sizes from 4x4 to 64x 64.
In the case of a data set divided into compressed subsets, maximum compressed units and whole compressed units, one predetermined rule for ordering elements is to order the compressed subsets first, then the maximum compressed units within each compressed subset, then the whole compressed units within each maximum compressed unit, and then the elements within each whole compressed unit.
That is, in the case where the data set is ultimately divided into whole compression units, one predetermined rule for ordering is to order the whole compression units first, and then order the elements within each whole compression unit.
The relation between the multi-component data set as the encoding object and the sampling rate of each component of the whole compression unit is generally expressed in a sampling format. Data where the N components all have the same sampling rate and size (i.e., the number of component samples) is referred to as full sample format data. The N components have different sampling rates and sizes Middle N 1 The sampling rate and size of the components, called the principal components, are the remaining N-N 1 Data of integer multiples of the sampling rate and size of the components, referred to as sub-components, are referred to as downsampled format data. The integer multiple is typically 2-fold, 4-fold, 8-fold, 2x 2-fold, 4x 2-fold, etc. In full sample format data, all components are considered to be primary components, with no secondary components. In the downsampled format data, at least one component is a major component and at least one component is a minor component. For example, for an array of two-dimensional data elements comprising computer-generated graphics and text-containing images, a sampling format called 4:4:4 (444) is typically used, i.e., 3 components of the data set all have the same sampling rate and size (i.e., number of component samples). For an array of another type of two-dimensional data elements comprising natural images and video captured by a camera, a sampling format called 4:2:0 (420 for short) is typically used, i.e. the sampling rate and size of 2 components called secondary components (D-component and E-component) of a data set (such as an image or video) having a rectangular shape and 3 components are each one quarter of the other component called primary component (F-component), i.e. there is a 4:1 downsampling relationship between the primary and secondary components. In this case, a D component D [ i ] ][j]And an E component Ei][j]Corresponding to four (2X 2) F components F [2i ]][2j],F[2i+1][2j],F[2i][2j+1],F[2i+1][2j+1]. If the resolution of the F component is 2M x 2N (horizontal 2M component elements, vertical 2N component elements), i.e. the F component of the dataset is f= { F [ M ]][n]: m=0-2M-1, n=0-2N-1, then the resolution of the D and E components are m×n (horizontal M component elements, vertical N component elements), respectively, i.e. the D and E components of the dataset are d= { D [ M ]][n]: m=0 to M-1, n=0 to N-1 and e= { E [ M ]][n]: m=0 to M-1, n=0 to N-1. Where higher quality is also required for the secondary components, a sampling format called 4:2:2 (422) is often used, i.e. the sampling rate and size of the 2 secondary components (D-component and E-component) of a data set (e.g. image or video) having a rectangular shape and 3 components are half the other primary component (F-component), i.e. primary component and secondary component, respectivelyWith a 2:1 downsampling relationship. In this case, in one direction (e.g., horizontal direction) of the dataset (e.g., image or video), one D component D [ i ]][j]And an E component Ei][j]Corresponding to two (2X 1) F components F [2i ]][j]And F2 i+1][j]. If the resolution of the F component is 2 mxn, i.e. the F component of the dataset is f= { F [ M ] ][n]: m=0-2M-1, n=0-N-1, then the resolution of the D and E components are m×n, respectively, i.e. the D and E components of the data set are d= { D [ M ]][n]: m=0 to M-1, n=0 to N-1 and e= { E [ M ]][n]: m=0 to M-1, n=0 to N-1. In images and video in YUV or YCbCr or YCgCo color formats, the F, D, E component described above is typically a Y, U, V component or a Y, cb, cr component or a Y, cg, co component, respectively. In images and video in RGB color format, the F, D, E component described above is typically G, B, R component or G, R, B component, respectively. Where the data is an image or video, the sampling format is also commonly referred to as a chroma format. A chroma format in which the components all have the same sampling rate is called a panchromatic format. A chroma format that has a downsampled relationship between one part of the component and another part of the component is referred to as a downsampled chroma format.
In the downsampling format, the position of one secondary component (usually called secondary component position) and its element correspond to the positions of a plurality of primary components (usually called primary component position, even if simply called position, no confusion is generated), and its element. Such one-to-many correspondence has uncertainty. To eliminate such uncertainty, a principal component is usually pre-specified in a plurality of positions (e.g., 2x2 positions in 420 format or 2x1 positions in 422 format) and elements thereof corresponding to a secondary component position and elements thereof Positive directionPosition and locationPositive directionAn element (e.g. designating the position 2x2 and the position on the upper left of the elements thereof and the element thereof or the position 2x1 and the position on the left of the elements thereof and the element thereof are the main componentsPositive directionPosition and locationPositive directionElement) as a one-to-one correspondence with the secondary component position and its elementUnique and regular formPrincipal component location and its elements. Principal componentPositive directionThe positions have a one-to-one correspondence with the secondary component positions, and therefore, the primary componentPositive directionLocation and sub-divisionThe quantitative position is collectively referred to as positive position, indicating that the position is the principal componentPositive directionThe positions are also secondary component positions, and the positive positions and the secondary component positions have a one-to-one correspondence, and any other position than the positive position among the plurality of positions corresponding to one secondary component position is referred to as a non-positive position. Principal componentPositive directionThere is also a one-to-one correspondence between the elements and the minor component elements, and therefore, the major componentPositive directionThe element and the minor component element are collectively referred to as a positive element, meaning that the element is the major componentPositive directionThe elements are secondary component elements, the positive elements and the secondary component elements have a one-to-one correspondence, and other elements except the positive elements in the plurality of elements corresponding to one secondary component element are called non-positive elements. On the other hand, in the full sampling format, all positions are considered to be principal components Positive directionPosition and locationPositive directionLocation, all elements are considered principal componentsPositive directionElements and method for producing the samePositive directionAn element.
In the case where the data is an array or sequence of arrays of two-dimensional data elements in 420 sample format, there is one primary component F and two secondary components D and E;
the sampling rate and size of the secondary components D and E are respectively one quarter of the primary component F, namely the primary component and the secondary component have a downsampling relation of 4:1, namely 2x 2:1;
one D component element D [ i ] [ j ] and one E component element E [ i ] [ j ] correspond to 2×2, i.e., 4F component elements F [2i ] [2j ], F [2i+1] [2j ], F [2i ] [2j+1], F [2i+1] [2j+1] arranged up, down, left and right;
the resolution of the F component elements is 2M x 2N, i.e., the F component elements make up the array f= { F [ M ] [ N ]: m=0 to 2M-1, n=0 to 2N-1,
the resolution of the D component elements is m×n, i.e., the D component elements make up an array d= { D [ M ] [ N ]: m=0 to M-1, n=0 to N-1,
the resolution of the E component elements is also mxn, i.e., the E component elements make up an array e= { E [ M ] [ N ]: m=0 to M-1, n=0 to N-1.
The principal component positive element on the pre-specified positive position is F [2i ] [2j ], called the principal component positive position of the upper left corner type and its positive element;
or,
the principal component positive element on the pre-specified positive position is F2i+1 ] [2j ], referred to as the principal component positive position of the upper right corner type and its positive element;
Or,
the principal component positive element on the pre-specified positive position is F [2i ] [2j+1], called the principal component positive position of the lower left corner type and its positive element;
or,
the principal component positive element on the pre-specified positive position is F [2i+1] [2j+1], referred to as the principal component positive position of the lower right corner type and its positive element.
In the case of a data set divided into whole compression units, one predetermined rule for ordering is to order the whole compression units first and then order the elements within each whole compression unit.
An effective means of data compression is string prediction, also known as string matching. String prediction divides an element of a current whole compression unit into element strings of variable length, and obtains a reference element string having the same or similar value as a current element string, referred to as a reference string or a predicted string or a matching string of the current element string, from a set of elements or a subset thereof called a reference set, which have been encoded and decoded to a predetermined extent. For a reference string of a current string, only a plurality of parameters are needed to record the position and/or shape and/or size and/or dimension of the reference string in a reference set, and the numerical value of each element in the current string is not needed to be recorded one by one, so that all elements of the current string and the numerical values thereof can be completely represented and reconstructed whenever and wherever needed, thereby achieving the aim of data compression. The elements reconstructing the current string produced are called reconstruction elements, the values of which are called the reconstructed values of the current string and its elements. Data compression where the reconstructed value of an element is equivalent to the original value of the element is referred to as lossless compression. Data compression in which the reconstructed value of an element is not equivalent to the original value of the element is referred to as lossy compression.
For example, if a current string which is continuously ordered according to a certain scanning mode can find a corresponding reference string in a reference set, the position and the size of the reference string in the reference set are recorded by only using two parameters, namely the position relation between the first element of the current string and the first element of the reference string and the string length, and the value of each element in the current string is not recorded one by one, so that all elements and the values of the elements of the current string can be completely represented and reconstructed whenever and wherever needed, and the reconstruction values of the current string and the elements of the current string are obtained. The number of bits consumed to record the two parameters is often much less than the number of bits consumed to record the value itself of each element in the current string one by one, thereby achieving data compression.
In string prediction, the reconstruction operation is typically accomplished by reading the reference element and copying it to the location of the current element. Thus, string prediction is also referred to as string replication. The throughput of generating the reconstruction element is substantially dependent on the throughput of reading the reference element.
In string prediction, unpredictable (also referred to as unmatched or unmatched) elements may also occur in which no reference element is found within the reference set. The components, major components, minor components of the unpredictable element are referred to as unpredictable components, unpredictable major components, unpredictable minor components, respectively. For the unpredictable element, only the accurate or approximate value of the unpredictable element can be recorded, the unpredictable element is compressed according to a preset mode, and the unpredictable element is reconstructed whenever and wherever needed, so as to obtain the reconstruction value of the unpredictable element.
Scanning methods often used in string prediction include:
horizontal raster scan: the elements in one whole compression unit are arranged along the horizontal direction, one element is arranged one element, the next row is arranged after one row is arranged, all the scanning directions in the rows are arranged from left to right or all the scanning directions in the rows are arranged from right to left.
Or alternatively
Horizontal back and forth scanning is also referred to as back and forth scanning or arcuate scanning: the elements in one whole compression unit are arranged along the horizontal direction one element by one element, one row is arranged next to the next row, the scanning direction in the row of one row in any two adjacent rows is arranged from left to right, the scanning direction in the row of the other row is arranged from right to left, the row arranged from left to right is called as a forward row, and the row arranged from right to left is called as a reverse row;
or alternatively
Vertical raster scan: the elements in one whole compression unit are arranged along the vertical direction one element by one element, the next row is arranged after one row is arranged, and all scanning directions in the rows are arranged from top to bottom or all scanning directions in the rows are arranged from bottom to top;
or alternatively
Vertical back and forth scanning is also known as round-trip scanning or arcuate scanning: the elements in one whole compression unit are arranged along the vertical direction one element by one element, one row is arranged next to the next row, the scanning direction in one row of any two adjacent rows is arranged from top to bottom, the scanning direction in the other row is arranged from bottom to top, the row arranged from top to bottom is called a forward row, and the row arranged from bottom to top is called a reverse row.
The first element in the scan, or arrangement, of the string is referred to as the start element and the last element in the scan, or arrangement, of the string is referred to as the end element.
One special case of string prediction is block prediction, also known as block matching. In this particular case, each string forms a rectangular block, even if one string, i.e. one block, is an entire compression unit. In this particular case, the codec may be performed not in the form and order of element scanning but directly in the form of blocks, but may be performed in the form and order of element scanning in a unified manner with the strings.
In this application, strings and blocks are collectively referred to as strings. Thus, string prediction is also a generic term for string prediction and block prediction.
An important factor affecting the coding efficiency of string prediction is the size of the reference set, also commonly referred to as the reference range, i.e. the desirable range of positions of the reference elements to which the string vector points. The larger the reference range, the more candidate reference elements, the more suitable reference elements can be found, and the higher the coding efficiency. But the larger the reference range, the higher the implementation complexity and cost. In particular, the reference range is large to a certain extent, the reference element cannot be placed inside the codec chip, but must be placed in a special memory chip outside the codec chip, so that not only is the cost increased, but both the read-write bandwidth and the pixel processing throughput become serious bottlenecks, and even the codec of the image and the video with high pixel resolution cannot be supported.
In order to reduce implementation complexity and cost in string prediction techniques, the reference range is typically limited, having a predetermined fixed size (i.e., number of elements), such as being limited to the maximum compression unit at or near which the current whole compression unit is located. Even if the reference range is limited, its elements are internal to the codec chip, read-write bandwidth and element processing throughput, especially the throughput of reading the reference elements, remain bottlenecks. For example, if only the reference element that produces at most 1 reconstruction element can be read per clock cycle, the throughput of producing reconstruction elements never exceeds 1 element per clock.
Point prediction is another special case of string prediction and is also an effective means of data compression.
The point prediction technique refers to the location in the data set of a number of data elements whose values frequently repeatedly appear in or near the current whole compression unit, where the encoding has been completed to a predetermined degree, as a normal-present location, and stores the data elements in an array or subset of normal-present locations, where each normal-present location stored in the array or subset is designated by an index, referred to as a normal-present location index or normal-present location address. The data elements in the frequently occurring locations are used as reference elements or prediction elements or matching elements. The method comprises the steps that an equal value string to be encoded or decoded in a current whole compression unit only needs to use an index parameter and a repetition number parameter of a constant position marked by the index to represent that all elements of the equal value string are elements on the constant position marked by the index (the constant position can be the position of one element in a data set before the equal value string or the position of one element in the equal value string), or to represent that all elements of the equal value string are equal to the constant position marked by the index (the constant position can be the position of one element in the data set before the equal value string or the position of one element in the equal value string), and the aim of data compression is achieved without recording the values of each element in the equal value string one by one. The values of the elements on the string of equal values as reconstruction elements are typically equal to or close to (i.e. the error does not exceed a predetermined threshold) the values of the original elements, thus ensuring a high quality, i.e. small distortion, of the reconstruction elements while achieving the purpose of data compression. Since the normal position is usually expressed in the form of a point vector, the normal position index is also referred to as a point vector address, and the normal position array is usually an array of point vectors, i.e., an array of parameters storing a point vector, and the parameters of the point vector include at least the point vector and information about the point vector, and the point vector is usually expressed in coordinates in a predetermined form, which are referred to as position coordinates of the point vector. The point vector array is sometimes also referred to as a point prediction array or a point prediction information table.
For example, if a current string arranged in a predetermined scanning manner can find a point vector in a constant current position array or a subset thereof, the value of the reference element pointed to by the point vector is a predicted value of all elements on the current string, and the predicted value is taken as a value of a reconstructed element, the value of each element in the current string can be completely represented by using only two parameters, namely, the point vector address of the point vector and the length of the current string, without recording the value of each element in the current string one by one. The number of bits consumed to record the two parameters is often much less than the number of bits consumed to record the value itself of each element in the current string one by one, thereby achieving data compression.
A normal-present position element, if present in a positive position, i.e., the position specified by the dot vector representing the normal-present position is a positive position, has all N components including a minor component, there are all N components including a minor component in the compressed data stream, the encoder writes values of all N components including a minor component to the compressed data stream, and the decoder obtains values of all N components including a minor component from the compressed data stream, otherwise, has only a major component and no minor component, there is only a major component and no minor component in the compressed data stream, the encoder writes values of only a major component to the compressed data stream, and the decoder obtains values of only a major component from the compressed data stream. The values of the secondary components of the frequently occurring position elements are stored in the secondary component space at the positive position. The usual location element, which is also referred to as a usual location reference element, is on the one hand a reconstruction element of the location and on the other hand a reference element of other elements for obtaining the reconstruction values of the other elements.
In the whole compression unit using the point prediction technique for encoding and decoding, there is a possibility that unmatched elements of the reference element cannot be found. Unmatched elements, if present inPositive directionThe position then has all N components including the secondary component, all N components including the secondary component are present in the compressed data stream, the encoder writes the values of all N components including the secondary component to the compressed data stream, and the decoder obtains the values of all N components including the secondary component from the compressed data stream, otherwise, only the primary component is present but no secondary component is present in the compressed data stream, the encoder writes the values of only the primary component to the compressed data stream, and the decoder obtains the values of only the primary component from the compressed data stream. The unmatched element itself is also allowed to be used as a reference element for other elements for obtaining reconstructed values of the other elements, in which case the unmatched element is also referred to as unmatched reference element.
The point prediction technique divides the elements of an entire compression unit into three kinds of element strings of variable length, namely, a path formed by continuously ordering the elements according to a predetermined scanning mode along a scanning path:
String type 1: the string of equal values is called an equal value string. The values of the reference elements or predicted elements of all elements on an equivalent string are equal to the values of a constant position element; the equivalent string uses a value of a constant current position and a point vector index (also simply referred to as a constant current position index or a point vector index) thereof to represent the constant current position used by the equivalent string and the point vector thereof, namely, the value of a reference element or a predicted element of all elements on the specified equivalent string is equal to the value of a data element on the constant current position pointed by which point vector;
string type 2: the element strings are not matched. All elements on a string of unmatched elements are unmatched elements, i.e., unpredictable elements; the unmatched element string also uses a value of a particular point vector index to indicate that the string is an unmatched element string rather than an equivalent string;
string type 3: a unit base vector string. The unit base vector string is a string in which the reference string is located a unit distance directly above the current string, wherein in the horizontal scan mode, the directly above refers to directly adjacent above, and in the vertical scan mode, the directly above refers to directly adjacent to the left. Thus, the unit base vector string is also called a duplicate upper string.
It can be seen that the equivalent strings and the unmatched element strings are both represented and distinguished by the value of a point vector index. Thus, the equivalent strings and the unmatched element strings are collectively referred to as point vector index representation strings.
Two unit base vector strings, duplicate upper strings, if consecutively presented, must be merged into the same duplicate upper string. Therefore, two unit base vector strings cannot appear consecutively. That is, a single unit base vector string always alternates with a set (one or more) of point vector index representation strings. This is a property that can be used to improve the efficiency of point predictive coding.
In the prior art, this property is not utilized, and for each unit base vector string in the current whole compression unit, a flag bit is first encoded to indicate that the current string is a unit base vector string. And each bit is required to consume bits, which seriously reduces the point prediction coding efficiency.
Disclosure of Invention
To solve this problem in the point prediction technique, the present invention provides a method and apparatus for encoding and decoding a set of point vector index representation strings and a unit base vector string automatically and alternately without using a flag bit. When each group of point vector indexes represents strings, firstly, a variable which represents how many point vector indexes of the group represent strings and is called string number and syntax elements thereof are encoded and decoded; the point vector index representing strings in the group are encoded and decoded one by one, and then encoding and decoding of one unit base vector string are automatically started, so that the encoding and decoding are continuously alternated until all strings in the current whole compression unit are encoded and decoded. Therefore, each unit base vector string can omit one bit of a flag bit, and the point prediction coding efficiency is effectively improved.
Preferably, the method comprises the steps of,
the number of strings is encoded using one or a combination of the following codes:
1) Truncated binary codes with a maximum value;
2) Truncated unary code with maximum value;
3) Truncated 0-order exponential golomb codes with a maximum value;
4) Truncated 1-order exponential golomb codes with a maximum value;
5) Truncated k-th order exponential golomb codes with a maximum value;
6) The codeword consists of a prefix and a middle prefix, the prefix is a fixed-length code with the length of n-1, the middle prefix is a fixed-length code with the length of 1 or is null, wherein n=ceil (Log 2 (V)), ceil () is an upward rounding operation, log2 () is a logarithm operation based on 2, and V is the maximum value of the number of strings.
Preferably, the method comprises the steps of,
the syntax description table for alternately encoding and decoding a set of point vector index representation strings and a unit base vector string includes at least:
while (NumCodedPixel < NumTotalPixel) {
isc_evs_ups_num_minus1// syntax element representing number of strings
Obtaining the string number StringNum from isc evs _ups_num_minus1
for (k = 0; k <Stringnum, K++ {// encoding/decoding Stringnum Point vector index one by one to represent string
isc_evs_ups_coding(x0,y0,width,height,component)
}
if (NumCodedPixel < NumTotalPixel) {
Encoding and decoding a unit base vector string
}
}
In the above table of the description of the grammar,
while (NumCodedPixel < NumTotalPixel) indicates that when there are more outstanding codec elements in the whole compression unit, the operations in the following curly brackets are circularly performed;
isc evs _ups_num_minus1 is a syntax element representing the number of strings for obtaining the number of strings StringNum;
for (k=0; k < strungnum; k++) means performing the operation strungnum in the following curly brackets a number of times, i.e. encoding and decoding strungnum point vector index representation strings one by one;
isc evs _ups_coding (x 0, y0, width, height, component) is a function of encoding and decoding a point vector index representation string;
if (NumCodedPixel < NumTotalPixel) indicates that if there are more outstanding codec elements in the whole compression unit, the following operations in curly brackets, i.e., codec of one unit base vector string, are performed.
According to a first aspect of the present invention, there is provided a coding method of point prediction, characterized by comprising at least the steps of:
1) At least one original data of the whole compression unit is inputted,
2) At least carrying out point prediction coding on the whole compression unit, and when each group of point vector indexes represent strings, firstly coding a variable which represents how many point vector indexes represent strings in the group and is called string number and syntax elements thereof; encoding the strings of point vector index representations in the set one by one, then automatically starting encoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are encoded,
3) And outputting at least the compressed data code stream of the whole compression unit.
According to a second aspect of the present invention, there is provided a coding apparatus for point prediction, characterized by comprising at least the following modules:
1) The original data input module: at least one original data of the whole compression unit is inputted,
2) And a point prediction coding module: at least carrying out point prediction coding on the whole compression unit, and when each group of point vector indexes represent strings, firstly coding a variable which represents how many point vector indexes represent strings in the group and is called string number and syntax elements thereof; encoding the strings of point vector index representations in the set one by one, then automatically starting encoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are encoded,
3) Compressed data code stream output module: and outputting at least the compressed data code stream of the whole compression unit.
According to a third aspect of the present invention, there is provided a decoding method of point prediction, characterized by comprising at least the steps of:
1) At least one compressed data code stream of the whole compression unit is input,
2) At least performing point prediction decoding on the whole compression unit, and when each group of point vector index representing strings is decoded, firstly decoding a variable which represents how many point vector indexes of the group represent strings and is called string number and syntax elements thereof; decoding the point vector index representative strings in the group one by one, then automatically starting decoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are decoded,
3) And outputting at least the reconstruction element of the whole compression unit.
According to a fourth aspect of the present invention, there is provided a decoding apparatus for point prediction, characterized by comprising at least the following modules:
1) Compressed data code stream input module: at least one compressed data code stream of the whole compression unit is input,
2) A point prediction decoding module: at least performing point prediction decoding on the whole compression unit, and when each group of point vector index representing strings is decoded, firstly decoding a variable which represents how many point vector indexes of the group represent strings and is called string number and syntax elements thereof; decoding the point vector index representative strings in the group one by one, then automatically starting decoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are decoded,
3) And a reconstruction element output module: and outputting at least the reconstruction element of the whole compression unit.
The invention is suitable for encoding and decoding the data in a lossy compression way, and is also suitable for encoding and decoding the data in a lossless compression way. The invention is applicable to the encoding and decoding of one-dimensional data such as character string data or byte string data or one-dimensional graphics or fractal graphics, and is also applicable to the encoding and decoding of data in two or more dimensions such as images, image sequences or video data.
In the present invention, the data involved in the data compression includes one or a combination of the following types of data
1) One-dimensional data;
2) Two-dimensional data;
3) Multidimensional data;
4) A pattern;
5) A split dimension graph;
6) An image;
7) A sequence of images;
8) Video;
9) Audio frequency;
10 A) a file;
11 A) bytes;
12 A) bits;
13 A) pixels;
14 A three-dimensional scene;
15 A sequence of continuously changing three-dimensional scenes;
16 A virtual reality scene;
17 Sequence of continuously changing virtual reality scenes
18 An image in the form of pixels;
19 Transform domain data of the image;
20 A set of bytes of two or more dimensions;
21 A set of bits that are two or more dimensions;
22 A set of pixels;
23 A set of single component pixels;
24 A set of three-component pixels (R, G, B, a);
25 A set of three-component pixels (Y, U, V);
26 A set of three-component pixels (Y, cb, cr);
27 A set of three-component pixels (Y, cg, co);
28 A set of four-component pixels (C, M, Y, K);
29 A set of four-component pixels (R, G, B, a);
30 A set of four-component pixels (Y, U, V, a);
31 A set of four-component pixels (Y, cb, cr, a);
32 Four-component pixels (Y, cg, co, a).
The technical features of the present invention are described above by means of several specific embodiments. Other advantages and effects of the present invention will be readily apparent to those skilled in the art from the present disclosure. The invention may be practiced or carried out in other embodiments that depart from the spirit and scope of the present invention, and the details of the present invention may be modified or changed from various points of view and applications.
Drawings
Fig. 1 is a schematic diagram of the encoding method or apparatus of the present invention.
Fig. 2 is a schematic diagram of the decoding method or apparatus of the present invention.
Detailed Description
Further details of the invention are set forth below.
Example 1
In the encoding method or encoding device or decoding method or decoding device, the original data is an array or sequence of arrays of two-dimensional data elements comprising an image, a sequence of images, a video,
the compressed subset related to the point prediction comprises an image, a sub-image of the image, a tile, a slice and a patch;
the maximum compression unit related to the point prediction comprises a tile block, a maximum coding unit LCU and a coding tree unit CTU;
The whole compression unit comprises a macroblock, a coding unit CU, a sub-region of the CU, a sub-coding unit sub-CU, a prediction block, a prediction unit PU, a sub-region of the PU, a sub-prediction unit sub-PU, a transformation block, a transformation unit TU, a sub-region of the TU and a sub-transformation unit sub-TU.
Example 2
In the encoding method or encoding apparatus or decoding method or decoding apparatus,
the number of strings is encoded using one or a combination of the following codes:
1) Truncated binary codes with a maximum value;
2) Truncated unary code with maximum value;
3) Truncated 0-order exponential golomb codes with a maximum value;
4) Truncated 1-order exponential golomb codes with a maximum value;
5) Truncated k-th order exponential golomb codes with a maximum value;
6) The codeword consists of a prefix and a middle prefix, the prefix is a fixed-length code with the length of n-1, the middle prefix is a fixed-length code with the length of 1 or is null, wherein n=ceil (Log 2 (V)), ceil () is an upward rounding operation, log2 () is a logarithm operation based on 2, and V is the maximum value of the number of strings.
Example 3
In the encoding method or encoding apparatus or decoding method or decoding apparatus,
the syntax description table for alternately encoding and decoding a set of point vector index representation strings and a unit base vector string includes at least:
while (NumCodedPixel < NumTotalPixel) {
isc evs _ups_num_minus1// syntax element representing the number of strings
Obtaining the string number StringNum from isc evs _ups_num_minus1
for (k = 0; k <Stringnum, K++ {// encoding/decoding Stringnum Point vector index one by one to represent string
isc_evs_ups_coding(x0,y0,width,height,component)
}
if (NumCodedPixel < NumTotalPixel) {
Encoding and decoding a unit base vector string
}
}
In the above table of the description of the grammar,
while (NumCodedPixel < NumTotalPixel) indicates that when there are more outstanding codec elements in the whole compression unit, the operations in the following curly brackets are circularly performed;
isc evs _ups_num_minus1 is a syntax element representing the number of strings for obtaining the number of strings StringNum;
for (k=0; k < strungnum; k++) means performing the operation strungnum in the following curly brackets a number of times, i.e. encoding and decoding strungnum point vector index representation strings one by one;
isc evs _ups_coding (x 0, y0, width, height, component) is a function of encoding and decoding a point vector index representation string;
if (NumCodedPixel < NumTotalPixel) indicates that if there are more outstanding codec elements in the whole compression unit, the following operations in curly brackets, i.e., codec of one unit base vector string, are performed.

Claims (10)

1. A method of encoding a point prediction, comprising at least the steps of:
1) At least one original data of the whole compression unit is inputted,
2) At least carrying out point prediction coding on the whole compression unit, and when each group of point vector indexes represent strings, firstly coding a variable which represents how many point vector indexes represent strings in the group and is called string number and syntax elements thereof; encoding the strings of point vector index representations in the set one by one, then automatically starting encoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are encoded,
3) And outputting at least the compressed data code stream of the whole compression unit.
2. A coding device for point prediction, characterized by comprising at least the following modules:
1) The original data input module: at least one original data of the whole compression unit is inputted,
2) And a point prediction coding module: at least carrying out point prediction coding on the whole compression unit, and when each group of point vector indexes represent strings, firstly coding a variable which represents how many point vector indexes represent strings in the group and is called string number and syntax elements thereof; encoding the strings of point vector index representations in the set one by one, then automatically starting encoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are encoded,
3) Compressed data code stream output module: and outputting at least the compressed data code stream of the whole compression unit.
3. A decoding method for point prediction, characterized by at least the steps of:
1) At least one compressed data code stream of the whole compression unit is input,
2) At least performing point prediction decoding on the whole compression unit, and when each group of point vector index representing strings is decoded, firstly decoding a variable which represents how many point vector indexes of the group represent strings and is called string number and syntax elements thereof; decoding the point vector index representative strings in the group one by one, then automatically starting decoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are decoded,
3) And outputting at least the reconstruction element of the whole compression unit.
4. The decoding method of claim 3, wherein,
the raw data is an array or sequence of arrays of two-dimensional data elements comprising an image, a sequence of images, a video,
the compressed subset related to the point prediction comprises an image, a sub-image of the image, a tile, a slice and a patch;
the maximum compression unit related to the point prediction comprises a tile block, a maximum coding unit LCU and a coding tree unit CTU;
The whole compression unit comprises a macroblock, a coding unit CU, a sub-region of the CU, a sub-coding unit sub-CU, a prediction block, a prediction unit PU, a sub-region of the PU, a sub-prediction unit sub-PU, a transformation block, a transformation unit TU, a sub-region of the TU and a sub-transformation unit sub-TU.
5. The decoding method of claim 3, wherein,
decoding the number of strings using one or a combination of the following codes:
1) Truncated binary codes with a maximum value;
2) Truncated unary code with maximum value;
3) Truncated 0-order exponential golomb codes with a maximum value;
4) Truncated 1-order exponential golomb codes with a maximum value;
5) Truncated k-th order exponential golomb codes with a maximum value;
6) The codeword consists of a prefix and a middle prefix, the prefix is a fixed-length code with the length of n-1, the middle prefix is a fixed-length code with the length of 1 or is null, wherein n=ceil (Log 2 (V)), ceil () is an upward rounding operation, log2 () is a logarithm operation based on 2, and V is the maximum value of the number of strings.
6. The decoding method of claim 3, wherein,
the syntax description table for alternately decoding a set of point vector index representation strings and a unit base vector string includes at least:
while (NumCodedPixel < NumTotalPixel) { isc evs _ups_num_minus1// syntax element representing the number of strings Obtaining the string number StringNum from isc evs _ups_num_minus1 for (k = 0; k <Stringnum, k++ {// decoding Stringnum's point vector index representation string one by one isc_evs_ups_coding(x0,y0,width,height,component) } if (NumCodedPixel < NumTotalPixel) { Decoding a unit base vector string } }
In the above table of the description of the grammar,
while (NumCodedPixel < NumTotalPixel) indicates that when there are more outstanding decoded elements in the whole compression unit, the operations in the following curly brackets are circularly performed;
isc evs _ups_num_minus1 is a syntax element representing the number of strings for obtaining the number of strings StringNum;
for (k=0; k < strugnum; k++) means that the operations strugnum in the following curly brackets are performed, i.e. the strugnum point vector index representation strings are decoded one by one;
isc evs _ups_coding (x 0, y0, width, height, component) is a function of decoding a point vector index representation string;
if (NumCodedPixel < NumTotalPixel) indicates that if there are more elements in the whole compression unit that have not been decoded yet, the following operations in curly brackets are performed, i.e., decoding one unit base vector string.
7. A decoding device for point prediction, characterized by comprising at least the following modules:
1) Compressed data code stream input module: at least one compressed data code stream of the whole compression unit is input,
2) A point prediction decoding module: at least performing point prediction decoding on the whole compression unit, and when each group of point vector index representing strings is decoded, firstly decoding a variable which represents how many point vector indexes of the group represent strings and is called string number and syntax elements thereof; decoding the point vector index representative strings in the group one by one, then automatically starting decoding a unit base vector string, so as to alternate until all strings in the current whole compression unit are decoded,
3) And a reconstruction element output module: and outputting at least the reconstruction element of the whole compression unit.
8. The decoding device of claim 7, wherein,
the raw data is an array or sequence of arrays of two-dimensional data elements comprising an image, a sequence of images, a video,
the compressed subset related to the point prediction comprises an image, a sub-image of the image, a tile, a slice and a patch;
the maximum compression unit related to the point prediction comprises a tile block, a maximum coding unit LCU and a coding tree unit CTU;
the whole compression unit comprises a macroblock, a coding unit CU, a sub-region of the CU, a sub-coding unit sub-CU, a prediction block, a prediction unit PU, a sub-region of the PU, a sub-prediction unit sub-PU, a transformation block, a transformation unit TU, a sub-region of the TU and a sub-transformation unit sub-TU.
9. The decoding device of claim 7, wherein,
decoding the number of strings using one or a combination of the following codes:
7) Truncated binary codes with a maximum value;
8) Truncated unary code with maximum value;
9) Truncated 0-order exponential golomb codes with a maximum value;
10 Truncated 1-order exponential golomb code with a maximum value;
11 Truncated k-order exponential golomb code with a maximum value;
12 The codeword consists of a prefix and a middle prefix, the prefix is a fixed-length code with the length of n-1, the middle prefix is a fixed-length code with the length of 1 or is null, wherein n=ceil (Log 2 (V)), ceil () is an upward rounding operation, log2 () is a logarithm operation based on 2, and V is the maximum value of the number of strings.
10. The decoding device of claim 7, wherein,
the syntax description table for alternately decoding a set of point vector index representation strings and a unit base vector string includes at least:
while (NumCodedPixel < NumTotalPixel) { isc evs _ups_num_minus1// syntax element representing the number of strings Obtaining the string number StringNum from isc evs _ups_num_minus1 for (k = 0; k <Stringnum, k++ {// decoding Stringnum's point vector index representation string one by one isc_evs_ups_coding(x0,y0,width,height,component) } if (NumCodedPixel < NumTotalPixel) { Decoding a unit base vector string } }
In the above table of the description of the grammar,
while (NumCodedPixel < NumTotalPixel) indicates that when there are more outstanding decoded elements in the whole compression unit, the operations in the following curly brackets are circularly performed;
isc evs _ups_num_minus1 is a syntax element representing the number of strings for obtaining the number of strings StringNum;
for (k=0; k < strugnum; k++) means that the operations strugnum in the following curly brackets are performed, i.e. the strugnum point vector index representation strings are decoded one by one;
isc evs _ups_coding (x 0, y0, width, height, component) is a function of decoding a point vector index representation string;
if (NumCodedPixel < NumTotalPixel) indicates that if there are more elements in the whole compression unit that have not been decoded yet, the following operations in curly brackets are performed, i.e., decoding one unit base vector string.
CN202111283456.XA 2021-11-01 2021-11-01 Coding and decoding method and device for alternately coding index representation string group and copying upper string Pending CN117319664A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111283456.XA CN117319664A (en) 2021-11-01 2021-11-01 Coding and decoding method and device for alternately coding index representation string group and copying upper string

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111283456.XA CN117319664A (en) 2021-11-01 2021-11-01 Coding and decoding method and device for alternately coding index representation string group and copying upper string

Publications (1)

Publication Number Publication Date
CN117319664A true CN117319664A (en) 2023-12-29

Family

ID=89253969

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111283456.XA Pending CN117319664A (en) 2021-11-01 2021-11-01 Coding and decoding method and device for alternately coding index representation string group and copying upper string

Country Status (1)

Country Link
CN (1) CN117319664A (en)

Similar Documents

Publication Publication Date Title
CN104378644B (en) Image compression method and device for fixed-width variable-length pixel sample string matching enhancement
CN107071450B (en) Coding and decoding method and device for data compression
WO2015120823A1 (en) Image compression method and device using reference pixel storage space in multiple forms
WO2015120818A1 (en) Picture coding and decoding methods and devices
CN104754362B (en) Image compression method using fine-divided block matching
CN111614359B (en) Data encoding method and decoding method using point prediction and frequent occurrence position array
CN107770540B (en) Data compression method and device for fusing multiple primitives with different reference relations
CN107770553B (en) Data compression method and device adopting multiple types of matching parameters and parameter storage addresses
CN111757117B (en) Data encoding and decoding method for performing string prediction on component downsampled format data
CN112637600B (en) Method and device for encoding and decoding data in a lossy or lossless compression mode
CN112565790B (en) Method and device for encoding and decoding string prediction by using minimum base vector mark
CN112040230B (en) Method for encoding a current block of image or video data
CN108989819B (en) Data compression method and device adopting respective corresponding color spaces for modes
CN117319664A (en) Coding and decoding method and device for alternately coding index representation string group and copying upper string
CN117459734A (en) Encoding and decoding method and device with different value ranges of first string number and other string numbers
CN117354376A (en) Coding and decoding method and device adopting unified sequence numbers of matching strings and unmatched elements
CN117319667A (en) Encoding and decoding method and device for encoding length upper limit of unmatched element strings in current block
CN117319665A (en) Encoding and decoding method and device for representing unmatched element strings by aid of point vector index values
CN117319666A (en) Encoding and decoding method and device for taking extra value by using suffix to represent point vector index
CN112532990B (en) String length parameter coding and decoding method and device
CN117336491A (en) Encoding and decoding method and device for increasing maximum value of point vector index value in point prediction
CN113395515B (en) Coding and decoding method and device for point prediction of component down-sampling format data
CN117459735A (en) Encoding and decoding method and device for narrowing value range of point vector index in point prediction
US11082718B2 (en) Method and device for coding image and method and device for decoding image
CN117319663A (en) Encoding and decoding method and device for multiplexing normal-present position with main component coming from point prediction

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination