ICC.1:2022 §10.16 · multiProcessElements · LittleCMS

iccnet

These PNGs are gradients, and their color profiles are neural networks. Every pixel stores its own position, and the profile holds a trained network written as matrices and curves, the vocabulary profiles use to describe cameras and screens. A color engine that converts the file runs the network on every pixel and paints a painting.

Your browser

Shows the gradient. Chrome, Safari and Firefox don't evaluate the part of the profile that holds the network, so they show the pixels as they are stored.

A color engine

Paints the pictures. ImageMagick runs the network on every pixel, exactly. Pillow, sharp and libvips by default go through a 33-point table and paint them blocky.

This page

Paints with its own JavaScript evaluator of the profile, read from the PNG, not with your browser's color management. It matches LittleCMS to within one code value.

The gallery
The file, as your browser shows it
The carrier PNG as this browser displays it: a gradient of its coordinate pixels
Its profile, run by this page

Run it yourself

Download trio.png (30 KB, its profile embedded) and sRGB.icc (540 bytes, a plain sRGB profile), then convert one to the other with ImageMagick:

magick trio.png -profile sRGB.icc painted.png    # ImageMagick 7
convert trio.png -profile sRGB.icc painted.png   # ImageMagick 6
Homebrew: brew install imagemagick. Debian and Ubuntu: apt install imagemagick.

painted.png holds the three paintings. To check it against the expected result, run magick compare -metric AE -fuzz 1% painted.png trio-expected.png null:, which prints 0 when the two match to within 1%.

Tested natively with ImageMagick 7.1.2-34 Q16-HDRI (Homebrew, macOS 27.0.1, LittleCMS 2.19.1) and ImageMagick 6.9.12-98 Q16 (Ubuntu 24.04, LittleCMS 2.14, on every push to the repository). The release bundles every carrier, the expected outputs, each engine's result and SHA-256 checksums, and REPRODUCE.md covers Pillow and the other engines.

A machine made of matrices and curves

When software shows an image that carries a color profile, it converts every pixel from the image's colors to the screen's, through a fixed reference space called the profile connection space (CIE XYZ or L*a*b* under a D50 illuminant). Since ICC.1:2010, profile version 4.3, a profile can do its half of that conversion with a multiProcessElements pipeline, kept in four DToB tags, one per rendering intent. The pipeline is a list of elements, each taking the previous element's channels and producing its own, and there are three kinds.

ElementComputesStored as
matf, matrixy = Wx + b, from p channels to qfloat32 W and b
cvst, curve setyi = fi(xi), one function per channela segmented curve per channel
clut, lookup tableinterpolation in a grid, inputs clamped to [0, 1]float32 samples, not used here

A curve splits the number line at breakpoints. Each piece is a formula, (ax + b)γ + c, a·log10(bxγ + c) + d or a·bcx + d + e, or a run of evenly spaced samples joined by straight lines. There are no loops, branches, variables or memory. An element sees only its own pixel, and the number of steps is fixed. Values pass between elements as float32, and the specification forbids clipping them, so a value can be −7 or 63 halfway through and survive. The pipeline is a straight-line program from three numbers to three numbers, run once per pixel.

A matrix followed by a curve set is a neural-network layer in which every neuron has an activation of its own. Networks like that are universal even when narrow. With ReLU, width 6 can approximate any continuous function from [0, 1]³ to three color channels (Hanin and Sellke, 2017), and width 8 suffices for almost any activation (Kidger and Lyons, 2020). LittleCMS, the color engine in most open-source imaging software, reads at most 15 channels per element, and the format allows any number of layers.

A pipeline sees one pixel and nothing else, so the image has to say where each pixel is. Red is the column, green the row, and blue picks the painting. The profile computes color from position, the way a coordinate network does (Stanley, 2007). A clut element could store one painting as a 255 × 255 table of about 1.5 MB. iccnet uses no tables and computes three paintings in 71 KB.

Inside the profile

Every element of the selected file's D2B1 tag, read from its PNG by this page. D2B0 to D2B3 point at the same bytes. The first two elements build the gate, and the last two hand the color to the profile connection space. Pick an element to see its curves or its weights.

Getting past the color engine

A color engine chooses which tags to read, rewrites pipelines it thinks it can speed up, and probes profiles with special colors. Each of these broke the picture at some point. Each is checked by a test or a probe in the repository.

It reads only the tag for the requested intent

LittleCMS takes the DToB tag of the rendering intent it is asked for and never falls back to another.

What the profile doesAll four DToB tags point at the same bytes, so one copy of the network serves every intent.

It asks the older tags whether the profile works

LittleCMS's intent check looks only at matrix and A2B tags, so a profile with DToB tags alone supports nothing. By their source code, libvips and sharp then convert with a built-in sRGB, Krita drops the profile, and GIMP and darktable route it away from LittleCMS.

What the profile doesIt also describes plain sRGB, once as a matrix with tone curves and once as A2B and B2A tables. Engines that skip DToB read those and show the pixel values as they are, which is the gradient your browser shows.

It runs the network on black and rescales every color

In the perceptual intent, LittleCMS compensates black points whenever the screen's profile is v4. Because this profile has matrix tags, it evaluates the profile at RGB 0, 0, 0 and maps the result to the screen's black. When that result is not black, each version treats it differently.

LittleCMSA "black" brighter than L* 50 becomes
2.14 and earlierL* 50
2.15 to 2.170, ignored
2.18 and 2.190 above L* 95, otherwise L* 50

An early version painted RGB 0, 0, 0 near-white. LittleCMS 2.17 ignored it. sharp's copy, 2.19, read it as a black point of L* 50 and darkened the whole picture by a mean of 59 code values.

What the profile doesA gate channel is 1 where blue is 0 and 0 elsewhere. It rides through every layer and is subtracted, times 1,000, just before the sigmoid. RGB 0, 0, 0 now paints true black in every version, and codes 1 to 255 are untouched. The gate is why the hidden layers are 14 wide instead of 15.

It turns integer pipelines into a lookup table

On 8- and 16-bit pixels LittleCMS samples the whole transform at 33 × 33 × 33 points and interpolates between them, one sample every 8 pixels. That suits the smooth transforms of real devices. A painting turns to blocks, a mean of 8.6 code values off for the trio. Float pixels are evaluated element by element, exactly.

What the profile doesNothing can, because the engine decides. ImageMagick converts in double precision and paints the picture exactly. The “Through a 33-point table” button above shows what sharp and Pillow paint.

Older versions clamp straight lines

LittleCMS 2.14 and 2.15 evaluate (ax + b)γ + c as c whenever ax + b is negative, even when γ = 1 and the formula is a plain line. Ubuntu 24.04 and Debian 12 ship 2.14, and the first CI run there failed on a learned curve whose straight tail dipped below zero.

What the profile doesEach tail is written from the end where it is zero, so its base never goes negative, and the curve turns constant beyond the farthest any input can drive that neuron. Interval arithmetic over the input cube gives that bound.

The specification has a typo

ICC.1:2022 Table 57 gives the curve set's signature ‘cvst’ as 6D666C74h, which spells ‘mflt’.

What the profile doesIt uses 63767374h, which does spell ‘cvst’ and is what LittleCMS expects.

One file, five engines

The trio file, three tiles at blue = 32, 128 and 224, converted to sRGB by each engine on an Apple M4 with macOS 27. Each output is compared with LittleCMS evaluating the profile in double precision.

What fourteen channels can draw

Fifteen channels is a hard limit, and the gate takes one, so every hidden layer is 14 wide. A curve can hold any number of samples, so the capacity goes into the activations. In the 8-layer network, 7,168 of the 8,739 learned numbers are curve samples, and learned curves beat ReLU by 4.4 dB with matrices of the same shape.

Open a file

Drop a PNG with an embedded profile, or an .icc file, or . The page lists its tags and, if a PNG's profile has a DToB tag, paints it.

Prior work

A search of the web, GitHub code, Hacker News, arXiv and patents in October 2026 found no published neural network stored in an ICC profile and run by an unmodified color engine. The repository's README has the full references.