Nikon D700 overexposed areas are magenta

Issue #148 new
Michael Ezra created an issue

When opening in ART Nikon D700 the overexposed areas are rendered with magenta.

For comparison, the same file opened in RT does not have same issue.

Looks like camcost.json in both RT and ART has identical values:

{ // Quality B, data from RusselCottrell at RT forums. sensor is not uniform
"make_model": "Nikon D700",
"dcraw_matrix": [ 8139,-2171,-663,-8747,16541,2295,-1925,2008,8093 ],
//"dcraw_matrix": [ 9336,-3405,14,-7321,14779,2764,-914,1171,8248 ], // illuminant A
"ranges": { "white": [ 15500, 15500, 15500 ] }
// Non linearities start at 15500 (hi ISOs) 15850 (low ISOs) with long exposures (>2sec) and LENR ON .. nominal 15892
// white 15500 is correct for 14-bit files, for 12-bit files RT auto_calculates it 15500*4095/16383=3874
}

Another observation, the Camera & As Shot white balance values for D700 are also different in RT and ART.

Comments (14)

  1. agriggio repo owner

    Hi,

    does this happen also if you set “highlight reconstruction” to something other than “Off”?

    Regarding the WB differences, in ART I’m always using Adobe D65 matrices to compute WB temp/tint, maybe RT is using a different matrix (look at cammatrices.json in ART)

  2. Michael Ezra reporter

    The highlight recornstruction does not help unfortunately.

    Thanks for pointing out the differences in WB, they are very minor, probably within the range of error in measurements

    For D700 camcost.json vs cammatrices.json

    • "dcraw_matrix": [ 8139, -2171, -663, -8747, 16541, 2295, -1925, 2008, 8093],
    • "dcraw_matrix" : [8139, -2171, -664, -8748, 16541, 2296, -1923, 2008, 8093]

  3. Michael Ezra reporter

    Here it is: http://photovertex.com/temp/MichaelEzra-D700-overexposed-DONOTSHARE.zip Please let me know once you get this, I will remove the file from my ftp.

    Actually, this raw file should be very useful for testing Auto CA along with the highlight recovery/color reconstruction.

    This is another issue, but I will mention, apparently, Auto CA correction depends on the accuracy of white pre-processing, as discussed here: https://github.com/Beep6581/RawTherapee/issues/5800. Perhaps it is worth having this tool available

  4. Michael Ezra reporter

    The reason I pointed to Auto CA correction, is that highlight reconstruction largely depends on the accuracy of CA correction - as CA color fringing may contaminate the reconstructed area.

  5. agriggio repo owner

    …but I don’t see anything wrong. Here’s neutral profile, -2Ev of exposure compensation:

    • ART:

    * RawTherapee:

    With highlight recovery in “Blend” mode:

    • ART:

    * RawTherapee:

    With “colour propagation”:

    • ART:

    * RawTherapee:

    The only difference is that in RT you have “clip out of gamut” that is checked by default. This, with no highlight recovery, will simply clip to pure white. But “blend” recovery gives better results… (ART doesn’t clip out of range values until later in the pipeline, when going from scene- to display-referred mode).

  6. Michael Ezra reporter

    Looks like the issue may be somewhere else! please take a look at the screenshots above.

    arp file: http://photovertex.com/temp/MichaelEzra-D700-overexposed-DONOTSHARE.NEF.arp.zip
    The top is after the initial loading of the raw file in rt, zoomed 100% top right corner.
    If you don’t get the same result, zoom in to that place and re-load the raw in ART, it maintains the zoom & position (which is great, btw!)

    After that, if I simply toggle the Exposure panel off/on, the result changes to magenta, as shown on the lower screenshot

  7. agriggio repo owner

    Well, I’ve seen colour propagation fail in similar ways also in other occasions. I can tell you I’ve tried to fix this, but so far with no luck. I just don’t properly understand the algorithm yet.

    Here is a possible workaround – maybe you will find it useful.

  8. Michael Ezra reporter

    One more finding: if I load the raw file and the preview looks like in the top screenshot, then export TIF, the output TIF looks like the lower screenshot.

  9. Michael Ezra reporter

    That’s even more interesting, I see that you added defringe with default settings, looks clean.

    But! when I disable defringe, the entire problem that I described above disappears (toggling exposure does not bring magenta, output does not have magenta either, even with defringe disabled)

  10. Log in to comment