Education Forums
| View previous topic :: View next topic |
| Author |
Message |
AE lover Guest
|
Posted: Sun Jun 22, 2008 11:58 pm Post subject: imaginary numbers for the outputs of the Gain-Offset_Gamma f |
|
|
Hi all,
I am using the GOG model Y=(gain*X+offset) ^gamma to fit the tone
curve of each channel of a monitor. ( X is normalized to be between 0
and 1).
My results are a negative offset and non-integer gamma. I get a
problem with the low digital values. At a low digital value, the
(gain*X+offset) is negative , and thus the (gain*X+offset) ^gamma
will be an imaginary number (gamma is around 2.3).
Can you please suggest what should I do? Just take the real part, or
anything else?
Thanks |
|
| Back to top |
|
 |
| |
Ads |
Advertising
Sponsor
|
|
Gernot Hoffmann Guest
|
Posted: Mon Jun 23, 2008 1:03 pm Post subject: Re: imaginary numbers for the outputs of the Gain-Offset_Gam |
|
|
AE lover schrieb:
| Quote: |
Hi all,
I am using the GOG model Y=(gain*X+offset) ^gamma to fit the tone
curve of each channel of a monitor. ( X is normalized to be between 0
and 1).
My results are a negative offset and non-integer gamma. I get a
problem with the low digital values. At a low digital value, the
(gain*X+offset) is negative , and thus the (gain*X+offset) ^gamma
will be an imaginary number (gamma is around 2.3).
Can you please suggest what should I do? Just take the real part, or
anything else?
Thanks
|
Model 1
The curve fitting for pairs xi,yi can be done by minimizing F(yo,G)
(your model with two instead of three parameters):
ui = yo+(1-yo)*xi
Si = ui^G - yi
F(yo,G)=Sum(i=1 to M) [Si]^2
As you said, this fails for ui<0 (of course G is noninteger).
The standard approach is to set Si=0 if ui<0.
I found this advice in one of Henry R.Kang's books, ch.14:
Color Technology for Electronic Imaging Devices.
For an uncalibrated CRT monitor this is physically somewhat
reasonable (a weak explanation) if we interpret ui as a control
voltage: For ui<0 the luminance doesn't become negative.
For a numerical function minimization which is based on
an assumed continuous function F(yo,G), such a definition is
obviously a desaster: searching a (relative) minimum for an
occasionally jumping function is at least not reliable.
Model 2
For a calibrated monitor the model 1 is wrong, because the
calibration software tries to establish a behaviour like this
model 2:
y=yo+(1-yo)*x^G
This can be seen from the visually flat slope at the origin
for a couple of measured data sets:
http://www.fho-emden.de/~hoffmann/measgamma10022004.pdf
For LCD/TFT monitors, model 1 is IMHO not the least valid.
The tone reproduction curve doesn't follow a nonlinear physical
law but a mathematically defined correction for an essentially
linear output device, in order to achieve the same behaviour
as for a calibrated CRT.
Best regards --Gernot Hoffmann |
|
| Back to top |
|
 |
| |
Ads |
Advertising
Sponsor
|
|
grADE Guest
|
Posted: Tue Jun 24, 2008 8:57 am Post subject: Re: imaginary numbers for the outputs of the Gain-Offset_Gam |
|
|
Hi AE lover,
You should look at the ACS CDL specs if you are working on gain offset
gamma which i assume means you are
working with video or film images.
Their specifications relate to a Cross platform specification which
means different applications
can interpret the Color Correction Data and 'emulate' the same values
or correction using their own internal mathematical formulae.
The ASC CDL spec is for representing CC Changes where Monitors and
calibration are presumed correct.
I could not understand otherwise why you are attempting to change a
monitors characteristics with simple
2 dimensional math. This may work for CRT monitors but given LCD and
Plasmas characteristics 2D math will simply not work.
Adrian Hauser
Digital Intermediate Color Correction
Cutting Edge
Sydney
On Jun 23, 11:03 pm, Gernot Hoffmann <hoffm...@fho-emden.de> wrote:
| Quote: |
AE lover schrieb:
Hi all,
I am using the GOG model Y=(gain*X+offset) ^gamma to fit the tone
curve of each channel of a monitor. ( X is normalized to be between 0
and 1).
My results are a negative offset and non-integer gamma. I get a
problem with the low digital values. At a low digital value, the
(gain*X+offset) is negative , and thus the (gain*X+offset) ^gamma
will be an imaginary number (gamma is around 2.3).
Can you please suggest what should I do? Just take the real part, or
anything else?
Thanks
Model 1
The curve fitting for pairs xi,yi can be done by minimizing F(yo,G)
(your model with two instead of three parameters):
ui = yo+(1-yo)*xi
Si = ui^G - yi
F(yo,G)=Sum(i=1 to M) [Si]^2
As you said, this fails for ui<0 (of course G is noninteger).
The standard approach is to set Si=0 if ui<0.
I found this advice in one of Henry R.Kang's books, ch.14:
Color Technology for Electronic Imaging Devices.
For an uncalibrated CRT monitor this is physically somewhat
reasonable (a weak explanation) if we interpret ui as a control
voltage: For ui<0 the luminance doesn't become negative.
For a numerical function minimization which is based on
an assumed continuous function F(yo,G), such a definition is
obviously a desaster: searching a (relative) minimum for an
occasionally jumping function is at least not reliable.
Model 2
For a calibrated monitor the model 1 is wrong, because the
calibration software tries to establish a behaviour like this
model 2:
y=yo+(1-yo)*x^G
This can be seen from the visually flat slope at the origin
for a couple of measured data sets:http://www.fho-emden.de/~hoffmann/measgamma10022004.pdf
For LCD/TFT monitors, model 1 is IMHO not the least valid.
The tone reproduction curve doesn't follow a nonlinear physical
law but a mathematically defined correction for an essentially
linear output device, in order to achieve the same behaviour
as for a calibrated CRT.
Best regards --Gernot Hoffmann |
|
|
| Back to top |
|
 |
| |
Ads |
Advertising
Sponsor
|
|
Roger Breton Guest
|
Posted: Tue Jul 01, 2008 4:23 am Post subject: Re: imaginary numbers for the outputs of the Gain-Offset_Gam |
|
|
I am not as versed in math as Gernot Hoffman -- please see his excellent
primers in PDF on his site. And I'm not as versed in programming as Graeme
and Gerard, but I have a hunch you'll never be able to fit enough of the
measured gamma with a simple power function. Maybe it would help model the
relationship with a lookup table? Seems the way the more advanced modeling
is going.
Roger
| Quote: |
Hi all,
I am using the GOG model Y=(gain*X+offset) ^gamma to fit the tone
curve of each channel of a monitor. ( X is normalized to be between 0
and 1).
My results are a negative offset and non-integer gamma. I get a
problem with the low digital values. At a low digital value, the
(gain*X+offset) is negative , and thus the (gain*X+offset) ^gamma
will be an imaginary number (gamma is around 2.3).
Can you please suggest what should I do? Just take the real part, or
anything else?
Thanks |
|
|
| Back to top |
|
 |
| |
Ads |
Advertising
Sponsor
|
|
AE lover Guest
|
Posted: Thu Jul 03, 2008 11:05 pm Post subject: Re: imaginary numbers for the outputs of the Gain-Offset_Gam |
|
|
Thank you guys for interesting suggestions. Yes, I will switch to use
look-up table, instead.
On Jun 30, 7:23 pm, Roger Breton <gr...@videotron.ca> wrote:
| Quote: |
I am not as versed in math as Gernot Hoffman -- please see his excellent
primers in PDF on his site. And I'm not as versed in programming as Graeme
and Gerard, but I have a hunch you'll never be able to fit enough of the
measured gamma with a simple power function. Maybe it would help model the
relationship with a lookup table? Seems the way the more advanced modeling
is going.
Roger
Hi all,
I am using the GOG model Y=(gain*X+offset) ^gamma to fit the tone
curve of each channel of a monitor. ( X is normalized to be between 0
and 1).
My results are a negative offset and non-integer gamma. I get a
problem with the low digital values. At a low digital value, the
(gain*X+offset) is negative , and thus the (gain*X+offset) ^gamma
will be an imaginary number (gamma is around 2.3).
Can you please suggest what should I do? Just take the real part, or
anything else?
Thanks- Hide quoted text -
- Show quoted text - |
|
|
| Back to top |
|
 |
| |
Ads |
Advertising
Sponsor
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|

93 Attacks blocked
Powered by phpBB © 2001, 2005 phpBB Group
|