JP7278737B2 - IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM - Google Patents

IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM Download PDF

Info

Publication number
JP7278737B2
JP7278737B2 JP2018188925A JP2018188925A JP7278737B2 JP 7278737 B2 JP7278737 B2 JP 7278737B2 JP 2018188925 A JP2018188925 A JP 2018188925A JP 2018188925 A JP2018188925 A JP 2018188925A JP 7278737 B2 JP7278737 B2 JP 7278737B2
Authority
JP
Japan
Prior art keywords
subject
image
amount
region
feature
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.)
Active
Application number
JP2018188925A
Other languages
Japanese (ja)
Other versions
JP2020057302A (en
Inventor
勇太 川村
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon 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 Canon Inc filed Critical Canon Inc
Priority to JP2018188925A priority Critical patent/JP7278737B2/en
Publication of JP2020057302A publication Critical patent/JP2020057302A/en
Application granted granted Critical
Publication of JP7278737B2 publication Critical patent/JP7278737B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Image Analysis (AREA)
  • Studio Devices (AREA)

Description

本発明は、撮像装置及びその制御方法、並びにプログラムに関する。 The present invention relates to an imaging device, its control method, and a program.

デジタルカメラにおいて、得られた画像データから画像の特定領域(特徴量領域)の特徴量をもとに、被写体を追尾し、その被写体に対してピント、明るさ、色などの撮影条件を好適な状態に合わせて撮影することが一般的になっている。このとき、特許文献1のように、特徴量領域のサイズを広めに設定すると、被写体の追尾において、当該特徴量領域に対応する画像領域の探索に用いる情報が多くなるため、追尾性能が向上すると期待される。 In a digital camera, a subject is tracked based on the feature amount of a specific area (feature amount area) of the image from the obtained image data, and shooting conditions such as focus, brightness, color, etc. are adjusted appropriately for the subject. It is common to shoot according to the conditions. At this time, if the size of the feature amount region is set wider as in Patent Document 1, the amount of information used to search for the image area corresponding to the feature amount region in tracking the subject increases, so the tracking performance is improved. Be expected.

特開平8-329110号公報JP-A-8-329110

しかし、特許文献1の技術は、画像を探索する際に、画像情報に基づき特徴量領域のサイズを変更するものではない。従って、仮に、特許文献1に係る技術を被写体の追尾における特徴量領域の探索に適用して、追尾性能の向上のために特徴量領域のサイズを大きくしたとすると、逆に、追尾が失敗してしまうことがある。 However, the technique of Patent Document 1 does not change the size of the feature amount region based on the image information when searching for the image. Therefore, if the technology according to Patent Document 1 is applied to search for a feature amount region in subject tracking and the size of the feature amount region is increased to improve tracking performance, tracking will fail. Sometimes I end up

例えば、特徴量領域が被写体領域よりも大きくなると、特徴量領域は、被写体の背景も含むことになる。この場合、被写体の追尾中に、例えば、カメラが大きく動く、被写体がそもそも動体であるなどといった状況が発生すると、特徴量領域内の背景情報が時間の経過に伴い変化することとなる。即ち、被写体(追尾対象)と背景との位置関係が大きく変わってしまい、同一特徴量が存在しなくなり、結果として、追尾が失敗してしまう。 For example, if the feature amount area is larger than the subject area, the feature amount area will also include the background of the subject. In this case, if a situation occurs during tracking of the subject, for example, the camera moves significantly or the subject is originally a moving body, the background information in the feature amount region will change over time. That is, the positional relationship between the subject (tracking target) and the background changes significantly, and the same feature amount no longer exists, resulting in failure of tracking.

本発明は、画像情報に基づき特徴量領域のサイズを決定することで、追尾状況によらず常に高い追尾性能を得ることが可能な撮像装置を提供することを目的とする。 SUMMARY OF THE INVENTION It is an object of the present invention to provide an imaging apparatus capable of always obtaining high tracking performance regardless of tracking conditions by determining the size of a feature amount region based on image information.

本発明の例に係る撮像装置は、第1の画像及び第2の画像を時系列で取得可能な撮像装置であって、前記第1の画像から追尾対象としての被写体を検出する被写体検出手段と、前記第1の画像に基づき前記被写体を含む特徴量領域を登録する特徴量領域登録手段と、前記第1及び第2の画像に係る、前記被写体の動き量を含む情報に基づき、前記特徴量領域登録手段に登録された前記特徴量領域のサイズの更新を行う特徴量領域更新手段と、前記第2の画像から、前記特徴量領域更新手段でサイズが更新された前記特徴量領域に対応する画像領域の探索を行うことで、前記被写体の追尾を行う被写体追尾手段と、を備える。 An imaging device according to an example of the present invention is an imaging device capable of acquiring a first image and a second image in time series, and includes subject detection means for detecting a subject as a tracking target from the first image. a feature region registering means for registering a feature region including the subject based on the first image; feature quantity region updating means for updating the size of the feature quantity region registered in the region registering means; and subject tracking means for tracking the subject by searching an image area.

本発明によれば、画像情報に基づき特徴量領域のサイズを決定することで、追尾状況によらず常に高い追尾性能を得ることが可能な撮像装置を提供できる。 According to the present invention, it is possible to provide an imaging apparatus capable of always obtaining high tracking performance regardless of the tracking situation by determining the size of the feature amount region based on the image information.

撮像装置の構成例を示すブロック図である。It is a block diagram which shows the structural example of an imaging device. 被写体認識部の構成例を示すブロック図である。3 is a block diagram showing a configuration example of a subject recognition unit; FIG. 撮像装置の動作例を示すフローチャートである。4 is a flow chart showing an operation example of the imaging device; 被写体認識処理の例を示すフローチャートである。8 is a flowchart showing an example of subject recognition processing; 被写体検出処理の例を示すフローチャートである。9 is a flowchart showing an example of subject detection processing; 被写体検出処理での評価画素及び推定領域の例を示す図である。FIG. 10 is a diagram showing examples of evaluation pixels and estimation regions in subject detection processing; 被写体検出処理での評価領域の例を示す図である。FIG. 10 is a diagram showing an example of an evaluation region in subject detection processing; 背景動き量の取得処理の例を示すフローチャートである。9 is a flowchart illustrating an example of background motion amount acquisition processing; 特徴量領域の更新処理の例を示すフローチャートである。8 is a flowchart illustrating an example of update processing of feature amount regions; 特徴量領域のサイズと動き量の差との関係を示す図である。FIG. 10 is a diagram showing the relationship between the size of a feature amount region and the difference in motion amount; 特徴量領域のサイズの変更例を示す図である。FIG. 10 is a diagram showing an example of changing the size of a feature amount region; テンプレートマッチングの例を示す図である。FIG. 10 is a diagram showing an example of template matching;

以下、本発明の実施形態について、図面を参照して詳細に説明する。
本発明は、被写体に対して特徴量領域を設定し、かつ当該特徴量領域に基づき、被写体を追尾すると共に当該被写体に対してピント、明るさ、色などの撮影条件を好適な状態に合わせる機能を有する撮像装置に関する。以下に説明する撮像装置は、ビデオカメラ、デジタルスチルカメラ、それらに使用可能な交換レンズなどの光学機器に適用される。
BEST MODE FOR CARRYING OUT THE INVENTION Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.
The present invention is a function of setting a feature amount area for a subject, tracking the subject based on the feature amount area, and adjusting shooting conditions such as focus, brightness, color, etc., to a suitable state for the subject. It relates to an imaging device having The imaging apparatus described below is applied to optical equipment such as video cameras, digital still cameras, and interchangeable lenses usable for them.

<撮像装置>
図1は、撮像装置の構成例を示す。
撮像装置100は、動画、静止画などの画像の撮影及び記録が可能である。撮像装置100内の各機能ブロックは、互いに通信可能な状態となるように、バス160により接続される。撮像装置100の各機能は、主制御部151がプログラムを実行して各機能ブロックを制御することにより実現される。
<Imaging device>
FIG. 1 shows a configuration example of an imaging device.
The imaging device 100 can shoot and record images such as moving images and still images. Each functional block in the imaging device 100 is connected by a bus 160 so as to be in a state of being able to communicate with each other. Each function of the imaging device 100 is realized by the main control unit 151 executing a program and controlling each functional block.

撮像装置100は、画像を解析し、かつその解析結果から特定の被写体領域を推定する被写体認識部161を備える。本実施形態は、被写体認識部161を用いて、画像情報(撮影時に得られる画像の情報)に基づき特徴量領域のサイズを変更可能とする点を特徴の一つとする。 The imaging device 100 includes a subject recognition unit 161 that analyzes an image and estimates a specific subject area from the analysis result. One of the features of this embodiment is that the object recognition unit 161 can be used to change the size of the feature amount region based on image information (image information obtained at the time of shooting).

ここで、画像情報は、撮影レンズ(レンズユニット)101、及び撮像素子141により、時系列で取得可能な複数の画像(複数のフレーム)に係る情報のことである。画像情報は、例えば、画面の平均輝度、WB(ホワイトバランス)、GPS機能による位置情報などを含む。また、画像情報は、後述するように、当該複数の画像から得られる情報、例えば、被写体の動き量、背景の動き量、さらには、それらから取得される被写体(追尾対象)と背景との位置関係の変化量なども含む。 Here, the image information is information relating to a plurality of images (a plurality of frames) that can be acquired in time series by the photographing lens (lens unit) 101 and the imaging device 141 . The image information includes, for example, the average brightness of the screen, WB (white balance), and position information by the GPS function. As will be described later, the image information is information obtained from the plurality of images, such as the amount of movement of the subject, the amount of movement of the background, and the positions of the subject (tracking target) and the background obtained from them. It also includes the amount of change in relationships.

このように、本実施形態では、被写体認識部161により特徴量領域のサイズを変更可能とすることで、追尾状況によらず常に高い追尾性能を得ることが可能な撮像装置を実現するものである。そのため、被写体認識部161は、被写体検出機能と、特徴量領域登録機能と、背景の動き量取得機能と、特徴量領域更新機能と、被写体追尾機能と、を有する。これらの機能の詳細については、後述する。 As described above, in the present embodiment, by enabling the object recognition unit 161 to change the size of the feature amount region, it is possible to realize an imaging apparatus that can always obtain high tracking performance regardless of the tracking situation. . Therefore, the subject recognition unit 161 has a subject detection function, a feature amount region registration function, a background motion amount acquisition function, a feature amount region update function, and a subject tracking function. Details of these functions will be described later.

撮影レンズ101は、固定1群レンズ102と、ズームレンズ111と、絞り103と、固定3群レンズ121と、フォーカスレンズ131と、ズームモータ112と、絞りモータ104と、フォーカスモータ132と、を備える。固定1群レンズ102、ズームレンズ111、絞り103、固定3群レンズ121、及びフォーカスレンズ131は、撮影光学系を構成する。 The taking lens 101 includes a fixed 1st group lens 102, a zoom lens 111, an aperture 103, a fixed 3rd group lens 121, a focus lens 131, a zoom motor 112, an aperture motor 104, and a focus motor 132. . A fixed 1st group lens 102, a zoom lens 111, an aperture 103, a fixed 3rd group lens 121, and a focus lens 131 constitute a photographing optical system.

尚、同図において、各レンズ102、111、121、131は、便宜上、1枚のレンズとして示しているが、複数のレンズの組み合わせから構成されてもよい。また、撮像装置100がカメラシステムを構成する場合、撮影レンズ101は、カメラ本体と一体化されてもよいし、又はカメラ本体から着脱可能なように構成されてもよい。 In the figure, each of the lenses 102, 111, 121, and 131 is shown as one lens for the sake of convenience, but may be composed of a combination of a plurality of lenses. Further, when the imaging device 100 constitutes a camera system, the photographing lens 101 may be integrated with the camera body, or may be configured to be detachable from the camera body.

絞り制御部105は、絞り103を駆動する絞りモータ104の動作を制御する。即ち、絞り制御部105は、絞り103の開口径を変更する。ズーム制御部113は、ズームレンズ111を駆動するズームモータ112の動作を制御する。即ち、ズーム制御部113は、撮影レンズ101の焦点距離(画角)を変更する。 A diaphragm control unit 105 controls the operation of a diaphragm motor 104 that drives the diaphragm 103 . That is, the aperture control unit 105 changes the aperture diameter of the aperture 103 . A zoom control unit 113 controls the operation of a zoom motor 112 that drives the zoom lens 111 . That is, the zoom control unit 113 changes the focal length (angle of view) of the photographing lens 101 .

フォーカス制御部133は、撮像素子141から得られる1対の焦点検出用信号(A像及びB像)の位相差に基づき、撮影レンズ101のデフォーカス量及びデフォーカス方向を取得する。そして、フォーカス制御部133は、デフォーカス量及びデフォーカス方向をフォーカスモータ132の駆動量及び駆動方向に変換する。この駆動量及び駆動方向に基づき、フォーカス制御部133は、フォーカスモータ132の動作を制御し、フォーカスレンズ131を駆動することで、撮影レンズ101の焦点状態を制御する。 The focus control unit 133 acquires the defocus amount and the defocus direction of the photographing lens 101 based on the phase difference between the pair of focus detection signals (the A image and the B image) obtained from the imaging device 141 . The focus control unit 133 then converts the defocus amount and defocus direction into the drive amount and drive direction of the focus motor 132 . Based on this driving amount and driving direction, the focus control unit 133 controls the operation of the focus motor 132 and drives the focus lens 131 to control the focus state of the photographing lens 101 .

このように、フォーカス制御部133は、位相差検出方式の自動焦点検出(AF)を実施する。但し、フォーカス制御部133は、位相差検出方式によるAFに代えて、画像信号から得られるコントラスト評価値に基づくコントラスト検出方式を用いて、AFを実行してもよい。 In this manner, the focus control unit 133 performs automatic focus detection (AF) using a phase difference detection method. However, the focus control unit 133 may perform AF using a contrast detection method based on a contrast evaluation value obtained from an image signal instead of AF using a phase difference detection method.

撮影レンズ101によって撮像素子141の結像面に形成される被写体像は、撮像素子141内に配置された複数の画素のそれぞれが有する光電変換素子により電気信号(画像信号)に変換される。撮像素子141は、例えば、CCD、CMOSイメージセンサなどであり、水平方向m画素、及び垂直方向n画素の画素アレイを備える。但し、n及びmは、それぞれ2以上の自然数である。各画素は、2つの光電変換素子(光電変換領域)を有する。撮像制御部143は、主制御部151からの指示に基づき、撮像素子141からの画像信号の読み出しを制御する。 A subject image formed on the imaging plane of the imaging element 141 by the photographing lens 101 is converted into an electrical signal (image signal) by a photoelectric conversion element of each of a plurality of pixels arranged in the imaging element 141 . The imaging element 141 is, for example, a CCD or CMOS image sensor, and has a pixel array of m pixels in the horizontal direction and n pixels in the vertical direction. However, n and m are natural numbers of 2 or more, respectively. Each pixel has two photoelectric conversion elements (photoelectric conversion regions). The imaging control unit 143 controls readout of image signals from the imaging device 141 based on instructions from the main control unit 151 .

撮像素子141から読み出された画像信号は、画像信号処理部142に供給される。画像信号処理部142は、ノイズ低減処理、A/D変換処理、自動利得制御処理などの信号処理を画像信号に適用し、かつ当該信号処理が適用された画像信号を撮像制御部143に出力する。撮像制御部143は、画像信号処理部142から受信した画像信号をRAM(ランダム・アクセス・メモリ)154に保存する。 An image signal read out from the imaging element 141 is supplied to the image signal processing section 142 . The image signal processing unit 142 applies signal processing such as noise reduction processing, A/D conversion processing, and automatic gain control processing to the image signal, and outputs the image signal to which the signal processing has been applied to the imaging control unit 143. . The imaging control unit 143 stores the image signal received from the image signal processing unit 142 in a RAM (random access memory) 154 .

画像処理部152は、RAM154に記憶された画像信号に対して、予め定められた画像処理を適用する。画像処理部152が適用する画像処理は、例えば、ホワイトバランス調整処理、色補間(デモザイク)処理、ガンマ補正処理などのいわゆる現像処理を含む。また、当該画像処理は、信号形式変換処理、スケーリング処理などを含んでもよい。当該画像処理の例としては、これらに限定されず、上述以外の処理を行っても構わない。 The image processing unit 152 applies predetermined image processing to the image signal stored in the RAM 154 . The image processing applied by the image processing unit 152 includes, for example, so-called development processing such as white balance adjustment processing, color interpolation (demosaicing) processing, and gamma correction processing. Also, the image processing may include signal format conversion processing, scaling processing, and the like. Examples of the image processing are not limited to these, and processing other than the above may be performed.

画像処理部152は、自動露出制御(AE)に用いるための、被写体輝度に関する情報などを生成することもできる。特定の被写体領域に関する情報は、被写体認識部161から画像処理部152に供給され、例えば、ホワイトバランス調整処理に利用される。尚、コントラスト検出方式によるAFを行う場合、画像処理部152は、AF評価値を生成することも可能である。画像処理部152は、処理済の画像信号をRAM154に保存する。 The image processing unit 152 can also generate information regarding subject brightness and the like for use in automatic exposure control (AE). Information about the specific subject area is supplied from the subject recognition unit 161 to the image processing unit 152, and used for white balance adjustment processing, for example. Note that when performing AF by the contrast detection method, the image processing unit 152 can also generate an AF evaluation value. The image processing unit 152 stores the processed image signal in the RAM 154 .

主制御部151は、RAM154に一時的に保存された画像信号に所定のヘッダを追加することで、所定の記録形式のデータファイルを生成する。この時、画像圧縮解凍部153は、主制御部151からの指示に基づき、当該データファイルを符号化し、画像信号に関する情報量を圧縮してもよい。そして、主制御部151は、生成されたデータファイルを、例えば、メモリカードのような記録媒体157に記録する。 The main control unit 151 adds a predetermined header to the image signal temporarily stored in the RAM 154 to generate a data file in a predetermined recording format. At this time, the image compression/decompression unit 153 may encode the data file based on an instruction from the main control unit 151 to compress the amount of information regarding the image signal. The main controller 151 then records the generated data file in a recording medium 157 such as a memory card.

また、RAM154に保存された画像信号を表示する場合、主制御部151は、モニタディスプレイなどの表示部150の表示サイズに適合するように、画像処理部152に対して画像信号のスケーリング処理を指示する。この後、主制御部151は、スケーリング処理された画像信号を、表示画像データとしてRAM154のビデオメモリ領域(VRAM領域)に書き込む。表示部150は、RAM154のVRAM領域から表示画像データを読み出し、例えば、LCD、有機ELディスプレイなどの表示装置に表示する。 When displaying the image signal stored in the RAM 154, the main control unit 151 instructs the image processing unit 152 to perform scaling processing of the image signal so as to fit the display size of the display unit 150 such as a monitor display. do. Thereafter, the main control unit 151 writes the scaled image signal to the video memory area (VRAM area) of the RAM 154 as display image data. The display unit 150 reads display image data from the VRAM area of the RAM 154 and displays it on a display device such as an LCD or an organic EL display.

本実施形態の撮像装置100は、動画撮影時(撮影スタンバイ状態、又は動画記録中)において、撮影された動画を表示部150に即時表示することで、表示部150を電子ビューファインダー(EVF)として機能させる。表示部150をEVFとして機能させる際に表示される動画像及びそのフレーム画像は、ライブビュー画像、又はスルー画像と呼ばれる。また、撮像装置100は、静止画撮影を行った場合にユーザが撮影結果を確認できるように、撮影した静止画を表示部150に一定時間表示する。これらの表示動作についても、主制御部151の制御によって実現される。 The imaging apparatus 100 of the present embodiment immediately displays the captured moving image on the display unit 150 during moving image recording (shooting standby state or during moving image recording), thereby using the display unit 150 as an electronic viewfinder (EVF). make it work. A moving image and its frame images displayed when the display unit 150 functions as an EVF are called live view images or through images. In addition, the imaging device 100 displays the captured still image on the display unit 150 for a certain period of time so that the user can confirm the captured result when the still image is captured. These display operations are also realized under the control of the main control unit 151 .

操作部156は、ユーザが撮像装置100に指示を入力するためのスイッチ、ボタン、キー、タッチパネルなどを備える。操作部156による入力は、バス160を経由して、主制御部151に転送される。主制御部151は、操作部156による入力に応じた動作を実現するために各部を制御する。 The operation unit 156 includes switches, buttons, keys, a touch panel, and the like for the user to input instructions to the imaging device 100 . Input from the operation unit 156 is transferred to the main control unit 151 via the bus 160 . The main control unit 151 controls each unit in order to realize the operation according to the input by the operation unit 156 .

主制御部151は、CPU、MPUなどのプログラマブルプロセッサを1つ以上有する。主制御部151は、フラッシュメモリなどの記憶部155に記憶されたプログラムをRAM154に読み出し、かつ当該プログラムを実行することで、各部を制御し、撮像装置100の各機能又は各処理を実現する。また、主制御部151は、被写体輝度の情報に基づき、露出条件(シャッタースピード、蓄積時間、絞り値、感度など)を自動的に決定するAE処理を実行する。被写体輝度の情報は、例えば、画像処理部152から取得できる。主制御部151は、人物の顔などの被写体領域を基準として露出条件を決定することもできる。 The main control unit 151 has one or more programmable processors such as CPU and MPU. The main control unit 151 reads a program stored in a storage unit 155 such as a flash memory to a RAM 154 and executes the program to control each unit and realize each function or each process of the imaging device 100 . Further, the main control unit 151 executes AE processing for automatically determining exposure conditions (shutter speed, accumulation time, aperture value, sensitivity, etc.) based on subject brightness information. Information on subject brightness can be obtained from the image processing unit 152, for example. The main control unit 151 can also determine exposure conditions based on a subject area such as a person's face.

主制御部151は、動画撮影時において、例えば、絞りを固定とし、電子シャッタスピード(蓄積時間)及びゲインの大きさを決定する。主制御部151は、この決定された露出条件(蓄積時間及びゲインの大きさ)を撮像制御部143に通知する。撮像制御部143は、主制御部151から通知された露出条件に従った撮影が行われるように、撮像素子141の動作を制御する。 The main control unit 151 fixes the aperture, for example, and determines the electronic shutter speed (accumulation time) and the magnitude of the gain during moving image shooting. The main control unit 151 notifies the imaging control unit 143 of the determined exposure conditions (accumulation time and gain magnitude). The imaging control unit 143 controls the operation of the imaging element 141 so that shooting is performed according to the exposure conditions notified from the main control unit 151 .

被写体認識部161の結果は、例えば、焦点検出領域の自動設定に用いることができる。この場合、特定の被写体領域に対する追尾AF機能を実現できる。また、焦点検出領域の輝度情報に基づきAE処理を行ったり、焦点検出領域の画素値に基づき画像処理(例えば、ガンマ補正処理、ホワイトバランス調整処理など)を行ったりすることもできる。尚、主制御部151は、現在の被写体領域の位置を表す指標(例えば、当該被写体領域を囲む矩形枠)を表示画像に重畳表示させてもよい。 The result of the subject recognition unit 161 can be used, for example, for automatic setting of the focus detection area. In this case, a tracking AF function for a specific subject area can be realized. It is also possible to perform AE processing based on the luminance information of the focus detection area, and to perform image processing (eg, gamma correction processing, white balance adjustment processing, etc.) based on the pixel values of the focus detection area. Note that the main control unit 151 may superimpose an index representing the current position of the subject area (for example, a rectangular frame surrounding the subject area) on the display image.

バッテリ159は、電源管理部158により管理され、撮像装置100の全体に電源を供給する。記憶部155は、主制御部151が実行するプログラム、プログラムの実行に必要な設定値、GUIデータ、ユーザ設定値などを記憶する。例えば、操作部156の操作により電源オフ状態から電源オン状態への移行が指示されると、記憶部155に記憶されたプログラムがRAM154に読み込まれ、かつ主制御部151が当該プログラムを実行する。 The battery 159 is managed by the power management unit 158 and supplies power to the entire imaging apparatus 100 . The storage unit 155 stores programs to be executed by the main control unit 151, setting values necessary for executing the programs, GUI data, user setting values, and the like. For example, when the operation unit 156 is operated to instruct the transition from the power-off state to the power-on state, the program stored in the storage unit 155 is read into the RAM 154, and the main control unit 151 executes the program.

<被写体認識部>
図2は、被写体認識部の構成例を示す。
被写体認識部161は、被写体検出部201と、特徴量領域登録部202と、背景の動き量取得部203と、特徴量領域更新部204と、被写体追尾部205と、を備える。
<Subject Recognition Unit>
FIG. 2 shows a configuration example of a subject recognition unit.
The subject recognition unit 161 includes a subject detection unit 201 , a feature amount region registration unit 202 , a background motion amount acquisition unit 203 , a feature amount region update unit 204 , and a subject tracking unit 205 .

被写体検出部201は、撮像素子141により取得され、かつ画像処理部152で処理された画像に基づき、被写体(追尾対象)の位置及びサイズを検出する。例えば、被写体検出部201は、画像処理部152から時系列で画像(フレーム)を取得し、各画像に含まれる追尾対象としての被写体を検出する。また、被写体検出部201は、被写体の位置及びサイズから、各画像内において被写体が占める領域、即ち、被写体領域を求めると共に、当該被写体領域の信頼性に関する情報を生成する。 The subject detection unit 201 detects the position and size of the subject (tracking target) based on the image acquired by the imaging device 141 and processed by the image processing unit 152 . For example, the subject detection unit 201 acquires images (frames) in time series from the image processing unit 152 and detects a subject as a tracking target included in each image. Further, the subject detection unit 201 obtains the area occupied by the subject in each image, that is, the subject area, based on the position and size of the subject, and generates information regarding the reliability of the subject area.

特徴量領域登録部202は、被写体検出部201によって検出された被写体領域に基づき被写体を含む特徴量領域を決定し、かつ当該特徴量領域を登録する。ここで、特徴量領域とは、追尾対象としての被写体を追尾するに当たって、nフレーム(第1の画像)で設定される被写体を含む画像領域のことである。但し、nは、自然数(1、2、3、…)であり、nが大きくなるほど、時間が後であることを意味する。そして、被写体の追尾は、後述するように、nフレームよりも後のフレーム、例えば、(n+1)フレーム(第2の画像)において、特徴量領域に対応する画像領域を探索することにより行う。 A feature amount area registration unit 202 determines a feature amount area including a subject based on the subject area detected by the subject detection unit 201, and registers the feature amount area. Here, the feature amount area is an image area including the subject set in the n frame (first image) when tracking the subject as the tracking target. However, n is a natural number (1, 2, 3, . . . ), and the larger n means the later time. Tracking of the subject is performed by searching for an image area corresponding to the feature amount area in a frame after the n frame, for example, the (n+1) frame (second image), as will be described later.

特徴量領域登録部202は、被写体検出部201によって第1の画像から検出された被写体領域に基づき特徴量領域を登録する場合、当該特徴領域のサイズをデフォルト値(初期値)に設定する。デフォルト値は、予め決定されている。但し、デフォルト値は、ユーザが操作部156などを介して自由に変更できるように構成してもよいし、又はプログラムが自動的に最適値を設定できるように構成してもよい。 When registering a feature region based on the subject region detected from the first image by the subject detection unit 201, the feature region registration unit 202 sets the size of the feature region to a default value (initial value). Default values are predetermined. However, the default value may be configured so that the user can freely change it via the operation unit 156 or the like, or it may be configured so that the program can automatically set the optimum value.

尚、後述する被写体追尾部205が特徴量領域に対応する画像領域を見つけ出して、追尾が成功となる場合には、特徴量領域登録部202は、既に登録されている特徴量領域に代えて、当該画像領域を新たな特徴量領域として登録する。一方、後述する被写体追尾部205が特徴量領域に対応する画像領域を見つけ出せず、追尾が不成功となる場合には、特徴量領域登録部202は、既に登録されている特徴量領域を引き続き登録する。 When the subject tracking unit 205, which will be described later, finds an image area corresponding to the feature amount area and the tracking is successful, the feature amount area registration unit 202 replaces the already registered feature amount area with The image area is registered as a new feature amount area. On the other hand, when the subject tracking unit 205, which will be described later, cannot find an image area corresponding to the feature amount region and the tracking is unsuccessful, the feature amount area registration unit 202 continues to register the already registered feature amount area. do.

背景の動き量取得部203は、時系列で逐次供給される複数の画像に基づき、背景の動き量を取得する。背景の動き量取得部203は、例えば、当該複数の画像から背景を推定し、かつ推定された背景に基づき、複数の画像間の動きベクトルを検出する。これにより、背景の動き量取得部203は、当該動きベクトルに基づき、背景の動き量を取得できる。 The background motion amount acquisition unit 203 acquires the background motion amount based on a plurality of images sequentially supplied in time series. The background motion amount acquisition unit 203, for example, estimates the background from the plurality of images, and detects a motion vector between the plurality of images based on the estimated background. Accordingly, the background motion amount acquisition unit 203 can acquire the background motion amount based on the motion vector.

また、背景の動き量取得部203は、ジャイロセンサ及び加速度センサのうちの少なくとも1つを用いて撮像装置100の動きを検出し、かつ撮像装置100の動きに基づき、背景の動き量を取得することもできる。尚、背景の動き量取得部203の動作の詳細については、後述する。 In addition, the background motion amount acquisition unit 203 detects the motion of the imaging device 100 using at least one of a gyro sensor and an acceleration sensor, and acquires the background motion amount based on the motion of the imaging device 100. can also Details of the operation of the background motion amount acquisition unit 203 will be described later.

特徴量領域更新部204は、時系列で逐次供給される複数の画像に係る情報に基づき、特徴量領域登録部202に登録された特徴量領域のサイズの更新を行う。例えば、特徴量領域更新部204は、背景の動き量取得部203によって取得された背景の動き量と、後述する被写体追尾部205によって取得された被写体の動き量とに基づき、被写体と背景との位置関係の変化量を取得する。そして、特徴量領域更新部204は、当該変化量に基づき、特徴量領域登録部202に登録された特徴量領域のサイズの更新を行う。 The feature region update unit 204 updates the size of the feature region registered in the feature region registration unit 202 based on the information on the plurality of images that are sequentially supplied in time series. For example, the feature amount region updating unit 204 determines the difference between the subject and the background based on the amount of background motion acquired by the background motion amount acquiring unit 203 and the amount of motion of the subject acquired by the subject tracking unit 205, which will be described later. Get the amount of change in the positional relationship. Then, the feature region update unit 204 updates the size of the feature region registered in the feature region registration unit 202 based on the amount of change.

ここで、特徴量領域登録部202が最初に登録する特徴量領域のサイズ(デフォルト値)は、過去に最も多く発生した被写体と背景との位置関係の変化量を基準値Δrefとした場合に、当該基準値Δrefに対応するサイズとするのが望ましい。基準値Δrefとデフォルト値との関係については、後述する。 Here, the size (default value) of the feature amount region that is first registered by the feature amount region registration unit 202 is given by: It is desirable to set the size to correspond to the reference value Δref. A relationship between the reference value Δref and the default value will be described later.

そして、特徴量領域更新部204は、被写体と背景との変化量が基準値Δrefよりも大きい場合に、特徴量領域のサイズをデフォルト値よりも小さくする。また、特徴量領域更新部204は、当該変化量が基準値Δrefよりも小さい場合に、特徴量領域のサイズをデフォルト値よりも大きくする。さらに、特徴量領域更新部204は、当該変化量が大きくなるに従い特徴量領域のサイズを小さくし、かつ当該変化量が小さくなるに従い特徴量領域のサイズを大きくする。但し、特徴量領域更新部204は、当該変化量が閾値よりも大きい場合には、特徴量領域のサイズを一定とする。 Then, when the amount of change between the subject and the background is larger than the reference value Δref, the feature region updating unit 204 makes the size of the feature region smaller than the default value. Also, when the amount of change is smaller than the reference value Δref, the feature quantity region updating unit 204 makes the size of the feature quantity region larger than the default value. Further, the feature quantity region update unit 204 reduces the size of the feature quantity region as the change amount increases, and increases the size of the feature quantity region as the change quantity decreases. However, when the amount of change is larger than the threshold, the feature amount region updating unit 204 keeps the size of the feature amount region constant.

被写体追尾部205は、時系列で逐次供給される複数の画像から、特徴量領域更新部204で更新された特徴量領域に対応する画像領域の探索を行うことで、被写体の追尾を行う。例えば、被写体追尾部205は、特徴量領域更新部204でサイズが更新された特徴量領域と類似度が最も高い画像領域を当該特徴量領域に対応する画像領域とし、当該画像領域に基づき被写体の追尾を行う。 The subject tracking unit 205 searches for an image area corresponding to the feature amount area updated by the feature amount area updating unit 204 from a plurality of images sequentially supplied in time series, thereby tracking the subject. For example, the subject tracking unit 205 sets the image area having the highest similarity to the feature amount area whose size is updated by the feature amount area updating unit 204 as the image area corresponding to the feature amount area, and determines the subject based on the image area. track.

ここで、類似度は、例えば、所定の関数で規定される評価値により判断し、被写体追尾部205は、当該評価値が最も低い領域を類似度が最も高い領域として決定する。また、被写体追尾部205は、評価値の最小値が閾値よりも大きい場合には、特徴量領域に対応する画像領域が見つけ出せなかったと結論付けることもできる。尚、探索結果は、画像内における被写体領域、信頼性、被写体の動き量などの情報を備え、主制御部151での各種処理に利用される。 Here, the degree of similarity is determined, for example, by an evaluation value defined by a predetermined function, and the subject tracking unit 205 determines the region with the lowest evaluation value as the region with the highest degree of similarity. Also, the subject tracking unit 205 can conclude that the image area corresponding to the feature amount area could not be found when the minimum value of the evaluation values is larger than the threshold. The search result includes information such as the object area in the image, reliability, amount of movement of the object, etc., and is used for various processes in the main control unit 151 .

<撮像装置の動作例>
図3は、撮像装置の動作例を示す。
本実施形態では、被写体検出処理、被写体追尾処理、並びに、被写体及び背景の動き量を検出する動き量検出処理を伴う動画撮影動作に関して説明する。動画撮影動作は、撮影スタンバイ時又は動画記録時に実行される。
<Example of operation of imaging device>
FIG. 3 shows an operation example of the imaging device.
In the present embodiment, a moving image shooting operation involving subject detection processing, subject tracking processing, and motion amount detection processing for detecting the amount of motion of the subject and background will be described. The motion picture shooting operation is executed during shooting standby or during motion picture recording.

尚、撮影スタンバイ時と動画記録時とでは、取り扱う画像(フレーム)の解像度など、細部において異なるが、被写体検出処理、被写体追尾処理、並びに、被写体及び背景の動き量を検出する動き量検出処理に係る内容は、基本的に同じである。従って、以下では、特に、撮影スタンバイ時と動画記録時とを区別することなく、説明する。 Details such as the resolution of images (frames) to be handled differ between shooting standby and video recording, but subject detection processing, subject tracking processing, and motion amount detection processing for detecting the amount of motion of the subject and background are performed. The content concerned is basically the same. Therefore, the following description will be made without particularly distinguishing between shooting standby and moving image recording.

まず、S301において、主制御部151は、撮像装置100の電源スイッチがオンであるか否かを判定する。電源スイッチがオフであれば、本フローを終了し、電源スイッチがオンであれば、本フローをS302に進める。 First, in S301, the main control unit 151 determines whether the power switch of the imaging device 100 is on. If the power switch is off, this flow ends, and if the power switch is on, this flow advances to S302.

次に、S302において、主制御部151は、各部を制御して、1フレーム分の撮像処理を実行した後、本フローをS303に進める。本実施形態では、撮像処理として、1対の視差画像と、1画面分の撮像画像とを取得し、これらをRAM154に保存する。また、S303において、主制御部151は、被写体認識処理を実行するように、被写体認識部161に指示を出す。ここで、被写体認識処理は、被写体検出処理、被写体追尾処理、並びに、被写体及び背景の動き量を検出する動き量検出処理を含む。被写体認識部161での被写体認識処理の詳細については、後述する。 Next, in S302, the main control unit 151 controls each unit to execute imaging processing for one frame, and then advances the flow to S303. In the present embodiment, as the imaging process, a pair of parallax images and a captured image for one screen are acquired and stored in the RAM 154 . In S303, the main control unit 151 instructs the subject recognition unit 161 to perform subject recognition processing. Here, the subject recognition processing includes subject detection processing, subject tracking processing, and motion amount detection processing for detecting the amount of motion of the subject and background. Details of the subject recognition processing in the subject recognition unit 161 will be described later.

この後、被写体領域の位置、サイズ、及び動き量が被写体認識部161から主制御部151に通知され、かつRAM154に保存される。主制御部151は、通知された被写体領域に基づき、焦点検出領域を設定する。 Thereafter, the position, size, and motion amount of the subject area are notified from the subject recognition section 161 to the main control section 151 and stored in the RAM 154 . The main control unit 151 sets the focus detection area based on the notified object area.

次に、S304において、主制御部151は、フォーカス制御部133に焦点検出処理を実行させる。フォーカス制御部133は、1対の視差画像の焦点検出領域に含まれる複数の画素のうち、同一行に配置された複数の画素から得られる複数のA信号を繋ぎ合わせてA像を生成し、かつ複数のB信号を繋ぎ合わせてB像を生成する。そして、フォーカス制御部133は、A像とB像との相対的な位置をずらしながらA像とB像の相関量を演算し、A像とB像との類似度が最も高くなる相対位置をA像とB像との位相差(ずれ量)として求める。さらに、フォーカス制御部133は、当該位相差をデフォーカス量及びデフォーカス方向に変換する。 Next, in S304, the main control unit 151 causes the focus control unit 133 to execute focus detection processing. The focus control unit 133 connects a plurality of A signals obtained from a plurality of pixels arranged in the same row among a plurality of pixels included in the focus detection areas of the pair of parallax images to generate an A image, In addition, a plurality of B signals are spliced together to generate a B image. Then, the focus control unit 133 calculates the amount of correlation between the A image and the B image while shifting the relative positions of the A image and the B image, and determines the relative position where the similarity between the A image and the B image is the highest. It is obtained as a phase difference (shift amount) between the A image and the B image. Furthermore, the focus control unit 133 converts the phase difference into a defocus amount and a defocus direction.

次に、S305において、フォーカス制御部133は、S304で求めたデフォーカス量及びデフォーカス方向に対応するレンズ駆動量及び駆動方向に従ってフォーカスモータ132を駆動し、フォーカスレンズ131を移動させる。また、レンズ駆動処理が終了すると、主制御部151は、本フローをS301に戻す。 Next, in S305, the focus control unit 133 drives the focus motor 132 and moves the focus lens 131 according to the lens drive amount and drive direction corresponding to the defocus amount and defocus direction obtained in S304. Also, when the lens driving process ends, the main control unit 151 returns the flow to S301.

以後、S301で電源スイッチがオフと判定されるまで、S302~S305の処理が繰り返し実行される。これにより、時系列で逐次供給される複数の画像(フレーム)に対して追尾対象としての被写体の探索が行われ、被写体追尾機能が実現される。尚、図3では被写体追尾処理を逐次供給されるフレーム毎に実行するが、主制御部151の処理負荷及び消費電力の軽減を目的として、被写体追尾処理を数フレーム毎に行ってもよい。 Thereafter, the processes of S302 to S305 are repeatedly executed until it is determined in S301 that the power switch is turned off. As a result, a subject as a tracking target is searched for a plurality of images (frames) sequentially supplied in time series, and a subject tracking function is realized. In FIG. 3, the subject tracking process is performed for each frame that is sequentially supplied, but the subject tracking process may be performed every several frames for the purpose of reducing the processing load and power consumption of the main control unit 151 .

<被写体認識処理>
図4は、被写体認識処理の例を示す。
このフローチャートは、図3のS303のサブルーチンである。
<Subject recognition processing>
FIG. 4 shows an example of subject recognition processing.
This flowchart is a subroutine of S303 in FIG.

まず、S401において、被写体認識部161は、撮像制御部143から画像(フレーム)を取得する。この後、S402において、被写体検出部201は、撮像制御部143からの画像に対して、中心位置及びサイズが異なる複数の評価領域を設定し、かつ各評価領域から被写体を検出する。被写体を検出する処理の詳細については、後述する。 First, in S<b>401 , the subject recognition unit 161 acquires an image (frame) from the imaging control unit 143 . After that, in S402, the subject detection unit 201 sets a plurality of evaluation areas with different center positions and sizes for the image from the imaging control unit 143, and detects subjects from each evaluation area. Details of the processing for detecting the subject will be described later.

次に、S403において、特徴量領域登録部202は、被写体検出部201によって検出された被写体領域、又は被写体追尾部206によって検出された前フレームの特徴量領域に対応する画像領域に基づき、特徴量領域を登録する。本実施形態では、特徴量領域の登録は、最初の1フレームでは、被写体検出部201の結果に基づき行われ、それ以降のフレームでは、被写体追尾部206の結果に基づき行われる。 Next, in step S<b>403 , the feature amount region registration unit 202 registers the feature amount based on the subject area detected by the subject detection unit 201 or the image area corresponding to the feature amount area of the previous frame detected by the subject tracking unit 206 . Register a region. In this embodiment, registration of feature amount regions is performed based on the results of the subject detection unit 201 for the first frame, and based on the results of the subject tracking unit 206 for subsequent frames.

次に、S404において、背景の動き量取得部203は、時系列で逐次供給される複数の画像に基づき、背景の動き量を取得する。背景の動き量を取得する処理の詳細については、後述する。この後、S405において、特徴量領域更新部204は、S404によって取得された背景の動き量と、後述するS406によって取得される前フレームの被写体の動き量とに基づき、特徴量領域のサイズの更新を行う。特徴量領域のサイズを更新する処理の詳細については、後述する。 Next, in S404, the background motion amount acquisition unit 203 acquires the background motion amount based on the plurality of images sequentially supplied in time series. The details of the process of acquiring the motion amount of the background will be described later. After that, in S405, the feature amount region updating unit 204 updates the size of the feature amount region based on the amount of motion of the background acquired in S404 and the amount of motion of the subject in the previous frame acquired in S406, which will be described later. I do. Details of the processing for updating the size of the feature amount region will be described later.

次に、S406において、被写体追尾部205は、時系列で逐次供給される複数の画像から、S405で更新された特徴量領域に対応する画像領域を探索する。例えば、被写体追尾部205は、当該特徴量領域と類似度が最も高い領域を当該特徴量領域に対応する画像領域とし、当該画像領域に基づき被写体の追尾を行う。被写体を追尾する処理の詳細については、後述する。 Next, in S406, the subject tracking unit 205 searches for an image area corresponding to the feature amount area updated in S405 from a plurality of images sequentially supplied in time series. For example, the subject tracking unit 205 sets an area having the highest degree of similarity to the feature amount area as an image area corresponding to the feature amount area, and tracks the subject based on the image area. The details of the subject tracking process will be described later.

<被写体検出処理>
図5は、被写体検出処理の例を示す。
このフローチャートは、図4のS402のサブルーチンである。
<Subject detection processing>
FIG. 5 shows an example of subject detection processing.
This flowchart is a subroutine of S402 in FIG.

まず、S501において、被写体検出部201は、画像の評価を行う評価領域を決定する。例えば、図6において、601は、入力画像であり、602は、評価画素であり、603は、評価領域候補である。図6(A)、図6(B)、及び図6(C)に示すように、各評価領域候補603は、互いに異なるサイズに設定される。評価画素602は、入力画像601の全画素からラスタ処理で順次選択される。 First, in S501, the subject detection unit 201 determines an evaluation region for image evaluation. For example, in FIG. 6, 601 is an input image, 602 is an evaluation pixel, and 603 is an evaluation area candidate. As shown in FIGS. 6A, 6B, and 6C, each evaluation area candidate 603 is set to have a different size. Evaluation pixels 602 are sequentially selected from all pixels of the input image 601 by raster processing.

次に、S502において、被写体検出部201は、評価領域に対する外側評価領域を決定する。例えば、図7において、701は、入力画像であり、702は、評価画素であり、703は、評価領域であり、704は、外側評価領域である。図7に示すように、外側評価領域704の中心位置は、評価領域703の中心位置と同一である。また、外側評価領域704の中心位置から外枠までのサイズは、評価領域703の中心位置から外枠までのサイズよりも大きい。即ち、外側評価領域704は、評価領域703に対応する領域を除いたリング状の領域である。尚、外側評価領域704の中心位置から外枠までのサイズと、評価領域703の中心位置から外枠までのサイズとの差は、入力画像701のサイズに基づき決定し、例えば、入力画像701の水平サイズの10%とする。 Next, in S502, the subject detection unit 201 determines an outer evaluation area for the evaluation area. For example, in FIG. 7, 701 is an input image, 702 is an evaluation pixel, 703 is an evaluation area, and 704 is an outer evaluation area. As shown in FIG. 7, the center position of the outer evaluation area 704 is the same as the center position of the evaluation area 703 . Also, the size from the center position of the outer evaluation area 704 to the outer frame is larger than the size from the center position of the evaluation area 703 to the outer frame. That is, the outer evaluation area 704 is a ring-shaped area excluding the area corresponding to the evaluation area 703 . Note that the difference between the size from the center position to the outer frame of the outer evaluation region 704 and the size from the center position to the outer frame of the evaluation region 703 is determined based on the size of the input image 701. 10% of horizontal size.

次に、S503において、被写体検出部201は、評価領域と外側評価領域に対応する画像信号の相違度を評価値として算出する。 Next, in S503, the subject detection unit 201 calculates the degree of difference between the image signals corresponding to the evaluation area and the outer evaluation area as an evaluation value.

評価値Dは、以下の式により算出される。

Figure 0007278737000001
The evaluation value D is calculated by the following formula.
Figure 0007278737000001

但し、dは、評価領域及び外側評価領域の色相情報から算出された相違度であり、pHiは、評価領域の色相情報がiである画素の数を表し、qHiは、外側評価領域のうち、色相情報がiである画素の数を表す。d、pSi、qSiは、それぞれ、彩度情報に関する値であり、d、pVi、qViは、輝度情報に関する値である。また、mは、色相情報、彩度情報、輝度情報が取り得る最大値である。 However, d H is the difference calculated from the hue information of the evaluation area and the outer evaluation area, p Hi represents the number of pixels whose hue information is i in the evaluation area, and q Hi is the outer evaluation area. represents the number of pixels whose hue information is i. d S , p Si , q Si are values related to saturation information, and d V , p Vi , q Vi are values related to luminance information. Also, m is the maximum value that hue information, saturation information, and luminance information can take.

次に、S504において、被写体検出部201は、未処理の評価領域があるか否か判定を行う。未処理の評価領域があれば、被写体検出部201は、本フローをS501に戻し、一連の処理を繰り返す。また、未処理の評価領域がなければ、被写体検出部201は、本フローをS505に進める。 Next, in S504, the subject detection unit 201 determines whether or not there is an unprocessed evaluation area. If there is an unprocessed evaluation area, the subject detection unit 201 returns the flow to S501 and repeats a series of processes. If there is no unprocessed evaluation area, the subject detection unit 201 advances the flow to S505.

次に、S505において、被写体検出部201は、被写体を決定する。即ち、被写体検出部201は、S503において算出した評価値のうち、最も高い評価値を有する領域を被写体として決定する。
尚、ここで説明した方法は、一例であり、被写体は、図5のフロー以外の方法により決定することも可能である。例えば、図5のフローにおいて、画像の奥行情報を加味して被写体を決定することも可能である。
Next, in S505, the subject detection unit 201 determines a subject. That is, the subject detection unit 201 determines the area having the highest evaluation value among the evaluation values calculated in S503 as the subject.
It should be noted that the method described here is just an example, and the subject can also be determined by a method other than the flow in FIG. For example, in the flow of FIG. 5, it is also possible to determine the subject in consideration of the depth information of the image.

<背景の動き量の取得処理>
図8は、背景動き量の取得処理の例を示す。
このフローチャートは、図4のS404のサブルーチンである。
<Acquisition processing of background motion amount>
FIG. 8 shows an example of background motion amount acquisition processing.
This flowchart is a subroutine of S404 in FIG.

図8(A)は、推定された背景から、背景の動き量を取得する例である。
まず、S8011において、背景の動き量取得部202は、S401で逐次取得される複数の画像に基づいて、背景の推定を行う。例えば、背景の動き量取得部202は、S402の被写体検出処理により被写体が検出された場合に、当該被写体以外の画像領域を背景と推定することができる。
FIG. 8A is an example of obtaining the background motion amount from the estimated background.
First, in S8011, the background motion amount acquisition unit 202 estimates the background based on a plurality of images sequentially acquired in S401. For example, when a subject is detected by the subject detection processing in S402, the background motion amount acquisition unit 202 can estimate an image area other than the subject to be the background.

次に、S8012において、背景の動き量取得部202は、S401で逐次取得される複数の画像のうち、現フレームに係る画像と、それよりも1フレーム前のフレームに係る画像とを使用し、推定された背景(画像)から背景の動きベクトルを算出する。 Next, in S8012, the background motion amount acquisition unit 202 uses, of the plurality of images sequentially acquired in S401, the image related to the current frame and the image related to the previous frame, A background motion vector is calculated from the estimated background (image).

最後に、S8013において、背景の動き量取得部202は、背景の動きベクトルに基づき、背景の動き量を取得する。 Finally, in S8013, the background motion amount acquisition unit 202 acquires the background motion amount based on the background motion vector.

図8(B)は、特徴点マッチングにより複数の動きベクトルを算出し、これらから背景の動きベクトルを選択することで、背景の動き量を取得する例である。
まず、S8021において、背景の動き量取得部202は、S401で取得される画像内に複数の特徴点を均一に分布させ、これら均一に分布させた複数の特徴点から、特徴点毎に動きベクトルを算出する。
FIG. 8B is an example of obtaining the motion amount of the background by calculating a plurality of motion vectors by feature point matching and selecting the motion vector of the background from them.
First, in S8021, the background motion amount acquisition unit 202 uniformly distributes a plurality of feature points in the image acquired in S401, and calculates a motion vector for each feature point from the plurality of uniformly distributed feature points. Calculate

次に、S8022において、背景の動き量取得部202は、算出された複数の動きベクトルから背景の動きベクトルを選択する。背景の動きベクトルを選択する方法は、公知の手法を用いることができる。例えば、背景の動き量取得部202は、S8021で算出された複数の動きベクトルをヒストグラム化し、最大個数のビンに係る動きベクトルを背景の動きベクトルとして決定する。 Next, in S8022, the background motion amount acquisition unit 202 selects a background motion vector from the plurality of calculated motion vectors. A known technique can be used as a method for selecting the motion vector of the background. For example, the background motion amount acquisition unit 202 histograms the plurality of motion vectors calculated in S8021, and determines the motion vector associated with the maximum number of bins as the background motion vector.

最後に、S8023において、背景の動き量取得部202は、背景の動きベクトルに基づき、背景の動き量を取得する。 Finally, in S8023, the background motion amount acquisition unit 202 acquires the background motion amount based on the background motion vector.

尚、背景の動きベクトルを算出するに当たり、現フレームに係る画像の1フレーム前のフレームに係る画像から当該動きベクトルの始点を検出し、かつ現フレームに係る画像から当該動きベクトルの終点を検出するのが望ましい。但し、背景の動きベクトルから取得される背景の動き量の時間に対する方向が、後述する被写体の動き量の時間に対する方向と同じであれば、当該動きベクトルの始点と終点を逆にしてもよい。 In calculating the motion vector of the background, the start point of the motion vector is detected from the image of the frame one frame before the image of the current frame, and the end point of the motion vector is detected from the image of the current frame. is desirable. However, if the direction with respect to time of the amount of motion of the background obtained from the motion vector of the background is the same as the direction with respect to time of the amount of motion of the subject, which will be described later, the start point and end point of the motion vector may be reversed.

また、本実施形態では、背景の動き量を取得するに当たり、画像から算出される動きベクトルを使用したが、これに代えて、ジャイロセンサ、加速度センサなどで撮像装置の動きを検出し、当該撮像装置の動きに基づき背景の動き量を決定してもよい。 In this embodiment, a motion vector calculated from an image is used to acquire the amount of motion of the background. The amount of background motion may be determined based on the motion of the device.

<特徴量領域の更新処理>
図9は、特徴量領域の更新処理の例を示す。
このフローチャートは、図4のS405のサブルーチンである。
<Update Processing of Feature Amount Region>
FIG. 9 shows an example of update processing of feature amount regions.
This flowchart is a subroutine of S405 in FIG.

まず、S901において、特徴量領域更新部204は、S8013又はS8023で取得した背景の動き量と、被写体の動き量との差を算出する。この差は、被写体と背景との位置関係の変化量に相当する。ここで、被写体の動き量は、被写体追尾部205が現フレームよりも前のフレームに係る画像から既に取得済みであり、例えば、RAM154に記憶されている。 First, in S901, the feature amount region updating unit 204 calculates the difference between the background motion amount acquired in S8013 or S8023 and the subject motion amount. This difference corresponds to the amount of change in the positional relationship between the subject and the background. Here, the subject tracking unit 205 has already acquired the motion amount of the subject from the image related to the frame before the current frame, and is stored in the RAM 154, for example.

被写体の動き量と背景の動き量との差に関しては、特徴量領域更新部204は、画像の水平方向での差の絶対値と、画像の垂直方向での差の絶対値とを算出し、それらの一方、又はそれらを足し合わせた値を、被写体の動き量と背景の動き量との差とする。例えば、特徴量領域更新部204は、水平方向における差の絶対値、及び垂直方向における差の絶対値うち、大きな値を有するほうを、被写体の動き量と背景の動き量との差として決定する。 Regarding the difference between the amount of motion of the subject and the amount of motion of the background, the feature amount region updating unit 204 calculates the absolute value of the difference in the horizontal direction of the image and the absolute value of the difference in the vertical direction of the image, One of them or a value obtained by adding them is taken as the difference between the amount of motion of the subject and the amount of motion of the background. For example, the feature amount region updating unit 204 determines the absolute value of the difference in the horizontal direction and the absolute value of the difference in the vertical direction, whichever has the larger value, as the difference between the amount of motion of the subject and the amount of motion of the background.

次に、S902において、特徴量領域更新部204は、被写体の動き量と背景の動き量との差に基づき、特徴量領域登録部202に登録された特徴量領域のサイズの更新を行い、本フローを終了する。 Next, in S902, the feature amount region updating unit 204 updates the size of the feature amount region registered in the feature amount region registration unit 202 based on the difference between the amount of movement of the subject and the amount of movement of the background. End the flow.

ここで、S902において、特徴量領域のサイズの更新を行う場合、特徴量領域更新部204は、被写体の動き量と背景の動き量との差、即ち、被写体と背景との位置関係の変化量が大きくなるに従い、特徴量領域のサイズを小さくする。また、特徴量領域更新部204は、被写体の動き量と背景の動き量との差が小さくなるに従い、特徴量領域のサイズを大きくする。 Here, when updating the size of the feature region in S902, the feature region updating unit 204 calculates the difference between the amount of motion of the subject and the amount of motion of the background, that is, the amount of change in the positional relationship between the subject and the background. increases, the size of the feature amount region is reduced. Further, the feature amount region update unit 204 increases the size of the feature amount region as the difference between the amount of movement of the subject and the amount of movement of the background becomes smaller.

図10は、特徴量領域のサイズと、被写体と背景との動き量の差との関係を示す。
デフォルト値(初期値)は、特徴量領域登録部202に最初に登録される特徴量領域のサイズである。デフォルト値に対応する動き量の差は、基準値Δrefである。
FIG. 10 shows the relationship between the size of the feature amount region and the difference in motion amount between the subject and the background.
The default value (initial value) is the size of the feature region registered first in the feature region registration unit 202 . The difference in motion amount corresponding to the default value is the reference value Δref.

同図によれば、動き量の差が基準値Δrefよりも大きい場合(ΔH)には、特徴量領域のサイズは、デフォルト値からそれよりも小さい値に変化する(矢印A)。また、動き量の差が基準値Δrefよりも小さい場合(ΔL)には、特徴量領域のサイズは、デフォルト値からそれよりも大きい値に変化する(矢印B)。即ち、動き量の差が大きくなるに従い、特徴量領域のサイズは、小さくなり、動き量の差が小さくなるに従い、特徴量領域のサイズは、大きくなる。但し、動き量の差が閾値Δthよりも大きい場合には、特徴量領域のサイズは、一定となる。 According to the figure, when the difference in motion amount is larger than the reference value Δref (ΔH), the size of the feature amount region changes from the default value to a smaller value (arrow A). Also, when the difference in motion amount is smaller than the reference value Δref (ΔL), the size of the feature amount region changes from the default value to a larger value (arrow B). That is, the size of the feature region decreases as the difference in motion amount increases, and the size of the feature region increases as the difference in motion amount decreases. However, when the difference in motion amount is larger than the threshold value Δth, the size of the feature amount region is constant.

図11は、特徴量領域のサイズと動き量の差との関係を模式的に示す。
同図(A)は、nフレームに係る画像であり、S403で登録された特徴量領域1101を示す。特徴量領域1101のサイズは、例えば、デフォルト値を有するものとする。同図(B)は、(n+1)フレームに係る画像であり、同図(A)の画像に対して、動き量の差が無いか、又はほとんど無い場合である。同図(D)は、(n+1)フレームに係る画像であり、同図(A)の画像に対して、動き量の差が大きい場合である。
FIG. 11 schematically shows the relationship between the size of the feature amount region and the difference in motion amount.
FIG. 8A shows an image of n frames, showing the feature amount region 1101 registered in S403. The size of the feature region 1101 is assumed to have a default value, for example. (B) in the figure is an image related to the (n+1) frame, in which there is no or almost no difference in the amount of motion with respect to the image in (A) in the figure. (D) in the figure is an image relating to the (n+1) frame, and shows a case in which the difference in motion amount is large with respect to the image in (A) in the figure.

同図(B)の場合、S405において、特徴量領域更新部204は、動き量の差が基準値Δrefよりも小さいと判断する。従って、同図(C)に示すように、特徴量領域更新部204は、特徴量領域1102のサイズを、同図(A)に示す特徴量領域1101のサイズよりも大きい値に更新する。 In the case of FIG. 4B, in S405, the feature amount region updating unit 204 determines that the difference in motion amount is smaller than the reference value Δref. Therefore, as shown in FIG. 2C, the feature amount region updating unit 204 updates the size of the feature amount region 1102 to a value larger than the size of the feature amount region 1101 shown in FIG.

この場合、特徴量領域1102は、被写体領域よりも大きくなり、被写体と背景の情報を含むことになる。即ち、(n+2)フレームに係る画像において、特徴量領域1102に対応する画像領域を探索する際に、探索に用いる情報が多くなり、追尾性能を向上させることができる。しかも、特徴量領域1102に含まれる背景情報は、変化しないか、又はほとんど変化しないため、背景情報の変化により追尾が失敗するといった事態も発生しない。 In this case, the feature amount area 1102 is larger than the subject area and contains information on the subject and the background. That is, when searching for the image region corresponding to the feature amount region 1102 in the image of the (n+2) frame, more information is used for searching, and tracking performance can be improved. Moreover, since the background information included in the feature amount region 1102 does not change or hardly changes, a situation in which tracking fails due to a change in background information does not occur.

また、同図(D)の場合、S405において、特徴量領域更新部204は、動き量の差が基準値Δrefよりも大きいと判断する。従って、同図(E)に示すように、特徴量領域更新部204は、特徴量領域1103のサイズを、同図(A)に示す特徴量領域1101のサイズよりも小さい値に更新する。 In the case of (D) in the figure, in S405, the feature amount region updating unit 204 determines that the difference in motion amount is larger than the reference value Δref. Therefore, as shown in (E) of the same figure, the feature quantity region updating unit 204 updates the size of the feature quantity region 1103 to a smaller value than the size of the feature quantity region 1101 shown in (A) of the same figure.

この場合、特徴量領域1103は、被写体領域とほぼ同じサイズとなり、背景を全く含まないか、又はほとんど含まなくなる。即ち、(n+2)フレームに係る画像において、特徴量領域1103に対応する画像領域を探索する際に、特徴量領域1103の背景情報の変化により、追尾が失敗してしまうといった事態が発生することはない。 In this case, the feature amount area 1103 has approximately the same size as the subject area, and does not include the background at all or hardly includes it. That is, when searching for an image area corresponding to the feature amount area 1103 in the image of the (n+2) frame, a situation in which tracking fails due to a change in the background information of the feature amount area 1103 does not occur. do not have.

<被写体追尾処理>
次に、図12を参照して、S405における被写体追尾処理について説明する。
被写体追尾部205は、S404で更新された特徴量領域に対応する画像領域を探索する。探索結果は、被写体追尾部205の出力情報として出力される。
<Subject Tracking Processing>
Next, the subject tracking processing in S405 will be described with reference to FIG.
The subject tracking unit 205 searches for an image area corresponding to the feature amount area updated in S404. A search result is output as output information of the subject tracking unit 205 .

図12は、テンプレートマッチングの例を示す。
特徴量領域に対応する画像領域の探索は、テンプレートマッチングにより行うことが可能である。テンプレートマッチングは、画素パターンをテンプレートとして設定し、テンプレートとの類似度が最も高い領域を画像内で探索する技術である。テンプレートと画像領域との類似度としては、対応画素間の差分絶対値和のような相関量を用いることができる。
FIG. 12 shows an example of template matching.
A search for an image region corresponding to a feature amount region can be performed by template matching. Template matching is a technique in which a pixel pattern is set as a template and an area with the highest similarity to the template is searched in the image. As the degree of similarity between the template and the image region, a correlation amount such as the sum of absolute differences between corresponding pixels can be used.

図12(A)は、テンプレート1201と、その構成例1202と、を模式的に示す。テンプレートマッチングを行う場合、テンプレート1201の画素パターンが予め設定される。本実施形態では、テンプレート1201は、水平画素数W、及び垂直画素数Hのサイズを有する。そして、テンプレートマッチングは、テンプレート1201に含まれる画素の輝度値を用いて実行される。 FIG. 12A schematically shows a template 1201 and its configuration example 1202. FIG. When performing template matching, the pixel pattern of the template 1201 is set in advance. In this embodiment, the template 1201 has a size of W pixels in the horizontal direction and H pixels in the vertical direction. Template matching is then performed using the luminance values of the pixels included in template 1201 .

テンプレート1201の特徴量T(i,j)は、図12(A)に示すような座標系を設定した場合、以下の式で表わされる。

Figure 0007278737000002
A feature amount T(i, j) of the template 1201 is expressed by the following equation when a coordinate system as shown in FIG. 12A is set.
Figure 0007278737000002

図12(B)は、探索領域1203内の画像領域1204と、その構成例1205と、を模式的に示す。探索領域1203は、被写体の追尾を行う後フレームに係る画像においてパターンマッチングを行う範囲を表す。探索領域1203は、当該画像の全体であってもよいし、又は一部であってよい。 FIG. 12B schematically shows an image area 1204 within the search area 1203 and its configuration example 1205 . A search area 1203 represents a range in which pattern matching is performed in an image related to a post-subject tracking frame. The search area 1203 may be the entire image or a portion thereof.

探索領域1203内の座標は、(x,y)で表すものとする。画像領域1204は、探索領域1203から、テンプレート1201に対して最も類似度が高い画像領域を探索するためのもので、探索領域1203内をシフトする。このため、探索領域1203のサイズは、テンプレート1201のサイズ(水平画素数W、垂直画素数H)と同じに設定する。 Coordinates within the search area 1203 are represented by (x, y). An image area 1204 is for searching an image area having the highest degree of similarity to the template 1201 from the search area 1203 and is shifted within the search area 1203 . Therefore, the size of the search area 1203 is set to be the same as the size of the template 1201 (horizontal pixel count W, vertical pixel count H).

被写体追尾部205は、画像領域1204をシフトさせる度に、画像領域1204に含まれる各画素の輝度値と、テンプレート1201に含まれる各画素の輝度値との類似度を算出する(パターンマッチング)。ここで、画像領域1204の特徴量S(i,j)は、図12(B)に示すような座標系を設定した場合、以下の式で表わされる。

Figure 0007278737000003
Each time the image area 1204 is shifted, the subject tracking unit 205 calculates the degree of similarity between the brightness value of each pixel included in the image area 1204 and the brightness value of each pixel included in the template 1201 (pattern matching). Here, the feature amount S(i, j) of the image area 1204 is expressed by the following equation when a coordinate system as shown in FIG. 12B is set.
Figure 0007278737000003

また、テンプレート1201と画像領域1204との類似性を表す評価値をV(x,y)とすると、V(x,y)は、以下の式に示す差分絶対和(SAD:Sum of Absolute Difference)で表される。

Figure 0007278737000004
但し、V(x,y)は、画像領域1204の左上頂点の座標(x,y)における評価値として表す。 Also, let V(x, y) be an evaluation value representing the similarity between the template 1201 and the image region 1204. V(x, y) is the sum of absolute differences (SAD) shown in the following equation. is represented by
Figure 0007278737000004
However, V(x, y) is expressed as an evaluation value at the coordinates (x, y) of the upper left vertex of the image area 1204 .

そして、被写体追尾部205は、画像領域1204を、探索領域1203の左上(x=0、y=0)から右方向(x方向)に1画素ずつシフトさせ、各位置において評価値V(x,y)を算出する。また、被写体追尾部205は、画像領域1204が探索領域1203の右端(x=X-W)に達すると、次に、画像領域1204を、左端(x=0)に戻し、かつ下方向(y方向)に1画素シフトさせる(y=1)。そして、被写体追尾部205は、再び、探索領域1203の左端(x=0、y=1)から右方向(x方向)に1画素ずつシフトさせ、各位置において評価値V(x,y)を算出する。 Then, the subject tracking unit 205 shifts the image area 1204 from the upper left (x=0, y=0) of the search area 1203 to the right (x direction) by one pixel, and the evaluation value V(x, y) is calculated. In addition, when the image area 1204 reaches the right end (x=XW) of the search area 1203, the subject tracking unit 205 returns the image area 1204 to the left end (x=0) and downward (y direction) by one pixel (y=1). Then, the subject tracking unit 205 again shifts the left end (x=0, y=1) of the search area 1203 by one pixel to the right (x direction), and calculates the evaluation value V(x, y) at each position. calculate.

被写体追尾部205は、以上の動作を、探索領域1203が探索領域1203の右下(x=X-W、y=Y-H)に達するまで、繰り返す。但し、Xは、探索領域1203の水平画素数(x方向の画素数)であり、Yは、探索領域1203の垂直画素数(y方向の画素数)である。また、被写体追尾部205は、各位置において算出された各評価値V(x,y)のうち、最も低い評価値を有する位置V(x,y)での画像領域1204が、テンプレート1201に対して類似度が最も高い画像領域であると判断する。 The subject tracking unit 205 repeats the above operation until the search area 1203 reaches the lower right of the search area 1203 (x=XW, y=YH). However, X is the number of horizontal pixels in the search area 1203 (the number of pixels in the x direction), and Y is the number of vertical pixels in the search area 1203 (the number of pixels in the y direction). In addition, the subject tracking unit 205 determines that the image area 1204 at the position V(x, y) having the lowest evaluation value among the evaluation values V(x, y) calculated at each position corresponds to the template 1201. image region with the highest degree of similarity.

このように、被写体追尾部205は、評価値V(x,y)が最小値を示す画素領域1204の位置を、特徴量領域に対応する画素領域の位置、即ち、被写体(追尾対象)の位置として決定する。尚、被写体追尾部205は、探索結果の信頼性が低い場合、例えば、評価値V(x,y)の最小値が閾値よりも大きい場合には、特徴量領域に対応する画像領域が見つけ出せなかったと決定してもよい。 In this way, the subject tracking unit 205 determines the position of the pixel area 1204 showing the minimum evaluation value V(x, y) as the position of the pixel area corresponding to the feature amount area, that is, the position of the subject (tracking target). Determined as When the reliability of the search result is low, for example, when the minimum value of the evaluation value V(x, y) is larger than the threshold, the subject tracking unit 205 cannot find the image area corresponding to the feature amount area. You may decide that

本実施形態では、パターンマッチングにおいて、特徴量として輝度値を用いる例を説明したが、輝度値以外の要素(明度、色相、彩度など)を用いてもよい。また、パターンマッチングにおける評価値V(x,y)は、複数の要素(輝度値、明度、色相、彩度など)を考慮して決定してもよい。さらに、評価値V(x,y)は、SADに代えて、正規化相互相関(NCC: Normalized Cross-Correlation)、ZNCCなどにより表すことも可能である。 In this embodiment, in pattern matching, an example in which the luminance value is used as the feature amount has been described, but elements other than the luminance value (brightness, hue, saturation, etc.) may be used. Also, the evaluation value V(x, y) in pattern matching may be determined in consideration of a plurality of factors (luminance value, lightness, hue, saturation, etc.). Furthermore, the evaluation value V(x, y) can be represented by normalized cross-correlation (NCC), ZNCC, etc. instead of SAD.

<その他の実施形態>
上述の実施形態の各機能又は各処理を実現するプログラムは、予め撮像装置100内のフラッシュメモリ155、又はこれに代えてROM(図示せず)にインストールしておくことが可能である。また、上述の実施形態の1以上の機能又は処理を実現するプログラムは、ネットワーク又は記憶媒体を介して撮像装置100に供給することも可能である。この場合、撮像装置100内の主制御部151、又はこれに代えて少なくとも1つのプロセッサ(図示せず)が当該供給されたプログラムを実行することで、上述の実施形態の各機能又は各処理が実現される。
<Other embodiments>
A program that implements each function or each process of the above-described embodiment can be installed in advance in the flash memory 155 in the imaging apparatus 100 or alternatively in a ROM (not shown). A program that implements one or more functions or processes of the above-described embodiments can also be supplied to the imaging device 100 via a network or storage medium. In this case, the main control unit 151 in the image capturing apparatus 100, or at least one processor (not shown) instead of this, executes the supplied program, thereby performing each function or each process of the above-described embodiment. Realized.

また、上述の実施形態の各機能又は各処理は、上述のように、コンピュータにインストールされたプログラム(ソフトウェア)により実現可能であると共に、ハードウェア(回路)によっても実現可能である。例えば、上述の実施形態の1以上の機能又は処理は、ASIC(Application Specific IC)、FPGA(Field Programmable Gate Array)などの回路でも実現可能である。 Moreover, each function or each process of the above-described embodiments can be realized by a program (software) installed in a computer as described above, and can also be realized by hardware (circuits). For example, one or more functions or processes of the above-described embodiments can also be implemented in circuits such as ASICs (Application Specific ICs), FPGAs (Field Programmable Gate Arrays), and the like.

<むすび>
以上、本発明によれば、画像情報に基づき特徴量領域のサイズを決定することで、追尾状況によらず常に高い追尾性能を得ることが可能な撮像装置を提供できる。例えば、被写体と背景の位置関係が大きく変化する条件下での追尾においては、特徴量領域を被写体領域とほぼ同じサイズとし、被写体と背景の位置関係がほとんど変化しない条件下での追尾においては、特徴量領域を被写体領域よりも大きくする。これにより、追尾状況によらず常に高い追尾性能を得ることが可能となる。
<Conclusion>
As described above, according to the present invention, it is possible to provide an imaging apparatus capable of always obtaining high tracking performance regardless of the tracking situation by determining the size of the feature amount region based on the image information. For example, in tracking under conditions where the positional relationship between the subject and the background changes significantly, the feature amount region is set to be approximately the same size as the subject region, and in tracking under conditions where the positional relationship between the subject and the background changes little, Make the feature amount area larger than the subject area. This makes it possible to always obtain high tracking performance regardless of the tracking situation.

161: 被写体認識部
201: 被写体検出部
202: 特徴量領域登録部
203: 背景の動き量取得部
204: 特徴量領域更新部
205: 被写体追尾部
161: subject recognition unit 201: subject detection unit 202: feature amount area registration unit 203: background movement amount acquisition unit 204: feature amount area update unit 205: subject tracking unit

Claims (15)

第1の画像及び第2の画像を時系列で取得可能な撮像装置であって、
前記第1の画像から追尾対象としての被写体を検出する被写体検出手段と、
前記第1の画像に基づき前記被写体を含む特徴量領域を登録する特徴量領域登録手段と、
前記第1及び第2の画像に係る、前記被写体の動き量を含む情報に基づき、前記特徴量領域登録手段に登録された前記特徴量領域のサイズの更新を行う特徴量領域更新手段と、
前記第2の画像から、前記特徴量領域更新手段でサイズが更新された前記特徴量領域に対応する画像領域の探索を行うことで、前記被写体の追尾を行う被写体追尾手段と、を備える、
ことを特徴とする撮像装置。
An imaging device capable of acquiring a first image and a second image in time series,
subject detection means for detecting a subject as a tracking target from the first image;
feature region registration means for registering a feature region including the subject based on the first image;
feature quantity region updating means for updating the size of the feature quantity region registered in the feature quantity region registration means based on information including the amount of motion of the subject relating to the first and second images;
subject tracking means for tracking the subject by searching from the second image for an image area corresponding to the feature amount region whose size is updated by the feature amount area updating means;
An imaging device characterized by:
前記特徴量領域登録手段は、前記第1の画像に基づき登録する前記特徴量領域のサイズを初期値とする、
ことを特徴とする請求項1に記載の撮像装置。
The feature amount region registration means sets the size of the feature amount region to be registered based on the first image as an initial value,
2. The imaging device according to claim 1, wherein:
前記特徴量領域更新手段は、前記被写体とその背景との位置関係の変化量が基準値よりも大きい場合に、前記特徴量領域のサイズを前記初期値よりも小さくし、かつ前記変化量が前記基準値よりも小さい場合に、前記特徴量領域のサイズを前記初期値よりも大きくする、
ことを特徴とする請求項2に記載の撮像装置。
The feature quantity region updating means reduces the size of the feature quantity region to be smaller than the initial value when the amount of change in the positional relationship between the subject and its background is larger than a reference value, and making the size of the feature region larger than the initial value if it is smaller than the reference value;
3. The imaging apparatus according to claim 2, characterized by:
前記特徴量領域更新手段は、前記変化量が大きくなるに従い前記特徴量領域のサイズを小さくし、かつ前記変化量が小さくなるに従い前記特徴量領域のサイズを大きくする、
ことを特徴とする請求項3に記載の撮像装置。
The feature quantity region updating means reduces the size of the feature quantity region as the amount of change increases, and increases the size of the feature quantity region as the amount of change decreases.
4. The imaging device according to claim 3, characterized in that:
前記特徴量領域更新手段は、前記変化量が閾値よりも大きい場合に、前記特徴量領域のサイズを一定にする、
ことを特徴とする請求項4に記載の撮像装置。
The feature quantity region updating means keeps the size of the feature quantity region constant when the amount of change is greater than a threshold.
5. The imaging device according to claim 4, characterized in that:
前記被写体追尾手段による前記探索が行われ、かつ前記追尾が成功の場合に、前記特徴量領域登録手段は、既に登録されている前記特徴量領域に代えて、前記探索に用いた前記特徴量領域を新たに登録する、
ことを特徴とする請求項1乃至5のいずれか1項に記載の撮像装置。
When the search by the subject tracking means is performed and the tracking is successful, the feature amount area registration means replaces the already registered feature amount area with the feature amount area used in the search. register anew
6. The imaging apparatus according to any one of claims 1 to 5, characterized by:
前記情報は、画面の平均輝度、ホワイトバランス、及びGPS機能による位置情報のうちの少なくとも1つを含む、
ことを特徴とする請求項1乃至6のいずれか1項に記載の撮像装置。
The information includes at least one of average brightness of the screen, white balance, and position information by GPS function.
7. The imaging apparatus according to any one of claims 1 to 6, characterized by:
前記情報は、前記被写体の背景の動き量を含む、
ことを特徴とする請求項1乃至6のいずれか1項に記載の撮像装置。
the information includes the amount of movement of the background of the subject ;
7. The imaging apparatus according to any one of claims 1 to 6, characterized by:
前記第1及び第2の画像から前記背景の動き量を取得する背景の動き量取得手段をさらに備え、
前記被写体追尾手段は、前記第1及び第2の画像から前記被写体の動き量を取得し、
前記特徴量領域更新手段は、前記被写体の動き量及び前記背景の動き量に基づき前記特徴量領域のサイズの更新を行う、
ことを特徴とする請求項8に記載の撮像装置。
Further comprising background motion amount acquisition means for acquiring the amount of motion of the background from the first and second images,
the subject tracking means acquires the amount of motion of the subject from the first and second images;
The feature region updating means updates the size of the feature region based on the amount of motion of the subject and the amount of motion of the background.
9. The imaging apparatus according to claim 8, characterized by:
前記背景の動き量取得手段は、
前記第1及び第2の画像から前記背景を推定し、
前記推定された背景に基づき、前記第1及び第2の画像間の動きベクトルを検出し、
前記動きベクトルに基づき、前記背景の動き量を取得する、
ことを特徴とする請求項9に記載の撮像装置。
The background motion amount acquisition means includes:
estimating the background from the first and second images;
Detecting a motion vector between the first and second images based on the estimated background;
obtaining a motion amount of the background based on the motion vector;
10. The imaging device according to claim 9, characterized by:
前記背景の動き量取得手段は、
ジャイロセンサ及び加速度センサの少なくとも1つにより前記撮像装置の動きを検出し、
前記撮像装置の動きに基づき、前記背景の動き量を取得する、
ことを特徴とする請求項9に記載の撮像装置。
The background motion amount acquisition means includes:
detecting movement of the imaging device by at least one of a gyro sensor and an acceleration sensor;
obtaining the amount of motion of the background based on the motion of the imaging device;
10. The imaging device according to claim 9, characterized by:
前記被写体の追尾に基づき前記被写体に対する撮影条件を制御する制御手段をさらに備える、
ことを特徴とする請求項1乃至11のいずれか1項に記載の撮像装置。
further comprising control means for controlling shooting conditions for the subject based on tracking of the subject;
12. The imaging apparatus according to any one of claims 1 to 11, characterized by:
第1の画像及び第2の画像を時系列で撮像する撮像素子と、
前記第1の画像及び前記第2の画像を処理する少なくとも1つのプロセッサと、を備え、
前記少なくとも1つのプロセッサは、
前記第1の画像から追尾対象としての被写体を検出する被写体検出手段と、
前記第1の画像に基づき前記被写体を含む特徴量領域を登録する特徴量領域登録手段と、
前記第1及び第2の画像に係る、前記被写体の動き量を含む情報に基づき、前記特徴量領域登録手段に登録された前記特徴量領域のサイズの更新を行う特徴量領域更新手段と、
前記第2の画像から、前記特徴量領域更新手段でサイズが更新された前記特徴量領域に対応する画像領域の探索を行うことで、前記被写体の追尾を行う被写体追尾手段と、を備える、
ことを特徴とする撮像装置。
an imaging device that captures the first image and the second image in time series;
at least one processor for processing the first image and the second image;
The at least one processor
subject detection means for detecting a subject as a tracking target from the first image;
feature region registration means for registering a feature region including the subject based on the first image;
feature quantity region updating means for updating the size of the feature quantity region registered in the feature quantity region registration means based on information including the amount of motion of the subject relating to the first and second images;
subject tracking means for tracking the subject by searching from the second image for an image area corresponding to the feature amount region whose size is updated by the feature amount area updating means;
An imaging device characterized by:
第1の画像及び第2の画像を時系列で取得可能な撮像装置の制御方法であって、
前記第1の画像から追尾対象としての被写体を検出する被写体検出工程と、
前記第1の画像に基づき前記被写体を含む特徴量領域を登録する特徴量領域登録工程と、
前記第1及び第2の画像に係る、前記被写体の動き量を含む情報に基づき、前記特徴量領域登録工程登録された前記特徴量領域のサイズの更新を行う特徴量領域更新工程と、
前記第2の画像から、前記特徴量領域更新工程サイズが更新された前記特徴量領域に対応する画像領域の探索を行うことで、前記被写体の追尾を行う被写体追尾工程と、を備える、
ことを特徴とする制御方法。
A control method for an imaging device capable of acquiring a first image and a second image in time series,
a subject detection step of detecting a subject as a tracking target from the first image;
a feature amount region registration step of registering a feature amount region including the subject based on the first image;
a feature quantity region updating step of updating the size of the feature quantity region registered in the feature quantity region registration step based on information including the amount of motion of the subject relating to the first and second images;
a subject tracking step of tracking the subject by searching from the second image for an image area corresponding to the feature amount region whose size has been updated in the feature amount region updating step;
A control method characterized by:
請求項1乃至13のいずれか1項に記載の撮像装置の各手段としてコンピュータを機能させるためのプログラム。 A program for causing a computer to function as each means of the imaging apparatus according to any one of claims 1 to 13.
JP2018188925A 2018-10-04 2018-10-04 IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM Active JP7278737B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2018188925A JP7278737B2 (en) 2018-10-04 2018-10-04 IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2018188925A JP7278737B2 (en) 2018-10-04 2018-10-04 IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM

Publications (2)

Publication Number Publication Date
JP2020057302A JP2020057302A (en) 2020-04-09
JP7278737B2 true JP7278737B2 (en) 2023-05-22

Family

ID=70107384

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2018188925A Active JP7278737B2 (en) 2018-10-04 2018-10-04 IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM

Country Status (1)

Country Link
JP (1) JP7278737B2 (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004206320A (en) 2002-12-25 2004-07-22 Matsushita Electric Ind Co Ltd Image recognition device and method
JP2005346425A (en) 2004-06-03 2005-12-15 Matsushita Electric Ind Co Ltd Automatic tracking system and automatic tracking method
JP2007068008A (en) 2005-09-01 2007-03-15 Matsushita Electric Ind Co Ltd Automatic tracking apparatus
JP2008011497A (en) 2006-06-01 2008-01-17 Canon Inc Camera apparatus
JP2012073997A (en) 2010-09-01 2012-04-12 Ricoh Co Ltd Object tracking device, object tracking method, and program thereof
JP2017151535A (en) 2016-02-22 2017-08-31 株式会社リコー Image processing device, object recognition device, equipment control system, image processing method, and program
JP2017215525A (en) 2016-06-01 2017-12-07 キヤノン株式会社 Imaging device and method for controlling the same, program, and storage medium
JP2018018393A (en) 2016-07-29 2018-02-01 オムロン株式会社 Image processing device and image processing method

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2004206320A (en) 2002-12-25 2004-07-22 Matsushita Electric Ind Co Ltd Image recognition device and method
JP2005346425A (en) 2004-06-03 2005-12-15 Matsushita Electric Ind Co Ltd Automatic tracking system and automatic tracking method
JP2007068008A (en) 2005-09-01 2007-03-15 Matsushita Electric Ind Co Ltd Automatic tracking apparatus
JP2008011497A (en) 2006-06-01 2008-01-17 Canon Inc Camera apparatus
JP2012073997A (en) 2010-09-01 2012-04-12 Ricoh Co Ltd Object tracking device, object tracking method, and program thereof
JP2017151535A (en) 2016-02-22 2017-08-31 株式会社リコー Image processing device, object recognition device, equipment control system, image processing method, and program
JP2017215525A (en) 2016-06-01 2017-12-07 キヤノン株式会社 Imaging device and method for controlling the same, program, and storage medium
JP2018018393A (en) 2016-07-29 2018-02-01 オムロン株式会社 Image processing device and image processing method

Also Published As

Publication number Publication date
JP2020057302A (en) 2020-04-09

Similar Documents

Publication Publication Date Title
JP5398156B2 (en) WHITE BALANCE CONTROL DEVICE, ITS CONTROL METHOD, AND IMAGING DEVICE
KR101062502B1 (en) Image pickup device having a panning mode for picking up panning images
JP4755490B2 (en) Blur correction method and imaging apparatus
JP5729237B2 (en) Image processing apparatus, image processing method, and program
JP6656035B2 (en) Image processing apparatus, imaging apparatus, and control method for image processing apparatus
JP2015148532A (en) Distance measuring device, imaging apparatus, distance measuring method, and program
JP4420906B2 (en) Imaging device
JP2016123044A (en) Subject tracking device, and control method and program therefor
JP2021128537A (en) Image processing device, image processing method, program and storage medium
JP2019101996A (en) Image processing apparatus and image processing method reducing noise by composing plural captured images
JP6564284B2 (en) Image processing apparatus and image processing method
KR20170034299A (en) Posture estimating apparatus, posture estimating method and computer program stored in recording medium
JP6231816B2 (en) IMAGING DEVICE, ITS CONTROL METHOD, PROGRAM, AND STORAGE MEDIUM
JP6178646B2 (en) Imaging apparatus and image shake correction processing method
JP2013110754A (en) Camera device, and photographing method and program of the same
JP2009053786A (en) Image processor, imaging apparatus, image processing method, and program
JP7278737B2 (en) IMAGING DEVICE, CONTROL METHOD THEREOF, AND PROGRAM
JP4807623B2 (en) Imaging apparatus, imaging method, and imaging program
US12008773B2 (en) Object tracking apparatus and control method thereof using weight map based on motion vectors
JP5451364B2 (en) Subject tracking device and control method thereof
JP6218520B2 (en) Image processing apparatus, image processing method, and program
JP2009027437A (en) Image processor, image processing method and imaging device
JP6493746B2 (en) Image tracking device and image tracking method
JP6381212B2 (en) Imaging apparatus and control method thereof
JP2018072941A (en) Image processing device, image processing method, program, and storage medium

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20211004

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20221017

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20221108

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20221227

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20230411

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20230510

R151 Written notification of patent or utility model registration

Ref document number: 7278737

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151