within the following code, I use a png image 4096*4096 pixels which includes every possible RGB colors (not twice the same pixel, can be found here http://allrgb.com/starry-night) Then I convert the RGB values to LAB values and I check the range of each of the channels
import cv2 as cv
import numpy as np
im=cv.imread('allrgb.png')
im=im.astype(np.uint8)
colors_lab=cv.cvtColor(im,cv.COLOR_BGR2LAB)
m=np.amin(colors_lab[...,...,0])
The results are the following :
if the original image has type uint8, R[0,255],G[0,255],B[0,255] gives L[0,255],A[42,226],B[20,223]
if the original image has type float32, R[0,1],G[0,1],B[0,1] gives L[0,100],A[-86.1813,98.2351],B[-107.862,94.4758]
In any case, the Lab range is never the expected one, which is given by open CV documentation
Any idea how to explain that ?