Login| Sign Up| Help| Contact|

Patent Searching and Data


Title:
HIGH THROUGHPUT CABAC
Document Type and Number:
WIPO Patent Application WO/2020/260878
Kind Code:
A1
Abstract:
Image data encoding apparatus comprises a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol; the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controller comprising: a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and a data router configured to route each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

Inventors:
KEATING STEPHEN MARK (GB)
SHARMAN KARL JAMES (GB)
BROWNE ADRIAN RICHARD (GB)
Application Number:
PCT/GB2020/051536
Publication Date:
December 30, 2020
Filing Date:
June 24, 2020
Export Citation:
Click for automatic bibliography generation   Help
Assignee:
SONY CORP (JP)
SONY EUROPE BV (GB)
International Classes:
H04N19/13
Foreign References:
US20190020877A12019-01-17
Other References:
BROWNE (SONY) A ET AL: "Switching between CABAC context coded bins and EP coded bins", no. JVET-O0519, 25 June 2019 (2019-06-25), XP030219793, Retrieved from the Internet [retrieved on 20190625]
JVT: "Text of Joint FCD for Joint Video Specification", 4. JVT MEETING; 61. MPEG MEETING; 22-07-2002 - 26-07-2002; KLAGENFURT,AT; (JOINT VIDEO TEAM OF ISO/IEC JTC1/SC29/WG11 AND ITU-T SG.16 ),, no. JVT-D157, 26 July 2002 (2002-07-26), XP030005420
JIN HEO ET AL: "Efficient Differential Pixel Value Coding in CABAC for H.264/AVC Lossless Video Compression", CIRCUITS, SYSTEMS & SIGNAL PROCESSING, BIRKHÄUSER-VERLAG, BO, vol. 31, no. 2, 27 July 2011 (2011-07-27), pages 813 - 825, XP035020281, ISSN: 1531-5878, DOI: 10.1007/S00034-011-9338-1
CHEN YU-HSIN ET AL: "A Deeply Pipelined CABAC Decoder for HEVC Supporting Level 6.2 High-Tier Applications", IEEE TRANSACTIONS ON CIRCUITS AND SYSTEMS FOR VIDEO TECHNOLOGY, INSTITUTE OF ELECTRICAL AND ELECTRONICS ENGINEERS, US, vol. 25, no. 5, 1 May 2015 (2015-05-01), pages 856 - 868, XP011580042, ISSN: 1051-8215, [retrieved on 20150501], DOI: 10.1109/TCSVT.2014.2363748
PENG ZHANG ET AL: "Variable-Bin-Rate CABAC Engine for H.264/AVC High Definition Real-Time Decoding", IEEE TRANSACTIONS ON VERY LARGE SCALE INTEGRATION (VLSI) SYSTEMS, IEEE SERVICE CENTER, PISCATAWAY, NJ, USA, vol. 17, no. 3, 1 March 2009 (2009-03-01), pages 417 - 426, XP011249867, ISSN: 1063-8210, DOI: 10.1109/TVLSI.2008.2005286
BROSS ET AL.: "High Efficiency Video Coding (HEVC) text specification draft 6", JCTVC-H1003_DO, November 2011 (2011-11-01)
WD4: WORKING DRAFT 4 OF HIGH-EFFICIENCY VIDEO CODING, JCTVC-F803_D5, DRAFT ISO/IEC 23008-HEVC; 201X(E, 28 October 2011 (2011-10-28)
BROSS ET AL.: "Versatile Video Coding (Draft 5", JVET-N1001-V10, July 2019 (2019-07-01)
Attorney, Agent or Firm:
TURNER, James (GB)
Download PDF:
Claims:
CLAIMS

1. Image data encoding apparatus, comprising:

a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

the controller comprising:

a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

a data router configured to route each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

2. The image data encoding apparatus of claim 1 , in which the first data encoder is a context adaptive binary arithmetic coding (CABAC) encoder.

3. The image data encoding apparatus of claim 1 , in which the second data encoder is a bypass encoder.

4. The image data encoding apparatus of claim 3, in which the second data encoder is a binary arithmetic coder using a fixed 50% probability context model.

5. The image data encoding apparatus of claim 1 , in which the output data unit is an independently decodable data unit.

6. The image data encoding apparatus of claim 5, in which the image portion is one of a picture, slice or tile.

7. The image data encoding apparatus of claim 6, in which the constraint is defined by:

N <= K1 * B + (K2 * CU) in which:

N = number of binarized symbols in the output data unit;

K1 is a constant;

B = number of encoded bytes for the output data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data encoding apparatus; and

CU = size of the picture, slice or tile represented by the output data unit expressed as a number of coding units of minimum size.

8. The image data encoding apparatus of claim 7, in which the apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to generate a tier parameter defining the currently selected encoding tier, at least the constant K1 being dependent upon the tier parameter.

9. The image data encoding apparatus of claim 1 , in which the apparatus is configured to encode image data as successive linear arrays of image blocks, image data of a given image block being encoded once image data in a previously encoded linear array, on which the encoding of the given image block depends, has been encoded.

10. The image data encoding apparatus of claim 9, in which the apparatus comprises multiple instances of the first data encoder and the second data encoder, configured to concurrently encode two or more of the linear arrays of image blocks.

11. The image data encoding apparatus of claim 9, in which each linear array of image blocks is an image portion represented by a respective output data unit.

12. The image data encoding apparatus of claim 1 , comprising:

a detector configured to detect, at a predetermined stage relative to the encoding of a current output data unit, whether the constraint will be met by the current output data unit; and a padding data generator configured to generate and insert in the current output data unit sufficient padding data so that the output data unit including the inserted padding data meets the constraint.

13. The image data encoding apparatus of claim 12, in which the predetermined stage is the end of encoding the current output data unit.

14. The image data encoding apparatus of claim 1 , in which: each symbol is associated with a default data encoder of the first data encoder and the second data encoder;

the data router is configured to selectively invert the default association so as to route symbols associated with one of the first and second data encoders to the other of the first and second data encoders.

15. The image data encoding apparatus of claim 14, in which:

within an image portion, the apparatus is configured to encode symbols representing plural sub-regions; and

the data router is configured to apply or disapply the selective inversion of the default association in respect of entire sub-regions.

16. The image data encoding apparatus of claim 15, in which:

the image portion comprises one of a picture, a slice and a tile.

17. The image data encoding apparatus of claim 15, in which:

the sub-regions comprise one or more of coding tree units, coding units, transform units and sub-portions of transform units.

18. The image data encoding apparatus of claim 17, in which the predictor is configured to generate the prediction in respect of a processing stage at a given boundary between a pair of adjacently processed sub-regions.

19. The image data encoding apparatus of claim 18, in which the data router is configured to apply the prediction to control selective inversion of the default association for a next sub-region to be processed starting from the given boundary.

20. The image data encoding apparatus of claim 18, in which the data router is configured to apply the prediction to control selective inversion of the default association for a subsequent sub-region to be processed starting from a further boundary between sub-regions following, in a sub-region processing order, the given boundary.

21. The image data encoding apparatus of claim 20, in which the further boundary is a boundary next following, in a sub-region processing order, the given boundary.

22. The image data encoding apparatus of claim 15, in which the predictor is configured to allocate a respective share of the upper limit to each sub-region and to generate a prediction in respect of each sub-region.

23. The image data encoding apparatus of claim 22, in which the predictor is configured to vary the allocation of respective shares of the upper limit to each sub-region so that, for an earlier-encoded and a later-encoded sub-region of an equal number of symbols within the image portion, the allocation to the earlier-encoded sub-region is lower than the allocation to the later-encoded sub-region.

24. The image data encoding apparatus of claim 14, in which:

the symbols are associated with multiple symbol classes; and

the data router is configured to inhibit inverting the default association for one or more predetermined symbol classes.

25. Video storage, capture, transmission or reception apparatus comprising apparatus according to claim 1.

26. An image data encoding method, comprising:

encoding data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

controlling the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

generating a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

routing each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

27. Computer software which, when executed by a computer, causes the computer to carry out the method of claim 26.

28. A machine-readable non-transitory storage medium which stores the computer software of claim 27.

29. A data signal comprising coded data generated according to the method of claim 26.

30. Image data decoding apparatus, comprising:

a first data decoder and a second data decoder, each configured to decode binarized symbols to generate successive symbols representing image data;

the first data decoder being configured to decode binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to generate a fixed number of decoded data bits from each input binarized symbol;

the apparatus comprising a controller configured to control the first data decoder and the second data decoder to decode a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

the controller comprising:

a predictor configured to generate a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

a data router configured to route each binarized symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

31. The image data decoding apparatus of claim 30, in which the first data decoder is a context adaptive binary arithmetic coding (CABAC) decoder.

32. The image data decoding apparatus of claim 30, in which the second data decoder is a bypass decoder.

33. The image data decoding apparatus of claim 32, in which the second data decoder is a binary arithmetic coder using a fixed 50% probability context model.

34. The image data decoding apparatus of claim 30, in which the data unit is an independently decodable data unit.

35. The image data decoding apparatus of claim 34, in which the image portion is one of a picture, slice or tile.

36. The image data decoding apparatus of claim 35, in which the constraint is defined by:

N <= K1 * B + (K2 * CU)

in which:

N = number of binarized symbols in the data unit;

K1 is a constant;

B = number of decoded bytes for the data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data decoding apparatus; and

CU = size of the picture, slice or tile represented by the data unit expressed as a number of coding units of minimum size.

37. The image data decoding apparatus of claim 36, in which the apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to detect a tier parameter defining the currently selected encoding tier, at least the constant K1 being dependent upon the detected tier parameter.

38. The image data decoding apparatus of claim 30, in which the apparatus is configured to decode image data as successive linear arrays of image blocks, image data of a given image block being decoded once image data in a previously decoded linear array, on which the decoding of the given image block depends, has been decoded.

39. The image data decoding apparatus of claim 38, in which the apparatus comprises multiple instances of the first data decoder and the second data decoder, configured to concurrently decode two or more of the linear arrays of image blocks.

40. The image data encoding apparatus of claim 38, in which each linear array of image blocks is an image portion represented by a respective output data unit.

41. The image data decoding apparatus of claim 30, in which:

each symbol is associated with a default data decoder of the first data decoder and the second data decoder;

the data router is configured to selectively invert the default association so as to route symbols associated with one of the first and second data decoders to the other of the first and second data decoders.

42. The image data decoding apparatus of claim 41 , in which:

within an image portion, the apparatus is configured to decode symbols representing plural sub-regions; and

the data router is configured to apply or disapply the selective inversion of the default association in respect of entire sub-regions.

43. The image data decoding apparatus of claim 42, in which:

the image portion comprises one of a picture, a slice and a tile.

44. The image data decoding apparatus of claim 42, in which:

the sub-regions comprise one or more of coding tree units, coding units, transform units and sub-portions of transform units.

45. The image data decoding apparatus of claim 44, in which the predictor is configured to generate the prediction in respect of a processing stage at a given boundary between a pair of adjacently processed sub-regions.

46. The image data decoding apparatus of claim 45, in which the data router is configured to apply the prediction to control selective inversion of the default association for a next sub-region to be processed starting from the given boundary.

47. The image data decoding apparatus of claim 45, in which the data router is configured to apply the prediction to control selective inversion of the default association for a subsequent sub-region to be processed starting from a further boundary between sub-regions following, in a sub-region processing order, the given boundary.

48. The image data decoding apparatus of claim 47, in which the further boundary is a boundary next following, in a sub-region processing order, the given boundary.

49. The image data decoding apparatus of claim 42, in which the predictor is configured to allocate a respective share of the upper limit to each sub-region and to generate a prediction in respect of each sub-region.

50. The image data decoding apparatus of claim 49, in which the predictor is configured to vary the allocation of respective shares of the upper limit to each sub-region so that, for an earlier-decoded and a later-decoded sub-region of an equal number of symbols within the image portion, the allocation to the earlier-decoded sub-region is lower than the allocation to the later-decoded sub-region.

51. The image data decoding apparatus of claim 41 , in which:

the symbols are associated with multiple symbol classes; and

the data router is configured to inhibit inverting the default association for one or more predetermined symbol classes.

52. Video storage, capture, transmission or reception apparatus comprising apparatus according to claim 30.

53. An image data decoding method, comprising:

decoding data using a first data decoder and a second data decoder, each configured to decode binarized symbols into successive symbols representing image data;

the first data decoder being configured to decode data bits from binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to decode a fixed number of decoded data bits from each decoded binarized symbol;

controlling the first data decoder and the second data decoder to generate a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

generating a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

routing each symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

54. Computer software which, when executed by a computer, causes the computer to carry out the method of claim 53.

55. A machine-readable non-transitory storage medium which stores the computer software of claim 54.

56. Image data encoding apparatus, comprising:

a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

the controller comprising:

an attribute detector configured to detect an encoding attribute applicable to a given output data unit; and

a selector configured to select, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

57. The image data encoding apparatus of claim 56, in which the first data encoder is a context adaptive binary arithmetic coding (CABAC) encoder.

58. The image data encoding apparatus of claim 56, in which the second data encoder is a bypass encoder.

59. The image data encoding apparatus of claim 58, in which the second data encoder is a binary arithmetic coder using a fixed 50% probability context model.

60. The image data encoding apparatus of claim 56, in which the output data unit is an independently decodable data unit.

61. The image data encoding apparatus of claim 60, in which the image portion is one of a picture, slice or tile.

62. The image data encoding apparatus of claim 61 , in which the constraint is defined by:

N <= K1 * B + (K2 * CU) (constraint equation 1)

in which:

N = number of binarized symbols in the output data unit;

K1 is a constant;

B = number of encoded bytes for the output data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data encoding apparatus; and CU = size of the picture, slice or tile represented by the output data unit expressed as a number of coding units of minimum size.

63. The image data encoding apparatus of claim 62, in which:

at least two candidate constraints are defined by the constraint equation 1 , a respective set of (K1 , K2) being associated with each of the at least two candidate constraints; and

the selector is configured to select a set of (K1 , K2) for the given output data unit.

64. The image data encoding apparatus of claim 63, in which the apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to generate a tier parameter defining the currently selected encoding tier, at least the constant K1 being dependent upon the tier parameter.

65. The image data encoding apparatus of claim 56, in which:

the controller is configured to encode a representation of the encoding attribute applicable to the given output data unit in association with an output data stream representing the given output data unit.

66. The image data encoding apparatus of claim 65, in which:

the image data encoding apparatus comprises a quantiser configured to selectively operate in a dependent quantisation mode; and

the encoding attribute indicates whether the dependent quantisation mode is enabled or disabled in respect of the given output data unit.

67. The image data encoding apparatus of claim 66, in which, in the dependent quantisation mode, a selection of a quantisation parameter for use in quantising a current data value depends at least in part on a property of a previously encoded data value.

68. The image data encoding apparatus of claim 56, comprising:

a padding data detector configured to detect, at a predetermined stage relative to the encoding of a current output data unit, whether the constraint will be met by the current output data unit; and

a padding data generator configured to generate and insert in the current output data unit sufficient padding data so that the output data unit including the inserted padding data meets the constraint.

69. The image data encoding apparatus of claim 68, in which the predetermined stage is the end of encoding the current output data unit.

70. The image data encoding apparatus of claim 69, in which:

the image portion comprises one of a picture, a slice and a tile.

71. Video storage, capture, transmission or reception apparatus comprising apparatus according to claim 56.

72. An image data encoding method, comprising:

encoding data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol; and

controlling the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controlling step comprising:

detecting an encoding attribute applicable to a given output data unit; and

selecting, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

73. Computer software which, when executed by a computer, causes the computer to carry out the method of claim 72.

74. A machine-readable non-transitory storage medium which stores the computer software of claim 73.

75. A data signal comprising coded data generated according to the method of claim 72.

Description:
HIGH THROUGHPUT CABAC

BACKGROUND

Field

This disclosure relates to image data encoding and decoding.

Description of Related Art

The“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.

High Efficiency Video Coding (HEVC), also known as H.265 or MPEG-H Part 2, is a proposed successor to H.264/M PEG-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 c 96 to 7680 x 4320 pixels resolution, roughly equivalent to bit rates ranging from 128kbit/s to 800Mbit/s.

SUMMARY

The present disclosure addresses or mitigates problems arising from this processing.

The present disclosure provides image data encoding apparatus, comprising:

a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

the controller comprising: a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

a data router configured to route each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

The present disclosure also provides an image data encoding method, comprising: encoding data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

controlling the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

generating a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

routing each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

The present disclosure also provides image data decoding apparatus, comprising:

a first data decoder and a second data decoder, each configured to decode binarized symbols to generate successive symbols representing image data;

the first data decoder being configured to decode binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to generate a fixed number of decoded data bits from each input binarized symbol;

the apparatus comprising a controller configured to control the first data decoder and the second data decoder to decode a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

the controller comprising:

a predictor configured to generate a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and a data router configured to route each binarized symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

The present disclosure also provides an image data decoding method, comprising:

decoding data using a first data decoder and a second data decoder, each configured to decode binarized symbols into successive symbols representing image data;

the first data decoder being configured to decode data bits from binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to decode a fixed number of decoded data bits from each decoded binarized symbol;

controlling the first data decoder and the second data decoder to generate a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

generating a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

routing each symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

The present disclosure also provides image data encoding apparatus, comprising:

a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

the controller comprising:

an attribute detector configured to detect an encoding attribute applicable to a given output data unit; and

a selector configured to select, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

The present disclosure also provides an image data encoding method, comprising: encoding data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol; and

controlling the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controlling step comprising:

detecting an encoding attribute applicable to a given output data unit; and

selecting, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

Further 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.

BRIEF DESCRIPTION OF THE DRAWINGS

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:

Figure 1 schematically illustrates an audio/video (A/V) data transmission and reception system using video data compression and decompression;

Figure 2 schematically illustrates a video display system using video data decompression;

Figure 3 schematically illustrates an audio/video storage system using video data compression and decompression;

Figure 4 schematically illustrates a video camera using video data compression;

Figures 5 and 6 schematically illustrate storage media;

Figure 7 provides a schematic overview of a video data compression and decompression apparatus;

Figure 8 schematically illustrates a predictor;

Figure 9 schematically illustrates a partially-encoded image;

Figure 10 schematically illustrates a set of possible intra-prediction directions;

Figure 11 schematically illustrates a set of prediction modes; Figure 12 schematically illustrates another set of prediction modes;

Figure 13 schematically illustrates an intra-prediction process;

Figure 14 schematically illustrates a CABAC encoder;

Figures 15 and 16 schematically illustrate CABAC encoding techniques;

Figures 17 and 18 schematically illustrate CABAC decoding techniques;

Figure 19 schematically illustrates a partitioned image;

Figure 20 schematically illustrates an apparatus;

Figures 21 to 25 are schematic flowcharts illustrating respective methods;

Figure 26 schematically illustrates a so-called wavefront encoding or decoding apparatus;

Figure 27 schematically illustrates a wavefront encoding or decoding arrangement;

Figures 28 to 31 are schematic flowcharts illustrating respective methods;

Figure 32 is a schematic timeline representation;

Figure 33 is a schematic flowchart illustrating a method;

Figure 34 is a schematic timeline representation;

Figure 35 schematically illustrates a controller; and

Figure 36 is a schematic flowchart illustrating a method.

DESCRIPTION OF THE PREFERRED EMBODIMENTS

Referring now to the drawings, Figures 1-4 are provided to give schematic illustrations of apparatus or systems making use of the compression and/or decompression apparatus to be described below in connection with embodiments of the present technology.

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.

Figure 1 schematically illustrates an audio/video data transmission and reception system using video data compression and decompression.

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.

Figure 2 schematically illustrates a video display system using video data decompression. In particular, a compressed audio/video signal 100 is processed by a decompression apparatus 110 to provide a decompressed signal which can be displayed on a display 120. The decompression apparatus 110 could be implemented as an integral part of the display 120, for example being provided within the same casing as the display device. Alternatively, the decompression apparatus 110 maybe provided as (for example) a so-called set top box (STB), noting that the expression "set-top" does not imply a requirement for the box to be sited in any particular orientation or position with respect to the display 120; it is simply a term used in the art to indicate a device which is connectable to a display as a peripheral device.

Figure 3 schematically illustrates an audio/video storage system using video data compression and decompression. An input audio/video signal 130 is supplied to a compression apparatus 140 which generates a compressed signal for storing by a store device 150 such as a magnetic disk device, an optical disk device, a magnetic tape device, a solid state storage device such as a semiconductor memory or other storage device. For replay, compressed data is read from the storage device 150 and passed to a decompression apparatus 160 for decompression to provide an output audio/video signal 170.

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.

Figure 4 schematically illustrates a video camera using video data compression. In Figure 4, an image capture device 180, such as a charge coupled device (CCD) image sensor and associated control and read-out electronics, generates a video signal which is passed to a compression apparatus 190. A microphone (or plural microphones) 200 generates an audio signal to be passed to the compression apparatus 190. The compression apparatus 190 generates a compressed audio/video signal 210 to be stored and/or transmitted (shown generically as a schematic stage 220).

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 Figures 1-4) relate to audio/video data, the techniques to be described below can find use in a system which simply deals with (that is to say, compresses, decompresses, stores, displays and/or transmits) video data. That is to say, the embodiments can apply to video data compression without necessarily having any associated audio data handling at all.

Figure 4 therefore provides an example of a video capture apparatus comprising an image sensor and an encoding apparatus of the type to be discussed below. Figure 2 therefore provides an example of a decoding apparatus of the type to be discussed below and a display to which the decoded images are output.

A combination of Figure 2 and 4 may provide a video capture apparatus comprising an image sensor 180 and encoding apparatus 190, decoding apparatus 110 and a display 120 to which the decoded images are output.

Figures 5 and 6 schematically illustrate storage media, which store (for example) the compressed data generated by the apparatus 20, 60, the compressed data input to the apparatus 110 or the storage media or stages 150, 220. Figure 5 schematically illustrates a disc storage medium such as a magnetic or optical disc, and Figure 6 schematically illustrates a solid state storage medium such as a flash memory. Note that Figures 5 and 6 can also provide examples of non-transitory machine-readable storage media which store computer software which, when executed by a computer, causes the computer to carry out one or more of the methods to be discussed below.

Therefore, the above arrangements provide examples of video storage, capture, transmission or reception apparatuses embodying any of the present techniques.

Figure 7 provides a schematic overview of a video data compression and decompression apparatus.

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 Figure 8. The image encoder or decoder (as the case may be) plus the intra-image predictor of Figure 8 may use features from the apparatus of Figure 7. This does not mean that the image encoder or decoder necessarily requires every feature of Figure 7 however.

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 Figure 8 but omitted from Figure 7 for clarity of the higher level diagram of Figure 7) before the signal is output. The apparatus of Figures 7 and 8 can act as a compression (encoding) apparatus or a decompression (decoding) apparatus. The functions of the two types of apparatus substantially overlap. The scan unit 360 and entropy encoder 370 are not used in a decompression mode, and the operation of the predictor 320 (which will be described in detail below) and other units follow mode and parameter information contained in the received compressed bit-stream rather than generating such information themselves.

Figure 8 schematically illustrates the generation of predicted images, and in particular the operation of the image predictor 320.

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 l-frame encoding in other video compression techniques. In contrast to l-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 Figure 8, two image prediction arrangements (corresponding to intra- and inter-image prediction) are shown, the results of which are selected by a multiplexer 500 under the control of a mode signal 510 (for example, from the controller 343) so as to provide blocks of the predicted image for supply to the adders 310 and 450. The choice is made in dependence upon which selection gives the lowest“energy” (which, as discussed above, may be considered as information content requiring encoding), and the choice is signalled to the decoder within the encoded output data-stream. Image energy, in this context, can be detected, for example, by carrying out a trial subtraction of an area of the two versions of the predicted image from the input image, squaring each pixel value of the difference image, summing the squared values, and identifying which of the two versions gives rise to the lower mean squared value of the difference image relating to that image area. In other examples, a trial encoding can be carried out for each selection or potential selection, with a choice then being made according to the cost of each potential selection in terms of one or both of the number of bits required for encoding and distortion to the picture.

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.

Figure 9 schematically illustrates a partially encoded image 800. Here, the image is being encoded from top-left to bottom-right on a block by block basis. An example block encoded partway through the handling of the whole image is shown as a block 810. A shaded region 820 above and to the left of the block 810 has already been encoded. The intra-image prediction of the contents of the block 810 can make use of any of the shaded area 820 but cannot make use of the unshaded area below that. 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 Figure 9. Within each CU, there is the potential (depending on the block splitting process that has taken place) for the CU to be handled as a set of two or more smaller blocks or transform units (TUs). This can give a hierarchical order of encoding so that the image is encoded on a CU by CU basis, and each CU is potentially encoded on a TU by TU basis. Note however that for an individual TU within the current coding tree unit (the largest node in the tree structure of block division), the hierarchical order of encoding (CU by CU then TU by TU) discussed above means that there may be previously encoded samples in the current CU and available to the coding of that TU which are, for example, above-right or below- left of that TU.

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.

Figure 10 schematically illustrates a set of possible (candidate) prediction directions. The full set of candidate directions is available to a prediction unit. The directions are determined by horizontal and vertical displacement relative to a current block position, but are encoded as prediction "modes", a set of which is shown in Figure 11. Note that the so-called DC mode represents a simple arithmetic mean of the surrounding upper and left-hand samples. Note also that the set of directions shown in Figure 10 is just one example; in other examples, a set of (for example) 65 angular modes plus DC and planar (a full set of 67 modes) as shown schematically in Figure 12 makes up the full set. Other numbers of modes could be used.

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 (and the image decoder is configured to detect such data).

Figure 13 schematically illustrates an intra-prediction process in which a sample 900 of a block or region 910 of samples is derived from other reference samples 920 of the same image according to a direction 930 defined by the intra-prediction mode associated with that sample. The reference samples 920 in this example come from blocks above and to the left of the block 910 in question and the predicted value of the sample 900 is obtained by tracking along the direction 930 to the reference samples 920. The direction 930 might point to a single individual reference sample but in a more general case an interpolated value between surrounding reference samples is used as the prediction value. Note that the block 910 could be square as shown in Figure 13 or could be another shape such as rectangular.

Figures 14 and 15 schematically illustrate a previously proposed reference sample projection process.

In Figures 14 and 15, a block or region 1400 of samples to be predicted is surrounded by linear arrays of reference samples from which the intra prediction of the predicted samples takes place. The reference samples 1410 are shown as shaded blocks in Figures 14 and 15, and the samples to be predicted are shown as unshaded blocks. Note that an 8x8 block or region of samples to be predicted is used in this example, but the techniques are applicable to variable block sizes and indeed block shapes.

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 Figure 13, the reference sample arrays can extend beyond the extent of the block to be predicted, in order to provide for prediction modes or directions within the range indicated in Figures 10-12. Where necessary, if previously decoded samples are not available for use as reference samples at particular reference sample positions, other reference samples can be re-used at those missing positions. Reference sample filtering processes can be used on the reference samples.

Figure 14 schematically illustrates the operation of a CABAC entropy encoder.

The CABAC encoder operates in respect of binary data, that is to say, data represented by only the two symbols 0 and 1. The encoder makes use of a so-called context modelling process which selects a "context" or probability model for subsequent data on the basis of previously encoded data. The selection of the context is carried out in a deterministic way so that the same determination, on the basis of previously decoded data, can be performed at the decoder without the need for further data (specifying the context) to be added to the encoded datastream passed to the decoder.

Referring to Figure 14, input data to be encoded may be passed to a binary converter 1400 if it is not already in a binary form; if the data is already in binary form, the converter 1400 is bypassed (by a schematic switch 1410). In the present embodiments, conversion to a binary form is actually carried out by expressing the quantised DCT coefficient data as a series of binary“maps”, which will be described further below.

The binary data may then be handled by one of two processing paths, a "regular" and a "bypass" path (which are shown schematically as separate paths but which, in embodiments of the invention discussed below, could in fact be implemented by the same processing stages, just using slightly different parameters). The bypass path employs a so-called bypass coder 1420 which does not necessarily make use of context modelling in the same form as the regular path. In some examples of CABAC coding, this bypass path can be selected if there is a need for particularly rapid processing of a batch of data, but in the present embodiments two features of so-called“bypass” data are noted: firstly, the bypass data is handled by the CABAC encoder (950, 1460), just using a fixed context model representing a 50% probability; and secondly, the bypass data relates to certain categories of data, one particular example being coefficient sign data. Otherwise, the regular path is selected by schematic switches 1430, 1440 operating under the control of control circuitry 1435. This involves the data being processed by a context modeller 1450 followed by a coding engine 1460.

The entropy encoder shown in Figure 14 encodes a block of data (that is, for example, data corresponding to a block of coefficients relating to a block of the residual image) as a single value if the block is formed entirely of zero-valued data. For each block that does not fall into this category, that is to say a block that contains at least some non-zero data, a “significance map” is prepared. The significance map indicates whether, for each position in a block of data to be encoded, the corresponding coefficient in the block is non-zero. The significance map data, being in binary form, is itself CABAC encoded. The use of the significance map assists with compression because no data needs to be encoded for a coefficient with a magnitude that the significance map indicates to be zero. Also, the significance map can include a special code to indicate the final non-zero coefficient in the block, so that all of the final high frequency / trailing zero coefficients can be omitted from the encoding. The significance map is followed, in the encoded bitstream, by data defining the values of the non-zero coefficients specified by the significance map.

Further levels of map data are also prepared and are encoded. An example is a map which defines, as a binary value (1 = yes, 0 = no) whether the coefficient data at a map position which the significance map has indicated to be“non-zero” actually has the value of “one”. Another map specifies whether the coefficient data at a map position which the significance map has indicated to be“non-zero” actually has the value of“two”. A further map indicates, for those map positions where the significance map has indicated that the coefficient data is“non zero”, whether the data has a value of“greater than two”. Another map indicates, again for data identified as“non-zero”, the sign of the data value (using a predetermined binary notation such as 1 for +, 0 for -, or of course the other way around).

In embodiments of the invention, the significance maps and the other maps are allocated in a predetermined manner either to the CABAC encoder or to the bypass encoder, and are all representative of different respective attributes or value ranges of the same initial data items. In one example, at least the significance map is CABAC encoded and at least some of the remaining maps (such as the sign data) are bypass encoded. Accordingly, each data item is split into respective subsets of data and the respective subsets are encoded by first (for example, CABAC) and second (for example, bypass) encoding systems. The nature of the data and of the CABAC and bypass encoding is such that for a predetermined quantity of CABAC encoded data, a variable quantity of zero or more bypass data is generated in respect of the same initial data items. So, for example, if the quantised, reordered DCT data contains substantially all zero values, then it may be that no bypass data or a very small quantity of bypass data is generated, because the bypass data concerns only those map positions for which the significance map has indicated that the value is non-zero. In another example, in quantised reordered DCT data having many high value coefficients, a significant quantity of bypass data might be generated.

In embodiments of the invention, the significance map and other maps are generated from the quantised DCT coefficients, for example by the scan unit 360, and is subjected to a zigzag scanning process (or a scanning process selected from zigzag, horizontal raster and vertical raster scanning according to the intra-prediction mode) before being subjected to CABAC encoding.

In general terms, CABAC encoding involves predicting a context, or a probability model, for a next bit to be encoded, based upon other previously encoded data. If the next bit is the same as the bit identified as“most likely” by the probability model, then the encoding of the information that“the next bit agrees with the probability model” can be encoded with great efficiency. It is less efficient to encode that“the next bit does not agree with the probability model”, so the derivation of the context data is important to good operation of the encoder. The term“adaptive” means that the context or probability models are adapted, or varied during encoding, in an attempt to provide a good match to the (as yet uncoded) next data.

Using a simple analogy, in the written English language, the letter“U” is relatively uncommon. But in a letter position immediately after the letter“Q”, it is very common indeed. So, a probability model might set the probability of a“U” as a very low value, but if the current letter is a“Q”, the probability model for a“U” as the next letter could be set to a very high probability value.

CABAC encoding is used, in the present arrangements, for at least the significance map and the maps indicating whether the non-zero values are one or two. Bypass processing - which in these embodiments is identical to CABAC encoding but for the fact that the probability model is fixed at an equal (0.5:0.5) probability distribution of 1s and 0s, is used for at least the sign data and the map indicating whether a value is >2. For those data positions identified as >2, a separate so-called escape data encoding can be used to encode the actual value of the data. This may include a Golomb-Rice encoding technique.

The CABAC context modelling and encoding process is described in more detail in WD4: Working Draft 4 of High-Efficiency Video Coding, JCTVC-F803_d5, Draft ISO/I EC 23008- HEVC; 201x(E) 2011-10-28.

Referring now to Figures 15 and 16, an entropy encoder forming part of a video encoding apparatus comprises a first encoding system (for example an arithmetic coding encoding system such as a CABAC encoder 1500) and a second encoding system (such as a bypass encoder 1510), arranged so that a particular data word or value is encoded to the final output data stream by either the CABAC encoder or the bypass encoder but not both. In embodiments of the invention, the data values passed to the CABAC encoder and to the bypass encoder are respective subsets of ordered data values split or derived from the initial input data (the reordered quantised DCT data in this example), representing different ones of the set of“maps” generated from the input data.

The schematic representation in Figure 15 treats the CABAC encoder and the bypass encoder as separate arrangements. This may well be the case in practice, but in another possibility, shown schematically in Figure 16, a single CABAC encoder 1620 is used as both the CABAC encoder 1500 and the bypass encoder 1510 of Figure 15. The encoder 1620 operates under the control of an encoding mode selection signal 1630, so as to operate with an adaptive context model (as described above) when in the mode of the CABAC encoder 1500, and to operate with a fixed 50% probability context model when in the mode of the bypass encoder 1510.

A third possibility combines these two, in that two substantially identical CABAC encoders can be operated in parallel (similar to the parallel arrangement of Figure 15) with the difference being that the CABAC encoder operating as the bypass encoder 1510 has its context model fixed at a 50% probability context model.

The outputs of the CABAC encoding process and the bypass encoding process can be stored (temporarily at least) in respective buffers 1540, 1550. In the case of Figure 16, a switch or demultiplexer 1660 acts under the control of the mode signal 1630 to route CABAC encoded data to the buffer 1550 and bypass encoded data to the buffer 1540.

Figures 17 and 18 schematically illustrate examples of an entropy decoder forming part of a video decoding apparatus. Referring to Figure 17, respective buffers 1710, 1700 pass data to a CABAC decoder 1730 and a bypass decoder 1720, arranged so that a particular encoded data word or value is decoded by either the CABAC decoder or the bypass decoder but not both. The decoded data are reordered by logic 1740 into the appropriate order for subsequent decoding stages.

The schematic representation in Figure 17 treats the CABAC decoder and the bypass decoder as separate arrangements. This may well be the case in practice, but in another possibility, shown schematically in Figure 18, a single CABAC decoder 1850 is used as both the CABAC decoder 1730 and the bypass decoder 1720 of Figure 17. The decoder 1850 operates under the control of a decoding mode selection signal 1860, so as to operate with an adaptive context model (as described above) when in the mode of the CABAC decoder 1730, and to operate with a fixed 50% probability context model when in the mode of the bypass encoder 1720.

As before, a third possibility combines these two, in that two substantially identical CABAC decoders can be operated in parallel (similar to the parallel arrangement of Figure 17) with the difference being that the CABAC decoder operating as the bypass decoder 1720 has its context model fixed at a 50% probability context model.

In the case of Figure 18, a switch or multiplexer 1870 acts under the control of the mode signal 1860 to route CABAC encoded data to the decoder 1850 from the buffer 1700 or the buffer 1710 as appropriate.

Figure 19 schematically illustrates a picture 1900 and will be used to demonstrate various picture partitioning schemes relevant to the following discussion. One example of the partitioning of a picture is into slices or“regular slices”. Each regular slice is encapsulated in its own network abstraction layer (NAL) unit. Prediction within the picture (for example intrasample prediction, motion information prediction, coding mode prediction) and entropy coding dependency across slice boundaries are disallowed. This means that a regular slice can be reconstructed independently from other regular slices within the same picture.

A so-called tile defines a horizontal and a vertical boundary to partition a picture into rows and columns of tiles. In a corresponding way to regular slices, in-picture prediction dependencies are not allowed across tile boundaries, nor are entropy decoding dependencies. However, tiles are not constrained to be included into individual NAL units.

In general terms, there may be multiple tiles within a slice, or multiple slices within a tile, and one or more of each within a picture. The schematic example of Figure 19 shows 4 slices 1910, 1920, 1930, 1940, with the slice 1940 comprising 2 tiles 1950, 1960. However, as mentioned, this is simply an arbitrary schematic example.

In some example arrangements, a threshold exists for the number of bins (either EP or CABAC) that may be encoded in a slice or a picture, according to the following equation:

BinCountsinNalUnits <= (4/3) * NumByteslnVclNalUnits +

(RawMinCuBits*PicSizelnMinCbsY)/32

The right hand side of the equation is dependent on the sum of two parts: these are a constant value (RawMinCuBits*PicSizelnMinCbsY) for a particular image region and related to the size of the slice or picture and a dynamic value (NumByteslnVclNalUnits) which is the number of bytes coded in the output stream of the slice or picture. Note that the value 4/3 represents a number of bins per bit.

RawMinCuBits is the number of bits in a raw CU of minimum size - typically 4*4; and PicSizelnMinCbsY is the number of minimum size CUs in the slice or picture.

If this threshold is exceeded, CABAC zero words (3 bytes with values 00 00 03) are appended to the stream, until the threshold is achieved. Each such zero word increments the dynamic value by 3.

This constraint may be expressed as:

N <= K1 * B + (K2 * CU)

in which:

N = number of binarized symbols in the output data unit;

K1 is a constant;

B = number of encoded bytes for the output data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data encoding apparatus; and CU = size of the picture, slice or tile represented by the output data unit expressed as a number of coding units of minimum size.

In previously proposed examples, this threshold check is performed at the picture and slice level.

However, as noted with reference to Figure 19, a picture or slice can be split into a number of tiles. An example of why this might be performed is to allow the use of multiple concurrent (parallel) decoders.

Under the previously proposed arrangement, each tile does not necessarily meet the threshold calculation discussed above. This could cause problems if, for example, a tile is used or decoded independently as though a picture, or if different tiles (for example with different quantisation parameters or from different sources) are composited together, there can be no guarantee that the resulting composited slice or picture complies with the specification set out above.

To address this issue, in example embodiments, the CABAC threshold is applied at the end of each tile rather than at the end of each slice or picture alone. So, the application of the threshold occurs at the end of encoding any one of a tile, a slice and a picture. Having said this, if each tile in an image is compliant with the threshold, it can be assumed that the whole picture must also be compliant, so that in the case of a picture divided into slices or tiles, it is not therefore necessary to apply the threshold again at the end of encoding the picture.

The terms“tile” and“slice” refer to independently decodable units and represent names in use at the priority date of the present application. In the case of a subsequent or other change of name, the arrangement is applicable to other such independently decodable units.

Therefore, in example arrangements, the data unit may be an independently decodable data unit. For example the image portion (represented by an output data unit) may be one of a picture, slice or tile.

In order to apply the equation discussed above, the dynamic value represents the number of bytes coded in the output stream of the tile and the fixed value is dependent upon the number of minimum size coding units (CUs) in the tile.

Figure 20 schematically illustrates apparatus configured to perform this test. Referring to Figure20, at an input 2000 a CABAC/EP encoded stream is received from an encoder. A detector 2010 detects, at a predetermined stage with reference to the completion of a slice or tile, such as at the end of encoding a slice or tile, whether the threshold calculation described above is complied with. A controller 2020 controls a generator 2030 in response to the detection by the detector 2010 to generate padding data 2040 such as the CABAC zero words described above and to append this by a combiner 2050 to the stream to form an output stream 2060. The generation of zero words can also be signalled back to the detector 2010 so that as the zero words are appended, the detector 2010 can continue to monitor for compliance with the threshold and cause the controller 2020 to cease the generation of zero words once the threshold has been complied with. The controller 2020 may also act as a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit in connection with embodiments to be described here.

The predetermined stage could be, for example, every n encoded bins (where n is an integer of one or more), but in example arrangements the predetermined stage is the end of encoding the current output data unit.

Therefore the apparatus of Figures 7 and 14, operating in accordance with the techniques discussed with respect to Figures 19 and 20 (and those discussed below) provides an example of image data encoding apparatus, comprising:

a first data encoder 1450, 1460 and a second data encoder 1420, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller 2020 configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controller 2020 comprising:

a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

a data router1430 configured to route each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

Similarly, at the decoder side, this provides an example of image data decoding apparatus, comprising:

a first data decoder and a second data decoder, each configured to decode binarized symbols to generate successive symbols representing image data;

the first data decoder being configured to decode binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to generate a fixed number of decoded data bits from each input binarized symbol;

the apparatus comprising a controller configured to control the first data decoder and the second data decoder to decode a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

the controller comprising:

a predictor configured to generate a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

a data router configured to route each binarized symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

Using techniques shown in Figure 14, The first data encoder / decoder may be a context adaptive binary arithmetic coding (CABAC) encoder / decoder. The second data encoder / decoder may be a bypass encoder / decoder. The second data encoder / decoder may be a binary arithmetic coder / decoder using a fixed 50% probability context model.

Figure 21 is a schematic flow chart illustrating a process by which a decision as to whether to encode a particular symbol as a CABAC bin (binarized symbol) or an EP bin. The flowchart of Figure 21 can represent example operations of the controller 1435 and/or the controller 2020.

Note that in general terms, each symbol or category of data to be encoded has associated with it a default allocation to either CABAC processing or EP (bypass) processing. The flow chart of Figure 21 starts with a step 2100 at which this default association is established or detected for a particular symbol to be encoded, so that the symbol is routed either to CABAC processing (down the left hand path of Figure 21) or EP/bypass processing down the right hand side of Figure 21.

At the step 2100, each symbol is associated with a default data encoder of the first data encoder and the second data encoder; and (as discussed below with reference to a step 2120) the data router is configured to selectively invert the default association so as to route symbols associated with one of the first and second data encoders to the other of the first and second data encoders.

Looking first at the CABAC path, at a step 2120, a determination is made as to whether the selection of CABAC or EP should be inverted. The potential and selective inversion of the selection will be discussed in detail below, along with example criteria by which it may be inverted. If yes, then control passes to a step 2140 at which the symbol is encoded as an EP bin. If the answer at the step 2120 was no, then control passes to a step 2150 at which the symbol is output as an encoded CABAC bin.

Returning to the step 2100, the right hand path (EP/bypass processing) involves the step 2140 just described.

This process allows a decision to be made at a symbol level, or at an image block or region level, as to whether CABAC or EP/bypass processing should be used. The decision at the step 2120 can be based upon a prediction, during encoding of a slice, tile or picture, of whether the threshold calculation described above will be met by the end of encoding that slice, tile or picture. Note that CABAC processing tends to be more efficient than EP processing - indeed, this is a justification for even using the CABAC processing in the first place. Therefore, the expectation, at least on an average basis, is that CABAC would encode symbols at less than 1 bin per bit, whereas the EP processing outputs 1 bin per encoded bit. Accordingly, by inverting the selection from CABAC to EP processing, the encoding can be made deliberately less efficient by a small margin, so as to allow the threshold discussed above to be met across the slice, tile or picture without necessarily needing to employ zero padding data at the end of the slice, tile or picture.

An example of the prediction of whether the threshold will be met is as follows.

In general terms, the test is“does the amount of output data generated so far, given the proportion of the output data unit (slice, tile, picture) which has so far been encoded, meet the threshold test?”

This can be performed at, for example, block or region boundaries or even bin-by-bin.

For example, a decision to invert the selection could be constrained so as to be made only at one of the following occasions:

Immediately following a CTU/CU/TU/sub-TU boundary; or immediately before a

CTU/CU/TU/sub-TU boundary.

The decision to stop inverting the selection could be constrained to be carried out only at a CTU/CU/TU/sub-TU boundary or could be allowed to be immediate (that is to say, as soon as the prediction indicates that the threshold condition is expected not to be broken).

It is possible for the decision to start inverting the selection to be constrained to one type of boundary and the decision to cease inverting the selection to be constrained differently, for example to a different boundary or not constrained at all.

Therefore, in examples, within an image portion, the apparatus is configured to encode symbols representing plural sub-regions (such as one or more of coding tree units, coding units, transform units and sub-portions of transform units or CTU/CU/TU/sub-TU); and the data router is configured to apply or disapply the selective inversion of the default association in respect of entire sub-regions. The predictor may be configured to allocate a respective share of the upper limit to each sub-region and to generate a prediction in respect of each sub-region.

In examples, the image portion comprises one of a picture, a slice and a tile.

An optional feature is to limit the use of the inversion step 2120 to certain CABAC contexts, such as excluding data such as so-called greater-than-one flags. This provides an example in which the symbols are associated with multiple symbol classes; and the data router is configured to inhibit inverting the default association for one or more predetermined symbol classes. It is possible to apply a non-linear distribution of the proportion of the threshold allocated to each block, region or portion within an output data unit. For example, earlier-encoded data within a particular output data unit could be such that the predictor is configured to vary the allocation of respective shares of the upper limit to each sub-region so that, for an earlier- encoded and a later-encoded sub-region of an equal number of symbols within the image portion, the allocation to the earlier-encoded sub-region is lower than the allocation to the later- encoded sub-region.

At the encoder side, the selective inversion of the selection at the step 2120 is carried out in dependence upon the progress of encoding a slice, tile or picture and may invert and cease inversion multiple times during the encoding of the slice, tile or picture. It is possible under these arrangements for the padding data discussed above to be never needed.

At the decoder side, the equivalent calculation can be carried out during decoding of a slice, tile or picture so that a corresponding inversion step can be performed at the decoder in dependence upon a prediction based on the encoded data received so far as to whether the threshold will be met for the current slice, tile or picture. So, at the decoder, data can be routed to the CABAC decoder or the EP decoder according to the prediction and the corresponding inversion step.

Another possible option is discussed with reference to Figure 22, in which the steps 2100, 2140 and 2150 correspond to those shown in Figure 21. A difference, however, is that instead of selectively forcing a change from CABAC to EP processing in order to deliberately (marginally) reduce the coding efficiency to avoid not meeting the threshold constraints discussed above, a step 2200 (in response to a prediction that the constraint will not be met, for example being performed at a boundary of successively encoded sub-regions or more often, for example every n encoded bins) selectively forces a CABAC renormalisation which takes place at a step 2210 and once again can artificially decrease the coding efficiency by a small amount so as to avoid the need for padding data to be inserted.

Note that the arrangement of Figure 22 can still operate in conjunction with a second (for example, bypass) encoder / decoder, with data items having an association with the second encoder / decoder being routed 1430 to the second encoder/decoder.

In examples, as discussed above, the binary arithmetic data encoder is configured to select one of a plurality of complementary sub-ranges of a set of code values according to the value of a current input symbol, the proportions of the sub-ranges relative to the set of code values being defined by a context variable associated with that input symbol, to assign the current input symbol to a code value within the selected sub-range and to modify the set of code values in dependence upon the assigned code value and the size of the selected sub range; and a renormalisation of the binary arithmetic data encoder comprises increasing the size of the set of code values and outputting an encoded data bit in response to each such size- increasing operation. Renormalisation may also occur in response to a detection of whether the set of code values is less than a predetermined minimum size; if so, a renormalisation of the binary arithmetic data encoder may be initiated.

The apparatus of Figure 7, operating in accordance with the technique of Figure 22, provides an example of image data encoding apparatus, comprising:

a binary arithmetic data encoder configured to encode respective binarized symbols from successive symbols representing image data, the binary arithmetic encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols;

the apparatus comprising a controller configured to control the binary arithmetic data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit; and a predictor configured to generate a prediction, during generation of a given output data unit, of whether the constraint will be met by the given output data unit; and

the controller being configured to initiate a renormalisation of the binary arithmetic data encoder in response to a prediction generated by the predictor that the constraint will not be met by the given output data unit.

Figure 23 is a schematic flowchart illustrating an image data encoding method, comprising:

encoding (at a step 2300) data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

controlling(at a step 2310) the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

generating (at a step 2320) a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

routing (at a step 2330) each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

Figure 24 is a schematic flowchart illustrating an image data decoding method, comprising: decoding (at a step 2400) data using a first data decoder and a second data decoder, each configured to decode binarized symbols into successive symbols representing image data; the first data decoder being configured to decode data bits from binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to decode a fixed number of decoded data bits from each decoded binarized symbol;

controlling (at a step 2410) the first data decoder and the second data decoder to generate a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

generating (at a step 2420) a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

routing (at a step 2430) each symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

Figure 25 is a schematic flowchart illustrating a method comprising:

encoding (at a step 2500), by a binary arithmetic data encoding process, respective binarized symbols from successive symbols representing image data, the encoding step comprising generating output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols;

controlling (at a step 2510) the binary arithmetic data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit; and

generating (at a step 2520) a prediction, during generation of a given output data unit, of whether the constraint will be met by the given output data unit; and

initiating (at a step 2530) a renormalisation of the binary arithmetic data encoder in response to a prediction generated by the predictor that the constraint will not be met by the given output data unit.

In each case, embodiments of the disclosure are represented by computer software which, when executed by a computer, causes the computer to carry out the respective method and by a machine-readable non-transitory storage medium which stores such computer software. In the case of encoding methods, embodiments of the disclosure are represented by a data signal comprising coded data generated according to the respective method.

Figures 26 and 27 schematically illustrate aspects of an encoding or decoding apparatus configured to handle so-called“wavefront” processing of image data.

Corresponding principles are employed at the encoder and the decoder. The aim of wavefront processing is to allow (though not to require) at least overlapping or concurrent encoding and/or decoding. In some contexts, this is referred to as a parallel or overlapping operation.

In principle, concurrent encoding and decoding could be performed simply using independently decodable slices or tiles. However, since the number of slices or tiles is determined by the encoder, it is not always possible for the decoder to rely on the presence of multiple slices or tiles to obtain real-time performance improvements by concurrent operation. Also, having too many independently decodable units (for example slices or tiles) in a single picture can make the encoding efficiency lower because it removes the opportunity for encoding dependence between the different units.

To address this, so-called overlapping wavefront processing allows the processing (encoding or decoding) of linear arrays or rows of blocks 2700 (Figure 27) at the same time without the need to prohibit coding dependencies between the blocks.

Referring to the apparatus of Figure 26, a block of data to be encoded or decoded is received at an input 2600 and is routed by a demultiplexer 2610 to one of multiple processors P1... P4 (which may be encoders or decoders depending on the function of the apparatus and which may be embodied as separate circuitry, separate programmable apparatus such as central processing units, or by separate processing threads for example). The routing is controlled by a controller 2620, for example implemented by aspects of the controller 343 discussed above.

For each of the processors P1... P4, the resulting encoded or decoded data is buffered in a respective buffer 2630 and is made available for use, for example, as reference samples, by one or more others of the processors P1... P4 handling a different respective linear array.

The buffered data is recombined into an output data stream 2640 by a multiplexer 2650, again under the control of the controller 2620.

The arrangement of Figure 26 is purely by way of example and it is not a requirement that four processors are used; a different number could be used. Indeed, at one or other of the encoder and decoder, just one processor could be used to handle each linear array of blocks to be encoded or decoded, while a multiple-processor wavefront arrangement is used at the other of the encoder and decoder.

The wavefront arrangement is shown schematically in Figure 27, in which blocks 2700 such as coding tree units (CTUs) are considered as rows or linear arrays 2710, 2720, 2730... of blocks. Each linear array may be handled by a respective processor P1... P4. That processor handles the entire linear array through to completion of encoding or decoding (as the case may be) of that linear array. For example, a linear array 2730 is handled in this example by the processor P1 in a left-to-right direction with respect to the blocks 2700.

In Figure 27, already-encoded (or already-decoded, as the case may be) blocks are shown unshaded and yet-to-be-encoded (or yet-to-be-decoded) blocks are shown as shaded. In an example linear array 2730, the processor P1 has encoded or decoded the first six blocks as drawn. To allow for encoding dependencies (in which prediction of samples within a particular block can depend upon samples above and to the left of that block) the processor P2 is progressing along a row 2740 but a number of blocks (for example, two blocks, though in other examples this might be one block or another number of blocks, as long as a given block in a row below is not encoded or decoded until the data on which its encoding depends - for example as reference samples - is processed and ready) behind the processor P1 so that for the encoding or decoding of a given block such as a block 2750, the processor P2 has already handled the block to its left and the process of P1 has already handled the blocks above the given block 2750.

Similarly, in a linear array 2760, the processor P3 is progressing, a number of blocks behind the processor P2, and the processor P4 is about to start processing a linear array 2770 as shown.

Therefore, in the wavefront processing arrangement shown in Figures 26 and 27, concurrent encoding or decoding of the various linear arrays can be achieved, so allowing concurrent operation at the encoder or the decoder without removing the possibility of encoding dependencies between the linear arrays. Providing wavefront processing, rather than one tile per row of CTUs, also allows the entropy encoding process to learn contexts from the data to be encoded, which can in turn provide a better encoding efficiency.

This therefore provides an example in which the (encoding or decoding) apparatus is configured to encode or decode (as the case may be) image data as successive linear arrays of image blocks, image data of a given image block being encoded or decoded once image data in a previously encoded or decoded linear array, on which the encoding or decoding of the given image block depends, has been encoded or decoded.

For example, as shown in Figure 26, the apparatus may comprise multiple instances of the first data encoder / decoder and the second data encoder decoder (each represented by a respective processor P1... P4), configured to concurrently encode / decode two or more of the linear arrays of image blocks.

In terms of extending or applying the techniques above to wavefront processing, an image region (from which an output data unit is derived using the techniques described above) can be treated as one of the linear arrays. In other words, each linear array of image blocks can be treated as an image portion represented by a respective output data unit. Figure 28 will illustrate a technique by which this can be achieved.

The basic processing then applied is shown schematically by a flowchart of Figure 28, in which, at a step 2800, the constraint (the threshold size of a picture, slice or tile containing the linear arrays of Figure 27) is first derived using the equations given above. At a step 2810, the threshold size is partitioned amongst each of the linear arrays, for example in proportion to the respective sizes in blocks or decoded samples of the linear arrays. A resulting proportion of the threshold size is allocated to each linear array at a step 2820, and then the processing

(encoding or decoding) described above is carried out with respect to each linear array using the allocated portion of the threshold size and the techniques discussed above in which a prediction of whether that linear array (as an image region represented by an output data unit) will meet the threshold size during encoding or decoding.

As discussed above, it is not a requirement that each linear array is handled by a separate processor or processing thread. It is not a requirement that the linear arrays (which may be horizontal linear arrays or rows as represented by Figure 27) extend across the entire width of a picture; in the case of a tile, for example, the tile could have a vertical boundary part-way across a picture and the division into the linear arrays 2710, 2720... could be within the extent of a single tile.

Further examples will now be provided of the generation of a prediction, during generation of an output data unit (for example, slice, tile, picture), of whether the constraint will be met by that output data unit. In the examples below predictions are made at or in response to so-called “switch points” which can occur during coding of the output data unit. The prediction is used to set (in the examples below) an“invert flag” which - at least until the invert flag is next set - controls the routing of bins (which would otherwise be CABAC encoded) to the EP (bypass) encoder. I some examples, an invert flag is generated in respect of a switch point for use in respect of the next set of processing leading up to the next switch point. In other examples, the invert flag is pre-prepared, for example in response to a given switch point and is then brought into effect at a subsequent switch point such as the switch point following the given switch point. In this way, in which the predictor is configured to generate the prediction in respect of a processing stage at a given boundary between a pair of adjacently processed sub- regions. In respect of Figures 31 and 32 to be described below, the data router is configured to apply the prediction to control selective inversion of the default association for a next sub-region to be processed starting from the given boundary. In respect of the example of Figures 33 and 34, the data router is configured to apply the prediction to control selective inversion of the default association for a subsequent sub-region to be processed starting from a further boundary between sub-regions following, in a sub-region processing order, the given boundary, for example a boundary next following, in a sub-region processing order, the given boundary.

Figure 29 is a schematic flowchart similar to that shown in Figure 21 above, and indeed the steps 2100, 2140 and 2150 are identical to those shown in Figure 21. As before, this flowchart can relate to operations carried out by the controller 1435 and/or the controller 2020.

A difference between Figures 29 and 21 relates to a step 2900 which takes the place of the step 2120 of Figure 21. Here, in order to determine whether or not to apply an inversion process, the controller 1435 detects the state of an invert flag. If, at the step 2900 the flag is set to“invert” then control passes to the step 2140. If not (which is to say, the flag is set to“don’t invert”), then control continues down the“CABAC” path to the step 2150.

Techniques for deriving the invert flag will be discussed in more detail below.

In the discussion earlier, in connection with Figure 21 , various stages, which will be referred to as“switch points” were indicated as stages in the processing of data to be encoded for which an assessment of whether or not to invert could be made. Examples given above include: immediately following a CTU/CU/TU/sub-TU boundary, or immediately before a

CTU/CU/TU/sub-TU boundary. Further examples of potential switch points will now be described, and then various types of action which can be taken in response to a switch point will also be described.

Figure 30 is a schematic flowchart illustrating a detection of whether a switch point has been reached. The process, from a start 3000, can be executed out every sample, or at every block or sub-block boundary during encoding, or at other intervals.

A series of condition tests (Cond 1... Cond n) is carried out. The conditions can be tested in series or in parallel, but for convenience of the drawing they are shown as being in series in Figure 30. If any one of the conditions is met at respective steps 3010, 3020, 3030, 3040, 3050 then control passes to a schematic step 3060 to perform processing associated with the detection of a switch point. If not then control returns to the top of Figure 30 to perform a next instance of the switch point detection processing.

In addition to, or as alternatives to, the list of switch points discussed above, the following example switch points may be used:

1. The start of a CTU;

2. The end of a CU if the CU is in a so-called merge skip mode (in which one or more coding parameters or actions are carried over from a preceding encoded CU);

3. At the beginning of a coefficient sub-block, for example immediately before or immediately after signalling a significant group flag, for a transform skip (TS) block;

4. At the beginning of a coefficient sub-block, immediately before or immediately after signalling the significant group flag, for a non-TS block; and

5. At the end of a TU if no coefficient sub-block has been coded.

An example of the switch point detection of Figure 30 is embodied within a flowchart of Figure 31 schematically illustrating an example process by which an invert flag is established. For example, the process of Figure 31 can generate an invert flag (indicating either“invert” or “do not invert” for use in respect of all coding until the next switch point occurs, at which the processing of Figure 31 will generate a further instance of the invert flag.

Referring to Figure 31 , at a step 3100 , a variable N is initialised to K2*CU (see above), representing a number of available bins. This occurs at the start of any separately decodable region e.g. tile/slice or alternatively at the beginning of a CTU. Then, for each bin coded (whether CABAC, EP, or termination) at a step 3110 the number of available bins N is decreased by 1.

At a step 3120, for each bin output data stream, an increment K1 (see above) is added to the number of available bins.

Note that the steps 3110 and 3120 are shown in series in Figure 31 but could be conducted in parallel or otherwise together.

At a step 3130, if the processing has reached a switch point (as detected by the flowchart of Figure 30) then control passes to a step 3140. Otherwise, control returns to a step 3110 in respect of a next coding instance.

At the step 3140, the remaining number of bins N at the switch point is compared with a threshold value Thr1 , for example 256. If N is < Thr1 then at a step 3150 the invert flag is set to “invert”. If not then the invert flag is set to“don’t invert” at a step 3160 and in either instance, control returns to the step 3110 for processing leading up to the next detection of a switch point.

Figure 32 is a schematic timeline representation indicating the process of Figure 31. Time is shown running down the diagram in a direction 3200. A processing stage 3210 represents the derivation of the invert flag at the end of a preceding set of processing leading up to a switch point. The invert flag generated at the processing stage 3210 is used in respect of processing 3220 of data leading up to a next switch point. At the next switch point, processing 3230 is performed to generate an invert flag for use in the following processing 3240 leading up to the next successive switch point and so on.

In another example, shown in Figure 33, many of the processing steps are identical to those shown in Figure 31 and are referred to by identical reference numerals. A substantive difference occurs at the“yes” output of the step 3130, or in other words when a switch point has been detected.

At this stage, control passes to a step 3300 at which a previously derived flag is applied as the invert flag for use in respect of the encoding to be carried out until the next detected switch point. Then, at a step 3310, the number of available bins is compared to a second threshold Thr2. If N < Thr2 then control passes to a step 3320 at which the next flag is set to “invert”. This next flag is not used in the immediately following processing but will be applied at the next instance at the step 3300, which is to say at the next-following switch point, so the flag is derived one switch point (or indeed more than one switch point) ahead of when it is needed and used.

Since the threshold Thr2 relates effectively to a prediction as to whether the invert flag should be set to“invert” not for the next-to-be-processed group (a term used here to describe processing between an adjacent pair of switch points) leading to the next switch point, but to the group between the next switch point and the switch point after that, the threshold Thr2 can be larger than the threshold Thr1. For example, in the case that the threshold Thr1 is used to derive an invert flag for the next group whereas the threshold Thr2 is used to derive an invert flag for the next-but-one group, the threshold Thr2 could be for example twice the threshold Thr1 (in this example, 512). In other examples, if (for the sake of discussion) the process was used to derive an invert flag for the nth group ahead then the threshold used could be n * Thr1.

Similarly, if the outcome of the step 3310 is no then control passes to a step 3330 at which the next flag is set to“don’t invert”. Control returns from the steps 3320, 3330 to the step 3110 for the processing leading up to the next following switch point.

Figure 34 provides a schematic timeline representation of this processing. Here, encoding 3400 is carried out using a previously derived invert flag and at the same time (as shown in Figure 34) processing 3410 associated with generating the next invert flag is performed. This processing 3410 may be overlapping in time with the processing 3400, may be completed before it starts, or may take the same length of time as the processing 3400.

A stage 3420 represents the step 3300 or Figure 33 at which the previously generated next flag is set as the invert flag for use in respect of coding 3430. Processing 3440 to generate a next flag to be set as the invert flag at the next switch point is then carried out.

Further examples will now be described.

Referring back to Figure 20, the detector 2010 may be considered as a padding data detector 2010 and the generator 2030 as a padding data generator 2030.

In examples, the controller 2020 may also act as a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit in connection with embodiments to be described here.

In Figure 20, therefore, there is disclosed an example of a padding data detector 2010 configured to detect, at a predetermined stage relative to the encoding of a current output data unit, whether the constraint will be met by the current output data unit; and a padding data generator 2030 configured to generate and insert in the current output data unit sufficient padding data so that the output data unit including the inserted padding data meets the constraint.

Referring to Figure 35, in some examples the controller 2020 comprises an attribute detector 3570 configured to detect an encoding attribute applicable to a given output data unit; and

a selector 3580 configured to select, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints 3582.

The controller 2020 may also comprise a comparator 3590 to compare a threshold derived from a currently selected constraint with the detection by the padding data detector 2010 in order to derive a control signal to control the operation of the padding data generator 2030. The attribute detected by the detector 3570 may be, for example, an attribute (such as an encoding mode or profile, for example the enabling of dependent quantisation (to be discussed below) which is a mode of operation in which a selection of a quantisation parameter for use in quantising a current data value depends at least in part on a property of a previously encoded data value and which is then represented by flag data (shown schematically as 3572) included in or associated with the encoded data stream so that it is later detectable at the decoder. For example, the flag data may be included in header data such as output data unit header data (for example, slice header data). The detector 3570 does not itself need to generate or insert the flag data; this aspect of the process is shown in Figure 35 merely for schematic purposes for the benefit of the present description.

Therefore the apparatus of Figures 7 and 14, operating in accordance with the techniques discussed with respect to Figures 19 and 20 (and those discussed below) provides an example of image data encoding apparatus, comprising:

a first data encoder 1450, 1460 and a second data encoder 1420, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller 2020 configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controller 2020 comprising:

an attribute detector 3570 configured to detect an encoding attribute applicable to a given output data unit; and

a selector 3580 configured to select, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

Using techniques shown in Figure 14, the first data encoder / decoder may be a context adaptive binary arithmetic coding (CABAC) encoder / decoder. The second data encoder / decoder may be a bypass encoder / decoder. The second data encoder / decoder may be a binary arithmetic coder / decoder using a fixed 50% probability context model.

Further examples of the use of constraints will now be described.

In the examples discussed above, a single threshold derivation or expression is used consistently. In alternative examples to be described below, a choice is implemented between two or more candidate thresholds. The choice or selection may be in response to one or more encoding attributes (for example, parameters, attributes or modes, for example parameters or modes which are signalled by flags or the like from the encoder side to the decoder side, or parameters, attributes or modes which are derivable in a corresponding or matching way at the encoder and decoder sides).

An example of a further candidate expression for the threshold is as follows:

BinCountsinNalUnits <= 10 * NumByteslnVclNalUnits +

(RawMinCuBits*PicSizelnMinCbsY)/16 (eq. 3)

So, although this eq. 3 could be used uniformly as discussed earlier, in example embodiments a selection is implemented between two or more candidate expressions, for example between eq. 1/2 (as equivalent expressions of the same thing) and eq. 3.

In some examples, the selection may be made in dependence upon whether a given coding attribute signalled in or with the encoded data stream is in a first or a second state, with a respective state of the given attribute corresponding to a selection, at the encoder side and the decoder side, of a respective candidate expression (for example, eq. 2 or eq. 3).

An example of such an attribute is the so-called“dep_quant_enabled_flag”. This indicates in a slice header whether or not a technique referred to as dependent quantisation is enabled in respect of the slice to which that slice header applies.

An alternative to the use of the dep_quant_enabled_flag is in fact a dependence on the availability of the (dep_quant) tool, rather than whether the tool is enabled. So for an example profile, the profile might itself defined (for example)“dep_quant_enabled_flag must be off (not enabled)”; in another there may be no such constraint, allow the dep_quant tool to be on (enabled) or off (not enabled). The selection of could therefore be made at the profile constraint, rather than on whether the dep_quant tool is currently enabled or disabled.

Dependent quantisation is defined in“Versatile Video Coding (Draft 5), Bross et al, JVET-N1001-v10, July 2019 (which is incorporated into the present description by reference); see for example section 8.7.3. It relates to a technique by which the decoding process selects between multiple possible quantisation parameters or sets of quantisation parameters, for example in response to a property (such as for example a parity property) of previously encoded and decoded sample values. So, when dep_quant_enabled_flag = 1 (enabled), such an ongoing dependent quantisation selection takes place. When dep_quant_enabled_flag = 0 (disabled), such an ongoing dependent quantisation selection does not take place. As mentioned above, the flag dep_quant_enabled_flag is provided (as an example of a coding attribute) for example in a slice header so that the enabling or disabling of dependent quantisation applies to whole slice.

A different constraint can be relevant when dependent quantisation is in use because of the empirical observation that dependent quantisation, when applied, can alter an expected relationship between encoded bins and decoded bins. A different constraint, such as eq. 3, can be more appropriate for use with dependent quantisation.

Where multiple candidate constraints are applicable, a decoder would be expected to be subject to a design constraint to provide sufficient processing power, speed or capacity to cope with encoded data generated under the more challenging (or most challenging) of the different available constraints.

More generally, however, any such attribute (for example a flag or parameter) could be used, whether or not it is explicitly signalled in or with the data stream. For example, different candidate expressions could be selected in respect of different respective instances of so-called “profiles”, where a profile in this context defines a set or basket of parameters such as bit depth, chrominance sampling (for example, 4:0:0 (monochrome), 4:2:0, 4:2:2, 4:4:4 or the like), restrictions on encoding type (such as intra-picture encoding only) and so on.

In example embodiments, an attribute defining some aspect of an output data unit can be used conveniently, because then the relevant threshold derivation can be applied to that output data unit. Examples of output data units in this context can include output data units representing respective image portions such as slices, tiles or pictures.

In some examples, as discussed above, the constraint or threshold is defined by an expression such as:

N <= K1 * B + (K2 * CU)

in which:

N = number of binarized symbols in the output data unit;

K1 is a constant;

B = number of encoded bytes for the output data unit = NumByteslnVclNalUnits;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data encoding apparatus; and

CU = size of the picture, slice or tile represented by the output data unit expressed as a number of coding units of minimum size.

It will be noted that this is in fact a generalisation of eq.1 , eq. 2 and eq. 3 discussed above, as follows:

With regard to the example of Eq. 5, the variable vcIByteScaleFactor can be expressed as:

vcIByteScaleFactor = (32 + 4*general_tier_flag) / 3

where general_tier_flag is an indicator of an encoding tier and varies (in at least some examples) as flag values of either 0 or 1 , with 0 indicating a so-called main tier and 1 indicating a so-called high tier. For a particular encoding level (representing maximum dimensions of the images to be encoded), the high tier generally corresponds to a higher bit rate representation than the main tier. In this example therefore, the image data encoding apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to generate a tier parameter (for example, to be encoded within or at least in association with the encoded image data or bitstream) defining the currently selected encoding tier, in which at least the constant K1 is dependent upon the tier parameter. For example, a higher tier parameter may indicate a higher quality encoded output for a given image size, and the parameter K1 may increase with the tier parameter.

This allows the processing, circuitry, code or logic used to generate the threshold value to be conveniently identical or substantially identical in each case, with the parameters K1 and K2 simply being altered in respect of each of the example equations eq.1 - eq. 4. However, it will be appreciated that one or more different equations or expressions (or even potentially different fixed threshold values) could be used, as between the different candidate thresholds or constraints.

Figure 36 is a schematic flowchart illustrating an image data encoding method, comprising:

encoding (at a step 3600) data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol; and

controlling (at a step 3610) the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controlling step comprising:

detecting (at a step 3620) an encoding attribute applicable to a given output data unit; and selecting (at a step 3630), in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

Example embodiments also provide an image decoder comprising circuitry configured to interpret an encoded signal having been generated by controlling the image data encoding apparatus of any one or more of the embodiments described here and to output decoded video images.

Example embodiments also provide an image decoder comprising circuitry configured to interpret an encoded signal having been generated by controlling the first and second data encoders and the controller of any one or more of the embodiments described here and to output decoded video images.

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. Image data encoding apparatus, comprising:

a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

the controller comprising:

a predictor configured to generate a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and a data router configured to route each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

2. The image data encoding apparatus of clause 1 , in which the first data encoder is a context adaptive binary arithmetic coding (CABAC) encoder.

3. The image data encoding apparatus of clause 1 or 2, in which the second data encoder is a bypass encoder.

4. The image data encoding apparatus of clause 3, in which the second data encoder is a binary arithmetic coder using a fixed 50% probability context model.

5. The image data encoding apparatus of any one of the preceding clauses, in which the output data unit is an independently decodable data unit.

6. The image data encoding apparatus of clause 5, in which the image portion is one of a picture, slice or tile.

7. The image data encoding apparatus of clause 6, in which the constraint is defined by:

N <= K1 * B + (K2 * CU)

in which:

N = number of binarized symbols in the output data unit;

K1 is a constant;

B = number of encoded bytes for the output data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data encoding apparatus; and

CU = size of the picture, slice or tile represented by the output data unit expressed as a number of coding units of minimum size.

8a. The image data encoding apparatus of clause 7, in which the apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to generate a tier parameter defining the currently selected encoding tier, at least the constant K1 being dependent upon the tier parameter.

8b. The image data encoding apparatus of any one of the preceding clauses, in which the apparatus is configured to encode image data as successive linear arrays of image blocks, image data of a given image block being encoded once image data in a previously encoded linear array, on which the encoding of the given image block depends, has been encoded.

9. The image data encoding apparatus of clause 8a or 8b, in which the apparatus comprises multiple instances of the first data encoder and the second data encoder, configured to concurrently encode two or more of the linear arrays of image blocks.

10. The image data encoding apparatus of clause 8a or 8b, in which each linear array of image blocks is an image portion represented by a respective output data unit.

11. The image data encoding apparatus of any one of the preceding clauses, comprising: a detector configured to detect, at a predetermined stage relative to the encoding of a current output data unit, whether the constraint will be met by the current output data unit; and a padding data generator configured to generate and insert in the current output data unit sufficient padding data so that the output data unit including the inserted padding data meets the constraint.

12. The image data encoding apparatus of clause 11 , in which the predetermined stage is the end of encoding the current output data unit.

13. The image data encoding apparatus of any one of the preceding clauses, in which: each symbol is associated with a default data encoder of the first data encoder and the second data encoder;

the data router is configured to selectively invert the default association so as to route symbols associated with one of the first and second data encoders to the other of the first and second data encoders.

14. The image data encoding apparatus of clause 13, in which:

within an image portion, the apparatus is configured to encode symbols representing plural sub-regions; and

the data router is configured to apply or disapply the selective inversion of the default association in respect of entire sub-regions.

15. The image data encoding apparatus of clause 14, in which:

the image portion comprises one of a picture, a slice and a tile.

16. The image data encoding apparatus of clause 14 or 15, in which:

the sub-regions comprise one or more of coding tree units, coding units, transform units and sub-portions of transform units.

17. The image data encoding apparatus of clause 16, in which the predictor is configured to generate the prediction in respect of a processing stage at a given boundary between a pair of adjacently processed sub-regions.

18. The image data encoding apparatus of clause 17, in which the data router is configured to apply the prediction to control selective inversion of the default association for a next sub- region to be processed starting from the given boundary.

19. The image data encoding apparatus of clause 17, in which the data router is configured to apply the prediction to control selective inversion of the default association for a subsequent sub-region to be processed starting from a further boundary between sub-regions following, in a sub-region processing order, the given boundary.

20. The image data encoding apparatus of clause 19, in which the further boundary is a boundary next following, in a sub-region processing order, the given boundary. 21. The image data encoding apparatus of any one of clauses 14 to 20, in which the predictor is configured to allocate a respective share of the upper limit to each sub-region and to generate a prediction in respect of each sub-region.

22. The image data encoding apparatus of clause 21 , in which the predictor is configured to vary the allocation of respective shares of the upper limit to each sub-region so that, for an earlier-encoded and a later-encoded sub-region of an equal number of symbols within the image portion, the allocation to the earlier-encoded sub-region is lower than the allocation to the later-encoded sub-region.

23. The image data encoding apparatus of any one of clauses 13 to 22, in which:

the symbols are associated with multiple symbol classes; and

the data router is configured to inhibit inverting the default association for one or more predetermined symbol classes.

24. Video storage, capture, transmission or reception apparatus comprising apparatus according to any one of the preceding clauses.

25. An image data encoding method, comprising:

encoding data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data;

the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

controlling the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

generating a prediction, during generation of the output data unit, of whether the constraint will be met by that output data unit; and

routing each symbol to either the first data encoder or the second data encoder in dependence upon a current state of the prediction generated by the predictor.

26. Computer software which, when executed by a computer, causes the computer to carry out the method of clause 25.

27. A machine-readable non-transitory storage medium which stores the computer software of clause 26.

28. A data signal comprising coded data generated according to the method of clause 25.

29. Image data decoding apparatus, comprising: a first data decoder and a second data decoder, each configured to decode binarized symbols to generate successive symbols representing image data;

the first data decoder being configured to decode binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to generate a fixed number of decoded data bits from each input binarized symbol;

the apparatus comprising a controller configured to control the first data decoder and the second data decoder to decode a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

the controller comprising:

a predictor configured to generate a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

a data router configured to route each binarized symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

30. The image data decoding apparatus of clause 29, in which the first data decoder is a context adaptive binary arithmetic coding (CABAC) decoder.

31. The image data decoding apparatus of clause 29 or 30, in which the second data decoder is a bypass decoder.

32. The image data decoding apparatus of clause 31 , in which the second data decoder is a binary arithmetic coder using a fixed 50% probability context model.

33. The image data decoding apparatus of any one of clauses 29 to 32, in which the data unit is an independently decodable data unit.

34. The image data decoding apparatus of clause 33, in which the image portion is one of a picture, slice or tile.

35. The image data decoding apparatus of clause 34, in which the constraint is defined by:

N <= K1 * B + (K2 * CU)

in which:

N = number of binarized symbols in the data unit;

K1 is a constant;

B = number of decoded bytes for the data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data decoding apparatus; and

CU = size of the picture, slice or tile represented by the data unit expressed as a number of coding units of minimum size. 36a The image data decoding apparatus of clause 35, in which the apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to detect a tier parameter defining the currently selected encoding tier, at least the constant K1 being dependent upon the detected tier parameter.

36b. The image data decoding apparatus of any one of clauses 29 to 35, in which the apparatus is configured to decode image data as successive linear arrays of image blocks, image data of a given image block being decoded once image data in a previously decoded linear array, on which the decoding of the given image block depends, has been decoded.

37. The image data decoding apparatus of clause 36a or 36b, in which the apparatus comprises multiple instances of the first data decoder and the second data decoder, configured to concurrently decode two or more of the linear arrays of image blocks.

38. The image data encoding apparatus of clause 36a, 36b or 37, in which each linear array of image blocks is an image portion represented by a respective output data unit.

39. The image data decoding apparatus of any one of clauses 29 to 38, in which:

each symbol is associated with a default data decoder of the first data decoder and the second data decoder;

the data router is configured to selectively invert the default association so as to route symbols associated with one of the first and second data decoders to the other of the first and second data decoders.

40. The image data decoding apparatus of clause 39, in which:

within an image portion, the apparatus is configured to decode symbols representing plural sub-regions; and

the data router is configured to apply or disapply the selective inversion of the default association in respect of entire sub-regions.

41. The image data decoding apparatus of clause 40, in which:

the image portion comprises one of a picture, a slice and a tile.

42. The image data decoding apparatus of clause 40 or 41 , in which:

the sub-regions comprise one or more of coding tree units, coding units, transform units and sub-portions of transform units.

43. The image data decoding apparatus of clause 42, in which the predictor is configured to generate the prediction in respect of a processing stage at a given boundary between a pair of adjacently processed sub-regions.

44. The image data decoding apparatus of clause 43, in which the data router is configured to apply the prediction to control selective inversion of the default association for a next sub- region to be processed starting from the given boundary.

45. The image data decoding apparatus of clause 43, in which the data router is configured to apply the prediction to control selective inversion of the default association for a subsequent sub-region to be processed starting from a further boundary between sub-regions following, in a sub-region processing order, the given boundary.

46. The image data decoding apparatus of clause 45, in which the further boundary is a boundary next following, in a sub-region processing order, the given boundary.

47. The image data decoding apparatus of any one of clauses 40 to 46, in which the predictor is configured to allocate a respective share of the upper limit to each sub-region and to generate a prediction in respect of each sub-region.

48. The image data decoding apparatus of clause 47, in which the predictor is configured to vary the allocation of respective shares of the upper limit to each sub-region so that, for an earlier-decoded and a later-decoded sub-region of an equal number of symbols within the image portion, the allocation to the earlier-decoded sub-region is lower than the allocation to the later-decoded sub-region.

49. The image data decoding apparatus of any one of clauses 47 to 48, in which:

the symbols are associated with multiple symbol classes; and

the data router is configured to inhibit inverting the default association for one or more predetermined symbol classes.

50. Video storage, capture, transmission or reception apparatus comprising apparatus according to any one of clauses 29 to 49.

51. An image data decoding method, comprising:

decoding data using a first data decoder and a second data decoder, each configured to decode binarized symbols into successive symbols representing image data;

the first data decoder being configured to decode data bits from binarized symbols at a variable ratio of a number of decoded data bits to a number of binarized symbols;

the second data decoder being configured to decode a fixed number of decoded data bits from each decoded binarized symbol;

controlling the first data decoder and the second data decoder to generate a data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual data unit relative to the size of that data unit;

generating a prediction, during generation of the data unit, of whether the constraint will be met by that data unit; and

routing each symbol to either the first data decoder or the second data decoder in dependence upon a current state of the prediction generated by the predictor.

52. Computer software which, when executed by a computer, causes the computer to carry out the method of clause 51.

53. A machine-readable non-transitory storage medium which stores the computer software of clause 52. 54. Image data encoding apparatus, comprising:

a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol;

the apparatus comprising a controller configured to control the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of symbols that may be expressed by any individual output data unit relative to the size of that output data unit;

the controller comprising:

an attribute detector configured to detect an encoding attribute applicable to a given output data unit; and

a selector configured to select, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

55. The image data encoding apparatus of clause 54, in which the first data encoder is a context adaptive binary arithmetic coding (CABAC) encoder.

56. The image data encoding apparatus of clause 54 or clause 55, in which the second data encoder is a bypass encoder.

57. The image data encoding apparatus of clause 56, in which the second data encoder is a binary arithmetic coder using a fixed 50% probability context model.

58. The image data encoding apparatus of any one of clauses 54 to 57, in which the output data unit is an independently decodable data unit.

59. The image data encoding apparatus of clause 58, in which the image portion is one of a picture, slice or tile.

60. The image data encoding apparatus of clause 59, in which the constraint is defined by:

N <= K1 * B + (K2 * CU) (constraint equation 1)

in which:

N = number of binarized symbols in the output data unit;

K1 is a constant;

B = number of encoded bytes for the output data unit;

K2 is a variable dependent upon properties of minimum size coding units employed by the image data encoding apparatus; and

CU = size of the picture, slice or tile represented by the output data unit expressed as a number of coding units of minimum size.

61. The image data encoding apparatus of clause 60, in which: at least two candidate constraints are defined by the constraint equation 1 , a respective set of (K1 , K2) being associated with each of the at least two candidate constraints; and

the selector is configured to select a set of (K1 , K2) for the given output data unit.

62a. The image data encoding apparatus of clause 61 , in which the apparatus is configured to operate at an encoding tier selected from at least two candidate encoding tiers and to generate a tier parameter defining the currently selected encoding tier, at least the constant K1 being dependent upon the tier parameter.

62b. The image data encoding apparatus of any one of clauses 54 to 62a, in which:

the controller is configured to encode a representation of the encoding attribute applicable to the given output data unit in association with an output data stream representing the given output data unit.

63. The image data encoding apparatus of clause 62a or 62b, in which:

the image data encoding apparatus comprises a quantiser configured to selectively operate in a dependent quantisation mode; and

the encoding attribute indicates whether the dependent quantisation mode is enabled or disabled in respect of the given output data unit.

64. The image data encoding apparatus of clause 63 in which, in the dependent quantisation mode, a selection of a quantisation parameter for use in quantising a current data value depends at least in part on a property of a previously encoded data value.

65. The image data encoding apparatus of any one of clauses 54 to 64, comprising:

a padding data detector configured to detect, at a predetermined stage relative to the encoding of a current output data unit, whether the constraint will be met by the current output data unit; and

a padding data generator configured to generate and insert in the current output data unit sufficient padding data so that the output data unit including the inserted padding data meets the constraint.

66. The image data encoding apparatus of clause 65, in which the predetermined stage is the end of encoding the current output data unit.

67. The image data encoding apparatus of clause 66, in which:

the image portion comprises one of a picture, a slice and a tile.

68. Video storage, capture, transmission or reception apparatus comprising apparatus according to any one of clauses 54 to 67.

69. An image data encoding method, comprising:

encoding data using a first data encoder and a second data encoder, each configured to generate output data bits representing binarized symbols from successive symbols representing image data; the first data encoder being configured to generate output data bits representing encoded symbols at a variable ratio of a number of data bits to a number of encoded symbols; the second data encoder being configured to generate a fixed number of output data bits to represent each encoded symbol; and

controlling the first data encoder and the second data encoder to generate an output data unit representing a set of symbols of an image portion, subject to a constraint defining an upper limit to the number of binarized symbols that may be expressed by any individual output data unit relative to the size of that output data unit; the controlling step comprising:

detecting an encoding attribute applicable to a given output data unit; and

selecting, in response to the detected encoding attribute, a constraint, for use with the given output data unit, from two or more candidate constraints.

70. Computer software which, when executed by a computer, causes the computer to carry out the method of clause 69.

71. A machine-readable non-transitory storage medium which stores the computer software of clause 70.

72. A data signal comprising coded data generated according to the method of clause 69.

Described embodiments may be implemented in any suitable form including hardware, software, firmware or any combination of these. Described embodiments may optionally be implemented at least partly as computer software running on one or more data processors and/or digital signal processors. The elements and components of any embodiment may be physically, functionally and logically implemented in any suitable way. Indeed the functionality may be implemented in a single unit, in a plurality of units or as part of other functional units. As such, the disclosed embodiments may be implemented in a single unit or may be physically and functionally distributed between different units, circuitry and/or processors. 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.