New project: camera color profile calculation - page 20 - RAW Shooting and Processing - CHDK Forum
supplierdeeply

New project: camera color profile calculation

  • 480 Replies
  • 329702 Views
*

Offline lks

  • *
  • 16
  • [A570IS, S5IS]
Re: New project: camera color profile calculation
« Reply #190 on: 01 / June / 2008, 21:14:42 »
Advertisements
I'm thinking part of the problem is that we need to also do a calibration for Tungsten light (Type A).  I'm guessing that's why the colors shift a bit with different color light, even after correcting for the white balance.

*

Offline lukg

  • ***
  • 162
  • Eos 450D+18-55is+55-250is & Powershot S5is - 1.01a
Re: New project: camera color profile calculation
« Reply #191 on: 02 / June / 2008, 08:46:01 »
I got a better palette pic.
I got a matrix at 0.90, and it seems to get 22/24 areas (my previous matrix got 7/22 areas). Obviously "Max error is greater then 10%, RESULTS ARE POOR" :D, but it seems to be a lot better than the others we found.

Quote
RESULTS
White area: 1
Errors:
Zone 1: 7,3%
Zone 2: 12,4%
Zone 3: 9,3%
Zone 4: 6,7%
Zone 5: 3,3%
Zone 6: 5,4%
Zone 7: 13,4%
Zone 8: 8,8%
Zone 9: 12,3%
Zone 10: 13,5%
Zone 11: 9,1%
Zone 12: 1,8%
Zone 13: 13,3%
Zone 14: 13,5%
Zone 15: 13,4%
Zone 16: 8,9%
Zone 17: 5,1%
Zone 18: 6,9%
Zone 19: 6,8%
Zone 20: 7,8%
Zone 21: 11,1%
Zone 22: 11,1%
### Max error is greater then 10%, RESULTS ARE POOR ###
Camera -> XYZ matrix:
1,637840 0,508453 0,781881
0,147034 1,924260 -0,003592
-0,104238 -0,650416 5,358281
XYZ -> Camera matrix:
0,622294 -0,195168 -0,090936
-0,047538 0,534707 0,007295
0,006335 0,061109 0,185744

Here a simple comparison with my previous matrix (Temperature,hue fixed for both images). On the right the new matrix.
You always need to adjust white balance (and primary colors) to let the colors match better with camera jpg, but this is a better matrix without doubt.
http://img217.imageshack.us/img217/6591/cattura1lj7.jpg
http://img76.imageshack.us/img76/966/cattura2lv7.jpg
 


*

Offline lks

  • *
  • 16
  • [A570IS, S5IS]
Re: New project: camera color profile calculation
« Reply #192 on: 02 / June / 2008, 11:14:47 »
I agree that does look better!

Can you share a DNG that has the raw pallette?  I can then run the ACR calibration program above.

*

Offline lukg

  • ***
  • 162
  • Eos 450D+18-55is+55-250is & Powershot S5is - 1.01a
Re: New project: camera color profile calculation
« Reply #193 on: 02 / June / 2008, 11:58:31 »
Sure, the problem is that I used a "virtual" gretag chart found online, not a real gretag chart (i took a photo of my LCD).
I should have a calibrated monitor to do ACR calibration...but I don't  :D.
If you have a real gretag you're the only that can do an empirical calibration in ACR, using a real DNG of the charts, and hoping to apply a "good" matrix on it. My DNG would be useless cause it depends on the calibration of my monitor.
 
Here the DNG (with latest matrix) and the camera JPG.

zSHARE - palette.rar

I did a test. Opened both in Photoshop, and set the white balance for both, picking up the color of the "white" square area. It's far from a definitive solution but it doesn't seem so bad.
(camera jpg on the right)





PS. Could you upload a real gretag chart photo taken in daylight by the S5 (jpg+crw)?
« Last Edit: 02 / June / 2008, 18:35:17 by lukg »


*

Offline lks

  • *
  • 16
  • [A570IS, S5IS]
Re: New project: camera color profile calculation
« Reply #194 on: 02 / June / 2008, 20:58:42 »
I forgot that you did not take the calibration photo in daylight -- I'm guessing the ACR calibration program works best on a color checker chart shot in daylight.

At any rate, the JPG/CRW for my calibration is at dngpsrawin.zip - 10.24MB.

Now that I know it is possible to get 22 areas, I will try some other time to take a better calibration picture.  My guess is that one has to push the exposure to the right enough so that the white patch is 245+ in intensity.  I can just bracket a few exposures and see if any work better.

*

Offline lukg

  • ***
  • 162
  • Eos 450D+18-55is+55-250is & Powershot S5is - 1.01a
Re: New project: camera color profile calculation
« Reply #195 on: 03 / June / 2008, 06:50:04 »
I forgot that you did not take the calibration photo in daylight -- I'm guessing the ACR calibration program works best on a color checker chart shot in daylight.

Thanks for your files.
The problem for me is that ACR calibration script expects to compare colors taken by an uncalibrated source with colors of real gretag charts (those colors are fixed and known). But without a real gretag is useless (we are lucky you have one), because the colors of my palette shot depends on two variables: colors fidelity of my LCD, and color fidelity in capturing of my camera. So I have 2 non-calibrated sources mixed together (actually we have another variable we must face to: the ACR calibration is done after we apply matrix to DNG. If the matrix is not good, with the ACR calibration we obtain optimal settings for that image and nothing else, and that's pretty useless too)
For what I saw in your JPG, the camera is already good calibrated by Canon. So ACR calibration is not our main problem (since our DNG are not "bad calibrated" from Canon, they're not calibrated at all). The problem is finding a perfect transformation matrix, but as I already said, I'm worried that there are millions of good matrix, but only few are good for all the pictures made by that camera. :'(
« Last Edit: 03 / June / 2008, 08:30:40 by lukg »

*

Offline lukg

  • ***
  • 162
  • Eos 450D+18-55is+55-250is & Powershot S5is - 1.01a
Re: New project: camera color profile calculation
« Reply #196 on: 04 / June / 2008, 13:23:48 »
Ok, I did some crazy experiments. I took 10 pictures (-1.1/3exp) in continuos mode. Averaged RAWs on camera, and jpgs using Photomatix. This is the results of the first calibration (at 1.00 brighness):

Quote
RESULTS
White area: 1
Errors:
Zone 1: 11,8%
Zone 2: 10,6%
Zone 3: 11,4%
Zone 4: 11,8%
Zone 5: 8,5%
Zone 6: 11,3%
Zone 7: 9,4%
Zone 8: 5,1%
Zone 9: 5,7%
Zone 10: 11,8%
Zone 11: 10,5%
Zone 12: 3,5%
Zone 13: 11,6%
Zone 14: 12,3%
Zone 15: 9,6%
Zone 16: 6,4%
Zone 17: 6,9%
Zone 18: 8,7%
Zone 19: 9,7%
Zone 20: 11,2%
Zone 21: 7,5%
Zone 22: 4,2%
Zone 23: 9,2%
Zone 24: 11,8%
### Max error is greater then 10%, RESULTS ARE POOR ###
Camera -> XYZ matrix:
1,829391 0,412710 0,792508
0,235154 1,880082 -0,035845
0,024875 -0,741887 5,160420
XYZ -> Camera matrix:
0,568353 -0,159643 -0,088393
-0,071335 0,553391 0,014799
-0,012995 0,080328 0,196336

All 24 patches found. That's a good start i think.

*

Offline lukg

  • ***
  • 162
  • Eos 450D+18-55is+55-250is & Powershot S5is - 1.01a
Re: New project: camera color profile calculation
« Reply #197 on: 04 / June / 2008, 19:42:21 »
I have an idea for Artden, after I saw how the ACR calibration script works.
 I don't know what are the mathematic calculations that are behind dng4ps, but it should be usefull in my opinion, having the possibility to choose a weight value to assing for each areas in the calibration process (like ACR script).
Here the screenshot of what i am talking about:

ACR Calibrator L

I think it could be usefull in finding a good compromise between minimizing the total color error (all color of the palette = same importance) and what color are "more" important than other ones (eg. red, green, blue patches).

Is it an insane idea?
« Last Edit: 04 / June / 2008, 20:13:15 by lukg »


*

DawMatt

Re: New project: camera color profile calculation
« Reply #198 on: 06 / June / 2008, 00:35:29 »
Hi Lukg,

I don't know if it's normal, but this are my results changing only the im.brightness:
Thanks for spending some time working through the calibration steps.

As you have noticed the im. bright has a significant impact on the minimum error rate. In my experience between 0.50 and 0.80 seems to be the most workable range, with 0.50 usually giving the best minimum error rate but (conversely) the better overall matrix coming from slightly higher minimum error rates.  Don't understand why, it just seems to work out that way.

Thanks for pointing out the issues with the potential verification steps I had in the wiki page.  I've now updated them to update the first matrix, and also to mention that writing to both the first and second matricies should be considered (that's what I normally do).  Main reason for overwriting both is that some camera types do use both matricies (namely those that came from dcraw).

And don't be concerned about the palette photo taking being "a lottery".  I know exactly what you mean.  Its not easy taking a good calibration photo.

Thanks,
Matt

*

DawMatt

Re: New project: camera color profile calculation
« Reply #199 on: 06 / June / 2008, 00:41:36 »
Hi lks,

Code: [Select]
RESULTS
White area: 9
Errors:
Zone 1: 11.1%
...
Zone 9: 6.0%
### Max error is greater then 10%, RESULTS ARE POOR ###
As you will notice above, only 9 zones have made it through the entire calculation process.  That means between 13 and 15 of the areas you marked before starting processing where considered [bad!] (as seen in the section before that you pasted in).  Personally I would want 0 [bad!] areas before adding a camera matrix to DNG4PS-2.  Unfortunately taking a good calibration shot and calculating a matrix with no bad zones seems more art than science.  Just keep trying!

Thanks,
Matt

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal