Converting image from RGB to HSV color space

Matplotlib provides RGB to HSV conversion function: matplotlib.colors.rgb_to_hsv():

matplotlib.colors.rgb_to_hsv(arr)

convert rgb values in a numpy array to hsv values input and output arrays should have shape (M,N,3)

Leave a Comment