IMAGE DATA ENCODING AND DECODING
An image encoding apparatus comprises a controller configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and an intra-image predictor configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples; in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
Latest Sony Corporation Patents:
- IMAGE ENCODING DEVICE AND METHOD AND IMAGE DECODING DEVICE AND METHOD
- Method for identifying terminal capabilities in a wireless communication system
- Bone conduction acoustic transmission device
- Method, base station, terminal and communication system for updating component carrier
- Imaging optical system and imaging apparatus
This disclosure relates to image data encoding and decoding.
Description of Related ArtThe “background” description provided herein is for the purpose of generally presenting the context of the disclosure. Work of the presently named inventors, to the extent it is described in this background section, as well as aspects of the description which may not otherwise qualify as prior art at the time of filing, is neither expressly or impliedly admitted as prior art against the present disclosure.
There are several video data encoding and decoding systems which involve transforming video data into a frequency domain representation, quantising the frequency domain coefficients and then applying some form of entropy encoding to the quantised coefficients. This can achieve compression of the video data. A corresponding decoding or decompression technique is applied to recover a reconstructed version of the original video data.
Current video codecs (coder-decoders) such as those used in H.264/MPEG-4 Advanced Video Coding (AVC) achieve data compression primarily by only encoding the differences between successive video frames. These codecs use a regular array of so-called macroblocks, each of which is used as a region of comparison with a corresponding macroblock in a previous video frame, and the image region within the macroblock is then encoded according to the degree of motion found between the corresponding current and previous macroblocks in the video sequence, or between neighbouring macroblocks within a single frame of the video sequence.
High Efficiency Video Coding (HEVC), also known as H.265 or MPEG-H Part 2, is a proposed successor to H.264/MPEG-4 AVC. It is intended for HEVC to improve video quality and double the data compression ratio compared to H.264, and for it to be scalable from 128×96 to 7680×4320 pixels resolution, roughly equivalent to bit rates ranging from 128 kbit/s to 800 Mbit/s.
SUMMARYThe present disclosure addresses or mitigates problems arising from this processing.
Respective aspects and features of the present disclosure are defined in the appended claims.
It is to be understood that both the foregoing general description and the following detailed description are exemplary, but are not restrictive, of the present technology.
A more complete appreciation of the disclosure and many of the attendant advantages thereof will be readily obtained as the same becomes better understood by reference to the following detailed description when considered in connection with the accompanying drawings, wherein:
Referring now to the drawings,
All of the data compression and/or decompression apparatus to be described below may be implemented in hardware, in software running on a general-purpose data processing apparatus such as a general-purpose computer, as programmable hardware such as an application specific integrated circuit (ASIC) or field programmable gate array (FPGA) or as combinations of these. In cases where the embodiments are implemented by software and/or firmware, it will be appreciated that such software and/or firmware, and non-transitory data storage media by which such software and/or firmware are stored or otherwise provided, are considered as embodiments of the present technology.
An input audio/video signal 10 is supplied to a video data compression apparatus 20 which compresses at least the video component of the audio/video signal 10 for transmission along a transmission route 30 such as a cable, an optical fibre, a wireless link or the like. The compressed signal is processed by a decompression apparatus 40 to provide an output audio/video signal 50. For the return path, a compression apparatus 60 compresses an audio/video signal for transmission along the transmission route 30 to a decompression apparatus 70.
The compression apparatus 20 and decompression apparatus 70 can therefore form one node of a transmission link. The decompression apparatus 40 and decompression apparatus 60 can form another node of the transmission link. Of course, in instances where the transmission link is uni-directional, only one of the nodes would require a compression apparatus and the other node would only require a decompression apparatus.
It will be appreciated that the compressed or encoded signal, and a storage medium such as a machine-readable non-transitory storage medium, storing that signal, are considered as embodiments of the present technology.
The techniques to be described below relate primarily to video data compression and decompression. It will be appreciated that many existing techniques may be used for audio data compression in conjunction with the video data compression techniques which will be described, to generate a compressed audio/video signal. Accordingly, a separate discussion of audio data compression will not be provided. It will also be appreciated that the data rate associated with video data, in particular broadcast quality video data, is generally very much higher than the data rate associated with audio data (whether compressed or uncompressed). It will therefore be appreciated that uncompressed audio data could accompany compressed video data to form a compressed audio/video signal. It will further be appreciated that although the present examples (shown in
A combination of
Therefore, the above arrangements provide examples of video storage, capture, transmission or reception apparatuses embodying any of the present techniques.
A controller 343 controls the overall operation of the apparatus and, in particular when referring to a compression mode, controls a trial encoding processes by acting as a selector to select various modes of operation such as block sizes and shapes, and whether the video data is to be encoded losslessly or otherwise. The controller is considered to part of the image encoder or image decoder (as the case may be). Successive images of an input video signal 300 are supplied to an adder 310 and to an image predictor 320. The image predictor 320 will be described below in more detail with reference to
The adder 310 in fact performs a subtraction (negative addition) operation, in that it receives the input video signal 300 on a “+” input and the output of the image predictor 320 on a “−” input, so that the predicted image is subtracted from the input image. The result is to generate a so-called residual image signal 330 representing the difference between the actual and projected images.
One reason why a residual image signal is generated is as follows. The data coding techniques to be described, that is to say the techniques which will be applied to the residual image signal, tend to work more efficiently when there is less “energy” in the image to be encoded. Here, the term “efficiently” refers to the generation of a small amount of encoded data; for a particular image quality level, it is desirable (and considered “efficient”) to generate as little data as is practicably possible. The reference to “energy” in the residual image relates to the amount of information contained in the residual image. If the predicted image were to be identical to the real image, the difference between the two (that is to say, the residual image) would contain zero information (zero energy) and would be very easy to encode into a small amount of encoded data. In general, if the prediction process can be made to work reasonably well such that the predicted image content is similar to the image content to be encoded, the expectation is that the residual image data will contain less information (less energy) than the input image and so will be easier to encode into a small amount of encoded data.
The remainder of the apparatus acting as an encoder (to encode the residual or difference image) will now be described. The residual image data 330 is supplied to a transform unit or circuitry 340 which generates a discrete cosine transform (DCT) representation of blocks or regions of the residual image data. The DCT technique itself is well known and will not be described in detail here. Note also that the use of DCT is only illustrative of one example arrangement. Other transforms which might be used include, for example, the discrete sine transform (DST). A transform could also comprise a sequence or cascade of individual transforms, such as an arrangement in which one transform is followed (whether directly or not) by another transform. The choice of transform may be determined explicitly and/or be dependent upon side information used to configure the encoder and decoder.
The output of the transform unit 340, which is to say, a set of DCT coefficients for each transformed block of image data, is supplied to a quantiser 350. Various quantisation techniques are known in the field of video data compression, ranging from a simple multiplication by a quantisation scaling factor through to the application of complicated lookup tables under the control of a quantisation parameter. The general aim is twofold. Firstly, the quantisation process reduces the number of possible values of the transformed data. Secondly, the quantisation process can increase the likelihood that values of the transformed data are zero. Both of these can make the entropy encoding process, to be described below, work more efficiently in generating small amounts of compressed video data.
A data scanning process is applied by a scan unit 360. The purpose of the scanning process is to reorder the quantised transformed data so as to gather as many as possible of the non-zero quantised transformed coefficients together, and of course therefore to gather as many as possible of the zero-valued coefficients together. These features can allow so-called run-length coding or similar techniques to be applied efficiently. So, the scanning process involves selecting coefficients from the quantised transformed data, and in particular from a block of coefficients corresponding to a block of image data which has been transformed and quantised, according to a “scanning order” so that (a) all of the coefficients are selected once as part of the scan, and (b) the scan tends to provide the desired reordering. One example scanning order which can tend to give useful results is a so-called up-right diagonal scanning order.
The scanned coefficients are then passed to an entropy encoder (EE) 370. Again, various types of entropy encoding may be used. Two examples are variants of the so-called CABAC (Context Adaptive Binary Arithmetic Coding) system and variants of the so-called CAVLC (Context Adaptive Variable-Length Coding) system. In general terms, CABAC is considered to provide a better efficiency, and in some studies has been shown to provide a 10-20% reduction in the quantity of encoded output data for a comparable image quality compared to CAVLC. However, CAVLC is considered to represent a much lower level of complexity (in terms of its implementation) than CABAC. Note that the scanning process and the entropy encoding process are shown as separate processes, but in fact can be combined or treated together. That is to say, the reading of data into the entropy encoder can take place in the scan order. Corresponding considerations apply to the respective inverse processes to be described below.
The output of the entropy encoder 370, along with additional data (mentioned above and/or discussed below), for example defining the manner in which the predictor 320 generated the predicted image, provides a compressed output video signal 380.
However, a return path is also provided because the operation of the predictor 320 itself depends upon a decompressed version of the compressed output data.
The reason for this feature is as follows. At the appropriate stage in the decompression process (to be described below) a decompressed version of the residual data is generated. This decompressed residual data has to be added to a predicted image to generate an output image (because the original residual data was the difference between the input image and a predicted image). In order that this process is comparable, as between the compression side and the decompression side, the predicted images generated by the predictor 320 should be the same during the compression process and during the decompression process. Of course, at decompression, the apparatus does not have access to the original input images, but only to the decompressed images. Therefore, at compression, the predictor 320 bases its prediction (at least, for inter-image encoding) on decompressed versions of the compressed images.
The entropy encoding process carried out by the entropy encoder 370 is considered (in at least some examples) to be “lossless”, which is to say that it can be reversed to arrive at exactly the same data which was first supplied to the entropy encoder 370. So, in such examples the return path can be implemented before the entropy encoding stage. Indeed, the scanning process carried out by the scan unit 360 is also considered lossless, but in the present embodiment the return path 390 is from the output of the quantiser 350 to the input of a complimentary inverse quantiser 420. In instances where loss or potential loss is introduced by a stage, that stage may be included in the feedback loop formed by the return path. For example, the entropy encoding stage can at least in principle be made lossy, for example by techniques in which bits are encoded within parity information. In such an instance, the entropy encoding and decoding should form part of the feedback loop.
In general terms, an entropy decoder 410, the reverse scan unit 400, an inverse quantiser 420 and an inverse transform unit or circuitry 430 provide the respective inverse functions of the entropy encoder 370, the scan unit 360, the quantiser 350 and the transform unit 340. For now, the discussion will continue through the compression process; the process to decompress an input compressed video signal will be discussed separately below.
In the compression process, the scanned coefficients are passed by the return path 390 from the quantiser 350 to the inverse quantiser 420 which carries out the inverse operation of the scan unit 360. An inverse quantisation and inverse transformation process are carried out by the units 420, 430 to generate a compressed-decompressed residual image signal 440.
The image signal 440 is added, at an adder 450, to the output of the predictor 320 to generate a reconstructed output image 460. This forms one input to the image predictor 320, as will be described below.
Turning now to the process applied to decompress a received compressed video signal 470, the signal is supplied to the entropy decoder 410 and from there to the chain of the reverse scan unit 400, the inverse quantiser 420 and the inverse transform unit 430 before being added to the output of the image predictor 320 by the adder 450. So, at the decoder side, the decoder reconstructs a version of the residual image and then applies this (by the adder 450) to the predicted version of the image (on a block by block basis) so as to decode each block. In straightforward terms, the output 460 of the adder 450 forms the output decompressed video signal 480. In practice, further filtering may optionally be applied (for example, by a filter 560 shown in
The apparatus of
There are two basic modes of prediction carried out by the image predictor 320: so-called intra-image prediction and so-called inter-image, or motion-compensated (MC), prediction. At the encoder side, each involves detecting a prediction direction in respect of a current block to be predicted, and generating a predicted block of samples according to other samples (in the same (intra) or another (inter) image). By virtue of the units 310 or 450, the difference between the predicted block and the actual block is encoded or applied so as to encode or decode the block respectively.
(At the decoder, or at the reverse decoding side of the encoder, the detection of a prediction direction may be in response to data associated with the encoded data by the encoder, indicating which direction was used at the encoder. Or the detection may be in response to the same factors as those on which the decision was made at the encoder).
Intra-image prediction bases a prediction of the content of a block or region of the image on data from within the same image. This corresponds to so-called I-frame encoding in other video compression techniques. In contrast to I-frame encoding, however, which involves encoding the whole image by intra-encoding, in the present embodiments the choice between intra- and inter- encoding can be made on a block-by-block basis, though in other embodiments the choice is still made on an image-by-image basis.
Motion-compensated prediction is an example of inter-image prediction and makes use of motion information which attempts to define the source, in another adjacent or nearby image, of image detail to be encoded in the current image. Accordingly, in an ideal example, the contents of a block of image data in the predicted image can be encoded very simply as a reference (a motion vector) pointing to a corresponding block at the same or a slightly different position in an adjacent image.
A technique known as “block copy” prediction is in some respects a hybrid of the two, as it uses a vector to indicate a block of samples at a position displaced from the currently predicted block within the same image, which should be copied to form the currently predicted block.
Returning to
The actual prediction, in the intra-encoding system, is made on the basis of image blocks received as part of the signal 460, which is to say, the prediction is based upon encoded-decoded image blocks in order that exactly the same prediction can be made at a decompression apparatus. However, data can be derived from the input video signal 300 by an intra-mode selector 520 to control the operation of the intra-image predictor 530.
For inter-image prediction, a motion compensated (MC) predictor 540 uses motion information such as motion vectors derived by a motion estimator 550 from the input video signal 300. Those motion vectors are applied to a processed version of the reconstructed image 460 by the motion compensated predictor 540 to generate blocks of the inter-image prediction.
Accordingly, the units 530 and 540 (operating with the estimator 550) each act as detectors to detect a prediction direction in respect of a current block to be predicted, and as a generator to generate a predicted block of samples (forming part of the prediction passed to the units 310 and 450) according to other samples defined by the prediction direction.
The processing applied to the signal 460 will now be described. Firstly, the signal is optionally filtered by a filter unit 560, which will be described in greater detail below. This involves applying a “deblocking” filter to remove or at least tend to reduce the effects of the block-based processing carried out by the transform unit 340 and subsequent operations. A sample adaptive offsetting (SAO) filter may also be used. Also, an adaptive loop filter is optionally applied using coefficients derived by processing the reconstructed signal 460 and the input video signal 300. The adaptive loop filter is a type of filter which, using known techniques, applies adaptive filter coefficients to the data to be filtered. That is to say, the filter coefficients can vary in dependence upon various factors. Data defining which filter coefficients to use is included as part of the encoded output data-stream.
The filtered output from the filter unit 560 in fact forms the output video signal 480 when the apparatus is operating as a decompression apparatus. It is also buffered in one or more image or frame stores 570; the storage of successive images is a requirement of motion compensated prediction processing, and in particular the generation of motion vectors. To save on storage requirements, the stored images in the image stores 570 may be held in a compressed form and then decompressed for use in generating motion vectors. For this particular purpose, any known compression / decompression system may be used. The stored images are passed to an interpolation filter 580 which generates a higher resolution version of the stored images; in this example, intermediate samples (sub-samples) are generated such that the resolution of the interpolated image is output by the interpolation filter 580 is 4 times (in each dimension) that of the images stored in the image stores 570 for the luminance channel of 4:2:0 and 8 times (in each dimension) that of the images stored in the image stores 570 for the chrominance channels of 4:2:0. The interpolated images are passed as an input to the motion estimator 550 and also to the motion compensated predictor 540.
The way in which an image is partitioned for compression processing will now be described. At a basic level, an image to be compressed is considered as an array of blocks or regions of samples. The splitting of an image into such blocks or regions can be carried out by a decision tree, such as that described in Bross et al: “High Efficiency Video Coding (HEVC) text specification draft 6”, JCTVC-H1003_d0 (November 2011), the contents of which are incorporated herein by reference. In some examples, the resulting blocks or regions have sizes and, in some cases, shapes which, by virtue of the decision tree, can generally follow the disposition of image features within the image. This in itself can allow for an improved encoding efficiency because samples representing or following similar image features would tend to be grouped together by such an arrangement. In some examples, square blocks or regions of different sizes (such as 4x4 samples up to, say, 64x64 or larger blocks) are available for selection. In other example arrangements, blocks or regions of different shapes such as rectangular blocks (for example, vertically or horizontally oriented) can be used. Other non-square and non-rectangular blocks are envisaged. The result of the division of the image into such blocks or regions is (in at least the present examples) that each sample of an image is allocated to one, and only one, such block or region.
The intra-prediction process will now be discussed. In general terms, intra-prediction involves generating a prediction of a current block of samples from previously-encoded and decoded samples in the same image.
In some examples, the image is encoded on a block by block basis such that larger blocks (referred to as coding units or CUs) are encoded in an order such as the order discussed with reference to
The block 810 represents a CU; as discussed above, for the purposes of intra-image prediction processing, this may be subdivided into a set of smaller units. An example of a current TU 830 is shown within the CU 810. More generally, the picture is split into regions or groups of samples to allow efficient coding of signalling information and transformed data. The signalling of the information may require a different tree structure of sub-divisions to that of the transform, and indeed that of the prediction information or the prediction itself. For this reason, the coding units may have a different tree structure to that of the transform blocks or regions, the prediction blocks or regions and the prediction information. In some examples such as HEVC the structure can be a so-called quad tree of coding units, whose leaf nodes contain one or more prediction units and one or more transform units; the transform units can contain multiple transform blocks corresponding to luma and chroma representations of the picture, and prediction could be considered to be applicable at the transform block level. In examples, the parameters applied to a particular group of samples can be considered to be predominantly defined at a block level, which is potentially not of the same granularity as the transform structure.
The intra-image prediction takes into account samples coded prior to the current TU being considered, such as those above and/or to the left of the current TU. Source samples, from which the required samples are predicted, may be located at different positions or directions relative to the current TU. To decide which direction is appropriate for a current prediction unit, the mode selector 520 of an example encoder may test all combinations of available TU structures for each candidate direction and select the prediction direction and TU structure with the best compression efficiency.
The picture may also be encoded on a “slice” basis. In one example, a slice is a horizontally adjacent group of CUs. But in more general terms, the entire residual image could form a slice, or a slice could be a single CU, or a slice could be a row of CUs, and so on. Slices can give some resilience to errors as they are encoded as independent units. The encoder and decoder states are completely reset at a slice boundary. For example, intra-prediction is not carried out across slice boundaries; slice boundaries are treated as image boundaries for this purpose.
In general terms, after detecting a prediction direction, the systems are operable to generate a predicted block of samples according to other samples defined by the prediction direction. In examples, the image encoder is configured to encode data identifying the prediction direction selected for each sample or region of the image.
In
As mentioned, the reference samples comprise at least two linear arrays in respective orientations with respect to the current image region of samples to be predicted. For example, the linear arrays may be an array or row 1420 of samples above the block of samples to be predicted and an array or column 1430 of samples to the left of the block of samples to be predicted.
As discussed above with reference to
A sample projection process is used to project at least some of the reference samples to different respective positions with respect to the current image region, in the manner shown in
One reason why projection of this nature is carried out is to reduce the complexity of the intra prediction process, in that all of the samples to be predicted are then referencing a single linear array of reference samples, rather than referencing two orthogonal linear arrays.
In embodiments, the same projection process is carried out in the decoder and in the encoder, so that the predicted samples are the same in each instance.
Possible variations in operation between the use of prediction modes which will be referred to as “straight modes” and prediction modes which will be referred to as “curved modes” will now be discussed.
The type of prediction modes shown schematically in, for example,
Therefore
As further background to the explanation of straight and curved prediction modes,
A system of (x, y) coordinates is used for convenience, to allow individual reference or predicted sample positions to be identified. In the example of
In the example of
Each of the samples to be predicted 1900 is predicted as follows. For each sample to be predicted, there is an associated (x, y) location such as a location (0, 5) for a sample 1970 or a location (0, 4) for a sample 1972. These two samples are used purely by way of example and the same technique applies to each of the samples 1900 to be predicted.
The sample positions of the samples 1970, 1972 to be predicted are mapped according to the direction 1950 associated with the current prediction mode to respective locations or reference positions 1974, 1976 among the reference samples. This mapping may be carried out using an expression such as that shown below, noting that this is a linear expression with respect to the coordinate system (x, y):
For horizontal modes 2-17 in the notation of
predicted value(x. y)={1−f(p)}×ref[y+i(p)]+f(p)×ref[y+i(p)+1] with p=A×(x+1)
For vertical modes 18-34 in the notation of
predicted value(x. y)={1−f(p)}×ref[x+i(p)]+f(p)×ref[x+i(p)+1] with p=A×(y+1)
and where i(p)=floor(p), is the value p rounded down (towards negative infinity) to the nearest integer, f(p)=p−i(p) represents the fractional part of the value p.
A is an angle parameter indicating the angle of the current mode. To illustrate, for example, for a horizontal or vertical line, A would be 0; for a 45° diagonal line, A would be ±1.
Those skilled in the art would appreciate that integer approximations can be used to simplify the linear equations, for example, representing the angle parameter A as a fractional fixed-precision number. In HEVC, the angles have an accuracy of 5 fractional bits.
In example arrangements, the reference position 1974, 1976 is detected to an accuracy or resolution of less than one sample, which is to say with reference to the reference sample locations (−5, −1) . . . (15, −1), a fractional value is used for the x coordinate of the reference position within the projected set of reference samples 1920. For example, the reference position could be detected to a resolution of 1/32 of a sample separation, so that the x coordinate of the reference positions 1974, 1976 is identified to that resolution. The y coordinate of the reference position is −1 in each case, but this is in fact irrelevant to the calculations that then take place, which relate to interpolation along the x axis of the reference samples 1920.
The prediction of the predicted values 1970, 1972 is an interpolation of the value applicable to the detected x coordinate of the reference sample position 1974, 1976, for example as described above in the formulae shown earlier.
A similar arrangement is shown schematically in
In the case of a generally horizontal mode, as discussed above, the projection circuitry shown in
Using the background discussed with
The intra mode selector 520 the selector may be configured to perform at least a partial encoding to select the prediction mode.
Taking the direction 2150 of the currently selected prediction mode into account, the positions of the samples 2120, 2130, 2140 to be predicted are mapped using the techniques described above to reference positions 2160, 2170, 2180 amongst the reference samples 2190 associated with the current block or region 2100. As discussed before, these reference positions 2160, 2170, 2180 can be expressed to a sub-sample resolution such as 1/32 samples in the x direction with respect to the reference samples 2190.
In each case, an angle 2122, 2132, 2142 which defines the direction or angle between the reference position 2160 . . . 2180 and the position 2120 . . . 2140 of the sample to be predicted, is the same. In other words it is independent of the location within the block or region 2100 of the sample to be predicted. This feature, that the angles 2122 . . . 2142 are all the same for each sample to be predicted within the block 2100, stems from the linear expression described above used to describe the reference position within the reference samples 2190.
In general for a curved mode, each sample to be predicted is associated with a coordinate position within the current region 2200, and an array or reference position is detected within the set or array of reference samples 2290 as a function of the coordinate position of a given sample to be predicted, with the function depending upon the selected prediction mode. For a curved mode, the function of the coordinate position of that sample to be predicted is a non-linear function.
Examples of suitable non-linear functions for use to define curved prediction modes are as follows:
-
- position=r*tan(angle)
- position=(r*r/5)*tan(angle)
where r=row number for vertical modes, for an example block size of 16×16 (the factor of 5 could change for other block sizes)
An analytical function of this nature is not a requirement; instead, a look-up table linking the location of the sample to predicted (or groups or classifications of locations) to reference position could be used. In examples, a different look-up table could be employed for each block size.
Therefore, in these examples, each sample to be predicted is associated with a coordinate position within the current region; and the detector (of the intra predictor 530) is configured to detect the array position for a given sample to be predicted as a function of the coordinate position of the given sample to be predicted, the function depending upon the selected prediction mode. For example, for a curved mode, the function of the coordinate position of that sample to be predicted is a non-linear function. In examples, the non-linear function may be dependent upon a location of the current region within the current image, for example to correspond to a type of distortion known or detected to be present in the image, and similarly the set of prediction modes may be dependent upon a location of the current region within the current image, again for example to correspond to a type of distortion known or detected to be present in the image.
Referring to
Some video encoding or decoding systems provide a so-called reference sample substitution process in which the samples 2420 are replaced (when unavailable) by, for example, repetitions of a nearest available reference sample such as a sample 2430. However, in techniques to be discussed below, the set of prediction modes from which a mode applicable to the current region 2400 can be selected is varied to account for the non-availability of the samples 2420. For example, a set of prediction modes 2440 may be considered to be less useful in the situation that the samples 2420 are unavailable, since the information obtained by predicting according to one of the prediction modes 2440 may be very limited, for example being based purely upon the sample value of the reference samples 2440 for a large number of samples to be predicted in the block 2400.
In
for samples 0 to m (being an arbitrary group of m+1 samples, of a group such as the groups 2510, 2520, 2512, 2514, 2524, 2526 or the like), where p is a sample value such as a luminance value:
Let deltam=pm−1−pm
It is appreciated that, to reduce complexity of the calculation, the sum of the squares is often replaced with a sum of the absolute values, and the square root operation can also be removed.
In the example situation shown in
Example embodiments to be discussed below make use of a controller (for example, embodied by the intra mode selector and/or as discussed with reference to
Example arrangements will now be discussed with reference to
In
In terms of the modes of the original set retained under the current process, in the present example of reference samples 2510 above the current block 2500 having a higher activity, those modes from the upper left diagonal mode 2600 (mode 18 in the representation of
However, an optional exception to this arrangement is to retain a horizontal mode 2620 (mode number 10 in the representation of
The process described so far leads to the generation or selection of a set of candidate prediction directions as a subset of the (full) set of prediction directions, for use in respect of a current image region. This technique in itself can potentially lead to more efficient coding because fewer mode numbers need to be encoded and so, potentially, fewer bits can be used to encode the mode numbers.
However, in other example arrangements, so-called additional modes are also used.
Examples of additional modes (such as an additional mode 2640 in
So, in
In
This arrangement can be implemented by using a mapping between the original mode numbers for these modes not retained in the candidate subset and the additional modes, for example as shown in the following table, which uses an example notation based upon the numbering of
So, the subsets of candidate modes derived in the examples of
As shown in
In particular, in the example of
In embodiments where multiple groups of reference samples are available, the groups could be examined to select the available mode. For example, if there were multiple rows of reference samples available, the rows could be correlated to steer the availability of modes. For curved modes, the multiple lines of reference samples could be used to steer the curvature at the edge, and the intra prediction mode be used to steer the average angle for the block. For straight modes, one row could be projected onto the other for the specified intra prediction mode and at sub-fractional offsets to that prediction mode, with the sub-fractional (or zero) offset selected depending on how the two rows correlate. For the latter case, since there is often a tendency for the transform/quantisation process to steer the residual to the orthogonal direction, the sub-fractional offsets may be better to be biased towards a particular side of the default mode, rather than evenly about it
The reference samples with the higher (or highest) activity could lead to only prediction directions pointing in that or those directions being made available in the candidate modes. In other examples, a subset (such as alternate) prediction modes could be excluded in the “lower activity” direction and optionally additional modes could be inserted in the “higher activity” direction. This arrangement provides an example in which the one or more properties represent at least image activity of the group of reference samples; and the selection of the subset of the prediction directions is weighted towards reference samples in the group of reference samples having higher image activity. More generally, the one or more properties can represent at least one from the list consisting of: image activity of the group of reference samples, the selection of the subset of the prediction directions being weighted towards reference samples in the group of reference samples having higher image activity; and position of the current image region within a picture. For example, if there would be a need to extrapolate or repeat reference samples because the set of reference samples in use extend beyond a current decoded region and/or have not been buffered, then the set of candidate modes can be predominantly including those pointing to reference samples which are not extrapolated or repeated. the position within a picture or image portion such as a slice can have a similar effect on availability of reference samples, so that (for example) some of the reference sample positions may fall outside the current picture or image portion by virtue of the position of the block, so that once again the set of candidate modes is steered towards reference samples which actually exist. In some example, modes which point to reference samples outside the current coding tree unit are removed from the set of modes available for use.
As mentioned above, the operation of the selector could simply be to choose a subset of the original full set of modes as the candidate set of prediction directions. However, in other examples, the selector could include functionalities as shown in
In some example arrangements, so-called most probable modes are derived from the modes applicable to previously encoded/decoded blocks. The aim of this process is that (a) the derivation of MPMs can be carried out in an identical manner at the encoder during encoding, and at the decoder during decoding, so that both are dealing with the same MPMs for any particular sample, (b) if the image content is similar between the current block and the previously encoded blocks from which the MPMs were derived, there is at least a good chance that samples of the current block will also use an MPM, and (c) a MPM can be encoded with a potentially smaller amount of data in the bit-stream, compared with an arbitrary one of the full set of MPMs. Therefore, for a sample of a current block, a shorter amount of data can be used to encode the chosen mode if it is an MPM derived from one or more previously (for example, preceding) encoded blocks. This is because a short data code can be used to indicate simply that “this sample is using the most probable mode derived by the pre-configured process from the previous blocks” rather than having to specify one mode amongst a group of, for example, 67 modes. So, given that mode selection is often similar within image regions, this can provide an overall saving in bit-rate.
The term “most probable mode” is one used in the art, and is therefore employed here for convenience. “More commonly used mode” would be another possible term for use in connection with these modes. The term MPM does not imply an absolute highest probability that a mode derived from preceding samples will be the most likely to be selected for a particular sample. However, so-called MPMs tend to be modes which are commonly used for preceding samples, or are derived from modes which are commonly used for preceding samples, and so there is generally a higher likelihood that they will be applicable to a current sample.
It is also noted that more than one MPM can be derived. The term “MPM” does not imply that the (more than one) modes are equally most likely, but as a set of two or more MPMs, they are intended to have an increased likelihood of being applicable to the current sample.
In the present examples, the controller is configured to detect, as further candidate prediction directions, one or more likely prediction directions in response to those commonly used for one or more previously encoded image regions and to encode the data identifying the prediction direction as either: (i) data indicating that the prediction direction is a detected likely prediction direction, or (ii) data identifying the prediction direction amongst the remaining candidate prediction directions.
The intra mode selector 520 also provides information relating to the selected mode (as information 3260 to the controller 343). The controller 343 can also receive information 3270 from the candidate mode selector 3210 defining the selection of candidate modes and/or any mapping between additional modes and non-used original modes. The controller 343 encodes information 3280 for inclusion in the encoded data, to represent the mode selector by the intra selector and/or any mapping performed by the candidate mode selector.
a controller (343, 2900, 2910, 3000, 3020) configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and
an intra-image predictor (530) configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples;
in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
For example, the controller may be configured to encode data identifying the prediction direction selected for each sample or region of the image.
a controller (343, 2900, 2910, 3000, 3020) configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and
an intra-image predictor (530) configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples;
in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
For example, the controller may be configured to detect encoded data identifying the prediction direction selected for each sample or region of the image.
selecting (at a step 3400), from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region;
selecting (at a step 3410) a prediction direction for the current image region from the set of candidate prediction directions; and
intra-image predicting (at a step 3420) samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples.
selecting (at a step 3500), from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region;
selecting (at a step 3510) a prediction direction for the current image region from the set of candidate prediction directions; and
intra-image predicting (at a step 3520) samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples.
selecting (at a step 3600), from a set of prediction modes, a prediction mode for prediction of a current region of a current image; and
intra-image predicting (at a step 3610) samples of the current region with respect to one or more of the group of reference samples of the same image according to a prediction direction, defined by the selected prediction mode, between a current sample to be predicted and a reference position amongst the reference samples;
in which the set of prediction modes comprises at least one curved prediction mode defining a prediction direction having an angle between the current sample and the reference position which varies with a location, within the current region, of the current sample to be predicted.
The apparatus of
a controller configured to select, from a set of prediction modes, a prediction mode for prediction of a current region of a current image; and
an intra-image predictor configured to predict samples of the current region with respect to one or more of the group of reference samples of the same image according to a prediction direction, defined by the selected prediction mode, between a current sample to be predicted and a reference position amongst the reference samples;
in which the set of prediction modes comprises at least one curved prediction mode defining a prediction direction having an angle between the current sample and the reference position which varies with a location, within the current region, of the current sample to be predicted.
selecting (at a step 3700), from a set of prediction modes, a prediction mode for prediction of a current region of a current image; and
intra-image predicting (at a step 3710) samples of the current region with respect to one or more of the group of reference samples of the same image according to a prediction direction, defined by the selected prediction mode, between a current sample to be predicted and a reference position amongst the reference samples;
in which the set of prediction modes comprises at least one curved prediction mode defining a prediction direction having an angle between the current sample and the reference position which varies with a location, within the current region, of the current sample to be predicted.
The apparatus of
a controller configured to select, from a set of prediction modes, a prediction mode for prediction of a current region of a current image; and
an intra-image predictor configured to predict samples of the current region with respect to one or more of the group of reference samples of the same image according to a prediction direction, defined by the selected prediction mode, between a current sample to be predicted and a reference position amongst the reference samples;
in which the set of prediction modes comprises at least one curved prediction mode defining a prediction direction having an angle between the current sample and the reference position which varies with a location, within the current region, of the current sample to be predicted.
In so far as embodiments of the disclosure have been described as being implemented, at least in part, by software-controlled data processing apparatus, it will be appreciated that a non-transitory machine-readable medium carrying such software, such as an optical disk, a magnetic disk, semiconductor memory or the like, is also considered to represent an embodiment of the present disclosure. Similarly, a data signal comprising coded data generated according to the methods discussed above (whether or not embodied on a non-transitory machine-readable medium) is also considered to represent an embodiment of the present disclosure.
It will be apparent that numerous modifications and variations of the present disclosure are possible in light of the above teachings. It is therefore to be understood that within the scope of the appended clauses, the technology may be practised otherwise than as specifically described herein.
Respective aspects and features are defined by the following numbered clauses:
- 1. An image encoding apparatus comprising:
a controller configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and
an intra-image predictor configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples;
in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
- 2. Apparatus according to clause 1, in which the one or more properties represent at least one from the list consisting of:
- i. image activity of the group of reference samples, the selection of the subset of the prediction directions being weighted towards reference samples in the group of reference samples having higher image activity;
- ii. position of the current image region within a picture; and
- iii. availability of reference samples for prediction of the current image region.
- 3. Apparatus according to clause 1 or clause 2, in which the controller is configured to supplement the set of candidate prediction directions with one or more additional prediction directions not forming part of the set of prediction directions.
- 4. Apparatus according to clause 3, in which:
the set of prediction directions each have associated direction identifiers; and
the controller is configured to assign the one or more additional prediction directions to respective direction identifiers associated with prediction directions which are in the set of prediction directions but not in the subset of prediction directions.
- 5. Apparatus according to clause 3 or clause 4, in which the one or more additional prediction directions comprise one or more of:
(i) a prediction direction lying between a respective pair of prediction directions in the set of candidate prediction directions; and
(ii) a prediction direction having an angle, between a current sample to be predicted and a reference position amongst the reference samples, which varies with a location, within the current region, of the current sample to be predicted.
- 6. Apparatus according to any one of the preceding clauses, in which the set of candidate prediction directions includes at least a horizontal prediction direction and a vertical prediction direction.
- 7. Apparatus according to any one of the preceding clauses, in which the controller is configured to encode data identifying the prediction direction selected for each sample or region of the image.
- 8. Apparatus according to clause 7, in which the controller is configured to detect, as further candidate prediction directions, one or more likely prediction directions in response to those commonly used for one or more previously encoded image regions and to encode the data identifying the prediction direction as either: (i) data indicating that the prediction direction is a detected likely prediction direction, or (ii) data identifying the prediction direction amongst the remaining candidate prediction directions.
- 9. Video storage, capture, transmission or reception apparatus comprising apparatus according to any one of the preceding clauses.
- 10. An image decoding apparatus comprising:
a controller configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and
an intra-image predictor configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples;
in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
- 11. Apparatus according to clause 10, in which the one or more properties represent at least one from the list consisting of:
1i. image activity of the group of reference samples, the selection of the subset of the prediction directions being weighted towards reference samples in the group of reference samples having higher image activity;
-
- ii. position of the current image region within a picture;
- iii. availability of reference samples for prediction of the current image region.
- 12. Apparatus according to clause 10 or clause 11, in which the controller is configured to supplement the set of candidate prediction directions with one or more additional prediction directions not forming part of the set of prediction directions.
- 13. Apparatus according to clause 12, in which:
the set of prediction directions each have associated direction identifiers; and
the controller is configured to assign the one or more additional prediction directions to respective direction identifiers associated with prediction directions which are in the set of prediction directions but not in the subset of prediction directions.
- 14. Apparatus according to clause 12, in which the one or more additional prediction directions comprise one or more of:
(i) a prediction direction lying between a respective pair of prediction directions in the set of candidate prediction directions; and
(ii) a prediction direction having an angle, between a current sample to be predicted and a reference position amongst the reference samples, which varies with a location, within the current region, of the current sample to be predicted.
- 15. Apparatus according to any one of clauses 10 to 14, in which the set of candidate prediction directions includes at least a horizontal prediction direction and a vertical prediction direction.
- 16. Apparatus according to any one of clauses 10 to 15, in which the controller is configured to detect encoded data identifying the prediction direction selected for each sample or region of the image.
- 17. Apparatus according to clause 16, in which the controller is configured to detect, as further candidate prediction directions, one or more likely prediction directions in response to those commonly used for one or more previously encoded image regions and to encode the data identifying the prediction direction as either: (i) data indicating that the prediction direction is a detected likely prediction direction, or (ii) data identifying the prediction direction amongst the remaining candidate prediction directions.
- 18. Video storage, capture, transmission or reception apparatus comprising apparatus according to any one of clauses 10 to 17.
- 19. An image encoding method comprising:
selecting, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region;
selecting a prediction direction for the current image region from the set of candidate prediction directions; and
intra-image predicting samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples.
- 20. Computer software which, when executed by a computer, causes the computer to carry out a method according to clause 19.
- 21. A machine-readable non-transitory storage medium which stores software according to clause 20.
- 22. An image decoding method comprising:
selecting, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region;
selecting a prediction direction for the current image region from the set of candidate prediction directions; and
intra-image predicting samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples.
- 23. Computer software which, when executed by a computer, causes the computer to carry out a method according to clause 22.
- 24. A machine-readable non-transitory storage medium which stores software according to clause 23.
- 25. A data signal comprising coded data generated according to the method of clause 19.
- 26. A video capture apparatus comprising an image sensor and the encoding apparatus of any one of clauses 1-8, decoding apparatus of any one of clauses 10-17 and a display to which the decoded images are output.
Claims
1-25. (canceled)
26. An image encoding apparatus comprising:
- a controller configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and
- an intra-image predictor configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples;
- in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
27. The apparatus according to claim 26, in which the one or more properties represent at least one from the list consisting of:
- i. image activity of the group of reference samples, the selection of the subset of the prediction directions being weighted towards reference samples in the group of reference samples having higher image activity;
- ii. position of the current image region within a picture; and
- iii. availability of reference samples for prediction of the current image region.
28. The apparatus according to claim 26, in which the controller is configured to supplement the set of candidate prediction directions with one or more additional prediction directions not forming part of the set of prediction directions.
29. The apparatus according to claim 28, in which:
- the set of prediction directions each have associated direction identifiers; and
- the controller is configured to assign the one or more additional prediction directions to respective direction identifiers associated with prediction directions which are in the set of prediction directions but not in the subset of prediction directions.
30. The apparatus according to claim 28, in which the one or more additional prediction directions comprise one or more of:
- (i) a prediction direction lying between a respective pair of prediction directions in the set of candidate prediction directions; and
- (ii) a prediction direction having an angle, between a current sample to be predicted and a reference position amongst the reference samples, which varies with a location, within the current region, of the current sample to be predicted.
31. The apparatus according to claim 26, in which the set of candidate prediction directions includes at least a horizontal prediction direction and a vertical prediction direction.
32. The apparatus according to claim 26, in which the controller is configured to encode data identifying the prediction direction selected for each sample or region of the image.
33. The apparatus according to claim 32, in which the controller is configured to detect, as further candidate prediction directions, one or more likely prediction directions in response to those commonly used for one or more previously encoded image regions and to encode the data identifying the prediction direction as either: (i) data indicating that the prediction direction is a detected likely prediction direction, or (ii) data identifying the prediction direction amongst the remaining candidate prediction directions.
34. Video storage, capture, transmission or reception apparatus comprising apparatus according to claim 26.
35. An image decoding apparatus comprising:
- a controller configured to select, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region; and
- an intra-image predictor configured to predict samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples;
- in which the intra-image predictor is configured to select the prediction direction for the current image region from the set of candidate prediction directions.
36. The apparatus according to claim 35, in which the one or more properties represent at least one from the list consisting of:
- i. image activity of the group of reference samples, the selection of the subset of the prediction directions being weighted towards reference samples in the group of reference samples having higher image activity;
- ii. position of the current image region within a picture;
- iii. availability of reference samples for prediction of the current image region.
37. The apparatus according to claim 35, in which the controller is configured to supplement the set of candidate prediction directions with one or more additional prediction directions not forming part of the set of prediction directions.
38. The apparatus according to claim 37, in which:
- the set of prediction directions each have associated direction identifiers; and
- the controller is configured to assign the one or more additional prediction directions to respective direction identifiers associated with prediction directions which are in the set of prediction directions but not in the subset of prediction directions.
39. The apparatus according to claim 37, in which the one or more additional prediction directions comprise one or more of:
- (i) a prediction direction lying between a respective pair of prediction directions in the set of candidate prediction directions; and
- (ii) a prediction direction having an angle, between a current sample to be predicted and a reference position amongst the reference samples, which varies with a location, within the current region, of the current sample to be predicted.
40. The apparatus according to claim 35, in which the controller is configured to detect encoded data identifying the prediction direction selected for each sample or region of the image.
41. The apparatus according to claim 42, in which the controller is configured to detect, as further candidate prediction directions, one or more likely prediction directions in response to those commonly used for one or more previously encoded image regions and to encode the data identifying the prediction direction as either: (i) data indicating that the prediction direction is a detected likely prediction direction, or (ii) data identifying the prediction direction amongst the remaining candidate prediction directions.
42. Video storage, capture, transmission or reception apparatus comprising apparatus according to claim 35.
43. An image encoding method comprising:
- selecting, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region;
- selecting a prediction direction for the current image region from the set of candidate prediction directions; and
- intra-image predicting samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples.
44. An image decoding method comprising:
- selecting, from a set of prediction directions, a set of candidate prediction directions as a subset of the set of prediction directions, for a current image region of a current image in dependence upon one or more properties of a group of reference samples of the current image applicable to the current image region;
- selecting a prediction direction for the current image region from the set of candidate prediction directions; and
- intra-image predicting samples of the current image region with respect to one or more of the group of reference samples of the same image according to a prediction direction between the current sample and a reference position amongst the reference samples.
45. A non-transitory computer readable medium including computer program instructions, which when executed by a computer causes the computer to perform the method of claim 44.
Type: Application
Filed: Oct 24, 2018
Publication Date: Aug 13, 2020
Applicant: Sony Corporation (Tokyo)
Inventors: Stephen Mark KEATING (Basingstoke), Karl James SHARMAN (Basingstoke), Magali Kimlee Miri PHILIPPE (Basingstoke)
Application Number: 16/756,030