colour.adaptation.chromatic_adaptation_VonKries#

colour.adaptation.chromatic_adaptation_VonKries(XYZ: Domain1, XYZ_w: ArrayLike, XYZ_wr: ArrayLike, transform: LiteralChromaticAdaptationTransform | str = 'CAT02') Range1[source]#

Adapt the specified stimulus CIE XYZ tristimulus values from test viewing conditions to reference viewing conditions using the Von Kries chromatic adaptation model.

Parameters:
  • XYZ (Domain1) – CIE XYZ tristimulus values of the stimulus to adapt.

  • XYZ_w (ArrayLike) – Test viewing conditions CIE XYZ tristimulus values of the whitepoint.

  • XYZ_wr (ArrayLike) – Reference viewing conditions CIE XYZ tristimulus values of the whitepoint.

  • transform (LiteralChromaticAdaptationTransform | str) – Chromatic adaptation transform.

Returns:

CIE XYZ tristimulus values of the stimulus corresponding colour.

Return type:

numpy.ndarray

Notes

Domain

Scale - Reference

Scale - 1

XYZ

1

1

XYZ_n

1

1

XYZ_r

1

1

Range

Scale - Reference

Scale - 1

XYZ_a

1

1

References

[Fai13a]

Examples

>>> XYZ = np.array([0.20654008, 0.12197225, 0.05136952])
>>> XYZ_w = np.array([0.95045593, 1.00000000, 1.08905775])
>>> XYZ_wr = np.array([0.96429568, 1.00000000, 0.82510460])
>>> chromatic_adaptation_VonKries(XYZ, XYZ_w, XYZ_wr)
array([ 0.2163881...,  0.1257    ,  0.0384749...])

Using Bradford transform:

>>> XYZ = np.array([0.20654008, 0.12197225, 0.05136952])
>>> XYZ_w = np.array([0.95045593, 1.00000000, 1.08905775])
>>> XYZ_wr = np.array([0.96429568, 1.00000000, 0.82510460])
>>> transform = "Bradford"
>>> chromatic_adaptation_VonKries(XYZ, XYZ_w, XYZ_wr, transform)
...
array([ 0.2166600...,  0.1260477...,  0.0385506...])