JP2009152725A - Automatic tracing apparatus and method - Google Patents
Automatic tracing apparatus and method Download PDFInfo
- Publication number
- JP2009152725A JP2009152725A JP2007327208A JP2007327208A JP2009152725A JP 2009152725 A JP2009152725 A JP 2009152725A JP 2007327208 A JP2007327208 A JP 2007327208A JP 2007327208 A JP2007327208 A JP 2007327208A JP 2009152725 A JP2009152725 A JP 2009152725A
- Authority
- JP
- Japan
- Prior art keywords
- image
- standard pattern
- value
- correlation
- pixel
- 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.)
- Pending
Links
Images
Landscapes
- Focusing (AREA)
- Automatic Focus Adjustment (AREA)
- Studio Devices (AREA)
Abstract
Description
本発明は、オートフォーカスや監視装置等に用いられる被写体の自動追跡装置及び方法に関するものである。 The present invention relates to an automatic tracking device and method for an object used for autofocus, a monitoring device, and the like.
撮影装置、例えばデジタルカメラでは、その多くがオートフォーカス機能を備えているこのようなデジタルカメラでは、撮影画面上にオートフォーカスエリア(以下、AFエリアと称する)が設定されており、このAFエリアに被写体を重ねることによって、その被写体に自動的にピントが合致するように撮影レンズのピント調節が行われる。 In such a digital camera, many of which are equipped with an autofocus function in a photographing apparatus, for example, a digital camera, an autofocus area (hereinafter referred to as an AF area) is set on the photographing screen. When the subject is overlapped, the focus of the photographic lens is adjusted so that the subject automatically comes into focus.
また、対象となる被写体(以下、対象被写体という)の移動に対して、AFエリアを追従させて移動させ、常に対象被写体にピントが合致するように対象被写体を追跡する機能を有したデジタルカメラも知られている。このように、AFエリアが対象被写体を追従するには、例えば対象被写体の画像を標準パターンとしてパターンマッチング処理を行い、対象被写体の画像と相関性の高い画像部分を撮影画像中から検出している。 Also, there is a digital camera having a function of tracking the target subject so that the subject is always in focus by moving the target subject (hereinafter referred to as the target subject) by following the AF area. Are known. In this way, in order for the AF area to follow the target subject, for example, pattern matching processing is performed using the target subject image as a standard pattern, and an image portion highly correlated with the target subject image is detected from the captured image. .
ところで、パターンマッチング処理の際に、初期設定された標準パターンを継続して用いた場合、撮影画面上における対象被写体の大きさや向き、明るさ、向き等の変化が生じると、標準パターンとして保持されている対象被写体の画像と実際の対象被写体の画像との差異が大きくなって対象被写体を検出できなくなってしまう。そこで、検出された領域の画像を新たな標準パターンとするようにして、順次に標準パターンを更新するものもある(例えば、特許文献1を参照)。この特許文献1では、標準パターンと、この標準パターンを用いて検出された領域画像との平均値や線形結合演算を施して得られる画像を新たな標準パターンとしている。 By the way, when the default standard pattern is continuously used in the pattern matching process, if a change in the size, orientation, brightness, orientation, etc. of the target subject on the shooting screen occurs, the standard pattern is retained. The difference between the target subject image and the actual target subject image becomes large, and the target subject cannot be detected. Therefore, there is a technique in which the standard pattern is sequentially updated so that the image of the detected area becomes a new standard pattern (see, for example, Patent Document 1). In Patent Document 1, an average value of a standard pattern and a region image detected using the standard pattern or an image obtained by performing a linear combination operation is used as a new standard pattern.
一方、上記のように標準パターンを順次に更新するようにした場合、対象被写体に他の物体が映り込んだり、対象被写体の前面を遮蔽物が通過したりする等したときには、それにより標準パターンが変化し、最終的に標準パターンが遮蔽物の画像に置き換わってしまうことがある。そして、標準パターンが遮蔽物の画像に置き換わると、対象被写体を追跡することができなくなってしまう。そこで、このような問題を解決するために、特許文献2では、異なる時刻に得られた複数の標準パターンを用いたパターンマッチング処理が提案されている。
On the other hand, when the standard pattern is sequentially updated as described above, when another object is reflected in the target subject, or when a shield passes through the front of the target subject, the standard pattern is thereby changed. In some cases, the standard pattern may be replaced with an image of the shielding object. If the standard pattern is replaced with an image of the shielding object, the target subject cannot be tracked. Therefore, in order to solve such a problem,
特許文献2では、過去に用いた標準パターンを含む複数の標準パターンを用いて、パターンマッチング処理を行い、その複数の標準パターンのそれぞれ最大一致度の中で、一番大きな一致度を得る標準パターンに基づいて検出された領域画像の位置を対象被写体の位置とし、その位置の領域画像を新たな標準パターンに加えている。
上記特許文献2のように、複数の標準パターンを用いる手法は、遮蔽物の通過などにより標準パターンが遮蔽物の画像となって対象被写体の追跡が困難になることを防止する効果はある。しかしながら、時間的に古い対象被写体の画像からなる標準パターンが最新の標準パターンとともに用いられるため、十分な精度で対象被写体を検出できず、結果として追跡精度が低くなるという問題があった。
As described in
本発明は、上記問題を解決するためになされたもので、遮蔽物の通過などによって追跡すべき対象被写体に遮蔽が生じたり、映り込みが生じたりしても、対象被写体を精度よく検出して追跡することができる自動追跡装置及び方法を提供することを目的とする。 The present invention has been made to solve the above-described problems, and can accurately detect a target subject even if the target subject to be tracked is blocked or reflected due to passage of a shield or the like. It is an object of the present invention to provide an automatic tracking apparatus and method capable of tracking.
上記問題を解決するために、本発明の請求項1記載の追跡装置では、特定の被写体の画像を標準パターンとして保持する保持手段と、入力画像中から保持手段に記憶されている標準パターンと最も合致する画像の領域をパターンマッチング処理によって検出するマッチング処理手段と、マッチング処理手段で検出された領域の画像を当該入力画像中から領域画像として抽出する抽出手段と、保持手段に保持されている標準パターンと抽出された領域画像との相関性の高低を判定する判定手段と、判定手段によって相関性が低いと判定された場合に、標準パターンと領域画像の対応する画素同士の輝度値の差分絶対値が所定の上限値以上である領域画像の各画素について、その差分絶対値を小さくする補正処理を行う補正手段と、判定手段によって相関性が低いと判定されたときには、補正手段で補正された領域画像を新たな標準パターンとし、相関性が高いと判定されたときには、抽出手段で抽出された領域画像を新たな標準パターンとして保持手段に保持する標準パターンを更新する更新制御手段とを備えたものである。 In order to solve the above problem, in the tracking device according to claim 1 of the present invention, a holding unit that holds an image of a specific subject as a standard pattern, a standard pattern stored in the holding unit from the input image, A matching processing means for detecting a matching image area by pattern matching processing, an extraction means for extracting an image of the area detected by the matching processing means as an area image from the input image, and a standard held in the holding means The determination means for determining the level of correlation between the pattern and the extracted area image, and the difference in luminance value between corresponding pixels of the standard pattern and the area image when the determination means determines that the correlation is low For each pixel of the region image whose value is equal to or greater than a predetermined upper limit value, a correction unit that performs a correction process for reducing the absolute difference value, and a determination unit When the correlation is determined to be low, the area image corrected by the correction means is set as a new standard pattern. When the correlation is determined to be high, the area image extracted by the extraction means is set as a new standard pattern. Update control means for updating the standard pattern held in the holding means.
請求項2記載の自動追跡装置では、判定手段を、標準パターンと領域画像の対応する画素同士の輝度値の差分絶対値をそれぞれ求め、各画素の差分絶対値を積算した差分積算値が所定のしきい値よりも小さいときに、相関性が高いと判定するようにしたものである。
In the automatic tracking device according to
請求項3記載の自動追跡装置では、補正手段を、補正処理の対象となる領域画像の画素について、その輝度値が対応する標準パターンの画素の輝度値よりも大きい場合には、その標準パターンの画素の輝度値に上限値を加算した輝度値に置き換え、対応する標準パターンの画素の輝度値よりも小さい場合には、その標準パターンの画素の輝度値から上限値を減算した輝度値に置き換えるようにしたものである。 In the automatic tracking device according to claim 3, when the luminance value of the pixel of the region image to be corrected is larger than the luminance value of the pixel of the corresponding standard pattern, Replace with the luminance value obtained by adding the upper limit value to the luminance value of the pixel, and if the luminance value is smaller than the luminance value of the pixel of the corresponding standard pattern, replace it with the luminance value obtained by subtracting the upper limit value from the luminance value of the pixel of the standard pattern. It is a thing.
請求項4記載の自動追跡装置では、補正手段を、補正処理の対象となる領域画像の画素について、その輝度を対応する標準パターンの画素の輝度値との平均値に置き換えるようにしたものである。
In the automatic tracking device according to
請求項5記載の自動追跡方法では、入力画像が入力されるごとに、保持している標準パターンと最も合致する画像の領域をパターンマッチング処理によって検出するマッチングステップと、標準パターンと検出された領域の画像との相関性の高低を判定する判定ステップと、判定ステップによって相関性が低いと判定されたときに、検出された領域の画像の画素のうち、標準パターンの対応する画素との輝度値の差分絶対値が所定の上限値以上である画素に対して差分絶対値を小さくする補正ステップと、判定ステップによって相関性が低いと判定されたときに、補正ステップによって補正された特定された領域の画像を新たな標準パターンとし、相関性が高いと判定されたときに、特定された領域の画像を新たな標準パターンとする更新ステップとを有するものである。
6. The automatic tracking method according to
本発明によれば、標準パターンをパターンマッチング処理によって特定した領域の領域画像で順次更新する際に、標準パターンと検出した領域画像の相関性が低い場合には、標準パターンと領域画像の対応する位置の画素同士の輝度値の差分絶対値が所定値以上である領域画像の各画素について、その差分絶対値を小さくする補正処理を行うようにしたから、遮蔽物の通過や映り込み等によって領域画像に生じる輝度変化に制限がかかり、新たな標準パターンと対象被写体との相関性が著しく低下しないようにしたから、遮蔽物の通過や映り込み等が生じても、対象被写体を精度よく検出して追跡することができる。 According to the present invention, when the standard pattern is sequentially updated with the region image of the region specified by the pattern matching process, if the standard pattern and the detected region image have low correlation, the standard pattern corresponds to the region image. Since each pixel of the region image in which the absolute value of the luminance value between the pixels at the position is greater than or equal to a predetermined value is corrected, the correction is performed to reduce the absolute value of the difference. The luminance change that occurs in the image is limited, and the correlation between the new standard pattern and the target subject is not significantly reduced, so the target subject can be detected accurately even if an obstacle passes or is reflected. Can be tracked.
図1に本発明を実施したデジタルカメラ2の構成を示す。システムコントローラ3は、操作部4からの各種操作信号に基づいて、デジタルカメラ2の撮影部5、自動追跡部6を制御する。操作部4は、撮影を指示するためのレリーズボタンや、各種設定を行うための操作ボタン,キーなどから構成されている。この操作部4を操作することにより、後述するAFエリアの初期設定を行うことができる。
FIG. 1 shows a configuration of a
撮影部5には、撮影レンズ10を設けてあり、この撮影レンズ10の背後にイメージセンサ11を配してある。被写体光は、撮影レンズ10を透過しイメージセンサ11の受光面に入射する。撮影レンズ10は、ピントを調節するフォーカス機構12を備えている。このフォーカス機構12は、フォーカスレンズ12aと、フォーカスレンズ12aを光軸方向に移動するモータやモータドライバ等で構成してあり、フォーカスレンズ12aの移動によってピントを調節する。
The photographing
イメージセンサ11は、被写体を撮影して撮影画像を出力するものであり、その受光面に多数の受光素子を備え、撮影レンズ10によって結像される被写体像を電気的な画像信号に変換して出力する。なお、イメージセンサ11としては、CCD型やMOS型等の各種のものを用いることができる。
The
信号処理部13は、イメージセンサ11からの画像信号に対して、各種信号処理を行う。この信号処理部13は、イメージセンサ11からの画像信号に対して信号増幅処理,デジタル変換処理,γ補正処理,ホワイトバランス補正処理等の信号処理を行って得られる画像データを出力する。
The
画像記録部14は、レリーズボタンの操作で撮影指示がされた際に、その操作に応答して撮影された静止画の撮影画像を記憶するものであり、例えばデジタルカメラ2に着脱自在なメモリカードと、それに対して画像データの読み出し書き込みを行う回路等で構成されている。
The image recording unit 14 stores a photographed image of a still image photographed in response to an operation when a photographing instruction is given by operating the release button. For example, the memory card is detachable from the
表示部15は、画像を表示するLCDやそれを駆動するドライバ等からなり、信号処理部13からの画像データが次々に送られることによって、それに基づいてスルー画像を表示する。撮影者は、そのスルー画像を観察することによってフレーミングを行うことができる。また、この表示部15には、スルー画像に重ねてAFエリアを示すAF枠が表示される。撮影者は、表示部15に表示されるAF枠を参照することで、AFエリアの初期設定を行うことができるとともに、自動的に更新されるAFエリアを確認することができる。
The
AF制御部16は、フォーカス機構12とともにAF手段を構成する。このAF制御部16は、フォーカス機構12を作動させて撮影レンズ10のピントが被写体に合致する位置を検出し、その合致するレンズ位置にフォーカスレンズ12aをセットする。AF制御部16は、撮影画面上に設定されるAFエリア内の被写体にピントが合致するようにフォーカス機構12を制御する。
The
AFエリアは、操作部4の操作によって指定される範囲が、自動追跡部6を介してAF制御部16に初期設定され、初期設定後は自動追跡部6によって、対象となる被写体(以下、対象被写体という)の移動にしたがってAFエリアが移動するように自動的に更新・設定される。すなわち、AFエリアが対象被写体を自動的に追跡する。
As for the AF area, a range designated by the operation of the
AF制御部16は、いわゆるコントラスト検出方式によって撮影レンズ10のピントを合致させる。すなわち、信号処理部13からの画像データに基づいて、撮影画像ごとにAFエリア内の画像の高周波成分を積算したAF評価値を求め、このAF評価値が最大となるレンズ位置にフォーカスレンズ12aを移動させる。なお、オートフォーカスの手法は、上記のような被写体像のコントラストによるものに限らない。
The
自動追跡部6は、AFエリアを処理領域とし、特定の被写体である対象被写体を追跡する自動追跡装置となっている。入力部20は、入力画像として信号処理部13から画像データ(撮影画像)を取得する。この取得する画像データとしては、例えば画素ごとの輝度信号レベルに相当する輝度値となっている。
The
入力部20は、撮影画像の輝度の分散を一定程度に均一化する正規化処理を行う。この正規化処理は、撮影画像に全体に行ってもよいが、後述するパターンマッチングを行う領域ごとに正規化処理を行ってもよい。なお、正規化処理を行わなくてもよい。
The
マッチング処理部21は、入力される撮影画像について、その画像データに基づいて標準パターン(テンプレート画像)を用いた周知のパターンマッチング(テンプレートマッチング)処理を行う。このマッチング処理部21は、例えばp×q画素からなる標準パターンと最も合致する、すなわち標準パターンに対して相関値が最も高いp×q画素の画像部分(以下、領域画像という)の領域を検出・特定し、その領域を示す領域情報を出力する。
The matching
マッチング処理部21によるパターンマッチング処理では、撮影画像上において標準パターンと最も合致する領域を特定できるようになっており、領域情報には、その領域の中心位置,大きさ、形状等の情報が含まれる。相関値は、例えば正規化相関パターンマッチング処理を用いる場合においては、標準パターンの輝度値をM、撮影画像中の領域画像の輝度値をIとして、それぞれの画素の個数をN(=p×q)個としたときには、次の式(1)によって相関値(相関係数)rが求められる。
In the pattern matching processing by the matching
抽出部22は、後述する更新制御部23の制御の下で、領域情報に示される領域内の画像、すなわち領域画像を撮影画像から抽出してバッファメモリ24に出力する。また、メモリ部25は、追跡の対象物の画像を標準パターンとして保持するものであり、バッファメモリ24から領域画像を取得して、これを標準パターンとして記憶する。
The
自動追跡の初期設定では、操作部4の操作によって指定されるAF枠に囲まれる領域がAFエリアとされる。抽出部22は、そのAFエリア内の画像を領域画像として抽出し、これがバッファメモリ24を介してメモリ部25に標準パターンとして記憶される。この初期設定以降では、抽出部22は、更新制御部23によって指定される領域の画像を領域画像として抽出し、これがバッファメモリ24に新たな標準パターンとして書き込まれる。メモリ部25は、更新制御部23からの更新信号が入力されることに応答して、バッファメモリ24から領域画像を標準パターンとして取得することで、標準パターンを更新する。
In the initial setting of automatic tracking, the area surrounded by the AF frame designated by the operation of the
更新制御部23は、メモリ部25の標準パターンの更新を制御するとともに、相関値の高低に基づいてパターンマッチングの可否を判定して、AFエリアの更新を制御する。この更新制御部23には、マッチング処理部21からの領域情報と相関値とが入力される。また、更新制御部23には、相関値と比較してAFエリアを更新すべきか否かを判断するための第1しきい値を設定してある。
The
更新制御部23は、相関値が第1しきい値以上である場合に、マッチング処理部21からの領域情報に示される領域を新たなAFエリアとするようにAF制御部16を制御し、また表示部15にその領域を示すAF枠を表示させる。一方、相関値が第1しきい値よりも小さく、十分な相関性が得られる領域を検出できない場合には、AFエリアの再設定を操作者に要求する。
The
補正処理部26は、標準パターンと領域画像の相関性の高低を判定し、相関性が低いときには領域画像を補正する補正処理を行う。相関性の高低を判定は、メモリ部25の標準パターンと、このメモリ部25の標準パターンとマッチングするとして抽出されたバッファメモリ24の領域画像の対応する画素同士の輝度値の差分絶対値を積算した差分積算値が予め設定された第2しきい値以上であるか否かで判定する。第2しきい値よりも小さいときには相関性が高いものとされ、第2しきい値以上である場合の相関性が低いものとされる。なお、第1しきい値を用いた相関性の高低の判定に比べて、第2しきい値を用いた相関性の高低の判定は、相関性が高いと判定される基準が高くされている。
The
補正処理部26には、差分絶対値に対する上限値が予め設定されており、標準パターンと抽出された領域画像の対応する画素同士の輝度値の差分絶対値が上限値以上となる領域画像の各画素の輝度を、その差分絶対値が小さくなるように補正処理が行われる。この例では、上限値以上となる領域画像の各画素の輝度が、それに対応する標準パターンの画素との差分絶対値が上限値とする。
In the
したがって、標準パターン内の任意の位置の画素の輝度値をAi、その画素Aiに対応する領域画像内の位置の画素の輝度値をBioldとしたとき、差分積算値Gは、次の式(2)によって求める。
G=Σ|Ai−Biold|・・・(2)
Therefore, when the luminance value of a pixel at an arbitrary position in the standard pattern is A i and the luminance value of a pixel at a position in the area image corresponding to the pixel A i is B iold , the difference integrated value G is It calculates | requires by Formula (2).
G = Σ | A i −B iold | (2)
また、標準パターンと領域画像の各画素の差分絶対値の上限値をLとしたときに、補正処理後の領域画像の画素の輝度値Binewは、次の式(3)〜(5)によって求められる。
|Ai−Biold|≦Lのとき
Binew=Bi ・・・(3)
|Ai−Biold|>LかつAi<Biold
Binew=Ai+L ・・・(4)
|Ai−Biold|>LかつAi>Biold
Binew=Ai−L ・・・(5)
Further, when the upper limit value of the absolute difference between each pixel of the standard pattern and the region image is L, the luminance value Binew of the pixel of the region image after the correction process is obtained by the following equations (3) to (5). It is done.
When | A i −B iold | ≦ L, B new = B i (3)
| A i −B iold |> L and A i <B iold
B new = A i + L (4)
| A i -B iold |> L and A i > B iold
B new = A i −L (5)
補正処理部26で補正処理が行われる場合には、更新制御部23が補正処理の完了後にメモリ部25に対して更新信号を送り、補正処理を行わない場合には、領域画像が抽出されてバッファメモリ24に書き込まれた直後に更新信号を送る。これにより、領域画像と標準パターンとの相関性が低いと判定されたときには、補正処理された領域画像を新たな標準パターンとし、相関性が高いと判定されたときには、抽出された領域画像をそのまま新たな標準パターンとして更新する。
When correction processing is performed by the
なお、この例では標準パターンと領域画像との相関性の高低を判定する際に、差分絶対値を積算した差分積算値の大きさに基づいているが、判定の手法はこれに限られるものではない。例えばマッチング処理部21がパターンマチングを行う際に算出する相関値を用いてもよい。この場合には、例えば上記式(1)で求められる相関値rの逆数の大小により、相関性の高低を判定してもよい。
In this example, when determining whether the correlation between the standard pattern and the region image is high or low, it is based on the magnitude of the difference integrated value obtained by integrating the difference absolute value, but the determination method is not limited to this. Absent. For example, a correlation value calculated when the
図2に示すように、撮影画像30内には、操作部4の操作で例えば矩形状にAFエリア31aが指定され、あるいはパターンマッチング処理によって特定された領域がAFエリア31aとされる。そして、そのAFエリア31aの内の領域画像が標準パターンとしてメモリ部25に記憶・保持される。なお、AF枠32は、AFエリア31aの外周として指定される。
As shown in FIG. 2, in the photographed
新たな撮影画像が入力されると、メモリ部25に記憶・保持される標準パターンを用いてパターンマッチング処理によって最も相関値の高い画像の領域が検出され、相関値が第1しきい値よりも大きいときには、その領域が新たなAFエリア31bとされる。このような処理を繰り返すことによって、撮影画像上で対象被写体が移動した場合には、その移動先にAFエリア31bが移動するようにして、対象被写体を追跡する。
When a new captured image is input, an image region having the highest correlation value is detected by pattern matching processing using a standard pattern stored and held in the
次に上記構成の作用について説明する。デジタルカメラ2を撮影モードとすると、撮影部5による撮影が開始され、スルー画像が表示部15に表示される。例えば、この初期状態では、AFエリアが撮影画面中央に設定され、そのAFエリア内の被写体にピントが合致するようにフォーカス機構12がAF制御部16の制御下で駆動される。また、スルー画像の表示のために1画面分の撮影が行われるごとに、撮影部5から自動追跡部6に画像データが送られ、その画像データが入力部20を介してマッチング処理部21と抽出部22に入力される。
Next, the operation of the above configuration will be described. When the
対象被写体にAFエリアを追従させる場合には、図3に示すように、撮影者は、表示部15に表示されるAF枠を参照しながら操作部4を操作して、対象被写体、例えば人物の顔を囲むようにAF枠のサイズや位置を設定し、対象被写体の追跡を指示する。
When making the target subject follow the AF area, as shown in FIG. 3, the photographer operates the
対象被写体の追跡が指示されると、システムコントローラ3によって、設定されたAF枠のサイズと位置に相当する領域情報が抽出部22に与えられる。これにより、その領域情報に示される領域内の画像が領域画像として抽出され、その領域画像が標準パターンとしてバッファメモリ24を介してメモリ部25に書き込まれる。
When the tracking of the target subject is instructed, the system controller 3 gives region information corresponding to the set size and position of the AF frame to the
上記のようにして、標準パターンをメモリ部25に保持した後、新たな1画面分の画像データが自動追跡部6に入力されると、その画像データが入力部20を介してマッチング処理部21と、抽出部22とに取り込まれる。そして、マッチング処理部21によって、メモリ部25から標準パターンが読み出され、この標準パターンを用いて新たな撮影画像に対してパターンマッチング処理が行われる。このパターンマッチング処理では、最も相関値が高くなる画像の領域が検出され、その領域を示す領域情報と、相関値とが更新制御部23に出力される。
After the standard pattern is held in the
更新制御部23によって、相関値と第1しきい値とが比較される。この比較において、例えば相関値が第1しきい値以上である場合には、AFエリアを更新するために、入力された領域情報に示される領域が新たなAFエリアとするようにAF制御部16の設定が変更され、またその領域を示すAF枠を表示させるように表示部15の設定が変更される。
The
なお、相関値が第1しきい値より小さい場合には、設定された対象被写体にマッチする領域画像がないものとして、AFエリアの更新は行われず、例えばAFエリアの再設定を操作者に促す案内が表示部15に表示される。
If the correlation value is smaller than the first threshold value, it is assumed that there is no area image that matches the set target subject, and the AF area is not updated. For example, the operator is prompted to reset the AF area. The guidance is displayed on the
上記のように相関値が第1しきい値以上であった場合には、更新制御部23からの領域情報に示される領域の画像を抽出するように抽出部22が作動され、抽出された画像すなわち領域画像がバッファメモリ24に書き込まれる。
When the correlation value is equal to or greater than the first threshold as described above, the
バッファメモリ24に領域画像が書き込まれると、補正処理部26が、メモリ部25に書き込まれている標準パターンの画素の輝度値を読み出すとともに、バッファメモリ24の領域画像の画素の輝度値を読み出し、それら対応する画素同士の輝度値の差分絶対値を求める。そして、それら各画素の差分絶対値を積算することにより、差分積算値が算出されて、第2しきい値と比較される。
When the area image is written in the
上記比較において、差分積算値が第2しきい値よりも小さい場合には、更新制御部23を介して直ちにメモリ部25に対して更新の指示が出され、この指示に応答してメモリ部25がバッファメモリ24の領域画像を新たな標準パターンとして取得して記憶する。
In the above comparison, if the difference integrated value is smaller than the second threshold value, an update instruction is immediately issued to the
一方、差分積算値が第2しきい値以上のときには、補正処理部26による補正処理が行われる。この補正処理により、差分絶対値がその上限値を超える領域画像の各画素のうち輝度値が対応する標準パターンの画素の輝度値よりも大きいものについては、その標準パターンの画素の輝度値に上限値を加算した輝度値に置き換えられる。また、輝度値が対応する標準パターンの画素の輝度値よりも小さい画素については、その標準パターンの画素の輝度値から上限値を減算した輝度値に置き換えられる。
On the other hand, when the difference integrated value is greater than or equal to the second threshold value, correction processing by the
上記のようにして領域画像に補正処理が行われてから、メモリ部25に対して更新の指示が出され、この指示に応答してメモリ部25が補正済みの領域画像を新たな標準パターンとしてバッファメモリ24から取得して記憶する。
After the area image is corrected as described above, an update instruction is issued to the
標準パターンの更新後、次の撮影画像の画像データが自動追跡部6に入力されると、上記のように更新された標準パターンを用いてパターンマッチング処理が行われる。以降、同様な手順により、領域画像と標準パターンとの相関値が第1しきい値以上であれば、AFエリアの更新が行われるとともに、標準パターンの更新が行われる。そして、標準パターンの更新の際には、標準パターンと新たに抽出された領域画像との対応する画素同士の差分絶対値の差分積算値が第2しきい値より小さければ、抽出された領域画像がそのまま新たな標準パターンとされ、差分積算値が第2しきい値以上であれば補正処理が施された領域画像が新たな標準パターンとされる。
After the standard pattern is updated, when image data of the next photographed image is input to the
以上のようにして標準パターンの更新を行うことにより、例えば対象被写体の前面を遮蔽物が通過する等した場合であっても、遮蔽物の通過等による領域画像に生じる輝度変化が上限値までの範囲で制限規される。このため、対象被写体の明るさが変化したり、向きが変化したりした場合はもちろん、遮蔽物が通過する等した場合であっても、更新される新たな標準パターンと対象被写体との相関性が著しく低下しなくなるので、対象被写体を精度よく検出して追跡することができる。 By updating the standard pattern as described above, for example, even when the shielding object passes through the front surface of the target subject, the luminance change that occurs in the area image due to the passage of the shielding object reaches the upper limit value. Limited in scope. For this reason, the correlation between the new standard pattern to be updated and the target subject, even when the brightness of the target subject changes or the direction changes, as well as when the shielding object passes, etc. Can be detected and tracked with high accuracy.
上記実施形態では、差分絶対値が上限値を超える場合の差分絶対値を小さくする手法として、差分絶対値が上限値となるように領域画像の輝度値を補正しているが、それに限るものではない。例えば、差分絶対値が上限値を超える領域画像の画素については、その領域画像の画素とそれに対応する標準パターンの画素の各輝度値の平均値に置き換えるようにしてもよい。 In the above embodiment, as a method of reducing the difference absolute value when the difference absolute value exceeds the upper limit value, the luminance value of the region image is corrected so that the difference absolute value becomes the upper limit value. Absent. For example, pixels of a region image whose difference absolute value exceeds the upper limit value may be replaced with the average value of the luminance values of the pixels of the region image and the corresponding standard pattern pixels.
また、上記実施形態では、追跡すべき対象被写体を操作部の操作で指定しているが、特定の対象、例えば人物の顔をデジタルカメラで自動認識させ、その顔を対象被写体とするようにしてもよい。さらに、デジタルカメラの例について説明したが、本発明は、これに限るものではなく、写真フイルムを用いた写真カメラ、ビデオカメラ、携帯電話等の各種機器に内蔵されたデジタルカメラ等の撮影装置に適用できる。 In the above embodiment, the target subject to be tracked is specified by the operation of the operation unit. However, a specific target, for example, a human face is automatically recognized by the digital camera, and the face is set as the target subject. Also good. Further, although an example of a digital camera has been described, the present invention is not limited to this, and the present invention is not limited to this. Applicable.
また、AFエリアに限らず、露出制御を行うための被写体輝度を測定するAEエリア、ホワイトバランスを調整するための色測定を行うAWBエリア等を対象被写体に追従させて移動させる場合にも利用できる。さらには、ビデオカメラで撮影されて録画された画像を入力画像として用いる場合などにも利用できる。本発明を監視カメラに適用し、撮影方向を被写体の移動に追従させて変化させるようにしてもよい。 Further, not only the AF area but also an AE area for measuring subject brightness for performing exposure control, an AWB area for performing color measurement for adjusting white balance, and the like can be used to move following the target subject. . Furthermore, the present invention can also be used when an image shot and recorded by a video camera is used as an input image. The present invention may be applied to a surveillance camera, and the shooting direction may be changed to follow the movement of the subject.
2 デジタルカメラ
4 操作部
5 撮影部
6 自動追跡部
21 マッチング処理部
22 抽出部
23 更新制御部
25 メモリ部
26 補正処理部
2
Claims (5)
前記特定の被写体の画像を標準パターンとして保持する保持手段と、
入力画像中から前記保持手段に記憶されている標準パターンと最も合致する画像の領域をパターンマッチング処理によって検出するマッチング処理手段と、
前記マッチング処理手段で検出された領域の画像を当該入力画像中から領域画像として抽出する抽出手段と、
前記保持手段に保持されている標準パターンと抽出された前記領域画像との相関性の高低を判定する判定手段と、
前記判定手段によって相関性が低いと判定された場合に、前記標準パターンと領域画像の対応する画素同士の輝度値の差分絶対値が所定の上限値以上である領域画像の各画素について、その差分絶対値を小さくする補正処理を行う補正手段と、
前記判定手段によって相関性が低いと判定されたときには、前記補正手段で補正された領域画像を新たな標準パターンとし、相関性が高いと判定されたときには、前記抽出手段で抽出された領域画像を新たな標準パターンとして前記保持手段に保持する標準パターンを更新する更新制御手段とを備えたことを特徴とする自動追跡装置。 In an automatic tracking device that detects and tracks a specific subject on input images that are sequentially input,
Holding means for holding the image of the specific subject as a standard pattern;
Matching processing means for detecting, by pattern matching processing, an image area that most closely matches the standard pattern stored in the holding means from the input image;
Extraction means for extracting an image of the area detected by the matching processing means as an area image from the input image;
Determination means for determining the level of correlation between the standard pattern held in the holding means and the extracted region image;
When it is determined that the correlation is low by the determination unit, the difference between the pixels of the region image in which the absolute value difference between the corresponding pixels of the standard pattern and the region image is equal to or greater than a predetermined upper limit value Correction means for performing correction processing to reduce the absolute value;
When the determination unit determines that the correlation is low, the region image corrected by the correction unit is used as a new standard pattern. When the correlation unit determines that the correlation is high, the region image extracted by the extraction unit is used. An automatic tracking apparatus comprising: an update control means for updating a standard pattern held in the holding means as a new standard pattern.
入力画像が入力されるごとに、保持している標準パターンと最も合致する画像の領域をパターンマッチング処理によって検出するマッチングステップと、
前記標準パターンと前記検出された領域の画像との相関性の高低を判定する判定ステップと、
前記判定ステップによって相関性が低いと判定されたときに、前記検出された領域の画像の画素のうち、前記標準パターンの対応する画素との輝度値の差分絶対値が所定の上限値以上である画素に対して前記差分絶対値を小さくする補正ステップと、
前記判定ステップによって相関性が低いと判定されたときに、前記補正ステップによって補正された前記特定された領域の画像を新たな標準パターンとし、相関性が高いと判定されたときに、前記特定された領域の画像を新たな標準パターンとする更新ステップとを有することを特徴とする自動追跡方法。 In an automatic tracking method for detecting and tracking a specific subject on input images that are sequentially input,
Each time an input image is input, a matching step for detecting a region of an image that most closely matches a held standard pattern by pattern matching processing,
A determination step of determining the level of correlation between the standard pattern and the image of the detected area;
When the correlation is determined to be low by the determination step, the absolute value of the difference in luminance value from the corresponding pixel of the standard pattern among the pixels of the image of the detected region is equal to or greater than a predetermined upper limit value A correction step for reducing the absolute value of the difference with respect to a pixel;
When it is determined that the correlation is low by the determination step, the image of the specified region corrected by the correction step is used as a new standard pattern, and the image is specified when the correlation is determined to be high. And an update step of using the image of the region as a new standard pattern.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007327208A JP2009152725A (en) | 2007-12-19 | 2007-12-19 | Automatic tracing apparatus and method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2007327208A JP2009152725A (en) | 2007-12-19 | 2007-12-19 | Automatic tracing apparatus and method |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2009152725A true JP2009152725A (en) | 2009-07-09 |
Family
ID=40921376
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2007327208A Pending JP2009152725A (en) | 2007-12-19 | 2007-12-19 | Automatic tracing apparatus and method |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2009152725A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012034069A (en) * | 2010-07-29 | 2012-02-16 | Nikon Corp | Image processor and image processing program |
WO2013094552A1 (en) * | 2011-12-22 | 2013-06-27 | ソニー株式会社 | Imaging device, method for controlling same, and program |
WO2013094551A1 (en) * | 2011-12-22 | 2013-06-27 | ソニー株式会社 | Imaging device, method for controlling same, and program |
JP2015095775A (en) * | 2013-11-12 | 2015-05-18 | リコーイメージング株式会社 | Imaging apparatus and imaging method |
-
2007
- 2007-12-19 JP JP2007327208A patent/JP2009152725A/en active Pending
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2012034069A (en) * | 2010-07-29 | 2012-02-16 | Nikon Corp | Image processor and image processing program |
CN103039068A (en) * | 2010-07-29 | 2013-04-10 | 株式会社尼康 | Image processing device and image processing program |
WO2013094552A1 (en) * | 2011-12-22 | 2013-06-27 | ソニー株式会社 | Imaging device, method for controlling same, and program |
WO2013094551A1 (en) * | 2011-12-22 | 2013-06-27 | ソニー株式会社 | Imaging device, method for controlling same, and program |
US9407811B2 (en) | 2011-12-22 | 2016-08-02 | Sony Corporation | Focus control unit in imaging apparatus, method of controlling the focus control unit and medium for controlling the focus control unit |
JP2015095775A (en) * | 2013-11-12 | 2015-05-18 | リコーイメージング株式会社 | Imaging apparatus and imaging method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
TWI425828B (en) | Image capturing apparatus, method for determing image area ,and computer-readable recording medium | |
JP6157242B2 (en) | Image processing apparatus and image processing method | |
US8139136B2 (en) | Image pickup apparatus, control method of image pickup apparatus and image pickup apparatus having function to detect specific subject | |
JP6512810B2 (en) | Image pickup apparatus, control method and program | |
JP2006211139A (en) | Imaging apparatus | |
US8411159B2 (en) | Method of detecting specific object region and digital camera | |
JP5237721B2 (en) | Imaging device | |
JP2012239156A (en) | Imaging apparatus, imaging method, and imaging program | |
JP5713885B2 (en) | Image processing apparatus, image processing method, program, and storage medium | |
JP5383366B2 (en) | Image processing apparatus, image processing method, and program thereof | |
JP6752681B2 (en) | Display control device, control method and program of display control device, and storage medium | |
JP5096297B2 (en) | Imaging device | |
JP2009288945A (en) | Image display unit and image display method | |
JP2019083364A (en) | Image processing device, imaging device, and control method | |
JP2013012940A (en) | Tracking apparatus and tracking method | |
JP2009055125A (en) | Imaging apparatus and its control method | |
JP2009152725A (en) | Automatic tracing apparatus and method | |
JP2011035891A (en) | Electronic camera | |
JP2008054031A (en) | Digital camera and display control method | |
JP5015121B2 (en) | Imaging device | |
JP5451364B2 (en) | Subject tracking device and control method thereof | |
JP2008172733A (en) | Imaging apparatus and control method thereof | |
JP2019129474A (en) | Image shooting device | |
JP2018185576A (en) | Image processing device and image processing method | |
JP2009117982A (en) | Automatic tracking apparatus and method, and image pickup apparatus |