Question about demosaicing alogrithm
Question about demosaicing alogrithm
In test_camera example, why the output RGB888 image color is so green ? Can I improve it ?
Re: Question about demosaicing alogrithm
Hi aqqz,
Can you share the output image? If the colors are far off, perhaps the demosaicing is applied with a wrong shift, thus interpreting the colors wrong.
If the green tint is subtle, this might be improved with a better demosaicing algorithm. The current one is very basic.
For further reading check out this blogpost
Can you share the output image? If the colors are far off, perhaps the demosaicing is applied with a wrong shift, thus interpreting the colors wrong.
If the green tint is subtle, this might be improved with a better demosaicing algorithm. The current one is very basic.
For further reading check out this blogpost
Re: Question about demosaicing alogrithm
Hi, gemenerik :
So, this the raw image:
and this is the RGB888 output image:
Is it so green ?
I see the blog, In fact, I want to use the aideck to regnoized color. but I don`t use the image dataset capture from the aideck to train models.
I don`t know if there is some wrong with the demosaicking algorithm or the cmos can not show the true color of the world.
So, this the raw image:
and this is the RGB888 output image:
Is it so green ?
I see the blog, In fact, I want to use the aideck to regnoized color. but I don`t use the image dataset capture from the aideck to train models.
I don`t know if there is some wrong with the demosaicking algorithm or the cmos can not show the true color of the world.
Re: Question about demosaicing alogrithm
Could you try to using this Ptyhon script on the raw image instead? This will use openCV to do the demosaicking. Do you get the same result?
Code: Select all
import numpy as np
import cv2
img = np.fromfile("img.raw", dtype=np.uint8)
print(img.size)
img.shape = (244, 324)
rgb = cv2.cvtColor(img, cv2.COLOR_BayerBG2BGRA )
cv2.imshow('Bayer', img)
cv2.imshow('RGB', rgb)
cv2.waitKey()
cv2.destroyAllWindows()