Why input of rgb_to_lab and output of lab_to_rgb are not the same?
See original GitHub issueHi Kornia team,
I test rbg_to_lab
and lab_to_rgb
with these lines of code:
The input
and output_rgb
are supposed to be the same, but it is not the case.
I checked the document but did not see any special preprocessing method for input/output of those conversion functions.
So why they are not the same?
Thanks.
Issue Analytics
- State:
- Created 2 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
Opencv L*a*b* to RGB conversion produces grayscale output
This is necessary because CIE-Lab* is not a linear color space so there's no known direct conversion to RGB. void CIElabtoXYZ(cv::Mat& image ...
Read more >kornia.color - Read the Docs
Convert an image from Lab to RGB. Returns. RGB version of the image. Range may not be in ...
Read more >Module: color — skimage v0.19.2 docs
Lab to RGB color space conversion. ... Same dimensions as input. ... If the input is a 1-dimensional image of shape (M, )...
Read more >Opencv L*a*b* to RGB conversion produces grayscale output ...
Convert CIE-Lab* to XYZ. This is necessary because CIE-Lab* is not a linear color space so there's no known direct conversion to RGB....
Read more >Converting from LAB to RGB leads to wrong colors · Issue #4105
We tried version 7.1.0-4 on mac and also on linux, but same result. The output image has no embedded profile, but the colorspace...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@edgarriba This might lead to some problems if someone tries to save an image or pass it onto another (kornia) function that expects things in 0,1 range. Imo
clip=True
is a safer default.Yes @shijianjian it is because of clipping done during
lab_to_rgb
. This is according to conversion standarts [ref]@hminle you can check our test for this exact thing here precision is within 1e-4. Let me know if this answers your question 😄