Log in

View Full Version here: : Debayering.


xelasnave
12-07-2018, 02:41 PM
Are you as clueless about this as me?
I am researching it as time permits but who in our beginners croud has this aspect sortted.
Alex

Merlin66
12-07-2018, 04:03 PM
From Helen on SGL:

Each pixel in a colour camera with a bayer matrix has a filter over it - to let through either red, green or blue. They are grouped in four pixels and each 4 has 2 green, 1 red, 1 blue (to match the human eye's response to colour).

If you capture in raw, all the camera downloads and is saved initially, is a measure of the photons captured by each pixel. It is quick as it just counts, it doesn't worry about what filter was over the pixel.

The debayering process takes the measurements and then assigns the colour to the measurement - this gives the colour output. It is quicker to read /capture in RAW and then use software to debayer later. You just need to know the colour pattern for each group of 4 - but trial an error is quick to sort that out if you don't know!

EDIT: I've added further detail.....
(Reconstruction of the colour from the Bayer matrix is handled by some smart algorithms - Bilinear, VNG (variable number of gradients) etc.
http://www.stark-labs.com/craig/resources/Articles-&-Reviews/Debayering_API.pdf)

Question - if the Bayer Matrix is blue/green/red why don't you see blue/green/red pixels when you zooooom in on the image?????
(Answer: see the PDF doc.)

glend
12-07-2018, 04:22 PM
Debayering is also a term used in DSLR camera modification. It means to remove the Bayer Matrix covering a colour camera sensor to make it a mono camera.

xelasnave
12-07-2018, 04:26 PM
Thanks Ken.
I am downloading that to read and re read.
I did find somethimg in deep sky stacker that may address the problem and am doing a stack to see what comes of it...
There is so much to this aspect.
I had heard of debayering and never looked into it.
Do you have a particular work flow wherein you do a debayer?
Alex

Merlin66
12-07-2018, 04:33 PM
Alex,
Hope it helps....
In spectroscopy we generally only use mono CCD/CMOS sensors.
We're trying to collect as much data as possible across the whole spectrum.

xelasnave
12-07-2018, 04:56 PM
Hi Ken
Thanks for that but I am still in the dark...it seems like I will be working on this for a while....learning new stuff is great at my age.
I see so many old folk get cranky because they dont understand something yet I dont go that way thank goodness...
And when you think about it thete is so much to learn....and then even more when you start to understand things just a little.
I hope this lattest stack shows better colour...I cant remember what the box said it does but sounded as if it could help...cteating a super pixel or something...I cant check cause the lappy is stacking and very hard to interrupt DSS.
On the positive last night was the onlu night I have missed for a while now and I am getting stuff working and organised at least.
Alex

Imme
12-07-2018, 05:23 PM
Think you may be looking in the wrong area Alex...try -
Load all your frames in dss
In ‘options’ open ‘Raw/Fits dpp settings
In the window open the ‘Fits files’ tab
You will then see a drop down box with a range of Bayer patterns to chose from. It also lists camera models so you may just be able to chose your camera.
Hit ‘apply’ then ‘ok’.

Stack your pics and if debating was your issue you’ll see a big difference

xelasnave
12-07-2018, 05:27 PM
Thanks Jon.
That sounds like what I need.
I shall look into that when the current stack has been completed.
Alex

RyanJones
12-07-2018, 05:58 PM
Thank you Alex for bringing this up and thank you Jon for your DSS guidance. I had PM'd Marc after his comments on your Corona Australis attempt and he was incredibly helpful in explaining what the Bayer matrix was but he doesn't use DSS so he was unable to add what you have Jon. Thank you all !

Imme
12-07-2018, 06:11 PM
12 months ago I was in your exact same boat Ryan/Alex.

The good folk here on IIS have helped me develop my knowledge so I’m happy to ‘pay it forward’ to other people who are currently paddling the boat I once was.

I’ve gone from a camera on a tripod with no idea what I was doing to a guided scope with cooled camera in 12 months. Made lots of mistakes on the way and the learning curve has been very steep, however, it is only through the help of the people on here and hours upon hours of reading I feel I’m finally at a point where my setup now works as it should, when it should.

xelasnave
12-07-2018, 11:10 PM
Hi Jon if you are still around.
I followed your directions.
I picked a nikon camera hoping it may be the same as mine and I think it has worked.
Have a look at the image just out of the oven.
The colour is probably off, I dont know because of my colour blindness but I think there is at least colour.
The second one is the before proposition.
alex

Zuts
12-07-2018, 11:47 PM
Hi Alex, not sure if it is correct yet as the the reflection nebula's have a white core and some blue nebulosity, while the globulas are white. Maybe try all of the Debayer options before processing and pick the best one. Could be colour balance but I am not sure?

Cheers
Paul

luka
13-07-2018, 01:35 AM
Not quite there yet Alex. The first one is very green, probably the red and the green channels are swapped. Not sure about the second one but as Paul said it still looks off.

Which Nikon camera do you have? It may be possible to find out the correct Bayer pattern on the internet.

Imme
13-07-2018, 07:18 AM
Looking better Alex. What model is you camera......we can work out a pattern from there

PKay
13-07-2018, 07:22 AM
Put red filter over telescope or camera lens and take image (inside with bright light will do). Use RAW setting.

ONLY ONE debayer pattern will give red image.
That is the correct setting.

NB: I used a red plastic bucket...

multiweb
13-07-2018, 07:32 AM
Hi Alex the first one looks like the correct one. DSLRs tend to emphasize greens as there are twice as many pixels. What's your NIKON model? Then we can find out the exact pattern you need to debayer with.

xelasnave
13-07-2018, 10:52 AM
Good Morning everyone I have just awoke and had a cuppa and processed the combined data from last night and the night before...all up 1 hour and 53 minutes.

And present that effort below.

And although I expect the colour may be off I am so very happy that I have in the last two efforts obtained colour which is a huge step past my black and white efforts.

I would like to thank everyone again particularly Marc for the heads up and Jon for a push here dummy approach which is a level I can mange.

I knew all about debayering from just reading stuff when I was thinking of modding my canon some 12 months ago I took it in but did not realise that one needed to throw some switches in DSS.

Thanks Peter I will try the red bucket idea simply to try the idea but hopefully we can determine my cameras needs from further discussion.
My camera is a Nikon D5500 always set at 1600 iso.
Thanks again to everyone.
alex

kosborn
13-07-2018, 12:27 PM
Alex,


The Bayer pattern for Nikon (and Canon) cameras is RGGB.


Kevin

xelasnave
14-07-2018, 04:48 PM
Thanks Kevin.
Alex