Bayer pattern for Canon 2000D Super UV-IR Cut

Jul 22, 2019
20
0
I have a new Canon 2000D Super UV-IR Cut and I have been unable to find out what bayer pattern it uses.
I attache the jpeg ( canon 2000d Super UV-IR Cut + ISO 1600 + Canon 55-250 @135mm f/6.7 + 17 x 240" )
After batchpreprocessing I splitted RGB channels --> linearfit G on channel red and on channel blue --> channel combination and this is result...
I don't understand...
Please, can anyone help me?
 

Attachments

bulrichl

PTeam Member
Nov 2, 2016
1,186
147
La Palma, Canary Islands
I assume you are capturing in RAW format. Which file format was used to save the light frames, CR2 or FITS?

When the files were saved as CR2 files, the bayer pattern is stored in the file and PixInsight retrieves the correct bayer pattern when opening the file.

When FITS files were saved and you let the bayer/mosaic pattern on the default, 'Auto', there will be an error message:
*** Error: Unable to acquire CFA pattern information: Required image metadata not available.
So in the case of FITS files, you have to input the correct bayer pattern (with Canon cameras presumably RGGB - I don't know a Canon model that deviates from this rule) yourself.

Bernd
 

bulrichl

PTeam Member
Nov 2, 2016
1,186
147
La Palma, Canary Islands
OK. The issue is that the raw image when opened in PixInsight still contains the optically black regions - regardless whether the option 'No image crop' in RAW format preferences is disabled (this setting is correct and is the default setting as well). This camera (it is correctly recognized as "Canon EOS 2000D") has an odd vertical offset. So the result is that the bayer pattern is jumbled:

Code:
R  G  R  G			G  B  G  B
G  B  G  B	  to  	        R  G  R  G
R  G  R  G			G  B  G  B
G  B  G  B			R  G  R  G

   RGGB		  to	   GBRG
However, I suggest you NOT to use 'GBRG' as debayer pattern. You must get rid of the optically black region anyway. So the better option seems to be to crop each raw image with these parameters:

left margin:  -76
upper margin: -35

In this way, the image that initially had 6096 x 4051 pixels will be cropped to 6020 x 4016 pixels.

The cropping can be done by loading the raw frames (CR2 format) into an image container (output template: "&filename;.xisf") and dragging and dropping the New instance (blue triangle) of the image container to the lower window edge of the crop process window. This procedure must be followed for ALL raw frames (lights, bias, darks, flats, ...).

Then use DPP with Bayer/mosaic pattern set to 'RGGB' for debayering.

----------

The Canon EOS 2000D was released in April 2018. I guess that this issue is caused by the LibRaw version 0.19.2 which does not support the cropping of the optical black regions with that camera model yet.


Bernd
 

bulrichl

PTeam Member
Nov 2, 2016
1,186
147
La Palma, Canary Islands
If you cannot realize my suggestion (using an ImageContainer), try instead the bayer/mosaic pattern 'GBRG' when debayering in your normal workflow. This might be not ideal because the black borders of the optically black pixels at the upper and left margin could disturb statistical calculations in PixInsight, but it will possibly not deteriorate the end result strongly.

Alternatively: wait until the announced PixInsight v1.8.7 is released and hope that the issue was fixed in LibRaw 0.19.3. ;-)

Bernd
 
Jul 22, 2019
20
0
I tried capture an image in JPEG and it's all ok; if I capture in RAW it's a disaster with rgb and with all debayering...
Is it possible that RAW of Canon 2000D is not yet decodified from Pixinsight?
 

pfile

PTeam Member
Nov 23, 2009
6,777
270
aldo, this is exactly what bernd is saying. the current libRaw included in PI 1.8.7 apparently can only partially handle a 2000D CR2 file.

try waiting for the next release of pixinsight if bernd's suggestions for fixing your files are too hard to do.

rob
 

bulrichl

PTeam Member
Nov 2, 2016
1,186
147
La Palma, Canary Islands
This is the result in the process console when I open the image in PixInsight. In RAW format preferences, 'Pure raw' is set:
-------------------------------------------------
C:/Users/Bulrich/Downloads/21-07-201901371600.CR2
Reading metadata: done

Camera ........... Canon EOS 2000D
Timestamp ........ 2019-07-21T22:42:14Z
Exposure ......... 240s
ISO speed ........ 1600
Focal length ..... 1.4e+02 mm
Aperture ......... f/6.7 = 20 mm
CFA pattern ...... Bayer RGGB
Raw dimensions ... w=6096 h=4051
Image geometry ... x=0 y=0 w=6096 h=4051

Raw decoding parameters:
Output mode ............... cfa
Auto crop ................. enabled
Wavelet noise threshold ... 0
White balancing ........... disabled
Black point correction .... disabled
Highlights clipping ....... disabled
Auto rotate ............... disabled
Output image .............. w=6096 h=4051 n=1 Gray
-------------------------------------------------


When I debayer the images (bayer/mosaic pattern set to 'GBRG', this is the result in the process console:
-------------------------------------------------
Debayer: Processing view: _21_07_201901371600
CFA pattern: GBRG
VNG demosaicing: done
Noise evaluation: done
Gaussian noise estimates:
s0 = 1.524e-03, n0 = 0.2783 (MRS)
s1 = 1.493e-03, n1 = 0.2393 (MRS)
s2 = 1.523e-03, n2 = 0.3940 (MRS)
16.162 s
-------------------------------------------------

I append a screen section (STF Auto Stretch with 'Link RGB channels' disbled) which contains M 20 to show the color (red and blue). No problem here.

Bernd
 

Attachments

Jul 22, 2019
20
0
Bernd, you are great; I followed your steps and now it seem ok; I thank you very very very very very very very very very much... You saved me, my DSLR, and hour of exposure...