colour.characterisation.apply_matrix_colour_correction_Vandermonde#

colour.characterisation.apply_matrix_colour_correction_Vandermonde(RGB: ArrayLike, CCM: ArrayLike, degree: int = 1) NDArrayFloat[source]#

Apply given colour correction matrix \(CCM\) computed using Vandermonde method to given RGB colourspace array.

Parameters:
  • RGB (ArrayLike) – RGB colourspace array to apply the colour correction matrix \(CCM\) to.

  • CCM (ArrayLike) – Colour correction matrix \(CCM\).

  • degree (int) – Expanded polynomial degree.

Returns:

Colour corrected RGB colourspace array.

Return type:

numpy.ndarray

References

[Wikipedia03f]

Examples

>>> RGB = np.array([0.17224810, 0.09170660, 0.06416938])
>>> CCM = np.array(
...     [
...         [1.0300256, 0.11417701, -0.26218168, 0.04180222],
...         [0.06702098, 1.02214943, -0.11661082, 0.01282503],
...         [0.07446128, -0.18728192, 1.12780782, -0.03180856],
...     ]
... )
>>> apply_matrix_colour_correction_Vandermonde(RGB, CCM)  
array([ 0.2128689...,  0.1106242...,  0.0362129...])