-
-
Notifications
You must be signed in to change notification settings - Fork 58
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Visible clipping artifacts in highlights with Malvar (2004) and Menon (2007). #7
Comments
Hi @jiawen, I could not reproduce the issue: import colour
import colour_demosaicing
RGB = colour_demosaicing.demosaicing_CFA_Bayer_Menon2007(
colour.read_image('mandi.tif'), 'BGGR')
colour.write_image(RGB, 'mandi_Menon2007.jpg') How are you invoking the function(s)? |
My apologies for the delay as I got distracted by other stuff at work. Maybe it's because I'm reading the input using skimage.io.imread() instead of colour.read_image()? Anyway, here's the IPython notebook I was using, and this is the output from Malvar. |
I'm using colour-demosaicing 0.1.2 installed from pip on Python 3.6. I'm not using colour.read_image() mainly because I have no idea how to easily install OpenImageIO into Anaconda without installing it system-wide. |
@jiawen : I will try to look at that over the weekend, by the mean time can you try converting the array you get from Cheers, Thomas |
Hi @jiawen, I'm closing this for now, feel free to continue the discussion though. Cheers, Thomas |
My apologies ahead of time for not posting images as I am uncertain whether I have the appropriate rights.
I just tried demosaicing_CFA_Bayer_Malvar2004() and demosaicing_CFA_Bayer_Menon2007() on the standard MATLAB test image "mandi.tif" (see https://www.mathworks.com/help/images/ref/demosaic.html).
With the Malvar method, I see distinctive speckles of pure red and blue in the output near highlights. Besides that, the results are basically identical to that of MATLAB.
With the Menon method, there are pure red, green, and blue everywhere.
I suspect these are some bugs in the way overflow and underflow are handled.
The text was updated successfully, but these errors were encountered: