Hi,
TL;DR: I’d love to read about your experience in making DCP profiles for artificial light sources.
I’ve been trying to make a DCP for my { current camera + macro lens + LED video light source + target } in the context of scanning film (and inverting it in RawTherapee Film Negative
module by @rom9).
I bought a target (Datacolor SpyderCheckr24) - fun fact? I also happen to have bought been scammed into a new old stock sealed faulty calibrite colorchecker passport - it lacks the 24-patch card (!).
After having read rawpedia’s article, I went through Torger’s dcamprof
documentation here and there.
I think I need the interaction with the experienced members here
So, feel free to comment on how you actually orient, light, shoot and preprocess your target before feeding it through the “basic” dcamprof
workflow.
A. Orient the target and the light source:
- Datacolor say the light source should be at a 45° angle.
a. sounds reasonable (to avoid most of the glare),
b. but in practice, I get some glare, most easily seen on the shiny-grainy texture of the grid of the target → I defocus slightly (just as Torger says). - Datacolor don’t mention anything about target orientation when illumination evenness is compromised (read: I can’t easily light my target evenly). This is where Torger suggests: " If you have visibly uneven light, orient the target such that darker patches are on the bright side, if possible. "
a. is this enough?
b. I thought it wasn’t (but I can’t prove it, yet) so I used theGraduated Filter
tool in RT to reduce a bit of the lightness gradient I could most visibly see on the grid lines.
c. flat-field: not sure how I should do it in RT, in this specific case. Get a white non-shiny piece of paper, shoot it in the same lighting conditions and then what? is that so easily applicable to this situation?
B. Target should be flat (in the reference image output): not really a problem, I have a copy stand (Kaiser RS2XA); if it were a problem, I’d retouch perspective in RT.
C. Lens should be closed down sufficiently to get contrast, fall-off problems out of the way. Not a problem. I use the automatic lens corrections anyway in RT.
D. ETTR should be used. Easy for me in-camera with UniWB. Otherwise, I’d check RT raw histogram.
E. Straighten, crop and rotate: OK.
- the brightest “white” patch must be at the top left corner, per the description of the target in the
ref
directory ofargyllcms
unfold me (datacolor reference guide excerpt)
Lighting the SpyderCheckr
Mount the SpyderCheckr or place in a stable location. Light it from a 45 degree angle. The ideal way to light a target is to use a single lightsource, with no reflector or diffuser, from a long distance. This assures that all portions of the target will have the same amount and and color of light, reducing fall-off and color variation across the width of a target. A good fluorescent proofing lamp placed in front of the target, with the bulb along the length of the target, shining down from above at 45 degrees, will offer even light. The perfect light source (in terms of color quality, as well as being a point source at a great distance) is the sun… but the sun comes with an automatic second light source, diffused, and of a very different color, called sky light. So if you shoot the target using sunlight, its best to do it under an overhang where there is minimal skylight involved.
Honestly, to me, the elephant in the room is the illumination evenness. Do you agree?
Should I solve this before the acquisition? or are the dcamprof
features robust enough to compensate for that? I don’t get what the “glare-matching” features do (or how they do it, esp. after looking at the suggested JSON target layout file contents dcamprof/data-examples/cc24-layout.json
) : quoting from the manual:
-g <target-layout.json>
provide target layout for glare matching and/or flatfield correction."
Once I get this sorted out, I might consider using my faulty colorchecker passport (for skin tones), too, to combine it into the DCP (stupid idea?)
Also, can someone dumb down, for me, the process of evaluating the results of the scanin
, make-profile
, make-dcp
sequence?
unfold me for console output
$ scanin -v -p -dipn nikon_D750_60mmAFD_CN-T96_spydercheckr24.tif /opt/homebrew/Cellar/argyll-cms/2.3.0/ref/SpyderChecker24.{cht,cie}
Input file 'nikon_D750_60mmAFD_CN-T96_spydercheckr24.tif': w=2971, h=4278, d = 3, bpp = 16
Data input file '/opt/homebrew/Cellar/argyll-cms/2.3.0/ref/SpyderChecker24.cie'
Data output file 'nikon_D750_60mmAFD_CN-T96_spydercheckr24.ti3'
Chart reference file '/opt/homebrew/Cellar/argyll-cms/2.3.0/ref/SpyderChecker24.cht'
Creating diagnostic tiff file 'diag.tif'
About to allocate scanrd_ object
Verbosity = 2, flags = 0x62a01
About to read input tiff file and discover groups
adivval = 1.000000
About to calculate edge lines
704 useful edges out of 5250
About to calculate perspective correction
Perspective correction factors = -0.000003 0.000004 1485.500000 2139.000000
About to calculate rotation
Mean angle = -0.250376
Standard deviation = 3.321807
Robust mean angle = 0.029528 from 558 lines
About to calculate feature information
About to read reference feature information
Read of chart reference file succeeded
About to match features
Checking xx
Checking yy
Checking xy
Checking yx
Checking xix
Checking yiy
Checking xiy
Checking yix
Axis matches for each possible orientation:
0: xx = 0.416864, yy = 0.332026, xx.sc = 0.145293, yy.sc = 0.144657
90: xiy = 0.311533, yx = 0.142099, xiy.sc = 0.147144, yx.sc = 0.280691
180: xix = 0.416864, yiy = 0.354814, xix.sc = 0.145293, yiy.sc = 0.144293
270: xy = 0.320125, yix = 0.142099, xy.sc = 0.147096, yix.sc = 0.280691
r0 = 0.530600, r90 = 0.179498, r180 = 0.543654, r270 = 0.183546
bcc = 0.543654, wcc = 0.179498
There are 2 candidate rotations:
cc = 0.530600, irot = 0.029528, xoff = 47.039445, yoff = -55.332419, xscale = 6.882655, yscale = 6.912913
cc = 0.543654, irot = 180.029528, xoff = -2913.665415, yoff = -4236.097761, xscale = 6.882655, yscale = 6.930327
About to compute match transform for rotation 0.029528 deg.
About to setup value scanrdg boxes
About to read raster values
About to compute expected value correlation
About to compute match transform for rotation 180.029528 deg.
About to setup value scanrdg boxes
About to read raster values
About to compute expected value correlation
Expected value distance values are:
0, rot 0.029528: 2387.960477
1, rot 180.029528: 4936.632612
Chosen rotation 0.029528 deg. as best
About to compute final match transform
Improve match
About to setup value scanrdg boxes
About to read raster values
About to write diag file
Writing output values to file 'nikon_D750_60mmAFD_CN-T96_spydercheckr24.ti3'
$ ~/programs/dcamprof/dcamprof/src/dcamprof make-profile -g ~/programs/dcamprof/dcamprof/data-examples/cc24-layout.json ~/Pictures/D750/spyderchecker_24/D750_60mm_CN-T96_20220625/nikon_D750_60mmAFD_CN-T96_spydercheckr24.{ti3,profile.json}
Reading target...
Glare test before glare matching...
Warning: large dynamic range difference detected. Likely glare issue.
Camera G on darkest patch(es) is 274.5% lighter compared to observer Y.
Y dynamic range is 5.01 stops, G dynamic range is 3.10 stops, difference
1.90 stops. A small difference is normal, while a large indicates that there
is glare.
Glare-matching target...
Minimum Y changed from 0.027800 to 0.132705. Glare was modeled in RGB space.
Testing glare after adjusting reference values (camera G and observer Y should
be close).
Camera G on darkest patch(es) is -20.6% lighter compared to observer Y.
Y dynamic range is 2.77 stops, G dynamic range is 3.10 stops, difference
-0.33 stops. A small difference is normal, while a large indicates that there
is glare.
Generating values for the calibration illuminant D50...
The most neutral patch (A06) differs 4.43 DE from actual neutral,
transforming target reference XYZ values to match, using CAT02.
Automatic LUT relaxation weights assigned.
Making camera profile...
Finding a camera raw RGB to CIE XYZ matrix for calibration illuminant D50...
Warning: whitest (most neutral) patch in target (A06) differs DE 4.43
from calibration illuminant, matrix precision may suffer.
Inverting to get ColorMatrix:
{
"ColorMatrix1": [
[ 1.122317, -0.355064, -0.233984 ],
[ -0.800380, 1.625453, 0.161850 ],
[ -0.344698, 0.439426, 0.750296 ]
]
}
Matrix patch match average DE 6.00, DE LCh 2.85 3.52 2.72
median DE 6.09, DE LCh 2.95 3.15 3.13
p90 DE 8.30, DE LCh 5.21 6.26 4.57
max DE 10.47, DE LCh 5.79 9.05 6.37
ColorMatrix optimal white balance for target: 0.540897,1,0.73557 (m1.84878,1,1.35949)
Finding a camera raw RGB to CIE XYZ matrix for connection space illuminant D50...
{
"LUTMatrix1": [
[ 0.627650, 0.134828, 0.201740 ],
[ 0.236348, 0.701442, 0.062210 ],
[ 0.000103, 0.042855, 0.782243 ]
]
}
LUTMatrix optimal white balance for target: 0.51573,1,0.773449 (m1.939,1,1.29291)
Matrix patch match average DE 6.75, DE LCh 2.63 3.53 4.03
median DE 6.50, DE LCh 2.36 3.45 3.51
p90 DE 10.22, DE LCh 6.22 7.78 9.19
max DE 12.07, DE LCh 7.37 8.28 10.10
Finding a camera raw RGB to CIE XYZ matrix for connection space illuminant D50...
Y row limit set to -0.2.
Applying white-balance to get ForwardMatrix:
{
"ForwardMatrix1": [
[ 0.578345, 0.166102, 0.219771 ],
[ 0.274867, 0.710576, 0.014557 ],
[ 0.087680, -0.276181, 1.013702 ]
]
}
ForwardMatrix optimal white balance for target: 0.51573,1,0.773449 (m1.939,1,1.29291)
Matrix patch match average DE 5.92, DE LCh 2.83 2.92 3.33
median DE 5.64, DE LCh 2.76 3.08 3.31
p90 DE 8.53, DE LCh 5.31 5.58 5.40
max DE 12.05, DE LCh 5.92 7.98 7.40
Making 2.5D chromaticity-addressed lookup table for XYZ correction...
16.67% of the patches was put in a chromaticity group due to nearby neighbor.
25.00% of the patches was removed due to being nearby the whitepoint.
Largest chromaticity group contains 2 patches. Patch count reduced from
24 to 14. Note that patch matching cannot reach 100% when chromaticity
groups are formed, as the LUT matches the average within a group.
Lightness axis is disabled. Since lightness affects chroma, the LUT chroma
control points are recalculated to better match the uncorrected lightness.
A residual error of up to about 0.2 DE is expected.
Relaxing LUT stretch with up to 2.72 DE. Iterating over 14 patches...
Lightness correction is disabled.
Average DE for the 14 tested patches increased to 3.02 after LUT relax.
0.00% could do without LUT correction.
Native LUT patch match average DE 4.24, DE LCh 2.85 1.60 1.73
median DE 3.70, DE LCh 2.77 1.11 1.06
p90 DE 7.44, DE LCh 5.31 4.38 5.53
max DE 11.38, DE LCh 5.92 8.60 8.01
5 worst patches for Overall DE:
A01 RGB 0.525 1.000 0.763 XYZref 0.757 0.793 0.786 XYZcam 0.960 0.994 0.811 sRGB #D7E8FC #FEFEFC DE 11.38 DE LCh +5.00 -8.60 -5.53 (whitish purple-blue)
A03 RGB 0.255 0.486 0.366 XYZref 0.422 0.443 0.430 XYZcam 0.471 0.488 0.386 sRGB #A6B3C0 #BBB9B5 DE 9.82 DE LCh +2.13 -5.27 -8.01 (pale purple-blue)
D03 RGB 0.071 0.161 0.073 XYZref 0.176 0.202 0.124 XYZcam 0.126 0.154 0.073 sRGB #728068 #60734E DE 7.44 DE LCh -5.92 +4.38 -1.09 (grayish yellow-green)
A04 RGB 0.150 0.285 0.215 XYZref 0.245 0.256 0.236 XYZcam 0.276 0.286 0.227 sRGB #848B92 #93918E DE 6.79 DE LCh +2.49 -2.84 -5.65 (gray 60%)
C01 RGB 0.270 0.193 0.047 XYZref 0.447 0.366 0.088 XYZcam 0.348 0.282 0.055 sRGB #E88C4C #D17B36 DE 5.97 DE LCh -5.81 +0.33 +1.31 (orange)
5 worst patches for Lightness DE:
D03 RGB 0.071 0.161 0.073 XYZref 0.176 0.202 0.124 XYZcam 0.126 0.154 0.073 sRGB #728068 #60734E DE 7.44 DE LCh -5.92 +4.38 -1.09 (grayish yellow-green)
C01 RGB 0.270 0.193 0.047 XYZref 0.447 0.366 0.088 XYZcam 0.348 0.282 0.055 sRGB #E88C4C #D17B36 DE 5.97 DE LCh -5.81 +0.33 +1.31 (orange)
B06 RGB 0.071 0.193 0.314 XYZref 0.146 0.139 0.312 XYZcam 0.195 0.181 0.392 sRGB #3D68AC #5373BE DE 5.58 DE LCh +5.31 +0.96 +2.40 (purple-blue)
C06 RGB 0.510 0.548 0.165 XYZref 0.568 0.533 0.133 XYZcam 0.712 0.669 0.168 sRGB #F4B55C #FEC967 DE 5.18 DE LCh +5.05 +1.11 +0.18 (light orange)
A01 RGB 0.525 1.000 0.763 XYZref 0.757 0.793 0.786 XYZcam 0.960 0.994 0.811 sRGB #D7E8FC #FEFEFC DE 11.38 DE LCh +5.00 -8.60 -5.53 (whitish purple-blue)
5 worst patches for Chroma DE:
A01 RGB 0.525 1.000 0.763 XYZref 0.757 0.793 0.786 XYZcam 0.960 0.994 0.811 sRGB #D7E8FC #FEFEFC DE 11.38 DE LCh +5.00 -8.60 -5.53 (whitish purple-blue)
A03 RGB 0.255 0.486 0.366 XYZref 0.422 0.443 0.430 XYZcam 0.471 0.488 0.386 sRGB #A6B3C0 #BBB9B5 DE 9.82 DE LCh +2.13 -5.27 -8.01 (pale purple-blue)
D03 RGB 0.071 0.161 0.073 XYZref 0.176 0.202 0.124 XYZcam 0.126 0.154 0.073 sRGB #728068 #60734E DE 7.44 DE LCh -5.92 +4.38 -1.09 (grayish yellow-green)
A04 RGB 0.150 0.285 0.215 XYZref 0.245 0.256 0.236 XYZcam 0.276 0.286 0.227 sRGB #848B92 #93918E DE 6.79 DE LCh +2.49 -2.84 -5.65 (gray 60%)
B01 RGB 0.060 0.275 0.296 XYZref 0.189 0.252 0.394 XYZcam 0.182 0.233 0.330 sRGB #00A1C3 #0F90AD DE 3.28 DE LCh -1.80 -2.74 -0.22 (blue)
5 worst patches for Hue DE:
A03 RGB 0.255 0.486 0.366 XYZref 0.422 0.443 0.430 XYZcam 0.471 0.488 0.386 sRGB #A6B3C0 #BBB9B5 DE 9.82 DE LCh +2.13 -5.27 -8.01 (pale purple-blue)
A04 RGB 0.150 0.285 0.215 XYZref 0.245 0.256 0.236 XYZcam 0.276 0.286 0.227 sRGB #848B92 #93918E DE 6.79 DE LCh +2.49 -2.84 -5.65 (gray 60%)
A01 RGB 0.525 1.000 0.763 XYZref 0.757 0.793 0.786 XYZcam 0.960 0.994 0.811 sRGB #D7E8FC #FEFEFC DE 11.38 DE LCh +5.00 -8.60 -5.53 (whitish purple-blue)
A02 RGB 0.373 0.709 0.537 XYZref 0.615 0.640 0.544 XYZcam 0.689 0.713 0.568 sRGB #CED1D4 #DEDBD7 DE 4.54 DE LCh +2.40 +0.32 -3.84 (gray 80%)
A05 RGB 0.079 0.151 0.113 XYZref 0.158 0.165 0.143 XYZcam 0.146 0.152 0.119 sRGB #6E7174 #6D6C69 DE 3.88 DE LCh -1.68 -0.19 -3.49 (gray 50%)
5 best patches for Overall DE:
A06 RGB 0.060 0.117 0.090 XYZref 0.112 0.117 0.096 XYZcam 0.112 0.117 0.096 sRGB #5F5F5F #5F5F5F DE 0.00 DE LCh +0.00 +0.00 +0.00 (gray 40%)
B02 RGB 0.236 0.187 0.218 XYZref 0.368 0.263 0.347 XYZcam 0.370 0.263 0.329 sRGB #C26FB2 #C56EAE DE 1.34 DE LCh -0.00 -0.19 +1.33 (purple)
C03 RGB 0.283 0.183 0.130 XYZref 0.364 0.266 0.186 XYZcam 0.387 0.284 0.189 sRGB #D06F82 #D67383 DE 1.87 DE LCh +1.45 +0.29 +1.15 (purple-red)
D02 RGB 0.151 0.308 0.344 XYZref 0.305 0.294 0.478 XYZcam 0.317 0.305 0.459 sRGB #7D91CE #8693CA DE 2.58 DE LCh +0.83 -1.49 +1.14 (purple-blue)
D06 RGB 0.126 0.165 0.105 XYZref 0.181 0.174 0.122 XYZcam 0.198 0.187 0.125 sRGB #846F69 #8C716A DE 2.59 DE LCh +1.49 +2.12 -0.07 (brown)
Writing output to "/Users/cynamon/Pictures/D750/spyderchecker_24/D750_60mm_CN-T96_20220625/nikon_D750_60mmAFD_CN-T96_spydercheckr24.profile.json"...
Complete!
$ ~/programs/dcamprof/dcamprof/src/dcamprof make-dcp -n "Nikon D750" -d "NikonD750_60mmAFD_CN-T96" -t acr ~/Pictures/D750/spyderchecker_24/D750_60mm_CN-T96_20220625/nikon_D750_60mmAFD_CN-T96_spydercheckr24.profile.{json,dcp}
Generating 2.5D HueSatMap with 90x30 = 2700 entries...done!
The tone curve's contrast value is 1.30 (=> auto chroma scaling value 1.121)
Generating 3D LookTable with 90x30x30 = 81000 entries for the neutral tone reproduction operator...
0%..10%..20%..30%..40%..50%..60%..70%..80%..90%..100%
Writing output to "/Users/cynamon/Pictures/D750/spyderchecker_24/D750_60mm_CN-T96_20220625/nikon_D750_60mmAFD_CN-T96_spydercheckr24.profile.dcp"...
Complete!
Thanks very much for your time and help.