New Sigmoid Scene to Display mapping

Made a try on kind of replicating the style of that Leica like processing. Its not one to one but I feel like its ok at least. What would you say? The biggest difference I see is the saturation of the feathers which is slightly lower in my version. Probably needs some sort of local or hue based adjustment to fix that. More related to other tools though.

DSCF7042.RAF.xmp (30.3 KB)

And one where I pushed it a bit more for some more punch while still trying to stay reasonable.

DSCF7042_01.RAF.xmp (39.1 KB)

Don’t have much to add for this one when it comes to tips and tricks, applied the same techniques as described above using exposure, tone equalizer and color balance rgb.

@rvietor Yes that could absolutely be part of the problem. Either as in fooling the camera / me or as in giving a green cast to parts of the feathers. A small tint adjustment might have helped actually.

The images don’t telegraph Leica to me but I do like the latest (punchier) take.

Trying my hand with dt 3.4.1

DSCF7042.RAF.xmp (10.0 KB)

Great!!,

I love it, the second one have more contrast and exposure, and the first preserve the high lights better. is a nice approach, I’m going to check the .xmp to learn.

Thanks a lot.

1 Like

It is okay to lift highlights as long as one doesn’t clip or quantize them.

1 Like

I may have over done it in some minds on my edit but I think you can still do more with the feathers in terms of detail
ruffly detail as @st.raw called them
 :wink:

2 Likes

This has probably been asked elsewhere so apologies if I am repeating but I have a few questions
 (not trying to put down the good work of @jandren, just asking)

Can the output of sigmoid be replicated by the settings in filmic?
If so, would it be better to have a preset in filmic rather than introducing a new module?
Is the main perceived advantage of sigmoid that it has fewer sliders so easier for people to use?
Can sigmoid cope with remapping high dynamic ranges in the same way that filmic does?
Are we happy with having lots of ways of doing things at the risk of generating lots of extra modules?

Lots of questions here


6 Likes

I’m sure others are asking the same questions!

  1. No, the generalized skew log-logistic function that the sigmoid module is based on can not be expressed by the filmic spline setup. I would rate the difference between the two as about as large as between base curve and filmic.
  2. Not possible due to the above.
  3. Simpler is kind of the first argument because it is the most obvious difference when you first look at the two. The non UI advantages include better roll-off/convergence in highlights and shadows, higher-order smoothness, more robust (all user inputs are valid up to the precision of the floating-point power function), and always supports -inf to inf EV dynamic range. The last couple of posts from me have been about researching if these mathematical properties also propagate to subjectively nice-looking pictures. I let you be the judge on that.
  4. Yes, as good or possibly even better by being well defined for up to infinite dynamic range!
  5. Tricky one and I do not have the authority to answer. This module started as a way for me to learn the darktable source code and it is thus not me who decides how or even if it should be included or not. That will be a discussion and decision for the darktable maintainers to make. I had personally liked to see a wealth of options for display transforms in darktable. One way of organizing that would be to collect them all in one parent module called f.ex. “display transform” and then have options for what method to use. Would make sense to me as you can only use one display transform and it has to happen at a very specific point in the pipeline.

A closer look at the difference

I actually developed a full tool for exploring the difference between a couple of different tone curves! I encourage everyone to try out the online version by themselves over here:
https://share.streamlit.io/jandren/tone-curve-explorer

I think the log-log view is especially interesting as all other methods have this linear section while the filmic does not. This is also the easiest way to show that filmic can’t produce the same result as the sigmoid as there is not setting the returns a linear slope for filmic in the log-log view. Filmic is linear in gamma-log instead if anyone wonders!

X axis is in EV with middle grey = 0.1845 = 0 EV
Y axis is the log2 off the linear display intensity. So display = 100% = 0

9 Likes

Thanks for posting and picking up this hot iron we’re all trying to avoid to touch somehow :wink:.

I often asked those questions to myself. Meanwhile I tested around 100 images with sigmoid and compared it to results of filmicrgb and basecurve. 20% out of my own portfolio, 70% from external sources like pixl.us and aprox. 10% from hdrihaven. Dynamic range starts from below 10 up to 23 EV.

Being a user with minimal knowlegde of the maths and development topics I cannot answer all of your questions completely.

=> Can the output of sigmoid be replicated by the settings in filmic?
<= While I don’t know if it is possible to get a 100% match, this should be answered by @jandren or @anon41087856, I think you can achieve results that are very close together.

<= If so, would it be better to have a preset in filmic rather than introducing a new module?
=> This would be very interesting indeed. I did not try to set up such a preset up to now. Not sure if this is possible. Maybe a question to the developpers again.

<= Is the main perceived advantage of sigmoid that it has fewer sliders so easier for people to use?
=> It’s not only the number of sliders. From a users point of view sigmoids workflow feels more robust, especially if you want to avoid clipped highlights or if you want to bring them back into the range without loosing too much contrast.

=> Can sigmoid cope with remapping high dynamic ranges in the same way that filmic does?
<= All the images with a dynamic range >=20 EV I processed so far could be processed with sigmoid to receive almost identical results. In my opinion sigmoid delivers a smother transition to highlighted areas with its starting settings, for instance if you shoot directly into the sun and watch the gradient to the darker areas of the sky. You need more experience to receive the same result with filmic. Example of HDRIHAVEN: https://dl.polyhaven.com/file/ph-assets/HDRIs/hdr/4k/flower_road_4k.hdr

filmic

sigmoid

<= Are we happy with having lots of ways of doing things at the risk of generating lots of extra modules?
=> Let me ask this question another way round: Does the implementation of sigmoid necessarily lead to more modules ? Couldn’t all tonemappers be integrated into one module ? On the other hand I think sigmoid could be a worthy replacement for the basecurve. Its delivers contrasty results in its basic settings and needs to be touched only in extreme situations.

5 Likes

Awesome! Hope you will have use for it!

@afre, I honestly do not know what quantitative metric to look for when classifying colors as Leica-like. I think it might be out of scope for the sigmoid module though as color changes should be done in scene-referred space in modules such as the color balance rgb. And for clipping, the nice thing about a scene-referred editing workflow is that you can push and pull stuff as much as you like without clipping as long as you didn’t overexpose your sensor when taking the picture :smiley:

I liked your image as well @priort! Just trying to stay simple in the edits here, to make it easier to understand which module did what in the editing :wink: Thanks for the contribution!

1 Like

@pass712 @jandren
Thanks both for your detailed answers! Very helpful


2 Likes

I agree that it would be tidier to have all the different methods of tone mapping integrated into one module in a similar way to the denoising. It makes it obvious that it is a choice and avoids anybody using them both at the same time.

1 Like

First, there are at least four denoising modules in 3.4.1: raw denoise, profiled denoise, hot pixels, and astro denoising. All with different aims, different algorithms, different uses

The profiled denoise module shares a lot of the basic functionaity between the different modes (the whole profiling part!) so it’s normal and logical to have them together.

Second, the different tone mapping modules have different functionality, and different basic aims.
Think of basecurve vs. filmic vs. tone curves (yes, that’s also a tone mapping)
I prefer the current situation, where you pick the tool that you want to use, without dragging in all the baggage from the other ways of doing things.

And having to duplicate a module, because I want to use another part of the functionality doesn’t feel right. That’s how I use the color calibration module if I want to do more with it than just set the illuminant, if only so I can swith of the extra changes.

In the case of the color calibration module it makes sense to have those different functionalities in the same module, as they are mathematically the same tool, and having all the settings in one module makes it a lot more efficient (computationally). That is clearly not the case with the different tone mappings like base curve, filmic etc.

And tbh, I never got the idea that dt was really interested in preventing use of the foot gun :P, thought the different module presets make it a lot less accessible. If you change those module presets, you are supposd to know what you are doing.

The comments were in response to @difrkaguilar (re: posts 219, 224).

2 Likes

All i can say is that i am addicted with this new module, fantastic results in an incredible short time. With it enjoy Darktable much more.

That’s just my 2 cents. I am just a final user, nothing else and for sure my opinion (non technical) is certainly out of topic.

Have a nice day!

4 Likes

@Kassyss Welcome to the forum! Let us know if you have any feedback. The more the better. :slight_smile: When the forum allows (you might have to write more posts first), drag and drop the images it is good at working on and some that don’t turn out well.

So do we know if sigmoid will be included in 3.6 or are there too many questions to iron out?
It has certainly generated some interesting questions which should be seen as a good thing.

I’d guess that is unlikely.

@jandren when testing sigmoid together with the vectorscope I noticed that changing contrast also leads to hue shifts. This is more pronounced with crosstalk but also visible to some degree in the preserve hue mode. Can you confirm / explain this ?

Examples

contrast = 1, crosstalk
capture_017_25052021_200127_crop25

contrast = 3, crosstalk
capture_018_25052021_200133_crop24

contrast = 1, preserve hue
capture_015_25052021_200101_crop23

contrast = 3, preserve hue
capture_016_25052021_200116_crop26

Test Image

https://discuss.pixls.us/uploads/short-url/gbhj5KOl26YR7s1QwGuimA6TX8C.cr2

Yes, that should happen with the crosstalk option. You can observe the same effect by keeping the contrast setting constant and increasing the exposure. Reducing the exposure will make the patches align towards the rgb axes as in your test. Increasing the exposure will make the patches align with the yellow, purple, and cyan axes.

As for the preserve hue option, what representation are you using for the vectorscope? JzAzBz? The preserve hue option in sigmoid preserves hue in the sense that it transforms the pixel values such that it could be represented as a combination of exposure change + linear chroma change. This is not the exact same definition for hue as that for JzAzBz so I’m not surprised that there will be some small shifts due to changing the saturation and brightness. The effect is called Abney Effect and it says the perceived hue of color changes slightly if white light is added to monochromatic light. Or in our case, a linear chroma change will not preserve the perceived hue perfectly. And the preserve hue option assumes that a linear chroma change is ok. Which apparently shows up in the vectorscope, nice!

Could be interesting to project the pixel hue using some other method than linear transforms that takes this Abney effect into consideration, like JzAzBz. Hmmmm, wonder how hard that would be and how much we would potentially gain on it


Did you try it on filmic? I think it should show similar results as the rgb ratio approach is making the same linear assumption.