JP2023004678A - Processing device and control method therefor - Google Patents
Processing device and control method therefor Download PDFInfo
- Publication number
- JP2023004678A JP2023004678A JP2021106530A JP2021106530A JP2023004678A JP 2023004678 A JP2023004678 A JP 2023004678A JP 2021106530 A JP2021106530 A JP 2021106530A JP 2021106530 A JP2021106530 A JP 2021106530A JP 2023004678 A JP2023004678 A JP 2023004678A
- Authority
- JP
- Japan
- Prior art keywords
- line
- sight
- image
- display
- focus detection
- 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
- 238000012545 processing Methods 0.000 title claims description 48
- 238000000034 method Methods 0.000 title claims description 43
- 238000012937 correction Methods 0.000 claims description 6
- 238000001514 detection method Methods 0.000 abstract description 113
- 230000004043 responsiveness Effects 0.000 abstract description 13
- 230000000007 visual effect Effects 0.000 abstract 3
- 238000003384 imaging method Methods 0.000 description 53
- 230000008569 process Effects 0.000 description 22
- 238000006243 chemical reaction Methods 0.000 description 19
- 210000001747 pupil Anatomy 0.000 description 15
- 210000001508 eye Anatomy 0.000 description 11
- 230000006870 function Effects 0.000 description 10
- 230000000875 corresponding effect Effects 0.000 description 9
- 238000004891 communication Methods 0.000 description 8
- 238000001914 filtration Methods 0.000 description 8
- 210000005252 bulbus oculi Anatomy 0.000 description 6
- 238000010586 diagram Methods 0.000 description 6
- 210000000744 eyelid Anatomy 0.000 description 6
- 230000008859 change Effects 0.000 description 5
- 238000004364 calculation method Methods 0.000 description 3
- 210000000887 face Anatomy 0.000 description 3
- 238000005286 illumination Methods 0.000 description 3
- 238000012417 linear regression Methods 0.000 description 3
- 230000003287 optical effect Effects 0.000 description 3
- 241001465754 Metazoa Species 0.000 description 2
- 210000005069 ears Anatomy 0.000 description 2
- 239000000284 extract Substances 0.000 description 2
- 230000004424 eye movement Effects 0.000 description 2
- 238000005259 measurement Methods 0.000 description 2
- 230000010355 oscillation Effects 0.000 description 2
- 238000002360 preparation method Methods 0.000 description 2
- 238000001454 recorded image Methods 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 230000007704 transition Effects 0.000 description 2
- WHXSMMKQMYFTQS-UHFFFAOYSA-N Lithium Chemical compound [Li] WHXSMMKQMYFTQS-UHFFFAOYSA-N 0.000 description 1
- 229910005580 NiCd Inorganic materials 0.000 description 1
- 229910005813 NiMH Inorganic materials 0.000 description 1
- 241000593989 Scardinius erythrophthalmus Species 0.000 description 1
- 230000001133 acceleration Effects 0.000 description 1
- 238000009825 accumulation Methods 0.000 description 1
- 238000003705 background correction Methods 0.000 description 1
- 230000008901 benefit Effects 0.000 description 1
- 230000004397 blinking Effects 0.000 description 1
- 230000001276 controlling effect Effects 0.000 description 1
- 210000004087 cornea Anatomy 0.000 description 1
- 230000002596 correlated effect Effects 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 238000011156 evaluation Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 230000005484 gravity Effects 0.000 description 1
- 238000010191 image analysis Methods 0.000 description 1
- 229910052744 lithium Inorganic materials 0.000 description 1
- 238000010801 machine learning Methods 0.000 description 1
- 239000000203 mixture Substances 0.000 description 1
- 210000000214 mouth Anatomy 0.000 description 1
- 210000001331 nose Anatomy 0.000 description 1
- 201000005111 ocular hyperemia Diseases 0.000 description 1
- 238000003672 processing method Methods 0.000 description 1
- 230000004044 response Effects 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 238000009416 shuttering Methods 0.000 description 1
- 230000005236 sound signal Effects 0.000 description 1
- 230000001629 suppression Effects 0.000 description 1
Images
Landscapes
- Automatic Focus Adjustment (AREA)
- Studio Devices (AREA)
- Image Analysis (AREA)
Abstract
Description
本発明は、人物の視線に対応する位置を取得する装置に関する。 The present invention relates to a device for acquiring a position corresponding to a person's line of sight.
人物の視線位置を検出する方法が知られている。特許文献1では、角膜に照明を行い、その反射像を撮影することで、被験者の視線位置を検出する方法が開示されている。また、特許文献1では、過去に取得した複数の時刻における視線位置から、カルマンフィルタを用いて現在の視線位置を予測する手段が開示されている。
A method for detecting the line-of-sight position of a person is known.
しかしながら、特許文献1では視線位置を予測するためのカルマンフィルタについて詳しく開示されていない。本発明は、視線位置を検出する手段と視線の表示手段を有する撮像装置において、視線検出の即応性と安定性のバランスを鑑みて視線位置を導出することを目的とする。
However,
本発明は、人物の視線の位置に対応する視線情報を取得する取得手段と、前記視線情報を補正する補正手段と、を有し、前記補正手段は、低次の多項式回帰式を用いたカルマンフィルタによって前記視線情報を補正するよう構成したことを特徴とする。 The present invention includes acquisition means for acquiring line-of-sight information corresponding to the line-of-sight position of a person, and correction means for correcting the line-of-sight information, wherein the correction means is a Kalman filter using a low-order polynomial regression equation. is configured to correct the line-of-sight information by
本発明によれば、視線検出の安定性と即応性を両立することが可能である。 According to the present invention, it is possible to achieve both stability and responsiveness in line-of-sight detection.
以下に、本発明の好ましい実施の形態を、添付の図面に基づいて詳細に説明する。 Preferred embodiments of the present invention are described in detail below with reference to the accompanying drawings.
[撮像装置の構成の説明]
図1は、本発明の実施形態にかかる撮像装置の構成を示すブロック図である。図1において、レンズユニット150は、交換可能な撮影レンズを搭載するレンズユニットである。レンズ103は通常、複数枚のレンズから構成されるが、ここでは簡略して一枚のレンズのみで示している。通信端子6はレンズユニット150がデジタルカメラ100側と通信を行う為の通信端子であり、通信端子10はデジタルカメラ100がレンズユニット150側と通信を行う為の通信端子である。レンズユニット150は、この通信端子6、10を介してシステム制御部50と通信し、内部のレンズシステム制御回路4によって絞り駆動回路2を介して絞り102の制御を行い、AF駆動回路3を介して、レンズ103の位置を変位させることで焦点を合わせる。
[Description of configuration of imaging device]
FIG. 1 is a block diagram showing the configuration of an imaging device according to an embodiment of the present invention. In FIG. 1, a
シャッター101は、システム制御部50の制御で撮像部22の露光時間を自由に制御できるフォーカルプレーンシャッターである。撮像部22は光学像を電気信号に変換するCCDやCMOS素子等で構成される撮像素子である。A/D変換器23は、アナログ信号をデジタル信号に変換する。A/D変換器23は、撮像部22から出力されるアナログ信号をデジタル信号に変換するために用いられる。撮像部22から得られた信号は、撮像だけでなく、露出制御、焦点検出制御にも用いられる。撮像部22には、1つのマイクロレンズに対して、光電変換部が分割された画素が設けられている。光電変換部を分割することにより入射瞳が分割され、それぞれの光電変換部から位相差検出信号を得ることができる。また、分割された光電変換部からの信号を加算することにより、撮像信号も得ることができる。
The
このような画素は、焦点検出画素と撮像画素を兼用できるというメリットがある。 Such pixels have the advantage that they can be used both as focus detection pixels and imaging pixels.
図2は、本実施形態にかかる画素の構成と、瞳面と光電変換部の対応関係を示している。201が光電変換部を、253が瞳面を、251がマイクロレンズを、252がカラーフィルタをそれぞれ示している。図2には、光電変換部201a(第1焦点検出画素)と、光電変換部201b(第2焦点検出画素)の2つの光電変換部201が設けられている。光電変換部201aにおいて、253aで示した瞳面を通過した光が光電変換部201aに入射する。また、光電変換部201bにおいて、253bで示した瞳面を通過した光が光電変換部201bに入射する。これにより、光電変換部201aと、光電変換部201bから得られた信号から焦点検出が行える。また、光電変換部201aと、光電変換部201bから得られた信号を加算することにより、撮像信号を生成することができる。
FIG. 2 shows the configuration of a pixel according to this embodiment and the correspondence relationship between the pupil plane and the photoelectric conversion unit. 201 denotes a photoelectric conversion unit, 253 denotes a pupil plane, 251 denotes a microlens, and 252 denotes a color filter. In FIG. 2, two
本実施例では、図2に示した画素を、撮像部22の全画面領域に設けることにより、画面上に写るいずれの被写体に対しても、位相差検出により焦点を合わせることが可能となる。
In this embodiment, by providing the pixels shown in FIG. 2 in the entire screen area of the
なお、本実施例では、上記の焦点検出方式で説明を行うが、焦点検出方式はこの場合に限らない。例えば、撮像部22に、後述の図3に示す焦点検出専用画素を設けて焦点検出を行ってもよい。また、撮像部22には、焦点検出用の画素を設けず、撮像用の画素のみを設け、コントラスト方式で焦点検出を行ってもよい。
In this embodiment, the above focus detection method will be described, but the focus detection method is not limited to this case. For example, the
図3は、焦点検出専用画素の構成と、瞳面と光電変換部の対応関係を示している。図3は、図2と異なり、焦点検出専用の画素である。瞳面253の形状は、開口部254により決定される。また、瞳面253を通過した光のみを検出するため、対となる画素、図3において不図示の右側の瞳面からの光を検出する画素、を別途設けて焦点検出信号を取得する必要がある。撮像部22に、図3に示す焦点検出画素と、撮像画素を全画面領域に設けることにより、画面上に写るいずれの被写体に対しても、位相差検出により焦点を合わせることが可能となる。
FIG. 3 shows the configuration of the focus detection dedicated pixels and the correspondence relationship between the pupil plane and the photoelectric conversion unit. Unlike FIG. 2, FIG. 3 shows pixels dedicated to focus detection. The shape of pupil plane 253 is determined by
画像処理部24は、A/D変換器23からのデータ、又は、メモリ制御部15からのデータに対し所定の画素補間、縮小といったリサイズ処理や色変換処理を行う。また、画像処理部24では、撮像した画像データを用いて所定の演算処理が行われ、得られた演算結果に基づいてシステム制御部50が露光制御、測距制御を行う。これにより、TTL(スルー・ザ・レンズ)方式のAF(オートフォーカス)処理、AE(自動露出)処理、EF(フラッシュプリ発光)処理が行われる。画像処理部24では更に、撮像した画像データを用いて所定の演算処理を行い、得られた演算結果に基づいてTTL方式のAWB(オートホワイトバランス)処理も行っている。
The image processing unit 24 performs resizing processing such as predetermined pixel interpolation and reduction, and color conversion processing on the data from the A/
A/D変換器23からの出力データは、画像処理部24及びメモリ制御部15を介して、或いは、メモリ制御部15を介してメモリ32に直接書き込まれる。メモリ32は、撮像部22によって得られA/D変換器23によりデジタルデータに変換された画像データや、表示手段としての表示部28に表示するための画像データを格納する。メモリ32は、所定枚数の静止画像や所定時間の動画像および音声を格納するのに十分な記憶容量を備えている。
Output data from the A/
また、メモリ32は画像表示用のメモリ(ビデオメモリ)を兼ねている。D/A変換器19は、メモリ32に格納されている画像表示用のデータをアナログ信号に変換して表示部28に供給する。こうして、メモリ32に書き込まれた表示用の画像データはD/A変換器19を介して表示部28により表示される。表示部28は、LCD等の表示器上に、D/A変換器19からのアナログ信号に応じた表示を行う。A/D変換器23によって一度A/D変換されメモリ32に蓄積されたデジタル信号をD/A変換器19においてアナログ変換し、表示部28に逐次転送して表示することで、電子ビューファインダとして機能し、スルー画像表示(ライブビュー表示)を行える。なお、表示部28は、不図示の接眼部を通して覗き込む電子ビューファインダを設けても、デジタルカメラ100の背面にディスプレイを設けてもよい。また、電子ビューファインダと、背面のディスプレイの両方を設けてもよい。
The
不揮発性メモリ56は、電気的に消去・記録可能なメモリであり、例えばEEPROM等が用いられる。不揮発性メモリ56には、システム制御部50の動作用の定数、プログラム等が記憶される。ここでいう、プログラムとは、本実施形態にて後述する各種フローチャートを実行するためのプログラムのことである。
The
システム制御部50は、デジタルカメラ100全体を制御する。前述した不揮発性メモリ56に記録されたプログラムを実行することで、後述する本実施形態の各処理を実現する。52はシステムメモリであり、RAMが用いられる。システムメモリ52には、システム制御部50の動作用の定数、変数、不揮発性メモリ56から読み出したプログラム等を展開する。また、システム制御部はメモリ32、D/A変換器19、表示部28等を制御することにより表示制御も行う。
A
システムタイマー53は各種制御に用いる時間や、内蔵された時計の時間を計測する計時部である。 A system timer 53 is a timer that measures the time used for various controls and the time of a built-in clock.
電源スイッチ72はデジタルカメラ100の電源のON及びOFFを切り替える操作部材である。
A
モード切替スイッチ60、第1シャッタースイッチ62、第2シャッタースイッチ64、操作部70はシステム制御部50に各種の動作指示を入力するための操作手段である。
A
モード切替スイッチ60は、システム制御部50の動作モードを静止画記録モード、動画撮影モード、再生モード等のいずれかに切り替える。静止画記録モードに含まれるモードとして、オート撮影モード、オートシーン判別モード、マニュアルモード、絞り優先モード(Avモード)、シャッター速度優先モード(Tvモード)がある。また、撮影シーン別の撮影設定となる各種シーンモード、プログラムAEモード、カスタムモード等がある。モード切り替えスイッチ60で、メニューボタンに含まれるこれらのモードのいずれかに直接切り替えられる。あるいは、モード切り替えスイッチ60でメニューボタンに一旦切り換えた後に、メニューボタンに含まれるこれらのモードのいずれかに、他の操作部材を用いて切り替えるようにしてもよい。同様に、動画撮影モードにも複数のモードが含まれていてもよい。第1シャッタースイッチ62は、デジタルカメラ100に設けられたシャッターボタン61の操作途中、いわゆる半押し(撮影準備指示)でONとなり第1シャッタースイッチ信号SW1を発生する。第1シャッタースイッチ信号SW1により、AF(オートフォーカス)処理、AE(自動露出)処理、AWB(オートホワイトバランス)処理、EF(フラッシュプリ発光)処理等の動作を開始する。
The
第2シャッタースイッチ64は、シャッターボタン61の操作完了、いわゆる全押し(撮影指示)でONとなり、第2シャッタースイッチ信号SW2を発生する。システム制御部50は、第2シャッタースイッチ信号SW2により、撮像部22からの信号読み出しから記録媒体200に画像データを書き込むまでの一連の撮影処理の動作を開始する。
The
操作部70の各操作部材は、表示部28に表示される種々の機能アイコンを選択操作することなどにより、場面ごとに適宜機能が割り当てられ、各種機能ボタンとして作用する。機能ボタンとしては、例えば終了ボタン、戻るボタン、画像送りボタン、ジャンプボタン、絞込みボタン、属性変更ボタン等がある。例えば、メニューボタンが押されると各種の設定可能なメニュー画面が表示部28に表示される。利用者は、表示部28に表示されたメニュー画面と、上下左右の4方向ボタンやSETボタンとを用いて直感的に各種設定を行うことができる。
Each operation member of the
操作部70は、ユーザーからの操作を受け付ける入力部としての各種操作部材である。操作部70には、メニュー選択、モード選択、撮影した動画像の再生などを実施するための電子ボタンや十字キーなどが設けられている。
The
本実施例では、操作部70の1つとして、視線入力操作部701が設けられている。視線入力操作部701は、ユーザーの視線が表示部28のいずれの箇所を見ているかを検出するための操作部材である。
In this embodiment, a line-of-sight
図4(a)は、視線入力操作部701の一例を示す。図4(a)では、特許文献1に開示されているファインダ視野内を覗くユーザーの眼球501aの光軸の回転角を検出し、検出した回転角からユーザーの視線を検出する方式を実現する構成である。表示部28には、レンズユニット100を通して撮影されたライブビュー表示画像が表示されている。701aはイメージセンサを、701bは受光レンズを、701cはダイクロイックミラーを、701dは接眼レンズを、701eは照明光源を示す。照明光源701eにより、眼球501aに赤外光が投射される。眼球501aを反射した赤外光は、ダイクロイックミラー701cに反射され、イメージセンサ701aにより撮影される。撮影された眼球画像は、不図示のA/D変換器によりデジタル信号に変換され、システム制御部50に送信される。視線情報生成手段、および、視線位置情報出力手段としてのシステム制御部50では、撮影された眼球画像から、瞳孔の領域などを抽出し、ユーザーの視線を算出する。
FIG. 4A shows an example of the line-of-sight
なお、視線入力操作部701は、この方式に限らず、ユーザーの両目を撮影し、視線を検出する方式でもよい。図4(b)には、図4とは異なる視線入力操作部701の一例を示す。図4(b)は、デジタルカメラ100の背面に設けられている表示部28に、レンズユニット100を通して撮影されたライブビュー表示画像が表示されている。図4(b)では、デジタルカメラ100の背面に、表示部28を観察しているユーザーの顔500を撮影するカメラ701fが設けられている。図5において、カメラ701fが撮影する画角を点線で示している。不図示の照明光源701eからユーザーの顔に投光を行い、カメラ701fにより眼球画像を取得する。これにより、ユーザーの視線を算出する。なお、視線入力操作部701は、この方式に限らず、ユーザーが表示部28のいずれの箇所を注視しているかを検出できる構成であればよい。
Note that the line-of-sight
電源制御部80は、電池検出回路、DC-DCコンバータ、通電するブロックを切り替えるスイッチ回路等により構成され、電池の装着の有無、電池の種類、電池残量の検出を行う。また、電源制御部80は、その検出結果及びシステム制御部50の指示に基づいてDC-DCコンバータを制御し、必要な電圧を必要な期間、記録媒体200を含む各部へ供給する。
The
電源部30は、アルカリ電池やリチウム電池等の一次電池やNiCd電池やNiMH電池、Li電池等の二次電池、ACアダプター等からなる。記録媒体I/F18は、メモリカードやハードディスク等の記録媒体200とのインターフェースである。記録媒体200は、撮影された画像を記録するためのメモリカード等の記録媒体であり、半導体メモリや磁気ディスク等から構成される。
The
通信部54は、無線または優先ケーブルによって接続し、映像信号や音声信号の送受信を行う。通信部54は無線LAN(Local Area Network)やインターネットとも接続可能である。通信部54は撮像部22で撮像した画像(スルー画像を含む)や、記録媒体200に記録された画像を送信可能であり、また、外部機器から画像データやその他の各種情報を受信することができる。
The
姿勢検知部55は重力方向に対するデジタルカメラ100の姿勢を検知する。姿勢検知部55で検知された姿勢に基づいて、撮像部22で撮影された画像が、デジタルカメラ100を横に構えて撮影された画像であるか、縦に構えて撮影された画像なのかを判別可能である。システム制御部50は、姿勢検知部55で検知された姿勢に応じた向き情報を撮像部22で撮像された画像の画像ファイルへの付加や、画像を回転して記録することが可能である。姿勢検知部55としては、加速度センサーやジャイロセンサーなどを用いることができる。
The
上述したデジタルカメラ100では中央1点AFや顔AFを用いた撮影が可能である。中央1点AFとは撮影画面内の中央位置1点に対してAFを行うことである。顔AFとは顔検出機能によって検出された撮影画面内の顔に対してAFを行うことである。
The
顔検出機能について説明する。システム制御部50は顔検出対象の画像データを画像処理部24に送る。システム制御部50の制御下で画像処理部24は、当該画像データに水平方向バンドパスフィルタを作用させる。また、システム制御部50の制御下で画像処理部24は処理された画像データに垂直方向バンドパスフィルタを作用させる。これら水平及び垂直方向のバンドパスフィルタにより、画像データよりエッジ成分が検出される。
The face detection function will be explained. The
その後、システム制御部50は、検出されたエッジ成分に関してパターンマッチングを行い、目及び鼻、口、耳の候補群を抽出する。そして、システム制御部50は、抽出された目の候補群の中から、予め設定された条件(例えば2つの目の距離、傾き等)を満たすものを、目の対と判断し、目の対があるもののみ目の候補群として絞り込む。そして、システム制御部50は、絞り込まれた目の候補群とそれに対応する顔を形成する他のパーツ(鼻、口、耳)を対応付け、また、予め設定した非顔条件フィルタを通すことで、顔を検出する。システム制御部50は、顔の検出結果に応じて上記顔情報を出力し、処理を終了する。このとき、顔の数などの特徴量をシステムメモリ52に記憶する。顔検出機能の実現方法は、上述の方法に限らず、公知の機械学習を用いた方法により、同様に、顔の数、サイズ、パーツなどを検出してもよい。また、被写体の種別として、人物の顔に限らず、動物や乗り物などを検出してもよい。
After that, the
以上のようにライブビュー表示あるいは再生表示される画像データを画像解析して、画像データの特徴量を抽出して被写体情報を検出することが可能である。本実施例では被写体情報として顔情報を例に挙げたが、被写体情報には他にも赤目判定や目の検出、目つむり検出、笑顔検出等の様々な情報がある。 As described above, it is possible to perform image analysis on image data displayed in live view display or playback display, extract feature amounts of the image data, and detect subject information. In this embodiment, face information is taken as an example of subject information, but there are various types of subject information such as red-eye determination, eye detection, blink detection, smile detection, and the like.
なお、顔AFと同時に顔AE,顔FE、顔WBを行うことができる。顔AEとは検出された顔の明るさに合わせて、画面全体の露出を最適化することである。顔FEとは検出された顔を中心にフラッシュの調光をすることである。顔WBとは、検出された顔の色に合わせて画面全体のWBを最適化することである。 Note that face AE, face FE, and face WB can be performed simultaneously with face AF. Face AE is to optimize the exposure of the entire screen according to the brightness of the detected face. Face FE is to adjust the light of the flash centering on the detected face. Face WB is to optimize the WB of the entire screen according to the color of the detected face.
[課題]
視線位置を検出する手段と視線の表示手段を有する撮像装置においては、次のような課題が生じる。該撮像装置において、撮影者が表示手段を目視し、その視線によって快適に被写体選択や測距点選択を行うためには、検出した視線位置の表示において安定性と即応性を両立する必要がある。視線位置は、視線検出の誤差と人の視線微動などによって、視線位置に振動やゆらぎが生じる。検出した視線位置を毎秒数10フレームのレートで該表示装置にポインタ表示等を行った場合、そのポインタを視認することで不快感を感じる、あるいは、被写体選択や測距点選択が困難となってしまう。そのため、視線の安定性を確保するために、複数の過去の視線位置を用いたフィルタリングを行う必要がある。しかしながら、過去に取得した複数の視線位置を用いて現在や未来の視線位置を予測すると、フィルタの位相遅れ特性によって遅延が生じてしまい即応性が損なわれる。この遅延は、過去の視線位置データを多く用いるほど大きくなってしまう。表示装置上で速い動きの被写体を視線で追跡する場合に遅延が大きいと、被写体を視線で捉えることが困難となってしまう。一方、即応性を確保するためにフィルタの強度を低下させると視線の振動を除去しきれず、安定性に問題が生じる。このように安定性と即応性は原理的にトレードオフの関係となる。該撮像装置においては、フィルタ強度を調整して安定性と即応性のバランスを確保することが考えられるが、視線検出の精度が撮影者や撮影条件によって異なるため、フィルタ強度を固定値として設定する等の手段では、安定性と即応性を両立するのは困難である。本実施例はこのような技術の課題に着目し、視線検出の安定性か即応性のバランスを両立するものである。
[Task]
The following problem arises in an imaging apparatus having means for detecting the line-of-sight position and means for displaying the line-of-sight. In the imaging apparatus, in order for the photographer to look at the display means and comfortably select a subject or a range-finding point based on the line of sight, it is necessary to achieve both stability and responsiveness in displaying the detected line-of-sight position. . The line-of-sight position vibrates and fluctuates due to line-of-sight detection errors and human line-of-sight slight movements. When the detected line-of-sight position is displayed as a pointer on the display device at a rate of several tens of frames per second, visually recognizing the pointer makes the user feel uncomfortable, or makes it difficult to select a subject or a range-finding point. put away. Therefore, in order to ensure the stability of the line of sight, it is necessary to perform filtering using a plurality of past line of sight positions. However, if the current and future line-of-sight positions are predicted using a plurality of line-of-sight positions acquired in the past, a delay occurs due to the phase delay characteristic of the filter, which impairs responsiveness. This delay increases as more past line-of-sight position data is used. If the delay is large when tracking a fast-moving object with the line of sight on the display device, it becomes difficult to catch the object with the line of sight. On the other hand, if the strength of the filter is reduced in order to ensure responsiveness, the line-of-sight vibration cannot be completely removed, resulting in a stability problem. In this way, stability and responsiveness are in principle in a trade-off relationship. In the imaging device, it is conceivable to adjust the filter strength to ensure a balance between stability and responsiveness, but since the accuracy of line-of-sight detection varies depending on the photographer and shooting conditions, the filter strength is set as a fixed value. With such means, it is difficult to achieve both stability and responsiveness. The present embodiment focuses on such technical problems, and balances the stability and responsiveness of line-of-sight detection at the same time.
[視線検出および撮影動作の説明]
以下、図5を参照して、本発明の第1の実施例における視線位置の検出処理方法について説明する。図5は、本実施形態の撮像装置の焦点検出、視線検出及び撮影動作を説明するためのフローチャートである。図6は、撮影スタンバイ状態などのライブビュー状態(動画撮影状態)から撮影を行うライブビュー撮影時の動作を示し、システム制御部50が主体となって実現される。
[Description of line-of-sight detection and shooting operation]
Hereinafter, the sight line position detection processing method according to the first embodiment of the present invention will be described with reference to FIG. FIG. 5 is a flowchart for explaining focus detection, line-of-sight detection, and photographing operations of the imaging apparatus of this embodiment. FIG. 6 shows the operation at the time of live view shooting, in which shooting is performed from a live view state (moving image shooting state) such as a shooting standby state, and is realized mainly by the
S1では、システム制御部50の制御に従い、撮像部22を駆動し、撮像データを取得する。取得する撮像データは、後述する記録用ではなく、検出・表示用の画像であるため、記録画像に対してサイズの小さい画像を取得する。S1では、焦点検出や被写体検出、もしくは、ライブビュー表示を行うために十分な解像度を有する画像を取得する。ここでは、ライブビュー表示用の動画撮影のための駆動動作であるため、ライブビュー表示用のフレームレートに応じた時間の電荷蓄積と読み出しを行う、いわゆる電子シャッタを用いた撮影を行う。ここで行うライブビュー表示は、撮影者が撮影範囲や撮影条件の確認を行うためのもので、例えば、30フレーム/秒(撮影間隔33.3ms)や60フレーム/秒(撮影間隔16.6ms)であってよい。
In S1, under the control of the
S2で、システム制御部50は、S1で得られた撮像データのうち、焦点検出領域に含まれる第1焦点検出画素と第2焦点検出画素から得られる焦点検出データを取得する。また、システム制御部50は、第1焦点検出画素と第2焦点検出画素の出力信号を加算し撮像信号を生成し、画像処理部24で色補間処理などを適用して得られる画像データを取得する。このように、1回の撮影により、画像データと、焦点検出データとを取得することができる。なお、撮像画素と、第1焦点検出画素、第2焦点検出画素を個別の画素構成とした場合には、焦点検出用画素の補完処理などを行って画像データを取得する。
In S2, the
S3でシステム制御部50は、S2で得られた画像データをもとに、画像処理部24を用いてライブビュー表示用の画像を生成し、表示部28に表示する。なお、ライブビュー表示用の画像は、例えば表示部28の解像度に合わせた縮小画像であり、S2で画像データを生成する際に画像処理部24で縮小処理を実施することもできる。この場合、システム制御部50はS2で取得した画像データを表示部28に表示させる。上述の通り、ライブビュー表示中は所定のフレームレートでの撮影と表示が行われるため、表示部28を通じて撮影者は撮影時の構図や露出条件の調整などを行うことができる。 また、上述の通り、本実施形態では、被写体として人物の顔や動物などを検出することが可能である。S3で、ライブビュー表示の開始に合わせて、検出している被写体の領域を示す枠などの表示も行う。
In S<b>3 , the
S4でシステム制御部50は、視線検出、および焦点検出を開始する。S4以降、視線入力操作部701により、撮影者が、表示部28上のどの位置を観察しているか(視線位置)を、撮影者が観察していた表示画像と関連付けて、所定の時間間隔で取得する。また、検出された視線位置を、撮影者に通知するため、表示部28上に、表示する。
In S4, the
S5でシステム制御部50は、撮影準備開始を示す第1シャッタースイッチ62(Sw1)のオン/オフを検出する。操作部70の一つであるシャッターボタン61は、押し込み量に応じて、2段階のオン/オフを検出することが可能で、上述のSw1のオン/オフは、レリーズ(撮影トリガ)スイッチの1段階目のオン/オフに相当する。
In S5, the
S5でSw1のオンが検出されない(あるいはオフが検出された)場合、システム制御部50は処理をS11に進め、操作部70に含まれるメインスイッチがオフされたか否かを判別する。一方、S5でSw1のオンが検出されると、システム制御部50は処理をS6に進め、合焦させる焦点検出領域の設定、および焦点検出を行う。ここでは、S4で検出を開始した視線位置と、撮像装置内部の被写体検出位置の両方を用いて、焦点検出領域を設定する。S4で検出される視線位置は、撮影者が意図する被写体の位置に対して、様々な要因で、誤差を有する。また、個人差はあるが、人間は視認してから目が動き出すまでにコンマ数秒程度の遅延時間が存在する。本発明では、検出される視線位置情報を、撮影条件に応じて視線情報の信頼性を評価し、加工処理をすることにより、人間が視認してから目が動き出すまでの遅延時間があってもより精度の高い視線位置情報を取得することか可能となる。詳細は、後述する。S6では、後述する処理が施された視線位置情報と撮像装置内部の被写体検出位置の両方を用いて、焦点検出領域を設定する。S6以降、視線位置情報を用いた焦点検出領域の設定と、焦点検出処理は、撮像を行うたびに、繰り返し実行される。
If Sw1 is not detected to be on (or is detected to be off) in S5, the
設定された焦点検出領域に対応する焦点検出データを用いて、デフォーカス量および方向を焦点検出領域ごとに求める。本実施形態では、システム制御部50が焦点検出用の像信号の生成と、焦点検出用信号のずれ量(位相差)の算出と、算出したずれ量からデフォーカス量と方向を求める処理を実施するものとする。
Using the focus detection data corresponding to the set focus detection area, the defocus amount and direction are obtained for each focus detection area. In this embodiment, the
設定した焦点検出領域から、焦点検出用の像信号として得られた第1焦点検出信号と第2焦点検出信号に、シェーディング補正、フィルター処理を行い、対の信号の光量差の低減と、位相差検出を行う空間周波数の信号抽出を行う。次に、フィルター処理後の第1焦点検出信号と第2焦点検出信号を相対的に瞳分割方向にシフトさせるシフト処理を行い、信号の一致度を表す相関量を算出する。 The first focus detection signal and the second focus detection signal obtained as image signals for focus detection from the set focus detection area are subjected to shading correction and filtering to reduce the light amount difference between the pair of signals and to reduce the phase difference. Perform signal extraction of the spatial frequency to be detected. Next, shift processing is performed to relatively shift the filtered first focus detection signal and the second focus detection signal in the direction of pupil division, and a correlation amount representing the degree of matching between the signals is calculated.
フィルター処理後のk番目の第1焦点検出信号をA(k)、第2焦点検出信号をB(k)、焦点検出領域に対応する番号kの範囲をWとする。さらに、シフト処理によるシフト量をs1、シフト量s1のシフト範囲をΓ1とすると、相関量CORは、式(1)により算出される。 Let A(k) be the k-th first focus detection signal after filtering, B(k) be the second focus detection signal, and W be the range of number k corresponding to the focus detection area. Furthermore, when the shift amount by the shift process is s1 and the shift range of the shift amount s1 is Γ1, the correlation amount COR is calculated by Equation (1).
シフト量s1のシフト処理により、k番目の第1焦点検出信号A(k)とk-s1番目の第2焦点検出信号B(k-s1)を対応させ減算し、シフト減算信号を生成する。生成されたシフト減算信号の絶対値を計算し、焦点検出領域に対応する範囲W内で番号kの和を取り、相関量COR(s1)を算出する。必要に応じて、各行毎に算出された相関量を、各シフト量毎に、複数行に渡って加算しても良い。 By the shift processing of the shift amount s1, the k-th first focus detection signal A(k) and the k-s1-th second focus detection signal B(k-s1) are correlated and subtracted to generate a shift subtraction signal. The absolute value of the generated shift subtraction signal is calculated, the sum of the numbers k is taken within the range W corresponding to the focus detection area, and the correlation amount COR(s1) is calculated. If necessary, the correlation amount calculated for each row may be added over a plurality of rows for each shift amount.
次に、相関量から、サブピクセル演算により、相関量が最小値となる実数値のシフト量を算出して像ずれ量p1とする。そして、算出した像ずれ量p1に、焦点検出領域の像高と、撮像レンズ(結像光学系)のF値、射出瞳距離に応じた変換係数K1をかけて、検出デフォーカス量を検出する。 Next, from the correlation amount, a sub-pixel calculation is performed to calculate the real-value shift amount that minimizes the correlation amount, and this is used as the image shift amount p1. Then, the calculated image shift amount p1 is multiplied by a conversion coefficient K1 corresponding to the image height of the focus detection area, the F value of the imaging lens (imaging optical system), and the exit pupil distance to detect the detected defocus amount. .
S7でシステム制御部50は、選択した焦点検出領域で検出されたデフォーカス量に基づき、レンズ駆動を行う。検出されたデフォーカス量が所定値より小さい場合には、必ずしもレンズ駆動を行う必要はない。
In S7, the
次に、S8で、S1で行った検出・表示用の画像の取得とライブビュー表示、および、S6で行った焦点検出処理を行う。ライブビュー表示には、上述の通り検出された被写体領域や視線位置の情報も重畳して表示する。S8で行う処理は、S7のレンズ駆動中に、並列的に行ってもよい。また、随時更新されるライブビュー表示に合わせて、得られる視線位置に対応させて、焦点検出領域を変更してもよい。焦点検出処理を終えるとS9に進み、システム制御部50は撮影開始指示を示す第2シャッタースイッチ64(Sw2)のオン/オフを検出する。操作部70の一つであるレリーズ(撮影トリガ)スイッチは、押し込み量に応じて、2段階のオン/オフを検出することが可能で、上述のSw2は、レリーズ(撮影トリガ)スイッチの2段階目のオン/オフに相当する。システム制御部50は、S9でSw2のオンが検出されない場合、S5に戻り、Sw1のオン/オフを検出する。
Next, in S8, acquisition of an image for detection/display and live view display performed in S1 and focus detection processing performed in S6 are performed. On the live view display, information on the subject area and line-of-sight position detected as described above is also superimposed and displayed. The processing performed in S8 may be performed in parallel while driving the lens in S7. Also, the focus detection area may be changed in accordance with the obtained line-of-sight position in accordance with the live view display that is updated as needed. When the focus detection process is finished, the process proceeds to S9, and the
S9でSw2のオンが検出されるとシステム制御部50は処理をS10に進め、画像記録を行うか否かを判定する。本実施形態では、連写中の画像取得を、記録画像用と撮像/表示、焦点検出用で、処理を切り替える。切り替えは、交互でもよいし、例えば、3回に1回撮像/表示、焦点検出を行うなどしてもよい。これにより、単位時間当たりの撮影枚数を、大幅に減らすことなく、高精度な焦点検出を行うができる。
When the ON state of Sw2 is detected in S9, the
S10で画像記録を行うと判定した場合には、S300に進み、撮影サブルーチンを実行する。撮影サブルーチンの詳細については後述する。S300で撮影サブルーチンが実行されるとS9に戻り、Sw2のオンが検出される、すなわち連写指示がされているか否かを判断する。 If it is determined in S10 that image recording is to be performed, the process advances to S300 to execute a photographing subroutine. Details of the shooting subroutine will be described later. When the photographing subroutine is executed in S300, the process returns to S9 and it is determined whether or not Sw2 is detected to be on, that is, whether or not continuous photographing is instructed.
S10で撮像/表示、焦点検出を行うと判定した場合には、S400に進み、連写中の撮像/表示、焦点検出処理を実行する。連写中の撮像/表示、焦点検出処理は、実行する処理の内容は、S8と同じである。違いは、連写の撮影コマ速、記録画像の生成処理などに応じて、S400で撮像した画像の表示期間、表示更新レート(間隔)、表示遅延が、S8の処理の場合と異なっている点である。表示制御手段としてのシステム制御部50が、上述の表示制御を行う。本実施形態のように、連写中に、表示画像の表示期間、更新レート、表示遅延が変わった際に、撮影者の視線位置は、少なからず影響を受ける。本発明では、上述の表示仕様の状態や切り替わりに応じて、検出される視線位置に誤差が生じることを鑑みて、適切に視線位置の加工や検出処理の制御を行う。これにより、表示仕様の変化によらず、精度の高い視線位置を取得することができる。得られた視線位置情報は、上述の通り、焦点検出領域の設定や検出された被写体領域との紐づけなどに用いる。詳細は後述する。S400で連写中の撮像/表示、焦点検出処理が実行されるとS9に戻り、Sw2のオンが検出される、すなわち連写指示がされているか否かを判断する。
If it is determined in S10 that imaging/display and focus detection are to be performed, the process advances to S400 to execute imaging/display and focus detection processing during continuous shooting. The imaging/display and focus detection processing during continuous shooting are the same as those in S8. The difference is that the display period, display update rate (interval), and display delay of the image captured in S400 are different from those in the process of S8, depending on the shooting frame speed of continuous shooting, the generation process of the recorded image, and the like. is. The
S5でSw1のオンが検出されず(あるいはオフが検出された)、S11で、メインスイッチのオフが検出されると、焦点検出及び撮影動作を終了する。一方S11でメインスイッチのオフが検出されない場合には、S2に戻り、画像データ、焦点検出データの取得を行う。 When Sw1 is not detected to be on (or is detected to be off) in S5 and the main switch is detected to be off in S11, focus detection and photographing operations are terminated. On the other hand, if it is not detected in S11 that the main switch is off, the process returns to S2 to acquire image data and focus detection data.
[視線予測の説明]
次に、図6を用いて、検出された視線位置情報を用いて予測制御するための視線位置の加工制御処理について説明する。図6は、視線予測方法を説明するためのフローチャートである。図6の処理は、図5のS4以降において、システム制御部50と視線入力操作部701が主体となって、並行して処理が実行される。
[Explanation of line-of-sight prediction]
Next, the line-of-sight position processing control process for predictive control using the detected line-of-sight position information will be described with reference to FIG. FIG. 6 is a flowchart for explaining the line-of-sight prediction method. The processing in FIG. 6 is executed in parallel by the
ステップS201では、所定期間内に、検出された視線位置情報を取得する。 In step S201, the detected line-of-sight position information is acquired within a predetermined period.
次の方法などによって視線の信頼度を算出しておいてもよい。視線検出データの信頼性を取得する方法としては、過去のある時間幅に渡る視線検出位置の分散を算出し、その逆数を取ることで視線情報の信頼性評価値とする方法が考えられる。分散データの逆数を取る事で、分散データが小さい場合は視線情報としてばらつきが小さく、値が安定している(信頼性が高い)ため信頼性の値が大きくなる。逆に、分散データが大きい場合は視線情報としてばらつきが大きく、値が不安定な(信頼性が低い)ため、信頼性の値としては小さくなる。 The line-of-sight reliability may be calculated by the following method or the like. As a method of obtaining the reliability of the line-of-sight detection data, a method of calculating the variance of the line-of-sight detection positions over a certain time span in the past and taking the reciprocal thereof is considered as a reliability evaluation value of the line-of-sight information. By taking the reciprocal of the distributed data, when the distributed data is small, the line-of-sight information has little variation and the value is stable (high reliability), so the reliability value increases. Conversely, when the distributed data is large, the line-of-sight information has large variations and the value is unstable (reliability is low), so the reliability value is small.
その他にも、焦点距離が長い程、ユーザーの手振れにより撮影中の被写体がブレてしまい、そのブレた被写体をユーザーが視線で追うと視線情報も正しく視線で追えず振動してしまうため、焦点距離を加味して信頼性を算出しても良い。具体的には、焦点距離が短い程信頼性を高く、焦点距離が長い程信頼性を低く評価すれば良い。 In addition, the longer the focal length, the more the subject being photographed becomes blurred due to the user's camera shake. may be added to calculate the reliability. Specifically, the shorter the focal length, the higher the reliability, and the longer the focal length, the lower the reliability.
また、上記に加え、瞼の開き具合に応じて視線検出センサ自体から取得された情報を視線情報の信頼性に加味してもよい。瞼の開き具合に応じて視線情報の信頼性が変化する理由は、視線位置に応じて視線検出精度が異なる理由と類似し、瞼によって瞳孔の一部が隠れてしまうことで生じる。瞼の開き具合に応じた視線情報の信頼性の変化は、視線検出センサより取得可能である。視線検出センサで瞼の開き具合による視線情報の信頼性を得ることが出来ない場合には、別途センサより瞼の開き具合の情報を取得し、信頼性を評価しても良い。 In addition to the above, information acquired from the line-of-sight detection sensor itself may be added to the reliability of the line-of-sight information according to the degree of opening of the eyelids. The reason that the reliability of line-of-sight information changes according to the degree of eyelid opening is similar to the reason that the line-of-sight detection accuracy differs according to the line-of-sight position, and is caused by part of the pupil being hidden by the eyelid. A change in the reliability of line-of-sight information according to the degree of eyelid opening can be obtained from a line-of-sight detection sensor. If it is not possible to obtain the reliability of line-of-sight information based on the degree of opening of the eyelids with the line-of-sight detection sensor, information on the degree of opening of the eyelids may be obtained from a separate sensor and the reliability may be evaluated.
ステップS202からS205では、制御パラメータを用いて視線予測を行う。 In steps S202 to S205, line-of-sight prediction is performed using control parameters.
カルマンフィルタを使用する本発明においては、回帰データ数nをあらかじめ決定した固定値とすることが望ましい。視線情報の信頼性を用いて回帰データ数nを決定する方法が考えられる。信頼性が高い場合には即応性を重視するためにnを減らし、信頼性が低い場合には振動成分の抑制を重視するためにnを増やす。しかしながら、nを信頼性に応じて適切な値に決定するのは難しい場合がある。撮影者や撮影条件によって、視線検出のばらつきが異なる。例えば眼が細い撮影者の場合など、ばらつきが大きい撮影者では、常時大きいnが設定され、常に大きな遅延が生じてしまい撮影者の快適性を損ねる場合がある。そのため、予めキャリブレーションなどによって、撮影者毎に最適なnを決定しておいて、撮影時にはnを動的に決定するのではなく、固定のnで視線位置を自動的に決定する方法が望ましい。ただ、nを固定値とすることで視線の即応性が低下する場合があるため、即応性を改善するためにカルマンフィルタを使用するのが効果的である。 In the present invention using the Kalman filter, it is desirable to set the number of regression data n to a predetermined fixed value. A method of determining the number of regression data n using the reliability of line-of-sight information is conceivable. When the reliability is high, n is decreased in order to give importance to responsiveness, and when the reliability is low, n is increased in order to emphasize suppression of vibration components. However, it may be difficult to determine an appropriate value for n depending on reliability. Variation in line-of-sight detection varies depending on the photographer and shooting conditions. For example, for a photographer with wide eyes, a large n is always set, and a large delay always occurs, which may impair the comfort of the photographer. Therefore, it is desirable to automatically determine the line-of-sight position with a fixed n instead of determining the optimum n for each photographer by calibration in advance and then dynamically determining n during shooting. . However, since setting n to a fixed value may reduce the line-of-sight responsiveness, it is effective to use a Kalman filter to improve the responsiveness.
[カルマンフィルタの説明]
カルマンフィルタは、系の誤差の正規性や線形の状態遷移モデルを前提とした場合において、最適なフィルタであることが公知であり、これを視線位置の推定に応用することで視線微動や視線検出の誤差に対して安定かつ遅延の少ないフィルタリングが可能となる。
[Description of Kalman filter]
The Kalman filter is known to be the optimum filter when assuming the normality of errors in the system and a linear state transition model. Filtering can be performed stably with little delay against errors.
カルマンフィルタは状態方程式と観測方程式の2種の方程式と、関連する処理で構成される。本実施形態において、状態方程式は状態遷移モデル、すなわち視線位置の動きをモデル化した式であり、観測方程式は視線位置の検出システムを記述する式である。詳細な例は後述する。また、カルマンフィルタは予測ステップとフィルタリングステップを持つ。予測ステップは前時刻の値から、予め与えた状態方程式(モデル)に従って現在時刻の値の推定値である事前推定値の算出を行う。フィルタリングステップでは、現在時刻の観測値と該事前推定値から、内挿によって値を修正した事後推定値の算出を行う。内挿の重みはカルマンゲインと呼ばれ、事前推定値に対する観測値の誤差の分散から算出される。観測値の誤差の分散が小さい場合は、観測の信頼性が高いとして、事後推定値は観測値に近いものとなる。逆に分散が大きい場合の事後推定値は事前推定値に近い値となる。このように予測ステップとフィルタリングステップを交互に繰り返し算出することで、状態の予測を自動的に行うことができる。前記の誤差の分散もカルマンフィルタで自動的に更新される。カルマンフィルタを用いてもある程度の遅延は避けられないが、誤差の分散が小さい場合には、現在時刻の観測値に近い値を事後推定値として得ることができるため、遅延を最小限に抑えることができる。ただし前記のようにnは撮影者や撮影条件に応じてあらかじめ適切な値に設定する必要がある。 The Kalman filter consists of two types of equations, a state equation and an observation equation, and related processing. In this embodiment, the state equation is a state transition model, that is, an equation that models the line-of-sight position movement, and the observation equation is an equation that describes the line-of-sight position detection system. A detailed example will be described later. Also, the Kalman filter has a prediction step and a filtering step. In the prediction step, a pre-estimated value, which is an estimated value at the current time, is calculated from the value at the previous time according to a state equation (model) given in advance. In the filtering step, a post-estimate value corrected by interpolation is calculated from the observed value at the current time and the pre-estimated value. The interpolation weight is called the Kalman gain and is calculated from the variance of the error of the observed value with respect to the prior estimate. When the variance of the observed value error is small, the posterior estimate is close to the observed value, assuming that the reliability of the observation is high. Conversely, when the variance is large, the posterior estimate is close to the prior estimate. By alternately and repeatedly calculating the prediction step and the filtering step in this manner, the state can be automatically predicted. The error variance described above is also automatically updated by the Kalman filter. Even if the Kalman filter is used, a certain amount of delay cannot be avoided, but if the variance of the error is small, a value close to the observed value at the current time can be obtained as the posterior estimate, so the delay can be minimized. can. However, as described above, n must be set to an appropriate value in advance according to the photographer and shooting conditions.
〔3次以上の高次の多項式をカルマンフィルタの状態方程式として使用したときの課題である「オーバーフィット(過学習)問題」についての説明〕
カルマンフィルタの状態方程式には、予測する系の状態変化をモデル化した式を使用する必要がある。視線位置の予測においては視線の動きをモデル化した式が必要となるが、カメラ撮影時にファインダで被写体を目で追うときの視線は撮影者の意思によるため、所謂、等速直線運動のような明確なモデル式は存在しない。しかしながら、人間の視線の動きは、カメラの撮影フレームを毎秒数30フレームとした場合、10フレーム分程度の時間長さ(約0.3秒)においては、連続的な動きをする場合が多い。そのため、撮影時のある時刻における視線位置は、その時刻から過去10フレーム分程度の視線データから、位置の連続性を仮定して精度良く予測できる場合が多い。この考え方にもとづくと、視線データの履歴を回帰データとした回帰式を視線予測の状態方程式として近似的に使用できる。回帰式の選定に関して、まず、撮像装置での処理の負荷を考慮すると、低い演算コストで処理が可能な線形カルマンフィルタが望ましい。そのため、カルマンフィルタの状態方程式として使用する回帰式は多項式回帰式が望ましい。次に視線予測の安定性を考慮すると、低次の多項式が望ましい。人間の視線は無意識に微動しており、カメラの表示装置に視線位置を表示し、それを目視しながら被写体選択や測距点選択を快適に行うためには、フィルタによって視線を平滑化した表示が必要となる。高次の多項式回帰式を用いると、回帰データの各点に対する誤差は低減させることができるが、所謂、オーバーフィットによって予測値に振動が生じてしまう。そのため、視線の予測に使用する回帰式としては、0~2次の低次の回帰式が望ましい。3次以上の回帰式では変曲点が1つ以上存在し、極大値と極小値を持つこととなるため、これが振動として生じてしまう可能性がある。
[Description of the "overfitting (overlearning) problem", which is a problem when using a higher-order polynomial of third or higher order as the state equation of the Kalman filter]
The state equation of the Kalman filter should use an equation that models the state change of the system to be predicted. Predicting the line-of-sight position requires a formula that models the movement of the line of sight. There is no clear model formula. However, when the number of frames captured by a camera is 30 frames per second, the human line of sight often moves continuously for a time length of about 10 frames (about 0.3 seconds). Therefore, in many cases, the line-of-sight position at a certain time during shooting can be accurately predicted from the line-of-sight data for about 10 frames in the past from that time, assuming the continuity of the positions. Based on this concept, a regression equation using the history of line-of-sight data as regression data can be approximately used as a state equation for line-of-sight prediction. Regarding the selection of the regression equation, first, considering the processing load on the imaging device, a linear Kalman filter that can be processed at a low calculation cost is desirable. Therefore, it is desirable that the regression equation used as the state equation of the Kalman filter be a polynomial regression equation. Next, considering the stability of line-of-sight prediction, a low-order polynomial is desirable. The human line of sight moves unconsciously, so in order to display the position of the line of sight on the display device of the camera, and to comfortably select subjects and AF points while looking at it, it is necessary to smooth the line of sight using a filter. Is required. Using a higher-order polynomial regression equation can reduce the error for each point in the regression data, but causes oscillations in the predicted values due to so-called overfitting. Therefore, it is desirable to use a low-order regression formula of 0 to 2 as the regression formula used for predicting the line of sight. A cubic or higher regression equation has one or more points of inflection and has a maximum value and a minimum value, which may cause oscillation.
[低次の多項式回帰式をカルマンフィルタの状態方程式として用いた実施例]
本実施例では視線位置の過去の履歴データから直線回帰とカルマンフィルタを用いて視線位置の予測を行う場合について、図6と図7を参照して説明する。図7ではn=6とした例を示す。
[Embodiment using a low-order polynomial regression equation as the state equation of the Kalman filter]
In this embodiment, a case where the line-of-sight position is predicted using linear regression and a Kalman filter from past history data of the line-of-sight position will be described with reference to FIGS. 6 and 7. FIG. FIG. 7 shows an example where n=6.
処理開始後、ステップS201で視線位置を取得する。同時に過去n点の視線の履歴データを蓄積しておく。蓄積データ数をmとして、mがn未満の場合は、n=mとして、以降で説明するステップS202~S205の処理を行ってもよいし、m=nとなるまで視線データを蓄積してから処理を開始してもよい。 After the process starts, the line-of-sight position is acquired in step S201. At the same time, history data of the past n points of sight lines are accumulated. If the number of accumulated data is m, and m is less than n, the processing of steps S202 to S205 described below may be performed with n=m, or after accumulating line-of-sight data until m=n Processing may begin.
図6のフローチャートでは処理の順序としてステップS201の直後にステップS202が続くが、ステップS201~S205は繰り返し処理されるため、説明の都合上、ステップS203から説明する。 In the flowchart of FIG. 6, step S202 follows immediately after step S201 as the order of processing, but since steps S201 to S205 are repeatedly processed, for the convenience of explanation, step S203 will be described.
処理開始後、ステップS202で視線位置xの事前推定値xqの初期値は、観測値をそのまま使用してもよいし、位置の座標原点の値を使用するなどでもよい。また、後述の事前推定値の誤差eqの分散Pqの初期値については公知のように0より大きな10-2程度の小さな値を与えればよい。 After the process is started, the initial value of the pre-estimated value xq of the line-of-sight position x in step S202 may be the observed value as it is or the value of the coordinate origin of the position. Also, as is well known, a small value greater than 0, such as about 10 −2 , may be given to the initial value of the variance P q of the error e q of the pre-estimated value, which will be described later.
視線座標を(x,y)とする。ここでは説明のために1次元の視線座標xについて説明するが、yについても同様である。 Let the line-of-sight coordinates be (x, y). For the sake of explanation, the one-dimensional line-of-sight coordinate x will be described here, but the same applies to y.
撮像装置のライブビュー撮影で連続的に複数フレームの撮影を行うものとして、そのk番目の撮影フレーム(以降、フレームkと称す)における時刻をt(k)、直線回帰式を数式(1)とする。tは時刻で独立変数である。 Assuming that a plurality of frames are continuously shot by live view shooting of an imaging device, the time at the k-th shot frame (hereinafter referred to as frame k) is t(k), and the linear regression equation is expressed as Equation (1). do. t is time and is an independent variable.
図7(a)は時刻t(k-n+1)~t(k)までのn個のデータから直線回帰計算を行うことを説明する図である。算出した回帰直線はLf(k)である。 FIG. 7(a) is a diagram for explaining linear regression calculation from n pieces of data from time t(k−n+1) to t(k). The calculated regression line is L f (k).
ステップS203で回帰係数a(k),b(k)を算出する。 In step S203, regression coefficients a(k) and b(k) are calculated.
数式(1)の回帰係数a(k),b(k)をn個の回帰データから最小二乗法によって数式(2)と数式(3)で算出する。公知の逐次最小二乗法などでa(k),b(k)を算出してもよい。 Regression coefficients a(k) and b(k) of equation (1) are calculated from n pieces of regression data by the least-squares method using equations (2) and (3). You may calculate a(k) and b(k) by well-known iterative least-squares method.
これより、次フレーム、すなわちフレームk+1における事前推定値xq(k+1)は、図7(b)に示すように、回帰データとして時刻t(k-n+1)~t(k)での事後推定値xpを使用して数式(4)によりステップS204で算出する。 From this, the a priori estimated value x q (k+1) in the next frame, that is, the frame k+1 is the posterior estimated value at times t(k−n+1) to t(k) as regression data, as shown in FIG. xp is used to calculate in step S204 by Equation (4).
数式(4)において数式(2)、数式(3)より、a(k)とb(k)にはx(k)の高々一次の項が含まれるので、これは位置x(k)に関して線形の式となる。 In equation (4), from equations (2) and (3), a(k) and b(k) contain at most first-order terms in x(k), so this is linear with respect to position x(k) The formula is
本実施例において、カルマンフィルタの状態方程式は、数式(5)とする。 In this embodiment, the state equation of the Kalman filter is given by Equation (5).
数式(5)はA(k)とu(k)の一部に回帰係数を含む線形の状態方程式である。数式(5)は数式(4)でx(k)について整理することで得られる。v(k)は視線微動等によるモデル化誤差成分であり、平均0、分散Q(k)の正規分布に従う確率変数であるとする。 Equation (5) is a linear state equation including regression coefficients in part of A(k) and u(k). Equation (5) is obtained by rearranging x(k) in Equation (4). It is assumed that v(k) is a modeling error component due to slight eye movement, etc., and is a random variable that follows a normal distribution with mean 0 and variance Q(k).
Q(k)は公知の人間の固視微動の平均的な値を与えてもよいし、視線検出装置のキャリブレーション後に、座標位置の正解が判っている指標点に対して測定した視線位置の分散を与えるなどでもよい。 Q(k) may be a known average value of human fixational eye movement, or may be the gaze position measured with respect to an index point whose correct coordinate position is known after calibration of the gaze detection device. For example, a variance may be given.
カルマンフィルタの観測方程式を、数式(6)とする。 Let the observation equation of the Kalman filter be Formula (6).
w(k)は測定誤差であり、平均0、分散R(k)の正規分布に従う確率変数であるとする。 Let w(k) be the measurement error, which is a random variable following a normal distribution with mean 0 and variance R(k).
R(k)は、座標位置の正解が判っている指標画像などを用いて予め測定した視線検出装置の誤差を与えてもよいし、視線位置の事後推定値に対する観測値の誤差の分散から、毎フレーム、あるいは数フレーム毎に動的に更新してもよい。 R(k) may be the error of the line-of-sight detection device that is measured in advance using an index image for which the correct coordinate position is known. It may be dynamically updated every frame or every few frames.
また、事前推定値の誤差eq(k)と事後推定値の誤差qp(k)を数式(7)、数式(8)のように定義する。xp(k)は視線位置xの事後推定値である。 Also, the error e q (k) of the pre-estimated value and the error q p (k) of the post-estimated value are defined as in Equations (7) and (8). x p (k) is the posterior estimate of the gaze position x.
eq(k)の分散をPq(k)、ep(k)の分散をPp(k)として、誤差の分散についても数式(9)で更新する。 With the variance of e q (k) as P q (k) and the variance of e p (k) as P p (k), the error variance is also updated by Equation (9).
次に、図7(c)に示すように、カルマンフィルタのフィルタリングステップで事後推定値x(k+1)を算出する。 Next, as shown in FIG. 7C, the posterior estimated value x(k+1) is calculated in the filtering step of the Kalman filter.
まず、カルマンゲインG(k)を数式(10)で算出する。 First, the Kalman gain G(k) is calculated by Equation (10).
さらにカルマンゲインによって、数式(11)によって事後推定値の更新を行う。 Further, the Kalman gain is used to update the posterior estimated value by Equation (11).
これは、事後推定値を事前推定値と観測値からカルマンゲインを重みとして内挿する式である。観測誤差の分散Rが事前推定値の誤差Pqとくらべて大きい場合はカルマンゲインG≒0となり、事後推定値xpは事前推定値と近い値となる。逆に、事前推定値の誤差Pqが観測誤差の分散Rよりも大きい場合は、カルマンゲインG≒1となり、事後推定値xpは観測値xmと近い値となる。 This is a formula for interpolating the posterior estimated value from the prior estimated value and the observed value using the Kalman gain as a weight. When the variance R of the observation error is larger than the error Pq of the pre-estimated value, the Kalman gain G≈0, and the posterior estimate x p is close to the pre-estimated value. Conversely, when the error Pq of the pre-estimated value is larger than the variance R of the observed error, the Kalman gain G≈1 , and the post-estimated value xp is close to the observed value xm.
誤差の分散は数式(12)で更新する。 The error variance is updated by Equation (12).
次に、図7(d)に示すように時刻を1つ進め、ステップS201~ステップS205で同様の処理を繰り返す。 Next, as shown in FIG. 7D, the time is advanced by one, and the same processing is repeated in steps S201 to S205.
以上を順次、撮影フレームで繰り替えし演算処理することで、観測値の誤差の大きさに応じて、自動的に事後推定値の分散が最小となるような視線位置を算出、予測することができる。 By repeatedly repeating the above process for each captured frame, it is possible to automatically calculate and predict the line-of-sight position that minimizes the variance of the posterior estimated value according to the size of the error in the observed value. .
なお、実施例の説明では連続して取得された視線情報を用いて視線予測をする場合について述べたが、視線取得中に瞬きやシャッター等の理由で部分的に視線情報が取得できない場合がある。その場合においても、取得できなかった時間の視線情報を加味して視線情報とその視線情報を取得したタイミングを適切に関連付けて視線予測処理をすれば良く、必ずしも連続した視線情報を用いなければ視線予測ができないわけではない。 In addition, in the description of the embodiment, the case of predicting the line of sight using the continuously acquired line of sight information was described, but there are cases where the line of sight information cannot be partially acquired due to reasons such as blinking or shuttering during the line of sight acquisition. . Even in such a case, the line-of-sight information may be appropriately associated with the timing when the line-of-sight information was acquired, taking into consideration the line-of-sight information for the time when the line-of-sight information could not be obtained. It's not unpredictable.
また、実施例では、回帰式の次数を1次として、撮影時に固定値として実施した例を示し。例えばある時間幅にわたって検出情報が取得できている比率や、ある時間幅にわたる視線位置の誤差や視線の信頼度等を加味して、回帰式の次数を動的に変化させてもよい。 Further, in the embodiment, an example is shown in which the order of the regression equation is set to the first order, and fixed values are set at the time of photographing. For example, the order of the regression equation may be dynamically changed in consideration of the rate at which detection information can be acquired over a certain time span, the line-of-sight position error over a certain time span, the line-of-sight reliability, and the like.
また、実施例では本発明をデジタルカメラで実施する例を説明したが、視線検出を行う装置であればどんな装置に適用しても良い。例えばヘッドマウントディスプレイやスマートフォン、PC等において実施することも可能である。 Also, in the embodiments, an example in which the present invention is implemented in a digital camera has been described, but the present invention may be applied to any device as long as it performs line-of-sight detection. For example, it is also possible to implement in a head mounted display, a smart phone, a PC, or the like.
また、前述の実施例でフローチャートを用いて説明した動作は、同様の目的を達成することができるように、適宜実行されるステップの順序を変更することが可能である。 Also, in the operations described using the flowcharts in the above embodiments, it is possible to change the order of the steps to be executed as appropriate so as to achieve the same purpose.
本発明は、上述の実施例の1以上の機能を実現するプログラムを、ネットワークあるいは記憶媒体を介してシステム又は装置に供給する構成をとることも可能である。。そして、、そのシステムあるいは装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。 The present invention can also be configured to supply a program implementing one or more functions of the above-described embodiments to a system or apparatus via a network or storage medium. . It can also be realized by processing in which one or more processors in the computer of the system or apparatus read and execute the program. It can also be implemented by a circuit (for example, ASIC) that implements one or more functions.
Claims (4)
前記視線情報を補正する補正手段と、を有し、
前記補正手段は、低次の多項式回帰式を用いたカルマンフィルタによって前記視線情報を補正することを特徴とする処理装置。 acquisition means for acquiring line-of-sight information corresponding to the line-of-sight position of a person;
and a correction means for correcting the line-of-sight information,
The processing device, wherein the correction means corrects the line-of-sight information by a Kalman filter using a low-order polynomial regression equation.
前記取得手段は、人物が注視する該表示手段における視線の位置に対応する情報を、前記視線情報として取得することを特徴とする請求項1乃至請求項3のいずれか1項に記載の処理装置。 having display means for displaying an image,
4. The processing apparatus according to any one of claims 1 to 3, wherein the acquisition unit acquires, as the line-of-sight information, information corresponding to a line-of-sight position on the display unit at which a person gazes. .
前記視線情報を補正する補正ステップと、を有し、
前記補正ステップでは、カルマンフィルタを用いて前記視線情報を補正することを特徴とする処理装置の制御方法。 an acquisition step of acquiring line-of-sight information corresponding to the line-of-sight position of a person;
a correction step of correcting the line-of-sight information;
The method of controlling a processing device, wherein in the correcting step, the line-of-sight information is corrected using a Kalman filter.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2021106530A JP2023004678A (en) | 2021-06-28 | 2021-06-28 | Processing device and control method therefor |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2021106530A JP2023004678A (en) | 2021-06-28 | 2021-06-28 | Processing device and control method therefor |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2023004678A true JP2023004678A (en) | 2023-01-17 |
Family
ID=85100717
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2021106530A Pending JP2023004678A (en) | 2021-06-28 | 2021-06-28 | Processing device and control method therefor |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2023004678A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117111252A (en) * | 2023-10-12 | 2023-11-24 | 北京建筑大学 | Optical instrument position adjustment method, system and storage medium |
-
2021
- 2021-06-28 JP JP2021106530A patent/JP2023004678A/en active Pending
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117111252A (en) * | 2023-10-12 | 2023-11-24 | 北京建筑大学 | Optical instrument position adjustment method, system and storage medium |
CN117111252B (en) * | 2023-10-12 | 2024-01-30 | 北京建筑大学 | Optical instrument position adjustment method, system and storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105282435B (en) | Zoom control equipment and Zoom control method | |
CN105323470B (en) | Zoom control equipment and Zoom control method | |
JP7615367B2 (en) | Electronic device and control method thereof | |
US20230042807A1 (en) | Electronic device | |
JP2013101305A (en) | Focus adjustment device and control method for focus adjustment device | |
JP2021105694A (en) | Imaging apparatus and method for controlling the same | |
JP2019029998A (en) | IMAGING DEVICE, IMAGING DEVICE CONTROL METHOD, AND CONTROL PROGRAM | |
CN101534394B (en) | Camera and camera method | |
US11523048B2 (en) | Electronic device, control method of electronic device, and non-transitory computer readable medium | |
JP2024055966A (en) | Subject tracking device, control method thereof, program, and storage medium | |
JP7538647B2 (en) | Gaze position processing device, imaging device, learning device, gaze position processing method, learning method, and program | |
US20210258472A1 (en) | Electronic device | |
CN107800956B (en) | Image pickup apparatus, control method, and storage medium | |
JP2023004678A (en) | Processing device and control method therefor | |
US11877051B2 (en) | Eye-gaze information acquiring apparatus, imaging apparatus, eye-gaze information acquiring method, and computer-readable storage medium | |
JP6253454B2 (en) | IMAGING DEVICE AND IMAGING DEVICE CONTROL METHOD | |
US12086310B2 (en) | Electronic apparatus and control method | |
JP7532045B2 (en) | Electronics | |
US11968445B2 (en) | Control apparatus for detecting and displaying line-of-sight position, control method thereof, and recording medium | |
JP2023047605A (en) | Control device, imaging device, control method, and program | |
US20250056117A1 (en) | Focus adjustment apparatus and method, electronic device, and storage medium | |
JP7254555B2 (en) | IMAGING DEVICE AND METHOD OF CONTROLLING IMAGING DEVICE | |
JP6465322B2 (en) | IMAGING DEVICE AND IMAGING DEVICE CONTROL METHOD | |
JP6858022B2 (en) | Focus detector, its control method and program, and imaging device | |
JP2024015578A (en) | Control device, imaging device, control method, and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD01 | Notification of change of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7421 Effective date: 20231213 |