JP2005045438A - Color conversion matrix calculation method and color correction method - Google Patents

Color conversion matrix calculation method and color correction method Download PDF

Info

Publication number
JP2005045438A
JP2005045438A JP2003201668A JP2003201668A JP2005045438A JP 2005045438 A JP2005045438 A JP 2005045438A JP 2003201668 A JP2003201668 A JP 2003201668A JP 2003201668 A JP2003201668 A JP 2003201668A JP 2005045438 A JP2005045438 A JP 2005045438A
Authority
JP
Japan
Prior art keywords
color
signal
matrix
hue
conversion matrix
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
JP2003201668A
Other languages
Japanese (ja)
Other versions
JP4136820B2 (en
Inventor
Toru Chiba
亨 千葉
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.)
Pentax Corp
Original Assignee
Pentax Corp
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 Pentax Corp filed Critical Pentax Corp
Priority to JP2003201668A priority Critical patent/JP4136820B2/en
Priority to US10/898,177 priority patent/US7586642B2/en
Publication of JP2005045438A publication Critical patent/JP2005045438A/en
Application granted granted Critical
Publication of JP4136820B2 publication Critical patent/JP4136820B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide a color conversion matrix capable of approximating a reproduced color with respect to a hue to an original color with high accuracy. <P>SOLUTION: A color conversion matrix calculation method obtains RGB signals of input colors Cin corresponding to a plurality of color patches by photographing a color chart and obtains RGB signals of target colors Cme from photometry values of each color patch, obtains a hue optimum matrix A_huew whereby the hue of the input colors Cin is coincident with the hue of the target colors Cme, obtains a saturation optimum matrix A_satw whereby the saturation of the input colors Cin is coincident with the saturation of the target colors Cme, and decides the product of the both to be a color conversion matrix A. The color conversion matrix calculation method obtains correction colors Ces by acting the color conversion matrix A on the input colors Cin, obtains a hue angle difference (θme-θes) between the correction colors Ces and the target colors Cme, and recognizes the color conversion matrix A to be effective when a square sum of the hue angle differences of all the color patches does not exceed a permissible value. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

【0001】
【発明の属する技術分野】
本発明は、被写体に対する再現カラー画像の色再現性を向上させるために色信号を補正する色補正方法、および色補正に用いる色変換マトリクスを算出する色変換マトリクス算出方法に関するものである。
【0002】
【従来の技術】
近年、画像の色情報を異なるメディア間で精度よく伝達するためにデジタル化することが多くなっており、例えばデジタルカメラやスキャナ等の画像入力装置は取り込んだ被写体のカラー画像を光の3原色のRGB信号に変換してこれをモニタやプリンタ等の画像出力装置に出力し、画像出力装置ではRGB信号に基づいてカラー画像を再現する(例えばモニタ画面に表示したり紙等に印刷する)ことが一般的に行われている。画像入力装置で得られるRGB信号は撮影レンズ等の光学系、カラーフィルタおよび撮像素子等の受光センサの撮像特性に依存し、また画像出力装置も再現の仕方によって同じRGB信号を入力しても再現される色が異なるだけでなく、画像入力装置および画像出力装置の特性にはそれぞれ固有の個体差が存在するため、RGB信号に基づく再現カラー画像は被写体に対する色再現性が悪い、即ち正確な色再現が行えない。
【0003】
そこで、近年では画像入力装置及び画像出力装置間で共通化したsRGB規格に準拠した色信号を採用することが多くなっており、画像入力装置では撮像系で得られるRGB信号をsRGB規格に応じて色補正し、これを出力している。これによりsRGB規格対応の画像出力装置では正確な色再現ができる、即ち同じRGB値が与えられれば近似した色味が再現できる。色補正の手法は様々であり、例えば撮像系に設ける光学フィルタの分光特性をsRGB規格に合わせる光学的な補正や、RGB信号をマトリクス演算する電子的な補正によって、再現色を本来の色に近似させている。
【0004】
従来、電子的な色補正で用いる色変換マトリクスの色変換精度を向上させる手法として重回帰分析法が提案されている。重回帰分析法は本来の色と再現色との関係を原因と結果ととらえた統計解析によってマトリクス要素を最適化する、即ち撮像系で得られたRGB信号に色変換マトリクスを作用させることにより予測した再現色と本来の色との信号レベル差が許容値以下となるようなマトリクス要素を求める手法であり、例えば特許文献1には3原色のRGB信号を異なる表色系のXYZ信号に変換するためのマトリクスを重回帰分析により求める技術が示されている。
【0005】
【特許文献1】
特開平10−164381号公報
【0006】
再現色と本来の色との一致の度合いは、人間の生理的色感に応じた色相、彩度および明度の3つの要素で評価することが通常である。特に色相の差は人間には色味の違いとして認識され易い。しかしながら、RGB信号は色相と線形的な関係にないため、上述した重回帰分析の精度の評価が難しいという問題がある。即ちRGB信号の信号レベル差が許容値範囲内にあっても、人間の目にとって異なる色に認識される程度の色相の差が生じることがある。
【0007】
【発明が解決しようとする課題】
本発明は上記問題点に鑑みて成されたものであり、特に色相に関して再現色を本来の色に高精度に近似できる色変換マトリクスを得ることを課題としている。
【0008】
【課題を解決するための手段】
本発明の色変換マトリクス算出方法は、第1色空間の任意の色信号を第2色空間の色信号に変換するための色変換マトリクスを算出する方法であって、色変換マトリクスが第1マトリクスと第2マトリクスとの積であり、彩度および色相が段階的に変化する複数のカラーパッチに各々対応する第1色空間の色信号を第1説明変数群とし、カラーパッチの各々に対応し第2色空間の色相に関する第1目標色信号を第1目的変数群とし、第1マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、第1説明変数群と第1目的変数群とに基づく重回帰分析により第1マトリクスの要素が求められ、カラーパッチに各々対応する第1色空間の色信号に第1マトリクスを作用させることにより得られた色相補正色信号を第2説明変数群とし、カラーパッチの各々に対応し第2色空間の彩度に関する第2目標色信号を第2目的変数群とし、第2マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、第2説明変数群と第2目的変数群とに基づく重回帰分析により第2マトリクスの要素が求められることを特徴とする。
【0009】
上記色変換マトリクス算出方法において、カラーパッチに対応する第1色空間の色信号、色相補正色信号、第1目標色信号および第2目標色信号は、色の一致度の評価の際にCIE−L均等色空間における色信号に変換されることが好ましい。また、例えば彩度に関する目標色信号がカラーパッチの測色信号であり、第1目標色信号がCIE−L色空間において座標原点と第2目標色信号の点とを結んだ直線に対して第1目標色信号を正射影した点が示す色信号であってもよい。
【0010】
上記色変換マトリクス算出方法で用いられるカラーパッチは、例えばマクベスカラーチェッカーの18色の有彩色カラーパッチであり、この場合18色の有彩色カラーパッチに対応する第1色空間の色信号は、マクベスカラーチェッカーの6色の無彩色カラーパッチに対応する第1色空間の色信号に基づいてホワイトバランス補正が施されることが好ましい。
【0011】
上記色変換マトリクス算出方法において、例えば第1色空間の色信号はカラーフィルタを設けた撮像素子によって得られた3原色RGB信号であり、第2色空間の色信号がsRGB(スタンダード・レッド・グリーン・ブルー)信号である。
【0012】
また、本発明に係る色補正方法は、画像の第1色空間における任意の色の色信号を色変換マトリクスを用いて第2の色空間における色信号に変換する色補正方法であって、色変換マトリクスが、第1マトリクスと第2マトリクスとの積であり、彩度および色相が段階的に変化する複数のカラーパッチに各々対応する第1色空間の色信号を第1説明変数群とし、カラーパッチの各々に対応し第2色空間の色相に関する第1目標色信号を第1目的変数群とし、第1マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、第1説明変数群と第1目的変数群とに基づく重回帰分析により第1マトリクスの要素が求められ、カラーパッチに各々対応する第1色空間の色信号に第1マトリクスを作用させることにより得られた色相補正色信号を第2説明変数群とし、カラーパッチの各々に対応し第2色空間の彩度に関する第2目標色信号を第2目的変数群とし、第2マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、第2説明変数群と第2目的変数群とに基づく重回帰分析により第2マトリクスの要素が求められることを特徴とする。
【0013】
【発明の実施の形態】
以下、本発明の実施形態について添付図面を参照して説明する。
【0014】
図1は、本発明の色変換マトリクス算出方法および色変換方法の実施形態を示す模式図である。
【0015】
デジタルカメラ10は、撮像素子により被写体のフルカラー画像を得る画像入力装置であり、撮影光学系12と、撮像素子、例えばRGB3原色のカラーチップフィルタ16が撮像面上に設けられた単板式のCCD14とを備える。撮影光学系12により撮像素子に結像された光学的被写体像はCCD14により光電変換された後CCD14から読み出されてアナログ信号処理を受けた後A/D変換され、1フレーム分のRAWデータとしてデジタル信号処理回路20に送られる。
【0016】
デジタル信号処理回路20では、RAWデータから画素毎のRGB信号を生成する色分解処理、白色基準値に応じてR、GおよびBのゲインを調整するホワイトバランス補正処理、第1色空間の色信号である原色RGB信号の色域をsRGB規格で定義された色域に変換することにより再現色を目的の色(例えば被写体本来の色)に近づけるための色補正処理、およびモニタ装置30のγ特性を相殺する様に階調を調整する階調補正処理等を順次施して、第2色空間の色信号であるsRGB信号を生成する。デジタル信号処理回路20は、sRGB信号をUSBケーブル等のインターフェース(図示せず)を介して外部装置、例えばパーソナルコンピュータに接続されたモニタ装置30(CRTディスプレイモニタまたはLCDモニタ)やプリンタ等(図示せず)の画像出力装置に出力できる。
【0017】
sRGB信号はIEC規定の色再現国際規格に準拠した信号であり、sRGB規格では標準のCRTディスプレイモニタ装置に応じて色再現性および色域が規定されている。この場合、ホワイトバランス補正処理においては白基準値がCIE−D65に定められ、色補正処理においてはRGB信号の色域が定義された色域に補正され、階調補正処理においてはγ値が2.2に定められる。
【0018】
デジタル信号処理回路20ではsRGB規格に準じて信号が処理されるが、撮像系(撮影光学系12、CCD14、RGBカラーチップフィルタ16等)にはsRGB規格に準拠した特性値をもつ素子が用いられているわけではなく、このため、被写体の色情報をsRGB規格に合わせて正確に撮ることができず、再現色が本来の色と一致しない現象が生じる。この現象を回避するために撮像系の感度特性をsRGB規格に一致させるための光学的な補正が成されているが十分ではなく、完全に一致させることは実質上困難である。このため、撮像系で得られたRGB信号の信号レベルを調節して電子的に補正するが、撮像系の感度特性は個々のデジタルカメラ10によって異なり、被写体本来の色情報とデジタルカメラ10により得られる色情報との関係に規則性がないことから両者の関係を理論的に定義することは困難であり、個々の色毎に異なる信号処理をしなければならない。R、GおよびB信号が8ビットデータである場合には色数は(2=167777216となり、全色に最適な色補正処理を行うことは現実的ではない。
【0019】
そこで、彩度および色相が段階的に変化する複数の色サンプルから成るカラーチャート、例えば、図1に示すマクベスカラーチャート(登録商標)40の24色のカラーパッチP〜P24(図1では24色のカラーパッチの一部のみに符号を付す)を、色彩計等により正確に測色するとともに個々のデジタルカメラ10によって測色時と同じ照明環境下で撮影し、撮影で得られたRGB信号を測色したRGB信号に一致させるような色変換マトリクスをそれぞれ求めておき、デジタルカメラ10に設定する。被写体を撮影したときには、デジタル信号処理回路20はこの色変換マトリクスによって色補正処理を行っている。これにより測色値に忠実な色再現が行える。
【0020】
色変換マトリクスは外部の色変換マトリクス算出装置34、例えばパーソナルコンピュータにより算出され、予めデジタルカメラ10のメモリ22に格納される。一方、デジタルカメラ10は、色変換マトリクスを算出するためにマクベスカラーチャート40を撮影して得られるRAWデータを、デジタル信号処理回路20から色変換マトリクス算出装置34に出力する。色変換マトリクスは、デジタルカメラ10の製造工程の終段において色変換マトリクス算出装置34との協働によって求められる3×3のマトリクスであり、個々のデジタルカメラ10の撮像系の色感度特性に応じて9個のマトリクス要素の値が定められる。
【0021】
RAWデータから得られる所定の色を入力色Cin、色変換マトリクスをA、色変換マトリクスAによる色補正処理後の色を補正色Cesと定義すると、それぞれのRGB信号Cin(Rin,Gin,Bin)およびCes(Res,Ges,Bes)について下記の(1)式に示す線形1次式が成り立つ。この(1)式と等価なマトリクス要素による表現式を(2)式に示す。a〜aは色変換マトリクスAのマトリクス要素である。
【0022】
【数1】

Figure 2005045438
【0023】
なお、本実施形態では正確な色再現を行うことを目的としているため、色変換マトリクスAを算出する際に設定される目標値はカラーパッチP〜P24の測色信号であるが、人物の肌色や青空の色等のよく使われる特定色を、正確な色ではなく使用者の望む色に再現する場合には、特定色に関して測色信号を修正した値を目標値に設定してもよい。なお、測色によるRGB信号は、色彩計でR、GおよびBの信号レベルを直接測定して得る他、例えば分光光度計によって分光反射率を測定する、または色彩計によってRGB表色系と異なる表色系で表現されたXYZ信号やL信号を測定して、分光反射率、XYZ信号またはL信号をRGB信号に変換して得てもよい。
【0024】
マクベスカラーチャート40は、市販の既製品であるため手に入れ易く、各カラーパッチP〜P24の測色信号が既知であり測色の手間が省ける。例えば、標準光の照明環境下のもとでの第1番のカラーパッチP(色名;暗い肌色)の測色信号は、x=0.4002、y=0.3504およびY=10.05であり、これら測色信号x、yおよびYを公知の変換式によってRGB信号に変換することができる。ただし、x=X/(X+Y+Z)、y=Y/(X+Y+Z)であり、X、YおよびZはXYZ表色系における三刺激値である。第1〜18番のカラーパッチP〜P18は有彩色であり、最終列の第19〜24番のカラーパッチP19〜P24は無彩色である。
【0025】
なお、カラーチャートとしては本実施形態のマクベスカラーチャートに限らず、複数のカラーパッチが均等色空間上に一様に分布するものであればよく、例えばJIS標準色標でもよい。マクベスカラーチャート40に基づいて得た色変換マトリクスは、各カラーパッチP〜P24の色については精度良く色再現できるが、他の色については保障されない。従って、良く使用される特定色(人物の肌色、青空の色、緑など)をカラーパッチにした独自のカラーチャートを作成しておけば、特定色について特に忠実に色再現できることになる。
【0026】
図2および図3を参照して、色変換マトリクス算出方法について説明する。図2には、色温度が6504Kの昼光を代表する標準の光CIE−D65を照明用光源とするCIE−L色空間(以下、Lab色空間と記載する)が示され、このLab色空間において、所定の1色に関する入力色Cinと、補正すべき目標の色Cme(以下、目標色と記載する)とがそれぞれ点で示されている。目標色CmeのL信号は測色で得られた値に設定される。図3は、色変換マトリクス算出処理の処理流れおよび各種色信号の関係を模式的に示すブロック図である。
【0027】
マトリクス演算では色はRGB信号で扱われるが、色の一致度の評価ではL信号で扱われる。これは、Lab色空間が人間の色知覚と座標上の距離との相関性が良好な均等色空間であることによる。図2に示すLab色空間においては、明度を表すL、色相および彩度を示すa、bの座標により任意の色を表すことができる。明度指数Lは任意の色の相対的な明るさや暗さを示し、黒の0%から白の100%の範囲である。色相はa平面における座標原点周りの角度で示され、0°から360°の範囲である。a軸において正の数字が大きくなる程赤が強くなり、負の数字が大きくなるほど緑が強くなる。b軸において正の数字が大きくなる程黄が強くなり、負の数字が大きくなるほど青が強くなる。また、座標原点からの距離が大きくなるほど彩度が高く、鮮やかな色になる。座標原点は無彩色である。
【0028】
RGB信号からL信号への変換は下記に示す公知の(3)式および(4)式により行う。(3)式はRGB信号をXYZ信号に変換するための変換式であり、(4)式はXYZ信号をL信号に変換するための変換式である。色の一致度の評価時にはRGB信号はRGB→XYZ→L変換によりL信号に変換され、マトリクス演算の時にはL信号はL→XYZ→RGB変換によりRGB信号に戻される。L→XYZ→RGB変換は(3)式および(4)式を変形した変換式により行われ、ここではその式は省略する。
【0029】
【数2】
Figure 2005045438
【0030】
【数3】
Figure 2005045438
【0031】
本実施形態では、カラーパッチP〜P18の18色について入力色Cinから予測した補正色Cesがそれぞれ対応する目標色Cmeに色相が一致するように色変換マトリクスAを最適化した後、彩度が一致するように最適化する。補正色Cesと目標色Cmeとの一致の度合いは、Lab色空間における両者の色相角θesおよびθmeの差によって評価する。色相角θ(θesおよびθme)はa面に下ろした点のa軸からの原点周りの回転角であり、下記の(5)式により定義される。色相角θesおよびθmeはそれぞれのa座標およびb座標を(5)式に代入して求められる。人間の知覚では、色相が異なる方が彩度が異なる場合に比べて別の色として認識され易いので、本実施形態では色相を優先的に一致させている。
【0032】
【数4】
Figure 2005045438
【0033】
まず、色相を合わせるために、Lab色空間において座標原点と目標色Cmeとを結ぶ直線L上に入力色Cinを正射影した点の色を色相最適化目標色Cme’に設定し、その色相最適化目標色Cme’のL信号をL→XYZ→RGB変換してRGB信号を求める処理を18色についてそれぞれ行い、18色の入力色Cinをそれぞれ対応する色相最適化目標色Cme’に一致させるための色相最適化マトリクスAhuew(第1マトリクス)を重回帰分析により求める。色相最適化目標色Cme’のRGB信号は色相に関する第1目標色信号である。直線Lは目標色Cmeと色相が同じ色の点の集合であり、入力色Cinを直線L上に正射影した点の色Cme’(以下、色相最適化目標色と記載する)は、目標色Cmeと色相が同じであってなおかつ入力色Cinに対してLab空間での距離が最も近い色である。即ち目標色を色相最適化目標色Cme’にすれば、Lab色空間において最短移動距離で色相を合わせることができる。なお、図2には1色のみが代表して示される。個々の入力色Cinに色相最適化マトリクスAhuewを作用させて得られる色相補正色Ces’は、対応する色相最適化目標色Cme’に略一致する。
【0034】
次に、彩度を合わせるために、18色の色相補正色Ces’をそれぞれ対応する目標色Cmeに一致させるための彩度最適化マトリクスAsatw(第2マトリクス)を重回帰分析により求める。目標色CmeのRGB信号は彩度に関する第2目標色信号である。個々の色相補正色Ces’に彩度最適化マトリクスAsatwを作用させて得られる補正色Cesは、対応する目標色Cmeに略一致する。
【0035】
入力色Cinを補正色Cesに変換するための色変換マトリクスAは、下記の(6)式に示すように、目標色Cmeに色相を近似させるための色相最適化マトリクスAhuewと、目標色Cmeに彩度を近似させるための彩度最適化マトリクスAsatwとの積により求められる。(6)式と等価なマトリクス要素による表現式を(7)式に示す。(7)式におけるa’〜a’は色相最適化マトリクスAhuewのマトリクス要素であり、a”〜a”は彩度最適化マトリクスAsatwのマトリクス要素である。
【0036】
【数5】
Figure 2005045438
【0037】
従って、入力色Cinを色変換マトリクスAによって補正色Cesに変換するということは、入力色Cinを補正色Cesに対して色相を一致させた後に彩度を一致させるということと同等である((8)式を参照)。
【数6】
Figure 2005045438
【0038】
次に、図4〜図6のフローチャートを参照して、色変換マトリクス算出処理について詳細に説明する。
【0039】
まずステップS102において、24色のカラーパッチP〜P24を有するマクベスカラーチャート40を用意し、これら24個のカラーパッチP〜P24をCIE−D65の照明光源下でデジタルカメラ10により撮影し、得られたRAWデータを色変換マトリクス算出装置34に転送する。
【0040】
色変換マトリクス算出装置34は、RAWデータに基づいて18個の有彩色カラーパッチP〜P18に対応する入力色CinのRGB信号を得る(ステップS104)。ここで、個々の有彩色カラーパッチP〜P18に対応する色データを区別するために、有彩色カラーパッチP〜P18の順番を示すパラメータk(k=1、2、…、18)を設定し、k番目のカラーパッチPに対応する入力色をCin(k)、そのRGB信号を(Rin(k),Gin(k),Bin(k))で表す。入力色Cin(k)のRGB信号(Rin(k),Gin(k),Bin(k))は、カラーパッチPに相当する撮像領域から抽出された30×30画素のR、GおよびBの信号レベルのそれぞれの平均値(以下、RGB平均値と記載する)であり、8ビットデータである。RGB平均値の信頼性を高めるために、30×30画素のうち欠陥画素などは取り除かれる。なお、RGB信号(Rin(k),Gin(k),Bin(k))は10ビットデータまたは12ビットデータであってもよい。
【0041】
マクベスカラーチャート40の第19〜24番のカラーパッチP19〜P24は6段階の無彩色カラーパッチであり、詳しくは第19番のカラーパッチP19(色名;白色)、第20番のカラーパッチP20(色名;グレイ8)、第21番のカラーパッチP21(色名;グレイ6.5)、第22番のカラーパッチP22(色名;グレイ5)、第23番のカラーパッチP23(色名;グレイ3.5)、第24番のカラーパッチP24(色名;黒色)から成る。
【0042】
これら無彩色の6個のカラーパッチP19〜P24はグレー階調の補正に用いられる。具体的には、各カラーパッチP19〜P24にそれぞれ相当する撮像領域から抽出された30×30画素のRGB平均値が求められ、6つの無彩色カラーパッチP19〜P24のRGB平均値とそれぞれの目標値(例えば測色信号)との誤差が最小となるようなオフセット値がR、GおよびBのそれぞれについて求められる。ステップS104で有彩色カラーパッチP(k=1、2、…、18)の入力色Cin(k)のRGB信号(Rin(k),Gin(k),Bin(k))を得る前に、RAWデータのR、GおよびB信号からそれぞれオフセット値が差し引かれ、これにより画像の白基準レベルおよび黒基準レベルが補正されるとともに、グレー階調、即ち色の濃さが適切なレベルに補正される。なお、階調はγ=1.0で正規化されたものである。
【0043】
また、6個の無彩色カラーパッチP19〜P24は、ホワイトバランス補正にも用いられ、RAWデータから得られる各無彩色カラーパッチP19〜P24のRGB平均値に基づいて、R、GおよびBのゲインがそれぞれ決定され、18個の有彩色カラーパッチP〜P18のRGB平均値がゲイン調整される。
【0044】
従って、ステップS104で得られる18色の有彩色カラーパッチP(k=1、2、…、18)の入力色Cin(k)のRGB信号(Rin(k),Gin(k),Bin(k))は、グレー階調補正およびホワイトバランス補正が施され、γ=1.0で正規化されたものである。
【0045】
また、ステップS106において既知である18個のカラーパッチP〜P18の測色信号(RGB信号)を色変換マトリクス算出装置34に入力する。なお、入力したデータが、RGB信号でない場合、例えばXYZ信号、L信号、分光反射率等の場合には公知の変換式によりRGB信号に変換しておく。また、測色信号の値が未知の場合には、ステップS106の前に撮影と同じ照明環境下でカラーパッチP〜P18を測色する。
【0046】
そして次のステップS108において、k番目(k=1、2、…、18)のカラーパッチPの目標色をCme(k)、そのRGB信号を(Rme(k),Gme(k),Bme(k))と定義し、ステップS106で得られた測色信号を目標色Cme(k)のRGB信号(Rme(k),Gme(k),Bme(k))に設定する。本実施形態では正確な色再現を行うことを目的としているので、測色信号を目標色Cme(k)のRGB信号(Rme(k),Gme(k),Bme(k))としているが、特定色を好ましい色に再現することを目的とする場合などでは、目的に応じて任意にRme(k)、Gme(k)、Bme(k)の値を変更する。なお、ステップS106およびS108は次のステップS110の前であればいつ行ってもよい。
【0047】
ステップS110では、ステップS104で得られた18色の入力色Cin(k)のRGB信号(Rin(k),Gin(k),Bin(k))(k=1、2、…、18)を、RGB→XYZ→L変換((3)式および(4)式)によりL信号に変換する。同様に、ステップS108で得られた18色の目標色Cme(k)のRGB信号(Rme(k),Gme(k),Bme(k))(k=1、2、…、18)をL信号に変換する。
【0048】
ステップS112では、18色についてそれぞれ色相最適化目標色Cme’(1)〜Cme’(18)を設定し、それらのL信号を求める。即ち、Lab色空間においてk番目(k=1、2、…、18)の目標色Cme(k)と座標原点とを結ぶ直線上に入力色Cin(k)を正射影した点を色相最適化目標色Cme’(k)に設定し、そのL座標を求める。そして、ステップS114において、色相最適化目標色Cme’(1)〜Cme’(18)のL信号をそれぞれL→XYZ→RGB変換し、RGB信号(Rme’(1),Gme’(1),Bme’(1))〜(Rme’(18),Gme’(18),Bme’(18))を求める。
【0049】
ステップS120では、18色の入力色Cin(1)〜Cin(18)のRGB信号を説明変数群とし、18色の色相最適化目標色Cme’(1)〜Cme’(18)のRGB信号を目的変数群とし、色相最適化マトリクスAhuewのマトリクス要素a’〜a’を偏回帰係数とする重回帰モデルを構築して重回帰分析を行い、ステップS122において色相最適化マトリクスAhuewのマトリクス要素a’〜a’を求める。
【0050】
この重回帰モデルでは、入力色Cin(1)〜Cin(18)のRGB信号および色相最適化目標色Cme’(1)〜Cme’(18)のRGB信号を各々列ベクトルとするマトリクスBin、Bme’と、偏回帰係数から成る色相最適化マトリクスAhuewとの間で、18色について(9)式に示す線形1次式が成立するものと仮定する。(9)式と等価なマトリクス要素による表現式を(10)式に示す。
【0051】
【数7】
Figure 2005045438
【0052】
色相最適化マトリクスAhuewは公知の最小二乗法などの最適化により求める。即ち、上述の重回帰モデル式において左辺(色相最適化目標色Cme’(1)〜Cme’(18)のRGB値)と、右辺(入力色Cin(1)〜Cin(18)に色相最適化マトリクスAhuewさせて得られるRGB値)とは、実際には一致せず、誤差が存在する。そこで、右辺と左辺の誤差の2乗和を最小にすることを条件として(9)式を(11)式に変形し、(11)式を解いて偏回帰係数Ahuewを求める。「( )」は転置行列を示し、「( )−1」は逆行列を示す。
【数8】
Figure 2005045438
【0053】
重回帰分析が終了し色相最適化マトリクスAhuewが得られると、続くステップS124〜S130において得られた色相最適化マトリクスAhuewの有効性が評価される。
【0054】
ステップS124において、入力色Cin(1)〜Cin(18)のRGB信号をそれぞれ色相最適化マトリクスAhuewで変換することにより色相補正色Ces’(1)〜Ces’(18)のRGB信号(Res(1),Ges(1),Bes(1))〜(Res(18),Ges(18),Bes(18))をそれぞれ求め((12)式を参照)、ステップS126において(3)式および(4)式のRGB→XYZ→L変換により、色相補正色Ces’(1)〜Ces’(18)のL信号を求める。
【数9】
Figure 2005045438
【0055】
ステップS128では、ステップS112で設定された色相最適化目標色Cme’(1)〜Cme’(18)のL信号と、ステップS126で得られた色相補正色Ces’(1)〜Ces’(18)のL信号とに基づいて、色相誤差θrmsを求める。詳述すると、k番目の色について色相最適化目標色Cme’(k)のL信号から(5)式により色相角θme’(k)を求めるとともに色相補正色Ces’(k)のL信号から(5)式により色相角θes’(k)を求める処理を、k=1、2、…、18について行い、18色の色相角θme’(k)およびθes’(k)の差の2乗和を求め、これを色相誤差θrmsとする((13)式を参照)。
【0056】
【数10】
Figure 2005045438
【0057】
ステップS130では、色相誤差θrmsが許容値α以下であるか否かが判定され、色相誤差θrmsが許容値αを超えた場合はステップS108に戻り、目標色Cme(1)〜Cme(18)のRGB信号のいずれかを変更して新たに色相最適化マトリクスAhuewを求める。なお、ステップS108に戻って目標色Cme(1)〜Cme(18)のRGB信号を再設定する際は、色相の変化が僅かとなるように、即ちモニタ装置30における再現色の色味が被写体本来の色と変わらないように、各値が定められることが必要である。
【0058】
ステップS130において色相誤差θrmsが許容値α以下であると判定された場合には、入力色Cinを目標色Cmeに対して色相に関して高精度に近似できる色相最適化マトリクスAhuewが得られたと見做され、彩度最適化マトリクスAsatwを求めるためのステップS140〜S144が実行される。
【0059】
ステップS140では色相だけでなく彩度を合わせるための重回帰モデルを構築し、重回帰分析を行う。この重回帰モデルは(14)式に示されるように、ステップS124で求められた18色の色相補正色Ces’(1)〜Ces’(18)のRGB信号が説明変数群であり、ステップS108で設定された18色の彩度最適化目標色Cme(1)〜Cme(18)が目的変数群である。(14)式のBinは色相補正色Ces’(1)〜Ces’(18)を各々列ベクトルとするマトリクスであり、Bmeは彩度最適化目標色Cme(1)〜Cme(18)を各々列ベクトルとするマトリクスである。ステップS142では求められた偏回帰係数a”〜a”を彩度最適化マトリクスAsatwのマトリクス要素に定める。彩度最適化マトリクスAsatwの求め方はステップS120〜S122の色相最適化マトリクスAhuewの求め方と同じであり、詳述しない。
【数11】
Figure 2005045438
【0060】
ステップS142で彩度最適化マトリクスAsatwが得られると、ステップS144において前述の(6)式((7)式)により色変換マトリクスAを算出する。そして、ステップS146において入力色Cin(1)〜Cin(18)のRGB信号をそれぞれ色変換マトリクスAで変換することにより補正色Ces(1)〜Ces(18)のRGB信号(Res(1),Ges(1),Bes(1))〜(Res(18),Ges(18),Bes(18))を求め(上述の(1)式および(2)式を参照)、ステップS148において(3)式および(4)式のRGB→XYZ→L変換により、補正色Ces(1)〜Ces(18)のL信号を求め、ステップS150において補正色Ces(1)〜Ces(18)と目標色Cme(1)〜Cme(18)との色相誤差θrmsを求める。ステップS150の色相誤差θrmsの求め方はステップS128の色相誤差θrmsの求め方と同じであり、説明を省略する。
【0061】
次のステップS152では、色相誤差θrmsが許容値α以下であるか否かが判定され、色相誤差θrmsが許容値αを超えた場合はステップS108に戻り、色相誤差θrmsが許容値α以下であると判定された場合には、入力色Cinを目標色Cmeに対して色相および彩度に関して高精度に近似できる色変換マトリクスAが得られたと見做され、ステップS154において色変換マトリクスAの係数が現在の値に確定し、ステップS156において色変換マトリクス算出装置34からデジタルカメラ10へ色変換マトリクスAの係数データを転送してメモリ22に書き込んで終了する。
【0062】
以上のように求められた色変換マトリクスAをデジタルカメラ10の色補正処理で用いると、特に色相について測色信号に忠実な色再現ができるsRGB信号を得ることができ、モニタ装置30の画面に被写体本来の色に極めて近い色味で被写体像を表示できる。
【0063】
このように、本実施形態では色相差を色味の違いとして捕らえ易い人間の視覚特性を考慮した色補正処理を行うことができる。即ち、色補正に用いる色変換マトリクスAを2つのマトリクス、即ち色相を目標色Cmeに一致させる色相最適化マトリクスAhuewと彩度を目標色Cmeに一致させるAsatwとの積により求め、それぞれのマトリクスを個別に重回帰分析によって求めている。これにより、補正色Cesを目標色Cmeに対して色相を優先的に一致させることができ、モニタ装置30において被写体本来の色に極めて近い色味を再現することができる。
【0064】
上記の重回帰モデルでは各色について補正色Cesと目標色Cmeとの色相角差がほぼ均等にばらつくが、肌色等の特定色に限定して色相一致の精度を向上させたい場合には、ステップS120およびステップS140の重回帰分析を行う前に、目的変数群となる色相最適化目標色Cme’(1)〜Cme’(18)および目標色Cme(1)〜Cme(18)に重み付けをする。即ち、18色についてそれぞれ設定した重みW(k)(k=1,2,…18)と色相最適化目標色Cme’(k)との積、および重みW(k)と目標色Cme(k)との積を目的変数群として重回帰分析を行う。(15)式には色相最適化目標色Cme’(1)〜Cme’(18)に重み付けをして色相を一致させるための重回帰モデル式が示され、(16)式には目標色Cme(1)〜Cme(18)に重み付けをして彩度を一致させるための重回帰モデル式が示される。Wは18色の重みW(k)を要素とするマトリクスであり、重みW(1)〜W(18)の総和は1である。この重み付けにより、重みを大きくした特定色ほど、より忠実な色再現を行うことができる。
【数12】
Figure 2005045438
【0065】
なお、画像入力装置としては本実施形態のデジタルカメラ10の他、デジタルビデオカメラ、スキャナであってもよい。また、本実施形態では色変換マトリクス算出装置34をデジタルカメラ10と別体にしているが、デジタルカメラ10に色変換マトリクス算出機能を搭載してもよい。またさらに、色変換マトリクスを算出するとともに色補正できる画像処理ソフトウェアとしてパーソナルコンピュータにインストールし、デジタルカメラ10から出力されたRAWデータをパーソナルコンピュータで色補正できるように構成してもよい。
【0066】
本実施形態では、撮像系で得られたRGB信号をsRGB規格に合わせて色補正する色変換マトリクスを求めているが、本発明のマトリクス算出方法は特に色補正を目的とする色変換マトリクスの算出に限定されない。例えば異なる色空間の色信号を相互変換する(RGB信号をXYZ信号や印刷のためのcmy信号に変換する等)ための色変換マトリクスの算出にも適用できる。
【0067】
【発明の効果】
以上説明したように、本発明によると、色相に関して再現色を本来の色に高精度に近似できる色変換マトリクスを得ることができる。
【図面の簡単な説明】
【図1】本発明の色変換マトリクス算出方法および色変換方法の実施形態を示す図であって、色変換を行うデジタルカメラと、色変換マトリクスを算出する色変換マトリクス算出装置とを示すブロック図である。
【図2】色変換マトリクス算出の原理を示す図であって、所定の色に関してLab色空間における変換前の入力色と変換すべき目標色との位置を示す図である。
【図3】色変換マトリクス算出処理の処理流れおよび各種色信号の関係を模式的に示すブロック図である。
【図4】色変換マトリクス算出処理を示すフローチャートの第1の部分である。
【図5】色変換マトリクス算出処理を示すフローチャートの第2の部分である。
【図6】色変換マトリクス算出処理を示すフローチャートの最後の部分である。
【符号の説明】
10 デジタルカメラ
20 デジタル信号処理回路
30 モニタ装置
34 色変換マトリクス算出装置
40 カラーチャート[0001]
BACKGROUND OF THE INVENTION
The present invention relates to a color correction method for correcting a color signal to improve the color reproducibility of a reproduced color image for a subject, and a color conversion matrix calculation method for calculating a color conversion matrix used for color correction.
[0002]
[Prior art]
In recent years, image color information is often digitized in order to accurately transmit it between different media. For example, an image input device such as a digital camera or a scanner converts a captured subject's color image into three primary colors of light. An RGB signal is converted and output to an image output device such as a monitor or printer, and the image output device reproduces a color image based on the RGB signal (for example, displayed on a monitor screen or printed on paper). Generally done. The RGB signal obtained by the image input device depends on the imaging characteristics of the optical system such as the photographic lens, the light receiving sensor such as the color filter and the image sensor, and the image output device also reproduces even if the same RGB signal is input depending on the reproduction method In addition to the differences in the colors to be reproduced, there are inherent individual differences in the characteristics of the image input device and the image output device. Therefore, the reproduced color image based on the RGB signal has poor color reproducibility with respect to the subject, that is, an accurate color. Cannot reproduce.
[0003]
Therefore, in recent years, color signals conforming to the sRGB standard commonly used between the image input device and the image output device are often used. In the image input device, the RGB signal obtained by the imaging system is used in accordance with the sRGB standard. Color correction is performed and this is output. As a result, an accurate color reproduction can be performed with an image output device compliant with the sRGB standard, that is, an approximate color can be reproduced if the same RGB values are given. There are various color correction methods. For example, the optical color provided in the imaging system approximates the reproduced color to the original color by optical correction that matches the spectral characteristics of the optical filter to the sRGB standard, or electronic correction that performs matrix operation on the RGB signal. I am letting.
[0004]
Conventionally, a multiple regression analysis method has been proposed as a technique for improving the color conversion accuracy of a color conversion matrix used in electronic color correction. Multiple regression analysis optimizes matrix elements by statistical analysis that captures the relationship between the original color and reproduced color as the cause and result, that is, predicts by applying a color conversion matrix to the RGB signal obtained in the imaging system This is a technique for obtaining a matrix element such that the signal level difference between the reproduced color and the original color is less than an allowable value. For example, Patent Document 1 converts RGB signals of three primary colors into XYZ signals of different color systems. The technique which calculates | requires the matrix for this by multiple regression analysis is shown.
[0005]
[Patent Document 1]
Japanese Patent Laid-Open No. 10-164381
[0006]
In general, the degree of coincidence between the reproduced color and the original color is evaluated by three factors of hue, saturation, and brightness according to human physiological color sense. In particular, the difference in hue is easily recognized as a difference in color by humans. However, since the RGB signal does not have a linear relationship with the hue, there is a problem that it is difficult to evaluate the accuracy of the multiple regression analysis described above. That is, even if the signal level difference of the RGB signals is within the allowable value range, a difference in hue that can be recognized as a different color by human eyes may occur.
[0007]
[Problems to be solved by the invention]
The present invention has been made in view of the above problems, and it is an object of the present invention to obtain a color conversion matrix capable of approximating a reproduced color to an original color with high accuracy, particularly with respect to hue.
[0008]
[Means for Solving the Problems]
The color conversion matrix calculation method of the present invention is a method for calculating a color conversion matrix for converting an arbitrary color signal in the first color space into a color signal in the second color space, and the color conversion matrix is the first matrix. And the second matrix, and color signals in the first color space corresponding to a plurality of color patches whose saturation and hue change stepwise are defined as a first explanatory variable group and correspond to each of the color patches. A multiple regression model is constructed in which the first target color signal relating to the hue of the second color space is the first objective variable group, and the elements of the first matrix are the partial regression coefficients, and the first explanatory variable group, the first objective variable group, The element of the first matrix is obtained by the multiple regression analysis based on the color correction, and the hue correction color signal obtained by applying the first matrix to the color signal of the first color space corresponding to each color patch is used as the second explanatory variable group. And A multiple regression model is constructed in which the second target color signal relating to the saturation of the second color space corresponding to each of the patches is the second objective variable group, and the elements of the second matrix are the partial regression coefficients, and the second explanatory variable group And an element of the second matrix is obtained by multiple regression analysis based on the second objective variable group.
[0009]
In the color conversion matrix calculation method, the color signal of the first color space, the hue correction color signal, the first target color signal, and the second target color signal corresponding to the color patch are converted into CIE- L * a * b * It is preferable that the color signal is converted into a color signal in a uniform color space. Further, for example, the target color signal related to saturation is a colorimetric signal of a color patch, and the first target color signal is CIE-L. * a * b * It may be a color signal indicated by a point obtained by orthogonally projecting the first target color signal with respect to a straight line connecting the coordinate origin and the point of the second target color signal in the color space.
[0010]
The color patches used in the color conversion matrix calculation method are, for example, 18 chromatic color patches of the Macbeth color checker. In this case, the color signal of the first color space corresponding to the 18 chromatic color patches is the Macbeth color patch. It is preferable that the white balance correction is performed based on the color signal of the first color space corresponding to the six achromatic color patches of the color checker.
[0011]
In the color conversion matrix calculation method, for example, the color signal in the first color space is an RGB signal of three primary colors obtained by an image sensor provided with a color filter, and the color signal in the second color space is sRGB (standard red green).・ Blue) Signal.
[0012]
The color correction method according to the present invention is a color correction method for converting a color signal of an arbitrary color in the first color space of an image into a color signal in the second color space using a color conversion matrix, The conversion matrix is a product of the first matrix and the second matrix, and color signals in the first color space respectively corresponding to a plurality of color patches whose chroma and hue change stepwise are defined as a first explanatory variable group. A multiple regression model is constructed in which the first target color signal relating to the hue of the second color space corresponding to each of the color patches is the first objective variable group, and the elements of the first matrix are the partial regression coefficients. Hue correction color obtained by applying the first matrix to the color signal of the first color space corresponding to each color patch, the elements of the first matrix being obtained by multiple regression analysis based on the first objective variable group and the first objective variable group Signal A multiple regression model is constructed in which an explanatory variable group, a second target color signal relating to the saturation of the second color space corresponding to each of the color patches is a second objective variable group, and an element of the second matrix is a partial regression coefficient. The elements of the second matrix are obtained by multiple regression analysis based on the second explanatory variable group and the second objective variable group.
[0013]
DETAILED DESCRIPTION OF THE INVENTION
Embodiments of the present invention will be described below with reference to the accompanying drawings.
[0014]
FIG. 1 is a schematic diagram showing an embodiment of a color conversion matrix calculation method and a color conversion method according to the present invention.
[0015]
The digital camera 10 is an image input device that obtains a full-color image of a subject using an image sensor, and includes a photographing optical system 12 and a single-plate CCD 14 in which an image sensor, for example, a color chip filter 16 of RGB three primary colors is provided on the imaging surface. Is provided. The optical object image formed on the image sensor by the photographing optical system 12 is photoelectrically converted by the CCD 14, read out from the CCD 14, subjected to analog signal processing, A / D converted, and RAW data for one frame. It is sent to the digital signal processing circuit 20.
[0016]
The digital signal processing circuit 20 performs color separation processing for generating RGB signals for each pixel from RAW data, white balance correction processing for adjusting R, G, and B gains according to white reference values, and color signals in the first color space. The color correction processing for bringing the reproduced color closer to the target color (for example, the original color of the subject) by converting the color gamut of the primary color RGB signal as described above into the color gamut defined by the sRGB standard, and the γ characteristic of the monitor device 30 A gradation correction process for adjusting the gradation so as to cancel out is sequentially performed to generate an sRGB signal that is a color signal of the second color space. The digital signal processing circuit 20 converts the sRGB signal into an external device such as a personal computer via an interface (not shown) such as a USB cable, a monitor device 30 (CRT display monitor or LCD monitor), a printer, etc. (not shown). To the image output device.
[0017]
The sRGB signal is a signal conforming to the IEC-stipulated international color reproduction standard, and the sRGB standard defines color reproducibility and color gamut according to a standard CRT display monitor device. In this case, in the white balance correction process, the white reference value is CIE-D. 65 In the color correction process, the color gamut of the RGB signal is corrected to the defined color gamut, and in the gradation correction process, the γ value is set to 2.2.
[0018]
The digital signal processing circuit 20 processes signals according to the sRGB standard, but an element having a characteristic value conforming to the sRGB standard is used for the imaging system (the photographing optical system 12, the CCD 14, the RGB color chip filter 16, etc.). For this reason, the color information of the subject cannot be accurately taken in accordance with the sRGB standard, and the reproduced color does not match the original color. In order to avoid this phenomenon, optical correction for matching the sensitivity characteristic of the image pickup system to the sRGB standard has been performed, but it is not sufficient, and it is substantially difficult to make it completely match. For this reason, the signal level of the RGB signal obtained by the imaging system is adjusted and electronically corrected. However, the sensitivity characteristics of the imaging system vary depending on the individual digital camera 10 and are obtained by the original color information of the subject and the digital camera 10. Since there is no regularity in the relationship with the color information to be obtained, it is difficult to theoretically define the relationship between the two, and different signal processing must be performed for each color. When the R, G, and B signals are 8-bit data, the number of colors is (2 8 ) 3 = 167777216, and it is not realistic to perform color correction processing optimal for all colors.
[0019]
Therefore, a color chart composed of a plurality of color samples whose saturation and hue change stepwise, for example, a 24-color patch P of the Macbeth Color Chart (registered trademark) 40 shown in FIG. 1 ~ P 24 (In FIG. 1, only a part of the 24 color patches are provided with reference numerals), the color is accurately measured by a colorimeter or the like, and the individual digital cameras 10 are photographed in the same lighting environment as the color measurement. A color conversion matrix that matches the obtained RGB signal with the colorimetric RGB signal is obtained and set in the digital camera 10. When the subject is photographed, the digital signal processing circuit 20 performs color correction processing using this color conversion matrix. Thereby, color reproduction faithful to the colorimetric value can be performed.
[0020]
The color conversion matrix is calculated by an external color conversion matrix calculation device 34, for example, a personal computer, and is stored in the memory 22 of the digital camera 10 in advance. On the other hand, the digital camera 10 outputs RAW data obtained by photographing the Macbeth color chart 40 to calculate the color conversion matrix from the digital signal processing circuit 20 to the color conversion matrix calculation device 34. The color conversion matrix is a 3 × 3 matrix obtained in cooperation with the color conversion matrix calculation device 34 at the final stage of the manufacturing process of the digital camera 10, and corresponds to the color sensitivity characteristics of the imaging system of each digital camera 10. Nine matrix element values are determined.
[0021]
When a predetermined color obtained from RAW data is defined as an input color Cin, a color conversion matrix A is defined as a color, and a color after color correction processing by the color conversion matrix A is defined as a corrected color Ces, the respective RGB signals Cin (Rin, Gin, Bin) As for Ces (Res, Ges, Bes), the linear linear expression shown in the following expression (1) holds. An expression using a matrix element equivalent to the expression (1) is shown in an expression (2). a 1 ~ A 9 Are matrix elements of the color conversion matrix A.
[0022]
[Expression 1]
Figure 2005045438
[0023]
In this embodiment, since the purpose is to perform accurate color reproduction, the target value set when calculating the color conversion matrix A is the color patch P. 1 ~ P 24 The colorimetric signal was corrected for the specific color when reproducing the frequently used specific color such as human skin color or blue sky color instead of the exact color. The value may be set as a target value. Note that RGB signals obtained by colorimetry are obtained by directly measuring R, G, and B signal levels with a colorimeter, for example, measuring spectral reflectance with a spectrophotometer, or different from the RGB color system with a colorimeter. XYZ signal and L expressed in color system * a * b * Measure signal, spectral reflectance, XYZ signal or L * a * b * The signal may be obtained by converting it into an RGB signal.
[0024]
The Macbeth color chart 40 is a commercially available off-the-shelf product that is easy to obtain. 1 ~ P 24 The colorimetric signal is already known and the colorimetry is saved. For example, the first color patch P under a standard light illumination environment 1 The colorimetric signals of (color name; dark skin color) are x = 0.4002, y = 0.3504, and Y = 10.05, and these colorimetric signals x, y, and Y are converted into RGB signals by a known conversion formula. Can be converted to However, x = X / (X + Y + Z), y = Y / (X + Y + Z), and X, Y, and Z are tristimulus values in the XYZ color system. 1st to 18th color patch P 1 ~ P 18 Is a chromatic color and the 19th-24th color patch P in the last row 19 ~ P 24 Is achromatic.
[0025]
The color chart is not limited to the Macbeth color chart of the present embodiment, and may be any color chart in which a plurality of color patches are uniformly distributed in a uniform color space. For example, a JIS standard color standard may be used. The color conversion matrix obtained on the basis of the Macbeth color chart 40 represents each color patch P 1 ~ P 24 The colors of can be accurately reproduced, but other colors are not guaranteed. Therefore, if a unique color chart using specific colors (such as human skin color, blue sky color, and green) that are often used as color patches is created, the specific colors can be reproduced particularly faithfully.
[0026]
The color conversion matrix calculation method will be described with reference to FIGS. FIG. 2 shows a standard light CIE-D representing daylight with a color temperature of 6504K. 65 CIE-L with light source for illumination * a * b * A color space (hereinafter referred to as “Lab color space”) is shown. In this Lab color space, an input color Cin relating to a predetermined color and a target color Cme (hereinafter referred to as “target color”) to be corrected are displayed. Each is indicated by a dot. L of target color Cme * a * b * The signal is set to a value obtained by colorimetry. FIG. 3 is a block diagram schematically showing the flow of the color conversion matrix calculation process and the relationship between various color signals.
[0027]
In matrix operation, colors are handled as RGB signals, but in the evaluation of color matching, L * a * b * Treated with a signal. This is because the Lab color space is a uniform color space in which the correlation between human color perception and coordinate distance is good. In the Lab color space shown in FIG. * A, indicating hue and saturation * , B * Any color can be expressed by the coordinates of. Lightness index L * Indicates the relative brightness or darkness of an arbitrary color, and ranges from 0% black to 100% white. Hue is a * b * It is indicated by an angle around the coordinate origin in the plane, and is in the range of 0 ° to 360 °. a * The larger the positive number on the axis, the stronger red, and the larger the negative number, the stronger green. b * The larger the positive number on the axis, the stronger yellow, and the larger the negative number, the stronger blue. Further, the greater the distance from the coordinate origin, the higher the saturation and the brighter the color. The coordinate origin is achromatic.
[0028]
RGB signal to L * a * b * Conversion to a signal is performed by the following known equations (3) and (4). Equation (3) is a conversion equation for converting RGB signals to XYZ signals, and Equation (4) is an XYZ signal converted to L * a * b * It is a conversion formula for converting into a signal. When evaluating the degree of color matching, RGB signals are RGB → XYZ → L * a * b * L by conversion * a * b * Converted to a signal and L for matrix operation * a * b * The signal is L * a * b * → XYZ → RGB signals are converted back to RGB signals. L * a * b * → XYZ → RGB conversion is performed by a conversion expression obtained by modifying Expressions (3) and (4), and the expression is omitted here.
[0029]
[Expression 2]
Figure 2005045438
[0030]
[Equation 3]
Figure 2005045438
[0031]
In this embodiment, the color patch P 1 ~ P 18 The color conversion matrix A is optimized so that the hues of the correction colors Ces predicted from the input color Cin for the 18 colors correspond to the corresponding target colors Cme, and then the saturation is optimized. The degree of coincidence between the correction color Ces and the target color Cme is evaluated by the difference between the hue angles θes and θme in the Lab color space. Hue angle θ (θes and θme) is a * b * A on the surface * The rotation angle around the origin from the axis, which is defined by the following equation (5). The hue angles θes and θme are respectively a * Coordinates and b * It is obtained by substituting the coordinates into equation (5). In human perception, a different hue is more easily recognized as a different color than a case where the saturation is different, and therefore the hue is preferentially matched in this embodiment.
[0032]
[Expression 4]
Figure 2005045438
[0033]
First, in order to match the hue, the color of the point obtained by orthogonally projecting the input color Cin on the straight line L connecting the coordinate origin and the target color Cme in the Lab color space is set as the hue optimization target color Cme ′, and the hue optimization is performed. L of target color Cme ' * a * b * L signal * a * b * → XYZ → RGB conversion to obtain RGB signals for each of the 18 colors, and a hue optimization matrix A for matching the 18 input colors Cin with the corresponding hue optimization target colors Cme ′ A hue (first matrix) is obtained by multiple regression analysis. The RGB signal of the hue optimization target color Cme ′ is the first target color signal related to the hue. A straight line L is a set of points having the same hue as the target color Cme, and a color Cme ′ (hereinafter referred to as a hue optimization target color) obtained by orthogonally projecting the input color Cin onto the straight line L is a target color. It is a color having the same hue as Cme and the closest distance in the Lab space with respect to the input color Cin. That is, if the target color is set to the hue optimization target color Cme ′, the hue can be matched with the shortest moving distance in the Lab color space. FIG. 2 shows only one color as a representative. Hue optimization matrix A for each input color Cin The hue correction color Ces ′ obtained by applying hue substantially matches the corresponding hue optimization target color Cme ′.
[0034]
Next, a saturation optimization matrix A for matching the 18 hue correction colors Ces ′ with the corresponding target color Cme in order to match the saturation. The satw (second matrix) is obtained by multiple regression analysis. The RGB signal of the target color Cme is a second target color signal related to saturation. Saturation optimization matrix A for each hue correction color Ces' The correction color Ces obtained by applying satw substantially matches the corresponding target color Cme.
[0035]
The color conversion matrix A for converting the input color Cin to the correction color Ces is a hue optimization matrix A for approximating the hue to the target color Cme as shown in the following equation (6). Saturation optimization matrix A for approximating saturation to hue and target color Cme It is obtained by product with satw. An expression using matrix elements equivalent to Expression (6) is shown in Expression (7). A ′ in the formula (7) 1 ~ A ' 9 Is a hue optimization matrix A a matrix element of hue, a " 1 ~ A " 9 Is saturation optimization matrix A It is a matrix element of satw.
[0036]
[Equation 5]
Figure 2005045438
[0037]
Therefore, converting the input color Cin to the correction color Ces by the color conversion matrix A is equivalent to matching the saturation after the hue of the input color Cin is matched to the correction color Ces (( (See 8)).
[Formula 6]
Figure 2005045438
[0038]
Next, the color conversion matrix calculation process will be described in detail with reference to the flowcharts of FIGS.
[0039]
First, in step S102, the 24-color patch P 1 ~ P 24 The Macbeth color chart 40 having the above is prepared, and these 24 color patches P are prepared. 1 ~ P 24 CIE-D 65 Then, the RAW data obtained by the digital camera 10 is transferred to the color conversion matrix calculation device 34.
[0040]
The color conversion matrix calculation device 34 calculates 18 chromatic color patches P based on the RAW data. 1 ~ P 18 RGB signals of the input color Cin corresponding to are obtained (step S104). Here, each chromatic color patch P 1 ~ P 18 In order to distinguish the color data corresponding to the chromatic color patch P 1 ~ P 18 Is set to a parameter k (k = 1, 2,..., 18) indicating the order of the kth color patch P k The input color corresponding to is represented by Cin (k), and the RGB signal is represented by (Rin (k), Gin (k), Bin (k)). The RGB signal (Rin (k), Gin (k), Bin (k)) of the input color Cin (k) is the color patch P k Is an average value (hereinafter referred to as RGB average value) of R, G, and B signal levels of 30 × 30 pixels extracted from the imaging region corresponding to the 8-bit data. In order to increase the reliability of the RGB average value, defective pixels are removed from 30 × 30 pixels. The RGB signals (Rin (k), Gin (k), Bin (k)) may be 10-bit data or 12-bit data.
[0041]
19th-24th color patch P of Macbeth color chart 40 19 ~ P 24 Is a 6-stage achromatic color patch. For details, refer to the 19th color patch P 19 (Color name: White), 20th color patch P 20 (Color name: Gray 8), 21st color patch P 21 (Color name: Gray 6.5), 22nd color patch P 22 (Color name: Gray 5), 23rd color patch P 23 (Color name: Gray 3.5), 24th color patch P 24 (Color name; black).
[0042]
These six achromatic color patches P 19 ~ P 24 Is used for correction of gray gradation. Specifically, each color patch P 19 ~ P 24 The RGB average values of 30 × 30 pixels extracted from the imaging regions corresponding to each of the six achromatic color patches P are obtained. 19 ~ P 24 An offset value that minimizes an error between the RGB average value and each target value (for example, a colorimetric signal) is obtained for each of R, G, and B. In step S104, the chromatic color patch P k Before obtaining RGB signals (Rin (k), Gin (k), Bin (k)) of the input color Cin (k) of (k = 1, 2,..., 18), R, G, and B of the RAW data are obtained. The offset value is subtracted from each signal, thereby correcting the white reference level and the black reference level of the image, and correcting the gray gradation, that is, the color density to an appropriate level. The gradation is normalized by γ = 1.0.
[0043]
Six achromatic color patches P 19 ~ P 24 Is also used for white balance correction, and each achromatic color patch P obtained from RAW data 19 ~ P 24 R, G, and B gains are determined based on the RGB average values of the eighteen chromatic color patches P. 1 ~ P 18 The RGB average values are adjusted for gain.
[0044]
Accordingly, the 18 chromatic color patches P obtained in step S104. k The RGB signals (Rin (k), Gin (k), Bin (k)) of the input color Cin (k) of (k = 1, 2,..., 18) are subjected to gray gradation correction and white balance correction. , Γ = 1.0.
[0045]
In addition, the 18 color patches P known in step S106. 1 ~ P 18 These colorimetric signals (RGB signals) are input to the color conversion matrix calculation device 34. If the input data is not an RGB signal, for example, an XYZ signal, L * a * b * In the case of a signal, spectral reflectance, etc., it is converted into an RGB signal by a known conversion formula. If the value of the colorimetric signal is unknown, the color patch P is used in the same lighting environment as that for photographing before step S106. 1 ~ P 18 Measure the color.
[0046]
In the next step S108, the kth (k = 1, 2,..., 18) color patch P k Is defined as Cme (k), and its RGB signals are defined as (Rme (k), Gme (k), Bme (k)), and the colorimetric signal obtained in step S106 is the target color Cme (k). Set to RGB signals (Rme (k), Gme (k), Bme (k)). Since the present embodiment aims to perform accurate color reproduction, the colorimetric signal is an RGB signal (Rme (k), Gme (k), Bme (k)) of the target color Cme (k). When the purpose is to reproduce a specific color as a preferable color, the values of Rme (k), Gme (k), and Bme (k) are arbitrarily changed according to the purpose. Steps S106 and S108 may be performed at any time before the next step S110.
[0047]
In step S110, the RGB signals (Rin (k), Gin (k), Bin (k)) (k = 1, 2,..., 18) of the 18 input colors Cin (k) obtained in step S104 are obtained. , RGB → XYZ → L * a * b * L by transformation (equations (3) and (4)) * a * b * Convert to signal. Similarly, the RGB signals (Rme (k), Gme (k), Bme (k)) (k = 1, 2,..., 18) of the 18 target colors Cme (k) obtained in step S108 are set to L. * a * b * Convert to signal.
[0048]
In step S112, hue optimization target colors Cme ′ (1) to Cme ′ (18) are set for 18 colors, and their L values are set. * a * b * Find the signal. That is, the hue optimization is performed at a point obtained by orthogonally projecting the input color Cin (k) on the straight line connecting the kth (k = 1, 2,..., 18) target color Cme (k) and the coordinate origin in the Lab color space. Set to target color Cme '(k) * a * b * Find the coordinates. In step S114, the hue optimization target colors Cme ′ (1) to Cme ′ (18) L * a * b * Each signal is L * a * b * → XYZ → RGB conversion to obtain RGB signals (Rme ′ (1), Gme ′ (1), Bme ′ (1)) to (Rme ′ (18), Gme ′ (18), Bme ′ (18)) .
[0049]
In step S120, the RGB signals of the 18 input colors Cin (1) to Cin (18) are used as explanatory variable groups, and the RGB signals of the 18 hue optimization target colors Cme ′ (1) to Cme ′ (18) are obtained. Hue optimization matrix A as objective variable group hue matrix element a ' 1 ~ A ' 9 A multiple regression model having a partial regression coefficient is constructed and a multiple regression analysis is performed. In step S122, the hue optimization matrix A is calculated. hue matrix element a ' 1 ~ A ' 9 Ask for.
[0050]
In this multiple regression model, matrices Bin and Bme each having column signals of RGB signals of input colors Cin (1) to Cin (18) and RGB signals of hue optimization target colors Cme ′ (1) to Cme ′ (18), respectively. 'And a hue optimization matrix A consisting of partial regression coefficients It is assumed that the linear linear expression shown in Expression (9) is established for 18 colors with respect to hue. Expression (10) is an expression using matrix elements equivalent to expression (9).
[0051]
[Expression 7]
Figure 2005045438
[0052]
Hue optimization matrix A The hue is obtained by optimization such as a known least square method. That is, hue optimization is performed on the left side (RGB values of hue optimization target colors Cme ′ (1) to Cme ′ (18)) and the right side (input colors Cin (1) to Cin (18)) in the multiple regression model equation described above. Matrix A (RGB values obtained by doing hue) do not actually match, and there is an error. Therefore, on the condition that the square sum of the error between the right side and the left side is minimized, the formula (9) is transformed into the formula (11), and the partial regression coefficient A is solved by solving the formula (11). Find hue. "() t ”Indicates a transposed matrix, and“ () -1 "Indicates an inverse matrix.
[Equation 8]
Figure 2005045438
[0053]
Multiple regression analysis is completed and hue optimization matrix A When hue is obtained, the hue optimization matrix A obtained in subsequent steps S124 to S130. The effectiveness of hue is evaluated.
[0054]
In step S124, the RGB signals of the input colors Cin (1) to Cin (18) are converted into the hue optimization matrix A, respectively. RGB signals (Res (1), Ges (1), Bes (1)) to (Res (18), Ges (18) of hue correction colors Ces ′ (1) to Ces ′ (18) by converting with hue. , Bes (18)) (see equation (12)), and in step S126, RGB → XYZ → L of equations (3) and (4) * a * b * By conversion, the hue correction colors Ces ′ (1) to Ces ′ (18) L * a * b * Find the signal.
[Equation 9]
Figure 2005045438
[0055]
In step S128, L of the hue optimization target colors Cme ′ (1) to Cme ′ (18) set in step S112. * a * b * Signal and L of the hue correction colors Ces ′ (1) to Ces ′ (18) obtained in step S126. * a * b * The hue error θrms is obtained based on the signal. More specifically, for the kth color, the hue optimization target color Cme ′ (k) L * a * b * The hue angle θme ′ (k) is obtained from the signal by the equation (5) and the hue correction color Ces ′ (k) L * a * b * The process of obtaining the hue angle θes ′ (k) from the signal by the equation (5) is performed for k = 1, 2,..., 18 and the difference between the hue angles θme ′ (k) and θes ′ (k) of the 18 colors is calculated. The sum of squares is obtained, and this is set as the hue error θrms (see equation (13)).
[0056]
[Expression 10]
Figure 2005045438
[0057]
In step S130, it is determined whether or not the hue error θrms is less than or equal to the allowable value α. If the hue error θrms exceeds the allowable value α, the process returns to step S108, and the target colors Cme (1) to Cme (18) Change one of the RGB signals to create a new hue optimization matrix A Find hue. Note that when returning to step S108 and resetting the RGB signals of the target colors Cme (1) to Cme (18), the hue of the reproduced color in the monitor device 30 is set to be the subject so that the change in hue is small. Each value needs to be determined so that it does not change from the original color.
[0058]
If it is determined in step S130 that the hue error θrms is less than or equal to the allowable value α, the hue optimization matrix A that can approximate the input color Cin with respect to the target color Cme with high accuracy. It is assumed that hue has been obtained, and saturation optimization matrix A Steps S140 to S144 for obtaining satw are executed.
[0059]
In step S140, a multiple regression model for adjusting not only the hue but also the saturation is constructed, and a multiple regression analysis is performed. In this multiple regression model, as shown in the equation (14), the RGB signals of the 18 hue correction colors Ces ′ (1) to Ces ′ (18) obtained in step S124 are explanatory variable groups, and step S108. The 18 color saturation optimization target colors Cme (1) to Cme (18) set in (1) are the objective variable group. Bin in the equation (14) is a matrix having hue correction colors Ces ′ (1) to Ces ′ (18) as column vectors, and Bme is a saturation optimization target color Cme (1) to Cme (18). It is a matrix that is a column vector. In step S142, the obtained partial regression coefficient a " 1 ~ A " 9 Saturation optimization matrix A It is determined in the matrix element of satw. Saturation optimization matrix A The method for obtaining satw is the hue optimization matrix A in steps S120 to S122. This is the same as how to obtain hue and will not be described in detail.
[Expression 11]
Figure 2005045438
[0060]
Saturation optimization matrix A in step S142 When satw is obtained, the color conversion matrix A is calculated in accordance with the above-described expression (6) (expression (7)) in step S144. In step S146, the RGB signals (Res (1), Cin (18)) of the correction colors Ces (1) to Ces (18) are converted by converting the RGB signals of the input colors Cin (1) to Cin (18) using the color conversion matrix A, respectively. Ges (1), Bes (1)) to (Res (18), Ges (18), Bes (18)) are obtained (refer to the above-described equations (1) and (2)), and in step S148 (3 ) Formula and (4) Formula RGB → XYZ → L * a * b * By conversion, L of the correction colors Ces (1) to Ces (18) * a * b * In step S150, a hue error θrms between the correction colors Ces (1) to Ces (18) and the target colors Cme (1) to Cme (18) is obtained. The method for obtaining the hue error θrms in step S150 is the same as the method for obtaining the hue error θrms in step S128, and a description thereof will be omitted.
[0061]
In the next step S152, it is determined whether or not the hue error θrms is less than or equal to the allowable value α. If the hue error θrms exceeds the allowable value α, the process returns to step S108, and the hue error θrms is less than or equal to the allowable value α. If it is determined that the color conversion matrix A can be obtained that can approximate the input color Cin with respect to the target color Cme with high accuracy in terms of hue and saturation, the coefficients of the color conversion matrix A are determined in step S154. In step S156, the coefficient data of the color conversion matrix A is transferred from the color conversion matrix calculation device 34 to the digital camera 10 and written in the memory 22, and the process ends.
[0062]
When the color conversion matrix A obtained as described above is used in the color correction processing of the digital camera 10, it is possible to obtain an sRGB signal that can reproduce a color faithful to the colorimetric signal, particularly with respect to the hue, and display it on the screen of the monitor device 30. The subject image can be displayed with a color very close to the original color of the subject.
[0063]
As described above, in this embodiment, it is possible to perform color correction processing in consideration of human visual characteristics in which a hue difference is easily captured as a color difference. In other words, the color conversion matrix A used for color correction is divided into two matrices, that is, a hue optimization matrix A that matches the hue with the target color Cme. A to match hue and saturation to the target color Cme The matrix is obtained by product with satw, and each matrix is individually obtained by multiple regression analysis. Accordingly, the hue of the correction color Ces can be preferentially matched with the target color Cme, and the monitor device 30 can reproduce a color very close to the original color of the subject.
[0064]
In the above-described multiple regression model, the hue angle difference between the correction color Ces and the target color Cme varies approximately equally for each color. Before performing the multiple regression analysis in step S140, the hue optimization target colors Cme ′ (1) to Cme ′ (18) and the target colors Cme (1) to Cme (18), which are target variable groups, are weighted. That is, the product of the weight W (k) (k = 1, 2,... 18) set for each of the 18 colors and the hue optimization target color Cme ′ (k), and the weight W (k) and the target color Cme (k ) And the multiple regression analysis using the objective variable group. The equation (15) shows a multiple regression model equation for weighting the hue-optimized target colors Cme ′ (1) to Cme ′ (18) to match the hues, and the equation (16) shows the target color Cme. A multiple regression model formula for weighting (1) to Cme (18) to match the saturation is shown. W is a matrix having 18 color weights W (k) as elements, and the sum of the weights W (1) to W (18) is 1. By this weighting, a more specific color reproduction can be performed for a specific color with a larger weight.
[Expression 12]
Figure 2005045438
[0065]
The image input device may be a digital video camera or a scanner in addition to the digital camera 10 of the present embodiment. In this embodiment, the color conversion matrix calculation device 34 is separated from the digital camera 10, but the digital camera 10 may be equipped with a color conversion matrix calculation function. Furthermore, it may be configured such that the color conversion matrix is calculated and installed in a personal computer as image processing software capable of color correction, and the RAW data output from the digital camera 10 can be color corrected by the personal computer.
[0066]
In the present embodiment, a color conversion matrix that performs color correction on RGB signals obtained by the imaging system in accordance with the sRGB standard is obtained. However, the matrix calculation method of the present invention calculates a color conversion matrix particularly for color correction purposes. It is not limited to. For example, the present invention can be applied to calculation of a color conversion matrix for mutually converting color signals in different color spaces (converting RGB signals into XYZ signals or cmy signals for printing).
[0067]
【The invention's effect】
As described above, according to the present invention, it is possible to obtain a color conversion matrix capable of approximating the reproduced color with respect to the hue to the original color with high accuracy.
[Brief description of the drawings]
FIG. 1 is a diagram illustrating an embodiment of a color conversion matrix calculation method and a color conversion method according to the present invention, and is a block diagram illustrating a digital camera that performs color conversion and a color conversion matrix calculation device that calculates a color conversion matrix. It is.
FIG. 2 is a diagram illustrating the principle of color conversion matrix calculation, and is a diagram illustrating positions of an input color before conversion and a target color to be converted in a Lab color space with respect to a predetermined color.
FIG. 3 is a block diagram schematically showing the processing flow of color conversion matrix calculation processing and the relationship between various color signals.
FIG. 4 is a first part of a flowchart showing a color conversion matrix calculation process.
FIG. 5 is a second part of a flowchart showing a color conversion matrix calculation process.
FIG. 6 is a final part of a flowchart showing a color conversion matrix calculation process.
[Explanation of symbols]
10 Digital camera
20 Digital signal processing circuit
30 Monitor device
34 color conversion matrix calculation device
40 color chart

Claims (7)

第1色空間の任意の色信号を第2色空間の色信号に変換するための色変換マトリクスを算出する色変換マトリクス算出方法であって、
前記色変換マトリクスが第1マトリクスと第2マトリクスとの積であり、
彩度および色相が段階的に変化する複数のカラーパッチに各々対応する第1色空間の色信号を第1説明変数群とし、前記カラーパッチの各々に対応し第2色空間の色相に関する第1目標色信号を第1目的変数群とし、前記第1マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、前記第1説明変数群と前記第1目的変数群とに基づく重回帰分析により前記第1マトリクスの要素が求められ、
前記カラーパッチに各々対応する第1色空間の色信号に前記第1マトリクスを作用させることにより得られた色相補正色信号を第2説明変数群とし、前記カラーパッチの各々に対応し第2色空間の彩度に関する第2目標色信号を第2目的変数群とし、前記第2マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、前記第2説明変数群と前記第2目的変数群とに基づく重回帰分析により前記第2マトリクスの要素が求められる
ことを特徴とする色変換マトリクス算出方法。
A color conversion matrix calculation method for calculating a color conversion matrix for converting an arbitrary color signal in a first color space into a color signal in a second color space,
The color conversion matrix is a product of a first matrix and a second matrix;
A color signal in the first color space corresponding to each of a plurality of color patches whose saturation and hue change stepwise is defined as a first explanatory variable group, and a first color related to the hue in the second color space corresponding to each of the color patches. A multiple regression model having a target color signal as a first objective variable group and an element of the first matrix as a partial regression coefficient is constructed, and a multiple regression analysis based on the first explanatory variable group and the first objective variable group is performed. Elements of the first matrix are determined;
The hue correction color signal obtained by applying the first matrix to the color signal of the first color space corresponding to each of the color patches is set as a second explanatory variable group, and the second color corresponding to each of the color patches is set. A multiple regression model is constructed in which the second target color signal relating to the saturation of the space is the second objective variable group, and the elements of the second matrix are the partial regression coefficients, and the second explanatory variable group and the second objective variable group A method for calculating a color conversion matrix, wherein elements of the second matrix are obtained by multiple regression analysis based on the above.
前記カラーパッチに対応する前記第1色空間の色信号、前記色相補正色信号、前記第1目標色信号および前記第2目標色信号は、色の一致度の評価の際にCIE−L均等色空間における色信号に変換されることを特徴とする請求項1に記載の色変換マトリクス算出方法。The color signal of the first color space corresponding to the color patch, the hue correction color signal, the first target color signal, and the second target color signal are CIE-L * a when the color matching degree is evaluated. * b * color conversion matrix calculation method according to claim 1, characterized in that it is converted to a color signal in the uniform color space. 前記彩度に関する目標色信号が前記カラーパッチの測色信号であり、前記第1目標色信号がCIE−L色空間において座標原点と前記第2目標色信号の点とを結んだ直線に対して前記第1目標色信号を正射影した点が示す色信号であることを特徴とする請求項1に記載の色変換マトリクス算出方法。The target color signal related to the saturation is a colorimetric signal of the color patch, and the first target color signal connects the coordinate origin and the point of the second target color signal in the CIE-L * a * b * color space. 2. The color conversion matrix calculation method according to claim 1, wherein the color signal is a color signal indicated by a point obtained by orthogonally projecting the first target color signal with respect to a straight line. 前記カラーパッチが、マクベスカラーチャートの18色の有彩色カラーパッチであることを特徴とする請求項1に記載の色変換マトリクス算出方法。The color conversion matrix calculation method according to claim 1, wherein the color patches are 18 chromatic color patches of a Macbeth color chart. 前記18色の有彩色カラーパッチに対応する第1色空間の色信号は、前記マクベスカラーチャートの6色の無彩色カラーパッチに対応する第1色空間の色信号に基づいてホワイトバランス補正が施されることを特徴とする請求項4に記載の色変換マトリクス算出方法。The color signal of the first color space corresponding to the 18 chromatic color patches is subjected to white balance correction based on the color signal of the first color space corresponding to the six achromatic color patches of the Macbeth color chart. The color conversion matrix calculation method according to claim 4, wherein: 前記第1色空間の色信号がカラーフィルタを設けた撮像素子によって得られた3原色RGB信号であり、前記第2色空間の色信号がsRGB(スタンダード・レッド・グリーン・ブルー)信号であることを特徴とする請求項1に記載の色変換マトリクス算出方法。The color signal of the first color space is an RGB signal of three primary colors obtained by an image sensor provided with a color filter, and the color signal of the second color space is an sRGB (Standard Red Green Blue) signal. The color conversion matrix calculation method according to claim 1. 画像の第1色空間における任意の色の色信号を色変換マトリクスを用いて第2の色空間における色信号に変換する色補正方法であって、
前記色変換マトリクスが、第1マトリクスと第2マトリクスとの積であり、
彩度および色相が段階的に変化する複数のカラーパッチに各々対応する第1色空間の色信号を第1説明変数群とし、前記カラーパッチの各々に対応し第2色空間の色相に関する第1目標色信号を第1目的変数群とし、前記第1マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、前記第1説明変数群と前記第1目的変数群とに基づく重回帰分析により前記第1マトリクスの要素が求められ、
前記カラーパッチに各々対応する第1色空間の色信号に前記第1マトリクスを作用させることにより得られた色相補正色信号を第2説明変数群とし、前記カラーパッチの各々に対応し第2色空間の彩度に関する第2目標色信号を第2目的変数群とし、前記第2マトリクスの要素を偏回帰係数とする重回帰モデルが構築され、前記第2説明変数群と前記第2目的変数群とに基づく重回帰分析により前記第2マトリクスの要素が求められる
ことを特徴とする色補正方法。
A color correction method for converting a color signal of an arbitrary color in a first color space of an image into a color signal in a second color space using a color conversion matrix,
The color conversion matrix is a product of a first matrix and a second matrix;
A color signal in the first color space corresponding to each of a plurality of color patches whose saturation and hue change stepwise is defined as a first explanatory variable group, and a first color related to the hue in the second color space corresponding to each of the color patches. A multiple regression model having a target color signal as a first objective variable group and an element of the first matrix as a partial regression coefficient is constructed, and a multiple regression analysis based on the first explanatory variable group and the first objective variable group is performed. Elements of the first matrix are determined;
The hue correction color signal obtained by applying the first matrix to the color signal of the first color space corresponding to each of the color patches is set as a second explanatory variable group, and the second color corresponding to each of the color patches is set. A multiple regression model is constructed in which the second target color signal relating to the saturation of the space is the second objective variable group, and the elements of the second matrix are the partial regression coefficients, and the second explanatory variable group and the second objective variable group A color correction method, wherein the elements of the second matrix are obtained by a multiple regression analysis based on:
JP2003201668A 2003-07-25 2003-07-25 Color conversion matrix calculation method and color correction method Expired - Fee Related JP4136820B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2003201668A JP4136820B2 (en) 2003-07-25 2003-07-25 Color conversion matrix calculation method and color correction method
US10/898,177 US7586642B2 (en) 2003-07-25 2004-07-26 Color-space transformation-matrix calculating system and calculating method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003201668A JP4136820B2 (en) 2003-07-25 2003-07-25 Color conversion matrix calculation method and color correction method

Publications (2)

Publication Number Publication Date
JP2005045438A true JP2005045438A (en) 2005-02-17
JP4136820B2 JP4136820B2 (en) 2008-08-20

Family

ID=34261663

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003201668A Expired - Fee Related JP4136820B2 (en) 2003-07-25 2003-07-25 Color conversion matrix calculation method and color correction method

Country Status (1)

Country Link
JP (1) JP4136820B2 (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108377373A (en) * 2018-05-10 2018-08-07 杭州雄迈集成电路技术有限公司 A kind of color rendition device and method pixel-based
US10712203B2 (en) 2016-07-27 2020-07-14 Toppan Printing Co., Ltd. Color calibration device, color calibration system, color calibration hologram, color calibration method, and program
CN112733079A (en) * 2020-12-29 2021-04-30 愉悦家纺有限公司 Construction and application of multi-dimensional superposition color mixing model and gradient chromatography matrix algorithm

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10712203B2 (en) 2016-07-27 2020-07-14 Toppan Printing Co., Ltd. Color calibration device, color calibration system, color calibration hologram, color calibration method, and program
CN108377373A (en) * 2018-05-10 2018-08-07 杭州雄迈集成电路技术有限公司 A kind of color rendition device and method pixel-based
CN112733079A (en) * 2020-12-29 2021-04-30 愉悦家纺有限公司 Construction and application of multi-dimensional superposition color mixing model and gradient chromatography matrix algorithm
CN112733079B (en) * 2020-12-29 2023-03-21 愉悦家纺有限公司 Method for constructing multi-dimensional superposition color mixing model and gradient chromatography matrix

Also Published As

Publication number Publication date
JP4136820B2 (en) 2008-08-20

Similar Documents

Publication Publication Date Title
US7586642B2 (en) Color-space transformation-matrix calculating system and calculating method
US8768055B2 (en) Image sensor apparatus and method for scene illuminant estimation
JP4120841B2 (en) Projector color correction method
US5929906A (en) Color correcting method and apparatus
JP4540492B2 (en) Color conversion matrix calculation method and image signal processing apparatus
US9342872B2 (en) Color correction parameter computation method, color correction parameter computation device, and image output system
US20090147098A1 (en) Image sensor apparatus and method for color correction with an illuminant-dependent color correction matrix
JP2005079834A (en) Method for calculating color conversion matrix and image signal processing unit
EP0990881B1 (en) Method of measuring spectral responsivity characteristic of image pick-up device
JP4677699B2 (en) Image processing method, image processing device, photographing device evaluation method, image information storage method, and image processing system
JP2005045446A (en) Color conversion matrix calculation method and color correction method
JP2008085659A (en) Digital camera
US6507667B1 (en) Color digital imaging apparatus having a rule-based hue-shift processor
JP3943167B2 (en) Color conversion method
JP2006222783A (en) Preparation of color conversion table
JP2002109523A (en) Image pickup device, optical filter group, and image data converter
JP4136820B2 (en) Color conversion matrix calculation method and color correction method
CN115426487B (en) Color correction matrix adjustment method, device, electronic equipment and readable storage medium
JP5097927B2 (en) Color conversion matrix calculation method
JPH10164352A (en) Image signal processing method
JPH08163387A (en) System and device for color picture recording
JP2004151952A (en) Color expressing method and image processing method
Rong Color Management of Desktop input devices: Quantitative analysis of Profile Quality
JPH10191077A (en) Image signal processing method
JPH09321995A (en) Color signal processing method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060614

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20080215

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080226

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080423

A711 Notification of change in applicant

Free format text: JAPANESE INTERMEDIATE CODE: A712

Effective date: 20080425

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20080527

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080603

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110613

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees