Purple fringing on shots from X-Trans sensor

I made several shots to compare some lenses and in shots from one of them I got this ugly purple fringing like someone sneezed with glitter all over the shot.
It’s in darktable, but RawTherapee produces the same results.
At first my thought was it is CA, but it looks strange and gets worse going from f/2 to f/4. Then I oppened the shot in Affinity Photo and there is no purple fringing at all.

That's how it looks in darktable

Only basic (always-on) modules and sigmoid, exposure, orientation, color calibration are turned on. The last four of them don’t cause the problem and they are left turned on just for convenience.

Shot in Affinity Photo

After some research now I think it is a problem of demosaicing algorithms for X-Trans sensors in darktable. At some point I considered it is a problem with highlights reconstruction, but if you suppress this purpleness then you can see clear clusters of cyan pixels that still are problematic. So I decided that highlights reconstructions is not the culprit.

Cyan pixels after chromatic abberations correction.

purp_fringe_dt_cyan

I can correct purple fringes via chromatic abberations or defringe, but cyan clusters will stay and colors will be greyish.
Color smoothing in demosaic module can beat cyan but colors are still dull.

My questions:

  1. Am I right that this is a demosaicing problem?
  2. Is there a way to get a result like in Affinity Photo for this image in darktable or RawTherapee?

Additional info:
Camera: Fujifilm X-M1
Lens: TTArtisans 25mm F2.0
RAW file:
DSCF0376__TT_25_4.RAF (25.0 MB)

A typical case where you would want to use some color smoothing in the demosaicer.

3 Likes

Interesting! … I also use Fuji (an X4) and although I do see the problem specifically with your image it is a problem that I have never seen before while using a variety of Fuji cameras. None of my images show this problem.
Is it possible that the TTArtisans lens is doing something unusual?

I just viewed the user guide for the section on color smoothing and it is not very informative. Is this option needed very often and if so when? What is its function.

Can’t come up with anything this lens could done which leads to that result. I mean, yes it is a dirt cheap lens,

I think that this lens is sharper than my other lenses and it makes fringes visible. I compared TTArtisans 25mm f/2 to XF18-55 and XF35 f2 R WR and TTArtisans was more sharp in the center of the frame.

In any case I consider this problem more of demosaic algorithm, or X-Trans sensors, or their 1-st generation, or sensor on my X-M1 rather than of the lens. Somehow Affinity Photo is able to open X-Trans RAW without fringing without any correction.

And there is another example of this problem but the shot was taken on XF35 f2 R WR.

Shot with XF35 f2 R WR

Affinity vs darktable. All corrections like CA, NR, lens corrections are turned off.

Does Affinity Photo actually read the raw data or does it use the embedded JPEG?

Yeah, it’s an actual raw data, not an embedded JPEG. Affinity has it’s own RAW processor (Development Persona), like Camera RAW in Photoshop.

Indeed:

@floopik , is that acceptable?

Alternatively:

BTW, the raw file has some clipped pixels, which may contribute to the problem.

2 Likes

use the “photosite color” pseude-demosaicer and you immediately see those very bright single photosites at the mentioned locations, or in other words “very high frequency chroma” content.

This can be due to sensor electronics, microlenses not in best shape, color filter not perfect or principally some lens issue (although that doesn’t look like that).

This sort of “bad data” is quite rare sometimes with high iso things might look like that. DT could analyse data and automatically toggle on some sort of “averaging / smoothing” - other software might do so. Out policy would be: a) user sees the camera might have a problem and b) defines a demosaicer preset for that camera :slight_smile:

Anyway, in my understanding absolutely no bug, demosaicer maths does exactly what it should do here.

1 Like

By playing around with the demosaic function the nasty pixels are easily subdued.
The firmware in the X-M1 may simply be a little different from the various Fuji models that I have used.
Affinity also may not offer such a broad range of demosaic options.

I have the same problem with x-trans and foliage which has clipped pixels due to direct sunlight reflections, I’d say this is a scenario of everything “working as intended” like you said, just a big x-trans weakness…