JP2004242099A - Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium - Google Patents

Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium Download PDF

Info

Publication number
JP2004242099A
JP2004242099A JP2003029920A JP2003029920A JP2004242099A JP 2004242099 A JP2004242099 A JP 2004242099A JP 2003029920 A JP2003029920 A JP 2003029920A JP 2003029920 A JP2003029920 A JP 2003029920A JP 2004242099 A JP2004242099 A JP 2004242099A
Authority
JP
Japan
Prior art keywords
color
image data
image
illumination condition
illumination
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.)
Withdrawn
Application number
JP2003029920A
Other languages
Japanese (ja)
Inventor
Hironori Suzuki
裕紀 鈴木
Toshiki Iso
俊樹 磯
Keitoku Isoda
佳徳 礒田
Toshiaki Sugimura
利明 杉村
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.)
NTT Docomo Inc
Original Assignee
NTT Docomo Inc
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 NTT Docomo Inc filed Critical NTT Docomo Inc
Priority to JP2003029920A priority Critical patent/JP2004242099A/en
Publication of JP2004242099A publication Critical patent/JP2004242099A/en
Withdrawn legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide a color distortion correction technology which effectively uses a photographing region for a photographing object and conducts correction processing of correcting color distortion in an image obtained by photographing the photographing object, in a short period of time. <P>SOLUTION: A color data conversion function K1 comprises a correction parameter storage function K2 for storing color conversion parameters for correcting color distortion and illumination parameters indicating features of illumination conditions into a correction parameter database 19a, by associating each other using each image data representing each image obtained by photographing a color chart under a plurality of illumination conditions; and an image conversion function K3 for estimating illumination parameters for image data representing the image obtained by photographing the photograph object including a white region under an arbitrary illumination condition, and for outputting correction image data representing a color distortion corrected image, using color conversion parameters associated with the illumination parameters and stored in the correction parameter database 19a. <P>COPYRIGHT: (C)2004,JPO&NCIPI

Description

【0001】
【発明の属する技術分野】
本発明は、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像に対し、照明条件の違いによる色歪みを補正するための技術に関する。
【0002】
【従来の技術】
一般的に、撮影対象が撮影される際に撮影対象に当たる照明の具合、即ち照明条件の違いによって、撮影された画像における撮影対象の色は微妙に異なるものである。このような照明条件の違いに応じた色の違い、即ち色歪みを補正するためのカラー画像変換装置が特許文献1に記載されている。このカラー画像変換装置には、補正基準となる所定の照明条件の下で撮影された各色票を含むカラーチャートの画像の情報が予め記憶されている。また、このカラー画像変換装置で扱われる撮影対象は、各色票を含むカラーチャートとともに撮影される。そして、この画像変換装置は、撮影対象と共に撮影されたカラーチャートに含まれる各色票に関する画像情報と、予め記憶されたカラーチャートに含まれる各色票に関する画像情報との対応関係を導出し、この対応関係を用いて、撮影対象を撮影して得られる画像の色歪みを補正する。
【0003】
【特許文献1】
特開2002−152768号公報
【0004】
【発明が解決しようとする課題】
しかし、このカラー画像変換装置によれば、被写界内、即ち、撮影対象を撮影するための撮影領域内に、カラーチャートを撮影するための領域が必要となる。このため、撮影領域が小さい場合には、撮影領域に占めるカラーチャートの割合が大きくなり、撮影される撮影対象の占める割合が小さくなる恐れがある。
また、カラーチャートに含まれる色票毎に上述の対応関係を導出するため、画像の色歪みを補正する処理に時間が掛かってしまう。
【0005】
そこで、本発明は、以上説明した事情に鑑みてなされたものであり、撮影対象を撮影するための撮影領域を有効に使用することができ、撮影対象を撮影して得られる画像の色歪みを補正する処理を短時間で行うことができる色歪み補正技術を提供する。
【0006】
【課題を解決するための手段】
本発明は、複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて記憶手段に予め記憶させる補正パラメータ記憶ステップと、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得ステップと、前記対象取得ステップで取得された画像データについて、その照明条件を推定する推定ステップと、前記推定ステップで推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得ステップで取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正ステップとを備えることを特徴とする色歪み補正方法を提供する。
【0007】
また、本発明は、情報を記憶する記憶手段と、複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて前記記憶手段に予め記憶させる補正パラメータ記憶手段と、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得手段と、前記対象取得手段で取得された画像データについて、その照明条件を推定する推定手段と、前記推定手段で推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得手段で取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正手段とを備えることを特徴とする色歪み補正装置を提供する。
【0008】
また、本発明は、情報を記憶する記憶手段と、複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて前記記憶手段に予め記憶させる補正パラメータ記憶手段と、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得手段と、前記対象取得手段で取得された画像データについて、その照明条件を推定する推定手段と、前記推定手段で推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得手段で取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正手段とを備えることを特徴とする携帯端末を提供する。
【0009】
また、本発明は、コンピュータに、複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて記憶手段に予め記憶させる補正パラメータ記憶ステップと、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得ステップと、前記対象取得ステップで取得された画像データについて、その照明条件を推定する推定ステップと、前記推定ステップで推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得ステップで取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正ステップとを実行させるためのプログラムを提供する。
【0010】
また、本発明は、上述のプログラムを記憶した記憶媒体を提供する。
【0011】
本発明によれば、複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて記憶手段に予め記憶させる。そして、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得し、この画像データについて、その照明条件を推定する。次いで、推定した照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、当該画像データを変更することにより、当該画像データで表される画像の色歪みを補正する。
【0012】
【発明の実施の形態】
以下、図面を参照して本発明の実施の形態を詳細に説明する。なお、実施の形態を説明するための全図において、同一機能を有するものは同一符号を付け、その繰り返しの説明は省略する。
【0013】
(1.色歪み補正装置1の構成)
<ハードウェア構成>
図2は、色歪み補正装置1のハードウェア構成を示すブロック図である。
画像入力部12は、図示しないスキャナと、このスキャナの走査制御を行う駆動回路と、スキャナによって走査された情報をアナログからディジタルに変換するA/D変換回路とを有する。画像入力部12は、ユーザにより画像がスキャナにセットされると、スキャナにてこの画像の情報を走査し、走査された情報をA/D変換回路にてデジタル化して、画像データを生成し、これをCPU(Central Processing Unit)10に供給する。
操作入力部13は、数字や文字、操作指示などを入力するための複数のキーを備え、これらのキーの操作に応じた操作信号をCPU10に出力する。
表示部14は、画像データをカラーで表示可能な表示パネルと、この表示パネルの表示制御を行う駆動回路とを有する。なお、この表示パネルにおいてカラー表示の際に用いる表色系は、任意の表色系で良い。
CPU10は、記憶部16に記憶されている各種プログラムを実行することにより、バス11を介して接続されている装置各部を制御する。
記憶部16は、ROM(Read Only Memory)17と、RAM(Random Access Memory)18と、HD(Hard Disk)19とを有している。
ROM17には、色歪み補正装置1の装置各部の基本制御を司るプログラムが記憶されている。また、RAM18は、CPU10のワークエリアとして用いられ、RAM18には、CPU10により実行される各種のプログラムやデータが一時的に記憶される。
【0014】
HD(Hard Disk)19には、色歪み補正装置1のオペレーティングシステムなどが記憶されている。また、以下の機能的構成欄で説明する機能をCPU10に実現させるためのプログラムと、その機能が実現される際に用いられる補正パラメータデータベース19a及び補正の基準となるカラーチャートに関する基準データとが記憶されている。なお、カラーチャートとは、図3に示されるように、白色の色票を含むn個の異なる色票を有しているものである。また、基準データとは、このようなカラーチャートに含まれる各色票についてディジタルデータ化されたものである。そして、この基準データに含まれる各色票に関するデータ(以下、基準色票データという)が、それぞれ各色票における真の色を示すデータであり、色票毎の色相の値と彩度の値と明度の値とから構成される。本実施形態においては、画像データの各色に関するデータを、各色に対応する真の色を示すデータに変換することを、色歪みを補正する、という。なお、以下では、色相の値と彩度の値と明度の値とを合わせて画素値という。
【0015】
<機能的構成>
図1は、CPU10によって実現される機能を例示するブロック図である。これらの機能は、1点鎖線の中に示した部分に示されている。
CPU10によって実現される機能を1つに集約したものが、カラーデータ変換機能K1である。カラーデータ変換機能K1は、任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像(以下、対象画像という)を表す画像データ(以下、対象画像データという)が画像入力部12から供給されると、この対象画像データに対し、照明条件の違いによる色歪みを補正した画像を表す画像データ(以下、補正画像データという)を出力する機能である。このカラーデータ変換機能K1は、補正パラメータ記憶機能K2と、画像変換機能K3とに大別される。
【0016】
補正パラメータ記憶機能K2は、カラーチャート画像取得機能K21と、表色系変換機能K22と、基準データ取得機能K23と、照明パラメータ算出機能K24と、カラー変換パラメータ算出機能K25と、データベース記憶機能K26とを集約した機能である。この補正パラメータ記憶機能K2の大略は、複数の照明条件下で撮影されたカラーチャート画像の画像データと、補正の基準となるカラーチャートに関する基準データとを用いて、照明条件の特徴を示す照明パラメータと当該照明条件下における色歪みを補正するためのカラー変換パラメータとを求め、これらを関連付けて補正パラメータデータベース19aに記憶させる、ことである。
【0017】
カラーチャート画像取得機能K21は、複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データ(以下、カラーチャート画像データという)を画像入力部12から取得する機能である。
表色系変換機能K22は、カラーチャート画像取得機能K21により取得されたカラーチャート画像データに含まれる各画素について、画素毎に画素値を算出して、このカラーチャート画像データの表色系を、色相と彩度と明度とを軸とする表色系に変換する機能である。
基準データ取得機能K23は、補正の基準となるカラーチャートに関する基準データを取得する機能である。なお、本実施形態においては、基準データとして、HD19に予め記憶されているものを用いる。しかし、上述のカラーチャート画像取得機能K21によって取得され表色系変換機能K22によって変換された画像データのうち、ある特定の照明条件下における画像データを選択し、これを基準データとして用いるようにしても良い。
照明パラメータ算出機能K24は、表色系変換機能K22によりその表色系が変換されたカラーチャート画像データを用いて、このカラーチャート画像が撮影された時の照明条件の特徴を示す照明パラメータを算出する機能である。
カラー変換パラメータ算出機能K25は、基準データ取得機能K23により取得された基準データの各基準色票データと、表色系変換機能K22によりその表色系が変換された各カラーチャート画像データに含まれるn個の各色票に対応するデータ部分(以下、色票データという)との対応関係を求めることにより、照明条件毎に、色歪み補正のためのカラー変換パラメータを算出する機能である。
データベース記憶機能K26は、照明パラメータ算出機能K24により算出された照明パラメータと、カラー変換パラメータ算出機能K25により算出されたカラー変換パラメータと(以下、これらを合わせて補正パラメータという)を関連付けて補正パラメータデータベース19aに記憶させる機能である。
【0018】
画像変換機能K3は、対象画像データに対する照明パラメータを推定する推定機能K300と、対象データに表される画像の色歪みを補正する補正機能K301とに大別される。推定機能K300は、表色系変換機能K31、照明パラメータ算出機能K32、照明条件検出機能K33とを集約した機能である。補正機能K301は、カラー変換パラメータ選択機能K34、カラー変換機能K35、表色系逆変換機能K36とを集約した機能である。
【0019】
表色系変換機能K31は、画像入力部12から供給された対象画像データに含まれる各画素について、画素毎に画素値を算出し、当該画像データの表色系を、色相と彩度と明度とを軸とする表色系に変換する機能である。
照明パラメータ算出機能K32は、表色系変換機能K31によりその表色系が変換された対象画像データの照明パラメータを暫定的に算出する機能である。照明条件検出機能K33は、照明パラメータ算出機能K32により算出された照明パラメータと最も類似する照明パラメータを検出する機能である。この照明条件検出機能K33により検出された照明パラメータが表す照明条件が、対象画像データに対する照明条件であると推定される。
カラー変換パラメータ選択機能K34は、照明条件検出機能K33により検出された照明パラメータを補正パラメータデータベース19aから読み出し、その照明パラメータに関連付けられて記憶されているカラー変換パラメータを選択する機能である。
カラー変換機能K35は、カラー変換パラメータ選択機能K34により選択されたカラー変換パラメータを用いて対象画像データを変更することにより、当該対象画像データに表される画像の色歪みを補正する機能である。
表色系逆変換機能K36は、カラー変換機能K35により変更された対象画像データの表色系(色相と彩度と明度とを軸とする表色系)を、表色系変換機能K31により変換される前の表色系に変換することにより、補正画像データを出力する機能である。
【0020】
(2.動作)
次に本実施形態の動作について説明する。本実施形態では、まず、事前に▲1▼補正パラメータを補正パラメータデータベース19aに記憶させる。その後、必要に応じて▲2▼撮影対象の画像に対する画像データの色歪みを補正する。そこで、まず、▲1▼に関する動作について説明する。
<▲1▼補正パラメータの記憶動作>
まず、ユーザは、図3に示されるようなn個の色票を有するカラーチャートを、異なるk個の照明条件下で、任意の撮影機を用いて撮影しておく。即ち、k個のカラーチャート画像を用意しておく。なお、撮影の際には、カラーチャートと撮影機との位置関係を固定するようにすれば、各カラーチャート画像において白色の色票が現れる位置が固定されるため、更に良い。
そして、ユーザは、これらk個のカラーチャート画像を、色歪み補正装置1の画像入力部12にそれぞれセットする。すると画像入力部12は、セットされた各カラーチャート画像を表す画像データ(カラーチャート画像データ)をそれぞれ生成し、これらk個のカラーチャート画像データをCPU10に供給する。CPU10は、供給されたk個のカラーチャート画像データを一時的にRAM18に記憶させる。
次いで、ユーザは、操作入力部13を操作することにより、RAM18に記憶されているk個のカラーチャート画像データに対して1つずつ、以下に説明する照明パラメータ算出処理をCPU10に行わせる。
【0021】
図6は、照明パラメータ算出処理の流れを示すフローチャートである。
まず、ユーザは、操作入力部13を操作することにより、RAM18に記憶されているカラーチャート画像データのうち、1つを表示部14に表示させる。すると、表示部14には、このカラーチャート画像データによって表されるカラーチャート画像が表示される。そして、ユーザは、操作入力部13を操作することにより、表示されたカラーチャート画像のうち、白色に表示されている白色領域を指定する(ステップS10)。すると、CPU10は、このカラーチャート画像を表すカラーチャート画像データのうち、指定された白色領域に対応するデータ部分に含まれる各画素について、画素毎の画素値を算出する(ステップS11)。次いで、指定された白色領域に対応するデータ部分に含まれる全ての画素について、画素値の算出を終えると、これらの画素値の平均値を算出する(ステップS12)。なお、以下では、画素値の平均値を平均画素値という。そして、CPU10は、この平均画素値をこのカラーチャート画像データに対する照明パラメータとして、RAM18に一時的に記憶させる。
以上のようにして、ユーザは、1つのカラーチャート画像データに対し、照明パラメータ算出処理をCPU10に行わせる。そして、ユーザは、残りの(k−1)個のカラーチャート画像データについても同様に照明パラメータ算出処理をCPU10に行わせる。これにより、k個の各照明条件に対応した各照明パラメータが算出される。
【0022】
次いで、ユーザが操作入力部13を操作することにより、照明パラメータ算出処理の終了を指示すると、CPU10は、次に、以下に説明するカラー変換パラメータ算出処理を行う。図7は、カラー変換パラメータ算出処理の流れを示すフローチャートである。
まず、CPU10は、RAM18に記憶されているk個のカラーチャート画像データのうち、1つのカラーチャート画像データを読み出し、このカラーチャート画像データに含まれる各色票データについても、色票毎に、平均画素値を算出する(ステップS20)。
【0023】
次いで、CPU10は、ニューラルネットワークの学習を行い(ステップS21)、図4に示されるようなニューラルネットワークを構築する。このニューラルネットワークの学習の際には、学習データを、HD19に記憶されている各基準色票データに対する各平均画素値とし、教師データを、ステップS20で算出した各色票データに対する各平均画素値とし、予め定められたニューラルネットワークの階層数やユニット数や学習則などの各種パラメータを用いる。なお、学習則として、バックプロパゲーションやヘッブ学習などの学習則を用いれば良い。
そして、CPU10は、このニューラルネットワークに基づいて、重み係数を算出する。この重み係数が、このカラーチャート画像データに対するカラー変換パラメータとなる。
【0024】
次いで、CPU10は、RAM18に記憶されている残りの(k―1)個のカラーチャート画像データについても同様に、データ毎にステップS20〜S21の処理を行う。そして、k個全てのカラーチャート画像データについてステップS20〜S21の処理を終えると、ステップS22の判定結果が肯定的となり、CPU10は、各カラーチャート画像データに対するカラー変換パラメータと、上述の照明パラメータ算出処理で算出された各カラーチャート画像データに対する照明パラメータとを関連付けて、補正パラメータデータベース19aに記憶させる。
【0025】
<▲2▼対象画像の色歪み補正動作>
次に、対象画像の色歪みを補正する動作について説明する。
本実施形態で用いる撮影対象は、図5に示されるような白色領域を含むカラーバーコードとする。対象画像は、このようなカラーバーコードが任意の照明条件下で任意の撮影機で撮影された画像とする。
【0026】
ユーザは、操作入力部13を操作することにより、この対象画像を画像入力部12にそれぞれセットする。すると画像入力部12は、セットされた対象画像を表す画像データ(対象画像データ)を生成し、これをCPU10に供給する。CPU10は、供給された対象画像データを一時的にRAM18に記憶させる。
次いで、CPU10は、この対象画像データに含まれる全ての画素について、画素毎に画素値を算出する。これにより、この対象画像データの表色系を、色相と彩度と明度とを軸とする表色系に変換する。そして、以下に説明する照明パラメータ推定処理を行う。
【0027】
図8は、照明パラメータ推定処理の流れを示すフローチャートである。
CPU10は、この対象画像データに含まれる全ての画素のうち、画素値に含まれる彩度が予め定められた閾値T以下となる画素を抽出し、これらをRAM18に記憶させる(ステップS30)。そして、RAM18に記憶された画素のうち、画素値に含まれる明度が最大の画素を選択する(ステップS31)。なお、白色は、彩度の値が小さく明度の値が大きいことから、ステップS31で選択された画素が、白色の画素であると推定される。
【0028】
次いで、CPU10は、選択された画素を中心とする近傍画素を選択する。ここでは、近傍画素として、一次近傍の画素を選択する。また、説明の便宜上、この一次近傍の画素に対して、中心となる画素(以下、中心画素という)の左右上下の順で1〜4の識別子を与える。そして、CPU10は、各近傍画素i(i=1〜4:近傍画素の識別子)についてそれぞれ、中心画素との色空間上の距離dを算出する(ステップS32)。このとき、近傍画素iの画素値及び中心画素の画素値を用いて算出する。なお、近傍画素として、二次近傍の画素を選択するようにしても良いし、選択された画素を中心とする半径R内の画素を選択しても良い。
【0029】
次いで、CPU10は、距離d(i=1〜4)の全てが予め定められた閾値T以下であるか否かを判定する(ステップS33)。なお、距離dが閾値T以下であれば、この近傍画素iは白色の画素であると推定され、距離dが閾値Tより大きければ、この近傍画素iは白色の画素でないと推定される。そして、ステップS33の判定結果が肯定的であれば、CPU10は、中心画素と近傍画素(i=1〜4)から構成される領域を白色領域と判定する。以上のようにしてCPU10は、対象画像に含まれる白色領域を推定する。そして、これらの画素の平均画素値を算出する(ステップS34)。この平均画素値が、この対象画像データの暫定的な照明パラメータ(以下、暫定照明パラメータという)となる。
【0030】
なお、ステップS33の判定結果が否定的であれば、CPU10は、RAM18に記憶されている(彩度が閾値T以下の画素)のうち、明度が最大の画素を取り除き(ステップS35)、ステップS31に移行する。
【0031】
ステップS34の後、CPU10は、対象画像データの暫定照明パラメータと、補正パラメータデータベース19aに記憶されているk個の各照明条件の照明パラメータとの各ユークリッド距離を算出する。そして、これらの距離のうち、最小の距離を検出し、この最小の距離となるときの照明パラメータを検出する。以上のようにして、この対象画像データの照明パラメータを推定する。次いで、CPU10は、補正パラメータデータベース19aから、この照明パラメータに関連付けられて記憶されているカラー変換パラメータ(ここでは、ニューラルネットワークの重み係数)を読み出す。なお、本実施形態では、照明パラメータの推定に最短距離を用いたが、単純類似度を用いても良い。
【0032】
次いで、CPU10は、読み出したカラー変換パラメータを用いて、RAM18に記憶されている対象画像データに含まれる各画素の画素値を変換することにより、この対象画像データに表される画像の色歪みを補正する。その後、この対象画像データの表色系を、色相と彩度と明度とを軸とする表色系に変換する前の表色系に変換する。そして、変換した対象画像データを出力する。以上のようにして、対象画像データに対し、色歪みを補正した画像を表す補正画像データを出力する。
【0033】
上述した色歪み補正装置1は、撮影対象と共にカラーチャートが撮影されなくとも、この撮影対象が撮影された際の照明条件を推定することで、この撮影対象の画像の色歪みを補正することができる。従って、カラーバーコードなどの情報が撮影されたIDタグなどの小さい対象画像を扱う場合には、好適である。更に、対象画像データに含まれる各色のデータそのものを分析することなく、白色領域のデータのみを分析することで、各色の歪みを補正するため、時間を掛けずに、色歪み補正のための処理を行うことができる。従って、物流管理などに用いられる上記IDタグなどのように、短時間で色歪み補正処理が行われることが必要な対象画像に対しても、好適である。
【0034】
なお、カラーチャート及び撮影対象が、ディジタルカメラなどの撮影画像をディジタル画像データとして出力する撮影機で撮影された場合には、撮影された画像データは、画像入力部12を介さず、図示しない外部インターフェースを介してCPU10に供給されるような構成としても良い。
【0035】
(3.変形例)
以上、本発明の実施形態について説明したが、本発明はその主要な特徴から逸脱することなく他の様々な形態で実施することが可能である。なお、変形例としては、例えば、以下のようなものが考えられる。
【0036】
<1.カラー変換パラメータ算出処理の他の例>
上述のカラー変換パラメータ算出処理では、カラー変換パラメータをニューラルネットワークを用いて算出するようにしたが、線形変換を用いて算出するようにしても良い。なお、本変形例の構成については、上述の実施形態と略同様であるため、その説明を省略する。また、本変形例の動作についても、上述の<▲1▼補正パラメータの記憶動作>において説明した照明パラメータ算出処理が終了するまでの動作は、上述の実施形態と略同様であるため、その説明を省略する。
CPU10は、照明パラメータ算出処理を終えると、次に、上述の処理と同様に、HD19に記憶されている基準データに含まれる各基準色票データの各画素値と、RAM18に記憶されているk個のカラーチャート画像データのうち、1つのカラーチャート画像データに含まれる各色票データの各平均画素値とを算出する。
次いで、CPU10は、学習データを、各色票データに対する各平均画素値とし、教師データを、各基準色票データに対する各画素値とし、以下の変換行列算出処理を行う。
【0037】
図9に、変換行列算出処理の流れを示す。
CPU10は、学習データと教師データとについて、それぞれ対応する1色の色票を代表色票として選択し、この代表色票に関する画素値(以下、代表画素値という)を学習データと教師データとからそれぞれ選択する。そして、学習データの代表画素値を、教師データの代表画素値に変換するための変換行列の係数を算出する(ステップS40)。図10に、これらの学習データ、教師データ、及び変換行列の例を示す。同図においては、教師データのH(t=1〜n)は色相の値を表し、S(t=1〜n)は彩度の値を表し、I(t=1〜n)は明度の値を表し、これらは、3行1列の行列として表されている。同様に、学習データのH(l=1〜n)は色相の値を表し、S(l=1〜n)は彩度の値を表し、I(l=1〜n)は明度の値を表し、これらは、3行1列の行列として表されている。変換行列は、3行3列の行列として表されており、変換行列の各apq(P=1〜3、q=1〜3)は、それぞれp行q列目における係数を表している。そして、学習データの代表画素値は、この変換行列を用いて行列変換が行われると、教師データの代表画素値に変換される。
【0038】
次いで、CPU10は、学習データに含まれる代表色票以外の各色票に関する平均画素値について、この変換行列を用いて行列変換を行い、各色票に関する変換後の平均画素値(以下、変換画素値という)を算出する(ステップS41)。そして、各色票関する変換画素値と、教師データに含まれる各基準色票に関する画素値とについて、対応する色票のデータ毎に誤差(ここでは、2乗平均誤差)を求める。更に、これらの誤差の合計(以下、2乗平均誤差合計という)を算出する(ステップS42)。
【0039】
次いで、上述の代表画素値を除いた各色票データの画素値の中から1色の色票に関する画素値を選択し、これを新たな代表画素値として、ステップS40〜S42の処理を行い、この新たな代表画素値に対応する変換行列とこれに基づく2乗平均誤差合計とを算出する。以上のようにして、カラーチャートに含まれる全ての色票について、各色票を代表色票として、ステップS40〜S42の処理を行い、各代表画素値に対応する変換行列とこれに基づく2乗平均誤差合計とをそれぞれ算出する。そして、全ての代表色票についてステップS40〜S42の処理が終えると、ステップS43の判定において判定結果が肯定的となり、ステップS44の処理に移行する。ステップS44では、CPU10は、各代表色票に対する代表画素値に対応する2乗平均誤差合計のうち、最小の値を検出する。次いで、この代表画素値に対する変換行列を検出する(ステップS43)。この変換行列が、この照明条件下で撮影されたカラーチャート画像データに対するカラー変換パラメータとなる。
【0040】
CPU10は、以上のようなステップS40〜ステップS44の変換行列処理を残りの(k−1)個のカラーチャート画像データについても行うことにより、k個の各照明条件下におけるカラーチャート画像データに対応するカラー変換パラメータ(ここでは、変換行列)を得る。CPU10は、これらを上述のカラー変換パラメータ算出処理と同様にして、各カラーチャート画像データに対する照明パラメータと関連付けてそれぞれ補正パラメータデータベース19aに記憶させる。
【0041】
その後、対象画像データの色歪み補正の際に、この対象画像データに対応するカラー変換パラメータを補正パラメータデータベース19aから読み出し、この対象画像データに含まれる画素毎の画素値を線形変換により変換するようにすれば良い。
【0042】
<2.携帯端末に色歪み補正装置1の機能を備える>
上述した色歪み補正装置1の機能を、無線通信機能を有する携帯端末に備える構成としても良い。更に、撮影機能を有する携帯端末に備える構成とすれば、この携帯端末でいつでもどこでもカラー画像を撮影することができるうえに、撮影時の照明条件を問わず、所定の照明条件下で撮影されたカラー画像と同等のカラー画像を常に得ることができる。更に、得られたカラー画像を無線通信機能により他の通信装置へ送ることができるため、様々な事に応用でき得る。
【0043】
【発明の効果】
白色領域を含む撮影対象を撮影するための撮影領域を有効に使用することができ、撮影対象を撮影して得られる画像の色歪みを補正する処理を短時間で行うことができる。
【図面の簡単な説明】
【図1】本発明の実施形態に係る色歪み補正装置1の機能的構成を示すブロック図である。
【図2】同実施形態に係る色歪み補正装置1のハードウェア構成を示すブロック図である。
【図3】同実施形態に係るカラーチャートを例示する図である。
【図4】同実施形態に係るニューラルネットワークを例示する図である。
【図5】同実施形態に係る撮影対象であるカラーバーコードを例示する図である。
【図6】同実施形態に係る照明パラメータ算出処理の流れを示すフローチャートである。
【図7】同実施形態に係るカラー変換パラメータ算出処理の流れを示すフローチャートである。
【図8】同実施形態に係る照明パラメータ推定処理の流れを示すフローチャートである。
【図9】同実施形態の他の例に係る変換行列算出処理の流れを示すフローチャートである。
【図10】同例に係る変換行列の算出式を例示する図である。
【符号の説明】
1・・・補正装置、11・・・バス、12・・・画像入力部、13・・・操作入力部、14・・・表示部、16・・・記憶部、17・・・ROM、18・・・RAM、19・・・HD、19a・・・補正パラメータデータベース。
[0001]
TECHNICAL FIELD OF THE INVENTION
The present invention relates to a technique for correcting a color distortion due to a difference in lighting conditions for an image obtained by shooting a shooting target including a white region under arbitrary lighting conditions.
[0002]
[Prior art]
In general, the color of a photographing target in a photographed image is slightly different depending on the condition of illumination applied to the photographing target when the photographing target is photographed, that is, a difference in lighting conditions. A color image conversion device for correcting a color difference according to such a difference in illumination conditions, that is, a color distortion, is described in Japanese Patent Application Laid-Open No. H11-163873. In this color image conversion apparatus, information of an image of a color chart including each color chart taken under a predetermined illumination condition serving as a correction reference is stored in advance. The object to be imaged handled by this color image conversion apparatus is imaged together with a color chart including each color chart. The image conversion apparatus derives a correspondence between image information on each color chart included in the color chart photographed together with the photographing target and image information on each color chart included in the color chart stored in advance. Using the relationship, the color distortion of the image obtained by shooting the shooting target is corrected.
[0003]
[Patent Document 1]
JP 2002-152768 A
[0004]
[Problems to be solved by the invention]
However, according to this color image conversion device, an area for photographing the color chart is required in the field, that is, in the photographing area for photographing the photographing target. For this reason, when the photographing area is small, the proportion of the color chart in the photographing area increases, and the proportion of the photographing target to be photographed may decrease.
Further, since the above-described correspondence is derived for each color chart included in the color chart, it takes time to correct the color distortion of the image.
[0005]
Therefore, the present invention has been made in view of the circumstances described above, and it is possible to effectively use a photographing area for photographing a photographing target, and to reduce color distortion of an image obtained by photographing a photographing target. Provided is a color distortion correction technique that can perform correction processing in a short time.
[0006]
[Means for Solving the Problems]
The present invention uses each piece of image data representing each image obtained by photographing a color chart having a plurality of different color patches under a plurality of different lighting conditions, using lighting condition information indicating the characteristics of each lighting condition, A correction parameter storing step of obtaining color conversion information for correcting color distortion of an image under illumination conditions, and correlating the obtained illumination condition information with the color conversion information and storing in advance in a storage unit; A target obtaining step of obtaining image data representing an image obtained by shooting a shooting target including a white region under conditions, and an image data obtained in the target obtaining step, an estimation step of estimating an illumination condition thereof; Using the color conversion information stored in the storage unit in association with illumination condition information indicating the characteristics of the illumination condition estimated in the estimation step, By changing the image data acquired by the obtained step, providing a color distortion correcting method characterized by comprising a correction step of correcting color distortion of an image represented by the image data.
[0007]
In addition, the present invention uses a storage unit for storing information and image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, and using each lighting condition. Lighting condition information indicating the characteristics of the above, and color conversion information for correcting color distortion of an image under each lighting condition are obtained, and the obtained lighting condition information and the color conversion information are associated with each other in advance in the storage unit. Correction parameter storage means for storing, object acquisition means for acquiring image data representing an image obtained by photographing a photographing object including a white region under arbitrary illumination conditions, and image data acquired by the object acquisition means. Estimating means for estimating the lighting condition, and color conversion information stored in the storage means in association with lighting condition information indicating characteristics of the lighting condition estimated by the estimating means. There, by changing the image data acquired by the target acquisition means, to provide a color correction apparatus, characterized in that it comprises a correcting means for correcting the color distortion of an image represented by the image data.
[0008]
In addition, the present invention uses a storage unit for storing information and image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, and using each lighting condition. Lighting condition information indicating the characteristics of the above, and color conversion information for correcting color distortion of an image under each lighting condition are obtained, and the obtained lighting condition information and the color conversion information are associated with each other in advance in the storage unit. Correction parameter storage means for storing, object acquisition means for acquiring image data representing an image obtained by photographing a photographing object including a white region under arbitrary illumination conditions, and image data acquired by the object acquisition means. Estimating means for estimating the lighting condition, and color conversion information stored in the storage means in association with lighting condition information indicating characteristics of the lighting condition estimated by the estimating means. There, by changing the image data acquired by the target acquisition means, to provide a mobile terminal, characterized in that it comprises a correcting means for correcting the color distortion of an image represented by the image data.
[0009]
Further, the present invention provides a computer that uses each image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, and uses the image data representing the characteristics of each lighting condition. A correction parameter storing step of obtaining condition information and color conversion information for correcting color distortion of an image under each lighting condition, and storing the obtained lighting condition information and the color conversion information in a storage unit in advance in a storage unit And a target obtaining step of obtaining image data representing an image obtained by shooting a shooting target including a white region under arbitrary lighting conditions, and estimating the lighting condition of the image data obtained in the target obtaining step. And a color conversion stored in the storage unit in association with lighting condition information indicating characteristics of the lighting condition estimated in the estimation step. Using broadcast, by changing the image data acquired by the target acquisition step provides a program for executing a correction step of correcting color distortion of an image represented by the image data.
[0010]
Further, the present invention provides a storage medium storing the above-mentioned program.
[0011]
According to the present invention, illumination condition information indicating the characteristics of each illumination condition, using image data representing each image obtained by photographing a color chart having a plurality of different color patches under a plurality of different illumination conditions, The color conversion information for correcting the color distortion of the image under each illumination condition is obtained, and the obtained illumination condition information and the color conversion information are stored in advance in a storage unit in association with each other. Then, image data representing an image obtained by photographing a photographing target including a white region under arbitrary lighting conditions is acquired, and the lighting conditions are estimated for the image data. Next, the image data is changed by using the color conversion information stored in the storage unit in association with the illumination condition information indicating the characteristics of the estimated illumination condition, thereby changing the image represented by the image data. Correct color distortion.
[0012]
BEST MODE FOR CARRYING OUT THE INVENTION
Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings. In all the drawings for describing the embodiments, components having the same function are denoted by the same reference numerals, and repeated description thereof will be omitted.
[0013]
(1. Configuration of the color distortion correction device 1)
<Hardware configuration>
FIG. 2 is a block diagram illustrating a hardware configuration of the color distortion correction device 1.
The image input unit 12 includes a scanner (not shown), a driving circuit for controlling the scanning of the scanner, and an A / D conversion circuit for converting information scanned by the scanner from analog to digital. When an image is set in the scanner by the user, the image input unit 12 scans information of the image with the scanner, digitizes the scanned information with an A / D conversion circuit, and generates image data. This is supplied to a CPU (Central Processing Unit) 10.
The operation input unit 13 includes a plurality of keys for inputting numbers, characters, operation instructions, and the like, and outputs an operation signal corresponding to the operation of these keys to the CPU 10.
The display unit 14 includes a display panel capable of displaying image data in color, and a drive circuit that controls display of the display panel. The color system used for color display in this display panel may be any color system.
The CPU 10 controls each unit of the device connected via the bus 11 by executing various programs stored in the storage unit 16.
The storage unit 16 includes a ROM (Read Only Memory) 17, a RAM (Random Access Memory) 18, and an HD (Hard Disk) 19.
The ROM 17 stores a program that controls the basic control of each unit of the color distortion correction device 1. The RAM 18 is used as a work area of the CPU 10, and various programs and data executed by the CPU 10 are temporarily stored in the RAM 18.
[0014]
The HD (Hard Disk) 19 stores an operating system of the color distortion correction apparatus 1 and the like. Further, a program for causing the CPU 10 to realize the functions described in the following functional configuration columns, a correction parameter database 19a used when the functions are realized, and reference data relating to a color chart serving as a correction reference are stored. Have been. As shown in FIG. 3, the color chart has n different color patches including a white color patch. The reference data is digital data of each color chart included in such a color chart. Data relating to each color chart included in the reference data (hereinafter referred to as reference color chart data) is data indicating a true color in each color chart, and includes a hue value, a saturation value, and a lightness value for each color chart. And the value of In the present embodiment, converting data relating to each color of image data into data indicating a true color corresponding to each color is referred to as correcting color distortion. Hereinafter, the value of hue, the value of saturation, and the value of lightness are collectively referred to as a pixel value.
[0015]
<Functional configuration>
FIG. 1 is a block diagram illustrating functions realized by the CPU 10. These functions are shown in the part shown by the dashed line.
The function realized by the CPU 10 is integrated into one to be a color data conversion function K1. The color data conversion function K1 is a function of the image input unit 12 for outputting image data (hereinafter, referred to as target image data) representing an image (hereinafter, referred to as target image) obtained by photographing a target including a white area under arbitrary lighting conditions. When the image data is supplied from the image data, the image data (hereinafter, referred to as corrected image data) representing the image in which the color distortion due to the difference in the illumination condition is corrected is output to the target image data. The color data conversion function K1 is roughly divided into a correction parameter storage function K2 and an image conversion function K3.
[0016]
The correction parameter storage function K2 includes a color chart image acquisition function K21, a color system conversion function K22, a reference data acquisition function K23, an illumination parameter calculation function K24, a color conversion parameter calculation function K25, and a database storage function K26. It is a function that aggregates The correction parameter storage function K2 is roughly based on image data of a color chart image photographed under a plurality of lighting conditions and reference data on a color chart serving as a reference for correction. And a color conversion parameter for correcting the color distortion under the illumination condition are obtained, and are stored in the correction parameter database 19a in association with each other.
[0017]
The color chart image acquisition function K21 outputs image data (hereinafter, referred to as color chart image data) representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions. 12 is a function obtained from.
The color system conversion function K22 calculates a pixel value for each pixel included in the color chart image data acquired by the color chart image acquisition function K21, and converts the color system of the color chart image data into This is a function of converting into a color system based on hue, saturation, and brightness.
The reference data acquisition function K23 is a function for acquiring reference data relating to a color chart that is a reference for correction. In the present embodiment, data stored in the HD 19 in advance is used as the reference data. However, among the image data acquired by the above-described color chart image acquisition function K21 and converted by the color system conversion function K22, image data under a specific lighting condition is selected, and this is used as reference data. Is also good.
The illumination parameter calculation function K24 uses the color chart image data whose color system has been converted by the color system conversion function K22 to calculate the illumination parameters indicating the characteristics of the illumination conditions when this color chart image was taken. Function.
The color conversion parameter calculation function K25 is included in each reference color chart data of the reference data acquired by the reference data acquisition function K23 and each color chart image data whose color system is converted by the color system conversion function K22. This function calculates a color conversion parameter for color distortion correction for each lighting condition by obtaining a correspondence relationship with a data portion (hereinafter, referred to as color patch data) corresponding to each of the n color patches.
The database storage function K26 associates the illumination parameters calculated by the illumination parameter calculation function K24 with the color conversion parameters calculated by the color conversion parameter calculation function K25 (hereinafter, these are collectively referred to as correction parameters) and associates them with a correction parameter database. This function is stored in the storage area 19a.
[0018]
The image conversion function K3 is roughly classified into an estimation function K300 for estimating an illumination parameter for target image data and a correction function K301 for correcting color distortion of an image represented by the target data. The estimation function K300 is a function obtained by integrating a color system conversion function K31, an illumination parameter calculation function K32, and an illumination condition detection function K33. The correction function K301 is a function obtained by integrating a color conversion parameter selection function K34, a color conversion function K35, and a color system inverse conversion function K36.
[0019]
The color system conversion function K31 calculates a pixel value for each pixel included in the target image data supplied from the image input unit 12, and determines the color system of the image data as hue, saturation, and brightness. This is a function of converting into a color system with axes as.
The illumination parameter calculation function K32 is a function for temporarily calculating the illumination parameters of the target image data whose color system has been converted by the color system conversion function K31. The illumination condition detection function K33 is a function of detecting an illumination parameter most similar to the illumination parameter calculated by the illumination parameter calculation function K32. It is estimated that the illumination condition represented by the illumination parameter detected by the illumination condition detection function K33 is the illumination condition for the target image data.
The color conversion parameter selection function K34 is a function of reading out the illumination parameters detected by the illumination condition detection function K33 from the correction parameter database 19a and selecting a color conversion parameter stored in association with the illumination parameters.
The color conversion function K35 is a function of correcting the color distortion of the image represented by the target image data by changing the target image data using the color conversion parameter selected by the color conversion parameter selection function K34.
The color system inverse conversion function K36 converts the color system (color system based on hue, saturation, and lightness) of the target image data changed by the color conversion function K35 with the color system conversion function K31. This is a function of outputting corrected image data by converting to a color system before the correction.
[0020]
(2. Operation)
Next, the operation of the present embodiment will be described. In the present embodiment, first, (1) the correction parameters are stored in advance in the correction parameter database 19a. Thereafter, if necessary, (2) the color distortion of the image data for the image to be captured is corrected. Therefore, the operation relating to (1) will be described first.
<(1) Operation of storing correction parameters>
First, the user shoots a color chart having n number of color charts as shown in FIG. 3 using an arbitrary camera under different k lighting conditions. That is, k color chart images are prepared. In photographing, it is more preferable to fix the positional relationship between the color chart and the photographing device, since the position where a white color chart appears in each color chart image is fixed.
Then, the user sets these k color chart images in the image input unit 12 of the color distortion correction device 1. Then, the image input unit 12 generates image data (color chart image data) representing each set color chart image, and supplies the k color chart image data to the CPU 10. The CPU 10 temporarily stores the supplied k color chart image data in the RAM 18.
Next, the user operates the operation input unit 13 to cause the CPU 10 to perform an illumination parameter calculation process described below for each of the k color chart image data stored in the RAM 18.
[0021]
FIG. 6 is a flowchart illustrating the flow of the illumination parameter calculation process.
First, the user operates the operation input unit 13 to display one of the color chart image data stored in the RAM 18 on the display unit 14. Then, the display unit 14 displays a color chart image represented by the color chart image data. Then, the user operates the operation input unit 13 to specify a white area displayed in white in the displayed color chart image (step S10). Then, the CPU 10 calculates a pixel value for each pixel in the color chart image data representing the color chart image, for each pixel included in the data portion corresponding to the designated white area (step S11). Next, when the calculation of the pixel values is completed for all the pixels included in the data portion corresponding to the designated white area, the average value of these pixel values is calculated (step S12). Hereinafter, the average value of the pixel values is referred to as an average pixel value. Then, the CPU 10 temporarily stores the average pixel value in the RAM 18 as an illumination parameter for the color chart image data.
As described above, the user causes the CPU 10 to perform the illumination parameter calculation process on one piece of color chart image data. Then, the user causes the CPU 10 to similarly perform the illumination parameter calculation process on the remaining (k-1) color chart image data. Thereby, each lighting parameter corresponding to each of the k lighting conditions is calculated.
[0022]
Next, when the user operates the operation input unit 13 to instruct the end of the illumination parameter calculation process, the CPU 10 next performs a color conversion parameter calculation process described below. FIG. 7 is a flowchart showing the flow of the color conversion parameter calculation process.
First, the CPU 10 reads out one piece of color chart image data from the k pieces of color chart image data stored in the RAM 18, and also averages each color chart data included in the color chart image data for each color chart. A pixel value is calculated (Step S20).
[0023]
Next, the CPU 10 learns the neural network (step S21), and constructs a neural network as shown in FIG. At the time of learning of this neural network, the learning data is set to each average pixel value for each reference color patch data stored in the HD 19, and the teacher data is set to each average pixel value for each color patch data calculated in step S20. Various parameters such as the number of layers, the number of units, and the learning rule of a predetermined neural network are used. Note that a learning rule such as back propagation or Hebb learning may be used as the learning rule.
Then, the CPU 10 calculates a weight coefficient based on the neural network. The weight coefficient becomes a color conversion parameter for the color chart image data.
[0024]
Next, the CPU 10 similarly performs steps S20 to S21 for the remaining (k-1) color chart image data stored in the RAM 18 for each data. When the processing in steps S20 to S21 is completed for all k color chart image data, the determination result in step S22 becomes positive, and the CPU 10 determines the color conversion parameters for each color chart image data and the above-described illumination parameter calculation. The correction parameters are stored in the correction parameter database 19a in association with the illumination parameters for each color chart image data calculated in the processing.
[0025]
<(2) Operation for correcting color distortion of target image>
Next, an operation for correcting the color distortion of the target image will be described.
The imaging target used in the present embodiment is a color barcode including a white area as shown in FIG. The target image is an image obtained by photographing such a color barcode with an arbitrary photographing device under arbitrary lighting conditions.
[0026]
The user operates the operation input unit 13 to set the target image in the image input unit 12, respectively. Then, the image input unit 12 generates image data (target image data) representing the set target image, and supplies this to the CPU 10. The CPU 10 temporarily stores the supplied target image data in the RAM 18.
Next, the CPU 10 calculates a pixel value for each pixel for all the pixels included in the target image data. Thus, the color system of the target image data is converted into a color system having hue, saturation, and lightness as axes. Then, an illumination parameter estimation process described below is performed.
[0027]
FIG. 8 is a flowchart showing the flow of the illumination parameter estimation process.
The CPU 10 sets the saturation T included in the pixel value to a predetermined threshold T among all the pixels included in the target image data. s The following pixels are extracted and stored in the RAM 18 (step S30). Then, among the pixels stored in the RAM 18, the pixel having the maximum brightness included in the pixel value is selected (Step S31). Note that, for white, since the value of saturation is small and the value of lightness is large, the pixel selected in step S31 is estimated to be a white pixel.
[0028]
Next, the CPU 10 selects a neighboring pixel centering on the selected pixel. Here, a pixel in the primary neighborhood is selected as a neighboring pixel. Further, for convenience of description, identifiers 1 to 4 are given to the pixels in the vicinity of the primary in the order of left, right, up, and down of a central pixel (hereinafter referred to as a central pixel). Then, the CPU 10 determines, for each of the neighboring pixels i (i = 1 to 4: an identifier of the neighboring pixel), the distance d in the color space from the center pixel. i Is calculated (step S32). At this time, the calculation is performed using the pixel value of the neighboring pixel i and the pixel value of the center pixel. Note that a pixel in the secondary neighborhood may be selected as a neighboring pixel, or a pixel within a radius R around the selected pixel may be selected.
[0029]
Next, the CPU 10 calculates the distance d i (I = 1 to 4) are all predetermined thresholds T d It is determined whether it is the following (step S33). Note that the distance d i Is the threshold T d If it is less than or equal to, the neighboring pixel i is estimated to be a white pixel, and the distance d i Is the threshold T d If it is larger, it is estimated that the neighboring pixel i is not a white pixel. Then, if the determination result in step S33 is positive, the CPU 10 determines that the area including the center pixel and the neighboring pixels (i = 1 to 4) is a white area. As described above, the CPU 10 estimates a white area included in the target image. Then, an average pixel value of these pixels is calculated (step S34). This average pixel value becomes a temporary illumination parameter of the target image data (hereinafter, referred to as a temporary illumination parameter).
[0030]
If the result of the determination in step S33 is negative, the CPU 10 stores the data in the RAM 18 (when the saturation is s Of the following pixels), the pixel having the highest lightness is removed (step S35), and the process proceeds to step S31.
[0031]
After step S34, the CPU 10 calculates each Euclidean distance between the provisional illumination parameter of the target image data and the illumination parameters of each of the k illumination conditions stored in the correction parameter database 19a. Then, of these distances, the minimum distance is detected, and the illumination parameter when the minimum distance is reached is detected. As described above, the illumination parameters of the target image data are estimated. Next, the CPU 10 reads out the color conversion parameters (here, the weight coefficients of the neural network) stored in association with the illumination parameters from the correction parameter database 19a. In the present embodiment, the shortest distance is used for estimating the illumination parameter, but a simple similarity may be used.
[0032]
Next, the CPU 10 converts the pixel value of each pixel included in the target image data stored in the RAM 18 using the read color conversion parameter, thereby reducing the color distortion of the image represented by the target image data. to correct. Thereafter, the color system of the target image data is converted to a color system before conversion to a color system having hue, saturation, and brightness as axes. Then, the converted target image data is output. As described above, the corrected image data representing the image obtained by correcting the color distortion with respect to the target image data is output.
[0033]
The above-described color distortion correction device 1 can correct the color distortion of the image of the photographing target by estimating the illumination condition when the photographing target is photographed even if the color chart is not photographed together with the photographing target. it can. Therefore, it is preferable to handle a small target image such as an ID tag in which information such as a color barcode is captured. Furthermore, by analyzing only the data in the white area without analyzing the data of each color included in the target image data, the processing for correcting the color distortion can be performed in a short time without correcting the distortion of each color. It can be performed. Therefore, the present invention is also suitable for a target image that needs to be subjected to color distortion correction processing in a short time, such as the above-described ID tag used for physical distribution management.
[0034]
When the color chart and the photographing target are photographed by a photographing machine that outputs a photographed image such as a digital camera as digital image data, the photographed image data does not pass through the image input unit 12 and is not shown in the figure. The configuration may be such that it is supplied to the CPU 10 via an interface.
[0035]
(3. Modified example)
As described above, the embodiments of the present invention have been described, but the present invention can be embodied in various other forms without departing from the main features. Note that, for example, the following modifications are possible.
[0036]
<1. Another example of color conversion parameter calculation processing>
In the above-described color conversion parameter calculation processing, the color conversion parameter is calculated using a neural network, but may be calculated using linear conversion. Note that the configuration of this modification is substantially the same as that of the above-described embodiment, and a description thereof will be omitted. Also, regarding the operation of the present modified example, the operation until the illumination parameter calculation processing described in <1> Operation of storing correction parameters described above is substantially the same as that of the above-described embodiment, and therefore will be described. Is omitted.
After completing the illumination parameter calculation process, the CPU 10 then, in the same manner as the above-described process, determines each pixel value of each reference color chart data included in the reference data stored in the HD 19 and the value of k stored in the RAM 18. The average pixel value of each color chart data included in one color chart image data among the pieces of color chart image data is calculated.
Next, the CPU 10 performs the following conversion matrix calculation process using the learning data as each average pixel value for each color patch data and the teacher data as each pixel value for each reference color patch data.
[0037]
FIG. 9 shows the flow of the transformation matrix calculation process.
The CPU 10 selects one color chart corresponding to each of the learning data and the teacher data as a representative color chart, and determines a pixel value (hereinafter, referred to as a representative pixel value) relating to the representative color chart from the learning data and the teacher data. Select each. Then, a coefficient of a conversion matrix for converting the representative pixel value of the learning data into the representative pixel value of the teacher data is calculated (step S40). FIG. 10 shows examples of the learning data, the teacher data, and the transformation matrix. In the figure, H of the teacher data t (T = 1 to n) represents a hue value, and S t (T = 1 to n) represents a saturation value, and I t (T = 1 to n) represent lightness values, which are represented as a matrix with 3 rows and 1 column. Similarly, the learning data H l (1 = 1 to n) represents a hue value, and S l (L = 1 to n) represents the value of saturation, and I l (L = 1 to n) represent brightness values, which are represented as a matrix with 3 rows and 1 column. The transformation matrix is represented as a 3-by-3 matrix, and each a of the transformation matrix pq (P = 1 to 3, q = 1 to 3) represent coefficients in the p-th row and the q-th column, respectively. The representative pixel value of the learning data is converted into a representative pixel value of the teacher data when matrix conversion is performed using this conversion matrix.
[0038]
Next, the CPU 10 performs a matrix conversion using the conversion matrix on the average pixel value of each color patch other than the representative color patch included in the learning data, and converts the converted average pixel value of each color patch (hereinafter, referred to as a conversion pixel value). ) Is calculated (step S41). Then, an error (here, a root-mean-square error) is obtained for the converted pixel value for each color patch and the pixel value for each reference color patch included in the teacher data for each corresponding color patch data. Further, the sum of these errors (hereinafter referred to as the sum of the root mean square errors) is calculated (step S42).
[0039]
Next, a pixel value relating to one color patch is selected from among the pixel values of each color patch data excluding the above-described representative pixel value, and the processes of steps S40 to S42 are performed using this as a new representative pixel value. A transformation matrix corresponding to the new representative pixel value and a root mean square error sum based on the transformation matrix are calculated. As described above, for all the color patches included in the color chart, the processes of steps S40 to S42 are performed using each color patch as a representative color patch, and the conversion matrix corresponding to each representative pixel value and the root mean square The total error is calculated. When the processes of steps S40 to S42 are completed for all the representative color patches, the determination result of step S43 becomes affirmative, and the process proceeds to step S44. In step S44, the CPU 10 detects the minimum value of the sum of the root mean square errors corresponding to the representative pixel values for each representative color chip. Next, a conversion matrix for the representative pixel value is detected (step S43). This conversion matrix is a color conversion parameter for the color chart image data captured under this lighting condition.
[0040]
The CPU 10 performs the conversion matrix processing of steps S40 to S44 as described above on the remaining (k-1) color chart image data, thereby supporting the k color chart image data under each lighting condition. Is obtained (here, a conversion matrix). The CPU 10 stores them in the correction parameter database 19a in association with the illumination parameters for each color chart image data in the same manner as in the above-described color conversion parameter calculation processing.
[0041]
Thereafter, at the time of color distortion correction of the target image data, a color conversion parameter corresponding to the target image data is read from the correction parameter database 19a, and the pixel value of each pixel included in the target image data is converted by linear conversion. You can do it.
[0042]
<2. Equip the mobile terminal with the function of the color distortion correction device 1>
The function of the color distortion correction device 1 described above may be provided in a portable terminal having a wireless communication function. Furthermore, if the portable terminal having a photographing function is provided, a color image can be photographed anytime and anywhere with this portable terminal.In addition, regardless of lighting conditions at the time of photographing, photographing is performed under predetermined lighting conditions. A color image equivalent to a color image can always be obtained. Further, since the obtained color image can be transmitted to another communication device by a wireless communication function, it can be applied to various things.
[0043]
【The invention's effect】
It is possible to effectively use a photographing region for photographing a photographing target including a white region, and to perform processing for correcting color distortion of an image obtained by photographing the photographing target in a short time.
[Brief description of the drawings]
FIG. 1 is a block diagram illustrating a functional configuration of a color distortion correction device 1 according to an embodiment of the present invention.
FIG. 2 is a block diagram showing a hardware configuration of the color distortion correction device 1 according to the embodiment.
FIG. 3 is a diagram illustrating a color chart according to the embodiment;
FIG. 4 is a diagram illustrating a neural network according to the embodiment;
FIG. 5 is a diagram exemplifying a color barcode to be photographed according to the embodiment;
FIG. 6 is a flowchart showing a flow of an illumination parameter calculation process according to the embodiment.
FIG. 7 is a flowchart showing a flow of a color conversion parameter calculation process according to the embodiment.
FIG. 8 is a flowchart showing a flow of an illumination parameter estimation process according to the embodiment.
FIG. 9 is a flowchart illustrating a flow of a transformation matrix calculation process according to another example of the embodiment.
FIG. 10 is a diagram illustrating an example of a calculation formula of a transformation matrix according to the example.
[Explanation of symbols]
Reference Signs List 1 correction device, 11 bus, 12 image input unit, 13 operation input unit, 14 display unit, 16 storage unit, 17 ROM, 18 ... RAM, 19 ... HD, 19a ... Correction parameter database.

Claims (13)

複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて記憶手段に予め記憶させる補正パラメータ記憶ステップと、
任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得ステップと、
前記対象取得ステップで取得された画像データについて、その照明条件を推定する推定ステップと、
前記推定ステップで推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得ステップで取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正ステップと
を備えることを特徴とする色歪み補正方法。
Using each image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, lighting condition information indicating characteristics of each lighting condition, and under each lighting condition A correction parameter storing step of obtaining color conversion information for correcting color distortion of an image, storing the obtained illumination condition information and the color conversion information in a storage unit in advance, and
A target obtaining step of obtaining image data representing an image obtained by shooting a shooting target including a white region under arbitrary lighting conditions,
For the image data acquired in the target acquisition step, an estimation step of estimating the illumination condition,
By using the color conversion information stored in the storage unit in association with the illumination condition information indicating the feature of the illumination condition estimated in the estimation step, by changing the image data acquired in the target acquisition step And correcting the color distortion of the image represented by the image data.
前記推定ステップは、
前記対象取得ステップで取得された画像データに含まれる各画素について、画素毎に色相と彩度と明度とを算出し、当該画像データの表色系を色相と彩度と明度とを用いた表色系に変換する表色系変換ステップと、
前記表色系変換ステップで算出された画素毎の色相と彩度と明度とを用いて、前記撮影対象の撮影時における照明条件の特徴を示す照明条件情報を求める照明パラメータ算出ステップと、
前記記憶手段に記憶されている照明条件情報のうち、前記照明パラメータ算出ステップで求められた照明条件情報と最も類似する照明条件情報を検出する照明条件検出ステップと
を備え、
前記照明条件検出ステップで検出された照明条件情報にその特徴が示される照明条件が、前記撮影対象の撮影時における照明条件であると推定する
ことを特徴とする請求項1に記載の色歪み補正方法。
The estimating step includes:
For each pixel included in the image data obtained in the target obtaining step, a hue, a saturation, and a brightness are calculated for each pixel, and a color system of the image data is calculated using the hue, the saturation, and the brightness. A color system conversion step for converting to a color system;
Using the hue, saturation, and brightness of each pixel calculated in the color system conversion step, an illumination parameter calculation step of obtaining illumination condition information indicating characteristics of illumination conditions at the time of shooting the shooting target,
An illumination condition detection step of detecting illumination condition information most similar to the illumination condition information obtained in the illumination parameter calculation step, out of the illumination condition information stored in the storage means,
2. The color distortion correction according to claim 1, wherein the illumination condition whose characteristics are indicated in the illumination condition information detected in the illumination condition detection step is estimated to be an illumination condition when the imaging target is photographed. Method.
前記補正ステップは、
前記照明条件検出ステップで検出された照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を読み出すカラー変換パラメータ選択ステップと、
前記カラー変換パラメータ選択ステップで読み出された色変換情報を用いて、前記対象取得ステップで取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正するカラー変換ステップと、
前記カラー変換ステップで変更された画像データの表色系を、前記表色系変換ステップで色相と彩度と明度とを用いた表色系に変換する前の表色系に変換する表色系逆変換ステップと
を備えることを特徴とする請求項2に記載の色歪み補正方法。
The correcting step includes:
A color conversion parameter selection step of reading color conversion information stored in the storage unit in association with the illumination condition information detected in the illumination condition detection step;
Color conversion for correcting color distortion of an image represented by the image data by changing the image data obtained in the object obtaining step using the color conversion information read in the color conversion parameter selecting step. Steps and
A color system for converting the color system of the image data changed in the color conversion step to a color system before conversion to a color system using hue, saturation, and lightness in the color system conversion step. 3. The color distortion correction method according to claim 2, further comprising an inverse conversion step.
前記補正パラメータ記憶ステップは、
異なる照明条件毎に前記カラーチャートを撮影して得られる画像を表す画像データを取得するカラーチャート画像取得ステップと、
前記カラーチャート画像取得ステップで取得された各画像データに含まれる各色票に対応する色相と彩度と明度とを算出し、当該画像データの表色系を色相と彩度と明度とを用いた表色系に変換する表色系変換ステップと、
補正基準となる前記カラーチャートの有する各色票に対応する色相と彩度と明度とを取得する基準データ取得ステップと、
前記表色系変換ステップで算出された色相と彩度と明度とを用いて、前記カラーチャートの撮影時における照明条件の特徴を示す照明条件情報を求める照明パラメータ算出ステップと、
前記表色系変換ステップで算出された各色票に対応する色相と彩度と明度と、前記基準データ取得ステップで取得された各色票に対応する色相と彩度と明度との対応関係を解析し、前記カラーチャートを撮影して得られる画像の色歪みを補正するための色変換情報を照明条件毎に求めるカラー変換パラメータ算出ステップと、
前記照明パラメータ算出ステップで求められた照明条件情報と、前記カラー変換パラメータ算出ステップで求められた色変換情報とを関連付けて前記記憶手段に記憶させるデータベース記憶ステップと
を備えることを特徴とする請求項1に記載の色歪み補正方法。
The correction parameter storing step includes:
A color chart image obtaining step of obtaining image data representing an image obtained by shooting the color chart for each different lighting condition,
The hue, saturation, and brightness corresponding to each color chart included in each image data acquired in the color chart image acquisition step were calculated, and the color system of the image data was calculated using hue, saturation, and brightness. A color system conversion step for converting to a color system;
Reference data acquisition step of acquiring hue, saturation, and lightness corresponding to each color chart having the color chart as a correction reference,
Using the hue, saturation, and lightness calculated in the color system conversion step, an illumination parameter calculation step of obtaining illumination condition information indicating a feature of an illumination condition during shooting of the color chart,
The hue, saturation, and lightness corresponding to each color chart calculated in the color system conversion step, and the correspondence between the hue, saturation, and lightness corresponding to each color chart obtained in the reference data acquisition step are analyzed. A color conversion parameter calculating step of obtaining color conversion information for each illumination condition to correct color distortion of an image obtained by photographing the color chart;
A database storage step of storing the illumination condition information obtained in the illumination parameter calculation step and the color conversion information obtained in the color conversion parameter calculation step in the storage unit in association with each other. 2. The color distortion correction method according to 1.
前記照明パラメータ算出ステップは、
前記撮影対象を撮影して得られる画像を表す画像データのうち当該画像に含まれる白色領域を表すデータ部分を推定する又は前記カラーチャートを撮影して得られる画像を表す画像データのうち当該画像に含まれる白色領域を表すデータ部分を取得する白色識別ステップと、
前記白色識別ステップで推定又は取得されたデータ部分に含まれる各画素について、画素毎の色相と彩度と明度とを算出する白色画素値算出ステップと、
前記白色画素値算出ステップで算出された色相と彩度と明度とを用いて、前記照明条件情報を求める算出ステップと
を備えることを特徴とする請求項2又は4に記載の色歪み補正方法。
The lighting parameter calculation step,
In the image data representing the image obtained by photographing the photographing target, the data portion representing the white area included in the image is estimated, or the image data representing the image obtained by photographing the color chart is subjected to the image. A white color identification step of obtaining a data portion representing a included white area;
For each pixel included in the data portion estimated or obtained in the white identification step, a white pixel value calculation step of calculating hue, saturation, and brightness for each pixel,
The color distortion correction method according to claim 2, further comprising: a calculating step of obtaining the illumination condition information using the hue, saturation, and brightness calculated in the white pixel value calculating step.
情報を記憶する記憶手段と、
複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて前記記憶手段に予め記憶させる補正パラメータ記憶手段と、
任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得手段と、
前記対象取得手段で取得された画像データについて、その照明条件を推定する推定手段と、
前記推定手段で推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得手段で取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正手段と
を備えることを特徴とする色歪み補正装置。
Storage means for storing information;
Using each image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, lighting condition information indicating characteristics of each lighting condition, and under each lighting condition Correction parameter storage means for obtaining color conversion information for correcting color distortion of an image, associating the obtained illumination condition information and the color conversion information with the storage means in advance, and
Target acquisition means for acquiring image data representing an image obtained by photographing a photographing target including a white region under arbitrary lighting conditions,
Estimating means for estimating the lighting conditions of the image data acquired by the object acquiring means,
By using the color conversion information stored in the storage unit in association with the illumination condition information indicating the feature of the illumination condition estimated by the estimation unit, by changing the image data acquired by the target acquisition unit A color distortion correcting device for correcting color distortion of an image represented by the image data.
前記推定手段は、
前記対象取得手段で取得された画像データに含まれる各画素について、画素毎に色相と彩度と明度とを算出し、当該画像データの表色系を色相と彩度と明度とを用いた表色系に変換する表色系変換手段と、
前記表色系変換手段で算出された画素毎の色相と彩度と明度とを用いて、前記撮影対象の撮影時における照明条件の特徴を示す照明条件情報を求める照明パラメータ算出手段と、
前記記憶手段に記憶されている照明条件情報のうち、前記照明パラメータ算出手段で求められた照明条件情報と最も類似する照明条件情報を検出する照明条件検出手段と
を備え、
前記照明条件検出手段で検出された照明条件情報にその特徴が示される照明条件が、前記撮影対象の撮影時における照明条件であると推定する
ことを特徴とする請求項6に記載の色歪み補正装置。
The estimating means includes:
For each pixel included in the image data obtained by the target obtaining unit, a hue, a saturation, and a brightness are calculated for each pixel, and a color system of the image data is calculated using the hue, the saturation, and the brightness. A color system conversion means for converting to a color system;
Using hue, saturation, and brightness of each pixel calculated by the color system conversion unit, an illumination parameter calculation unit that obtains illumination condition information indicating characteristics of illumination conditions at the time of shooting the shooting target,
Among the illumination condition information stored in the storage unit, the illumination condition information detection unit that detects the illumination condition information most similar to the illumination condition information obtained by the illumination parameter calculation unit,
7. The color distortion correction according to claim 6, wherein the illumination condition indicated by the illumination condition information detected by the illumination condition detection unit is estimated to be an illumination condition at the time of photographing of the photographing target. apparatus.
前記補正手段は、
前記照明条件検出手段で検出された照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を読み出すカラー変換パラメータ選択手段と、
前記カラー変換パラメータ選択手段で読み出された色変換情報を用いて、前記対象取得手段で取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正するカラー変換手段と、
前記カラー変換手段で変更された画像データの表色系を、前記表色系変換手段で色相と彩度と明度とを用いた表色系に変換する前の表色系に変換する表色系逆変換手段と
を備えることを特徴とする請求項7に記載の色歪み補正装置。
The correction means,
A color conversion parameter selection unit that reads out color conversion information stored in the storage unit in association with the illumination condition information detected by the illumination condition detection unit;
Color conversion for correcting color distortion of an image represented by the image data by changing the image data acquired by the object acquisition unit using the color conversion information read by the color conversion parameter selection unit. Means,
A color system for converting the color system of the image data changed by the color conversion unit to a color system before conversion to a color system using hue, saturation, and lightness by the color system conversion unit. The color distortion correction device according to claim 7, further comprising an inverse conversion unit.
前記補正パラメータ記憶手段は、
異なる照明条件毎に前記カラーチャートを撮影して得られる画像を表す画像データを取得するカラーチャート画像取得手段と、
前記カラーチャート画像取得手段で取得された画像データに含まれる各色票に対応する色相と彩度と明度とを算出し、当該画像データの表色系を色相と彩度と明度とを用いた表色系に変換する表色系変換手段と、
補正基準となる前記カラーチャートの有する各色票に対応する色相と彩度と明度とを取得する基準データ取得手段と、
前記表色系変換手段で算出された色相と彩度と明度とを用いて、前記カラーチャートの撮影時における照明条件の特徴を示す照明条件情報を求める照明パラメータ算出手段と、
前記表色系変換手段で算出された各色票に対応する色相と彩度と明度と、前記基準データ取得手段で取得された各色票に対応する色相と彩度と明度との対応関係を解析し、前記カラーチャートを撮影して得られる画像の色歪みを補正するための色変換情報を照明条件毎に求める前記カラー変換パラメータ算出手段と、
前記照明パラメータ算出手段で求められた照明条件情報と、前記カラー変換パラメータ算出手段で求められた色変換情報とを関連付けて前記記憶手段に記憶させるデータベース記憶手段と、
を備えることを特徴とする請求項6に記載の色歪み補正装置。
The correction parameter storage means,
Color chart image acquisition means for acquiring image data representing an image obtained by photographing the color chart for each different lighting condition,
The hue, saturation, and brightness corresponding to each color chart included in the image data acquired by the color chart image acquisition means are calculated, and the color system of the image data is calculated using the hue, saturation, and brightness. A color system conversion means for converting to a color system;
Reference data acquisition means for acquiring hue, saturation, and lightness corresponding to each color chart having the color chart as a correction reference,
Using hue, saturation, and brightness calculated by the color system conversion unit, an illumination parameter calculation unit that obtains illumination condition information indicating characteristics of illumination conditions at the time of shooting the color chart,
The hue, saturation, and lightness corresponding to each color chart calculated by the color system conversion means, and the correspondence between the hue, saturation, and lightness corresponding to each color chart acquired by the reference data acquisition means are analyzed. The color conversion parameter calculation means for obtaining color conversion information for correcting color distortion of an image obtained by photographing the color chart for each illumination condition,
Database storage means for storing the illumination condition information obtained by the illumination parameter calculation means and the color conversion information obtained by the color conversion parameter calculation means in the storage means in association with each other;
The color distortion correction device according to claim 6, further comprising:
前記照明パラメータ算出手段は、
前記撮影対象を撮影して得られる画像を表す画像データのうち当該画像に含まれる白色領域を表すデータ部分を推定する又は前記カラーチャートを撮影して得られる画像を表す画像データのうち当該画像に含まれる白色領域を表すデータ部分を取得する白色識別手段と、
前記白色識別手段で推定又は取得されたデータ部分に含まれる各画素について、画素毎の色相と彩度と明度とを算出する白色画素値算出手段と、
前記白色画素値算出手段で算出された色相と彩度と明度とを用いて、前記照明条件情報を求める算出手段と、
を備えることを特徴とする請求項7又は9に記載の色歪み補正装置。
The lighting parameter calculation means,
In the image data representing the image obtained by photographing the photographing target, the data portion representing the white area included in the image is estimated, or the image data representing the image obtained by photographing the color chart is subjected to the image. White identification means for acquiring a data portion representing a white area included therein,
For each pixel included in the data portion estimated or obtained by the white identification unit, a white pixel value calculation unit that calculates hue, saturation, and lightness of each pixel,
Using hue, saturation, and brightness calculated by the white pixel value calculation unit, a calculation unit that obtains the illumination condition information,
The color distortion correction device according to claim 7, further comprising:
情報を記憶する記憶手段と、
複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて前記記憶手段に予め記憶させる補正パラメータ記憶手段と、
任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得手段と、
前記対象取得手段で取得された画像データについて、その照明条件を推定する推定手段と、
前記推定手段で推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得手段で取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正手段と
を備えることを特徴とする携帯端末。
Storage means for storing information;
Using each image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, lighting condition information indicating characteristics of each lighting condition, and under each lighting condition Correction parameter storage means for obtaining color conversion information for correcting color distortion of an image, associating the obtained illumination condition information and the color conversion information with the storage means in advance, and
Target acquisition means for acquiring image data representing an image obtained by photographing a photographing target including a white region under arbitrary lighting conditions,
Estimating means for estimating the lighting conditions of the image data acquired by the object acquiring means,
By using the color conversion information stored in the storage unit in association with the illumination condition information indicating the feature of the illumination condition estimated by the estimation unit, by changing the image data acquired by the target acquisition unit And a correcting means for correcting color distortion of an image represented by the image data.
コンピュータに、
複数の異なる照明条件下で複数の異なる色票を有するカラーチャートを撮影して得られる各画像を表す各画像データを用いて、各照明条件の特徴を示す照明条件情報と、各照明条件下における画像の色歪みを補正するための色変換情報とを求め、求めた前記照明条件情報と前記色変換情報とを関連付けて記憶手段に予め記憶させる補正パラメータ記憶ステップと、
任意の照明条件下で白色領域を含む撮影対象を撮影して得られる画像を表す画像データを取得する対象取得ステップと、
前記対象取得ステップで取得された画像データについて、その照明条件を推定する推定ステップと、
前記推定ステップで推定された照明条件の特徴を示す照明条件情報と関連付けられて前記記憶手段に記憶されている色変換情報を用いて、前記対象取得ステップで取得された画像データを変更することにより、当該画像データで表される画像の色歪みを補正する補正ステップと
を実行させるためのプログラム。
On the computer,
Using each image data representing each image obtained by photographing a color chart having a plurality of different color charts under a plurality of different lighting conditions, lighting condition information indicating characteristics of each lighting condition, and under each lighting condition A correction parameter storing step of obtaining color conversion information for correcting color distortion of an image, storing the obtained illumination condition information and the color conversion information in a storage unit in advance, and
A target obtaining step of obtaining image data representing an image obtained by shooting a shooting target including a white region under arbitrary lighting conditions,
For the image data acquired in the target acquisition step, an estimation step of estimating the illumination condition,
By using the color conversion information stored in the storage unit in association with the illumination condition information indicating the feature of the illumination condition estimated in the estimation step, by changing the image data acquired in the target acquisition step A correction step for correcting color distortion of an image represented by the image data.
請求項12に記載のプログラムを記憶した記憶媒体。A storage medium storing the program according to claim 12.
JP2003029920A 2003-02-06 2003-02-06 Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium Withdrawn JP2004242099A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003029920A JP2004242099A (en) 2003-02-06 2003-02-06 Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003029920A JP2004242099A (en) 2003-02-06 2003-02-06 Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium

Publications (1)

Publication Number Publication Date
JP2004242099A true JP2004242099A (en) 2004-08-26

Family

ID=32956964

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003029920A Withdrawn JP2004242099A (en) 2003-02-06 2003-02-06 Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium

Country Status (1)

Country Link
JP (1) JP2004242099A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008534951A (en) * 2005-04-01 2008-08-28 ユニバーシティー オブ イースト アングリア Illuminant estimation
KR101023508B1 (en) 2009-10-13 2011-03-21 중앙대학교 산학협력단 Apparatus and method for color correction of image including multiple light sources
US8611660B2 (en) 2009-12-17 2013-12-17 Apple Inc. Detecting illumination in images
US8811729B2 (en) 2006-11-08 2014-08-19 Apple Inc. Illuminant estimation
JP2020530920A (en) * 2018-07-27 2020-10-29 シェンチェン センスタイム テクノロジー カンパニー リミテッドShenzhen Sensetime Technology Co.,Ltd Image lighting methods, devices, electronics and storage media
WO2023095490A1 (en) * 2021-11-26 2023-06-01 新興窯業株式会社 Program, information processing device, information processing method, method for generating learning model, and imaging system

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008534951A (en) * 2005-04-01 2008-08-28 ユニバーシティー オブ イースト アングリア Illuminant estimation
US8811729B2 (en) 2006-11-08 2014-08-19 Apple Inc. Illuminant estimation
KR101023508B1 (en) 2009-10-13 2011-03-21 중앙대학교 산학협력단 Apparatus and method for color correction of image including multiple light sources
US8611660B2 (en) 2009-12-17 2013-12-17 Apple Inc. Detecting illumination in images
JP2020530920A (en) * 2018-07-27 2020-10-29 シェンチェン センスタイム テクノロジー カンパニー リミテッドShenzhen Sensetime Technology Co.,Ltd Image lighting methods, devices, electronics and storage media
US11455516B2 (en) 2018-07-27 2022-09-27 Shenzhen Sensetime Technology Co., Ltd. Image lighting methods and apparatuses, electronic devices, and storage media
WO2023095490A1 (en) * 2021-11-26 2023-06-01 新興窯業株式会社 Program, information processing device, information processing method, method for generating learning model, and imaging system

Similar Documents

Publication Publication Date Title
JP4258550B2 (en) Image processing method, image processing apparatus, and program
US20060153472A1 (en) Blurring correction method and imaging device
US9438768B2 (en) Image processing apparatus, image reading apparatus, image processing method and information storage medium
JP2005354278A (en) Image data processing apparatus for processing image data of image picked up by imaging means
US20090274368A1 (en) Image correction method and apparatus
JP2006222899A (en) Image processing apparatus and image processing method
KR20100076342A (en) Method for detecting and correcting bad pixels in image sensor
US20040247197A1 (en) Correction parameter determining method, correction parameter determining apparatus, computer program, and recording medium
JP2004242099A (en) Color distortion correction method, color distortion correction device, mobile terminal, program, and storage medium
JP4527500B2 (en) Image processing method, apparatus, and program
CN117095417A (en) Screen shot form image text recognition method, device, equipment and storage medium
JP2000242261A (en) Image display method, image processor, and recording medium
JP2005184685A (en) Image processing device, program, and recording medium
JP2004350212A (en) System and method for image processing
JP4800724B2 (en) Person image correction apparatus, person image correction method, and person image correction program
JP2019106173A (en) Image processing method, image processing apparatus and program
EP2541469B1 (en) Image recognition device, image recognition method and image recognition program
JP2019012424A (en) Image processing device and computer program
JP2004185183A (en) Image correction device, character recognition method, and image correction program
WO2019116975A1 (en) Image processing method, image processing device, and program
CN111242087A (en) Object recognition method and device
JP2005293554A (en) Determination of main object in image
JP5069599B2 (en) Video conversion apparatus, video conversion method, and video conversion program
JP4769416B2 (en) Image processing apparatus and image processing method
JP2827973B2 (en) Image processing apparatus and image processing method

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20060509