ART and Sigmoid [solved]

The sine qua non of photography ! 95% should be done when you press the shutter button. The last 5% can be done in software.

5 Likes

I’ve seen many examples of various software (FOSS and proprietary) made to “walk and talk” by highly skilled operators. But as impressive as that is, I always have to wonder if / why the shot wasn’t better exposed / composed. Who knows, there may have been good reasons.

Then again, it’s more interesting to watch a miracle being performed than watch ordinary stuff, so… :slight_smile: That said, I’m glad there are “miraculous” tools available, given how I shoot sometimes! LOL

2 Likes

If someone exposes badly or chooses an unfavorable section, it is rarely intentional, but almost always an inability. Either the photographer couldn’t do any better or the situation made it impossible to make the necessary adjustments. But sometimes there are also situations where there is no better way if you don’t want to miss the shot.
Good software should and can help you get the best out of your photos.

And that brings us back to an old topic:
ART, RawTherapee and darktable: all three are very good. And if poor developments are made, it is certainly always because the user was too sloppy or too inexperienced. But as far as I know today, it is completely impossible to achieve significantly better results with one of the three than with the others.

The crucial question is: How do I personally cope with the software?

I’ve admired darktable for years - but if I take a break for a few weeks, I’ve forgotten a lot of important things. In short: I’ve always struggled with my understanding and mastery of dt.

RawTherapee was my absolute favorite for years. I could do anything with it and would be happy with it for the next 100 years, but not when the project stalled like this, that worried me a little, especially in terms of support for new cameras or lenses.

And that’s where ART came in: Fresh, clear and intuitive. After several attempts, I manage to achieve the quality of RT. And ART is thoroughly likeable. And then there’s Alberto. I can’t believe how much and how quickly he helps everyone, even beginners. And as soon as someone draws his attention to a bug, it is usually fixed very quickly.
What more could you want? I don’t need any more, ART offers me everything I can only dream of.

You probably already know the term mid-grey, or midtones: stuff that we perceive as neither ‘dark’ nor ‘bright’: the sky, away from the Sun; grass; many wooden surfaces. When Ansel Adams developed his ‘zone system’, he centred it around mid-grey (German Wikipedia: Neutralgrau – Wikipedia), which is defined as a surface that reflects 18% of the light. Here 100% would be defined as a surface that reflects all the light in a diffuse way, like white paper or a white wall; not like a mirror. However, in the world that we photograph, there are areas that are brighter than 100% diffuse reflections: light sources, or surfaces such as metal, water etc. that are almost like mirrors (called ‘specular’ reflections (German Wikipedia link: Reflexion (Physik) – Wikipedia)).
While our displays clearly emit light, so they are light sources, they cannot be as bright as the Sun, or the surface of the filament in a traditional light bulb. When printing, the situation is even worse, as paper is clearly a reflective surface, it cannot be brighter than 100%, by definition.

If we tried to represent light in a linear way, without compression, we may end up with something like this. Parts that are brighter than the display can handle are ‘burnt out’.

What we want is to be able to create a picture between 0% and 100% brightness that somehow resembles reality, even though in reality the contrast between the darkest and brightest parts of a scene is much larger than what paper or a display can produce.

If one were to simply scale the values equally (multiply pixel values by a number < 1), making sure that the brightest part of an image becomes 100% white on the display or the paper, the scene would be too dark. Here’s a screenshot using ART:

We could then add a curve on top to bring up the shadows. That is the traditional ‘base curve’/‘camera curve’/‘tone curve’ approach. A very bad attempt:

Luckily, our senses (sight as well as hearing) are (as far as I know, and probably only approximately) logarithmic in nature. That means, when the signal (light or volume) is multiplied by an amount (for example, doubles), we sense it increased by some amount (we perceive addition), not multiplication (for example, doubling). When the signal doubles again, we again perceive an increase by the same amount. So, it went from ‘10’ (whatever the unit is) to ‘20’, then from ‘20’ to ‘40’ (so it increased first by ‘10 units’, then by ‘20 units’), we feel it changed ‘x’ both times.

For sound volume, you are probably familiar with dB. That is also a logarithmic scale; the threshold of our hearing is defined as the base line 0 dB; a quiet room is 30 dB, a normal conversation is about 60 dB, a hairdrier 90 dB, a rock concert 120 or above. Even though physically the power levels moving the air are not 1:4 in ratio, we feel that if we take the difference between the threshold of human hearing to a quiet room, we then go again ‘as much’ from the quiet room to 60 dB (about the loudness of a normal conversation), then again to 90 dB (the sound level of a blender or hair drier), and once more to 120 dB, the rock concert.

Here is a plot of the ‘natural’ logarithm function:
image

At x = 10, the value is 2.3; at 20, about 3, so it increased by 0.7. At x = 40, the curve reads about 3.7; again, it increased by 0.7; at 80, it’s at 4.4, so it went up by 0.7 again.

With log tone mapping, you get this gentle curve that becomes less and less steep. There is more maths involved, but that is not so important.

Instead of darkening the image as shown above, we can apply the log tone mapping to keep the shadows visible, and map those bright parts (the sky, which is a light source) into the displayable/printable range:

However, you can also see that it also means you lose contrast. There is only a small portion where contrast is close to 1 (the black line is contrast = 1, the blue is the log):
image.

One solution is to use a traditional S-curve, like the one I gave above, to place contrast wherever you need it. The other is a parametric curve, like Sigmoid. (filmic is another such curve, originating in the animation software Blender, I think, and also used in darktable in a modified form.)

If you open the curve explorer (also posted above), and only plot sigmoid (log-logistic), using contrast you can control how steep the straight part of the curve is. Contrast 1 vs 2:


With skew, you can control how much the shadows and the highlights are compressed. Notice when the line ‘leaves the ground’ and ‘hits the ceiling’. Skew: -2 vs 1:


(Edit: contrast is contrast (slope of a tangent, a straight line touching but not crossing the curve) at 0 EV; the slope at other points depends on the base contrast one sets, but also on the skew.)

How is that different from a traditional S-curve? The tricky part is that the y axis is in screen/paper brightness percent, but the x, the input, is in EV (so, at the bottom, you don’t see 1%, 2%, 4%, 8%, 16%, 32%, 64%, 128%, 256% and so on; 0 EV is mid-grey, the others are the given number of EV above or below it, so for each step the amount of light doubles or halves). That is where you can see the logarithm at play: a difference of 1 EV is doubling the amount of light, which we perceive as ‘it got brighter by the same amount each time’.

I do not know if this helped or confused you even more. Please let me know.

7 Likes

Please be careful. Again, the development has been, and continues to be, active. Only the release cycle got longer due to temporary issues. The project itself never “stalled”.

2 Likes

What do these curve mean to what I see?

Steep part: high contrast; flat part: low contrast.

as an illustration to @Lawrence37 's comment relevant to the topic of this thread @micha , check out the enhancements to the Tone Response Curve in Local Adjustments (which can be used globally) currently being developed by @jdc Another tutorial – Color appearance – Truck under a tunnel - #4 by jdc As Jacques points out, this tool provides an interesting and simple alternative to:

3 Likes

Thank you for this tip. Don’t worry, I always have an eye on RT and I certainly won’t forget my old love.
It would be a dream come true if ART and RT could find each other again, i.e. the best of both worlds pulling in the same direction. Unfortunately, that will probably never happen, but we have to be content with that, everyone can go the way they recognize as their own. Even the software developers.

A huge contribution. I have copied it into a text document, will translate it into German and work through it until I understand everything. That may take a while.
It looks very challenging, interesting but also important.
But thank you very much for your efforts.

Hello Wayne,
Thanks for the tip. You make me curious and I will seriously try this branch, I am very curious to see how well I get along with this software.
But I’m sure I won’t make much progress without help. But I will ask if I need to know anything. If necessary, Jacques himself, with whom I am also in contact.

For a good introduction to the basic TRC, see this video by @Andy_Astbury1 starting at 13:40 minutes. https://www.youtube.com/watch?v=-30NwsK5TuY&list=PLnIcpm2W3TX_kcxfxeZdfW6R_4FYh-KjS&index=17
Note that the video doesn’t cover the more advanced TRC in the lacam16 development branch mentioned above.

Thank you for your efforts, but I’m starting to find everything far too complicated again. The possibilities are great and I admire them, but hopefully I will never need them.
But I will look at it all with patience and perseverance, even if it’s all too much for me at the moment.

Your suggestion to take a closer look at this topic appeals to me, but we should definitely open a new topic and not continue writing here.
But before I get fully and intensively involved, I would like to hear from you: What can this TCR do?
I’m not that interested in learning something new just because it’s new, but it’s really just another method. In the end, does TCR offer more and better possibilities for raw development than ART?
Then you could start a new topic, with a suitable example photo - and I will be enthusiastic about it.

Just take a look at Jacques’ tutorial in the link on my message above.

Hello @Wayne_Sutton
Yes, yes, I’ve looked at it a lot, but it’s not that easy for me to get started.
Please, can you tell me what this miracle tool can do that others, especially ART, can’t?
That is important to me.

@micha, to be clear I’m not advocating this tool over and above any of the others. Each has its merits and uses depending on the type of image. My only reason for mentioning it was in response to your remark about RawTherapee development being stalled and the lengthy discussion about Log Encoding and Sigmoid that preceded it. The TRC is just one more tool that tries to address the problem of processing high dynamic range images.

2 Likes

Hello Wayne,
Thank you for the clear and understandable answer to my question.

Finally, I have to say that I find it much easier to achieve better results with log tone mapping. Here is the .arp file so that anyone who wants to can try it out for themselves.

M1_Log Tone Mapping.dng.arp (12.0 KB)

I’m not saying that Sigmoid is any less good, just that despite comments to the contrary on the net, I simply get on better with Log Tone Mapping. Mainly because the highlights are not so terribly soft.

But it’s a matter of opinion. It could also be that I would develop my image differently in a few weeks or months.

As things stand today: LTM is my favorite!

edit: If I increase the Skew slider in Sigmoid, I can create wonderful contrasts in the highlights. I’m currently editing an image where Sigmoid is better than with Log Tone Mapping.

I’m discovering more and more.

Which prooves what I said the other day: don’t be afraid to try different modules, and even different combinations of modules, and trust your eyes. The important is to get a result that pleases you.

3 Likes