bundles / skimage 0.26.1rc0.dev0+git20260530.b607368ff / skimage / color / colorconv / xyz2luv
function
skimage.color.colorconv:xyz2luv
source: /dev/scikit-image/src/skimage/color/colorconv.py:1342
Signature
def xyz2luv(xyz, illuminant = D65, observer = 2, *, channel_axis = -1)Summary
XYZ to CIE-Luv color space conversion.
Parameters
xyz: array_like of shape (..., C=3, ...)The image in XYZ format. By default, the final dimension denotes channels.
illuminant: {"A", "B", "C", "D50", "D55", "D65", "D75", "E"}, optionalThe name of the illuminant (the function is NOT case sensitive).
observer: {"2", "10", "R"}, optionalThe aperture angle of the observer.
channel_axis: int, optionalThis parameter indicates which axis of the array corresponds to channels.
Returns
out: ndarray of shape (..., C=3, ...)The image in CIE-Luv format. Same dimensions as input.
Raises
: ValueErrorIf
xyzis not at least 2-D with shape (..., C=3, ...).: ValueErrorIf either the illuminant or the observer angle are not supported or unknown.
Notes
By default XYZ conversion weights use observer=2A. Reference whitepoint for D65 Illuminant, with XYZ tristimulus values of (95.047, 100., 108.883). See function ~.xyz_tristimulus_values for a list of supported illuminants.
Examples
from skimage import data from skimage.color import rgb2xyz, xyz2luv img = data.astronaut() img_xyz = rgb2xyz(img) img_luv = xyz2luv(img_xyz)✓
Aliases
skimage.color.xyz2luv