colour.characterisation.matrix_augmented_Cheung2004#

colour.characterisation.matrix_augmented_Cheung2004(RGB: ArrayLike, terms: Literal[3, 5, 7, 8, 10, 11, 14, 16, 17, 19, 20, 22] = 3) numpy.ndarray[source]#

Perform polynomial expansion of given RGB colourspace array using Cheung et al. (2004) method.

Parameters
  • RGB (ArrayLike) – RGB colourspace array to expand.

  • terms (Literal[3, 5, 7, 8, 10, 11, 14, 16, 17, 19, 20, 22]) – Number of terms of the expanded polynomial.

Returns

Expanded RGB colourspace array.

Return type

numpy.ndarray

Notes

  • This definition combines the augmented matrices given in [CWCR04] and [WR04].

References

[CWCR04], [WR04]

Examples

>>> RGB = np.array([0.17224810, 0.09170660, 0.06416938])
>>> matrix_augmented_Cheung2004(RGB, terms=5)  
array([ 0.1722481...,  0.0917066...,  0.0641693...,  0.0010136...,  1...])