def LAB2RGB(X): for i in range(X.shape[0]): X[i,:,:,:] = color.lab2rgb(X[i,:,:,:].astype('int8')) return X.astype('float32')