CN107197225A - Color digital camera white balance correcting based on chromatic adaptation model - Google Patents

Color digital camera white balance correcting based on chromatic adaptation model Download PDF

Info

Publication number
CN107197225A
CN107197225A CN201710442492.3A CN201710442492A CN107197225A CN 107197225 A CN107197225 A CN 107197225A CN 201710442492 A CN201710442492 A CN 201710442492A CN 107197225 A CN107197225 A CN 107197225A
Authority
CN
China
Prior art keywords
mrow
msup
color
msub
light source
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
CN201710442492.3A
Other languages
Chinese (zh)
Other versions
CN107197225B (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.)
Zhejiang University ZJU
Original Assignee
Zhejiang University ZJU
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 Zhejiang University ZJU filed Critical Zhejiang University ZJU
Priority to CN201710442492.3A priority Critical patent/CN107197225B/en
Publication of CN107197225A publication Critical patent/CN107197225A/en
Application granted granted Critical
Publication of CN107197225B publication Critical patent/CN107197225B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/84Camera processing pipelines; Components thereof for processing colour signals
    • H04N23/88Camera processing pipelines; Components thereof for processing colour signals for colour balance, e.g. white-balance circuits or colour temperature control

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Processing Of Color Television Signals (AREA)
  • Color Image Communication Systems (AREA)

Abstract

The invention discloses a kind of color digital camera white balance correcting based on chromatic adaptation model, the present invention calculates color correction matrix using radical sign polynomial regression (Root Polynomial Regression) method, so that the equipment relevant response value RGB under several common light sources (hereinafter referred to as Calibrating source) is changed to same light source into device-independent CIE1931 tristimulus values XYZ.The RGB responses of unknown light source in actual scene (hereinafter referred to as testing light source) are changed into XYZ color space using the color correction matrix demarcated in advance, and its corresponding color under reference light source is calculated using CAT02 chromatic adaptation transformation models, the correspondence color is that observer produces the color that chromatic adaptation after-vision system is perceived to testing light source.

Description

基于色适应模型的彩色数码相机白平衡校正方法White Balance Calibration Method of Color Digital Camera Based on Chromatic Adaptation Model

技术领域technical field

本发明涉及利用色适应模型对彩色数码相机白平衡校正结果进行调节的方法,该方法能够使彩色数码相机对拍摄场景实现更符合人眼感知的色彩还原。The invention relates to a method for adjusting the white balance correction result of a color digital camera by using a color adaptation model. The method can enable the color digital camera to realize color restoration more in line with human perception for shooting scenes.

背景技术Background technique

同一物体在不同光源下往往具有不同的色度学参数。由于人类视觉系统具有颜色恒常性,这些色度上的差异在一定程度上能够被人眼及大脑自动进行补偿,从而在不同光源下对物体“真实”的颜色进行恢复。彩色数码相机图像信号处理流程(ISP Pipeline)中的白平衡模块,通过计算实际光源色品与标准光源色品之间的差异,对非标准光源下的物体偏色现象进行校正,从而模拟了人类视觉系统的颜色恒常性。The same object often has different colorimetric parameters under different light sources. Due to the color constancy of the human visual system, these differences in chromaticity can be automatically compensated by the human eye and brain to a certain extent, so as to restore the "true" color of the object under different light sources. The white balance module in the image signal processing flow (ISP Pipeline) of a color digital camera corrects the color cast of objects under non-standard light sources by calculating the difference between the chromaticity of the actual light source and the chromaticity of the standard light source, thereby simulating the human Color constancy of the visual system.

目前的彩色数码相机对光源色品的获取主要来源于两种方式:1)在相机的存储空间中预先设定好若干种类型的光源模式,在实际拍摄时由用户指定场景所属的光源类型。这类光源色品获取方式称为“手动白平衡模式”;2)对拍摄到的图像进行分析,通过某些光源估计算法或借助外置传感器对光源的颜色进行预测。这类光源色品获取方式称为“自动白平衡模式”。无论工作在何种模式下,白平衡校正模块通常都是利用两个或三个增益系数对偏色图像的红(Red)、蓝(Blue)或红、绿(Green)、蓝通道进行线性调节,使得场景中假想的完善反射表面(在任意波长处的光谱反射比恒为1的完善反射表面)经白平衡校正后具有相同的(或与参考白点一致的)三通道响应值。The current color digital camera obtains the chromaticity of the light source mainly from two ways: 1) several types of light source modes are pre-set in the storage space of the camera, and the user specifies the light source type to which the scene belongs during actual shooting. This type of light source chromaticity acquisition method is called "manual white balance mode"; 2) Analyze the captured images, and predict the color of the light source through some light source estimation algorithms or with the help of external sensors. This type of light source chromaticity acquisition method is called "automatic white balance mode". Regardless of the working mode, the white balance correction module usually uses two or three gain coefficients to linearly adjust the red (Red), blue (Blue) or red, green (Green) and blue channels of the color cast image , so that the imaginary perfect reflective surface in the scene (perfect reflective surface with a constant spectral reflectance of 1 at any wavelength) has the same (or consistent with the reference white point) three-channel response value after white balance correction.

若对任何照明光源,尤其是某些色品较明显偏离参考白点的光源,都使用统一的参考光源作为白平衡校正目标,会对白平衡校正后的图像产生如下弊端:1)输出图像过“白”,场景中颜色的还原不符合人眼感知;2)光源对场景氛围的渲染作用完全被抑制;3)将偏色较严重的光源强行校正至参考光源,会增加图像信号处理流程中后续模块(例如镜头阴影校正、颜色校正等)的处理难度,甚至导致图像质量出现劣化。If any lighting source, especially some light sources whose chromaticity deviates significantly from the reference white point, uses a unified reference light source as the target of white balance correction, the following disadvantages will occur to the image after white balance correction: 1) The output image is too " 2) The rendering effect of the light source on the atmosphere of the scene is completely suppressed; 3) Forcibly correcting the light source with serious color cast to the reference light source will increase the subsequent processing of the image signal. The processing difficulty of modules (such as lens shading correction, color correction, etc.) may even cause image quality to deteriorate.

发明内容Contents of the invention

为了使数码相机的白平衡校正模块实现更加真实的场景颜色复现,本发明利用原始白平衡校正模块中获取的增益系数计算实际拍摄场景中光源的颜色。为表述统一起见,本发明中使用完善反射表面的物体色来表征光源色,因为完善反射表面能够无波长选择性地反射光源的全部能量。使用CIECAM02色貌模型中的CAT02色适应变换对该物体色在参考光源下的对应色进行计算,从而得到色适应后的白平衡校正增益系数以实现对图像进行更加符合人眼视觉感知的白平衡校正。In order to make the white balance correction module of the digital camera realize more realistic scene color reproduction, the present invention utilizes the gain coefficient obtained in the original white balance correction module Calculates the color of the light source in the actual shooting scene. For the sake of uniform expression, in the present invention, the object color of the perfect reflective surface is used to represent the color of the light source, because the perfect reflective surface can reflect all the energy of the light source without wavelength selectivity. Use the CAT02 color adaptation transformation in the CIECAM02 color appearance model to calculate the corresponding color of the object color under the reference light source, so as to obtain the white balance correction gain coefficient after color adaptation In order to realize the white balance correction of the image that is more in line with the visual perception of the human eye.

本发明使用根号多项式回归(Root-Polynomial Regression)方法计算颜色校正矩阵,从而将若干种常见光源(以下称为标定光源)下的设备相关响应值RGB转换至同一光源下设备无关的CIE1931三刺激值XYZ。利用预先标定的颜色校正矩阵将实际场景中待校正的未知光源(以下称为测试光源)的RGB响应值转换至XYZ颜色空间中,并使用CAT02色适应变换模型计算其在参考光源下的对应色,该对应色即为观察者对测试光源产生色适应后视觉系统所感知的颜色。The present invention uses the root-polynomial regression (Root-Polynomial Regression) method to calculate the color correction matrix, thereby converting the device-dependent response value RGB under several common light sources (hereinafter referred to as calibration light sources) to the device-independent CIE1931 tri-stimulus value under the same light source Value XYZ. Use the pre-calibrated color correction matrix to convert the RGB response value of the unknown light source to be corrected in the actual scene (hereinafter referred to as the test light source) to the XYZ color space, and use the CAT02 color adaptation transformation model to calculate its corresponding color under the reference light source , the corresponding color is the color perceived by the visual system of the observer after chromatic adaptation to the test light source.

本发明所采用的具体技术方案如下:The concrete technical scheme that the present invention adopts is as follows:

基于色适应模型的彩色数码相机白平衡校正方法,步骤如下:A color digital camera white balance correction method based on a chromatic adaptation model, the steps are as follows:

S1:利用根号多项式回归颜色校正方法将不同标定光源下的设备相关响应值RGB转换至同一光源下设备无关的三刺激值CIE1931 XYZ;S1: Convert the device-related response value RGB under different calibration light sources to the device-independent tristimulus value CIE1931 XYZ under the same light source by using the root polynomial regression color correction method;

S2:获取待校正光源下拍摄的图像的白平衡校正增益系数,计算待校正光源在平面上的坐标,在相机平面上搜索与该坐标距离最近的标定光源,调用该标定光源对应的颜色校正矩阵,将该光源的设备相关的相机响应值转换至CIE1931 XYZ空间中,将光源颜色视为物体色;S2: Obtain the white balance correction gain coefficient of the image taken under the light source to be corrected, and calculate the Coordinates on the plane, at the camera Search for the calibration light source closest to the coordinate on the plane, call the color correction matrix corresponding to the calibration light source, convert the device-related camera response value of the light source into the CIE1931 XYZ space, and regard the light source color as the object color;

S3:使用CIECAM02色貌模型中的色适应变换CAT02计算物体色经色适应后的标准光源下的对应色:S3: Use the color adaptation transformation CAT02 in the CIECAM02 color appearance model to calculate the corresponding color of the object color under the standard light source after color adaptation:

S4:将对应色利用所述颜色校正矩阵的逆矩阵重新映射回相机RGB空间,并重新计算色适应后的白平衡校正增益系数。S4: Remap the corresponding color back to the RGB space of the camera using the inverse matrix of the color correction matrix, and recalculate the white balance correction gain coefficient after color adaptation.

基于上述技术方案,各步骤可以采用如下具体实现方式:Based on the above technical solution, each step can adopt the following specific implementation methods:

作为优选,所述的S1具体为:As a preference, said S1 is specifically:

S101:对于光谱功率分布为P(λ)的标定光源L,使用相机响应值构成模型计算标准色卡第i个色块在该光源照明下的相机RGB值ri、gi和biS101: For the calibration light source L whose spectral power distribution is P(λ), use the camera response value composition model to calculate the camera RGB values r i , g i and b i of the i-th color block of the standard color card under the illumination of the light source:

式中ρi(λ)表示第i个色块的光谱反射比,Sk(λ)表示相机第k个通道的光谱灵敏度函数,k=R、G、B,Ω′为相机光谱响应的波长范围;对于有N个色块的标准色卡,计算得到一个N×3的相机响应值矩阵C(L),其中每一行对应一个色块的相机RGB值;In the formula, ρi (λ) represents the spectral reflectance of the i -th color block, S k (λ) represents the spectral sensitivity function of the k-th channel of the camera, k=R, G, B, and Ω′ is the wavelength of the spectral response of the camera Range; for a standard color card with N color blocks, an N×3 camera response value matrix C(L) is calculated, where each row corresponds to the camera RGB value of a color block;

S102:计算该标定光源下完善反射表面的相机RGB值rill、gill和billS102: Calculate the camera RGB values r ill , g ill and b ill of the perfect reflective surface under the calibration light source:

并记录其在平面上的坐标 and record it in coordinates on the plane

S103:对于光谱功率分布为P(λ)的标定光源,使用CIE1931 2°标准观察者色匹配函数计算标准色卡第i个色块在该光源照明下的CIE1931 XYZ三刺激值:S103: For the calibration light source with spectral power distribution P(λ), use CIE1931 2° standard observer color matching function Calculate the CIE1931 XYZ tristimulus value of the i-th color block of the standard color card under the illumination of this light source:

式中Ω为可见光的波长范围;对于有N个色块的标准色卡,计算得到一个N×3的三刺激值矩阵T(L),其中每一行对应一个色块的XYZ三刺激值;In the formula, Ω is the wavelength range of visible light; for a standard color card with N color blocks, an N×3 tristimulus value matrix T(L) is calculated, in which each row corresponds to the XYZ tristimulus value of a color block;

S104:将相机响应值矩阵C(L)的维度由N×3扩展为N×q,q>3,其中第4~q列对应各个色块响应值的根号多项式;S104: Expand the dimension of the camera response value matrix C(L) from N×3 to N×q, q>3, wherein the 4th to q columns correspond to the root polynomials of the response values of each color block;

S105:利用最小二乘法或其它以色差作为目标函数的校正矩阵优化方法,计算C′(L)转换至T(L)的6×3颜色校正矩阵M′(L):S105: Calculate the 6×3 color correction matrix M'(L) converted from C'(L) to T(L) by using the least square method or other correction matrix optimization methods with color difference as the objective function:

以C′(L)·M′(L)与T(L)之间的均方根误差作为优化目标时,采用伪逆法对M′(L)进行计算:When the root mean square error between C′(L)·M′(L) and T(L) is taken as the optimization target, the pseudo-inverse method is used to calculate M′(L):

M′(L)=[C′T(L)C′(L)]-1C′T(L)·T(L),M'(L)=[C'T(L)C'(L)] -1 C'T (L)· T (L),

以C′(L)·M′(L)与T(L)之间的色差作为优化目标时,利用非线性优化方法对M′(L)进行计算:When the color difference between C'(L)·M'(L) and T(L) is used as the optimization target, the nonlinear optimization method is used to calculate M'(L):

M′(L)=arg min △E(C′(L)·M′(L),T(L)),M'(L)=arg min △E(C'(L)·M'(L),T(L)),

式中△E(A,B)为用于计算A和B之间的色差的函数;Where △E(A,B) is a function used to calculate the color difference between A and B;

S106:利用S105中的方法计算各个标定光源下的3×3颜色校正矩阵M(L);S107:对于所有标定光源,采用S101~S106的方法计算得到各自的颜色校正矩阵M′(L)与M(L),并存储于相机内置存储器中。S106: Use the method in S105 to calculate the 3×3 color correction matrix M(L) under each calibration light source; S107: For all calibration light sources, use the method of S101 to S106 to calculate the respective color correction matrix M'(L) and M(L) and stored in the camera's built-in memory.

作为优选,所述的S2具体为:As preferably, said S2 is specifically:

S201:手动设置或利用已有的自动白平衡算法获取待校正光源下拍摄的图像的白平衡校正增益系数 S201: Manually set or use the existing automatic white balance algorithm to obtain the white balance correction gain coefficient of the image shot under the light source to be corrected

S202:计算待校正光源在相机raw域上的RGB值:S202: Calculate the RGB value of the light source to be corrected in the raw domain of the camera:

在相机平面上搜索与距离最近的标定光源L,并从相机内置存储器中调用其对应的颜色校正矩阵M′(L);in camera Plane search with The closest calibration light source L, and call its corresponding color correction matrix M'(L) from the camera's built-in memory;

S203:利用颜色校正矩阵M′(L)将该场景光源下的完善反射表面的相机响应值转换至CIE1931 XYZ空间中:S203: Transform the camera response value of the perfect reflective surface under the scene light source into the CIE1931 XYZ space by using the color correction matrix M′(L):

式中Xill,Yill,Zill分别为XYZ空间中的三刺激值。In the formula, X ill , Y ill , Z ill are the tristimulus values in XYZ space, respectively.

作为优选,所述的S3具体为:Preferably, said S3 is specifically:

使用CIECAM02色貌模型中的色适应变换CAT02计算物体色[Xill,Yill,Zill]经色适应后的标准光源下的对应色:Use the color adaptation transformation CAT02 in the CIECAM02 color appearance model to calculate the corresponding color of the object color [X ill , Y ill , Z ill ] under the standard light source after color adaptation:

式中色适应变换模型fCAT02的四个输入依次是待计算的物体色三刺激值、待适应的光源三刺激值、参考光源三刺激值以及环境亮度因子LAIn the formula, the four inputs of the color adaptation transformation model f CAT02 are the tristimulus value of the object color to be calculated, the tristimulus value of the light source to be adapted, the tristimulus value of the reference light source and the environmental brightness factor L A .

进一步的,所述的环境亮度因子使用两个sigmoid函数进行计算:Further, the ambient brightness factor is calculated using two sigmoid functions:

式中,光源色品距离d通过计算实际光源与参考光源色品在CIELUV均匀颜色空间中的欧式距离获得,a1、b1、K1、a2、b2、K2作为调整sigmoid函数形状的待定参数。In the formula, the light source chromaticity distance d is obtained by calculating the Euclidean distance between the actual light source and the reference light source chromaticity in the CIELUV uniform color space, and a 1 , b 1 , K 1 , a 2 , b 2 , and K 2 are used to adjust the shape of the sigmoid function The undetermined parameters of .

作为优选,所述的S4具体为:As preferably, said S4 is specifically:

对所述的标定光源L对应的3×3颜色校正矩阵M(L)求逆,并将色适应后的完善反射体三刺激值重新映射回相机RGB空间中:Invert the 3×3 color correction matrix M(L) corresponding to the calibration light source L, and use the perfect reflector tristimulus value after color adaptation Remap back into camera RGB space:

由此,计算色适应后的白平衡校正增益系数 From this, calculate the white balance correction gain coefficient after color adaptation

本发明通过对已标定的颜色校正矩阵求逆,可以将色适应后的CIE1931 XYZ三刺激值转换回相机RGB颜色空间中,从而确定色适应后的白平衡校正增益系数。The invention converts the chromatic-adapted CIE1931 XYZ tristimulus value back into the camera RGB color space by inverting the calibrated color correction matrix, thereby determining the chromatic-adapted white balance correction gain coefficient.

为了对本发明的实施过程有更直观的了解,下文特举一实施例,并配合所附图示进行详细说明。In order to have a more intuitive understanding of the implementation process of the present invention, an embodiment is given below and described in detail with the accompanying drawings.

附图说明Description of drawings

图1是本发明实施例中所使用的标定光源在由作为横纵坐标构成的平面(以下称为平面)上的坐标分布。Fig. 1 is the calibration light source used in the embodiment of the present invention by and As a plane composed of horizontal and vertical coordinates (hereinafter referred to as Coordinate distribution on the plane).

图2是本发明中对若干标定光源的颜色校正矩阵进行标定的流程图。Fig. 2 is a flow chart of calibrating the color correction matrices of several calibration light sources in the present invention.

图3是本发明实施例中所使用的CAT02色适应模型输入参数LA(环境亮度因子)与d(CIELUV均匀颜色空间中的欧式距离)、E(拍摄场景照度)之间的对应关系示意图。3 is a schematic diagram of the corresponding relationship between the CAT02 color adaptation model input parameter LA (environmental brightness factor), d (Euclidean distance in CIELUV uniform color space), and E (shooting scene illuminance) used in the embodiment of the present invention.

图4是本发明中对某一测试光源进行色适应后的白平衡校正增益系数计算的流程图。Fig. 4 is a flow chart of the calculation of the white balance correction gain coefficient after chromatic adaptation is performed on a test light source in the present invention.

具体实施方式detailed description

下面结合附图和具体实施方式对本发明做进一步阐述和说明。The present invention will be further elaborated and illustrated below in conjunction with the accompanying drawings and specific embodiments.

目前大多数彩色数码相机的白平衡校正模块将任何光源下的中性点均校正至参考光源下的驱动值,这种白平衡校正方式既不符合人眼对于真实场景中颜色的感知,也容易使得校正后的颜色出现明显的失真。本发明提出一种利用CIECAM02色貌模型中的CAT02色适应变换对数码相机白平衡校正模块原有的增益系数进行色适应调节的方法,从而使白平衡校正后的图像更加符合人眼的颜色感知。At present, the white balance correction module of most color digital cameras corrects the neutral point under any light source to the driving value under the reference light source. Makes the corrected color appear noticeably distorted. The present invention proposes a method for adjusting the color adaptation of the original gain coefficient of the digital camera white balance correction module by using the CAT02 color adaptation transformation in the CIECAM02 color appearance model, so that the image after white balance correction is more in line with the color perception of human eyes .

本发明使用根号多项式回归颜色校正(Root-Polynomial Regression ColorCorrection)方法将若干种常见光源下的设备相关响应值RGB转换至同一光源下设备无关的三刺激值CIE1931 XYZ。由于根号多项式回归颜色校正中使用的颜色校正矩阵取决于光源光谱功率分布函数,所以本发明需要预先对若干种典型光源进行颜色校正矩阵的标定。The present invention uses a root-polynomial regression color correction (Root-Polynomial Regression ColorCorrection) method to convert device-related response values RGB under several common light sources to device-independent tristimulus values CIE1931 XYZ under the same light source. Since the color correction matrix used in the square root polynomial regression color correction depends on the spectral power distribution function of the light source, the present invention needs to pre-calibrate the color correction matrix for several typical light sources.

图1展示了一种可行的标定光源选取方法,并绘制了39种标定光源在相机平面上的坐标分布。Figure 1 shows a feasible calibration light source selection method, and draws 39 calibration light sources in the camera Coordinate distribution on the plane.

图2为本发明中对若干标定光源的颜色校正矩阵进行标定的流程图。其中,标定光源的数量及种类可以灵活选择,在某些对存储开销限制较大的应用场景中,也可仅选取D65光源作为唯一的标定光源对颜色校正矩阵进行计算。Fig. 2 is a flow chart of calibrating the color correction matrices of several calibration light sources in the present invention. Among them, the number and types of calibration light sources can be flexibly selected, and in some application scenarios with a large storage cost limitation, only the D65 light source can be selected as the only calibration light source to calculate the color correction matrix.

1.本发明的标定过程包含以下步骤:1. The calibration process of the present invention comprises the following steps:

为将相机响应值RGB转换至设备无关的三刺激值XYZ,本发明采用根号多项式回归颜色校正方法。In order to convert the camera response value RGB to the device-independent tristimulus value XYZ, the present invention adopts a root polynomial regression color correction method.

对于光谱功率分布为P(λ)的标定光源L,使用相机响应值构成模型计算标准色卡第i个色块在该光源照明下的相机RGB值:For the calibration light source L whose spectral power distribution is P(λ), use the camera response value construction model to calculate the camera RGB value of the i-th color block of the standard color card under the illumination of the light source:

式中ρi(λ)表示第i个色块的光谱反射比,Sk(λ)表示相机第k个通道的光谱灵敏度函数(k=R、G、B),可从相机出厂时的标称数据中获得或利用相关的光谱灵敏度估计算法计算获得,Ω′为相机光谱响应的波长范围。对于有N个色块的标准色卡,可以计算得到一个N×3的相机响应值矩阵C(L),其中每一行对应一个色块的相机RGB值。In the formula, ρ i (λ) represents the spectral reflectance of the i-th color block, S k (λ) represents the spectral sensitivity function of the k-th channel of the camera (k=R, G, B), which can be obtained from the standard of the camera when it leaves the factory It is said to be obtained from the data or calculated by using the relevant spectral sensitivity estimation algorithm, and Ω' is the wavelength range of the camera's spectral response. For a standard color card with N color patches, an N×3 camera response value matrix C(L) can be calculated, where each row corresponds to the camera RGB value of a color patch.

同时,计算该标定光源下完善反射表面的相机RGB值:At the same time, calculate the camera RGB value of the perfect reflective surface under the calibration light source:

并记录其在平面上的坐标 and record it in coordinates on the plane

对于光谱功率分布为P(λ)的标定光源,使用CIE1931 2°标准观察者色匹配函数计算标准色卡第i个色块在该光源照明下的CIE1931 XYZ三刺激值:For the calibration light source with spectral power distribution P(λ), use CIE1931 2° standard observer color matching function Calculate the CIE1931 XYZ tristimulus value of the i-th color block of the standard color card under the illumination of this light source:

式中Ω为可见光的波长范围。对于有N个色块的标准色卡,可以计算得到一个N×3的三刺激值矩阵T(L),其中每一行对应一个色块的XYZ三刺激值。where Ω is the wavelength range of visible light. For a standard color card with N color blocks, an N×3 tristimulus value matrix T(L) can be calculated, where each row corresponds to the XYZ tristimulus value of a color block.

将相机响应值矩阵C(L)的维度由N×3扩展为N×q(q>3),其中第4~q列对应了各个色块响应值的根号多项式。以二次根号多项式为例,此时有q=6,扩展后的相机响应值矩阵C′(L)的第i行为 Expand the dimension of the camera response value matrix C(L) from N×3 to N×q(q>3), where the 4th to q columns correspond to the root sign polynomials of the response values of each color block. Take the quadratic root sign polynomial as an example, at this time, q=6, the i-th behavior of the extended camera response value matrix C′(L)

利用最小二乘法或其它以色差作为目标函数的校正矩阵优化方法,计算C′(L)转换至T(L)的6×3颜色校正矩阵M′(L):Using the least squares method or other correction matrix optimization methods with color difference as the objective function, calculate the 6×3 color correction matrix M'(L) converted from C'(L) to T(L):

以C′(L)·M′(L)与T(L)之间的均方根误差作为优化目标时,可采用伪逆法对M′(L)进行计算:When the root mean square error between C′(L)·M′(L) and T(L) is used as the optimization target, the pseudo-inverse method can be used to calculate M′(L):

M′(L)=[C′T(L)C′(L)]-1C′T(L)·T(L).M'(L)=[C'T(L)C'(L)] -1 C'T (L)· T (L).

以C′(L)·M′(L)与T(L)之间的色差作为优化目标时,可利用高斯-牛顿法等非线性优化方法对M′(L)进行计算:When the color difference between C′(L)·M′(L) and T(L) is used as the optimization target, M′(L) can be calculated by using nonlinear optimization methods such as the Gauss-Newton method:

M′(L)=arg min △E(C′(L)·M′(L),T(L)).M'(L)=arg min △E(C'(L)·M'(L),T(L)).

式中△E(A,B)为用于计算A和B之间的色差的函数;Where △E(A,B) is a function used to calculate the color difference between A and B;

同时,利用类似的方法,计算各个标定光源下的3×3颜色校正矩阵M(L)。M(L)与M′(L)的差别在于,M′(L)适用于根号多项式展开后的响应值矩阵C′(L),而M(L)适用于原始的响应值矩阵C(L)。At the same time, using a similar method, the 3×3 color correction matrix M(L) under each calibration light source is calculated. The difference between M(L) and M'(L) is that M'(L) is applicable to the response value matrix C'(L) after the root sign polynomial expansion, and M(L) is applicable to the original response value matrix C( L).

对于所有标定光源,采用如上方法计算得到各自的颜色校正矩阵M′(L)与M(L),并存储于相机内置存储器中。For all calibration light sources, the respective color correction matrices M'(L) and M(L) are calculated by the above method and stored in the built-in memory of the camera.

2.本发明对任一未知光源下拍摄的图像进行基于色适应模型的白平衡校正的过程如下:2. The present invention carries out the process of correcting the white balance based on the color adaptation model to the image taken under any unknown light source as follows:

手动设置或利用已有的自动白平衡算法获取该图像的白平衡校正增益系数 Manually set or use the existing automatic white balance algorithm to obtain the white balance correction gain coefficient of the image

计算该场景中光源在相机raw域上的RGB值:Calculate the RGB value of the light source in the scene on the camera's raw domain:

在相机平面上搜索与距离最近的标定光源L,并从相机内置存储器中调用其对应的颜色校正矩阵M′(L)。in camera Plane search with The nearest calibration light source L, and its corresponding color correction matrix M'(L) is called from the built-in memory of the camera.

利用颜色校正矩阵M′(L)将该场景光源下的完善反射表面的相机响应值转换至CIE1931 XYZ空间中:Use the color correction matrix M′(L) to transform the camera response value of the perfect reflective surface under the scene light source into the CIE1931 XYZ space:

使用CIECAM02色貌模型中的色适应变换CAT02计算物体色[Xill,Yill,Zill]经色适应后的标准光源下的对应色:Use the color adaptation transformation CAT02 in the CIECAM02 color appearance model to calculate the corresponding color of the object color [X ill , Y ill , Z ill ] under the standard light source after color adaptation:

式中,色适应变换模型fCAT02的四个输入依次是待计算的物体色三刺激值、待适应的光源三刺激值、参考光源三刺激值以及LA环境亮度因子。由于本发明需要计算测试光源经色适应后的感知颜色,其等价于计算测试光源下完善反射表面的对应色,故该模型的前两个输入均为测试光源的CIE1931 XYZ三刺激值。本实施例中选择CIE D65照明体作为标准照明体,故In the formula, the four inputs of the chromatic adaptation transformation model f CAT02 are the tristimulus value of the object color to be calculated, the tristimulus value of the light source to be adapted, the tristimulus value of the reference light source, and the L A environmental brightness factor. Since the present invention needs to calculate the perceived color of the test light source after chromatic adaptation, which is equivalent to calculating the corresponding color of the perfect reflective surface under the test light source, the first two inputs of the model are the CIE1931 XYZ tristimulus values of the test light source. In this embodiment, the CIE D65 illuminant is selected as the standard illuminant, so

环境亮度因子LA可综合考虑实际光源与参考光源的色品距离d以及场景照度E这两个因素。本发明中使用两个sigmoid函数对LA进行计算:The environmental brightness factor L A can comprehensively consider the two factors of the chromaticity distance d between the actual light source and the reference light source and the scene illuminance E. In the present invention, two sigmoid functions are used to calculate LA :

式中,光源色品距离d可通过计算实际光源与参考光源色品在CIELUV均匀颜色空间中的欧式距离获得,a1、b1、K1、a2、b2、K2作为调整sigmoid函数形状的待定参数,可根据实际需求进行标定。一种可行的环境亮度因子与d、E之间的对应关系如图3所示。In the formula, the light source chromaticity distance d can be obtained by calculating the Euclidean distance between the actual light source and the reference light source chromaticity in the CIELUV uniform color space, and a 1 , b 1 , K 1 , a 2 , b 2 , and K 2 are used as the adjusted sigmoid function The undetermined parameters of the shape can be calibrated according to actual needs. A possible corresponding relationship between the ambient brightness factor and d, E is shown in Figure 3.

最后,对该测试光源对应的3×3颜色校正矩阵M(L)求逆,并将色适应后的完善反射体三刺激值重新映射回相机RGB空间中:Finally, the 3×3 color correction matrix M(L) corresponding to the test light source is inverted, and the perfect reflector tristimulus value after color adaptation Remap back into camera RGB space:

由此,计算色适应后的白平衡校正增益系数:Thus, the white balance correction gain coefficient after color adaptation is calculated:

利用该增益系数对即可实现对图像进行更加符合人眼视觉感知的白平衡校正。By using the gain coefficient pair, the white balance correction of the image that is more in line with the visual perception of the human eye can be realized.

对某一测试光源进行色适应后的白平衡校正增益系数计算的流程图如图4所示。The flow chart of calculating the white balance correction gain coefficient after chromatic adaptation to a test light source is shown in FIG. 4 .

以上所述的实施例只是本发明的一种较佳的方案,然其并非用以限制本发明。有关技术领域的普通技术人员,在不脱离本发明的精神和范围的情况下,还可以做出各种变化和变型。因此凡采取等同替换或等效变换的方式所获得的技术方案,均落在本发明的保护范围内。The above-mentioned embodiment is only a preferred solution of the present invention, but it is not intended to limit the present invention. Various changes and modifications can be made by those skilled in the relevant technical fields without departing from the spirit and scope of the present invention. Therefore, all technical solutions obtained by means of equivalent replacement or equivalent transformation fall within the protection scope of the present invention.

Claims (6)

1.一种基于色适应模型的彩色数码相机白平衡校正方法,其特征在于,步骤如下:1. A color digital camera white balance correction method based on color adaptation model, it is characterized in that, the steps are as follows: S1:利用根号多项式回归颜色校正方法将不同标定光源下的设备相关响应值RGB转换至同一光源下设备无关的三刺激值CIE1931XYZ;S1: Convert the device-related response value RGB under different calibration light sources to the device-independent tristimulus value CIE1931XYZ under the same light source by using the root polynomial regression color correction method; S2:获取待校正光源下拍摄的图像的白平衡校正增益系数,计算待校正光源在平面上的坐标,在相机平面上搜索与该坐标距离最近的标定光源,调用该标定光源对应的颜色校正矩阵,将该光源的设备相关的相机响应值转换至CIE1931XYZ空间中,将光源颜色视为物体色;S2: Obtain the white balance correction gain coefficient of the image taken under the light source to be corrected, and calculate the Coordinates on the plane, at the camera Search the calibration light source closest to the coordinate on the plane, call the color correction matrix corresponding to the calibration light source, convert the device-related camera response value of the light source into the CIE1931XYZ space, and regard the light source color as the object color; S3:使用CIECAM02色貌模型中的色适应变换CAT02计算物体色经色适应后的标准光源下的对应色:S3: Use the color adaptation transformation CAT02 in the CIECAM02 color appearance model to calculate the corresponding color of the object color under the standard light source after color adaptation: S4:将对应色利用所述颜色校正矩阵的逆矩阵重新映射回相机RGB空间,并重新计算色适应后的白平衡校正增益系数。S4: Remap the corresponding color back to the RGB space of the camera using the inverse matrix of the color correction matrix, and recalculate the white balance correction gain coefficient after color adaptation. 2.如权利要求1所述的基于色适应模型的彩色数码相机白平衡校正方法,其特征在于,所述的S1具体为:2. the color digital camera white balance correction method based on color adaptation model as claimed in claim 1, is characterized in that, described S1 is specifically: S101:对于光谱功率分布为P(λ)的标定光源L,使用相机响应值构成模型计算标准色卡第i个色块在该光源照明下的相机RGB值ri、gi和biS101: For the calibration light source L whose spectral power distribution is P(λ), use the camera response value composition model to calculate the camera RGB values r i , g i and b i of the i-th color block of the standard color card under the illumination of the light source: <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msub> <mi>r</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>R</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>g</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>G</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>b</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>B</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msub> <mi>r</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>R</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>g</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>G</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>b</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>B</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> 式中ρi(λ)表示第i个色块的光谱反射比,Sk(λ)表示相机第k个通道的光谱灵敏度函数,k=R、G、B,Ω′为相机光谱响应的波长范围;对于有N个色块的标准色卡,计算得到一个N×3的相机响应值矩阵C(L),其中每一行对应一个色块的相机RGB值;In the formula, ρi (λ) represents the spectral reflectance of the i -th color block, S k (λ) represents the spectral sensitivity function of the k-th channel of the camera, k=R, G, B, and Ω′ is the wavelength of the spectral response of the camera Range; for a standard color card with N color blocks, an N×3 camera response value matrix C(L) is calculated, where each row corresponds to the camera RGB value of a color block; S102:计算该标定光源下完善反射表面的相机RGB值rill、gill和billS102: Calculate the camera RGB values r ill , g ill and b ill of the perfect reflective surface under the calibration light source: <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msup> <mi>r</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>R</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msup> <mi>g</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>G</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msup> <mi>b</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>B</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msup> <mi>r</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>R</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msup> <mi>g</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>G</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msup> <mi>b</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <msup> <mi>&amp;Omega;</mi> <mo>&amp;prime;</mo> </msup> </munder> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <msup> <mi>S</mi> <mi>B</mi> </msup> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> 并记录其在平面上的坐标 and record it in coordinates on the plane S103:对于光谱功率分布为P(λ)的标定光源,使用CIE1931 2°标准观察者色匹配函数计算标准色卡第i个色块在该光源照明下的CIE1931XYZ三刺激值:S103: For the calibration light source with spectral power distribution P(λ), use CIE1931 2° standard observer color matching function Calculate the CIE1931XYZ tristimulus value of the i-th color block of the standard color card under the illumination of this light source: <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msub> <mi>X</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <mi>&amp;Omega;</mi> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mover> <mi>x</mi> <mo>&amp;OverBar;</mo> </mover> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>Y</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <mi>&amp;Omega;</mi> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mover> <mi>y</mi> <mo>&amp;OverBar;</mo> </mover> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>Z</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <mi>&amp;Omega;</mi> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mover> <mi>z</mi> <mo>&amp;OverBar;</mo> </mover> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msub> <mi>X</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <mi>&amp;Omega;</mi> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mover> <mi>x</mi> <mo>&amp;OverBar;</mo> </mover> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>Y</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <mi>&amp;Omega;</mi> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mover> <mi>y</mi> <mo>&amp;OverBar;</mo> </mover> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msub> <mi>Z</mi> <mi>i</mi> </msub> <mo>=</mo> <munder> <mo>&amp;Integral;</mo> <mi>&amp;Omega;</mi> </munder> <msub> <mi>&amp;rho;</mi> <mi>i</mi> </msub> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>P</mi> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mover> <mi>z</mi> <mo>&amp;OverBar;</mo> </mover> <mrow> <mo>(</mo> <mi>&amp;lambda;</mi> <mo>)</mo> </mrow> <mi>d</mi> <mi>&amp;lambda;</mi> <mo>,</mo> </mrow> </mtd> </mtr> </mtable> </mfenced> 式中Ω为可见光的波长范围;对于有N个色块的标准色卡,计算得到一个N×3的三刺激值矩阵T(L),其中每一行对应一个色块的XYZ三刺激值;In the formula, Ω is the wavelength range of visible light; for a standard color card with N color blocks, an N×3 tristimulus value matrix T(L) is calculated, in which each row corresponds to the XYZ tristimulus value of a color block; S104:将相机响应值矩阵C(L)的维度由N×3扩展为N×q,q>3,其中第4~q列对应各个色块响应值的根号多项式;S104: Expand the dimension of the camera response value matrix C(L) from N×3 to N×q, q>3, wherein the 4th to q columns correspond to the root polynomials of the response values of each color block; S105:利用最小二乘法或其它以色差作为目标函数的校正矩阵优化方法,计算C′(L)转换至T(L)的6×3颜色校正矩阵M′(L):S105: Calculate the 6×3 color correction matrix M'(L) converted from C'(L) to T(L) by using the least square method or other correction matrix optimization methods with color difference as the objective function: <mrow> <msup> <mi>C</mi> <mo>&amp;prime;</mo> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <msup> <mi>M</mi> <mo>&amp;prime;</mo> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;cong;</mo> <mi>T</mi> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>,</mo> </mrow> <mrow> <msup> <mi>C</mi> <mo>&amp;prime;</mo> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <msup> <mi>M</mi> <mo>&amp;prime;</mo> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;cong;</mo> <mi>T</mi> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>,</mo> </mrow> 以C′(L)·M′(L)与T(L)之间的均方根误差作为优化目标时,采用伪逆法对M′(L)进行计算:When the root mean square error between C′(L)·M′(L) and T(L) is taken as the optimization target, the pseudo-inverse method is used to calculate M′(L): M′(L)=[C′T(L)C′(L)]-1C′T(L)·T(L),M'(L)=[C'T(L)C'(L)] -1 C'T (L)· T (L), 以C′(L)·M′(L)与T(L)之间的色差作为优化目标时,利用非线性优化方法对M′(L)进行计算:When the color difference between C'(L)·M'(L) and T(L) is used as the optimization target, the nonlinear optimization method is used to calculate M'(L): M′(L)=argmin△E(C′(L)·M′(L),T(L)),M'(L)=argmin△E(C'(L)·M'(L),T(L)), 式中△E(A,B)为用于计算A和B之间的色差的函数;Where △E(A,B) is a function used to calculate the color difference between A and B; S106:利用S105中的方法计算各个标定光源下的3×3颜色校正矩阵M(L);S106: Use the method in S105 to calculate the 3×3 color correction matrix M(L) under each calibration light source; S107:对于所有标定光源,采用S101~S106的方法计算得到各自的颜色校正矩阵M′(L)与M(L),并存储于相机内置存储器中。S107: For all the calibration light sources, calculate the respective color correction matrices M'(L) and M(L) by using the method of S101-S106, and store them in the built-in memory of the camera. 3.如权利要求1所述的基于色适应模型的彩色数码相机白平衡校正方法,其特征在于,所述的S2具体为:3. the color digital camera white balance correction method based on color adaptation model as claimed in claim 1, is characterized in that, described S2 is specifically: S201:手动设置或利用已有的自动白平衡算法获取待校正光源下拍摄的图像的白平衡校正增益系数 S201: Manually set or use the existing automatic white balance algorithm to obtain the white balance correction gain coefficient of the image shot under the light source to be corrected S202:计算待校正光源在相机raw域上的RGB值:S202: Calculate the RGB value of the light source to be corrected in the raw domain of the camera: <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <mfrac> <mn>1</mn> <msubsup> <mi>R</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>A</mi> <mi>W</mi> <mi>B</mi> </mrow> </msubsup> </mfrac> <mo>,</mo> </mtd> </mtr> <mtr> <mtd> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <mn>1</mn> <mo>,</mo> </mtd> </mtr> <mtr> <mtd> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <mfrac> <mn>1</mn> <msubsup> <mi>B</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>A</mi> <mi>W</mi> <mi>B</mi> </mrow> </msubsup> </mfrac> <mo>&amp;CenterDot;</mo> </mtd> </mtr> </mtable> </mfenced> <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <mfrac> <mn>1</mn> <msubsup> <mi>R</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>A</mi> <mi>W</mi> <mi>B</mi> </mrow> </msubsup> </mfrac> <mo>,</mo> </mtd> </mtr> <mtr> <mtd> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <mn>1</mn> <mo>,</mo> </mtd> </mtr> <mtr> <mtd> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>=</mo> <mfrac> <mn>1</mn> <msubsup> <mi>B</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>A</mi> <mi>W</mi> <mi>B</mi> </mrow> </msubsup> </mfrac> <mo>&amp;CenterDot;</mo> </mtd> </mtr> </mtable> </mfenced> 在相机平面上搜索与距离最近的标定光源L,并从相机内置存储器中调用其对应的颜色校正矩阵M′(L);in camera Plane search with The closest calibration light source L, and call its corresponding color correction matrix M'(L) from the camera's built-in memory; S203:利用颜色校正矩阵M′(L)将该场景光源下的完善反射表面的相机响应值转换至CIE1931XYZ空间中:S203: Transform the camera response value of the perfect reflective surface under the scene light source into CIE1931XYZ space by using the color correction matrix M′(L): <mrow> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>=</mo> <msup> <mi>M</mi> <mo>&amp;prime;</mo> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msqrt> <mrow> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> </mrow> </msqrt> <mo>,</mo> <msqrt> <mrow> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> </mrow> </msqrt> <mo>,</mo> <msqrt> <mrow> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> </mrow> </msqrt> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>.</mo> </mrow> <mrow> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>=</mo> <msup> <mi>M</mi> <mo>&amp;prime;</mo> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msqrt> <mrow> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> </mrow> </msqrt> <mo>,</mo> <msqrt> <mrow> <msup> <mi>G</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> </mrow> </msqrt> <mo>,</mo> <msqrt> <mrow> <msup> <mi>R</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <msup> <mi>B</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> </mrow> </msqrt> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>.</mo> </mrow> 式中Xill,Yill,Zill分别为XYZ空间中的三刺激值。In the formula, X ill , Y ill , Z ill are the tristimulus values in XYZ space, respectively. 4.如权利要求1所述的基于色适应模型的彩色数码相机白平衡校正方法,其特征在于,所述的S3具体为:4. the color digital camera white balance correction method based on color adaptation model as claimed in claim 1, is characterized in that, described S3 is specifically: 使用CIECAM02色貌模型中的色适应变换CAT02计算物体色[Xill,Yill,Zill]经色适应后的标准光源下的对应色:Use the color adaptation transformation CAT02 in the CIECAM02 color appearance model to calculate the corresponding color of the object color [X ill , Y ill , Z ill ] under the standard light source after color adaptation: <mrow> <msup> <mrow> <mo>&amp;lsqb;</mo> <msubsup> <mi>X</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Y</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Z</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>=</mo> <msub> <mi>f</mi> <mrow> <mi>C</mi> <mi>A</mi> <mi>T</mi> <mn>02</mn> </mrow> </msub> <mrow> <mo>(</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>r</mi> <mi>e</mi> <mi>f</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>r</mi> <mi>e</mi> <mi>f</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>r</mi> <mi>e</mi> <mi>f</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> <msub> <mi>L</mi> <mi>A</mi> </msub> <mo>)</mo> </mrow> <mo>,</mo> </mrow> <mrow> <msup> <mrow> <mo>&amp;lsqb;</mo> <msubsup> <mi>X</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Y</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Z</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>=</mo> <msub> <mi>f</mi> <mrow> <mi>C</mi> <mi>A</mi> <mi>T</mi> <mn>02</mn> </mrow> </msub> <mrow> <mo>(</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msup> <mi>X</mi> <mrow> <mi>r</mi> <mi>e</mi> <mi>f</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Y</mi> <mrow> <mi>r</mi> <mi>e</mi> <mi>f</mi> </mrow> </msup> <mo>,</mo> <msup> <mi>Z</mi> <mrow> <mi>r</mi> <mi>e</mi> <mi>f</mi> </mrow> </msup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> <msub> <mi>L</mi> <mi>A</mi> </msub> <mo>)</mo> </mrow> <mo>,</mo> </mrow> 式中色适应变换模型fCAT02的四个输入依次是待计算的物体色三刺激值、待适应的光源三刺激值、参考光源三刺激值以及环境亮度因子LAIn the formula, the four inputs of the color adaptation transformation model f CAT02 are the tristimulus value of the object color to be calculated, the tristimulus value of the light source to be adapted, the tristimulus value of the reference light source and the environmental brightness factor L A . 5.如权利要求4所述的基于色适应模型的彩色数码相机白平衡校正方法,其特征在于,所述的环境亮度因子使用两个sigmoid函数进行计算:5. the color digital camera white balance correction method based on color adaptation model as claimed in claim 4, is characterized in that, described environment brightness factor uses two sigmoid functions to calculate: <mrow> <msub> <mi>L</mi> <mi>A</mi> </msub> <mo>=</mo> <mfrac> <msub> <mi>K</mi> <mn>1</mn> </msub> <mrow> <mn>1</mn> <mo>+</mo> <msup> <mi>e</mi> <mrow> <mo>(</mo> <msub> <mi>a</mi> <mn>1</mn> </msub> <mi>d</mi> <mo>-</mo> <msub> <mi>b</mi> <mn>1</mn> </msub> <mo>)</mo> </mrow> </msup> </mrow> </mfrac> <mo>&amp;CenterDot;</mo> <mfrac> <msub> <mi>K</mi> <mn>2</mn> </msub> <mrow> <mn>1</mn> <mo>+</mo> <msup> <mi>e</mi> <mrow> <mo>(</mo> <msub> <mi>b</mi> <mn>2</mn> </msub> <mo>-</mo> <msub> <mi>a</mi> <mn>2</mn> </msub> <mi>E</mi> <mo>)</mo> </mrow> </msup> </mrow> </mfrac> <mo>,</mo> </mrow> <mrow> <msub> <mi>L</mi> <mi>A</mi> </msub> <mo>=</mo> <mfrac> <msub> <mi>K</mi> <mn>1</mn> </msub> <mrow> <mn>1</mn> <mo>+</mo> <msup> <mi>e</mi> <mrow> <mo>(</mo> <msub> <mi>a</mi> <mn>1</mn> </msub> <mi>d</mi> <mo>-</mo> <msub> <mi>b</mi> <mn>1</mn> </msub> <mo>)</mo> </mrow> </msup> </mrow> </mfrac> <mo>&amp;CenterDot;</mo> <mfrac> <msub> <mi>K</mi> <mn>2</mn> </msub> <mrow> <mn>1</mn> <mo>+</mo> <msup> <mi>e</mi> <mrow> <mo>(</mo> <msub> <mi>b</mi> <mn>2</mn> </msub> <mo>-</mo> <msub> <mi>a</mi> <mn>2</mn> </msub> <mi>E</mi> <mo>)</mo> </mrow> </msup> </mrow> </mfrac> <mo>,</mo> </mrow> 式中,光源色品距离d通过计算实际光源与参考光源色品在CIELUV均匀颜色空间中的欧式距离获得,a1、b1、K1、a2、b2、K2作为调整sigmoid函数形状的待定参数。In the formula, the light source chromaticity distance d is obtained by calculating the Euclidean distance between the actual light source and the reference light source chromaticity in the CIELUV uniform color space, and a 1 , b 1 , K 1 , a 2 , b 2 , and K 2 are used to adjust the shape of the sigmoid function The undetermined parameters of . 6.如权利要求3所述的基于色适应模型的彩色数码相机白平衡校正方法,其特征在于,所述的S4具体为:6. the color digital camera white balance correction method based on color adaptation model as claimed in claim 3, is characterized in that, described S4 is specifically: 对所述的标定光源L对应的3×3颜色校正矩阵M(L)求逆,并将色适应后的完善反射体三刺激值重新映射回相机RGB空间中:Invert the 3×3 color correction matrix M(L) corresponding to the calibration light source L, and use the perfect reflector tristimulus value after color adaptation Remap back into camera RGB space: <mrow> <msup> <mrow> <mo>&amp;lsqb;</mo> <msubsup> <mi>R</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>G</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>B</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>=</mo> <msup> <mi>M</mi> <mrow> <mo>-</mo> <mn>1</mn> </mrow> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msubsup> <mi>X</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Y</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Z</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> </mrow> <mrow> <msup> <mrow> <mo>&amp;lsqb;</mo> <msubsup> <mi>R</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>G</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>B</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>=</mo> <msup> <mi>M</mi> <mrow> <mo>-</mo> <mn>1</mn> </mrow> </msup> <mrow> <mo>(</mo> <mi>L</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <msup> <mrow> <mo>&amp;lsqb;</mo> <msubsup> <mi>X</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Y</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>,</mo> <msubsup> <mi>Z</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <mo>&amp;rsqb;</mo> </mrow> <mi>T</mi> </msup> <mo>,</mo> </mrow> 由此,计算色适应后的白平衡校正增益系数 From this, calculate the white balance correction gain coefficient after color adaptation <mrow> <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msubsup> <mi>R</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>C</mi> <mi>A</mi> <mi>T</mi> </mrow> </msubsup> <mo>=</mo> <mfrac> <msubsup> <mi>G</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <msubsup> <mi>R</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> </mfrac> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msubsup> <mi>B</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>C</mi> <mi>A</mi> <mi>T</mi> </mrow> </msubsup> <mo>=</mo> <mfrac> <msubsup> <mi>G</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <msubsup> <mi>B</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> </mfrac> </mrow> </mtd> </mtr> </mtable> </mfenced> <mo>.</mo> </mrow> 3 <mrow> <mfenced open = "{" close = ""> <mtable> <mtr> <mtd> <mrow> <msubsup> <mi>R</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>C</mi> <mi>A</mi> <mi>T</mi> </mrow> </msubsup> <mo>=</mo> <mfrac> <msubsup> <mi>G</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <msubsup> <mi>R</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> </mfrac> </mrow> </mtd> </mtr> <mtr> <mtd> <mrow> <msubsup> <mi>B</mi> <mrow> <mi>g</mi> <mi>a</mi> <mi>i</mi> <mi>n</mi> </mrow> <mrow> <mi>C</mi> <mi>A</mi> <mi>T</mi> </mrow> </msubsup> <mo>=</mo> <mfrac> <msubsup> <mi>G</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> <msubsup> <mi>B</mi> <mi>a</mi> <mrow> <mi>i</mi> <mi>l</mi> <mi>l</mi> </mrow> </msubsup> </mfrac> </mrow> </mtd> </mtr> </mtable> </mfenced> <mo>.</mo> </mrow> 3
CN201710442492.3A 2017-06-13 2017-06-13 Color digital camera white balance correcting based on chromatic adaptation model Expired - Fee Related CN107197225B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710442492.3A CN107197225B (en) 2017-06-13 2017-06-13 Color digital camera white balance correcting based on chromatic adaptation model

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710442492.3A CN107197225B (en) 2017-06-13 2017-06-13 Color digital camera white balance correcting based on chromatic adaptation model

Publications (2)

Publication Number Publication Date
CN107197225A true CN107197225A (en) 2017-09-22
CN107197225B CN107197225B (en) 2019-04-05

Family

ID=59877611

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710442492.3A Expired - Fee Related CN107197225B (en) 2017-06-13 2017-06-13 Color digital camera white balance correcting based on chromatic adaptation model

Country Status (1)

Country Link
CN (1) CN107197225B (en)

Cited By (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109035346A (en) * 2018-08-13 2018-12-18 北京中科慧眼科技有限公司 A kind of camera color calibration method, apparatus and automated driving system
CN109218698A (en) * 2018-10-19 2019-01-15 浙江大学 A kind of color digital camera color calibration method of high fault tolerance
CN110060308A (en) * 2019-03-28 2019-07-26 杭州电子科技大学 A kind of color constancy method based on light source colour distribution limitation
CN110276129A (en) * 2019-06-21 2019-09-24 贵州大学 Method, system and device for controlling fuel equivalence ratio supplied to combustion furnace based on combustion control system
CN110351537A (en) * 2019-07-31 2019-10-18 深圳前海达闼云端智能科技有限公司 White balance method, device, storage medium and the electronic equipment of Image Acquisition
CN110726536A (en) * 2019-09-25 2020-01-24 宁波永新光学股份有限公司 Color correction method for color digital reflection microscope
CN110751607A (en) * 2019-10-21 2020-02-04 浙江大华技术股份有限公司 Skin color correction method and device, storage medium and electronic device
CN110807812A (en) * 2019-09-29 2020-02-18 浙江大学 A system error calibration method for digital image sensor based on prior noise model
CN110807817A (en) * 2019-10-29 2020-02-18 长春融成智能设备制造股份有限公司 A Machine Vision Method for Target Color Recognition Adapting to Illumination Changes
CN110896452A (en) * 2018-09-13 2020-03-20 奇酷互联网络科技(深圳)有限公司 Flash lamp correction method of mobile terminal, mobile terminal and device
CN111008942A (en) * 2019-12-16 2020-04-14 吴成 Image processing method based on light change
CN111429827A (en) * 2020-03-19 2020-07-17 展讯通信(上海)有限公司 Display screen color calibration method and device, electronic equipment and readable storage medium
CN112714300A (en) * 2020-12-01 2021-04-27 南京理工大学 Color correction method based on spectral response under ultralow illumination
CN113487681A (en) * 2021-07-01 2021-10-08 浙江大学 Camera color calibration method based on spectral sensitivity curve and light source spectrum optimization
CN113628135A (en) * 2021-07-28 2021-11-09 Oppo广东移动通信有限公司 Image color correction method, image color correction device, computer device, and storage medium
CN113763257A (en) * 2020-11-13 2021-12-07 齐鲁工业大学 A fast extraction and transfer application method of color correction model
CN114902644A (en) * 2019-12-31 2022-08-12 皇家飞利浦有限公司 Method and system for full slide imaging
CN115100082A (en) * 2022-08-24 2022-09-23 浙江大学 A high-precision color display system based on a hyperspectral camera
WO2022199332A1 (en) * 2021-03-26 2022-09-29 Oppo广东移动通信有限公司 Color correction method, correctable display method, electronic device, and chip
CN115937207A (en) * 2023-01-09 2023-04-07 江苏恒力化纤股份有限公司 Image-based method for measuring color of dyed polyester fabric
CN116437060A (en) * 2021-12-31 2023-07-14 荣耀终端有限公司 An image processing method and related electronic equipment
EP4261771A4 (en) * 2021-12-31 2024-07-03 Honor Device Co., Ltd. IMAGE PROCESSING METHOD AND ASSOCIATED ELECTRONIC DEVICE
US12047689B2 (en) 2022-06-28 2024-07-23 Acer Incorporated White balance coefficient correction method and electronic device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007141737A (en) * 2005-11-21 2007-06-07 Sharp Corp LIGHTING DEVICE, LIQUID CRYSTAL DISPLAY DEVICE, LIGHTING DEVICE CONTROL METHOD, LIGHTING DEVICE CONTROL PROGRAM, AND RECORDING MEDIUM
CN101039439A (en) * 2007-04-23 2007-09-19 北京中星微电子有限公司 Method and apparatus for realizing correction of white balance
JP4960597B2 (en) * 2005-02-22 2012-06-27 キヤノン株式会社 White balance correction apparatus and method, and imaging apparatus
CN103200410A (en) * 2013-04-01 2013-07-10 上海富瀚微电子有限公司 White balance control method and white balance control device
CN103905803A (en) * 2014-03-18 2014-07-02 中国科学院国家天文台 Image color correcting method and device
CN104010176A (en) * 2014-03-26 2014-08-27 云南师范大学 A method of color correction from display to printer using human eyes

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4960597B2 (en) * 2005-02-22 2012-06-27 キヤノン株式会社 White balance correction apparatus and method, and imaging apparatus
JP2007141737A (en) * 2005-11-21 2007-06-07 Sharp Corp LIGHTING DEVICE, LIQUID CRYSTAL DISPLAY DEVICE, LIGHTING DEVICE CONTROL METHOD, LIGHTING DEVICE CONTROL PROGRAM, AND RECORDING MEDIUM
CN101039439A (en) * 2007-04-23 2007-09-19 北京中星微电子有限公司 Method and apparatus for realizing correction of white balance
CN103200410A (en) * 2013-04-01 2013-07-10 上海富瀚微电子有限公司 White balance control method and white balance control device
CN103905803A (en) * 2014-03-18 2014-07-02 中国科学院国家天文台 Image color correcting method and device
CN104010176A (en) * 2014-03-26 2014-08-27 云南师范大学 A method of color correction from display to printer using human eyes

Cited By (35)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109035346A (en) * 2018-08-13 2018-12-18 北京中科慧眼科技有限公司 A kind of camera color calibration method, apparatus and automated driving system
CN110896452A (en) * 2018-09-13 2020-03-20 奇酷互联网络科技(深圳)有限公司 Flash lamp correction method of mobile terminal, mobile terminal and device
CN109218698A (en) * 2018-10-19 2019-01-15 浙江大学 A kind of color digital camera color calibration method of high fault tolerance
CN110060308A (en) * 2019-03-28 2019-07-26 杭州电子科技大学 A kind of color constancy method based on light source colour distribution limitation
CN110060308B (en) * 2019-03-28 2021-02-02 杭州电子科技大学 A color constancy method based on light source color distribution constraints
CN110276129A (en) * 2019-06-21 2019-09-24 贵州大学 Method, system and device for controlling fuel equivalence ratio supplied to combustion furnace based on combustion control system
CN110276129B (en) * 2019-06-21 2022-11-29 贵州大学 Method, system and device for controlling fuel equivalence ratio supplied to combustion furnace based on combustion control system
CN110351537A (en) * 2019-07-31 2019-10-18 深圳前海达闼云端智能科技有限公司 White balance method, device, storage medium and the electronic equipment of Image Acquisition
CN110351537B (en) * 2019-07-31 2021-09-24 深圳前海达闼云端智能科技有限公司 White balance method and device for image acquisition, storage medium and electronic equipment
CN110726536A (en) * 2019-09-25 2020-01-24 宁波永新光学股份有限公司 Color correction method for color digital reflection microscope
CN110726536B (en) * 2019-09-25 2021-08-06 宁波永新光学股份有限公司 Color correction method for color digital reflection microscope
CN110807812A (en) * 2019-09-29 2020-02-18 浙江大学 A system error calibration method for digital image sensor based on prior noise model
CN110807812B (en) * 2019-09-29 2022-04-05 浙江大学 Digital image sensor system error calibration method based on prior noise model
CN110751607A (en) * 2019-10-21 2020-02-04 浙江大华技术股份有限公司 Skin color correction method and device, storage medium and electronic device
CN110807817A (en) * 2019-10-29 2020-02-18 长春融成智能设备制造股份有限公司 A Machine Vision Method for Target Color Recognition Adapting to Illumination Changes
CN110807817B (en) * 2019-10-29 2023-01-03 长春融成智能设备制造股份有限公司 Machine vision method for target color recognition adapting to illumination change
CN111008942A (en) * 2019-12-16 2020-04-14 吴成 Image processing method based on light change
CN114902644A (en) * 2019-12-31 2022-08-12 皇家飞利浦有限公司 Method and system for full slide imaging
CN111429827B (en) * 2020-03-19 2022-11-29 展讯通信(上海)有限公司 Display screen color calibration method and device, electronic equipment and readable storage medium
CN111429827A (en) * 2020-03-19 2020-07-17 展讯通信(上海)有限公司 Display screen color calibration method and device, electronic equipment and readable storage medium
CN113763257B (en) * 2020-11-13 2024-02-02 齐鲁工业大学 Quick extraction and migration application method of color correction model
CN113763257A (en) * 2020-11-13 2021-12-07 齐鲁工业大学 A fast extraction and transfer application method of color correction model
CN112714300A (en) * 2020-12-01 2021-04-27 南京理工大学 Color correction method based on spectral response under ultralow illumination
WO2022199332A1 (en) * 2021-03-26 2022-09-29 Oppo广东移动通信有限公司 Color correction method, correctable display method, electronic device, and chip
CN113487681B (en) * 2021-07-01 2022-10-04 浙江大学 Camera color calibration method based on spectral sensitivity curve and light source spectrum optimization
CN113487681A (en) * 2021-07-01 2021-10-08 浙江大学 Camera color calibration method based on spectral sensitivity curve and light source spectrum optimization
CN113628135A (en) * 2021-07-28 2021-11-09 Oppo广东移动通信有限公司 Image color correction method, image color correction device, computer device, and storage medium
CN116437060B (en) * 2021-12-31 2024-04-12 荣耀终端有限公司 Image processing method and related electronic equipment
CN116437060A (en) * 2021-12-31 2023-07-14 荣耀终端有限公司 An image processing method and related electronic equipment
EP4261771A4 (en) * 2021-12-31 2024-07-03 Honor Device Co., Ltd. IMAGE PROCESSING METHOD AND ASSOCIATED ELECTRONIC DEVICE
US12143732B2 (en) 2021-12-31 2024-11-12 Honor Device Co., Ltd. Image processing method and related electronic device
US12047689B2 (en) 2022-06-28 2024-07-23 Acer Incorporated White balance coefficient correction method and electronic device
CN115100082A (en) * 2022-08-24 2022-09-23 浙江大学 A high-precision color display system based on a hyperspectral camera
CN115937207B (en) * 2023-01-09 2023-08-01 江苏恒力化纤股份有限公司 Image type dyed polyester fabric color measurement method
CN115937207A (en) * 2023-01-09 2023-04-07 江苏恒力化纤股份有限公司 Image-based method for measuring color of dyed polyester fabric

Also Published As

Publication number Publication date
CN107197225B (en) 2019-04-05

Similar Documents

Publication Publication Date Title
CN107197225A (en) Color digital camera white balance correcting based on chromatic adaptation model
US10535125B2 (en) Dynamic global tone mapping with integrated 3D color look-up table
KR100866486B1 (en) Ambient light adaptive color correction device and method
CN110830778B (en) Imaging device color correction method, imaging device color correction device, electronic device and storage medium
CN113170028B (en) Method for generating image data of machine learning based imaging algorithm
CN101860761B (en) Correction method of color distortion of projected display images
CN109218698B (en) Color correction method of high-fault-tolerance color digital camera
CN109979382B (en) Color correction method and system for under-screen imaging system based on screen transmission spectrum
CN108600723A (en) A kind of color calibration method and evaluation method of panorama camera
US9961236B2 (en) 3D color mapping and tuning in an image processing pipeline
CN101953148A (en) Method for processing color image, color processing device and color processing program
US20090046171A1 (en) Non-linear color correction
US20090060326A1 (en) Image processing apparatus and method
JP2013527730A (en) Adaptive lens shading correction
CN103200409B (en) Color correction method of multi-projector display system
CN104581105B (en) Based on the auto white balance method of colour temperature range conversion weight map and the correction of block reliability
JP2016006954A (en) Color correction parameter calculation method, color correction parameter calculation device, and image output system
US20130154903A1 (en) Color correcting apparatus and method for color match between stereoscopic display devices
EP2205002A1 (en) Spectral characteristic correction device and spectral characteristic correction method
US8284260B2 (en) Optimal raw RGB determination for color calibration
US10937230B2 (en) Image processing
TWI513326B (en) Color correction method for high dynamic range synthetic image
CN117014733A (en) Shooting correction method, device and equipment
CN105812761B (en) The restoring method and terminal of a kind of color of image
KR100827128B1 (en) Imaging Method of Portable Imaging Device

Legal Events

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

Granted publication date: 20190405