Information technology — JPEG XS low-latency lightweight image coding system — Part 1: Core coding system

This document defines the syntax and an accompanying decompression process that is capable to represent continuous-tone grey-scale, or continuous-tone colour digital images without visual loss at moderate compression rates. Typical compression rates are between 2:1 and 6:1 but can also be higher depending on the nature of the image. In particular, the syntax and the decoding process specified in this document allow lightweight encoder and decoder implementations that limit the end-to-end latency to a fraction of the frame size. However, the definition of transmission channel buffer models necessary to ensure such latency is beyond the scope of this document. This document: — specifies decoding processes for converting compressed image data to reconstructed image data; — specifies a codestream syntax containing information for interpreting the compressed image data; — provides guidance on encoding processes for converting source image data to compressed image data.

Technologies de l'information — Système de codage d'images léger à faible latence JPEG XS — Partie 1: Système de codage de noyau

General Information

Status
Published
Publication Date
28-Mar-2022
Current Stage
9092 - International Standard to be revised
Completion Date
16-Jun-2022
Ref Project

Relations

Buy Standard

Standard
ISO/IEC 21122-1:2022 - Information technology — JPEG XS low-latency lightweight image coding system — Part 1: Core coding system Released:3/29/2022
English language
100 pages
sale 15% off
Preview
sale 15% off
Preview
Draft
ISO/IEC FDIS 21122-1 - Information technology -- JPEG XS low-latency lightweight image coding system
English language
100 pages
sale 15% off
Preview
sale 15% off
Preview

Standards Content (Sample)

INTERNATIONAL ISO/IEC
STANDARD 21122-1
Second edition
2022-03
Information technology — JPEG XS
low-latency lightweight image coding
system —
Part 1:
Core coding system
Technologies de l'information — Système de codage d'images léger à
faible latence JPEG XS —
Partie 1: Système de codage de noyau
Reference number
ISO/IEC 21122-1:2022(E)
© ISO/IEC 2022

---------------------- Page: 1 ----------------------
ISO/IEC 21122-1:2022(E)
COPYRIGHT PROTECTED DOCUMENT
© ISO/IEC 2022
All rights reserved. Unless otherwise specified, or required in the context of its implementation, no part of this publication may
be reproduced or utilized otherwise in any form or by any means, electronic or mechanical, including photocopying, or posting on
the internet or an intranet, without prior written permission. Permission can be requested from either ISO at the address below
or ISO’s member body in the country of the requester.
ISO copyright office
CP 401 • Ch. de Blandonnet 8
CH-1214 Vernier, Geneva
Phone: +41 22 749 01 11
Email: copyright@iso.org
Website: www.iso.org
Published in Switzerland
ii
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 2 ----------------------
ISO/IEC 21122-1:2022(E)
Contents Page
Foreword .iv
Introduction .v
1 Scope . 1
2 Normative references . 1
3 Terms and definitions, abbreviated terms and symbols . 1
3.1 Terms and definitions . 1
3.2 Abbreviated terms . 6
3.3 Symbols . 6
4 Conventions . 9
4.1 Conformance language . 9
4.2 Operators . 9
4.2.1 Arithmetic operators . 9
4.2.2 Logical operators . 10
4.2.3 Relational operators . 10
4.2.4 Precedence order of operators . 10
4.2.5 Mathematical functions . 11
5 Functional concepts . .11
5.1 Sample grid, sampling and components . 11
5.2 Interpretation of CFA data .12
5.3 Wavelet decomposition .12
5.4 Codestream. 13
6 Encoder requirements .13
7 Decoder .13
7.1 Decoding process general provisions . 13
7.2 Decoder requirements .15
Annex A (normative) Codestream syntax .16
Annex B (normative) Image data structures .29
Annex C (normative) Entropy decoding .42
Annex D (normative) Quantization .60
Annex E (normative) Discrete wavelet transformation .64
Annex F (normative) Multiple component transformations .74
Annex G (normative) DC level shifting, non-linear transform and output clipping .85
Annex H (informative) Example weight tables .92
Bibliography . 100
iii
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 3 ----------------------
ISO/IEC 21122-1:2022(E)
Foreword
ISO (the International Organization for Standardization) and IEC (the International Electrotechnical
Commission) form the specialized system for worldwide standardization. National bodies that are
members of ISO or IEC participate in the development of International Standards through technical
committees established by the respective organization to deal with particular fields of technical
activity. ISO and IEC technical committees collaborate in fields of mutual interest. Other international
organizations, governmental and non-governmental, in liaison with ISO and IEC, also take part in the
work.
The procedures used to develop this document and those intended for its further maintenance
are described in the ISO/IEC Directives, Part 1. In particular, the different approval criteria
needed for the different types of document should be noted. This document was drafted in
accordance with the editorial rules of the ISO/IEC Directives, Part 2 (see www.iso.org/directives or
www.iec.ch/members_experts/refdocs).
Attention is drawn to the possibility that some of the elements of this document may be the subject
of patent rights. ISO and IEC shall not be held responsible for identifying any or all such patent
rights. Details of any patent rights identified during the development of the document will be in the
Introduction and/or on the ISO list of patent declarations received (see www.iso.org/patents) or the IEC
list of patent declarations received (see patents.iec.ch).
Any trade name used in this document is information given for the convenience of users and does not
constitute an endorsement.
For an explanation of the voluntary nature of standards, the meaning of ISO specific terms and
expressions related to conformity assessment, as well as information about ISO's adherence to
the World Trade Organization (WTO) principles in the Technical Barriers to Trade (TBT) see
www.iso.org/iso/foreword.html. In the IEC, see www.iec.ch/understanding-standards.
This document was prepared by Joint Technical Committee ISO/IEC JTC 1, Information technology,
Subcommittee SC 29, Coding of audio, picture, multimedia and hypermedia information.
This second edition cancels and replaces the first edition (ISO/IEC 21122-1:2019), which has been
technically revised.
The main changes are as follows:
— coding tools for compressing colour filter array images (CFA images) have been added;
— coding tools that enable lossless coding of images with up to 12 bits per sample have been added;
— support for 4:2:0 sampled images has been added.
A list of all parts in the ISO/IEC 21122 series can be found on the ISO and IEC websites.
Any feedback or questions on this document should be directed to the user’s national standards
body. A complete listing of these bodies can be found at www.iso.org/members.html and
www.iec.ch/national-committees.
iv
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 4 ----------------------
ISO/IEC 21122-1:2022(E)
Introduction
The International Organization for Standardization (ISO) and International Electrotechnical
Commission (IEC) draw attention to the fact that it is claimed that compliance with this document may
involve the use of patents.
ISO and IEC take no position concerning the evidence, validity and scope of these patent rights.
The holders of these patent rights have assured ISO and IEC that they are willing to negotiate licences
under reasonable and non-discriminatory terms and conditions with applicants throughout the world.
In this respect, the statements of the holders of these patent rights are registered with ISO and IEC.
Information may be obtained from the patent database available at www.iso.org/patents.
Attention is drawn to the possibility that some of the elements of this document may be the subject
of patent rights other than those in the patent database. ISO and IEC shall not be held responsible for
identifying any or all such patent rights.
v
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 5 ----------------------
INTERNATIONAL STANDARD ISO/IEC 21122-1:2022(E)
Information technology — JPEG XS low-latency lightweight
image coding system —
Part 1:
Core coding system
1 Scope
This document defines the syntax and an accompanying decompression process that is capable to
represent continuous-tone grey-scale, or continuous-tone colour digital images without visual loss at
moderate compression rates. Typical compression rates are between 2:1 and 6:1 but can also be higher
depending on the nature of the image. In particular, the syntax and the decoding process specified
in this document allow lightweight encoder and decoder implementations that limit the end-to-end
latency to a fraction of the frame size. However, the definition of transmission channel buffer models
necessary to ensure such latency is beyond the scope of this document.
This document:
— specifies decoding processes for converting compressed image data to reconstructed image data;
— specifies a codestream syntax containing information for interpreting the compressed image data;
— provides guidance on encoding processes for converting source image data to compressed image
data.
2 Normative references
There are no normative references in this document.
3 Terms and definitions, abbreviated terms and symbols
3.1 Terms and definitions
For the purposes of this document, the following terms and definitions apply.
ISO and IEC maintain terminology databases for use in standardization at the following addresses:
— ISO Online browsing platform: available at https:// www .iso .org/ obp
— IEC Electropedia: available at https:// www .electropedia .org/
3.1.1
band
input data to a specific wavelet filter type (3.1.58) that contributes to the generation of one of the
components (3.1.14) of the image
3.1.2
band type
single number collapsing the information on the component, and horizontal and vertical wavelet
filter types that are applied in the filter cascade reconstructing spatial image samples from inversely
quantized wavelet coefficients
1
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 6 ----------------------
ISO/IEC 21122-1:2022(E)
3.1.3
bit
binary choice encoded as either 0 or 1
3.1.4
bitplane
array of bits having all the same significance
3.1.5
bitplane count
number of significant bitplanes of a code group, counting from the LSB up to the most significant, non-
empty bitplane
3.1.6
bitplane count subpacket
subset of a packet which decodes to the bitplane counts of all code groups within a packet, followed by
padding and optional filler bytes
Note 1 to entry: See subclause C.5.3.
3.1.7
byte
group of 8 bits
3.1.8
colour filter array
CFA
rectangular array of sensor elements yielding a 1-component picture where the colour to which a sensor
element is sensitive to depends on the position of the sensor element
3.1.9
codestream
compressed image data representation that includes all necessary data to allow a (full or approximate)
reconstruction of the sample values of a digital image
3.1.10
code group
group of quantization indices in sign-magnitude representation before inverse quantization
3.1.11
coefficient
input value to the inverse wavelet transformation resulting from inverse quantization
3.1.12
coefficient group
number of horizontally adjacent wavelet coefficients from the same band
3.1.13
column
set of vertically aligned precincts
3.1.14
component
two-dimensional array of samples having the same designation such as red, green or blue in the output
or display device
3.1.15
compression
process of reducing the number of bits used to represent source image data
2
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 7 ----------------------
ISO/IEC 21122-1:2022(E)
3.1.16
continuous-tone image
image whose components have more than one bit per sample
3.1.17
data subpacket
subset of a packet which consists of the quantization index magnitudes, followed by padding and
optional filler bytes
Note 1 to entry: See subclause C.5.4.
3.1.18
deadzone quantizer
quantizer whose zero bucket has a size different from all other buckets
3.1.19
decoder
embodiment of a decoding process
3.1.20
decoding process
process which takes as its input a codestream and outputs a continuous-tone image
3.1.21
decomposition level
set of wavelet coefficients resulting from a particular level of recursive application of a wavelet
transform
3.1.22
downsampling
procedure by which the spatial resolution of a component is reduced
3.1.23
encoder
embodiment of an encoding process.
3.1.24
encoding process
process which outputs compressed image data in the form of a codestream
3.1.25
entropy decoder
embodiment of an entropy decoding procedure
3.1.26
entropy decoding
lossless procedure which recovers the sequence of symbols from the sequence of bits produced by the
entropy encoder
3.1.27
entropy encoder
embodiment of an entropy encoding procedure
3.1.28
entropy encoding
lossless procedure which converts a sequence of input symbols into a sequence of bits such that the
average number of bits per symbol approaches the entropy of the input symbols
3
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 8 ----------------------
ISO/IEC 21122-1:2022(E)
3.1.29
filler bytes
integer number of bytes a decoder will skip over on decoding without interpreting the values of the
bytes itself
3.1.30
grayscale image
continuous-tone image that has only one component
3.1.31
inverse quantization
inverse procedure to quantization by which the decoder recovers a representation of the coefficients
3.1.32
inverse reversible multi component transformation
inverse RCT
inverse transformation across multiple component sample values located at the same sample grid point
that is invertible without loss
Note 1 to entry: See subclauses F.3 and F.4.
3.1.33
LL band
input to a series of wavelet filters where only inverse low-pass filters are applied in horizontal and
vertical direction
3.1.34
lossless
descriptive term for encoding and decoding processes and procedures in which the output of the
decoding procedure(s) is identical to the input to the encoding procedure(s)
3.1.35
lossless coding
mode of operation which refers to any one of the coding processes defined in this document in which all
of the procedures are lossless
3.1.36
lossy
descriptive term for encoding and decoding processes which are not lossless
3.1.37
packet
segment of the codestream containing entropy coded information on a single precinct, line and a subset
of the bands within this precinct and line
3.1.38
padding
bits within the codestream whose only purpose is to align syntax elements to byte boundaries and that
carry no information
3.1.39
precinct
collection of quantization indices of all bands contributing to a given spatial region of the image
3.1.40
precision
number of bits allocated to a particular sample, coefficient, or other binary numerical representation
3.1.41
procedure
set of steps which accomplishes one of the tasks which comprise an encoding or decoding process
4
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 9 ----------------------
ISO/IEC 21122-1:2022(E)
3.1.42
quantization
method of reducing the precision of the individual coefficients
3.1.43
quantization index
input to the inverse quantization process which reconstructs the quantization index to a wavelet
coefficient
3.1.44
quantization index magnitude
absolute value of a quantization index
3.1.45
sample
one element in the two-dimensional image array which comprises a component
3.1.46
sample grid
common coordinate system for all samples of an image, the samples at the top left edge of the image
have the coordinates (0,0), the first coordinate increases towards the right, the second towards the
bottom
3.1.47
sign subpacket
subset of a packet that consists of the sign information of all non-zero quantization indices within a
packet, followed by padding and optional filler bytes
Note 1 to entry: See subclause C.5.5.
3.1.48
significance
attribute of code groups that applies if, depending on the Run Mode flag in the picture header, either at
least one of coefficients in the code group is non-zero, or the bitplane count prediction residual of the
code group is non-zero
3.1.49
significance group
group of a horizontally adjacent code groups sharing the same significance information in the
significance subpacket
3.1.50
significance subpacket
subset of a packet that identifies which significance groups within a packet are insignificant, followed
by padding and optional filler bytes
Note 1 to entry: see subclause C.5.2
3.1.51
slice
integral number of precincts whose wavelet coefficients can be entropy-decoded independently
3.1.52
star-tetrix
decorrelation transformation that combines a spatial with an inter-component decorrelation
transformation particularly tuned for CFA pattern compression
Note 1 to entry: see subclause F.5
5
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 10 ----------------------
ISO/IEC 21122-1:2022(E)
3.1.53
subpacket
substructure of a packet containing information of one or multiple bands of one line of a single precinct
3.1.54
super pixel
2×2 arrangement of sensor elements in a CFA pattern array containing at least one sensor element for
each colour filter type
3.1.55
truncation position
number of least significant bitplanes not included in the quantization index of a wavelet coefficient
3.1.56
uniform quantizer
quantizer whose buckets are all of equal size
3.1.57
upsampling
procedure by which the spatial resolution of a component is increased
3.1.58
wavelet filter type
single number that uniquely identifies each element of the wavelet filter with regard to the number and
type of horizontal and vertical decompositions
Note 1 to entry: Unlike the band type, the wavelet filter type does not include component information.
3.2 Abbreviated terms
JPEG XS informal name of this standard where XS stands for “extra speed”
LSB least significant bit
MSB most significant bit
3.3 Symbols
B[c] bit precision of component c
β wavelet filter type
b band type
b [β,i] band existence flag for filter type β in component i. 1 if the filter exists, 0 otherwise.
x
b' [b] band existence flag for band type b. 1 if the filter exists, 0 otherwise.
x
Bw nominal overall bit precision of the wavelet data
B number of bits required to encode a bitplane count in raw
r
Cpih colour transformation type
c[p,λ,b,x] wavelet coefficient in precinct p, line λ, band b and position x
C width of precincts other than the rightmost precinct in sample grid positions
s
C colour transformation CFA pattern type derived from the component registration
t
6
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 11 ----------------------
ISO/IEC 21122-1:2022(E)
C colour transformation reflection and extension flags
f
Cw width of precincts in multiples of 8 LL subsampled band sample grid positions
D[p,b] bitplane count coding mode of band b in precinct p
D [p,s] raw coding mode override flag for packet s in precinct p
r
DCO DC offset
d [β,i] horizontal decomposition level of wavelet filter type β of component i
x
d [β,i] vertical decomposition level of wavelet filter type β of component i
y
δ [c] horizontal position of component c in a CFA super pixel
x
δ [c] vertical position of component c in a CFA super pixel
y
E exponent of the slope of the linear region of the extended non-linearity
e colour transformation exponent of first chroma component
1
e colour transformation exponent of second chroma component
2
Fs sign packing flag
Fslc slice coding mode
Fq number of fractional bits in the representation of wavelet coefficients
G[b] gain of subband b
H [β,k] height of filter type β of component k in wavelet coefficients
b
H [i] height of the component i in sample points
c
H height of the image in sampling grid points
f
H height of a precinct in lines
p
H height of a slice in precincts
sl
I[p,b,λ,s] line inclusion flag, set if line λ of band b and precinct p is included in packet s, reset otherwise
k[δ , δ ] Component within CFA super pixel at position δ , δ
x y x y
L [p,b] first line of band b in precinct p
0
L [p,b] last line + 1 of band b in precinct p
1
Lcod codestream length in bytes
L [p,s] size of the bitplane count subpacket of precinct p and packet s in bytes
cnt
L [p,s] size of the data subpacket of precinct p and packet s in bytes
dat
Lh long header flag in in the picture header, set if long headers are enforced, reset otherwise
L [p] length of the entropy coded data in precinct p
prc
L [p,s] size of the sign subpacket of precinct p and packet s in bytes
sgn
7
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 12 ----------------------
ISO/IEC 21122-1:2022(E)
L [p,s] size of the significance subpacket of precinct p and packet s in bytes
sig
M[p,λ,b,g] bitplane count of precinct p, line λ, band b and code group g
M [p,λ,b,g] vertical predictor of the bitplane count of precinct p, line λ, band b and code group g
top
N number of components in an image
c
N [p,b] number of code groups in precinct p and band b
cg
N number of bands per component
β
N number of coefficients in a code group
g
N [p,b] number of significance groups per line band b of precinct p
s
N [t] number of precincts in slice t
p
N number of bands in the wavelet decomposition of the image (wavelet filter types times
L
components)
N maximal number of horizontal decomposition levels
L,x
N' [i] number of horizontal decomposition levels of component i
L,x
N maximal number of vertical decomposition levels over all components
L,y
N' [i] number of vertical decomposition levels of component i
L,y
N number of precincts per sampling grid line
p,x
N number of precincts per sampling grid column
p,y
N [p] number of packets in precinct p
pc
O[c,x,y] unscaled output of the inverse wavelet transformation at coordinates x and y of the com-
ponent c
Ω[c,x,y] output of the inverse multiple component transformation at position x,y for component c
P[b] priority of band b
Plev level a particular codestream complies to
Ppih profile a particular codestream complies to
Ppoc progression order in which bands are transmitted in the codestream
Q[p] quantization parameter of precinct p
Qpih quantization type of the picture
Rl raw-mode selection per packet flag
Rm run mode used for significance coding
R[p] refinement of precinct p
R[c,x,y] reconstructed sample value at position x,y for component c
Sd number of components for which wavelet decomposition is suppressed
8
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 13 ----------------------
ISO/IEC 21122-1:2022(E)
S size of a significance group in code groups
s
s [i] sampling factor of component i in horizontal direction
x
s [i] sampling factor of component i in vertical direction
y
s[p,λ,b,x] sign of the wavelet coefficient in precinct p, line λ, band b and position x.
T1 first threshold of the extended non-linearity
T2 second threshold of the extended non-linearity
T[p,b] truncation position of precinct p and band b
T [p,b] vertical Truncation position predictor of precinct p and band b
top
T[β,x,y] temporary wavelet coefficient of filter type β at location x,y.
v[x,y] sample value at the sample grid position x,y
v[p,λ,b,x] quantization index magnitude of the wavelet coefficient in precinct p, line λ, band b and
position x
W [β,k] width of filter type β of component k in wavelet coefficients
b
W [i] width of component i in samples
c
W width of the image in sampling grid points
f
W [p] width of the precinct p in sampling grid points
p
W [p,b] width of subband b of precinct p in coefficients
pb
Wt wavelet filter type for horizontal filtering
x
Wt wavelet filter type for vertical filtering
y
X[y] one-dimensional temporal array of wavelet coefficients
Xcrg[c] horizontal component registration of component c relative to the sample grid
Ycrg[c] vertical component registration of component c relative to the sample grid
Yslh vertical slice order within the picture
Z[p,λ,b,j] significance flag of precinct p, line λ, band b and significance group j
4 Conventions
4.1 Conformance language
The keyword "reserved" indicates a provision that is not specified at this time, shall not be used, and
may be specified in the future. The keyword "forbidden" indicates "reserved" and in addition indicates
that the provision will never be specified in the future.
4.2 Operators
NOTE Many of the operators used in document are similar to those used in the C programming language.
4.2.1 Arithmetic operators
9
© ISO/IEC 2022 – All rights reserved

---------------------- Page: 14 ----------------------
ISO/IEC 21122-1:2022(E)
& bitwise AND operation
+ addition
− subtraction (as a binary operator) or negation (as a unary prefix operator)
× multiplication
/ division without truncation or rounding
s
<< left shift: x< s
>> right shift: x>>s is defined as ⎿x/2 ⏌
umod x umod a is the unique value y between 0 and a–1 for which y+Na = x with a suitable integer N
4.2.2 Logical operators
|| logical OR
&& logical AND
! logical NOT
4.2.3 Relational operators
> greater than
≥ greater than or equal to
< less than
≤ less than or equal to
== equal to
!= not equal to
4.2.4 Precedence order of operators
NOTE Operators are listed below in descending order of precedence. If several operators appear in the same
line, they have equal precedence. When several operators of equal precedence appear at the same level in an
expression, evaluation proceeds according to the associativity of the operator either from right to left or from
left to right.
Operators Type of operation Associativity
() expression left to right
[] indexing of arrays left to right
– unary negation
×, / multiplication, division left to right
mod modulo (remainder) left to right
+, − addition and subtraction left to right
10
  © ISO/IEC 2022 – All rights reserved

---------------------- Page: 15 ----------------------
ISO/IEC 21122-1:2022(E)
<<, >> lef
...

FINAL
INTERNATIONAL ISO/IEC
DRAFT
STANDARD FDIS
21122-1
ISO/IEC JTC 1/SC 29
Information technology — JPEG XS
Secretariat: JISC
low-latency lightweight image coding
Voting begins on:
2021-10-13 system —
Voting terminates on:
Part 1:
2021-12-08
Core coding system
RECIPIENTS OF THIS DRAFT ARE INVITED TO
SUBMIT, WITH THEIR COMMENTS, NOTIFICATION
OF ANY RELEVANT PATENT RIGHTS OF WHICH
THEY ARE AWARE AND TO PROVIDE SUPPOR TING
DOCUMENTATION.
IN ADDITION TO THEIR EVALUATION AS
Reference number
BEING ACCEPTABLE FOR INDUSTRIAL, TECHNO-
ISO/IEC FDIS 21122-1:2021(E)
LOGICAL, COMMERCIAL AND USER PURPOSES,
DRAFT INTERNATIONAL STANDARDS MAY ON
OCCASION HAVE TO BE CONSIDERED IN THE
LIGHT OF THEIR POTENTIAL TO BECOME STAN-
DARDS TO WHICH REFERENCE MAY BE MADE IN
NATIONAL REGULATIONS. © ISO/IEC 2021

---------------------- Page: 1 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
COPYRIGHT PROTECTED DOCUMENT
© ISO/IEC 2021
All rights reserved. Unless otherwise specified, or required in the context of its implementation, no part of this publication may
be reproduced or utilized otherwise in any form or by any means, electronic or mechanical, including photocopying, or posting on
the internet or an intranet, without prior written permission. Permission can be requested from either ISO at the address below
or ISO’s member body in the country of the requester.
ISO copyright office
CP 401 • Ch. de Blandonnet 8
CH-1214 Vernier, Geneva
Phone: +41 22 749 01 11
Email: copyright@iso.org
Website: www.iso.org
Published in Switzerland
ii
  © ISO/IEC 2021 – All rights reserved

---------------------- Page: 2 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
Contents Page
Foreword .iv
Introduction .v
1 Scope . 1
2 Normative references . 1
3 Terms and definitions, abbreviated terms and symbols . 1
3.1 Terms and definitions . 1
3.2 Abbreviated terms . 6
3.3 Symbols . 6
4 Conventions . 9
4.1 Conformance language . 9
4.2 Operators . 9
4.2.1 Arithmetic operators . 9
4.2.2 Logical operators . 10
4.2.3 Relational operators . 10
4.2.4 Precedence order of operators . 10
4.2.5 Mathematical functions . 11
5 Functional concepts . .11
5.1 Sample grid, sampling and components . 11
5.2 Interpretation of CFA data .12
5.3 Wavelet decomposition .12
5.4 Codestream. 13
6 Encoder requirements .13
7 Decoder .13
7.1 Decoding process general provisions . 13
7.2 Decoder requirements .15
Annex A (normative) Codestream syntax .16
Annex B (normative) Image data structures .29
Annex C (normative) Entropy decoding .42
Annex D (normative) Quantization .60
Annex E (normative) Discrete wavelet transformation .64
Annex F (normative) Multiple component transformations .74
Annex G (normative) DC level shifting, non-linear transform and output clipping .85
Annex H (informative) Example weight tables .92
Bibliography . 100
iii
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 3 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
Foreword
ISO (the International Organization for Standardization) and IEC (the International Electrotechnical
Commission) form the specialized system for worldwide standardization. National bodies that are
members of ISO or IEC participate in the development of International Standards through technical
committees established by the respective organization to deal with particular fields of technical
activity. ISO and IEC technical committees collaborate in fields of mutual interest. Other international
organizations, governmental and non-governmental, in liaison with ISO and IEC, also take part in the
work.
The procedures used to develop this document and those intended for its further maintenance
are described in the ISO/IEC Directives, Part 1. In particular, the different approval criteria
needed for the different types of document should be noted. This document was drafted in
accordance with the editorial rules of the ISO/IEC Directives, Part 2 (see www.iso.org/directives or
www.iec.ch/members_experts/refdocs).
Attention is drawn to the possibility that some of the elements of this document may be the subject
of patent rights. ISO and IEC shall not be held responsible for identifying any or all such patent
rights. Details of any patent rights identified during the development of the document will be in the
Introduction and/or on the ISO list of patent declarations received (see www.iso.org/patents) or the IEC
list of patent declarations received (see patents.iec.ch).
Any trade name used in this document is information given for the convenience of users and does not
constitute an endorsement.
For an explanation of the voluntary nature of standards, the meaning of ISO specific terms and
expressions related to conformity assessment, as well as information about ISO's adherence to
the World Trade Organization (WTO) principles in the Technical Barriers to Trade (TBT) see
www.iso.org/iso/foreword.html. In the IEC, see www.iec.ch/understanding-standards.
This document was prepared by Joint Technical Committee ISO/IEC JTC 1, Information technology,
Subcommittee SC 29, Coding of audio, picture, multimedia and hypermedia information.
This second edition cancels and replaces the first edition (ISO/IEC 21122-1:2019), which has been
technically revised.
The main changes are as follows:
— coding tools for compressing colour filter array images (CFA images) have been added;
— coding tools that enable lossless coding of images with up to 12 bits per sample have been added;
— support for 4:2:0 sampled images has been added.
A list of all parts in the ISO/IEC 21122 series can be found on the ISO and IEC websites.
Any feedback or questions on this document should be directed to the user’s national standards
body. A complete listing of these bodies can be found at www.iso.org/members.html and
www.iec.ch/national-committees.
iv
 © ISO/IEC 2021 – All rights reserved

---------------------- Page: 4 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
Introduction
The International Organization for Standardization (ISO) and International Electrotechnical
Commission (IEC) draw attention to the fact that it is claimed that compliance with this document may
involve the use of patents.
ISO and IEC take no position concerning the evidence, validity and scope of these patent rights.
The holders of these patent rights have assured ISO and IEC that they are willing to negotiate licences
under reasonable and non-discriminatory terms and conditions with applicants throughout the world.
In this respect, the statements of the holders of these patent rights are registered with ISO and IEC.
Information may be obtained from the patent database available at www.iso.org/patents.
Attention is drawn to the possibility that some of the elements of this document may be the subject
of patent rights other than those in the patent database. ISO and IEC shall not be held responsible for
identifying any or all such patent rights.
v
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 5 ----------------------
FINAL DRAFT INTERNATIONAL STANDARD ISO/IEC FDIS 21122-1:2021(E)
Information technology — JPEG XS low-latency lightweight
image coding system —
Part 1:
Core coding system
1 Scope
This document defines the syntax and an accompanying decompression process that is capable to
represent continuous-tone grey-scale, or continuous-tone colour digital images without visual loss at
moderate compression rates. Typical compression rates are between 2:1 and 6:1 but can also be higher
depending on the nature of the image. In particular, the syntax and the decoding process specified
in this document allow lightweight encoder and decoder implementations that limit the end-to-end
latency to a fraction of the frame size. However, the definition of transmission channel buffer models
necessary to ensure such latency is beyond the scope of this document.
This document:
— specifies decoding processes for converting compressed image data to reconstructed image data;
— specifies a codestream syntax containing information for interpreting the compressed image data;
— provides guidance on encoding processes for converting source image data to compressed image
data.
2 Normative references
There are no normative references in this document.
3 Terms and definitions, abbreviated terms and symbols
3.1 Terms and definitions
For the purposes of this document, the following terms and definitions apply.
ISO and IEC maintain terminological databases for use in standardization at the following addresses:
— ISO Online browsing platform: available at https:// www .iso .org/ obp
— IEC Electropedia: available at https:// www .electropedia .org/
3.1.1
band
input data to a specific wavelet filter type (3.1.58) that contributes to the generation of one of the
components (3.1.14) of the image
3.1.2
band type
single number collapsing the information on the component, and horizontal and vertical wavelet
filter types that are applied in the filter cascade reconstructing spatial image samples from inversely
quantized wavelet coefficients
1
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 6 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
3.1.3
bit
binary choice encoded as either 0 or 1
3.1.4
bitplane
array of bits having all the same significance
3.1.5
bitplane count
number of significant bitplanes of a code group, counting from the LSB up to the most significant, non-
empty bitplane
3.1.6
bitplane count subpacket
subset of a packet which decodes to the bitplane counts of all code groups within a packet, followed by
padding and optional filler bytes
Note 1 to entry: See subclause C.5.3.
3.1.7
byte
group of 8 bits
3.1.8
colour filter array
CFA
rectangular array of sensor elements yielding a 1-component picture where the colour to which a sensor
element is sensitive to depends on the position of the sensor element
3.1.9
codestream
compressed image data representation that includes all necessary data to allow a (full or approximate)
reconstruction of the sample values of a digital image
3.1.10
code group
group of quantization indices in sign-magnitude representation before inverse quantization
3.1.11
coefficient
input value to the inverse wavelet transformation resulting from inverse quantization
3.1.12
coefficient group
number of horizontally adjacent wavelet coefficients from the same band
3.1.13
column
set of vertically aligned precincts
3.1.14
component
two-dimensional array of samples having the same designation such as red, green or blue in the output
or display device
3.1.15
compression
process of reducing the number of bits used to represent source image data
2
  © ISO/IEC 2021 – All rights reserved

---------------------- Page: 7 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
3.1.16
continuous-tone image
image whose components have more than one bit per sample
3.1.17
data subpacket
subset of a packet which consists of the quantization index magnitudes, followed by padding and
optional filler bytes
Note 1 to entry: See subclause C.5.4.
3.1.18
deadzone quantizer
quantizer whose zero bucket has a size different from all other buckets
3.1.19
decoder
embodiment of a decoding process
3.1.20
decoding process
process which takes as its input a codestream and outputs a continuous-tone image
3.1.21
decomposition level
set of wavelet coefficients resulting from a particular level of recursive application of a wavelet
transform
3.1.22
downsampling
procedure by which the spatial resolution of a component is reduced
3.1.23
encoder
embodiment of an encoding process.
3.1.24
encoding process
process which outputs compressed image data in the form of a codestream
3.1.25
entropy decoder
embodiment of an entropy decoding procedure
3.1.26
entropy decoding
lossless procedure which recovers the sequence of symbols from the sequence of bits produced by the
entropy encoder
3.1.27
entropy encoder
embodiment of an entropy encoding procedure
3.1.28
entropy encoding
lossless procedure which converts a sequence of input symbols into a sequence of bits such that the
average number of bits per symbol approaches the entropy of the input symbols
3
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 8 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
3.1.29
filler bytes
integer number of bytes a decoder will skip over on decoding without interpreting the values of the
bytes itself
3.1.30
grayscale image
continuous-tone image that has only one component
3.1.31
inverse quantization
inverse procedure to quantization by which the decoder recovers a representation of the coefficients
3.1.32
inverse reversible multi component transformation
inverse RCT
inverse transformation across multiple component sample values located at the same sample grid point
that is invertible without loss
Note 1 to entry: See subclauses F.3 and F.4.
3.1.33
LL band
input to a series of wavelet filters where only inverse low-pass filters are applied in horizontal and
vertical direction
3.1.34
lossless
descriptive term for encoding and decoding processes and procedures in which the output of the
decoding procedure(s) is identical to the input to the encoding procedure(s)
3.1.35
lossless coding
mode of operation which refers to any one of the coding processes defined in this document in which all
of the procedures are lossless
3.1.36
lossy
descriptive term for encoding and decoding processes which are not lossless
3.1.37
packet
segment of the codestream containing entropy coded information on a single precinct, line and a subset
of the bands within this precinct and line
3.1.38
padding
bits within the codestream whose only purpose is to align syntax elements to byte boundaries and that
carry no information
3.1.39
precinct
collection of quantization indices of all bands contributing to a given spatial region of the image
3.1.40
precision
number of bits allocated to a particular sample, coefficient, or other binary numerical representation
3.1.41
procedure
set of steps which accomplishes one of the tasks which comprise an encoding or decoding process
4
  © ISO/IEC 2021 – All rights reserved

---------------------- Page: 9 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
3.1.42
quantization
method of reducing the precision of the individual coefficients
3.1.43
quantization index
input to the inverse quantization process which reconstructs the quantization index to a wavelet
coefficient
3.1.44
quantization index magnitude
absolute value of a quantization index
3.1.45
sample
one element in the two-dimensional image array which comprises a component
3.1.46
sample grid
common coordinate system for all samples of an image, the samples at the top left edge of the image
have the coordinates (0,0), the first coordinate increases towards the right, the second towards the
bottom
3.1.47
sign subpacket
subset of a packet that consists of the sign information of all non-zero quantization indices within a
packet, followed by padding and optional filler bytes
Note 1 to entry: See subclause C.5.5.
3.1.48
significance
attribute of code groups that applies if, depending on the Run Mode flag in the picture header, either at
least one of coefficients in the code group is non-zero, or the bitplane count prediction residual of the
code group is non-zero
3.1.49
significance group
group of a horizontally adjacent code groups sharing the same significance information in the
significance subpacket
3.1.50
significance subpacket
subset of a packet that identifies which significance groups within a packet are insignificant, followed
by padding and optional filler bytes
Note 1 to entry: see subclause C.5.2
3.1.51
slice
integral number of precincts whose wavelet coefficients can be entropy-decoded independently
3.1.52
star-tetrix
decorrelation transformation that combines a spatial with an inter-component decorrelation
transformation particularly tuned for CFA pattern compression
Note 1 to entry: see subclause F.5
5
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 10 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
3.1.53
subpacket
substructure of a packet containing information of one or multiple bands of one line of a single precinct
3.1.54
super pixel
2×2 arrangement of sensor elements in a CFA pattern array containing at least one sensor element for
each colour filter type
3.1.55
truncation position
number of least significant bitplanes not included in the quantization index of a wavelet coefficient
3.1.56
uniform quantizer
quantizer whose buckets are all of equal size
3.1.57
upsampling
procedure by which the spatial resolution of a component is increased
3.1.58
wavelet filter type
single number that uniquely identifies each element of the wavelet filter with regard to the number and
type of horizontal and vertical decompositions
Note 1 to entry: Unlike the band type, the wavelet filter type does not include component information.
3.2 Abbreviated terms
JPEG XS informal name of this standard where XS stands for “extra speed”
LSB least significant bit
MSB most significant bit
3.3 Symbols
B[c] bit precision of component c
β wavelet filter type
b band type
b [β,i] band existence flag for filter type β in component i. 1 if the filter exists, 0 otherwise.
x
b' [b] band existence flag for band type b. 1 if the filter exists, 0 otherwise.
x
Bw nominal overall bit precision of the wavelet data
B number of bits required to encode a bitplane count in raw
r
Cpih colour transformation type
c[p,λ,b,x] wavelet coefficient in precinct p, line λ, band b and position x
C width of precincts other than the rightmost precinct in sample grid positions
s
C colour transformation CFA pattern type derived from the component registration
t
6
  © ISO/IEC 2021 – All rights reserved

---------------------- Page: 11 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
C colour transformation reflection and extension flags
f
Cw width of precincts in multiples of 8 LL subsampled band sample grid positions
D[p,b] bitplane count coding mode of band b in precinct p
D [p,s] raw coding mode override flag for packet s in precinct p
r
DCO DC offset
d [β,i] horizontal decomposition level of wavelet filter type β of component i
x
d [β,i] vertical decomposition level of wavelet filter type β of component i
y
δ [c] horizontal position of component c in a CFA super pixel
x
δ [c] vertical position of component c in a CFA super pixel
y
E exponent of the slope of the linear region of the extended non-linearity
e colour transformation exponent of first chroma component
1
e colour transformation exponent of second chroma component
2
Fs sign packing flag
Fslc slice coding mode
Fq number of fractional bits in the representation of wavelet coefficients
G[b] gain of subband b
H [β,k] height of filter type β of component k in wavelet coefficients
b
H [i] height of the component i in sample points
c
H height of the image in sampling grid points
f
H height of a precinct in lines
p
H height of a slice in precincts
sl
I[p,b,λ,s] line inclusion flag, set if line λ of band b and precinct p is included in packet s, reset otherwise
k[δ , δ ] Component within CFA super pixel at position δ , δ
x y x y
L [p,b] first line of band b in precinct p
0
L [p,b] last line + 1 of band b in precinct p
1
Lcod codestream length in bytes
L [p,s] size of the bitplane count subpacket of precinct p and packet s in bytes
cnt
L [p,s] size of the data subpacket of precinct p and packet s in bytes
dat
Lh long header flag in in the picture header, set if long precinct headers are enforced, reset
otherwise
L [p] length of the entropy coded data in precinct p
prc
L [p,s] size of the sign subpacket of precinct p and packet s in bytes
sgn
7
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 12 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
L [p,s] size of the significance subpacket of precinct p and packet s in bytes
sig
M[p,λ,b,g] bitplane count of precinct p, line λ, band b and code group g
M [p,λ,b,g] vertical predictor of the bitplane count of precinct p, line λ, band b and code group g
top
N number of components in an image
c
N [p,b] number of code groups in precinct p and band b
cg
N number of bands per component
β
N number of coefficients in a code group
g
N [p,b] number of significance groups per line band b of precinct p
s
N [t] number of precincts in slice t
p
N number of bands in the wavelet decomposition of the image (wavelet filter types times
L
components)
N maximal number of horizontal decomposition levels
L,x
N' [i] number of horizontal decomposition levels of component i
L,x
N maximal number of vertical decomposition levels over all components
L,y
N' [i] number of vertical decomposition levels of component i
L,y
N number of precincts per sampling grid line
p,x
N number of precincts per sampling grid column
p,y
N [p] number of packets in precinct p
pc
O[c,x,y] unscaled output of the inverse wavelet transformation at coordinates x and y of the com-
ponent c
Ω[c,x,y] output of the inverse multiple component transformation at position x,y for component c
P[b] priority of band b
Plev level a particular codestream complies to
Ppih profile a particular codestream complies to
Ppoc progression order in which bands are transmitted in the codestream
Q[p] quantization parameter of precinct p
Qpih quantization type of the picture
Rl raw-mode selection per packet flag
Rm run mode used for significance coding
R[p] refinement of precinct p
R[c,x,y] reconstructed sample value at position x,y for component c
Sd number of components for which wavelet decomposition is suppressed
8
  © ISO/IEC 2021 – All rights reserved

---------------------- Page: 13 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
S size of a significance group in code groups
s
s [i] sampling factor of component i in horizontal direction
x
s [i] sampling factor of component i in vertical direction
y
s[p,λ,b,x] sign of the wavelet coefficient in precinct p, line λ, band b and position x.
T1 first threshold of the extended non-linearity
T2 second threshold of the extended non-linearity
T[p,b] truncation position of precinct p and band b
T [p,b] vertical Truncation position predictor of precinct p and band b
top
T[β,x,y] temporary wavelet coefficient of filter type β at location x,y.
v[x,y] sample value at the sample grid position x,y
v[p,λ,b,x] quantization index magnitude of the wavelet coefficient in precinct p, line λ, band b and
position x
W [β,k] width of filter type β of component k in wavelet coefficients
b
W [i] width of component i in samples
c
W width of the image in sampling grid points
f
W [p] width of the precinct p in sampling grid points
p
W [p,b] width of subband b of precinct p in coefficients
pb
Wt wavelet filter type for horizontal filtering
x
Wt wavelet filter type for vertical filtering
y
X[y] one-dimensional temporal array of wavelet coefficients
Xcrg[c] horizontal component registration of component c relative to the sample grid
Ycrg[c] vertical component registration of component c relative to the sample grid
Yslh vertical slice order within the picture
Z[p,λ,b,j] significance flag of precinct p, line λ, band b and significance group j
4 Conventions
4.1 Conformance language
The keyword "reserved" indicates a provision that is not specified at this time, shall not be used, and
may be specified in the future. The keyword "forbidden" indicates "reserved" and in addition indicates
that the provision will never be specified in the future.
4.2 Operators
NOTE Many of the operators used in document are similar to those used in the C programming language.
4.2.1 Arithmetic operators
9
© ISO/IEC 2021 – All rights reserved

---------------------- Page: 14 ----------------------
ISO/IEC FDIS 21122-1:2021(E)
& bitwise AND operation
+ addition
− subtraction (as a binary operator) or negation (as a unary prefix operator)
× multiplication
/ division without truncation or rounding
s
<< left shift: x< s
>> right shift: x>>s is defined as ⎿x/2 ⏌
umod x umod a is the unique value y between 0 and a–1 for which y+Na = x with a suitable integer N
4.2.2 Logical operators
|| logical OR
&& logical AND
! logical NOT
4.2.3 Relational operators
> greater than
≥ greater than or equal to
< less than
≤ less than or equal to
== equal to
!= not equal to
4.2.4 Precedence order of operators
NOTE Operators are listed below in descending order of precedence. If several operators appear in the same
line, they have equal precedence. When several operators of equal precedence
...

Questions, Comments and Discussion

Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.