CN1889693A - Gamma characteristic correcting method and detecting method for determining equivalent model and parameter thereof - Google Patents

Gamma characteristic correcting method and detecting method for determining equivalent model and parameter thereof Download PDF

Info

Publication number
CN1889693A
CN1889693A CNA2005100802535A CN200510080253A CN1889693A CN 1889693 A CN1889693 A CN 1889693A CN A2005100802535 A CNA2005100802535 A CN A2005100802535A CN 200510080253 A CN200510080253 A CN 200510080253A CN 1889693 A CN1889693 A CN 1889693A
Authority
CN
China
Prior art keywords
mrow
model
inverse
equal
equivalent
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CNA2005100802535A
Other languages
Chinese (zh)
Other versions
CN100527856C (en
Inventor
罗忠
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CNB2005100802535A priority Critical patent/CN100527856C/en
Priority to PCT/CN2006/000710 priority patent/WO2007003086A1/en
Publication of CN1889693A publication Critical patent/CN1889693A/en
Application granted granted Critical
Publication of CN100527856C publication Critical patent/CN100527856C/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/14Picture signal circuitry for video frequency region
    • H04N5/20Circuitry for controlling amplitude response
    • H04N5/202Gamma control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/80Camera processing pipelines; Components thereof
    • H04N23/82Camera processing pipelines; Components thereof for controlling camera response irrespective of the scene brightness, e.g. gamma correction

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Transforming Electric Information Into Light Information (AREA)
  • Picture Signal Circuits (AREA)
  • Facsimile Image Signal Circuits (AREA)

Abstract

本发明涉及视频通信技术,特别公开信号传输和处理环节中伽玛特性等效模型确定、等效模型参数的检测方法以及校正方法,以解决现有技术中伽玛等效模型选择和模型参数测量不准确,从而无法准确分析并校正信号传输和处理环节中的伽玛特性。所述方法包括下列步骤:确定校正点,该校正点之前有Na个环节之后有Np个环节;选择等效所述Na个环节伽玛特性的第一等效模型并确定其第一逆模型,选择等效所述Np个环节伽玛特性的第二等效模型并确定其第二逆模型;根据所述第一逆模型和所述第二逆模型构造校正环节模型,利用该校正环节模型确定所述Na个环节最后输出信号的校正信号并将该校正信号输入所述Np个环节。

Figure 200510080253

The present invention relates to video communication technology, and particularly discloses the gamma characteristic equivalent model determination, equivalent model parameter detection method and correction method in the signal transmission and processing links, so as to solve the gamma equivalent model selection and model parameter measurement in the prior art Inaccurate, so that the gamma characteristics in the signal transmission and processing links cannot be accurately analyzed and corrected. The method includes the following steps: determining a correction point, N p links after N a links before the correction point; selecting the first equivalent model equivalent to the gamma characteristics of the N a links and determining its first Inverse model, select the second equivalent model equivalent to the gamma characteristics of the N p links and determine its second inverse model; construct a correction link model according to the first inverse model and the second inverse model, use the The correction link model determines the correction signal of the final output signal of the N a links and inputs the correction signal to the N p links.

Figure 200510080253

Description

伽玛特性的校正方法和确定等效模型及其参数的检测方法Correction method of gamma characteristic and detection method of determining equivalent model and its parameters

技术领域technical field

本发明涉及视频通信技术,特别涉及视频信号传输和处理环节中确定伽玛特性等效模型及其参数的检测方法和校正方法。The invention relates to video communication technology, in particular to a detection method and a correction method for determining a gamma characteristic equivalent model and its parameters in video signal transmission and processing links.

背景技术Background technique

Gamma校正是多媒体信息系统中普遍存在并需要解决的问题,对于多媒体信息系统的由摄像机/摄像头捕获的视频/静止图像、计算机生成的图形/动画、以及在通信中来自对方终端的视频/静止图像等,为了在显示设备上达到高质量的显示效果,获得好的用户体验(User Experience,或者叫做Quality ofExperience),必须进行Gamma校正。Gamma correction is a common problem in multimedia information systems that needs to be solved. For multimedia information systems, video/still images captured by cameras/cameras, computer-generated graphics/animations, and video/still images from other terminals in communication etc. In order to achieve a high-quality display effect on the display device and obtain a good user experience (User Experience, or Quality of Experience), Gamma correction must be performed.

与本发明相关的多媒体信息系统涉及Gamma校正的情况包含如下方面:The situation that the multimedia information system related to the present invention involves Gamma correction includes the following aspects:

情况A:本地终端系统,信息主要在本地终端上处理,不涉及通信过程。主要是本地摄像机/摄像头捕获的视频/静止图像,计算机生成的图形/动画等在本地显示屏上显示的情况。比如PC、PDA(Personal Digital Assistant)或者带有摄像功能的手机等。Situation A: local terminal system, information is mainly processed on the local terminal and does not involve the communication process. Mainly the video/still image captured by the local camera/camera, computer-generated graphics/animation, etc. are displayed on the local display. Such as PC, PDA (Personal Digital Assistant) or mobile phone with camera function.

情况B:多终端/终端-服务器通信系统,多个终端之间通信,或者终端和服务器之间通信。主要是可视电话,带有MMS(多媒体短信)或者视频通信功能的高端(2.5G/3G、B3G)手机、PDA等。Case B: Multi-terminal/terminal-server communication system, communication between multiple terminals, or communication between a terminal and a server. Mainly videophones, high-end (2.5G/3G, B3G) mobile phones, PDAs, etc. with MMS (Multimedia Message Message) or video communication functions.

视频通信目前正在随着宽带网络的迅速发展而得到日益广泛的应用,在国内和国际上,视频会议和可视电话业务正在成为NGN(Next Generation Network下一代网络)上的基本业务。各国的电信运营商也非常重视这个市场机会,可以预期在未来几年中,视频通信业务将成为运营商重要的业务增长点。发展此类业务的一个关键问题是提高端到端(End-to-end)的用户体验(UserExperience,或者叫做Quality of Experience)。用户体验中除了网络的QoS(丢包,延迟,抖动,R因子等)参数外,对于视频,因为各个环节引起的Gamma非线性问题,造成对于亮度信号的畸变(Distortion),也是影响最终用户体验的重要因素。但是目前,对于提高端到端用户体验的方法和技术主要集中在保证网络QoS和视频压缩编码相关的前后处理(Pre-processing,Post-processing)方面,而对于Gamma特性引起的亮度畸变问题,缺乏关注和系统的解决方法,但是该问题的严重性已经引起了一些国际大电信运营商的关注。法国电信(France Telecom)在国际电信联盟ITU-T近期就提出了要在视频通信中考虑Gamma特性对于通信用户体验的影响,并对此类问题加以解决的建议。Video communication is currently being widely used with the rapid development of broadband networks. Domestically and internationally, video conferencing and videophone services are becoming basic services on NGN (Next Generation Network). Telecom operators in various countries also attach great importance to this market opportunity. It can be expected that in the next few years, video communication services will become an important business growth point for operators. A key issue in developing this type of business is to improve the end-to-end (End-to-end) user experience (UserExperience, or Quality of Experience). In user experience, in addition to network QoS (packet loss, delay, jitter, R factor, etc.) parameters, for video, the Gamma nonlinearity caused by each link causes distortion of the brightness signal, which also affects the end user experience. important factor. However, at present, the methods and technologies for improving end-to-end user experience are mainly focused on ensuring network QoS and video compression coding-related pre-processing (Post-processing), but for the brightness distortion problem caused by Gamma characteristics, there is a lack of However, the seriousness of this problem has attracted the attention of some major international telecom operators. France Telecom (France Telecom) recently proposed in the International Telecommunication Union ITU-T to consider the impact of Gamma characteristics on communication user experience in video communication, and to solve such problems.

在一个多媒体信息终端(下文简称终端)中,外界场景(人物、背景、文件等)的光信号进入到摄像机/摄像头,经过A/D转换成数字图像信号,然后:In a multimedia information terminal (hereinafter referred to as the terminal), the optical signal of the external scene (person, background, file, etc.) enters the camera/camera, and is converted into a digital image signal by A/D, and then:

在情况A下,直接送到显示设备上显示,最终又变成光信号被人眼感知。当然中间可能经过一些处理,比如为了提升图像效果的图像增强等;In case A, it is directly sent to the display device for display, and finally becomes a light signal to be perceived by human eyes. Of course, there may be some processing in the middle, such as image enhancement to improve the image effect;

在情况B下,数字图像信号经过压缩编码器(Encoder)压缩,然后通过网络(有线、无线、电路交换、分组交换网络都可以)传送出去到达对方终端,在对方终端经过解码器(Decoder)去压缩(decompression)解码还原为数字图像信号,再在显示设备上显示出来,最终又变成光信号被人眼感知。In case B, the digital image signal is compressed by a compression encoder (Encoder), and then transmitted through the network (wired, wireless, circuit switching, packet switching network can be used) to reach the other terminal, and the other terminal passes through the decoder (Decoder). Compression (decompression) is decoded and restored to a digital image signal, which is then displayed on a display device, and finally becomes a light signal to be perceived by the human eye.

如图1所示,图1为环节Gamma特性的模型示意图,不论情况A还是情况B,这个过程中图像亮度信号(Luminance,这里是一种广义的亮度信号,即一开始的光信号到电信号,再到数字化的图像亮度/灰度信号,每个阶段的信号都含有亮度信号的信息,因此广义来说,亮度信号经过了多个环节)经过了多个环节。按照定义,Gamma特性就是指一个环节的亮度信号输入-输出关系不是线性的,而是一种非线性,如图10中的曲线所示。As shown in Figure 1, Figure 1 is a schematic diagram of the model of the Gamma characteristic of the link. No matter in case A or case B, the image luminance signal (Luminance, here is a generalized luminance signal, that is, the initial optical signal to electrical signal , and then to the digitized image brightness/grayscale signal, the signal at each stage contains the information of the brightness signal, so in a broad sense, the brightness signal has gone through multiple links) through multiple links. By definition, the Gamma characteristic means that the input-output relationship of a luminance signal in a link is not linear but nonlinear, as shown in the curve in Figure 10 .

Gamma非线性环节畸变的影响如图2所示,上面的一行灰度方块亮度是线性递增的,从0.1到1.0,下面一行是经过Gamma非线性环节畸变的,亮度是按照幂函数规律递增的。The influence of Gamma nonlinear link distortion is shown in Figure 2. The brightness of the upper row of gray squares increases linearly, from 0.1 to 1.0. The lower row is distorted by the Gamma nonlinear link, and the brightness increases according to the law of the power function.

在实际中,Gamma非线性是由不同原因引起的,对于电视机、PC显示器等CRT(Cathod Ray Tube,阴极射线管)显示设备,Gamma特性在理想状况下满足公式1:In practice, Gamma nonlinearity is caused by different reasons. For CRT (Cathod Ray Tube, cathode ray tube) display devices such as TVs and PC monitors, the Gamma characteristic satisfies Formula 1 under ideal conditions:

                 Lout=Lin 2.2        (1)L out =L in 2.2 (1)

公式1是一个幂函数(Power Function)。需要说明的是,这里的输入和输出亮度信号都是在各自的坐标空间中进行了规一化(Normalized)的,即0≤Lout≤1,0≤Lin≤1。Formula 1 is a power function (Power Function). It should be noted that the input and output luminance signals here are normalized (Normalized) in their respective coordinate spaces, that is, 0≤L out ≤1, 0≤L in ≤1.

而对于手机、PDA等其它类型的显示器比如液晶等,其Gamma函数的形式或者形式上不同、或者参数不同。For other types of displays such as mobile phones and PDAs, such as liquid crystals, etc., the form or form of the Gamma function is different, or the parameters are different.

如图3所示,图3为多个环节级联(cascading或者叫做串联)起来环节Gamma特性的模型示意图,总的Gamma特性等于各个环节Gamma函数的复合(composition),满足公式2:As shown in Figure 3, Figure 3 is a schematic diagram of the model of the Gamma characteristics of multiple links cascaded (cascading or called in series), and the total Gamma characteristics are equal to the composition of the Gamma functions of each link, which satisfies Formula 2:

GCT(.)=G(1)(.)оG(2)(.)оG(3)(.)……G(n-1)(.)оG(n)(.)G CT (.)=G (1) (.)оG (2) (.)оG (3) (.)……G (n-1) (.)оG (n) (.)

lout=GCT(lin)=G(n)(G(n-1)(G(n-2)(……G(2)(G(1)(lin)))))   (2)l out =GCT(l in )=G(n)(G (n-1) (G (n-2) (...G (2) (G (1) (l in ))))) (2)

“о”表示函数的复合运算。CT表示cascaded total,即级联总Gamma的意思。"о" indicates the compound operation of the function. CT stands for cascaded total, which means cascaded total Gamma.

对于情况A:涉及的多个Gamma环节如图4所示,主要有:For case A: the multiple Gamma links involved are shown in Figure 4, mainly including:

1、摄像机/摄像头Gamma,表示成GCam(.);1. Camera/camera Gamma, expressed as G Cam (.);

一般的摄像机都有Gamma特性,除了成像器件比如CCD自身的非线性,摄像机引入了人为的非线性,其目的是让摄像机的Gamma特性刚好补偿掉显示器的Gamma特性,使得总的Gamma特性是线性的。如果显示器理想的Gamma是:Lout=Lin2.2;那么摄像机的理想Gamma是:Lout=Lin 0.45General cameras have Gamma characteristics. In addition to the nonlinearity of imaging devices such as CCD itself, the camera introduces artificial nonlinearity. The purpose is to make the Gamma characteristics of the camera just compensate for the Gamma characteristics of the display, so that the total Gamma characteristics are linear. . If the ideal Gamma of the display is: L out = Lin2.2; then the ideal Gamma of the camera is: L out = Lin 0.45 .

因此理论上,摄像机的Gamma特性是由显示器的Gamma特性决定的。但是因为终端系统日益复杂,摄像机和显示器之间存在多个环节,其数目不定,各自的Gamma特性也未知,这样即使摄像机和显示器的Gamma正好匹配能够相互补偿,但因为中间环节存在,这种补偿一般情况下是无效的。并且显示器类型众多,例如:CRT和液晶、等离子等显示器,其Gamma特性相差很多,而廉价的摄像头的Gamma特性往往严重偏离其理想Gamma。Therefore, in theory, the Gamma characteristics of the camera are determined by the Gamma characteristics of the display. However, due to the increasing complexity of the terminal system, there are multiple links between the camera and the display, the number of which is uncertain, and their respective Gamma characteristics are also unknown, so that even if the Gamma of the camera and the display match exactly, they can compensate each other, but because of the existence of intermediate links, this compensation Generally invalid. And there are many types of displays, such as: CRT and liquid crystal, plasma and other displays, their Gamma characteristics are quite different, and the Gamma characteristics of cheap cameras often seriously deviate from their ideal Gamma.

2、存储文件Gamma,表示成GFil(.);2. Store the file Gamma, expressed as G Fil (.);

文件可能来自摄像机,经过了处理,压缩编码,也经历了多个Gamma环节,因此文件本身已经携带了Gamma特性。The file may come from a camera, has been processed, compressed and encoded, and has also gone through multiple gamma links, so the file itself already carries the gamma characteristic.

3、显示帧存Gamma,表示成GFBuf(.);3. Display frame memory Gamma, expressed as G FBuf (.);

早期的显示器因为显示存储的色彩深度不够,比如只能支持4位、8位、16位色彩深度,而不是理想的24位真彩色,等于压缩了输入亮度信号的动态范围,因此也引入了Gamma特性。另外,因为在非真彩色下模式下,使用的调色板(Palette)色彩映射技术或者抖动(Dither)技术等,都会引入非线性Gamma。Because the color depth of the display storage in the early display is not enough, for example, it can only support 4-bit, 8-bit, and 16-bit color depth, instead of the ideal 24-bit true color, which is equivalent to compressing the dynamic range of the input brightness signal, so Gamma is also introduced. characteristic. In addition, because in the non-true color mode, the used palette (Palette) color mapping technology or dithering (Dither) technology will introduce non-linear Gamma.

4、显示查表Gamma,表示成GLUT(.);4. Display the look-up table Gamma, expressed as G LUT (.);

有些显示设备,为了补偿显示器的非线性,人为引入了Gamma,该Gamma表现为一个LUT(Look-Up Table),从帧存中读出的亮度数据要经过LUT转换,才去驱动显示器。Some display devices, in order to compensate for the non-linearity of the display, artificially introduce Gamma, which is represented as a LUT (Look-Up Table), and the brightness data read from the frame memory must be converted by the LUT to drive the display.

5、显示器Gamma,表示成GDisp(.)。5. Display Gamma, expressed as G Disp (.).

一般的显示器带有很强的Gamma非线性。General monitors have strong Gamma non-linearity.

对于情况B:涉及的多个Gamma环节如图5所示,主要有:For case B: the multiple Gamma links involved are shown in Figure 5, mainly including:

1、摄像机/摄像头Gamma,表示成GCam(.);1. Camera/camera Gamma, expressed as G Cam (.);

2、存储文件Gamma,表示成GFil(.);2. Store the file Gamma, expressed as G Fil (.);

3、显示帧存Gamma,表示成GFBuf(.);3. Display frame memory Gamma, expressed as G FBuf (.);

4、显示查表Gamma,表示成GLUT(.);4. Display the look-up table Gamma, expressed as G LUT (.);

5、显示器Gamma,表示成GDisp(.);5. Display Gamma, expressed as G Disp (.);

6、编码器Gamma,表示成GEnc(.);6. Encoder Gamma, expressed as G Enc (.);

因为压缩中的DCT(Discrete Cosine Transform)变换、量化造成的Gamma。Gamma caused by DCT (Discrete Cosine Transform) transformation and quantization in compression.

7、解码器Gamma,表示成GDec(.)。7. Decoder Gamma, expressed as G Dec (.).

因为解压缩中的DCT反变换、反量化造成的Gamma。Gamma caused by DCT inverse transformation and inverse quantization in decompression.

对于情况B,更为严重的是,本地视频/图像、远端视频/图像和自环视频/图像(用于特殊目的如故障诊断等)经过的Gamma环节是不同的,另外,不论情况A或B,在真实情况涉及到的Gamma环节可能更多,因此情况更加复杂。For case B, what is more serious is that the Gamma links of local video/image, remote video/image and self-loop video/image (used for special purposes such as fault diagnosis, etc.) are different. In addition, no matter case A or B. There may be more Gamma links involved in the real situation, so the situation is more complicated.

理想的情况是输入光信号从进入摄像头到最终在显示屏上显示输出光信号,输入和输出亮度信号之间存在线性关系,即:Lout=Lin,这样人看到的景物才和原来的完全一样,用户体验最好。The ideal situation is that there is a linear relationship between the input light signal and the output light signal from entering the camera to finally displaying the output light signal on the display, that is: L out = L in , so that the scene seen by people is the same as the original Exactly the same, best user experience.

要获得线性关系,必须对于具有非线性Gamma特性环节进行Gamma校正(Gamma Correction)。如图6所示,对于一个环节来说,其Gamma特性给定,那么可以用另外一个校正环节和它进行级联,来使得级联后总的Gamma特性称为真正的线性关系,从而达到了补偿掉给定环节非线性的目的,校正环节的模型为Gamma特性等效模型的逆模型,如果等效模型可以用函数关系式表示,则逆模型的函数关系式为其反函数。显然,Gg(.)和Gc(.)互为反函数。一般情况下,对于一个函数,要获得其反函数不一定有解(或者即使解存在,也无法用计算的方法获得)。To obtain a linear relationship, Gamma Correction (Gamma Correction) must be performed on links with nonlinear Gamma characteristics. As shown in Figure 6, for a link, its Gamma characteristic is given, then another correction link can be used to cascade with it, so that the total Gamma characteristic after cascading is called a true linear relationship, thus achieving For the purpose of compensating the nonlinearity of a given link, the model of the correction link is the inverse model of the equivalent model of Gamma characteristics. If the equivalent model can be expressed by a functional relational expression, then the functional relational expression of the inverse model is its inverse function. Obviously, G g (.) and G c (.) are inverse functions of each other. In general, for a function, there may not necessarily be a solution to obtain its inverse function (or even if the solution exists, it cannot be obtained by calculation).

实际应用中更多的情况如图7所示,校正环节需要插入到前后两个给定环节之间,此时Gc(.)情况更加复杂,Gc(.)和Ga(.)或者Gp(.)不再是简单的反函数关系。In more practical applications, as shown in Figure 7, the correction link needs to be inserted between the two given links before and after. At this time, the situation of G c (.) is more complicated, and G c (.) and G a (.) or G p (.) is no longer a simple inverse functional relationship.

现有技术中校正环节的实现方法主要有以下两种:There are mainly two methods for realizing the correction link in the prior art:

现有技术一:完全依赖摄像机/摄像头或者显示LUT的Gamma特性来校正显示器Gamma特性Existing technology 1: Correct the Gamma characteristics of the display completely relying on the Gamma characteristics of the camera/camera or the display LUT

假设理想状态下:GCam(.)∶Lout=Lin 0.45;GLUT(.)∶Lout=Lin 0.45;GDisp(.)∶Lout=Lin 2.2 Assuming an ideal state: G Cam (.): L out = L in 0.45 ; G LUT (.): L out = L in 0.45 ; G Disp (.): L out = L in 2.2

则:GCamоGDisp(.)成为:Lout=Lin,形成标准的线性关系;GLUTоGDisp(.)成为:Lout=Lin,形成标准的线性关系。Then: G Cam оG Disp (.) becomes: L out =L in , forming a standard linear relationship; G LUT оG Disp (.) becomes: L out =L in , forming a standard linear relationship.

但是,上述技术存在如下不足:But there is following deficiency in above-mentioned technology:

理想状态是很难获得的,不能保证摄像机/摄像头、LUT的Gamma刚好和显示器Gamma完全匹配。并且显示器类型很多,而廉价的摄像头的Gamma肯定是非理想的;如果GCam(.),GLUT(.)同时存在,则补偿过度,GCamоGLUTоGDisp(.)成为:Lout=Lin 0.45,反而偏离了线性;模拟伽玛特性的数学模型不准确,很多研究表明,显示器的Gamma不是简单的幂函数,而更精确的模型可能是幂函数和常数函数的线性组合,或者是一个线性函数和幂函数的复合。The ideal state is difficult to obtain, and there is no guarantee that the Gamma of the camera/camera and LUT will exactly match the Gamma of the monitor. And there are many types of displays, and the Gamma of a cheap camera is definitely not ideal; if G Cam (.) and G LUT (.) exist at the same time, the compensation is over-compensated, and G Cam оG LUT оG Disp (.) becomes: L out = L in 0.45 , it deviates from linearity; the mathematical model for simulating the gamma characteristics is inaccurate. Many studies have shown that the gamma of the display is not a simple power function, and a more accurate model may be a linear combination of a power function and a constant function, or a Composition of linear and power functions.

现有技术二:Prior art two:

在某些环节之间,比如在摄像机环节之后、或者显示帧存环节之前,插入一个Gamma校正环节进行Gamma校正。另外,可能在显示器的Gamma特性模型方面,采用了更加精确的模型,比如公式3:Between some links, such as after the camera link or before the display frame storage link, a Gamma correction link is inserted to perform Gamma correction. In addition, a more accurate model may be used in terms of the Gamma characteristic model of the display, such as formula 3:

LL outout == 11 0.450.45 LL inin ,, ifif 00 &le;&le; LL inin &le;&le; 0.0810.081 11 1.0991.099 (( LL inin ++ 0.0990.099 )) 2.22.2 ,, ifif 0.0810.081 << LL inin &le;&le; 11 -- -- -- (( 33 ))

对应地,摄像机的Gamma被认为和显示器Gamma完全匹配,比如公式4:Correspondingly, the Gamma of the camera is considered to exactly match the Gamma of the display, such as formula 4:

LL outout == 0.450.45 LL inin ,, ifif 00 &le;&le; LL inin &le;&le; 0.0810.081 1.0991.099 LL inin 0.450.45 -- 0.0990.099 ,, ifif 0.0810.081 << LL inin &le;&le; 11 -- -- -- (( 44 ))

现有技术二缺点在于:Prior art two shortcoming is:

校正模型单一,而多个环节的情况非常复杂,多个环节的Gamma特性未能精确获得,必然导致不能精确校正,即校正结果仍然是非线性的,即使模型精确一些也是没有帮助的。因此,仍然不能避免存在过校正或者校正不足的问题;并且该方法只能应用在一些特定情况,无法通用于任意多个Gamma环节的校正。The correction model is single, but the situation of multiple links is very complicated. The Gamma characteristics of multiple links cannot be accurately obtained, which will inevitably lead to inaccurate correction, that is, the correction result is still nonlinear, and even if the model is more accurate, it will not help. Therefore, the problem of over-correction or under-correction cannot be avoided; and this method can only be applied in some specific situations, and cannot be used for the correction of any number of Gamma links.

发明内容Contents of the invention

本发明提供一种确定伽玛等效模型及其参数的检测方法,以解决现有技术中伽玛等效模型选择和模型参数测量不准确,从而无法准确分析并校正信号传输和处理环节中的伽玛特性;The invention provides a detection method for determining the gamma equivalent model and its parameters to solve the inaccurate gamma equivalent model selection and model parameter measurement in the prior art, so that it is impossible to accurately analyze and correct the signal transmission and processing links. Gamma characteristics;

同时,基于上述检测方法,提供一种同时适用于单环节和多环节的伽玛特性的校正方法,以解决现有校正方法无法通用的问题。At the same time, based on the above detection method, a correction method applicable to the gamma characteristics of both single-link and multi-link is provided, so as to solve the problem that the existing correction methods cannot be used universally.

一种伽玛特性校正方法,用于校正所述多媒体信息系统或者特定信号在所述多媒体信息系统传输和处理过程中包括的Nt个具有伽玛特性的环节,所述方法包括如下步骤:A method for correcting gamma characteristics, used to correct N t links with gamma characteristics included in the multimedia information system or a specific signal during transmission and processing of the multimedia information system, the method comprising the following steps:

确定校正点,该校正点将所述Nt个环节划分为位于该校正点之前的Na个环节和位于该校正点之后的Np个环节,其中:Na≥0、Np≥0、Na+Np=Ntdetermining a correction point, which divides the N t links into N a links before the correction point and N p links after the correction point, wherein: N a ≥ 0, N p ≥ 0, N a + N p = N t ;

确定等效所述Na个环节伽玛特性的第一等效模型及其第一逆模型,确定等效所述Np个环节伽玛特性的第二等效模型及其第二逆模型;determining the first equivalent model and its first inverse model equivalent to the gamma characteristics of the N a links, and determining the second equivalent model and its second inverse model equivalent to the gamma characteristics of the N p links;

根据所述第一逆模型和所述第二逆模型构造校正环节模型,利用该校正环节模型确定所述Na个环节最后输出信号的校正信号并将该校正信号输入所述Np个环节。Constructing a correction link model according to the first inverse model and the second inverse model, using the correction link model to determine the correction signal of the final output signal of the N a links and inputting the correction signal into the N p links.

当所述等效模型采用函数表示形式时,所述逆模型的表示函数是对应的反函数。When the equivalent model adopts a functional representation, the representation function of the inverse model is the corresponding inverse function.

所述的确定所述第一等效模型或第二等效模型包括如下步骤:The determining the first equivalent model or the second equivalent model includes the following steps:

A1、分别检测将输入信号的N个采样值Lin(i)输入所述环节产生的实际输出信号的N个值LP out(i),其中:0≤i≤N-1;A1. Detect respectively N values L P out (i) of the actual output signal generated by inputting N sampling values L in (i) of the input signal into the link, wherein: 0≤i≤N-1;

A2、在一组备选的采用函数表示形式的等效模型中选择一个待测模型执行步骤A3;A2. Select a model to be tested from a group of alternative equivalent models using functional representations to perform step A3;

A3、对于所述待测模型,选择一组初始参数;A3. For the model to be tested, select a set of initial parameters;

A4、计算:A4. Calculation:

根据所述待测模型计算所述N个采样值对应的理论输出信号的N个值LM out(i),其中:0≤i≤N-1;以及Calculating N values L M out (i) of theoretical output signals corresponding to the N sampling values according to the model to be tested, wherein: 0≤i≤N-1; and

目标函数值F,所述目标值函数值F与每一对对应的LP out(i)和LM out(i)的差值相关;an objective function value F, which is related to the difference between each pair of corresponding L P out (i) and L M out (i);

A5、判断所述目标函数值F是否等于或小于设定的门限值,如果是则认为所述待测模型被接受为最终的等效模型,并且将该最小的目标函数值F对应的参数作为该等效模型的参数后转入步骤A8;否则执行步骤A6;A5. Judging whether the objective function value F is equal to or less than the set threshold value, if so, it is considered that the model to be tested is accepted as the final equivalent model, and the parameter corresponding to the minimum objective function value F After being used as the parameter of the equivalent model, turn to step A8; otherwise, perform step A6;

A6、判断步骤A4的执行次数是否到达限定的迭代次数,如果是则从其它尚未检测的备选等效模型中再选择一个作为待测模型并返回步骤A3;否则执行步骤A7;A6. Determine whether the number of executions of step A4 reaches the limited number of iterations, if so, select one from other undetected alternative equivalent models as the model to be tested and return to step A3; otherwise, execute step A7;

A7、利用所述数学优化方法调整所述模型参数,返回步骤A4;A7, using the mathematical optimization method to adjust the model parameters, return to step A4;

A8、结束。A8. End.

所述步骤A5中,当所述目标函数值F等于或小于设定的门限值时,再根据设定的循环次数,利用所述数学优化方法调整所述参数并计算所述目标函数值F,然后将其中最小的目标函数值F对应的参数作为所述等效模型的参数。In the step A5, when the objective function value F is equal to or less than the set threshold value, then according to the set number of cycles, use the mathematical optimization method to adjust the parameters and calculate the objective function value F , and then take the parameter corresponding to the minimum objective function value F as the parameter of the equivalent model.

所述的方法还包括如下步骤:Described method also comprises the steps:

分别将测量得到的参数带入对应的逆模型的表示函数中,求取对应第一逆模型的第一反函数式和对应第二逆模型的第二反函数式;respectively bringing the measured parameters into the representation function of the corresponding inverse model, and obtaining a first inverse function corresponding to the first inverse model and a second inverse function corresponding to the second inverse model;

利用该第一反函数式和第二反函数式构造校正模型。A calibration model is constructed using the first inverse function formula and the second inverse function formula.

所述校正环节模型的构造方法包括下列之一:The construction method of the correction link model includes one of the following:

直接计算法:利用第一反函数和第二反函数的复合函数实时计算Na个环节的最后输出信号的校正信号;Direct calculation method: use the composite function of the first inverse function and the second inverse function to calculate the correction signal of the final output signal of N a links in real time;

两步计算法:利用第一反函数实时计算Na个环节的最后输出信号的一次校正信号,利用第二反函数计算该一次校正信号的二次校正信号,将该二次校正信号作为所述校正信号;Two-step calculation method: use the first inverse function to calculate the primary correction signal of the final output signal of N a links in real time, use the second inverse function to calculate the secondary correction signal of the primary correction signal, and use the secondary correction signal as the correction signal;

查表法:预先根据所述直接计算法或两步计算法,计算出所述Na个环节的最后输出信号的取值区间中的多个采样值的对应的校正值,并将对应关系保存在一个数据表中,然后通过实时查询该数据表确定任意待校正值的校正值。Look-up table method: in advance, according to the direct calculation method or two-step calculation method, calculate the corresponding correction values of a plurality of sampling values in the value interval of the final output signal of the N a links, and save the corresponding relationship In a data table, the correction value for any value to be corrected is then determined by querying the data table in real time.

所述的查表法中:当输入的待校正值在数据表中时,则直接通过查表获得对应的校正值;当输入的待校正值不在数据表的输入列中时,采取线性插值平均的方法求取对应的校正值。In the table look-up method: when the input value to be corrected is in the data table, the corresponding correction value is directly obtained by looking up the table; when the input value to be corrected is not in the input column of the data table, linear interpolation average The method to obtain the corresponding correction value.

所述目标函数值F满足如下条件:The objective function value F satisfies the following conditions:

Ff == &Sigma;&Sigma; ii == 00 NN -- 11 (( LL outout PP (( ii )) -- LL outout Mm (( ii )) )) 22

所述一组备选等效模型的函数关系及其对应的反函数包括:The functional relationship of said group of alternative equivalent models and their corresponding inverse functions include:

所述伽玛特性等效模型函数关系式为:Lout=pLin α+(1-p),其中:该函数的定义域为区间[0,1],值域为区间[(1-p),1];则该函数的反函数关系式为:The gamma characteristic equivalent model function relational formula is: L out =pL in α +(1-p), wherein: the definition domain of this function is the interval [0,1], and the value range is the interval [(1-p ), 1]; then the inverse function relation of this function is:

L out = ( 1 p L in + ( 1 - 1 p ) ) 1 &alpha; ; 或者, L out = ( 1 p L in + ( 1 - 1 p ) ) 1 &alpha; ; or,

所述伽玛特性等效模型函数关系式为: L out = ( qL in + ( 1 - q ) ) 1 &beta; , 其中:该函数的定义域为区间[1-1/q,1],值域为区间[0,1];则该函数的反函数关系式为:The equivalent model function relational expression of described gamma characteristic is: L out = ( QUR in + ( 1 - q ) ) 1 &beta; , Among them: the definition domain of the function is the interval [1-1/q, 1], and the value range is the interval [0, 1]; then the inverse function relation of the function is:

LL outout == 11 qq LL inin &beta;&beta; ++ (( 11 -- 11 qq )) ;;

其中:Lin为输入信号值、Lout为输出信号值、p和α以及q和β分别为需要测量的参数;并且当Na=1或Np=1时:0<p≤1、α≥1,q≥1、β≥1;当Na>1或Np>1时:0<p≤1、α≥0,q≥1、β≥0。Among them: L in is the input signal value, L out is the output signal value, p and α, q and β are the parameters to be measured respectively; and when N a =1 or N p =1: 0<p≤1, α ≥1, q≥1, β≥1; when N a >1 or N p >1: 0<p≤1, α≥0, q≥1, β≥0.

所述的数学优化方法包括但不限于下列方法之一:爬山法;0.618法;最速下降法;共轭梯度法。The mathematical optimization method includes but is not limited to one of the following methods: hill climbing method; 0.618 method; steepest descent method; conjugate gradient method.

所述的输入信号的N个采样值在区间[0,1]中选择。The N sampling values of the input signal are selected in the interval [0, 1].

当所述等效模型为数据表形式时,对应的所述逆模型就是该数据表的逆表。When the equivalent model is in the form of a data table, the corresponding inverse model is the inverse table of the data table.

一种确定伽玛特性等效模型及其参数的检测方法,所述伽玛特性等效模型用于等效信号传输或处理环节中的伽玛特性,包括如下步骤:A detection method for determining a gamma characteristic equivalent model and parameters thereof, the gamma characteristic equivalent model being used for equivalent signal transmission or gamma characteristics in a processing link, comprising the following steps:

B1、分别检测将输入信号的N个采样值Lin(i)输入所述环节产生的实际输出信号的N个值LP out(i),其中:0≤i≤N-1;B1. Respectively detect N values L P out (i) of the actual output signal generated by inputting N sampling values L in (i) of the input signal into the link, wherein: 0≤i≤N-1;

B2、在一组备选的采用函数表示形式的等效模型中选择一个待测模型执行步骤B3;B2. Select a model to be tested from a group of alternative equivalent models in the form of a function to perform step B3;

B3、对于所述待测模型,选择一组初始参数;B3. For the model to be tested, select a set of initial parameters;

B4、计算:B4. Calculation:

根据所述待测模型计算所述信号N个采样值对应的理论输出信号的N个值:LM out(i),其中:0≤i≤N-1;以及Calculate N values of the theoretical output signal corresponding to the N sampling values of the signal according to the model to be tested: L M out (i), where: 0≤i≤N-1; and

目标函数值F,所述目标值函数值F与每一对对应的LP out(i)和LM out(i)的差值相关;an objective function value F, which is related to the difference between each pair of corresponding L P out (i) and L M out (i);

B5、判断所述目标函数值F是否等于或小于设定的门限值,如果是则认为所述待测模型被接受为最终的等效模型,并且将该组参数作为该等效模型的参数后转入步骤B8;否则执行步骤B6;B5. Judging whether the objective function value F is equal to or less than the set threshold value, if so, it is considered that the model to be tested is accepted as the final equivalent model, and this group of parameters is used as the parameter of the equivalent model Then go to step B8; otherwise, go to step B6;

B6、判断步骤B4的执行次数是否到达限定的迭代次数,如果是则从其它尚未检测的备选等效模型中再选择一个作为待测模型并返回步骤B3;否则执行步骤B7;B6. Determine whether the number of executions of step B4 reaches the limited number of iterations, if so, select one from other undetected alternative equivalent models as the model to be tested and return to step B3; otherwise, execute step B7;

B7、利用所述数学优化方法调整所述参数,返回步骤B4;B7. Using the mathematical optimization method to adjust the parameters, return to step B4;

B8、结束。B8. End.

所述步骤B5中,当所述目标函数值F等于或小于设定的门限值时,再根据设定的循环次数,利用所述数学优化方法调整所述参数并计算所述目标函数值F,然后将其中最小的目标函数值F对应的参数作为所述等效模型的参数。In the step B5, when the objective function value F is equal to or less than the set threshold value, then according to the set number of cycles, use the mathematical optimization method to adjust the parameters and calculate the objective function value F , and then take the parameter corresponding to the minimum objective function value F as the parameter of the equivalent model.

本发明的有益效果如下:The beneficial effects of the present invention are as follows:

本发明解决了多媒体信息系统中普遍存在的Gamma特性模型的选择问题及其参数的检测问题和环节Gamma特性校正的问题,对于任意多环节级联的综合Gamma特性给出一种通用的校正方法。从而可以大大提高多媒体信息系统的用户体验。The invention solves the selection problem of the Gamma characteristic model and the detection problem of the parameters and the correction problem of the Gamma characteristic of the link which are common in the multimedia information system, and provides a general correction method for the comprehensive Gamma characteristic of any multi-link cascade. Therefore, the user experience of the multimedia information system can be greatly improved.

附图说明Description of drawings

图1为环节Gamma特性的一般模型;Figure 1 is a general model of the link Gamma characteristic;

图2为环节Gamma特性引起的亮度信号畸变的示意图;Fig. 2 is a schematic diagram of brightness signal distortion caused by link Gamma characteristics;

图3为多环节级联Gamma特性的一般模型;Figure 3 is a general model of multi-link cascaded Gamma characteristics;

图4为情况A下的多个Gamma环节示意图;FIG. 4 is a schematic diagram of multiple Gamma links in case A;

图5为情况B下的多个Gamma环节示意图;Fig. 5 is a schematic diagram of multiple Gamma links in case B;

图6为校正单个环节的Gamma特性示意图;Fig. 6 is a schematic diagram of the Gamma characteristic of a single link of correction;

图7为校正多个给定环节的Gamma特性示意图;Fig. 7 is a schematic diagram of the Gamma characteristic of correcting multiple given links;

图8为应用本发明所述校正方法时,确定校正点的示意图;Fig. 8 is a schematic diagram of determining correction points when applying the correction method of the present invention;

图9为应用本发明所述分别利用两个子环节进行前后校正的示意图;Fig. 9 is a schematic diagram of using two sub-links to perform front and rear correction according to the present invention;

图10为Gamma特性函数曲线示意图;Fig. 10 is a schematic diagram of the Gamma characteristic function curve;

图11a和图11b分别为Gamma特性模型函数曲线示意图;Fig. 11a and Fig. 11b are the schematic diagrams of the Gamma characteristic model function curve respectively;

图12为Gamma特性模型函数曲线局限区域示意图。Fig. 12 is a schematic diagram of the limited area of the function curve of the Gamma characteristic model.

具体实施方式Detailed ways

研究表明,更精确的伽玛特性等效模型的函数关系是幂函数和常数函数的线性组合,或者是一个线性函数和幂函数的复合,在不同的环境中,通过实际测量函数关系中的参数可以较为精确的得到具体的函数关系。Studies have shown that the functional relationship of a more accurate gamma-characteristic equivalent model is a linear combination of a power function and a constant function, or a compound of a linear function and a power function, in different environments, by actually measuring the parameters in the functional relationship The specific functional relationship can be obtained more accurately.

实施例一:伽玛特性等效模型参数的测量方法Embodiment 1: Measurement method of gamma characteristic equivalent model parameters

发明选择采用如下单环节等效模型作为Gamma特性的通用模型为例进行The invention selection takes the following single-link equivalent model as a general model of Gamma characteristics as an example

详细说明:Detailed description:

第一类Gamma模型:Lout=pLin α+(1-p) 0<p≤1,α≥1     (5)The first type of Gamma model: L out = pL in α + (1-p) 0<p≤1, α≥1 (5)

其中:公式5所示函数的定义域(即自变量取值范围)为区间[0,1],值域(函数值的取值范围)为区间[(1-p),1],曲线特性如图11a所示,显然对于第一类模型,如果p=1,α=1,则有Lout=Lin。因此在实际测量时,如果该第一类模型的参数p=1,α=1时,或者p充分接近1并且α充分接近1时,可以认为环节的伽玛特性可以被忽略,不用进行校正。该第一类Gamma特性的典型例子是CRT显示器。Among them: the domain of definition of the function shown in formula 5 (that is, the value range of the independent variable) is the interval [0, 1], the value range (the value range of the function value) is the interval [(1-p), 1], and the curve characteristics As shown in Fig. 11a, obviously for the first type of model, if p=1, α=1, then L out =L in . Therefore, in actual measurement, if the parameters of the first type of model are p=1, α=1, or p is sufficiently close to 1 and α is sufficiently close to 1, it can be considered that the gamma characteristic of the link can be ignored without correction. A typical example of this first type of gamma characteristic is a CRT monitor.

第二类Gamma模型: L out = ( qL in + ( 1 - q ) ) 1 &beta; - - - q &GreaterEqual; 1 , &beta; &GreaterEqual; 1 - - - ( 6 ) The second type of Gamma model: L out = ( QUR in + ( 1 - q ) ) 1 &beta; - - - q &Greater Equal; 1 , &beta; &Greater Equal; 1 - - - ( 6 )

其中:公式6所示函数的定义域(即自变量取值范围)为区间[1-1/q,1],值域(函数值的取值范围)为区间[(0,1],曲线特性如图11b所示,显然对于第二类模型,如果q=1,β=1,则有Lout=Lin。同样,在实际测量时,如果q=1,β=1时,或者q充分接近1并且β充分接近1时,可以认为环节的伽玛特性可以被忽略,不用进行校正,而该第二类特性的典型例子是摄像机。Wherein: the domain of definition of the function shown in formula 6 (that is, the value range of the independent variable) is the interval [1-1/q, 1], and the value domain (the value range of the function value) is the interval [(0, 1], the curve The characteristics are shown in Figure 11b. Obviously, for the second type of model, if q=1, β=1, then there is L out =L in . Similarly, in actual measurement, if q=1, β=1, or q When β is sufficiently close to 1 and β is sufficiently close to 1, it can be considered that the gamma characteristic of the link can be ignored without correction, and a typical example of this second type of characteristic is a camera.

此外,如果q=1/p,α=β,那么第一类和第二类模型互为反函数,因此可以相互补偿得到线性特性。即:如果给定环节对像具有第一类Gamma特性,那么其校正Gamma特性具有第二类模型;如果给定环节对像具有第二类Gamma特性,那么其校正Gamma特性具有第一类模型。In addition, if q=1/p, α=β, then the first type and the second type of models are inverse functions of each other, so they can compensate each other to obtain linear characteristics. That is: if a given link object has the first-type Gamma characteristics, then its corrected Gamma characteristics have the second-type model; if a given link object has the second-type Gamma characteristics, then its corrected Gamma characteristics have the first-type model.

多个Gamma环节进行级联后,其综合的Gamma特性,从数学一般性来说,不再具有单环节的第一类或者第二类模型。但是我们在研究中发现,多环节综合Gamma特性的数学模型具有如下特点:After multiple Gamma links are cascaded, their comprehensive Gamma characteristics, in terms of mathematical generality, no longer have the first or second type of single-link models. However, we found in the research that the mathematical model of multi-link integrated Gamma characteristics has the following characteristics:

1、其函数图像局限于坐标平面的区域[0,1]×[0,1](这里”×”表示两个集合的笛卡尔积Cartesian Product,或者叫做直积)内,如图12所示;1. Its function image is limited to the area [0, 1]×[0, 1] of the coordinate plane (where “×” represents the Cartesian Product of two sets, or called the direct product), as shown in Figure 12 ;

2、单调递增;2. Monotonically increasing;

3、上凸和下凸;3. Convex up and down;

两种情况,从几何意思上说,上凸为曲线向左上弯曲,下凸为曲线向右下弯曲。In the two cases, geometrically speaking, convex means that the curve bends upward to the left, and convex means that the curve bends downward to the right.

4、和Lin轴相交,或者和Lout轴相交(两种情况);4. Intersect with the Lin axis, or intersect with the Lout axis (two cases);

5、曲线通过(1,1)点;5. The curve passes through the (1,1) point;

因此,3、4的情况独立组合就形成四种复合情况:Therefore, the independent combination of situations 3 and 4 forms four compound situations:

情况1、和Lin轴相交,上凸;Case 1, intersects with the Lin axis and is convex;

情况2、和Lin轴相交,下凸;Case 2, intersects with the Lin axis and is convex downward;

情况3、和Lout轴相交,上凸;Case 3, intersects with the L out axis and is convex;

情况4、和Lout轴相交,下凸。Case 4, intersects with the L out axis and is convex downward.

根据以上定性分析,多个Gamma环节级联的综合Gamma特性模型可以有以下两类,函数关系式分别为公式7和公式8:According to the above qualitative analysis, the comprehensive Gamma characteristic model of cascading multiple Gamma links can have the following two types, and the functional relations are formula 7 and formula 8 respectively:

第一类:Lout=pLin α+(1-p) 0<p≤1,α>0  对应情况3和4   (7)The first category: L out =pL in α +(1-p) 0<p≤1, α>0 corresponds to cases 3 and 4 (7)

第二类: L out = ( qL in + ( 1 - q ) ) 1 &beta; q≥1,β>0  对应情况1和2     (8)The second category: L out = ( QUR in + ( 1 - q ) ) 1 &beta; q≥1, β>0 corresponds to cases 1 and 2 (8)

需要指出,从形式上看,多环节(其中可以有第一类环节,也可以有第二类环节,两类环节可以按照任意数量和顺序级联,本发明的方法都适用)综合Gamma特性的第一类,第二类分别和单环节Gamma特性第一类,第二类是一样的。但是,第一类综合特性模型中,根据定性分析结果和实际测量的经验值,指数α取值范围变成α>0,而第二类综合特性模型中,指数β取值范围变成β>0。It should be pointed out that from a formal point of view, multi-links (wherein there can be first-type links and second-type links, and the two types of links can be cascaded according to any number and order, and the method of the present invention is applicable) the comprehensive Gamma characteristic The first type and the second type are the same as the first type and the second type of the single-link Gamma characteristic respectively. However, in the first type of comprehensive characteristic model, according to the qualitative analysis results and actual measured experience values, the value range of index α becomes α>0, while in the second type of comprehensive characteristic model, the value range of index β becomes β> 0.

选定了Gamma特性模型后,需要在具体应用环境中测量其中的Gamma特性参数,测量方法直接关系最后的Gamma特性模型中输入输出信号满足的函数关系是否准确。其中:对于第一类模型,需要确定参数p和α;对于第二类模型,需要确定参数q和β。After the Gamma characteristic model is selected, it is necessary to measure the Gamma characteristic parameters in the specific application environment. The measurement method is directly related to whether the functional relationship satisfied by the input and output signals in the final Gamma characteristic model is accurate. Among them: for the first type of model, parameters p and α need to be determined; for the second type of model, parameters q and β need to be determined.

单环节Gamma特性模型参数的测量具体步骤如下:The specific steps of measuring the parameters of the single-link Gamma characteristic model are as follows:

1、在输入亮度信号Lin在[0,1]区间上选择间隔均匀的N个采样点:Lin(0)、Lin(1)、Lin(2)……Lin(i)……Lin(N-2)、Lin(N-1);1. Select evenly spaced N sampling points on the interval [0, 1] of the input brightness signal L in : Lin in (0), Lin in (1), Lin in (2)...L in (i)... …L in (N-2), Lin in (N-1);

2、将亮度信号N个采样值分别输入环节中,并测量实际输出亮度信号N个对应的值:LP out(0)、LP out(1)、LP out(2)……LP out(i)……LP out(N-2)、LP out(N-1);2. Input the N sampling values of the luminance signal into the link respectively, and measure the corresponding values of the N actual output luminance signals: L P out (0), L P out (1), L P out (2)...L P out (i)...L P out (N-2), L P out (N-1);

3、构造拟合的目标函数为,目标函数和实际检测的输出亮度信号与通过Gamma特性模型确定的理论输出亮度信号之间的差值相关,而且,差值越小,说明模型的等效效果越接近实际情况。3. The objective function of the construction fitting is that the objective function is related to the difference between the actual detected output brightness signal and the theoretical output brightness signal determined by the Gamma characteristic model, and the smaller the difference, the equivalent effect of the model is shown closer to the actual situation.

目标函数的构造方法很多,较为常用的是下述公式9或公式10:There are many ways to construct the objective function, and the more commonly used ones are the following formula 9 or formula 10:

F T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - pL in ( i ) &alpha; - ( 1 - p ) ) 2 - - - ( 9 ) 或者, f T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - PL in ( i ) &alpha; - ( 1 - p ) ) 2 - - - ( 9 ) or,

Ff TT 22 (( qq ,, &beta;&beta; )) == &Sigma;&Sigma; ii == 00 NN -- 11 (( LL outout PP (( ii )) -- (( qLQUR inin (( ii )) ++ (( 11 -- qq )) )) 11 &beta;&beta; )) 22 -- -- -- (( 1010 ))

4、设定目标函数值的门限T和最大迭代次数M,利用数学优化法寻找最适合的参数组;4. Set the threshold T of the objective function value and the maximum number of iterations M, and use the mathematical optimization method to find the most suitable parameter group;

首先对于第一类的代价函数 F T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - pL in ( i ) &alpha; - ( 1 - p ) ) 2 , 采用某种数学优化技术,例如:爬山法、0.618法(华罗庚优选法)、最速下降法或共轭梯度法等求取其最小值;First, for the cost function of the first category f T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - PL in ( i ) &alpha; - ( 1 - p ) ) 2 , Use some mathematical optimization technique, such as: hill climbing method, 0.618 method (Hua Luogeng optimization method), steepest descent method or conjugate gradient method to find its minimum value;

这个过程其实是一个迭代过程,在这个过程中不断调整参数p和α,函数值F在不断下降,当函数值下降到小于给定门限T后,则认为已经找到了最小点。此时对应的参数p和α,就认为是本次应用环境模型的真正参数,应当注意的是,参数p和α的取值范围分别是:0<p≤1、α≥1;This process is actually an iterative process. In this process, the parameters p and α are constantly adjusted, and the function value F is continuously decreasing. When the function value decreases to less than the given threshold T, it is considered that the minimum point has been found. At this time, the corresponding parameters p and α are considered to be the real parameters of the application environment model. It should be noted that the value ranges of the parameters p and α are: 0<p≤1, α≥1;

如果对于 F T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - pL in ( i ) &alpha; - ( 1 - p ) ) 2 经过M次迭代,还不能使得函数下降到门限T以下,则认为模型选择不对。应该选择第二类模型,于是对于 F T 2 ( q , &beta; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - ( qL in ( i ) + ( 1 - q ) ) 1 &beta; ) 2 重复上述步骤4,得到对应的模型参数q和β,应当注意的是,参数p和α的取值范围分别是:q≥1、β≥1。if for f T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - PL in ( i ) &alpha; - ( 1 - p ) ) 2 After M iterations, if the function cannot drop below the threshold T, it is considered that the model selection is wrong. The second type of model should be chosen, so for f T 2 ( q , &beta; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - ( QUR in ( i ) + ( 1 - q ) ) 1 &beta; ) 2 Repeat the above step 4 to obtain the corresponding model parameters q and β. It should be noted that the value ranges of the parameters p and α are respectively: q≥1 and β≥1.

如果想要得到更精确的参数,可以在目标函数值F下降到门限T以下后,仍然再迭代几次,如果目标函数值F持续下降,或下降后又上升,或直接上升,不管目标函数值F是何种变化情况,则选择其中的最小值对应的参数作为测量结果会在一定程度上提高参数测量的精度。If you want to get more accurate parameters, you can iterate a few more times after the objective function value F drops below the threshold T. If the objective function value F continues to decline, or rises after falling, or directly rises, regardless of the objective function value F is what kind of change, then choosing the parameter corresponding to the minimum value as the measurement result will improve the accuracy of parameter measurement to a certain extent.

可以看到,模型类型的确定和参数的测量是同时进行的,实际中,等效模型的类型不只这两种形式,通过上述方法可以在相关的所有等效模型通过测量参数的方法找到最合适的一个。It can be seen that the determination of the model type and the measurement of parameters are carried out at the same time. In practice, the types of equivalent models are not limited to these two forms. Through the above method, the most suitable method can be found in all relevant equivalent models by measuring parameters. one of.

同样可以利用上述方法测量多环节综合Gamma特性模型参数,具体步骤如下:The above method can also be used to measure the parameters of the multi-link comprehensive Gamma characteristic model. The specific steps are as follows:

1、在输入亮度信号Lin在[0,1]区间上选择间隔均匀的N个采样点:Lin(0)、Lin(1)、Lin(2)……Lin(i)……Lin(N-2)、Lin(N-1);1. Select evenly spaced N sampling points on the interval [0, 1] of the input brightness signal L in : Lin in (0), Lin in (1), Lin in (2)...L in (i)... …L in (N-2), Lin in (N-1);

2、将亮度信号N个采样值分别输入环节中,并测量实际输出亮度信号N个对应的值:LP out(0)、LP out(1)、LP out(2)……LP out(i)……LP out(N-2)、LP out(N-1);2. Input the N sampling values of the luminance signal into the link respectively, and measure the corresponding values of the N actual output luminance signals: L P out (0), L P out (1), L P out (2)...L P out (i)...L P out (N-2), L P out (N-1);

3、构造拟合的目标函数为,目标函数和实际检测的输出亮度信号与通过Gamma特性模型确定的理论输出亮度信号之间的差值相关,而且,差值越小,说明模型的等效效果越接近实际情况。3. The objective function of the construction fitting is that the objective function is related to the difference between the actual detected output brightness signal and the theoretical output brightness signal determined by the Gamma characteristic model, and the smaller the difference, the equivalent effect of the model is shown closer to the actual situation.

目标函数的构造方法很多,较为常用的仍然是公式9或公式10:There are many ways to construct the objective function, and the more commonly used ones are still Formula 9 or Formula 10:

F T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - pL in ( i ) &alpha; - ( 1 - p ) ) 2 - - - ( 9 ) 或者, f T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - PL in ( i ) &alpha; - ( 1 - p ) ) 2 - - - ( 9 ) or,

Ff TT 22 (( qq ,, &beta;&beta; )) == &Sigma;&Sigma; ii == 00 NN -- 11 (( LL outout PP (( ii )) -- (( qLQUR inin (( ii )) ++ (( 11 -- qq )) )) 11 &beta;&beta; )) 22 -- -- -- (( 1010 ))

4、设定目标函数值的门限T和最大迭代次数M,利用数学优化法寻找最适合的参数组;4. Set the threshold T of the objective function value and the maximum number of iterations M, and use the mathematical optimization method to find the most suitable parameter group;

首先对于第一类的代价函数 F T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - pL in ( i ) &alpha; - ( 1 - p ) ) 2 , 采用某种数学优化技术,例如:爬山法、0.618法(华罗庚优选法)、最速下降法或共轭梯度法等求取其最小值;First, for the cost function of the first category f T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - PL in ( i ) &alpha; - ( 1 - p ) ) 2 , Use some mathematical optimization technique, such as: hill climbing method, 0.618 method (Hua Luogeng optimization method), steepest descent method or conjugate gradient method to find its minimum value;

这个过程其实是一个迭代过程,在这个过程中不断调整参数p和α,函数值F在不断下降,当函数值下降到小于给定门限T后,则认为已经找到了最小点。此时对应的参数p和α,就认为是本次应用环境模型的真正参数,应当注意的是,和单环节测量不同之处在于,参数p和α的取值范围分别是:0<p≤1、α≥0;This process is actually an iterative process. In this process, the parameters p and α are constantly adjusted, and the function value F is continuously decreasing. When the function value decreases to less than the given threshold T, it is considered that the minimum point has been found. At this time, the corresponding parameters p and α are considered to be the real parameters of the application environment model. It should be noted that the difference from the single-link measurement is that the value ranges of the parameters p and α are: 0<p≤ 1. α≥0;

同样,如果对于 F T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - pL in ( i ) &alpha; - ( 1 - p ) ) 2 经过M次迭代,还不能使得函数下降到门限T以下,则认为模型选择不对。应该选择第二类模型,于是对于 F T 2 ( q , &beta; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - ( qL in ( i ) + ( 1 - q ) ) 1 &beta; ) 2 重复上述步骤4,得到对应的模型参数q和β,应当注意的是,和单环节测量不同之处在于,参数p和α的取值范围分别是:q≥1、β≥0。Likewise, if for f T 1 ( p , &alpha; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - PL in ( i ) &alpha; - ( 1 - p ) ) 2 After M iterations, if the function cannot drop below the threshold T, it is considered that the model selection is wrong. The second type of model should be chosen, so for f T 2 ( q , &beta; ) = &Sigma; i = 0 N - 1 ( L out P ( i ) - ( QUR in ( i ) + ( 1 - q ) ) 1 &beta; ) 2 Repeat the above step 4 to obtain the corresponding model parameters q and β. It should be noted that the difference from single-stage measurement is that the value ranges of parameters p and α are: q≥1 and β≥0, respectively.

与单环节参数测量方法相同,如果想要得到更精确的参数,可以在目标函数值F下降到门限T以下后,仍然再迭代几次,如果目标函数值F持续下降,或下降后又上升,或直接上升,不管目标函数值F是何种变化情况,则选择其中的最小值对应的参数作为测量结果会在一定程度上提高参数测量的精度。In the same way as the single-stage parameter measurement method, if you want to get more accurate parameters, you can iterate several times after the objective function value F drops below the threshold T. If the objective function value F continues to drop, or rises after falling, Or directly increase, regardless of the change of the objective function value F, selecting the parameter corresponding to the minimum value as the measurement result will improve the accuracy of parameter measurement to a certain extent.

与单环节参数测量方法相同,模型类型的确定和参数的测量是同时进行的,实际中,等效模型的类型不只这两种形式,通过上述方法可以在相关的所有等效模型通过测量参数的方法找到最合适的一个。The same as the single-link parameter measurement method, the determination of the model type and the measurement of the parameters are carried out at the same time. In practice, the types of equivalent models are not limited to these two forms. Through the above method, all relevant equivalent models can be measured by measuring parameters. method to find the most suitable one.

实施例二、多环节Gamma特性的校正方法:Embodiment 2, the correction method of multi-link Gamma characteristic:

基于实施例一的伽玛特性等效模型参数的测量方法,可以得到伽玛特性等效模型的函数关系,利用该函数的反函数构造出校正模型,就可以对单环节或多环节伽玛特性进行校正,下面以多媒体信息系统中的具体应用为例进行详细说明。Based on the measurement method of the gamma characteristic equivalent model parameters of the first embodiment, the functional relationship of the gamma characteristic equivalent model can be obtained, and the correction model can be constructed by using the inverse function of the function, and the single-link or multi-link gamma characteristic Correction is performed, and a detailed description will be given below taking a specific application in a multimedia information system as an example.

如图9所示,一般情况多媒体信息系统是多个Gamma环节级联起来,对于不同情况,比如情况A和情况B,图中参加级联的环节千变万化。一般来说,环节1是摄像机/摄像头,而环节Nt(最后一个)是显示器。理论上,在任何两个环节之间可以插入一个校正环节(电路实现或者软件实现)(包括在最前面或最后面插入校正环节),但是实际情况可能并非如此。比如在前面说到的显示帧存Gamma环节和显示LUT Gamma环节之间无法插入校正环节。因此,一般情况是可能存在P个校正环节插入点,也叫做校正点。本发明方法只要从以上P个校正点中选择一个,在该点插入校正环节,即可实现全部的Gamma校正。As shown in Figure 9, in general, a multimedia information system is cascaded with multiple Gamma links. For different situations, such as situation A and situation B, the links participating in the cascade in the figure are ever-changing. Generally, Link 1 is the camera/camera, and Link N t (the last one) is the display. In theory, a correction link (circuit implementation or software implementation) can be inserted between any two links (including inserting a correction link at the front or at the end), but this may not be the case in practice. For example, a correction link cannot be inserted between the display frame memory Gamma link and the display LUT Gamma link mentioned earlier. Therefore, in general, there may be P correction link insertion points, also called correction points. The method of the present invention only needs to select one of the above P correction points and insert a correction link at this point to realize all Gamma corrections.

对于情况A:本发明的一个实施例是在摄像机和显示帧存之间加入校正环节。For case A: One embodiment of the present invention is to add a calibration link between the camera and the display frame memory.

对于情况B:本发明的一个实施例是:For Case B: An embodiment of the invention is:

1、对于本端视频/图像,在摄像机和显示帧存之间加入校正环节;1. For the local video/image, a correction link is added between the camera and the display frame memory;

2、对于远端视频/图像,在解码器和显示帧存之间加入校正环节;2. For remote video/image, a correction link is added between the decoder and the display frame memory;

3、对于自环视频/图像,在摄像机和编码器之间加入校正环节,或者在解码器和显示帧存之间加入校正环节。3. For the self-loop video/image, add a correction link between the camera and the encoder, or add a correction link between the decoder and the display frame memory.

从这个校正点开始,前面的环节个数为Na个(环节1到环节Na),后面的环节个数为Np个(环节Na+1到Nt,有关系Na+Np=Nt成立),有下列两种特例:Starting from this correction point, the number of links in the front is N a (link 1 to link Na ), and the number of links in the back is N p (links Na +1 to N t , there is a relationship between Na +N p = N t established), there are two special cases as follows:

1)、当Na或Np等于零时,对应一个在最前面或最后面插入校正环节的特例,这时实际上将系统看作一个具有多环节综合Gamma特性进行校正;1) When N a or N p is equal to zero, it corresponds to a special case where a correction link is inserted at the front or at the end. At this time, the system is actually regarded as a multi-link integrated Gamma characteristic for correction;

2)、当Na或Np等于1时,对摄像机/摄像头或者显示器进行单独校正。2) When N a or N p is equal to 1, the camera/camera head or display is calibrated separately.

令环节1到环节Na的Na个环节的级联综合Gamma特性是Ga(.),环节Na+1到环节Nt的Np个环节的级联综合Gamma特性是Gp(.)。采用该种方法,可以方便地获得校正环节的模型。并且需要说明,该方法不限于各个单一环节的模型,或者综合模型采用本发明的第一类和第二类模型。对于其它模型,如果能够从数学上求出Ga(.)和Gp(.)其反函数的解析形式(closed form),那么都适用本发明的子环节分解方法。并且,本发明还适用于其它一些形式的模型,比如采用数据表形式的模型,对于Ga(.)、Gp(.)本身没有解析形式(比如采用查表方法实现的,当然其反函数也就没有解析形式了)的情况。对于模型本身就是用数据表的形式存在的,那么其逆模型就是该数据表的逆表,一个表存在两列,很多行,左列(输入列)是输入信号的采样值,即待校正的信号值,右列(输出列)是对应的输出信号值,即校正后的信号值,行数取决于采样点数,行数越多越精确,逆表就是把左右两列对调得到的新数据表,本发明的一个实施例就是用查表实现的。Let the cascaded integrated Gamma characteristic of Na links from link 1 to link Na be G a (.), and the cascaded integrated Gamma characteristic of N p links from link Na + 1 to link N t be G p (.). Using this method, the model of the calibration link can be obtained conveniently. And it should be noted that the method is not limited to the models of each single link, or the comprehensive model adopts the first and second types of models of the present invention. For other models, if the analytical form (closed form) of the inverse function of G a (.) and G p (.) can be obtained mathematically, then the sub-link decomposition method of the present invention is applicable. And, the present invention is also applicable to the model of some other forms, such as adopting the model of data table form, for G a (.), G p (.) itself does not have analytical form (such as adopting the look-up table method to realize, of course its inverse function There is no analytical form). For the model itself exists in the form of a data table, then its inverse model is the inverse table of the data table. A table has two columns and many rows. The left column (input column) is the sampling value of the input signal, that is, the value to be corrected Signal value, the right column (output column) is the corresponding output signal value, that is, the corrected signal value, the number of rows depends on the number of sampling points, the more rows, the more accurate, the reverse table is the new data table obtained by swapping the left and right columns , an embodiment of the present invention is realized with look-up table exactly.

具体校正方法包括如下步骤:The specific correction method includes the following steps:

1、建立校正子环节Gac(.):1. Establish the correction sub-link G ac (.):

如果Ga(.)属于综合第一类等效模型:If G a (.) belongs to the comprehensive first-class equivalent model:

LL outout == pp oo LL inin &alpha;&alpha; nno ++ (( 11 -- pp aa )) -- -- -- 00 << pp aa &le;&le; 11 ,, &alpha;&alpha; aa >> 00 -- -- -- (( 1313 ))

那么Gac(.)模型是:Then the G ac (.) model is:

LL outout == (( 11 pp aa LL inin ++ (( 11 -- 11 pp aa )) )) 11 &alpha;&alpha; aa -- -- -- pp aa &GreaterEqual;&Greater Equal; 11 ,, &alpha;&alpha; aa >> 00 -- -- -- (( 1414 ))

如果Ga(.)属于综合第二类等效模型:If G a (.) belongs to the second type of comprehensive equivalent model:

LL outout == (( qq aa LL inin ++ (( 11 -- qq aa )) )) 11 &beta;&beta; aa -- -- -- qq aa &GreaterEqual;&Greater Equal; 11 ,, &beta;&beta; aa >> 00 -- -- -- (( 1515 ))

那么Gac(.)模型是:Then the G ac (.) model is:

LL outout == 11 qq aa LL inin &beta;&beta; nno ++ (( 11 -- 11 qq aa )) -- -- -- qq aa &GreaterEqual;&Greater Equal; 11 ,, &beta;&beta; aa >> 00 -- -- -- (( 1616 ))

2、建立校正子环节Gpc(.);2. Establish the correction sub-link G pc (.);

如果Gp(.)属于综合第一类等效模型:If G p (.) belongs to the comprehensive first-class equivalent model:

LL outout == pp pp LL inin &alpha;&alpha; pp ++ (( 11 -- pp pp )) -- -- -- 00 << pp pp &le;&le; 11 ,, &alpha;&alpha; pp >> 00 -- -- -- (( 1717 ))

那么Gpc(.)模型是:Then the G pc (.) model is:

LL outout == (( 11 pp pp LL inin ++ (( 11 -- 11 pp pp )) )) 11 &alpha;&alpha; pp -- -- -- pp pp &GreaterEqual;&Greater Equal; 11 ,, &alpha;&alpha; pp >> 00 -- -- -- (( 1818 ))

如果Gp(.)属于综合第二类等效模型:If G p (.) belongs to the comprehensive second-class equivalent model:

LL outout == (( qq pp LL inin ++ (( 11 -- qq pp )) )) 11 &beta;&beta; pp -- -- -- qq pp &GreaterEqual;&Greater Equal; 11 ,, &beta;&beta; pp >> 00 -- -- -- (( 1919 ))

那么Gpc(.)模型是:Then the G pc (.) model is:

LL outout == 11 qq pp LL inin &beta;&beta; pp ++ (( 11 -- 11 qq pp )) -- -- -- qq pp &GreaterEqual;&Greater Equal; 11 ,, &beta;&beta; pp >> 00 -- -- -- (( 2020 ))

3、级联两个校正子环节构成校正环节;3. Cascading two correction sub-links to form a correction link;

如图9所示,校正环节Gc(.)由子环节Gac(.)和子环节Gpc(.)按照Gac(.)在前,Gpc(.)在后的顺序级联得到。As shown in Figure 9, the correction link G c (.) is obtained by cascading sub-links G ac (.) and sub-links G pc (.) in the order that G ac (.) comes first and G pc (.) follows.

建立Gac(.)和Gpc(.)模型后,具体实现其两者的级联,有如下方法:After establishing the G ac (.) and G pc (.) models, the specific implementation of the cascade of the two has the following methods:

1)、直接计算法:根据函数复合的定义,按照Gac(.)和Gpc(.)的参数计算Gc(.)的参数。因为指数α和β不一定是整数或者是整数的倒数,复合之后的函数形式一般涉及非整数指数的广义牛顿二项式展开,含有无限多项。为了计算方便,只能截取前若干项,计算复杂,并且造成计算误差。然后根据这个复合模型和输入的亮度信号实时计算输出后的校正信号。1) Direct calculation method: According to the definition of function composition, the parameters of G c (.) are calculated according to the parameters of G ac (.) and G pc (.). Because the exponents α and β are not necessarily integers or reciprocals of integers, the functional form after compounding generally involves the generalized Newton binomial expansion of non-integer exponents, which contains infinite numbers. For the convenience of calculation, only the first few items can be intercepted, which is complicated and causes calculation errors. Then, the output correction signal is calculated in real time according to the composite model and the input luminance signal.

2)、两步法:首先计算Gac(.)的校正的结果,即输入亮度信号首先经过Gac(.)进行一次校正,校正结果再作为Gpc(.)的输入进行二次校正,Gpc(.)的输出的二次校正后的亮度信号作为最后的校正结果。2), Two-step method: first calculate the correction result of G ac (.), that is, the input brightness signal is first corrected by G ac (.), and the correction result is used as the input of G pc (.) for secondary correction. The secondary corrected luminance signal output by G pc (.) is used as the final correction result.

3)、查表法:按照1)或者2),对于输入亮度信号取值区间上计算足够多的点,记录其校正结果,作为一个查表。然后在进行校正的时候,对于需要校正的输入信号值,通过查表获得校正结果。表项数越多,即样本采集越密集,查表的效果越精确。3) Table look-up method: According to 1) or 2), calculate enough points on the value interval of the input brightness signal, and record the correction results as a look-up table. Then, when performing correction, for the input signal value to be corrected, the correction result is obtained by looking up the table. The more table entries, that is, the denser the sample collection, the more accurate the table lookup effect.

对于数据量大的视频数据,进行实时计算的计算量很大,查表是最实际的方法。表的结构形式一般包括两列和多行:待校正信号值为左列,校正结果对应列在右列,行数取决与采样值的多少。查表的方法是,根据待校正信号值,在表的左列中查找,如果找到,直接把对应的右列值作为查表的结果。如果没有找到,利用线性插值计算,设待校正信号值是a,其位于b、c(c>a>b)两个左列相邻表项之间,b、c对应的右列表项是d、e,那么最终查表结果 f = c - a c - b b + a - b c - b c . For video data with a large amount of data, the amount of calculation for real-time calculation is very large, and table lookup is the most practical method. The structure of the table generally includes two columns and multiple rows: the signal value to be corrected is in the left column, the corrected result is listed in the right column, and the number of rows depends on the number of sampled values. The method of looking up the table is to search in the left column of the table according to the value of the signal to be corrected, and if found, directly use the corresponding value in the right column as the result of the table lookup. If not found, use linear interpolation to calculate, assuming that the value of the signal to be corrected is a, which is located between b and c (c>a>b) two adjacent items in the left column, and the corresponding right list item of b and c is d , e, then the final table lookup result f = c - a c - b b + a - b c - b c .

本发明技术方案带来的有益效果如下:The beneficial effects brought by the technical solution of the present invention are as follows:

本发明解决了多媒体信息系统中普遍存在的Gamma特性的测量问题和校正的问题,对于任意多环节级联的综合Gamma特性给出一种通用的校正方法。从而可以大大提高多媒体信息系统的用户体验,吸引用户,提升相关产品的市场竞争力,并且推动新型电信业务比如可视电话,视频会议等的加快普及,为电信运营商提供广阔的商机。The invention solves the problem of measurement and correction of Gamma characteristics which are ubiquitous in multimedia information systems, and provides a general correction method for the comprehensive Gamma characteristics of arbitrary multi-link cascading. This can greatly improve the user experience of the multimedia information system, attract users, enhance the market competitiveness of related products, and promote the accelerated popularization of new telecommunication services such as video telephony and video conferencing, providing telecom operators with broad business opportunities.

显然,本领域的技术人员可以对本发明进行各种改动和变型而不脱离本发明的精神和范围。这样,倘若本发明的这些修改和变型属于本发明权利要求及其等同技术的范围之内,则本发明也意图包含这些改动和变型在内。Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and equivalent technologies thereof, the present invention also intends to include these modifications and variations.

Claims (19)

1. A gamma correction method for correcting N included in a multimedia information systemtGamma characteristics of individual segments, characterized in that the method comprises the steps of:
determining a correction point that will correct said NtEach link is divided into N before the correction pointaA link and N after the correction pointpA link, wherein: n is a radical ofa≥0、Np≥0、Na+Np=Nt
Determining the equivalent of said NaOne ringDetermining a first equivalent model of the joint gamma characteristic and a first inverse model thereof to be equivalent to the NpA second equivalent model and a second inverse model of the gamma characteristic of each link;
constructing a calibration link model according to the first inverse model and the second inverse model, and determining the N by using the calibration link modelaThe last output signal of each link is corrected and input into the NpAnd (5) carrying out each link.
2. The method of claim 1, wherein the representation function of the inverse model is the corresponding inverse function when the equivalent model takes the functional representation form.
3. The method of claim 2, wherein the determining the first equivalent model or the second equivalent model comprises the steps of:
a1, detecting N sampling values L of input signal respectivelyin(i) Inputting N values L of the actual output signal generated by the linkP out(i) Wherein: i is more than or equal to 0 and less than or equal to N-1;
a2, selecting a model to be tested from a group of alternative equivalent models in a function representation form to execute the step A3;
a3, selecting a group of initial parameters for the model to be tested;
a4, calculating:
calculating N values L of theoretical output signals corresponding to the N sampling values according to the model to be testedM out(i) Wherein: i is more than or equal to 0 and less than or equal to N-1; and
a value of the objective function F corresponding to each pair of LP out(i) And LM out(i) Is correlated with the difference of (a);
a5, judging whether the objective function value F is equal to or less than a set threshold value, if so, determining that the model to be tested is accepted as a final equivalent model, and switching to the step A8 after taking a parameter corresponding to the minimum objective function value F as a parameter of the equivalent model; otherwise, executing step A6;
a6, judging whether the execution times of the step A4 reach the limited iteration times, if so, selecting one alternative equivalent model from other undetected alternative equivalent models as a model to be tested and returning to the step A3; otherwise, executing step A7;
a7, adjusting the model parameters by using a mathematical optimization method, and returning to the step A4;
and A8, ending.
4. The method as claimed in claim 3, wherein in step A5, when the objective function value F is equal to or less than a set threshold value, the parameters are adjusted and the objective function value F is calculated by the mathematical optimization method according to a set number of cycles, and then the parameter corresponding to the smallest objective function value F is used as the parameter of the equivalent model.
5. The method of claim 3 or 4, further comprising the steps of:
respectively substituting the measured parameters into the expression functions of the corresponding inverse models, and solving a first inverse function formula corresponding to the first inverse model and a second inverse function formula corresponding to the second inverse model;
and constructing a correction model by using the first inverse function formula and the second inverse function formula.
6. The method of claim 5, wherein the method of constructing the calibration link model comprises one of:
direct calculation method: real-time computation of N using a complex function of a first inverse function and a second inverse functionaThe correction signal of the final output signal of each link;
the two-step calculation method comprises the following steps: real-time computation of N using a first inverse functionaCalculating a secondary correction signal of the primary correction signal by using a second inverse function, and taking the secondary correction signal as the correction signal;
table look-up method: according to the direct calculation in advanceBy calculation of said NaAnd correcting values corresponding to a plurality of sampling values in the value interval of the final output signal of each link, storing the corresponding relation in a data table, and determining the correcting value of any value to be corrected by inquiring the data table in real time.
7. The method of claim 6, wherein the table lookup comprises:
when the input value to be corrected is in the data table, the corresponding correction value is directly obtained through table look-up;
when the input value to be corrected is not in the input column of the data table, the corresponding correction value is obtained by adopting a linear interpolation average method.
8. The method of claim 3, wherein the objective function value F satisfies the following condition:
<math> <mi>F</mi> </math><math> <mo>=</mo> </math><math> <mrow> <munderover> <mi>&Sigma;</mi> <mrow> <mi>i</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>N</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <msup> <mrow> <mo>(</mo> <msubsup> <mi>L</mi> <mi>out</mi> <mi>P</mi> </msubsup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>-</mo> <msubsup> <mi>L</mi> <mi>out</mi> <mi>M</mi> </msubsup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mn>2</mn> </msup> <mo>.</mo> </mrow> </math>
9. the method of claim 3, wherein the functional relation and its corresponding inverse functional relation of the set of alternative equivalent models in functional representation form comprises:
the equivalent model functional relation of the gamma characteristic is as follows: l isout=pLin α+ (1-p), wherein: the domain of the function is the interval [0, 1]]The range is the interval [ (1-p), 1](ii) a Then it isThe inverse of the function is:
<math> <mrow> <msub> <mi>L</mi> <mi>out</mi> </msub> <mo>=</mo> <msup> <mrow> <mo>(</mo> <mfrac> <mn>1</mn> <mi>p</mi> </mfrac> <msub> <mi>L</mi> <mi>in</mi> </msub> <mo>+</mo> <mrow> <mo>(</mo> <mn>1</mn> <mo>-</mo> <mfrac> <mn>1</mn> <mi>p</mi> </mfrac> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mfrac> <mn>1</mn> <mi>&alpha;</mi> </mfrac> </msup> <mo>;</mo> </mrow> </math> or,
the equivalent model functional relation of the gamma characteristic is as follows: <math> <mrow> <msub> <mi>L</mi> <mi>out</mi> </msub> <mo>=</mo> <msup> <mrow> <mo>(</mo> <msub> <mi>qL</mi> <mi>in</mi> </msub> <mo>+</mo> <mrow> <mo>(</mo> <mn>1</mn> <mo>-</mo> <mi>q</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mfrac> <mn>1</mn> <mi>&beta;</mi> </mfrac> </msup> <mo>,</mo> </mrow> </math> wherein: the domain of the function is the interval [1-1/q, 1]The range is the interval [0, 1]](ii) a The inverse of the function is then:
<math> <mrow> <msub> <mi>L</mi> <mi>out</mi> </msub> <mo>=</mo> <mfrac> <mn>1</mn> <mi>q</mi> </mfrac> <msup> <msub> <mi>L</mi> <mi>in</mi> </msub> <mi>&beta;</mi> </msup> <mo>+</mo> <mrow> <mo>(</mo> <mn>1</mn> <mo>-</mo> <mfrac> <mn>1</mn> <mi>q</mi> </mfrac> <mo>)</mo> </mrow> <mo>;</mo> </mrow> </math>
wherein: l isinIs an input signal value, LoutRespectively taking the output signal values, p and alpha, and q and beta as parameters to be measured; and when N isa1 or NpWhen the value is 1: p is more than 0 and less than or equal to 1, alpha is more than or equal to 1, q is more than or equal to 1, and beta is more than or equal to 1; when N is presenta> 1 or NpAt > 1: p is more than 0 and less than or equal to 1, alpha is more than or equal to 0, q is more than or equal to 1, and beta is more than or equal to 0.
10. The method of claim 3, wherein the mathematical optimization method is: hill climbing, or 0.618, or steepest descent, or conjugate gradient.
11. A method as claimed in claim 3, characterized in that N sample values of the input signal are selected in the interval [0, 1 ].
12. The method of claim 1, wherein when the equivalent model is in the form of a data table, the corresponding inverse model is an inverse table of the data table.
13. A detection method for determining a gamma characteristic equivalent model and parameters thereof, wherein the gamma characteristic equivalent model is used for gamma characteristics in an equivalent signal transmission or processing link, and is characterized by comprising the following steps:
b1, detecting N sampling values L of input signal respectivelyin(i) Inputting N values L of the actual output signal generated by the linkP out(i) Wherein: i is more than or equal to 0 and less than or equal to N-1;
b2, selecting one to-be-tested model from a group of alternative equivalent models in a function representation form to execute the step B3;
b3, selecting a group of initial parameters for the model to be tested;
b4, calculating:
calculating N values of theoretical output signals corresponding to the N sampling values of the signals according to the model to be tested: l isM out(i) Wherein: i is more than or equal to 0 and less than or equal to N-1; and
a value of the objective function F corresponding to each pair of LP out(i) And LM out(i) Is correlated with the difference of (a);
b5, judging whether the objective function value F is equal to or smaller than a set threshold value, if so, considering that the model to be tested is accepted as a final equivalent model, and switching to a step B8 after taking the group of parameters as the parameters of the equivalent model; otherwise, executing step B6;
b6, judging whether the execution times of the step B4 reach the limited iteration times, if so, selecting one alternative equivalent model from other undetected alternative equivalent models as a model to be tested and returning to the step B3; otherwise, executing step B7;
b7, adjusting the parameters by using the mathematical optimization method, and returning to the step B4;
and B8, ending.
14. The method as claimed in claim 13, wherein in step B5, when the objective function value F is equal to or less than a predetermined threshold value, the parameters are adjusted by the mathematical optimization method according to a predetermined number of cycles, and the objective function value F is calculated, and then the parameter corresponding to the smallest objective function value F is used as the parameter of the equivalent model.
15. The method according to claim 13 or 14, wherein the objective function value F satisfies the following condition:
<math> <mi>F</mi> </math><math> <mo>=</mo> </math><math> <mrow> <munderover> <mi>&Sigma;</mi> <mrow> <mi>i</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>N</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <msup> <mrow> <mo>(</mo> <msubsup> <mi>L</mi> <mi>out</mi> <mi>P</mi> </msubsup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>-</mo> <msubsup> <mi>L</mi> <mi>out</mi> <mi>M</mi> </msubsup> <mrow> <mo>(</mo> <mi>i</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mn>2</mn> </msup> <mo>.</mo> </mrow> </math>
16. the method of claim 15, wherein the gamma characteristic comprises a single-ring-segment gamma characteristic or a multi-ring-cascade synthesis gamma characteristic.
17. The method of claim 15, wherein the functional relationships of the set of candidate equivalent models and their corresponding inverse functions comprise:
the equivalent model functional relation of the gamma characteristic is as follows: l isout=pLin α+ (1-p), wherein: the domain of the function is the interval [0, 1]]The range is the interval [ (1-p), 1](ii) a The inverse of the function is then:
<math> <mrow> <msub> <mi>L</mi> <mi>out</mi> </msub> <mo>=</mo> <msup> <mrow> <mo>(</mo> <mfrac> <mn>1</mn> <mi>p</mi> </mfrac> <msub> <mi>L</mi> <mi>in</mi> </msub> <mo>+</mo> <mrow> <mo>(</mo> <mn>1</mn> <mo>-</mo> <mfrac> <mn>1</mn> <mi>p</mi> </mfrac> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mfrac> <mn>1</mn> <mi>&alpha;</mi> </mfrac> </msup> <mo>;</mo> </mrow> </math> or,
the equivalent model functional relation of the gamma characteristic is as follows: <math> <mrow> <msub> <mi>L</mi> <mi>out</mi> </msub> <mo>=</mo> <msup> <mrow> <mo>(</mo> <msub> <mi>qL</mi> <mi>in</mi> </msub> <mo>+</mo> <mrow> <mo>(</mo> <mn>1</mn> <mo>-</mo> <mi>q</mi> <mo>)</mo> </mrow> <mo>)</mo> </mrow> <mfrac> <mn>1</mn> <mi>&beta;</mi> </mfrac> </msup> <mo>,</mo> </mrow> </math> wherein: the domain of the function is the interval [1-1/q, 1]The range is the interval [0, 1]](ii) a The inverse of the function is then:
<math> <mrow> <msub> <mi>L</mi> <mi>out</mi> </msub> <mo>=</mo> <mfrac> <mn>1</mn> <mi>q</mi> </mfrac> <msup> <msub> <mi>L</mi> <mi>in</mi> </msub> <mi>&beta;</mi> </msup> <mo>+</mo> <mrow> <mo>(</mo> <mn>1</mn> <mo>-</mo> <mfrac> <mn>1</mn> <mi>q</mi> </mfrac> <mo>)</mo> </mrow> <mo>;</mo> </mrow> </math>
wherein: l isinIs an input signal value, LoutRespectively taking the output signal values, p and alpha, and q and beta as parameters to be measured; in the single-ring-segment gamma characteristic: p is more than 0 and less than or equal to 1, alpha is more than or equal to 1, q is more than or equal to 1, and beta is more than or equal to 1; the multi-ring gammaAmong the characteristics: p is more than 0 and less than or equal to 1, alpha is more than or equal to 0, q is more than or equal to 1, and beta is more than or equal to 0.
18. The method of claim 13, wherein the mathematical optimization method is: hill climbing, or 0.618, or steepest descent, or conjugate gradient.
19. The method of claim 13 wherein N samples of the input signal are selected in the interval [0, 1 ].
CNB2005100802535A 2005-06-30 2005-06-30 Gamma characteristic correcting method Expired - Fee Related CN100527856C (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CNB2005100802535A CN100527856C (en) 2005-06-30 2005-06-30 Gamma characteristic correcting method
PCT/CN2006/000710 WO2007003086A1 (en) 2005-06-30 2006-04-18 Method for gamma character equivalent model and parameter determination and gamma correction

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2005100802535A CN100527856C (en) 2005-06-30 2005-06-30 Gamma characteristic correcting method

Publications (2)

Publication Number Publication Date
CN1889693A true CN1889693A (en) 2007-01-03
CN100527856C CN100527856C (en) 2009-08-12

Family

ID=37578951

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2005100802535A Expired - Fee Related CN100527856C (en) 2005-06-30 2005-06-30 Gamma characteristic correcting method

Country Status (2)

Country Link
CN (1) CN100527856C (en)
WO (1) WO2007003086A1 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007147363A1 (en) * 2006-06-15 2007-12-27 Huawei Technologies Co., Ltd. A method and an apparatus for correcting the gamma characteristic of the video communication
CN108628715A (en) * 2018-03-20 2018-10-09 青岛海信电器股份有限公司 It is a kind of display equipment display effect bearing calibration and device
CN110491336A (en) * 2019-08-27 2019-11-22 武汉精立电子技术有限公司 A kind of display module Gamma adjusting process and system

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5196924A (en) * 1991-07-22 1993-03-23 International Business Machines, Corporation Look-up table based gamma and inverse gamma correction for high-resolution frame buffers
JPH07264406A (en) * 1994-03-18 1995-10-13 Oki Electric Ind Co Ltd Gamma correction method for image reader
US6441870B1 (en) * 1998-12-22 2002-08-27 Gateway, Inc. Automatic gamma correction for multiple video sources
CN1281011C (en) * 2002-12-10 2006-10-18 中兴通讯股份有限公司 Adaptive carrier inhibiting method for multiple-carrier linear power amplifier

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007147363A1 (en) * 2006-06-15 2007-12-27 Huawei Technologies Co., Ltd. A method and an apparatus for correcting the gamma characteristic of the video communication
CN108628715A (en) * 2018-03-20 2018-10-09 青岛海信电器股份有限公司 It is a kind of display equipment display effect bearing calibration and device
CN108628715B (en) * 2018-03-20 2022-01-28 海信视像科技股份有限公司 Display effect correction method and device of display equipment
CN110491336A (en) * 2019-08-27 2019-11-22 武汉精立电子技术有限公司 A kind of display module Gamma adjusting process and system

Also Published As

Publication number Publication date
WO2007003086A1 (en) 2007-01-11
CN100527856C (en) 2009-08-12

Similar Documents

Publication Publication Date Title
CN1305009C (en) Image processing device and image processing method and processing program
CN1263329C (en) Image deta processing for providing to image display device
CN1265627C (en) Image data processing method, and image data processing circuit
CN100341045C (en) Image display device, image processing method, program and storage medium
CN1809838A (en) Method and system for video quality assessment
CN1430420A (en) Device and method for controlling image brightness
CN1294530C (en) Color image processing method, color image processor, color display, computer program for implementing the color image processing method
CN1257466C (en) Image processing system and method, device and terminal thereof
CN1595958A (en) Image quality correction apparatus and image quality correction method
CN101075415A (en) Display device, display panel driver and method of driving a display panel
CN1573425A (en) Gamma correction circuit, liquid crystal driving circuit, display and power supply circuit
CN1722852A (en) High-Quality Gradient-Corrected Linear Interpolation for Color Image Demosaicing
CN1945627A (en) Method for correcting digital tongue picture colour cast
CN1518350A (en) Frame data correction output device, correction device and method, display device
CN1229969C (en) Color conversion device and color conversion method
CN101056417A (en) Image processing apparatus, image processing method, image output apparatus, and image processing system
CN1783181A (en) Image display apparatus and driving method thereof
CN1476718A (en) Image processing system, projector, information storage medium and black and white extended processing method
CN1726529A (en) Image signal processing apparatus, image signal processing method, program for practicing that method, and computer-readable medium in which that program has been recorded
CN1846229A (en) Image processing apparatus, image processing program, and readable recording medium
CN100342709C (en) Image recording apparatus, image recording method, image processing apparatus, image processing method and image processing system
CN1163057C (en) Image quality correction circuit
CN1543742A (en) Motion detection device, image processing system, motion detection method, program, and recording medium
CN1578474A (en) Image processing device, image display device, and image processing method
CN1885954A (en) Blocking effect measuring method and video quality estimation method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20090812

Termination date: 20150630

EXPY Termination of patent right or utility model