Closed Mangus78 closed 3 years ago
Have you tried other demosaic algorithms? (for instance frequency-domain chroma)
Also, in my experience such black edges can be due to chromatic aberrations (combined with input color profile it can lead to very dark or negative values) Unfortunately there is currently no good way to correct them for fuji yet, but I am working on it.
Have you tried other demosaic algorithms? (for instance frequency-domain chroma)
Yes, i've tried everyone of them. "frequency domain chroma" and "markesteijn 3 pass", both with five times color smoothing. Sometime the first is better, sometimes the other. But are very similar in general.
Could you post the screenshot without defringe? Just to see how much chromatic aberrations we have here. I think the problem comes probably from that. Thanks
Also, in my experience such black edges can be due to chromatic aberrations (combined with input color profile it can lead to very dark or negative values)
Absolutely agree after what I've seen with my tests. Glad to know that it's something that you're taking care of. I was worried that it could be marked as "impossible" and leave to its destiny. Fujifilm is gaining a lot of traction in the latest years and its cameras are wonderful and it would be a pity.
Could you post the screenshot without defringe? Just to see how much chromatic aberrations we have here. I think the problem comes probably from that. Thanks
Yes. If you want, I can share tha RAF file and the JPG SOOC of that image. It isn't a "good" photo by any means but I think it's a good example for both chromatic aberrations (in the whole picture but especially in the corners where there are clipped highlights) and color smearing in the foliage.
Great! You can rename the issue to something like: "add chromatic aberrations correction before input color profile compatible with xtrans sensors"
Yes I'd like to have the RAF please, it will be useful to test the algorithm Thanks
As I said, this is an extreme example of the problems. Other images with different colors and less contrast areas are fine.
The files are too big to upload here, here it's a link to a zip with both on my google drive: https://drive.google.com/file/d/1OaRqpK1dTrlvNxvMXPgxmmlSkb97FTMd/view?usp=sharing
(sorry if I make some mistake using github, it's the first time that I use this platform :D )
So at the moment the issues are actually two: -chromatic aberration (add CA correction for fuji xtrans) -smeared colors in some situation (create a dedicated color profile?) Do you think that they are actually two different problems or that also color smearing is due to the CA issue?
Thanks for the screenshot and the files (I will download them later on)! I am not sure I actually understand the smeared color issue. Do you have an example of that with an image that does not have also the problem of chromatic aberrations?
Thanks for the screenshot and the files (I will download them later on)! I am not sure I actually understand the smeared color issue. Do you have an example of that with an image that does not have also the problem of chromatic aberrations?
Mmm...I don't think so...but in the image that I uploaded you can see them too in the leaves of the trees. Here there is another example from a similar image. The borders of the leaves are always "smeared" and you can resemble the fuji sooc rendition working a lot on contrast equalizer but it's very difficult to obtain the same results. It's difficult to explain clearly this issue, googling around in the past few days I've found that it's a fuji-related problem even in other editors (like rawtherapee, lightroom etc.), maybe because the demosaic methods are the same (or very similar)? ATM I've made some test wit DT, RT and C1. C1 is the best, maybe because there is a collaboration between C1 and Fuji (they have a dedicated version for fuji with also the film simulations implemented and it is advertised even on Fuji website)
I think these are probably also chromatic aberrations, even if they are small
I think these are probably also chromatic aberrations, even if they are small
Yes, probably you're right. To get around the smearing issue I use some tweaks in the color module and a contrast equailizer module set something like this, but it's only a workaround as it also adds a bit of noise:
I was making other tests and reading here and there trying to find some new ideas. What about that for fuji cameras there are no custom matrix? It could help a lot I think in the demosaicing/chromatic aberration management.
I don't think custom matrix will help. For other cameras, custom matrix seem quite close to standard matrix. The black pixels we get is a combined effect of chromatic aberrations and having negative coefficient in the matrix, but we usually find such negative coefficient also in custom matrix
Custom matrices aren't being added anymore for any cameras, they are default only due to historic reasons.
I tried iridient x-transformer to convert raf to dng, as they said it's one of the best tool to demosaic RAF files. The results are quite similar to darktable except for the edges of tiny objects which are clearly better identified and smoother. Resulting globally in an image with less "noise" in objects' borders, cleaner and sharper once fully edited in DT.
Custom matrices aren't being added anymore for any cameras, they are default only due to historic reasons.
I didn't know that. The documentation on the website is obsolete/unclear about these kind of subjects. Thanks!
Just another 2 screenshots, jpg on the left, edited raf on the right, at 100% I tried everything but I find it impossible to avoid that CA on borders of objects and it drives me crazy as in these days I have a lot of pictures of foliage to edit :smile:
This issue did not get any activity in the past 30 days and will be closed in 365 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.
2 things you can use until the new module is ready:
Thanks!
Here is an example on your image:
Yes, I am working on a new module working on rgb data before colorin to correct CA. The idea behind the algorithm is to use one of the 3 channels as a guide, and to locally approximate each channel as a sparse function of the guide. The most naive way of doing that is to locally approximate a channel by a guide, where a* is the ratio of the local averages. But this gives halos near edges (same issue that we can have with defringe, see below), so I am using a slightly more complex approximation. Code is currently on branch rawfiner-cacorrect on my git, but not finished yet.
example with defringe:
with my module:
It seems a very promising result. So it will work also on x-trans raws, right? When do you think would be completed and will it replace the "old" chromatic aberration module? Thanks a lot!
Yes it works with any raw, even jpg etc.. See PR #7633 for more information And I think current chromatic aberration correction module should probably be kept, as it works using a different algorithm that actually works quite well on bayer sensors
This is really great news for x-trans users! Thanks! So, this new module could be used with lens correction module without the risk of new CA? Can't wait to try it!
Yes :-)
Hi, how is going with this module? Any idea about when would it be realeased? Don't want to make any haste, just curious and eager to try it. It seems sooooo promising!
Hi, how is going with this module? Any idea about when would it be realeased? Don't want to make any haste, just curious and eager to try it. It seems sooooo promising!
It should be (if work is done and tests ok) for 3.6, released in june. At worst, this would be for 3.8, in Christmas.
EDIT: at this time, this expected for 3.6. Wait and see!
This issue did not get any activity in the past 30 days and will be closed in 365 days if no update occurs. Please check if the master branch has fixed it and report again or close the issue.
Hi, I just installed the unstable version for testing purpose. What's the name of this new module, so I can try it? Also, opening the same raw that I posted here, I receive the "disable as not appropriate" red band error on the "demosaic" module, is it related to this new module that you're working on or is it something else that I should check?
Hi, I just installed the unstable version for testing purpose. What's the name of this new module, so I can try it? Also, opening the same raw that I posted here, I receive the "disable as not appropriate" red band error on the "demosaic" module, is it related to this new module that you're working on or is it something else that I should check?
This module is not in master (unstable version) by now. It's still a work in progress. You could see the open pull request here: #7633
Thanks @Nilvus for answering I don't know at all about the disable as not appropriate red band on demosaic
Also for the new module, the PR will be updated very soon. I know there has not been a lot of activity on the PR for some time, but there was some work behind the scenes and I should be able to push it soon on the PR :-)
Describe the bug the rendition of fujifilm RAF files is very problematic sometimes. Especially with foliage images or high contrast areas. There are artifacts in hight contrast zones and a "smeared" rendition of foliage in trees. I noticed that the demosaic method needs to be perfectioned but maybe the solution could be a dedicated input color profiles for fujifilm cameras (I have an X-T3). At the moment the best fuji RAF rendition by a third party editor is by Capture One. I tried changing the input color profile from "enhanced color matrix" to "linear prophoto RGB", and the results are that the colour rendition is wrong but the artifacts are nearly totally gone, making the image very very similar to the capture one version (from an "artifact" point of view at least). The smeared colors I suppose that would benefit only from a better demosaic. Anyway this way and with a lot of color tweak through some modules, the results are very similar to Capture One. Looking at the darktable's supported camera list, the custom color matrix for fujifilm cameras aren't available. so I think we need: -custom matrix for fuji -trying to improve demosaic method
I'm no developer at all but If I could help, I would be happy to. I own a Fuji X-T3 if you need some kind of sample RAF file.
Expected behavior No artifacts or smeared colours in fujifilm RAF files processing.
Screenshots On the left the enhanced color matrix, on the right the linear prophoto RGB. I added only lens correction and defringe to make the differences more clear.
Platform (please complete the following information): 3.2.1 on every OS