JP7377721B2 - Marker detection device and its program, and marker light emitting device - Google Patents
Marker detection device and its program, and marker light emitting device Download PDFInfo
- Publication number
- JP7377721B2 JP7377721B2 JP2020000983A JP2020000983A JP7377721B2 JP 7377721 B2 JP7377721 B2 JP 7377721B2 JP 2020000983 A JP2020000983 A JP 2020000983A JP 2020000983 A JP2020000983 A JP 2020000983A JP 7377721 B2 JP7377721 B2 JP 7377721B2
- Authority
- JP
- Japan
- Prior art keywords
- marker
- light emission
- unit
- image
- light
- 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
Links
Images
Landscapes
- Length Measuring Devices By Optical Means (AREA)
Description
本発明は、マーカ検出装置およびそのプログラム、ならびに、マーカ発光装置に関する。 The present invention relates to a marker detection device and its program, and a marker light emitting device.
カメラの位置、姿勢および画角(以下、カメラパラメータ)を推定する手法は、3次元の形状および大きさが既知の物体や、3次元の位置関係が既知の複数のマーカを用いて行う手法が一般的である。この推定手法は、強校正と呼ばれる。
例えば、同一平面内に存在する位置関係が既知の4個以上の点を用いて、透視4点問題(P4P問題;Perspective 4-Point Problem)を解くことでカメラパラメータを推定することができる。
このP4P問題の解法を用いるカメラ校正手法では、カメラが撮像した画像上において、4個以上の点がどの像に対応するかを対応付ける必要がある。
一般に、形状や大きさが既知の矩形状のパターンを印刷した平面上のマーカを用いて、矩形状のパターンとともに印刷される識別用パターンによって、複数のマーカを区別する工夫がなされている。
また、3次元位置が既知の点付近にある3次元位置が未知のパターンを用いてカメラパラメータを推定する手法が開示されている(非特許文献1参照)。
A method for estimating the position, orientation, and angle of view (hereinafter referred to as camera parameters) of a camera is to use an object with a known three-dimensional shape and size, or multiple markers with a known three-dimensional positional relationship. Common. This estimation method is called strong calibration.
For example, camera parameters can be estimated by solving a Perspective 4-Point Problem (P4P problem) using four or more points with known positional relationships existing in the same plane.
In the camera calibration method using this method of solving the P4P problem, it is necessary to associate which image four or more points correspond to on the image captured by the camera.
In general, a plan-based marker on which a rectangular pattern of known shape and size is printed is used, and an identification pattern printed together with the rectangular pattern is used to distinguish a plurality of markers.
Furthermore, a method of estimating camera parameters using a pattern whose three-dimensional position is unknown and which is located near a point whose three-dimensional position is known has been disclosed (see Non-Patent Document 1).
強校正に用いるマーカとして、印刷されたパターン等、非発光のマーカを用いる場合、マーカに光が当たらなければ当該パターンを校正に用いることができない。
また、マーカに識別用パターンを含めても、識別用パターンの一部に影が落ちる等、均一な照明が得られない場合、識別誤りが生じることがある。
また、マーカに類似した模様の物体が校正すべきカメラの視野内に存在すると、誤認識を起こしてしまう。
このように、従来の手法では、マーカの検出および識別を頑健に行うことができないという問題がある。また、強校正以外にも、物体の位置検出等、少なくとも2以上のマーカを頑強に検出および識別する手法が望まれている。
When a non-luminescent marker such as a printed pattern is used as a marker for strong calibration, the pattern cannot be used for calibration unless the marker is exposed to light.
Furthermore, even if a marker includes an identification pattern, if uniform illumination cannot be obtained, such as when a part of the identification pattern is cast in a shadow, an identification error may occur.
Furthermore, if an object with a pattern similar to the marker exists within the field of view of the camera to be calibrated, erroneous recognition will occur.
As described above, the conventional method has a problem in that marker detection and identification cannot be performed robustly. In addition to strong calibration, there is a need for a method for robustly detecting and identifying at least two or more markers, such as detecting the position of an object.
本発明は、このような問題、要望に鑑み、マーカの検出や識別を頑強に行うことが可能なマーカ検出装置およびそのプログラム、ならびに、マーカ発光装置を提供することを課題とする。 In view of these problems and demands, it is an object of the present invention to provide a marker detection device and its program, and a marker light emitting device that can robustly detect and identify markers.
前記課題を解決するため、本発明に係るマーカ検出装置は、複数のタイムスロットで構成された発光パターンの時間区間において、前記タイムスロットごとの発光パターンの変化を示す発光パターンベクトルの同一のマーカにおける内積が0より大きく、異なるマーカ間の前記内積が0以下となる発光パターンで発光する複数のマーカを撮像した映像から、前記マーカを検出するマーカ検出装置であって、相関演算部と、閾値処理部と、マーカ座標演算部と、を備える構成とした。 In order to solve the above problem, a marker detection device according to the present invention provides a marker detection device according to the present invention, in which a light emission pattern vector indicating a change in a light emission pattern for each time slot is detected at the same marker in a time interval of a light emission pattern made up of a plurality of time slots. A marker detection device that detects a marker from a video image of a plurality of markers emitting light in a light emission pattern in which the inner product is greater than 0 and the inner product between different markers is less than or equal to 0, the marker detection device comprising: a correlation calculation unit; and a threshold processing unit. The configuration includes a section and a marker coordinate calculation section.
かかる構成において、マーカ検出装置は、相関演算部によって、発光パターンの時間区間ごとに、映像のフレーム画像の画素と、発光パターンごとの発光パターンベクトルとの間の相関を演算することで発光パターンごとの相関画像を生成する。
このとき、各マーカの発光パターンは、同一のマーカにおける発光パターンベクトルの内積が0より大きく、異なるマーカ間の発光パターンベクトル内積が0以下であるため、相関画像は、発光パターンと相関の強い画素の画素値が正または負で大きな値となる。
In such a configuration, the marker detection device uses the correlation calculation unit to calculate the correlation between the pixels of the frame image of the video and the light emission pattern vector for each light emission pattern for each time interval of the light emission pattern. generate a correlated image of
At this time, in the luminescence pattern of each marker, the inner product of luminescence pattern vectors for the same marker is greater than 0, and the inner product of luminescence pattern vectors between different markers is less than or equal to 0. Therefore, the correlation image is composed of pixels that have a strong correlation with the luminescence pattern. If the pixel value of is positive or negative, it becomes a large value.
そして、マーカ検出装置は、閾値処理部によって、発光パターンごとの相関画像を予め定めた閾値で二値化する。これによって、マーカ検出装置は、マーカとそれ以外の領域とを区分した二値化画像を生成する。
そして、マーカ検出装置は、マーカ座標演算部によって、閾値処理部で生成された二値化画像において、マーカの領域の重心等の代表点を演算する。
これによって、マーカ検出装置は、発光パターンで識別されるマーカの位置を代表点の位置として検出する。
Then, in the marker detection device, the threshold processing section binarizes the correlation image for each emission pattern using a predetermined threshold. Thereby, the marker detection device generates a binarized image in which the marker and other areas are separated.
Then, in the marker detection device, the marker coordinate calculation unit calculates a representative point such as the center of gravity of the marker region in the binarized image generated by the threshold processing unit.
Thereby, the marker detection device detects the position of the marker identified by the light emission pattern as the position of the representative point.
なお、マーカ検出装置は、コンピュータを、前記した各部として機能させるためのマーカ検出プログラムで動作させることができる。 Note that the marker detection device can be operated by a marker detection program for causing a computer to function as each of the above-described units.
また、前記課題を解決するため、本発明に係るマーカ発光装置は、マーカごとに予め定めた発光パターンで複数のマーカを発光するマーカ発光装置であって、前記複数のマーカとなる複数の発光素子を備えた発光部と、前記マーカごとの発光状態を制御する発光制御部と、を備える構成とした。 Further, in order to solve the above problems, a marker light emitting device according to the present invention is a marker light emitting device that emits a plurality of markers in a predetermined light emission pattern for each marker, and includes a plurality of light emitting elements serving as the plurality of markers. The present invention is configured to include a light emitting section having a light emitting section, and a light emitting control section controlling the light emitting state of each marker.
かかる構成において、マーカ発光装置は、発光制御部によって、複数のタイムスロットで構成された発光パターンの時間区間において、タイムスロットごとの発光パターンの変化を示す発光パターンベクトルの同一のマーカにおける内積が0より大きく、異なるマーカ間の内積が0以下となる発光パターンで、発光部のマーカの発光状態を制御する。
このような発光パターンでマーカの発光状態を制御することで、マーカを撮像した映像から、マーカの発光パターンと相関の強い画像上の位置を検出することが可能になる。
In such a configuration, in the marker light emitting device, the light emitting control unit causes the inner product of the light emitting pattern vectors indicating the change in the light emitting pattern for each time slot to be 0 at the same marker in the time interval of the light emitting pattern composed of a plurality of time slots. The light emitting state of the marker of the light emitting unit is controlled using a light emitting pattern that is larger and has an inner product between different markers of 0 or less.
By controlling the light emission state of the marker using such a light emission pattern, it becomes possible to detect a position on the image that has a strong correlation with the light emission pattern of the marker from an image of the marker.
本発明は、以下に示す優れた効果を奏するものである。
本発明によれば、マーカの発光によって、照明が均一でない環境であっても、マーカを検出することができる。また、本発明によれば、マーカの発光パターンによって、映像中のマーカの検出と識別とを頑健に行うことができる。
The present invention has the following excellent effects.
According to the present invention, the marker can be detected even in an environment where illumination is not uniform due to the light emission of the marker. Further, according to the present invention, it is possible to robustly detect and identify a marker in an image based on the light emission pattern of the marker.
以下、本発明の実施形態について図面を参照して説明する。
<第1実施形態>
[マーカ検出システム]
図1を参照して、本発明の第1実施形態に係るマーカ検出システムSの概要について説明する。
マーカ検出システムSは、2以上のマーカを、カメラが撮像した映像から検出し識別するものである。
マーカ検出システムSは、マーカ発光装置1と、マーカ検出装置2と、カメラ3と、を備える。
Embodiments of the present invention will be described below with reference to the drawings.
<First embodiment>
[Marker detection system]
With reference to FIG. 1, an overview of a marker detection system S according to a first embodiment of the present invention will be described.
The marker detection system S detects and identifies two or more markers from an image captured by a camera.
The marker detection system S includes a marker
マーカ発光装置1は、マーカごとに予め定めた発光パターンで複数のマーカを発光するものである。ここでは、マーカ発光装置1とマーカ検出装置2とを信号線4で接続し、マーカ発光装置1から、信号線4を介して、発光パターンを制御信号としてマーカ検出装置2に出力する。
マーカ検出装置2は、マーカ発光装置1が発光するマーカの発光パターンによって、カメラ3が撮像した映像から、マーカの位置を検出するものである。ここでは、マーカ検出装置2は、それぞれのマーカごとに、その位置を、映像を構成する時系列の画像中の座標として出力する。
The marker
The
カメラ3は、マーカ発光装置1が発光するマーカを撮像するビデオカメラである。なお、マーカ検出システムSを、カメラ校正のために用いる場合、カメラ3は、校正対象のカメラとなる。
以下、マーカ発光装置1およびマーカ検出装置2について詳細に説明する。
The
The marker
[マーカ発光装置]
まず、図1を参照して、本発明の第1実施形態に係るマーカ発光装置1について説明する。
図1に示すように、マーカ発光装置1は、発光部10と発光制御部11とを備える。
発光部10は、複数のマーカ101,…,106として複数の発光素子を備える。
マーカ101,…,106は、2つの発光状態で切り替えて光(可視光、赤外光、紫外光等の電磁波)を発光するものである。2つの発光状態とは、点滅の場合であれば点灯状態および消灯状態、輝度変化の場合であれば高輝度状態および低輝度状態等である。
ここでは、マーカを6個(101~106)、2つの発光状態を点滅とする例で説明する。
[Marker light emitting device]
First, with reference to FIG. 1, a marker
As shown in FIG. 1, the marker light-emitting
The
The
Here, an example will be explained in which there are six markers (101 to 106) and two light emission states are blinking.
発光部10を構成する発光素子であるマーカ101,…,106は、図2に示すように、カメラ3が撮像する空間内に配置される。
マーカ101,…,106は、発光制御部11から出力される制御信号により発光状態を切り替える。
The
発光制御部11は、マーカ101,…,106ごとの発光状態を制御するものである。この発光制御部11は、予め定めた発光パターンで、発光部10のマーカ101,…,106の発光状態を制御する。
ここでは、発光制御部11は、2値の値をとる時間関数により定義される発光パターンを用いる。以下、時間関数をwn(t)とする。なお、nはマーカを区別する符号(ここでは、101~106)であり、tは時刻である。wn(t)は、“+1”および“-1”の2値をとる。
The light
Here, the light
発光制御部11は、マーカごとの時間関数wn(t)の値に応じて、例えば、“+1”の場合は点灯、“-1”の場合は消灯するように、各マーカの発光状態を制御する。
時間関数wn(t)は、所定の時間周期でパターンが繰り返され、その時間周期に有限個のタイムスロット(一定の時間区間)を有し、各タイムスロットにおいて1つの発光状態を継続するような関数とする。
例えば、時間関数wn(t)は、カメラ3の撮像のフレームレートFに同期したM個のタイムスロットを有し、周期M/Fの時間で反復するウォルシュ関数Wnで定義する以下の式(1)とする。
The light
The time function w n (t) has a pattern that is repeated in a predetermined time period, has a finite number of time slots (fixed time sections), and continues one light emitting state in each time slot. Let it be a function.
For example, the time function w n (t) has M time slots synchronized with the frame rate F of imaging by the
また、Wn()は、定数関数を除くウォルシュ関数であって、例えば、タイムスロットの数をM=4としたとき、W101()~W106()は、以下の式(3)とする。 Furthermore, W n () is a Walsh function excluding constant functions, and for example, when the number of time slots is M=4, W 101 () to W 106 () are expressed as the following equation (3). do.
この式(3)の値を有する前記式(1)の時間関数wn(t)を、図3のグラフで示す。
図3において、(a)はw101(t)、(b)はw102(t)、(c)はw103(t)、(d)はw104(t)、(e)はw105(t)、(f)はw106(t)のそれぞれのタイムスロット4個分の時刻tにおける値を示している。
なお、(d)~(f)の各値は、(a)~(c)の同じ時刻の値の符号を反転したものである。
The time function w n (t) of the above equation (1) having the value of this equation (3) is shown in the graph of FIG.
In FIG. 3, (a) is w 101 (t), (b) is w 102 (t), (c) is w 103 (t), (d) is w 104 (t), and (e) is w 105 (t) and (f) indicate the values of w 106 (t) at time t for each of four time slots.
Note that each value of (d) to (f) is the value obtained by inverting the sign of the value of (a) to (c) at the same time.
ここで、前記式(1)で制御されるマーカ101,…,106の発光状態を図4に示す。図4は、カメラ3が撮像する映像の4フレーム周期で時系列に変化するフレーム画像を示し、(a)はI(4k+0)、(b)はI(4k+1)、(c)はI(4k+2)、(d)はI(4k+3)のフレーム画像(kは整数)を示している。
図4(a)は、マーカ101,102,103が点灯し、マーカ104,105,106が消灯した状態を示している。図4(b)は、マーカ101,105,106が点灯し、マーカ102,103,104が消灯した状態を示している。図4(c)は、マーカ103,104,105が点灯し、マーカ101,102,106が消灯した状態を示している。図4(d)は、マーカ102,104,106が点灯し、マーカ101,103,105が消灯した状態を示している。
このように、発光制御部11は、予め定めた数のタイムスロットで、周期的に、マーカ101,…,106の発光状態を変えて発光させる。
Here, FIG. 4 shows the light emission state of the
FIG. 4A shows a state in which the
In this way, the light
発光制御部11がマーカ101,…,106を制御する発光パターンは、同一のマーカにおける時間関数wn(t)の発光パターンベクトルの内積(自己相関)が“0”よりも大きく、異なるマーカ間の時間関数wm(t) (m≠n)における発光パターンベクトルの内積(相互相関)が“0”以下とする。
発光パターンベクトルは、タイムスロットごとの発光パターンの変化を示す数値列である。例えば、タイムスロットの数が4個で変化する図3(a)のw101(t)は、[+1 +1 -1 -1]、図3(b)のw102(t)は、[+1 -1 -1 +1]、図3(c)のw103(t)は、[+1 -1 +1 -1]等である。
The light emission pattern in which the light
The light emission pattern vector is a numerical value string indicating a change in the light emission pattern for each time slot. For example, w 101 (t) in FIG. 3(a), where the number of time slots changes by four, is [ +1 +1 −1 −1 ], and w 102 (t) in FIG. 3(b) is [ +1 −1 1 −1 +1 ], w 103 (t) in FIG. 3(c) is [ +1 −1 +1 −1 ], and so on.
なお、時間関数wn(t)は、時間関数wm(t) (m≠n)との相互相関が、時間関数wn(t)の自己相関よりも十分低ければよく、例えば、相互相関が自己相関の0.5倍以下とすることが好ましい。
また、時間関数wn(t)は、ウォルシュ関数以外にも、疑似ランダム雑音系列、M系列等、2値(±1とする)の切り替えを周期的に行う関数であればよい。この場合、周期的に切り替わる2値のそれぞれに、マーカの発光状態を対応付ければよい。
Note that the time function w n (t) only needs to have a cross-correlation with the time function w m (t) (m≠n) that is sufficiently lower than the autocorrelation of the time function w n (t). is preferably 0.5 times or less than the autocorrelation.
Further, the time function w n (t) may be any function other than the Walsh function, such as a pseudorandom noise sequence, an M sequence, or the like, which periodically switches between binary values (assumed to be ±1). In this case, the light emitting state of the marker may be associated with each of the periodically switched binary values.
なお、ここでは、発光部10を6個のマーカ101,…,106で構成したが、マーカの数はこれに限定されない。マーカを増減させる場合、マーカごとに個別の発光パターンで発光させればよい。その場合、タイムスロットの数を増減してもよいし、符号を反転した信号(ここでは、w104(t)~w106(t))を使用しないこととしてもよい。
In addition, although the
[マーカ検出装置:構成]
次に、図1を参照して、本発明の第1実施形態に係るマーカ検出装置2の構成について説明する。
図1に示すように、マーカ検出装置2は、相関演算部20と、閾値処理部30と、マーカ座標演算部40と、を備える。
[Marker detection device: configuration]
Next, with reference to FIG. 1, the configuration of the
As shown in FIG. 1, the
相関演算部20は、発光パターンの時間区間ごとに、映像のフレーム画像の画素と、発光パターンごとの発光パターンベクトルとの間の相関を演算するものである。この演算結果は、発光パターンごとの相関として演算された画素値の画素で構成された相関画像となる。
ここでは、相関演算部20は、乗算部21と、積算部22と、を備える。
The
Here, the
乗算部21は、発光パターンごとに、カメラ3から入力される映像のフレーム画像の画素値と、フレーム画像の時刻に対応して符号が変化する信号線4を介して入力される発光パターンの発光パターンベクトルの値とを乗算するものである。
ここでは、乗算部21は、以下の式(4)に示すように、時刻tに入力されるフレーム画像I(t)と、マーカごとの制御信号である時間関数wn(t)とを、個々の乗算器M1~M3で乗算することで、マーカごとの乗算結果pn(t)を生成する。
For each light emission pattern, the
Here, the
なお、乗算部21は、マーカ発光装置1の発光制御部11において、発光パターンとして、反転した発光パターンを用いている場合、反転していない発光パターンまたは反転した発光パターンのいずれかを用いればよい。
ここでは、反転していない発光パターンを示す関数w101(t),w102(t),w103(t)を、それぞれ、乗算器M1,M2,M3に入力し、フレーム画像I(t)と乗算することで、乗算結果p101(t),p102(t),p103(t)を生成する。
乗算部21は、乗算結果p101(t),p102(t),p103(t)を、積算部22に出力する。
Note that when the light
Here, functions w 101 (t), w 102 (t), and w 103 (t) indicating non-inverted light emission patterns are input to multipliers M 1 , M 2 , and M 3 , respectively, and the frame image I (t) to generate multiplication results p 101 (t), p 102 (t), and p 103 (t).
The
積算部22は、乗算部21で乗算された発光パターンごとの乗算結果を発光パターン時間区間ごとに積算するものである。この積算結果が相関画像となる。
ここでは、積算部22は、以下の式(5)に示すように、乗算部21で生成された乗算結果pn(t)を、発光パターンの繰り返しの基準であるタイムスロットM個(ここでは、4個)分に相当する時間区間で、画素位置ごとに和を演算することで、相関画像rn(t)を生成する。
The integrating
Here, the
なお、Lは、自然数であって典型的には“1”である。このLは、積算部22における積算数が、必ずしも発光パターンの繰り返しの基準であるタイムスロットの数に限定されず、その整数倍であってもよいことを意味する。
積算部22は、生成した相関画像r101(t),r102(t),r103(t)を、積算部22に出力する。
Note that L is a natural number and is typically "1". This L means that the number of integrations in the
The
ここで、図5を参照して、相関画像rn(t)の具体例について説明する。
図5は、前記式(5)の演算によって積算部22が生成する相関画像を示す図であって、(a)は相関画像r101(t)、(b)は相関画像r102(t)、(c)は相関画像t103(t)を示す。
図5に示すように、マーカ101は、相関画像r101(t)のみにおいてマーカ像が現れ、そのマーカ像はマーカ101の輝度に応じた輝度が高い正の画素値となり、他の画素はそれよりも輝度が低い画素値となる。
また、マーカ102は、相関画像r102(t)のみにおいてマーカ像が現れ、そのマーカ像はマーカ102の輝度に応じた輝度が高い正の画素値となり、他の画素はそれよりも輝度が低い画素値となる。
同様に、マーカ103は、相関画像r103(t)のみにおいてマーカ像が現れ、そのマーカ像はマーカ103の輝度に応じた輝度が高い正の画素値となり、他の画素はそれよりも輝度が低い画素値となる。
Here, a specific example of the correlation image r n (t) will be described with reference to FIG. 5.
FIG. 5 is a diagram showing correlation images generated by the
As shown in FIG. 5, the marker image of the
Further, the marker image appears only in the correlation image r 102 (t), and the marker image has a positive pixel value with high brightness according to the brightness of the
Similarly, the marker image of the
マーカ104は、マーカ101の発光パターンの符号を判定させたものであるため、相関画像r101(t)のみにおいてマーカ像が現れ、そのマーカ像はマーカ104の輝度に応じた輝度が低い負の画素値となり、他の画素はそれよりも輝度が高い画素値となる。
また、マーカ105は、マーカ102の発光パターンの符号を判定させたものであるため、相関画像r102(t)のみにおいてマーカ像が現れ、そのマーカ像はマーカ105の輝度に応じた輝度が低い負の画素値となり、他の画素はそれよりも輝度が高い画素値となる。
同様に、マーカ106は、マーカ103の発光パターンの符号を判定させたものであるため、相関画像r103(t)のみにおいてマーカ像が現れ、そのマーカ像はマーカ106の輝度に応じた輝度が低い負の画素値となり、他の画素はそれよりも輝度が高い画素値となる。
このように、相関演算部20は、相関画像として、マーカの領域を輝度で識別可能な画像を生成する。
図1に戻って、マーカ検出装置2の構成について説明を続ける。
Since the
Furthermore, since the
Similarly, since the
In this way, the
Returning to FIG. 1, the description of the configuration of the
閾値処理部30は、相関演算部20で生成された発光パターンごとの相関画像を予め定めた閾値で二値化することで、マーカとそれ以外の領域とを区分した二値化画像を生成するものである。
閾値処理部30は、抽出したいマーカの像が正の画素値となる相関画像rn(t)については、相関画像rn(t)の各画素の画素値が予め定めた正の閾値を超えた(または閾値以上)か否かを判定する。そして、閾値処理部30は、閾値を超えた(または閾値以上の)場合には、二値化画像の当該画素位置の画素値を例えば“1”、それ以外の場合には、二値化画像の当該画素位置の画素値を例えば“0”とする。
The
For a correlated image r n (t) in which the image of the marker to be extracted has a positive pixel value, the
また、閾値処理部30は、抽出したいマーカの像が負の画素値となる相関画像rn(t)については、相関画像rn(t)の各画素の画素値が予め定めた負の閾値を超えた(または閾値以上)か否かを判定する。そして、閾値処理部30は、閾値を超えた(または閾値以上の)場合には、二値化画像の当該画素位置の画素値を例えば“0”、それ以外の場合には、二値化画像の当該画素位置の画素値を例えば“1”とする。
In addition, for a correlated image r n (t) in which the image of the marker to be extracted has a negative pixel value, the
例えば、閾値処理部30は、図6に示す構成とすることができる。
図6に示すように、閾値処理部30は、マーカの数に応じた複数の二値化部31(311,312,313,314,315,316)を備える。
二値化部311,312,313は、正の閾値で相関画像を二値化するものである。
ここでは、二値化部311は、相関画像r101(t)を入力し、閾値(+θ)を超える画素値を“1”、閾値(+θ)以下の画素値を“0”とすることで、二値化画像b101(t)を生成する。
二値化部312は、二値化部311と同様の処理で、相関画像r102(t)から二値化画像b102(t)を生成する。
二値化部313も、二値化部311と同様の処理で、相関画像r103(t)から二値化画像b103(t)を生成する。
For example, the
As shown in FIG. 6, the
The
Here, the
The
The
二値化部314,315,316は、負の閾値で相関画像を二値化するものである。
ここでは、二値化部314は、相関画像r101(t)を入力し、閾値(-θ)以上の画素値を“0”、閾値(-θ)未満の画素値を“1”とすることで、二値化画像b104(t)を生成する。
二値化部315は、二値化部314と同様の処理で、相関画像r102(t)から二値化画像b105(t)を生成する。
二値化部316も、二値化部314と同様の処理で、相関画像r103(t)から二値化画像b106(t)を生成する。
The
Here, the binarization unit 314 inputs the correlation image r 101 (t), and sets pixel values above the threshold (-θ) to "0" and pixel values below the threshold (-θ) to "1". By doing so, a binarized image b 104 (t) is generated.
The binarization unit 315 generates a binarized image b 105 (t) from the correlation image r 102 (t) using the same process as the
The binarization unit 316 also generates a binarized image b 106 (t) from the correlation image r 103 (t) using the same process as the
例えば、閾値処理部30は、図5に示した相関画像r101(t)~r103(t)から、図7に示した二値化画像b101(t)~b106(t)を生成する。なお、図7中、点線で示した像は、マーカの位置を分かりやすく示したもので、実際の二値化画像には存在しない像である。
図7(a)に示すように、二値化画像b101(t)には、マーカ101のみが明るく検出される。また、図7(b)に示すように、二値化画像b102(t)には、マーカ102のみが明るく検出される。また、図7(c)に示すように、二値化画像b103(t)には、マーカ103のみが明るく検出される。また、図7(d)に示すように、二値化画像b104(t)には、マーカ104のみが明るく検出される。また、図7(e)に示すように、二値化画像b105(t)には、マーカ105のみが明るく検出される。また、図7(f)に示すように、二値化画像b106(t)には、マーカ106のみが明るく検出される。
図1に戻って、マーカ検出装置2の構成について説明を続ける。
閾値処理部30は、生成したマーカごとの二値化画像をマーカ座標演算部40に出力する。
For example, the
As shown in FIG. 7A, only the
Returning to FIG. 1, the description of the configuration of the
The
マーカ座標演算部40は、閾値処理部30で生成された二値化画像において、マーカの領域の代表点を演算するものである。代表点とは、画像領域の代表となる位置であって、当該領域の重心、平均等である。
ここでは、マーカ座標演算部40は、各二値化画像において、マーカの像として検出された所定画素値(ここでは、“1”)の領域の重心をマーカ座標として算出する。
マーカ座標演算部40は、二値化画像bn(t)の画像座標(x,y)における画素値をbn(t;x,y)としたとき、以下の式(6)により、マーカであるはマーカnの画像座標(ξn,ηn)をマーカ座標として算出する。
The marker coordinate
Here, the marker coordinate
When the pixel value at the image coordinates (x, y) of the binarized image b n (t) is b n (t; x, y), the marker coordinate
マーカ座標演算部40は、算出したマーカごとのマーカ座標を検出結果として出力する。
以上説明したようにマーカ検出装置2を構成することで、マーカ検出装置2は、マーカの発光パターンによって、照明が均一でない環境であっても、マーカを検出し、各マーカを識別することができる。
なお、マーカ検出装置2は、コンピュータを、前記した各部として機能させるプログラム(マーカ検出プログラム)で動作させることができる。
The marker coordinate
By configuring the
Note that the
[マーカ検出装置:動作]
次に、図8を参照(構成については適宜図1参照)して、本発明の第1実施形態に係るマーカ検出装置2の動作について説明する。なお、マーカ検出装置2には、マーカ発光装置1が所定発光パターンで複数のマーカを発光させた空間をカメラ3で撮像した映像が、入力されるものとする。また、マーカ検出装置2には、マーカ発光装置1がマーカを発光させる発光パターンの制御信号が、信号線4を介して入力されるものとする。
[Marker detection device: operation]
Next, with reference to FIG. 8 (see FIG. 1 as appropriate for the configuration), the operation of the
ステップS1において、相関演算部20の乗算部21は、カメラ3が撮像した映像のフレーム画像ごとに、マーカごとの発光パターンの制御信号を乗算することで、発光パターンごとの乗算結果を生成する。なお、マーカの発光パターンが互いに反転したパターンの場合、乗算部21は、一方の発光パターンのみを用いて、乗算結果を生成する。
In step S1, the
ステップS2において、相関演算部20の積算部22は、ステップS1で生成された乗算結果に対して、発光パターンの繰り返しの基準となる時間区間で、画素位置ごとに和を演算する。
これによって、相関演算部20は、発光パターンの時間区間を基準として画素ごとの相関を示す相関画像(図5参照)を、発光パターンごとに生成する。
In step S2, the
Thereby, the
ステップS3において、閾値処理部30は、ステップS2で生成された発光パターンごとの相関画像を閾値処理することで、マーカごとの二値化画像(図7参照)を生成する。
なお、マーカの発光パターンが互いに反転したパターンの場合、閾値処理部30は、1つの相関画像から、2つの二値化画像を生成する。
In step S3, the
Note that when the light emission patterns of the markers are inverted patterns, the
ステップS4において、マーカ座標演算部40は、ステップS3で生成されたマーカごとの二値化画像から、それぞれ、マーカの領域を示す所定画素値の領域の代表点(重心)の座標を算出する。
これによって、マーカ座標演算部40は、マーカごとの画像上のマーカ座標を算出する。
以上の動作によって、マーカ検出装置2は、複数のマーカの発光パターンによって、マーカを撮像した映像から、マーカを検出するとともに、マーカの識別を行うことができる。
In step S4, the marker coordinate
Thereby, the marker coordinate
Through the above-described operations, the
<第2実施形態>
[マーカ検出装置]
次に、図9を参照して、本発明の第2実施形態に係るマーカ検出装置2Bについて説明する。なお、マーカ発光装置は、図1で説明したマーカ発光装置1を用いることができる。
<Second embodiment>
[Marker detection device]
Next, with reference to FIG. 9, a
マーカ検出装置2Bは、マーカ検出装置2と同様、マーカ発光装置1が発光するマーカの発光パターンによって、カメラ3が撮像した映像から、マーカの位置を検出し識別するものである。ただし、マーカ検出装置2は、少なくとも、発光パターンの時間区間において、カメラ3の位置、姿勢および画角が一定である必要がある。それに対し、マーカ検出装置2Bは、カメラ3の位置、姿勢、画角等の動きを許容して、マーカを検出する。
Like the
図9に示すように、マーカ検出装置2Bは、相関演算部20Bと、閾値処理部30と、マーカ座標演算部40と、を備える。閾値処理部30およびマーカ座標演算部40は、図1で説明したマーカ検出装置2と同じ構成であるため、同一の符号を付して説明を省略する。
As shown in FIG. 9, the
相関演算部20Bは、カメラ3の位置、姿勢および画角の変化を許容して、発光パターンの時間区間ごとに、映像のフレーム画像の画素と、発光パターンごとの発光パターンベクトルとの間の相関を演算することで、相関画像を生成するものである。
ここでは、相関演算部20Bは、映像遅延部23と、動き補償部24と、信号遅延部25と、乗算部21Bと、積算部22Bと、を備える。
The
Here, the
映像遅延部23は、カメラ3が撮像する映像を予め定めたフレーム単位で遅延させるものである。ここでは、複数の映像遅延部231,232,233を備え、各映像遅延部23が、映像を1フレーム遅延させる。
映像遅延部231は、カメラ3から入力される映像を1フレーム遅延して、映像遅延部232と、動き補償部241とに出力する。
映像遅延部232は、映像遅延部231から入力される映像を1フレーム遅延して、映像遅延部233と、動き補償部242とに出力する。
映像遅延部233は、映像遅延部232から入力される映像を1フレーム遅延して、動き補償部243に出力する。
The
The
The
The
動き補償部24は、カメラ3から入力される映像と、映像遅延部23で遅延された映像との間の映像の動きを推定し、推定した動き量に基づいて、映像遅延部23で遅延された映像をフレーム画像ごとに動き補償するものである。ここでは、複数の動き補償部241,242,243を備え、各動き補償部24が、それぞれ、映像遅延部231,232,233で遅延された映像の動き補償を行う。
The
動き補償部241は、カメラ3から入力される映像と、映像遅延部231で遅延された映像との間の画像の動きを推定し動き補償を行うことで、遅延された映像をカメラ3から入力される映像に位置合わせした動き補償映像を生成する。動き補償部241は、生成した動き補償映像を、乗算部212に出力する。
動き補償部242は、カメラ3から入力される映像と、映像遅延部232で遅延された映像との間の画像の動きを推定し動き補償を行うことで、遅延された映像をカメラ3から入力される映像に位置合わせした動き補償映像を生成する。動き補償部242は、生成した動き補償映像を、乗算部213に出力する。
動き補償部243は、カメラ3から入力される映像と、映像遅延部233で遅延された映像との間の画像の動きを推定し動き補償を行うことで、遅延された映像をカメラ3から入力される映像に位置合わせした動き補償映像を生成する。動き補償部243は、生成した動き補償映像を、乗算部214に出力する。
The
The
The
この各動き補償部24における動き補償は、一般的な手法を用いればよい。
例えば、動き補償部24は、画面全体を幾何変換するグローバル動き補償を行うものであってもよい。グローバル動き補償を行うことで、画面全体の大局的な動きを補償し、時刻の異なる画像間の細かな動きに影響されない頑健なマーカの検出および識別が可能になる。
Motion compensation in each
For example, the
また、例えば、動き補償部24は、画面を部分領域ごとに幾何変換する局所的な動き補償を行うものであってもよい。この部分領域は、互いに重なりを有さなくてもよいし、重なりを有していてもよい。また、局所的な動き補償は、画像を複数の矩形領域に区切って、各矩形領域に対して個々の幾何変換を適用する。局所的な動き補償を行うことで、カメラ3の光学系に幾何学的な歪がある場合でも高精度な動き補償が可能になり、マーカの検出および識別の精度が向上する。
なお、グローバル動き補償や局所的な動き補償に用いる幾何変換には、併進、拡大・縮小、回転、せん断写像(シアー)、アフィン変換、ホモグラフィー変換、レンズ歪み補償の一つまたは複数の組み合わせが挙げられる。
Further, for example, the
Note that the geometric transformation used for global motion compensation and local motion compensation includes one or more combinations of translation, expansion/reduction, rotation, shear mapping (shear), affine transformation, homography transformation, and lens distortion compensation. Can be mentioned.
また、各動き補償部24における動き推定は、一般的な手法を用いればよい。
例えば、動き補償部24は、入力した映像の画像間で、画素値列の誤差を最小化するように動きを推定するものであってもよいし、画像間の画素値列の相関を最大化するように動きを推定するものであってもよい。また、画素値列の誤差を最小化する手法は、ロバスト推定法を用いてもよい。
例えば、ロバスト推定法として、最小メジアン(LMedS;Least Median of Squares)を用いる場合、動き補償部24は、入力した映像の画像間において画素値列の誤差を最小化する際に、画素ごとの二乗誤差を求め、その中央値が最小となるように、幾何変換のパラメータを算出することで動き推定し動き補償を行う。
これによって、マーカ以外の被写体の輝度や動きの変化、画像の雑音等の影響を抑えて動き補償の頑健性を高めることができ、頑健なマーカの検出および識別が可能になる。
Further, motion estimation in each
For example, the
For example, when using the least median of squares (LMedS) as the robust estimation method, the
As a result, the robustness of motion compensation can be increased by suppressing the effects of changes in brightness and movement of subjects other than markers, image noise, etc., and robust detection and identification of markers becomes possible.
例えば、図10(a)~(d)に示すように、時刻tのフレーム画像I(t)、時刻t-1のフレーム画像I(t-1)、時刻t-2のフレーム画像I(t-2)、時刻t-3のフレーム画像I(t-3)としたとする。
このとき、動き補償部241は、フレーム画像I(t-1)に対して、フレーム画像I(t)との誤差が最小となるように動き補償を行う。また、動き補償部242は、フレーム画像I(t-2)に対して、フレーム画像I(t)との誤差が最小となるように動き補償を行う。また、動き補償部243は、フレーム画像I(t-3)に対して、フレーム画像I(t)との誤差が最小となるように動き補償を行う。また、動き補償部244は、フレーム画像I(t-4)に対して、フレーム画像I(t)との誤差が最小となるように動き補償を行う。
For example, as shown in FIGS. 10(a) to 10(d), a frame image I(t) at time t, a frame image I(t-1) at time t-1, a frame image I(t) at time t-2, -2), frame image I(t-3) at time t-3.
At this time, the motion compensation unit 241 performs motion compensation on the frame image I(t-1) so that the error with the frame image I(t) is minimized. Further, the motion compensation unit 242 performs motion compensation on the frame image I(t-2) so that the error between it and the frame image I(t) is minimized. Furthermore, the motion compensation unit 243 performs motion compensation on frame image I(t-3) so that the error between it and frame image I(t) is minimized. Further, the motion compensator 244 performs motion compensation on frame image I(t-4) so that the error between frame image I(t) and frame image I(t) is minimized.
信号遅延部25は、信号線4を介して入力される発光パターンの制御信号を予め定めたフレームの時間単位で遅延させるものである。ここでは、複数の信号遅延部251,252,253を備え、各信号遅延部25が、制御信号を1フレームに相当する時間遅延させる。この各信号遅延部25における遅延量は、各映像遅延部23の遅延量と同じである。
The
信号遅延部251は、信号線4を介して入力される制御信号を1フレームに相当する時間遅延して、乗算部212と、信号遅延部252とに出力する。
信号遅延部252は、信号遅延部251で遅延された制御信号をさらに1フレームに相当する時間遅延して、乗算部213と、信号遅延部253とに出力する。
信号遅延部253は、信号遅延部252で遅延された制御信号をさらに1フレームに相当する時間遅延して、乗算部214に出力する。
The signal delay section 251 delays the control signal input via the
The signal delay section 252 further delays the control signal delayed by the signal delay section 251 by a time corresponding to one frame, and outputs the delayed control signal to the multiplication section 213 and the signal delay section 253 .
The signal delay section 253 further delays the control signal delayed by the signal delay section 252 by a time corresponding to one frame, and outputs the delayed control signal to the multiplication section 214 .
乗算部21Bは、カメラ3から入力される映像のフレーム画像ごとに、信号線4を介して入力される発光パターンの制御信号を乗算するものである。ここでは、複数の乗算部211,212,213,214を備え、各乗算部21が、順次、遅延された映像に対して、遅延された制御信号を乗算する。なお、乗算部211,212,213,214は、それぞれ、図1で説明した乗算部21と同じ構成である。
The
乗算部211は、時刻tに入力されたフレーム画像I(t)と、制御信号である時間関数wn(t)とを、個々の乗算器M11~M13で乗算する。
乗算器M11は、フレーム画像I(t)と関数w101(t)とを乗算し、乗算結果(図中、〇A)を積算部22Bに出力する。なお、図中の丸で囲んだ文字A,B,…等は、本明細書において、〇A,〇B,…等と記載する。
乗算器M12は、フレーム画像I(t)と関数w102(t)とを乗算し、乗算結果(図中、〇B)を積算部22Bに出力する。
乗算器M13は、フレーム画像I(t)と関数w103(t)とを乗算し、乗算結果(図中、〇C)を積算部22Bに出力する。
The
The multiplier M11 multiplies the frame image I(t) by the function w101 (t), and outputs the multiplication result (○A in the figure) to the
The multiplier M12 multiplies the frame image I(t) by the function w102 (t), and outputs the multiplication result (○B in the figure) to the
The multiplier M13 multiplies the frame image I(t) by the function w103 (t), and outputs the multiplication result (○C in the figure) to the
乗算部212は、時刻t-1に入力されたフレーム画像I(t-1)と、制御信号である時間関数wn(t-1)とを、個々の乗算器M21~M23で乗算する。
乗算器M21は、フレーム画像I(t-1)と関数w101(t-1)とを乗算し、乗算結果(図中、〇D)を積算部22Bに出力する。
乗算器M22は、フレーム画像I(t-1)と関数w102(t-1)とを乗算し、乗算結果(図中、〇E)を積算部22Bに出力する。
乗算器M23は、フレーム画像I(t-1)と関数w103(t-1)とを乗算し、乗算結果(図中、〇F)を積算部22Bに出力する。
The multiplier 212 multiplies the frame image I(t-1) input at time t-1 and the time function w n (t-1), which is a control signal, using individual multipliers M 21 to M 23 . Multiply.
The multiplier M 21 multiplies the frame image I(t-1) by the function w 101 (t-1) and outputs the multiplication result (○D in the figure) to the
The multiplier M 22 multiplies the frame image I(t-1) by the function w 102 (t-1), and outputs the multiplication result (○E in the figure) to the
The multiplier M 23 multiplies the frame image I(t-1) by the function w 103 (t-1), and outputs the multiplication result (○F in the figure) to the
乗算部213は、時刻t-2に入力されたフレーム画像I(t-2)と、制御信号である時間関数wn(t-2)とを、個々の乗算器M31~M33で乗算する。
乗算器M31は、フレーム画像I(t-2)と関数w101(t-2)とを乗算し、乗算結果(図中、〇G)を積算部22Bに出力する。
乗算器M32は、フレーム画像I(t-2)と関数w102(t-2)とを乗算し、乗算結果(図中、〇H)を積算部22Bに出力する。
乗算器M33は、フレーム画像I(t-2)と関数w103(t-2)とを乗算し、乗算結果(図中、〇I)を積算部22Bに出力する。
The multiplier 213 multiplies the frame image I(t-2) input at time t-2 and the time function w n (t-2), which is a control signal, using individual multipliers M 31 to M 33 . Multiply.
The multiplier M 31 multiplies the frame image I(t-2) by the function w 101 (t-2), and outputs the multiplication result (○G in the figure) to the
The multiplier M 32 multiplies the frame image I(t-2) by the function w 102 (t-2) and outputs the multiplication result (○H in the figure) to the
The multiplier M 33 multiplies the frame image I(t-2) by the function w 103 (t-2), and outputs the multiplication result (○I in the figure) to the
乗算部214は、時刻t-3に入力されたフレーム画像I(t-3)と、制御信号である時間関数wn(t-3)とを、個々の乗算器M41~M43で乗算する。
乗算器M41は、フレーム画像I(t-3)と関数w101(t-3)とを乗算し、乗算結果(図中、〇J)を積算部22Bに出力する。
乗算器M42は、フレーム画像I(t-3)と関数w102(t-3)とを乗算し、乗算結果(図中、〇K)を積算部22Bに出力する。
乗算器M43は、フレーム画像I(t-3)と関数w103(t-3)とを乗算し、乗算結果(図中、〇L)を積算部22Bに出力する。
The multiplier 214 multiplies the frame image I(t-3) input at time t-3 and the time function w n (t-3), which is a control signal, using individual multipliers M 41 to M 43 . Multiply.
Multiplier M 41 multiplies frame image I(t-3) by function w 101 (t-3) and outputs the multiplication result (〇J in the figure) to
The multiplier M 42 multiplies the frame image I(t-3) by the function w 102 (t-3), and outputs the multiplication result (○K in the figure) to the
The multiplier M 43 multiplies the frame image I(t-3) by the function w 103 (t-3) and outputs the multiplication result (○L in the figure) to the
積算部22Bは、乗算部21Bで生成された乗算結果に対して、予め定めた時間区間で画素位置ごとに和を演算するである。この積算部22Bは、同じマーカに対応する制御信号を乗算した乗算結果の総和を演算する。ここでは、積算部22Bは、加算部221と、加算部222と、加算部223と、を備える。
The integrating
加算部221は、乗算部211の乗算器M11における乗算結果(〇A)と、乗算部212の乗算器M21における乗算結果(〇D)と、乗算部213の乗算器M31における乗算結果(〇G)と、乗算部214の乗算器M41における乗算結果(〇J)と、を加算するものである。
加算部221は、加算結果を閾値処理部30に出力する。
The adding
The addition section 221 outputs the addition result to the
加算部222は、乗算部211の乗算器M12における乗算結果(〇B)と、乗算部212の乗算器M22における乗算結果(〇E)と、乗算部213の乗算器M32における乗算結果(〇H)と、乗算部214の乗算器M42における乗算結果(〇K)と、を加算するものである。
加算部222は、加算結果を閾値処理部30に出力する。
The adding unit 222 combines the multiplication result (〇B) in the multiplier M12 of the multiplication unit 211 , the multiplication result (〇E) in the multiplier M22 of the
The addition section 222 outputs the addition result to the
加算部223は、乗算部211の乗算器M13における乗算結果(〇C)と、乗算部212の乗算器M23における乗算結果(〇F)と、乗算部213の乗算器M33における乗算結果(〇I)と、乗算部214の乗算器M43における乗算結果(〇L)と、を加算するものである。
加算部223は、加算結果を閾値処理部30に出力する。
これによって、積算部22Bは、図5に示したような発光パターンに対する画素ごとの相関を示す相関画像を生成することができる。
The adding unit 223 combines the multiplication result (○C) in the multiplier M13 of the multiplication unit 211 , the multiplication result (○F) in the multiplier M23 of the multiplication unit 212 , and the multiplication result (○F) in the multiplier M13 of the
The addition section 223 outputs the addition result to the
Thereby, the
以上説明したようにマーカ検出装置2Bを構成することで、マーカ検出装置2Bは、マーカの発光パターンによって、照明が均一でない環境であっても、マーカを検出し、各マーカを識別することができる。さらに、マーカ検出装置2Bは、カメラ3の位置、姿勢および画角が不安定であっても、精度よくマーカを検出し識別することができる。
なお、マーカ検出装置2Bは、コンピュータを、前記した各部として機能させるプログラム(マーカ検出プログラム)で動作させることができる。
By configuring the
Note that the
<第3実施形態>
[マーカ発光装置]
次に、図11を参照して、本発明の第3実施形態に係るマーカ発光装置1Cについて説明する。
第1実施形態、第2実施形態のマーカ発光装置1(図1参照)は、マーカ101~106の点灯または消灯の2つの発光状態を予め定めた発光パターンで制御するものであった。
このマーカは、点灯および消灯以外に、異なる輝度、異なる色、または、それらの組み合わせごとの複数の発光状態で発光パターンを形成してもよい。
ここでは、消灯と3つの異なる色の発光とによって、4状態をとるタイムスロットで発光するマーカを例に説明する。
マーカ発光装置1Cは、消灯と3つの異なる色の発光状態によって、マーカを検出するための発光パターンを発光するものである。
図11に示すように、マーカ発光装置1Cは、発光部10Cと発光制御部11Cとを備える。
<Third embodiment>
[Marker light emitting device]
Next, with reference to FIG. 11, a marker
The marker light emitting device 1 (see FIG. 1) of the first embodiment and the second embodiment controls the two light emitting states of the
In addition to turning on and off, this marker may form a light emitting pattern in a plurality of light emitting states with different brightness, different colors, or a combination thereof.
Here, a marker that emits light in a time slot that takes four states by turning off and emitting light in three different colors will be described as an example.
The marker light-emitting
As shown in FIG. 11, the marker
発光部10Cは、複数(ここでは、36個とする)のマーカ101C,…,136Cを備える。
マーカ101C,…,136Cは、消灯、赤点灯、緑点灯および黄点灯の4つの発光状態を切り替えて光を発光するものである。
The
The
例えば、マーカ101Cは、図12に示すように、赤(R)および緑(G)の発光体を1つの外装に封入した発光素子とする。
赤および緑の発光体をいずれも消灯した場合、マーカ101Cは消灯状態となる。また、赤の発光体のみを点灯した場合、マーカ101Cは赤点灯状態となる。また、緑の発光体のみを点灯した場合、マーカ101Cは緑点灯状態となる。また、赤および緑の発光体をいずれも点灯した場合、マーカ101Cは黄点灯状態となる。
マーカ101C,…,136Cは、発光制御部11Cから出力される制御信号により発光状態を切り替える。
For example, as shown in FIG. 12, the
When both the red and green light emitters are turned off, the
The
発光制御部11Cは、予め定めた発光パターンで、発光部10Cのマーカ101C,…,136Cの発光状態を制御するものである。
ここでは、発光制御部11Cは、2値の値をとる時間関数により、発光パターンを生成する。以下、時間関数をwp
(R)(t),wp
(G)(t)とする。なお、wp
(R)(t)はマーカの赤(R)の発光体を制御する関数であり、wp
(G)(t)はマーカの緑(G)の発光体を制御する関数である。また、pはマーカを区別する符号(ここでは、0~35)であり、tは時刻である。wp
(R)(t),wp
(G)(t)は、それぞれ、“+1(発光)”および“-1(消灯)”の2値をとる。
時間関数wp
(R)(t),wp
(G)(t)を、以下の式(7)で定義する。
The light
Here, the light
The time functions w p (R) (t) and w p (G) (t) are defined by the following equation (7).
式(7)の右辺の関数は、6個の時間関数wq(t)、(q∈{0,1,…,5))であって、例えば、図13に示すウォルシュ関数である。この場合、マーカの赤および緑の発光に対して、それぞれ、6個の発光パターンを生成させることで、計36の状態を表すことができる。 The functions on the right side of equation (7) are six time functions w q (t), (qε{0, 1, . . . , 5)), and are, for example, the Walsh functions shown in FIG. 13. In this case, a total of 36 states can be expressed by generating six light emission patterns for each of the red and green light emission of the marker.
発光制御部11Cは、式(7)に示す時間関数に基づいて発光部10Cを制御するとともに、時間関数に基づいた発光パターンを制御信号として、信号線4を介して、後記するマーカ検出装置2Cに出力する。なお、信号線41は、時間関数wp
(R)(t)に基づいた発光パターンを示す信号を送信する信号線であり、信号線42は、時間関数wp
(G)(t)に基づいた発光パターンを示す信号を送信する信号線である。
これによって、マーカ発光装置1Cは、消灯と3つの異なる色の発光状態によって、36個の発光パターンによるマーカの発光を行うことができる。
The light
As a result, the marker
[マーカ検出装置]
次に、図14を参照して、本発明の第3実施形態に係るマーカ検出装置2Cについて説明する。
マーカ検出装置2Cは、図11で説明したマーカ発光装置1Cが発光するマーカの発光パターンによって、カメラ3Cが撮像したカラー映像から、マーカの位置を検出し識別するものである。
[Marker detection device]
Next, with reference to FIG. 14, a
The
図14に示すように、マーカ検出装置2Cは、相関演算部20(201,202)と、閾値処理部30(301,302)と、論理演算部50と、マーカ座標演算部40と、を備える。
As shown in FIG. 14, the
相関演算部20は、発光パターンの時間区間ごとに、映像のフレーム画像の画素と、発光パターンごとの発光パターンベクトルとの間の相関を演算することで、相関画像を生成するものである。
相関演算部20は、カメラ3が撮像する色チャンネルのうち、2つの色チャンネルに対応して、2つの相関演算部201,202を備える。なお、相関演算部201,202は、それぞれ、入力するフレーム画像の色チャンネルが異なるだけで、図1で説明した相関演算部20と同じものである。なお、相関演算部201,202は、図9で説明した相関演算部20Bで構成してもよい。
The
The
相関演算部201は、カメラ3Cが撮像した映像のうち、赤チャンネルの映像と、赤チャンネルに対応したマーカ発光装置1Cで生成される制御信号とを入力し、相関画像を生成するものである。
ここでは、相関演算部201は、発光パターンの繰り返しの基準である4個のタイムスロットに相当する時間区間ごとに、3個の相関画像を生成する(図5参照)。相関演算部201は、生成した相関画像を閾値処理部301に出力する。
The correlation calculation unit 201 receives the red channel video of the video captured by the
Here, the correlation calculation unit 201 generates three correlation images for each time period corresponding to four time slots, which are the reference for repeating the light emission pattern (see FIG. 5). The correlation calculation unit 201 outputs the generated correlation image to the threshold processing unit 301 .
相関演算部202は、カメラ3Cが撮像した映像のうち、緑チャンネルの映像と、緑チャンネルに対応したマーカ発光装置1Cで生成される制御信号とを入力し、相関画像を生成するものである。
ここでは、相関演算部202は、発光パターンの繰り返しの基準である4個のタイムスロットに相当する時間区間ごとに、3個の相関画像を生成する(図5参照)。相関演算部202は、生成した相関画像を閾値処理部302に出力する。
The correlation calculation unit 202 receives the green channel video of the video captured by the
Here, the correlation calculation unit 202 generates three correlation images for each time interval corresponding to four time slots, which are the reference for repeating the light emission pattern (see FIG. 5). The correlation calculation unit 202 outputs the generated correlation image to the threshold processing unit 302 .
閾値処理部30は、相関演算部20で生成された発光パターンごとの相関画像を予め定めた閾値で二値化することで、マーカとそれ以外の領域とを区分した二値化画像を生成するものである。
閾値処理部30は、相関演算部201,202に対応して、2つの閾値処理部301,302を備える。なお、閾値処理部301,302は、図1で説明した閾値処理部30と同じものである。
The
The
閾値処理部301は、相関演算部201で赤チャンネルの映像から生成された相関画像に対して閾値処理を行うことで、二値化画像を生成するものである。
ここでは、閾値処理部301は、6個の二値化画像を生成する(図6参照)。閾値処理部301は、生成した二値化画像を論理演算部50に出力する。
The threshold processing unit 301 generates a binarized image by performing threshold processing on the correlation image generated from the red channel video by the correlation calculation unit 201 .
Here, the threshold processing unit 301 generates six binarized images (see FIG. 6). The threshold processing section 301 outputs the generated binarized image to the
閾値処理部302は、相関演算部202で緑チャンネルの映像から生成された相関画像に対して閾値処理を行うことで、二値化画像を生成するものである。
ここでは、閾値処理部302は、6個の二値化画像を生成する(図6参照)。閾値処理部302は、生成した二値化画像を論理演算部50に出力する。
The threshold processing unit 302 generates a binarized image by performing threshold processing on the correlation image generated from the green channel video by the correlation calculation unit 202 .
Here, the threshold processing unit 302 generates six binarized images (see FIG. 6). The threshold processing section 302 outputs the generated binarized image to the
論理演算部50は、閾値処理部301で生成された複数の二値化画像と、閾値処理部302で生成された複数の二値化画像との組み合わせにおいて、論理積を演算するものである。
ここでは、論理演算部50は、閾値処理部301で生成された6個の二値化画像と、閾値処理部302で生成された6個の二値化画像との36個の組み合わせで、論理積を演算する。
なお、論理演算部50における論理積は、二値化画像同士の対応する画素位置ごとに画素値の最小値を選択すればよい。
これによって、論理演算部50は、マーカごとに、当該マーカの像のみを抽出した画像を生成することができる。
論理演算部50は、生成した二値化画像(ここでは、36個の二値化画像)を、マーカ座標演算部40に出力する。
The
Here, the
Note that the logical product in the
Thereby, the
The
マーカ座標演算部40は、論理演算部50で生成されたマーカごとの二値化画像から、マーカの画像上の代表点の座標をマーカ座標として算出するものである。
なお、マーカ座標演算部40は、二値化画像の数が異なるだけで、図1で説明したマーカ座標演算部40と同じものである。
これによって、マーカ検出装置2Cは、4個のタイムスロット、4発光状態(消灯状態を含む)、および、6種類の時間関数wq(t) (q∈0,1,…,5)(図13参照)に基づいて、最大で36個のマーカの位置を検出し、識別することができる。
なお、マーカ検出装置2Cは、コンピュータを、前記した各部として機能させるプログラム(マーカ検出プログラム)で動作させることができる。
The marker coordinate
Note that the marker coordinate
As a result, the
Note that the
以上、本発明の実施形態について説明したが、本発明は、これらの実施形態に限定されるものではない。
例えば、ここでは、マーカの発光状態を、点灯および消灯の2種類の状態とした。
しかし、マーカの輝度値に応じて、発光状態を多状態としてもよい。また、色(赤、緑、青、シアン、マゼンタ、黄、白等)および輝度値に応じて、マーカの発光状態を多状態とすることとしてもよい。
その場合、マーカ検出装置2は、カメラ3が撮像するフレーム画像から特定の輝度範囲ごとの画像を生成する、あるいは、カメラ3が撮像するフレーム画像の色チャンネルごとに、特定の輝度範囲ごとの画像を生成する輝度別画像生成部(不図示)を備え、図14で説明したマーカ検出装置2Cの複数の相関演算部20に、輝度範囲ごとの画像を出力することとすればよい。
また、相関演算部20および閾値処理部30は、色チャンネルおよび輝度範囲ごとに、複数備えることとすればよい。
これによって、発光パターンの基準となる時間区間のタイムスロットに多値情報を載せることが可能になり、より多くのマーカを短時間で検出することが可能になる。
Although the embodiments of the present invention have been described above, the present invention is not limited to these embodiments.
For example, here, there are two light-emitting states of the marker: on and off.
However, the light emitting state may be multi-state depending on the luminance value of the marker. Further, the light emitting state of the marker may be set to multiple states depending on the color (red, green, blue, cyan, magenta, yellow, white, etc.) and brightness value.
In that case, the
Furthermore, a plurality of
This makes it possible to place multivalued information in the time slot of the time interval that is the reference of the light emission pattern, and it becomes possible to detect more markers in a short time.
また、ここでは、マーカ発光装置1は、信号線4を介して、発光パターンを制御信号としてマーカ検出装置2に出力することとした。
しかし、図15に示すように、マーカ検出装置2に、マーカ発光装置1の発光制御部11と同じ発光パターンを生成する発光制御部60を備え、発光制御部11と発光制御部60とで、同期して動作する構成としてもよい。
なお、この同期方法は、発光制御部11および発光制御部60のいずれか一方から他方へと有線または無線で同期のための信号を伝送してもよいし、外部に設けた同期用に信号源から同期信号を発光制御部11および発光制御部60に有線または無線により与えてもよい。あるいは、標準電波、ビーコン、測位衛星、天体からの電磁波等に基づいて、発光制御部11および発光制御部60を同期させてもよい。
Further, here, the marker
However, as shown in FIG. 15, the
In this synchronization method, a signal for synchronization may be transmitted from one of the light
1 マーカ発光装置
10,0C 発光部
101,…,106 マーカ
11,11C 発光制御部
2,2B,2C マーカ検出装置
20,20B 相関演算部
21,22B 乗算部
22,22B 積算部
23 映像遅延部
24 動き補償部
25 信号遅延部
30 閾値処理部
31 二値化部
40 マーカ座標演算部
50 論理演算部
60 発光制御部
3,3C カメラ
1 Marker
Claims (10)
前記時間区間ごとに、前記映像のフレーム画像の画素と、前記発光パターンごとの発光パターンベクトルとの間の相関を演算することで前記発光パターンごとの相関画像を生成する相関演算部と、
前記発光パターンごとの相関画像を予め定めた閾値で二値化することで、前記マーカとそれ以外の領域とを区分した二値化画像を生成する閾値処理部と、
前記閾値処理部で生成された二値化画像において、前記マーカの領域の代表点を演算するマーカ座標演算部と、
を備えることを特徴とするマーカ検出装置。 In a time interval of a light emission pattern composed of a plurality of time slots, an inner product of light emission pattern vectors at the same marker indicating a change in the light emission pattern for each time slot is greater than 0, and the inner product between different markers is less than or equal to 0. A marker detection device that detects a plurality of markers from a captured image of a plurality of markers that emit light in a light emission pattern,
a correlation calculation unit that generates a correlation image for each of the light emission patterns by calculating a correlation between pixels of a frame image of the video and a light emission pattern vector for each of the light emission patterns for each of the time intervals;
a threshold processing unit that generates a binarized image in which the marker and other areas are separated by binarizing the correlation image for each of the light emission patterns using a predetermined threshold;
a marker coordinate calculation unit that calculates a representative point of the marker area in the binarized image generated by the threshold processing unit;
A marker detection device comprising:
前記発光パターンごとに、前記映像のフレーム画像の画素値と、前記フレーム画像の時刻に対応して符号が変化する前記発光パターンベクトルの値とを乗算する乗算部と、
前記乗算部で乗算された前記発光パターンごとの乗算結果を前記時間区間ごとに積算して前記相関画像を生成する積算部と、
を備えることを特徴とする請求項1に記載のマーカ検出装置。 The correlation calculation unit is
a multiplication unit that multiplies, for each of the light emission patterns, a pixel value of a frame image of the video by a value of the light emission pattern vector whose sign changes depending on the time of the frame image;
an integrating unit that generates the correlation image by integrating the multiplication results for each of the light emission patterns multiplied by the multiplier for each of the time intervals;
The marker detection device according to claim 1, comprising:
前記映像をフレーム単位で遅延させる映像遅延部と、
前記フレーム画像の時刻に対応して前記発光パターンを示す制御信号を前記フレーム単位で遅延させる信号遅延部と、
現時点のフレーム画像と、前記遅延されたフレーム画像とから映像の動きを推定し、前記遅延されたフレーム画像の動き補償を行う動き補償部と、
前記動き補償されたフレーム画像において、当該フレーム画像の画素の画素値と、当該フレーム画像の時刻に対応して遅延された前記制御信号の値とを乗算する乗算部と、
前記乗算部で乗算された同じ発光パターンに対応する乗算結果を前記時間区間ごとに加算して前記相関画像を生成する積算部と、
を備えることを特徴とする請求項1に記載のマーカ検出装置。 The correlation calculation unit is
a video delay unit that delays the video in units of frames;
a signal delay unit that delays a control signal indicating the light emission pattern in units of the frame in accordance with the time of the frame image;
a motion compensation unit that estimates motion of a video from a current frame image and the delayed frame image, and performs motion compensation for the delayed frame image;
a multiplication unit that multiplies, in the motion-compensated frame image, a pixel value of a pixel of the frame image by a value of the control signal delayed in accordance with a time of the frame image;
an integrating unit that generates the correlation image by adding multiplication results corresponding to the same light emission pattern multiplied by the multiplying unit for each of the time intervals;
The marker detection device according to claim 1, comprising:
複数の前記閾値処理部で生成された二値化画像に対して、論理積演算を行うことで、発光パターンの組み合わせに係る前記マーカの領域を示す二値化画像を生成する論理演算部をさらに備えることを特徴とする請求項1から請求項4のいずれか一項に記載のマーカ検出装置。 A plurality of the correlation calculation units and the threshold processing unit generate the correlation image for each light emission pattern indicating a plurality of light emission states with different brightness, different colors, or a combination thereof, and generate the binarized image. Prepare,
further comprising a logical operation unit that generates a binary image indicating an area of the marker related to a combination of light emission patterns by performing a logical product operation on the binary images generated by the plurality of threshold processing units; The marker detection device according to any one of claims 1 to 4, further comprising: a marker detection device according to claim 4.
前記複数のマーカとなる複数の発光素子を備えた発光部と、
前記マーカごとの発光状態を制御する発光制御部と、を備え、
前記発光制御部は、複数のタイムスロットで構成された発光パターンの時間区間において、前記タイムスロットごとの発光パターンの変化を示す発光パターンベクトルの同一のマーカにおける内積が0より大きく、異なるマーカ間の前記内積が0以下となる発光パターンで前記マーカの発光状態を制御することを特徴とするマーカ発光装置。 A marker light emitting device that emits light from a plurality of markers in a predetermined light emission pattern for each marker,
a light emitting unit including a plurality of light emitting elements serving as the plurality of markers;
and a light emission control unit that controls the light emission state of each marker,
The light emission control unit is arranged such that, in a time interval of a light emission pattern made up of a plurality of time slots, an inner product of light emission pattern vectors at the same marker indicating a change in the light emission pattern for each time slot is greater than 0, and an inner product between different markers is larger than 0. A marker light emitting device, characterized in that the light emitting state of the marker is controlled by a light emitting pattern in which the inner product is 0 or less.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2020000983A JP7377721B2 (en) | 2020-01-07 | 2020-01-07 | Marker detection device and its program, and marker light emitting device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2020000983A JP7377721B2 (en) | 2020-01-07 | 2020-01-07 | Marker detection device and its program, and marker light emitting device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2021110571A JP2021110571A (en) | 2021-08-02 |
| JP7377721B2 true JP7377721B2 (en) | 2023-11-10 |
Family
ID=77059611
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2020000983A Active JP7377721B2 (en) | 2020-01-07 | 2020-01-07 | Marker detection device and its program, and marker light emitting device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP7377721B2 (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2023119338A (en) * | 2022-02-16 | 2023-08-28 | 株式会社メガチップス | Processing system, first processing device and second processing device |
Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2006033329A (en) | 2004-07-15 | 2006-02-02 | Advanced Telecommunication Research Institute International | Optical marker system |
| JP2006030127A (en) | 2004-07-21 | 2006-02-02 | Japan Science & Technology Agency | Camera calibration system and three-dimensional measurement system |
| JP2009033366A (en) | 2007-07-25 | 2009-02-12 | Advanced Telecommunication Research Institute International | Optical marker system |
| JP2014056450A (en) | 2012-09-13 | 2014-03-27 | Casio Comput Co Ltd | Image processing device and program |
-
2020
- 2020-01-07 JP JP2020000983A patent/JP7377721B2/en active Active
Patent Citations (4)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP2006033329A (en) | 2004-07-15 | 2006-02-02 | Advanced Telecommunication Research Institute International | Optical marker system |
| JP2006030127A (en) | 2004-07-21 | 2006-02-02 | Japan Science & Technology Agency | Camera calibration system and three-dimensional measurement system |
| JP2009033366A (en) | 2007-07-25 | 2009-02-12 | Advanced Telecommunication Research Institute International | Optical marker system |
| JP2014056450A (en) | 2012-09-13 | 2014-03-27 | Casio Comput Co Ltd | Image processing device and program |
Also Published As
| Publication number | Publication date |
|---|---|
| JP2021110571A (en) | 2021-08-02 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US12106581B2 (en) | Systems and methods for locating a retroreflective object in a digital image | |
| Chen et al. | A novel visible light positioning system with event-based neuromorphic vision sensor | |
| JP6858650B2 (en) | Image registration method and system | |
| US7054491B2 (en) | Scalable architecture for corresponding multiple video streams at frame rate | |
| CN114964168B (en) | Position information acquisition device, position information acquisition method, and recording medium | |
| KR20110093382A (en) | Depth Estimation Method Using Depth Estimator | |
| EP3577416B1 (en) | System and method for 3d scanning | |
| US9684840B2 (en) | Detection system | |
| WO2019020200A1 (en) | Method and apparatus for accurate real-time visible light positioning | |
| JP2013115497A (en) | Transmission apparatus, and reception apparatus and method | |
| US9705596B2 (en) | Optical communication apparatus, wavelength band estimating apparatus, optical communication method and storage medium | |
| JP7377721B2 (en) | Marker detection device and its program, and marker light emitting device | |
| JP2014186010A (en) | Measuring device, method, and program | |
| CN108781268A (en) | Image processing apparatus and method | |
| US9524696B2 (en) | Image projection device | |
| JP2001330417A (en) | Three-dimensional shape measuring method and apparatus using color pattern light projection | |
| JP2021183990A (en) | Location information acquisition system, location information acquisition device, location information acquisition method and program | |
| KR101021015B1 (en) | 3D user interface method | |
| JP2016082425A (en) | Visible light transmitter, visible light receiver, visible light communication system, visible light communication method and program | |
| CN109756667B (en) | Position acquisition system, position acquisition device, position acquisition method, and recording medium | |
| US20220292693A1 (en) | Image processing device, image processing method, and program | |
| EP4290786A1 (en) | Information exchange using an event camera | |
| US9958958B2 (en) | Interactive projector and method of controlling interactive projector | |
| CN110736965B (en) | Two-dimensional coding and decoding method for visible light positioning | |
| JP7026868B2 (en) | Target tracking device and target tracking method |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20221212 |
|
| A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20230731 |
|
| A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20230829 |
|
| A521 | Request for written amendment filed |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20230919 |
|
| 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: 20231003 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20231030 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 7377721 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |