How do I sport the Demosaicing Differences?

I created 4 versions of the same photo using AMAZE, RCD, DCB and VNG4 demosaicing algorithms and opened them all in different layers in the same Photoshop image. Using the Difference Blend mode I expected to be able to see where the different algorithms gave different results, but even when viewed at 400% the result was a black (ie no difference) screen no matter what I compared with what.

Clearly there should be a difference (in RT the running commentary at the bottom as the file was saved showed the appropriate algorithm) so what am I doing wrong when comparing?

When viewed at 400% zoom, and an image with sufficient detail, you should at least be able to see the differences by eye. Is that the case?

This one is definitely down to Photoshop. I can see the differences with the naked eye at 400% but the program canā€™t. Interesting.

Donā€™t know about Photoshop, but using Absolute Difference Blend and on top of that using an extreme brightness curve you should be able to see the differences.

You need carefully chosen images, known to be challenging to demosaic, to be able to spot real differences. For example, sharp horizontal, diagonal and vertical patterns like fences, fabrics, fuzzy clouds or curtains, noisy pictures, saturated objects and lens chromatic aberrations.

Otherwise, when the conditions are nice, all of them perform similarly.

I disagree.

Well, if you need forensics methods digitally enhanced to make a diff picture legible, thatā€™s my ground truth for ā€œsimilar performanceā€.

@heckflosse Can you tell me which of these images is significantly different to your eyes? And which two are identical? At 100% zoom please :wink:

Demosaic_try.zip (10.7 MB)

Edit: and for 10 bonus points, which image belongs to which demosaicing method.

Why should I do this (waste of time) ? You know that there are differences between outputs of different demosaicers. Do I really need to show examples? Then please provide a raw file. Then I will show the differences. Tiff (or png) files are not even worth a look, sorry :frowning:

1 Like

What are they for?

@heckflosse Please take note of the wink, it wasnā€™t meant too seriously. Both you and Aurelien are correct. At pixel peeping levels there are significant differences between algorithms which may get blown up due to other processing. At 100% zoom level and using a picture taken in ā€˜nice conditionsā€™, the differences are almost non-existent and certainly not bothersome.

My zip contains an illustration to that point for anyone whoā€™s interested. Look at 100% zoom and tell me which differences you see, then look at 400% zoom and spot the differences.

Interesting, thanks. I suppose these are simple crops from the demosaics, not resized? I hope you will say what seven methods were used.

With a quick script, I use ImageMagick to loop through each pair of images and find the largest RMSE difference. This is between images 1 and 4, with RMSE 0.011 on a scale of 0 to 1, so 1.1%. As a rule of thumb, 1% is the threshold at which I can just see that two ordinary photos are different, when the differences are evenly spread through the images.

At first glance, I canā€™t see differences between 1 and 4. But ImageMagick (or anything similar) can point out where the differences are.

magick Demosaic-1.png Demosaic-4.png -compose Difference -composite -auto-level demosaic-diff.png

Guided by this, I know where to look. And the differences are obvious, even at merely 100%.

Thanks, the tip of the high brightness curve helped make the naked eye differences even clearer.

So, I use a ā€˜halfā€™ demosaic for my proofs, as itā€™s quick and looks fine when downsized to 800x600. For clients that want full resolution, Iā€™d produce a rendition that used one of @heckflosseā€™s wonderful tools courtesy librtprocess. Havenā€™t had a client in at least 30 years, howeverā€¦ :smiley:

Iā€™m also using half to process spectrum captures for SSF profiles; need RGB triplets to calculate channel averages down each image column, and half doesnā€™t change the original R and B captures, and only does an average of G1 and G2 for G. Need as little change as possible for the downstream processingā€¦

@snibgo There are seven files, two of them use RCD (so should be identical), one is AMaZE, one is DCB, one is IGV, one is LMMSE and one is Fast. All options as named in RawTherapee.
There are no other adjustments to the image, except for a little increase in exposure, contrast and saturation - otherwise, things looked too dull.

Why not? Downsizing that much using quarter demosaic (binning) should be good enough :slight_smile:

Well, why using modern highres Nikon Cams then?

of @heckflosseā€™s wonderful tools courtesy librtprocess

Thanks, but not olny mine, also @CarVac and others were involved.

1 Like

Thanks. 3 and 7 are identical, so they are RCD. Which ones are AMaZE, DCB, IGV, LMMSE and Fast?

I will also add that while differences may not be visible immediately after demosiac, the differences can be much more pronounced after processing - particularly sharpening. (At least this is true for X-Trans images)

1 Like

@Thanatomanic Yea, which ones are which?

Ok, Iā€™ll biteā€¦

4 is clearly ā€œfastā€, and it is significantly worse than the others. 3 and 7 are identical, so they must be RCD. From here, Iā€™d guess 6 and 5 are Amaze and DCB (or the other way round), whereas 1 and 2 are IGV and LMMSE (or perhaps the other way round).

How far off am I? :wink: