JP6583923B2 - Camera calibration apparatus, method and program - Google Patents
Camera calibration apparatus, method and program Download PDFInfo
- Publication number
- JP6583923B2 JP6583923B2 JP2016161404A JP2016161404A JP6583923B2 JP 6583923 B2 JP6583923 B2 JP 6583923B2 JP 2016161404 A JP2016161404 A JP 2016161404A JP 2016161404 A JP2016161404 A JP 2016161404A JP 6583923 B2 JP6583923 B2 JP 6583923B2
- Authority
- JP
- Japan
- Prior art keywords
- line
- intersections
- coordinates
- frame
- camera
- 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
- Studio Devices (AREA)
- Image Analysis (AREA)
Description
本発明は、カメラのキャリブレーション技術に関し、特に、野球、サッカーまたはテニスのようなスポーツ映像に対するキャリブレーション技術に関する。 The present invention relates to a camera calibration technique, and more particularly to a calibration technique for sports images such as baseball, soccer, or tennis.
カメラキャリブレーション(以下、単にキャリブレーションと呼ぶ)は、3Dコンピュータビジョンにおいて非常に重要な技術であり、現実シーンのワールド座標系(以下、実座標系と呼ぶ)とカメラ画像のピクセル座標系(以下、カメラ座標系と呼ぶ。)との関係は、カメラに固有の内部パラメータ及び外部パラメータ(あるいはホモグラフィ行列)に基づいて求められる。特に、スポーツ映像における自由視点でのナビゲーションでは、実際のフィールド上での各選手の位置が重要であり、カメラ画像における各選手の座標をホモグラフィ行列で射影変換することで求められる。したがって、正確なキャリブレーションを自動で行える技術が、自由視点ナビゲーションやビデオ分析のリアルタイムアプリケーションにおいて必要とされる。 Camera calibration (hereinafter simply referred to as calibration) is a very important technology in 3D computer vision, and is based on the world coordinate system of the real scene (hereinafter referred to as the real coordinate system) and the pixel coordinate system of the camera image (hereinafter referred to as the real coordinate system). The relationship with the camera coordinate system is obtained based on the internal parameters and external parameters (or homography matrix) unique to the camera. In particular, in navigation from a free viewpoint in a sports video, the position of each player on the actual field is important, and can be obtained by projective transformation of the coordinates of each player in the camera image using a homography matrix. Therefore, a technology capable of automatically performing accurate calibration is required for real-time applications such as free viewpoint navigation and video analysis.
なお、あるフレームのホモグラフィ行列は、既知である少なくとも4点の実座標と、当該少なくとも4点の実座標に対応する、当該フレームでのカメラ座標が分かれば求めることができる。ここで、非特許文献1は、サッカーフィールドのペネルティエリアやゴールエリア等を示す2つの直交するラインの交点に基づきホモグラフィ行列を求める構成を開示している。 A homography matrix of a certain frame can be obtained if at least four known real coordinates and the camera coordinates corresponding to the at least four real coordinates are known. Here, Non-Patent Document 1 discloses a configuration for obtaining a homography matrix based on the intersection of two orthogonal lines indicating a penalty area, a goal area, or the like of a soccer field.
しかしながら、非特許文献1の構成では、映像を構成するフレームの内、直交する2つのラインの交点が少なくとも4つ存在するフレームに対してはホモグラフィ行列を求めることができるが、その他のフレームについてはホモグラフィ行列を求めることができない。 However, in the configuration of Non-Patent Document 1, a homography matrix can be obtained for a frame in which there are at least four intersections of two orthogonal lines among the frames constituting the video. Cannot find a homography matrix.
本発明は、ホモグラフィ行列を算出できるフレームの数を、従来技術より多くできるキャリブレーション装置、方法及びプログラムを提供するものである。 The present invention provides a calibration apparatus, method, and program capable of increasing the number of frames from which a homography matrix can be calculated as compared with the prior art.
本発明の一側面によると、スポーツ・フィールドの円状ラインの少なくとも一部と、前記円状ラインと交差し、かつ、前記円状ラインの中心を通る直線状ラインの少なくとも一部を含むフレームから、当該フレームに対するホモグラフィ行列を求めるキャリブレーション装置は、前記直線状ラインと前記円状ラインとの2つの第1交点の実座標と、前記直線状ラインと直交し、かつ、前記円状ラインの中心を通る第1仮想直線と、前記円状ラインとの2つの第2交点の実座標と、を保持する保持手段と、前記フレームからライン部分を判定してラインを示すライン画像を生成する生成手段と、前記ライン画像から前記2つの第1交点のカメラ座標と、前記2つの第2交点のカメラ座標を判定する判定手段と、前記2つの第1交点の実座標及びカメラ座標と、前記2つの第2交点の実座標及びカメラ座標と、に基づき前記フレームのホモグラフィ行列を算出する算出手段と、を備えていることを特徴とする。 According to one aspect of the invention, from a frame including at least a portion of a circular line of a sports field and at least a portion of a straight line that intersects the circular line and passes through the center of the circular line. The calibration apparatus for obtaining a homography matrix for the frame includes the real coordinates of the two first intersections of the linear line and the circular line, and the orthogonal line of the circular line that is orthogonal to the linear line. A holding means for holding a first virtual straight line passing through the center and real coordinates of two second intersections of the circular line, and generating a line image indicating a line by determining a line portion from the frame Means for determining the camera coordinates of the two first intersections from the line image, the determination means for determining the camera coordinates of the two second intersections, the actual coordinates of the two first intersections, and And camera coordinates, characterized in that it comprises the two real coordinates and camera coordinates of the second intersection, and a calculating means for calculating a homography matrix of the frame based on.
本発明によると、従来技術より多くのフレームについてホモグラフィ行列を算出することができる。 According to the present invention, a homography matrix can be calculated for more frames than in the prior art.
以下、本発明の例示的な実施形態についてサッカーの映像を例にして説明する。なお、以下の実施形態は例示であり、本発明を実施形態の内容に限定するものではない。また、以下の各図においては、実施形態の説明に必要ではない構成要素については図から省略する。 Hereinafter, an exemplary embodiment of the present invention will be described using a soccer video as an example. In addition, the following embodiment is an illustration and does not limit this invention to the content of embodiment. In the following drawings, components that are not necessary for the description of the embodiments are omitted from the drawings.
<第一実施形態>
図1は、サッカーフィールドを示している。本実施形態によるキャリブレーション装置は、図1の黒丸、白丸、網掛をした丸の実座標を示す情報を保持している。また、フィールドにひかれたラインを実座標系で特定できる情報も保持している。なお、黒丸は、フィールド上に引かれた2つのラインの交点である。また、白丸は、フィールド上に引かれた2つのラインの交点ではないが、あるラインを伸ばした場合における他のラインとの交点を示している。なお、図1においては、あるラインを伸ばした部分を点線で示している。つまり、点線は、フィールド上に実際にひかれたラインではない。また、網掛をした丸は、センターラインと直交し、かつ、センターサークルの中心を通る直線とセンターサークルの交点を示している。
<First embodiment>
FIG. 1 shows a soccer field. The calibration apparatus according to the present embodiment holds information indicating the actual coordinates of the black circle, white circle, and shaded circle in FIG. It also holds information that can identify the line drawn in the field in the real coordinate system. A black circle is an intersection of two lines drawn on the field. A white circle is not an intersection of two lines drawn on the field, but indicates an intersection with another line when a certain line is extended. In FIG. 1, a portion obtained by extending a certain line is indicated by a dotted line. That is, the dotted line is not a line actually drawn on the field. A shaded circle indicates the intersection of a straight line passing through the center of the center circle and the center circle.
図2は、本実施形態によるキャリブレーション装置が実行するキャリブレーション方法のフローチャートである。なお、図2は1つのフレームに対する処理を示し、実際には、映像内の全フレームに渡り図2の処理は繰り返される。まず、S10において、フィールドの色とフィールド上のラインの色との違いに基づきフィールド上のライン部分を抽出する。一例として、フレームの、例えば、中央付近の所定領域内の各画素の色値の平均値を求める。そして、フレーム内の各画素について、平均値との色値の差が閾値以上ある画素を前景画素とし、それ以外の画素を背景画素(フィールドを示す画素)とする。そして、前景画素を例えば、画素値255(白色)で示し、背景画素を画素値0で示すマスク画像を生成する。通常、ライン及びフィールド上の選手に対応する画素が前景画素として得られる。続いて、ライン部分を強調するため、例えば、メディアンフィルタをマスク画像に適用し、フィルタ適用前後のマスク画像の差分を取ることでライン部分を示すライン画像を抽出することができる。なお、ライン画像にはフィールド上の選手によるノイズが現れるが、この部分は、ライン上に連続する画素とはならないため影響はない。なお、ライン画像の生成方法は、上述した例に限定されず、その他の公知の方法を使用できる。例えば、ラインの色は、通常、フィールドの色とは異なるため、ラインの色に基づきライン画像を抽出することもできる。また、上記例では、フレームの所定領域内の各画素の色値の平均値をフィールドの色値とし、平均値との差が少ない色値の画素をフィールドの画素としていたが、平均値の代わりに予め求めた固定的な値を使用することができる。なお、ライン画像とは、ラインに対応する画素と、それ以外の画素を2値で示す2値画像である。 FIG. 2 is a flowchart of a calibration method executed by the calibration apparatus according to the present embodiment. Note that FIG. 2 shows processing for one frame. Actually, the processing of FIG. 2 is repeated over all frames in the video. First, in S10, a line portion on the field is extracted based on the difference between the field color and the line color on the field. As an example, the average value of the color values of each pixel in a predetermined area near the center of the frame is obtained. For each pixel in the frame, a pixel whose color value difference from the average value is greater than or equal to a threshold value is a foreground pixel, and the other pixels are background pixels (pixels indicating a field). Then, for example, a mask image in which the foreground pixel is indicated by a pixel value 255 (white) and the background pixel is indicated by a pixel value 0 is generated. Usually, pixels corresponding to players on the line and field are obtained as foreground pixels. Subsequently, in order to emphasize the line portion, for example, a median filter is applied to the mask image, and a line image indicating the line portion can be extracted by taking a difference between the mask images before and after applying the filter. Note that although noise due to players on the field appears in the line image, this portion has no effect because it is not a continuous pixel on the line. The line image generation method is not limited to the above-described example, and other known methods can be used. For example, since the line color is usually different from the field color, a line image can be extracted based on the line color. In the above example, the average value of the color values of each pixel in the predetermined area of the frame is used as the field color value, and the pixel having a color value with a small difference from the average value is used as the field pixel. A fixed value obtained in advance can be used. Note that the line image is a binary image in which pixels corresponding to the line and other pixels are expressed in binary.
図3は、ライン画像の一例であり、黒色部分がラインとして抽出された画素(以下、ライン画素と呼ぶ)を示している。なお、ノイズは選手に起因するものである。また、図3に示す様に、フィールド上の各ラインには、所々にライン画素として検出されない箇所が存在する。キャリブレーション装置は、直線又は曲線状に連続するライン画素を1つのグループとする。図3の例では、グループ40〜49が、それぞれ、1つのグループとして検出される。なお、選手に起因するノイズは直線や曲線状とはならないため除外される。そして、キャリブレーション装置は、グループ内のライン画素の連続する方向から、直線を構成するグループと、曲線を構成するグループに分類する。そして、直線を構成するグループについては、ライン画素の連続する方向と、その位置から、さらに、同じラインを示すグループを判定する。つまり、図3の例では、ライン画素のグループ40〜42が1つの連続する直線の部分であり、ライン画素のグループ43〜45が1つの連続する直線の部分であり、ライン画素のグループ46〜49が1つの連続する円の部分であると判定することができる。これにより、キャリブレーション装置は、実際にはラインであるが、ライン画素として抽出されなかった部分を補間して、処理対象のフレーム内に写っているフィールドのラインを復元することができる。つまり、例えば、図3のセンターサークルは、4箇所で途切れているが、途切れている部分をライン画素に置き換えて、フレーム上では楕円状に見えるセンターサークルを示す様にライン画像を変更することができる。なお、選手に起因するノイズをラインに属するグループと誤判定することを避けるため、所定数以上の画素が直線又は曲線状に繋がっているグループのみを検出して、同じラインのグループか否かを判定する構成であっても良い。
FIG. 3 is an example of a line image, and illustrates a pixel from which a black portion is extracted as a line (hereinafter referred to as a line pixel). Noise is caused by players. As shown in FIG. 3, each line on the field has a portion that is not detected as a line pixel in some places. The calibration apparatus groups line pixels that are continuous in a straight line or curved line into one group. In the example of FIG. 3, each of the
図2に戻り、キャリブレーション装置は、S11で、ライン画像がゴール付近の画像であり、直交する2つのラインの交点が少なくとも4つ存在するかを判定する。なお、図1に示す様に、直交する2つのラインの総ての交点の実座標は既知である。直交する2つのラインの交点が少なくとも4つ存在すると、キャリブレーション装置は、S12で、非特許文献1に記載の構成により処理対象フレームのホモグラフィ行列を算出する。例えば、ゴールエリアを示すラインの4つの頂点がライン画像に存在すると、この4つの頂点の実座標とライン画像におけるカメラ座標に基づきホモグラフィ行列を算出することができる。なお、フレーム内の交点が、実座標系のどの交点に対応するかはライン画像が示すラインと、図1にて説明したフィールドにひかれたラインを実座標系で特定できる情報との比較により特定することができる。 Returning to FIG. 2, in S11, the calibration apparatus determines whether the line image is an image near the goal and there are at least four intersections of two orthogonal lines. As shown in FIG. 1, the actual coordinates of all intersections of two orthogonal lines are known. If there are at least four intersections of two orthogonal lines, the calibration apparatus calculates a homography matrix of the processing target frame with the configuration described in Non-Patent Document 1 in S12. For example, if four vertices of a line indicating the goal area exist in the line image, a homography matrix can be calculated based on the actual coordinates of the four vertices and the camera coordinates in the line image. Note that the intersection in the frame corresponds to the intersection in the real coordinate system by comparing the line indicated by the line image with the information that can identify the line drawn in the field described in FIG. 1 in the real coordinate system. can do.
一方、S11で、少なくとも4つの交点がライン画像に存在しないと、キャリブレーション装置は、S12で、センターサークル及びセンターラインがライン画像内にあるかを判定する。なお、センターサークル及びセンターラインの総てがライン画像内にある必要はなく、それぞれの部分が存在すれば良い。なお、サッカーフィールドにおいて曲線は、センターサークルと、ペナルティアークのみであり、ペナルティアーク付近のフレームと、センターサークル付近のフレームでは、フレーム内のラインの数等が異なるため、ライン画像の曲線がセンターサークルであるかペナルティアークであるかを判別することができる。センターサークル及びセンターラインがライン画像内にあると、キャリブレーション装置は、S14でセンターサークルに基づくホモグラフィ行列の算出を行う。一方、S13で、センターサークル及びセンターラインがライン画像内ないと、キャリブレーション装置は、S15で、当該処理対象フレームについてはホモグラフィ行列を算出できないことを記録して、処理を終了する。なお、ホモグラフィ行列を算出できないフレームについては、公知の別の方法により、個別にホモグラフィ行列を算出する必要がある。したがって、キャリブレーション装置は、記録したホモグラフィ行列を算出できなかったフレームを示す情報、例えば、フレーム番号等をユーザに表示・通知する。 On the other hand, if at least four intersections do not exist in the line image in S11, the calibration apparatus determines in S12 whether the center circle and the center line are in the line image. Note that the center circle and the center line do not have to be in the line image, and each portion only needs to exist. In the soccer field, the curve is only the center circle and penalty arc. The number of lines in the frame differs between the frame near the penalty arc and the frame near the center circle. Or a penalty arc can be discriminated. If the center circle and the center line are in the line image, the calibration apparatus calculates a homography matrix based on the center circle in S14. On the other hand, if the center circle and the center line are not included in the line image in S13, the calibration apparatus records in S15 that the homography matrix cannot be calculated for the processing target frame, and ends the process. For frames for which a homography matrix cannot be calculated, it is necessary to calculate the homography matrix individually by another known method. Therefore, the calibration apparatus displays / notifies the user of information indicating a frame for which the recorded homography matrix could not be calculated, for example, a frame number.
図4は、S14における処理を示すフローチャートである。本実施形態では、ライン画像にセンターサークル及びセンターラインが写っている場合、図5(A)及び(B)に示す様に、センターサークルとセンターラインの交点51及び52と、センターラインと直交し、かつ、センターサークルの中心を通る仮想直線62とセンターサークルとの交点53及び54の計4つの交点を使用してホモグラフィ行列を算出する。なお、交点51〜54の実座標は上述した様に既知である。したがって、交点51〜54のカメラ座標が分かればホモグラフィ行列を算出することができる。
FIG. 4 is a flowchart showing the processing in S14. In this embodiment, when the center circle and the center line are shown in the line image, as shown in FIGS. 5A and 5B, the
このため、キャリブレーション装置は、まず、S20で、交点51及び52のカメラ座標を判定する。交点51及び52がライン画像内に存在するのであれば、交点51及び52のカメラ座標はライン画像から直ちに求めることができる。一方、交点51及び52の両方、或いは、いずれか一方がライン画像内に存在しないと、キャリブレーション装置は、以下に説明する様に計算により交点51及び52のカメラ座標を求める。
For this reason, the calibration apparatus first determines the camera coordinates of the
センターサークルは円であるが、通常、フレーム内においては図5(B)に示す様に楕円状になる。したがって、センターサークルは、カメラ座標系において、
ax2+bxy+cy2+dx+ey+f=0
で表される。また、フレーム内においてセンターラインは斜線となり、
(x−g)/h=(y−i)/k
で表される。キャリブレーション装置は、ライン画像内のセンターサークル及びセンターラインに基づき未知数a〜kを求め、これにより交点51及び52のカメラ座標を求める。
Although the center circle is a circle, it is usually elliptical in the frame as shown in FIG. Therefore, the center circle in the camera coordinate system
ax 2 + bxy + cy 2 + dx + ey + f = 0
It is represented by Also, the center line is shaded in the frame,
(X−g) / h = (y−i) / k
It is represented by The calibration apparatus obtains the unknowns a to k based on the center circle and the center line in the line image, and thereby obtains the camera coordinates of the
一方、交点53及び交点54は、仮想直線62とセンターサークルの交点である。本実施形態において、キャリブレーション装置は、まず、図6に示す様に、仮想直線63を設定し、仮想直線63とセンターサークルの2つの交点71及び72のカメラ座標を判定する。図6に示す様に、仮想直線63は、仮想直線62の方向とは異なり、よって、交点71及び72は、交点53及び54に一致していない。しかしながら、キャリブレーション装置は、交点71及び72の実座標が、保持している交点53及び54の実座標であるものとしてホモグラフィ行列を算出する。キャリブレーション装置は、仮想直線63の方向を所定範囲内にて移動させながら上記処理を繰り返し、仮想直線63の方向毎のホモグラフィ行列をS21で算出する。なお、所定範囲は、センターラインの方向に基づき決定することができる。より詳しくは、フレームにおけるセンターラインを示す方程式の傾きを基準に、所定の範囲内の傾きの仮想直線63をそれぞれ求めて交点71及び72のカメラ座標を求める構成とすることができる。
On the other hand, the
キャリブレーション装置は、S22において、S21で求めた仮想直線63の方向毎のホモグラフィ行列から最良のものを選択する。なお、この最良のものは、仮想直線63の方向が仮想直線62の方向に一番近いものとなる。つまり、交点71と交点53や、交点72と交点54の差が最も小さいときのホモグラフィ行列である。このため、キャリブレーション装置は、図1に示す交点の実座標を使用する。具体的には、図1に示す交点の実座標を、S21で求めた1つのホモグラフィ行列で変換してカメラ座標を求める。そして、変換後のカメラ座標がライン画像内にあるものについて、変換後のカメラ座標を中心とした所定半径の円内にあるライン画素の数をそれぞれ求める。所定半径の円内にあるライン画素の数が閾値以上であるものについては評価値を1として、そうでなければ評価値を−1として、変換後のカメラ座標がライン画像内にある交点総ての評価値の合計値又は平均値を求める。そして、S21で求めたホモグラフィ行列それぞれについて求めた評価値の合計値又は平均値を比較し、評価値の合計値又は平均値が最大となるものを最良のホモグラフィ行列として選択する。
In S22, the calibration apparatus selects the best one from the homography matrix for each direction of the virtual
以上の構成によりたとえ直交する2つのラインの交点を4つ得ることができないセンターサークル付近のみが写っているフレームに対してもホモグラフィ行列を求めることができる。したがって、非特許文献1の発明と比較して、より多くのフレームについてのホモグラフィ行列を算出することができる。 With the above configuration, a homography matrix can be obtained even for a frame in which only the vicinity of the center circle in which four intersecting points of two orthogonal lines cannot be obtained. Therefore, compared to the invention of Non-Patent Document 1, a homography matrix for more frames can be calculated.
図7は、本実施形態によるキャリブレーション装置の構成図である。交点実座標保持部15は、図1に示す既知の交点の座標や、ラインを示す情報を保持している。ライン判定部11は、映像のフレームからライン部分を判定してライン画像を生成する。判定部12は、ライン画像において、直交する2つのラインの交点が4つ以上あるか否かを判定する。4つ以上あると、判定部12は、ライン画像を第1ホモグラフィ行列判定部13に出力する。第1ホモグラフィ行列判定部13は、交点実座標保持部15が保持する実座標と、ライン画像上の4つ以上の交点に基づき処理対象フレームのホモグラフィ行列を算出する。また、判定部12は、ライン画像において、直交する2つのラインの交点が4つ以上ないと、センターサークル及びセンターラインがライン画像内にあるかを判定する。センターサークル及びセンターラインの両方、又は、いずれか一方がないと、判定部12は、処理対象フレームのフレーム番号を記録部16に記録する。なお、フレーム番号は、各機能ブロックにおいて既知であるものとする。また、センターサークル及びセンターラインがライン画像内にあると、ライン画像を第2ホモグラフィ行列判定部14に出力する。
FIG. 7 is a configuration diagram of the calibration apparatus according to the present embodiment. The intersection actual coordinate holding
図8は、第2ホモグラフィ行列判定部14の構成図である。第1交点検出部141は、図5の交点51及び52のカメラ座標を検出する。なお、交点51及び52の内、ライン画像内にあるものについては、そのカメラ座標は、ライン画像の当該交点の座標である。一方、交点51及び52の内、ライン画像内にないものについては、楕円を示す方程式と直線を示す方程式をライン画像内の、センターサークルに対応する曲線部分と、センターラインに対応する直線部分から求めて交点のカメラ座標を求める。第1交点検出部141は、求めた交点51及び52のカメラ座標を行列算出部143に出力する。
FIG. 8 is a configuration diagram of the second homography
第2交点検出部142は、図5の交点53及び54のカメラ座標を推定する。なお、図6を用いて説明した様に、第2交点検出部142は、交点53及び54の推定位置として、交点71及び交点72のカメラ座標の組を複数個求める。そして、求めた複数の組のカメラ座標を行列算出部143に出力する。行列算出部143は、交点51及び52のカメラ座標と、交点53及び54の推定位置(交点71及び72)のカメラ座標と、これらの実座標に基づきホモグラフィ行列を算出して検証部144に出力する。なお、ホモグラフィ行列は、交点53及び54の推定位置の組それぞれについて求め、よって、複数のホモグラフィ行列が検証部144に出力される。
The second
検証部144は、交点実座標保持部15が保持する実座標を各ホモグラフィ行列で変換し、ライン画像のラインの位置と比較する。例えば、交点実座標保持部15が保持する交点を基準点とし、各基準点の実座標を各ホモグラフィ行列で変換して基準点のカメラ座標を求める。そして、ライン画像内に位置する各基準点について、所定範囲内にライン画素が存在するか否かを判定する。これは、例えば、基準点を中心とする所定半径内のライン画素の数が閾値以上であるか否かにより判定できる。そして、所定範囲内にラインが存在する基準点については第1評価値を付与し、それ以外の基準点には、第1評価値より低い第2評価値を付与する。そして、ホモグラフィ行列それぞれについて、基準点の評価値の合計値又は平均値を求め、評価値の合計値又は平均値の最も高いホモグラフィ行列を選択して、処理対象フレームのホモグラフィ行列として出力する。
The
<その他の実施形態>
以下、第一実施形態の変形例について説明する。第一実施形態では、仮想直線63の方向を所定範囲内で変更しながら交点71及び72の組を複数求め、それぞれについてのホモグラフィ行列を計算した上で、最良のものを選択していた。しかしながら、センターライン61を示すカメラ座標での方程式に基づき仮想直線62の方程式を算出し、仮想直線62の方程式とセンターサークルを示す方程式に基づき交点53及び54のカメラ座標を算出する構成とすることもできる。この場合、図8の検証部144で行う検証処理は必要ない。また、ライン画像にサイドラインが含まれる場合、仮想直線62は、サイドラインと並行であるため、このサイドラインを並行移動させることで、仮想直線62の方程式を求めることもできる。なお、サッカーのフィールドを用いて上記実施形態を説明したが、センターサークルと、センターサークルと交差するラインとを含むフィールドであれば良く、本発明は、サッカーの映像に限定されない。
<Other embodiments>
Hereinafter, modified examples of the first embodiment will be described. In the first embodiment, a plurality of sets of
なお、本発明によるキャリブレーション装置は、コンピュータを上記キャリブレーション装置として動作させるプログラムにより実現することができる。これらコンピュータプログラムは、コンピュータが読み取り可能な記憶媒体に記憶されて、又は、ネットワーク経由で配布が可能なものである。 The calibration apparatus according to the present invention can be realized by a program that causes a computer to operate as the calibration apparatus. These computer programs can be stored in a computer-readable storage medium or distributed via a network.
11:ライン判定部、12:判定部、14:第2ホモグラフィ行列判定部、15:交点実座標保持部 11: line determination unit, 12: determination unit, 14: second homography matrix determination unit, 15: intersection actual coordinate holding unit
Claims (12)
前記直線状ラインと前記円状ラインとの2つの第1交点の実座標と、前記直線状ラインと直交し、かつ、前記円状ラインの中心を通る第1仮想直線と、前記円状ラインとの2つの第2交点の実座標と、を保持する保持手段と、
前記フレームからライン部分を判定してラインを示すライン画像を生成する生成手段と、
前記ライン画像から前記2つの第1交点のカメラ座標と、前記2つの第2交点のカメラ座標を判定する判定手段と、
前記2つの第1交点の実座標及びカメラ座標と、前記2つの第2交点の実座標及びカメラ座標と、に基づき前記フレームのホモグラフィ行列を算出する算出手段と、
を備えていることを特徴とするキャリブレーション装置。 From a frame including at least a part of a circular line of a sports field and at least a part of a straight line that intersects the circular line and passes through the center of the circular line, a homography matrix for the frame is obtained. A calibration device to be obtained,
Real coordinates of two first intersections of the linear line and the circular line, a first imaginary straight line orthogonal to the linear line and passing through the center of the circular line, and the circular line Holding means for holding the real coordinates of the two second intersections of
Generating means for determining a line portion from the frame and generating a line image indicating the line;
Determination means for determining the camera coordinates of the two first intersections and the camera coordinates of the two second intersections from the line image;
Calculation means for calculating a homography matrix of the frame based on real coordinates and camera coordinates of the two first intersections, and real coordinates and camera coordinates of the two second intersections;
A calibration apparatus comprising:
前記直線状ラインと前記円状ラインとの2つの第1交点の実座標と、前記直線状ラインと直交し、かつ、前記円状ラインの中心を通る第1仮想直線と、前記円状ラインとの2つの第2交点の実座標と、を保持する保持手段と、
前記フレームからライン部分を判定してラインを示すライン画像を生成する生成手段と、
前記ライン画像から前記2つの第1交点のカメラ座標を判定する判定手段と、
前記ライン画像から前記2つの第2交点のカメラ座標の候補の組を複数推定する推定手段と、
前記推定手段が推定した候補の組それぞれについて、前記2つの第1交点の実座標及びカメラ座標と、前記2つの第2交点の実座標と、前記候補の組の2つのカメラ座標と、に基づきホモグラフィ行列を算出する算出手段と、
前記推定手段が推定した候補の組それぞれについて前記算出手段が算出したホモグラフィ行列から、前記フレームに対するホモグラフィ行列を選択する選択手段と、
を備えていることを特徴とするキャリブレーション装置。 From a frame including at least a part of a circular line of a sports field and at least a part of a straight line that intersects the circular line and passes through the center of the circular line, a homography matrix for the frame is obtained. A calibration device to be obtained,
Real coordinates of two first intersections of the linear line and the circular line, a first imaginary straight line orthogonal to the linear line and passing through the center of the circular line, and the circular line Holding means for holding the real coordinates of the two second intersections of
Generating means for determining a line portion from the frame and generating a line image indicating the line;
Determination means for determining camera coordinates of the two first intersections from the line image;
Estimating means for estimating a plurality of sets of candidate camera coordinates of the two second intersections from the line image;
For each candidate set estimated by the estimation means, based on the real coordinates and camera coordinates of the two first intersections, the real coordinates of the two second intersections, and the two camera coordinates of the candidate set A calculating means for calculating a homography matrix;
Selection means for selecting a homography matrix for the frame from the homography matrix calculated by the calculation means for each set of candidates estimated by the estimation means;
A calibration apparatus comprising:
前記選択手段は、前記算出手段が算出したホモグラフィ行列それぞれにより基準点の座標をカメラ座標に変換し、変換後のカメラ座標と前記ライン画像が示すラインとの距離に基づき、前記算出手段が算出したホモグラフィ行列から前記フレームに対するホモグラフィ行列を選択することを特徴とする請求項5に記載のキャリブレーション装置。 The holding means holds real coordinates of a plurality of reference points of the sports field,
The selection means converts the coordinates of the reference point into camera coordinates by each of the homography matrices calculated by the calculation means, and the calculation means calculates based on the distance between the converted camera coordinates and the line indicated by the line image. 6. The calibration apparatus according to claim 5, wherein a homography matrix for the frame is selected from the homography matrix.
前記推定手段は、前記第1方程式に基づき前記フレームのカメラ座標系において前記第1仮想直線を示す第3方程式を複数推定し、前記第3方程式と前記第1方程式の2つの交点のカメラ座標を、前記2つの第2交点のカメラ座標の候補の組とすることを特徴とする請求項5又は6に記載のキャリブレーション装置。 The determination means obtains a first equation indicating the circular line in the camera coordinate system of the frame from at least a part of the circular line included in the line image, and determines the linear line included in the line image. A second equation indicating the linear line in at least a part of the camera coordinate system of the frame is obtained, and based on the first equation and the second equation, camera coordinates of a first intersection not included in the line image are obtained. Judgment,
The estimation means estimates a plurality of third equations indicating the first virtual line in the camera coordinate system of the frame based on the first equation, and calculates camera coordinates of two intersections of the third equation and the first equation. The calibration apparatus according to claim 5, wherein a set of candidate camera coordinates of the two second intersections is used.
前記キャリブレーション方法は、
前記フレームからライン部分を判定してラインを示すライン画像を生成する生成ステップと、
前記ライン画像から前記2つの第1交点のカメラ座標と、前記2つの第2交点のカメラ座標を判定する判定ステップと、
前記2つの第1交点の実座標及びカメラ座標と、前記2つの第2交点の実座標及びカメラ座標と、に基づき前記フレームのホモグラフィ行列を算出する算出ステップと、
を含むことを特徴とするキャリブレーション方法。 From a frame including at least a part of a circular line of a sports field and at least a part of a straight line that intersects the circular line and passes through the center of the circular line, a homography matrix for the frame is obtained. A calibration method in a calibration device to be calculated, wherein the calibration device is orthogonal to the actual coordinates of the two first intersections of the linear line and the circular line, and the linear line Holding a first imaginary straight line passing through the center of the circular line and real coordinates of two second intersections of the circular line;
The calibration method is:
A generation step of determining a line portion from the frame and generating a line image indicating the line;
A determination step of determining the camera coordinates of the two first intersections and the camera coordinates of the two second intersections from the line image;
A calculation step of calculating a homography matrix of the frame based on real coordinates and camera coordinates of the two first intersections, and real coordinates and camera coordinates of the two second intersections;
A calibration method comprising:
前記キャリブレーション方法は、
前記フレームからライン部分を判定してラインを示すライン画像を生成する生成ステップと、
前記ライン画像から前記2つの第1交点のカメラ座標を判定する判定ステップと、
前記ライン画像から前記2つの第2交点のカメラ座標の候補の組を複数推定する推定ステップと、
推定した候補の組それぞれについて、前記2つの第1交点の実座標及びカメラ座標と、前記2つの第2交点の実座標と、前記候補の組の2つのカメラ座標と、に基づきホモグラフィ行列を算出する算出ステップと、
前記候補の組それぞれについて算出したホモグラフィ行列から、前記フレームに対するホモグラフィ行列を選択する選択ステップと、
を含むことを特徴とするキャリブレーション方法。 From a frame including at least a part of a circular line of a sports field and at least a part of a straight line that intersects the circular line and passes through the center of the circular line, a homography matrix for the frame is obtained. A calibration method in a calibration device to be calculated, wherein the calibration device is orthogonal to the actual coordinates of the two first intersections of the linear line and the circular line, and the linear line Holding a first imaginary straight line passing through the center of the circular line and real coordinates of two second intersections of the circular line;
The calibration method is:
A generation step of determining a line portion from the frame and generating a line image indicating the line;
A determination step of determining camera coordinates of the two first intersections from the line image;
An estimation step of estimating a plurality of sets of candidate camera coordinates of the two second intersections from the line image;
For each of the estimated candidate sets, a homography matrix is calculated based on the real coordinates and camera coordinates of the two first intersection points, the real coordinates of the two second intersection points, and the two camera coordinates of the candidate set. A calculating step for calculating;
A selection step of selecting a homography matrix for the frame from the homography matrix calculated for each of the candidate sets;
A calibration method comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2016161404A JP6583923B2 (en) | 2016-08-19 | 2016-08-19 | Camera calibration apparatus, method and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2016161404A JP6583923B2 (en) | 2016-08-19 | 2016-08-19 | Camera calibration apparatus, method and program |
Publications (2)
Publication Number | Publication Date |
---|---|
JP2018028864A JP2018028864A (en) | 2018-02-22 |
JP6583923B2 true JP6583923B2 (en) | 2019-10-02 |
Family
ID=61249070
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2016161404A Active JP6583923B2 (en) | 2016-08-19 | 2016-08-19 | Camera calibration apparatus, method and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP6583923B2 (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110567469B (en) | 2018-06-05 | 2021-07-20 | 北京市商汤科技开发有限公司 | Visual positioning method and device, electronic equipment and system |
US11140328B2 (en) | 2019-01-22 | 2021-10-05 | Tempus Ex Machina, Inc. | Systems and methods for partitioning a video feed to segment live player activity |
CN111179357B (en) * | 2019-12-30 | 2023-09-29 | 南京航空航天大学 | Large-view-field camera calibration method based on plane target combination |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2009122510A1 (en) * | 2008-03-31 | 2009-10-08 | 堺市 | Computer graphics image displaying system and method |
US8553982B2 (en) * | 2009-12-23 | 2013-10-08 | Intel Corporation | Model-based play field registration |
JP2012054914A (en) * | 2010-08-03 | 2012-03-15 | Kddi Corp | Camera parameter calibration device and program |
US20120180084A1 (en) * | 2011-01-12 | 2012-07-12 | Futurewei Technologies, Inc. | Method and Apparatus for Video Insertion |
-
2016
- 2016-08-19 JP JP2016161404A patent/JP6583923B2/en active Active
Also Published As
Publication number | Publication date |
---|---|
JP2018028864A (en) | 2018-02-22 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108475433B (en) | Method and system for large scale determination of RGBD camera poses | |
JP4663966B2 (en) | Method and apparatus for tracking an object from a video signal | |
JP6351238B2 (en) | Image processing apparatus, imaging apparatus, and distance correction method | |
US10762649B2 (en) | Methods and systems for providing selective disparity refinement | |
JP6503906B2 (en) | Image processing apparatus, image processing method and image processing program | |
JP2019075156A (en) | Method, circuit, device, and system for registering and tracking multifactorial image characteristic and code executable by related computer | |
US10818018B2 (en) | Image processing apparatus, image processing method, and non-transitory computer-readable storage medium | |
TWI500904B (en) | Stereo camera and automatic range finding method for measuring a distance between stereo camera and reference plane | |
KR20140045854A (en) | Method and apparatus for monitoring video for estimating gradient of single object | |
JP6583923B2 (en) | Camera calibration apparatus, method and program | |
KR20120065063A (en) | System and method for measuring flight information of a spheric object with a high-speed stereo camera | |
WO2016031573A1 (en) | Image-processing device, image-processing method, program, and recording medium | |
US8164633B2 (en) | Calibration apparatus and method for imaging devices and computer program | |
WO2019123554A1 (en) | Image processing device, image processing method, and recording medium | |
JP7334058B2 (en) | Geometric parameter estimation device, geometric parameter estimation system, geometric parameter estimation method, and computer program | |
JP6395429B2 (en) | Image processing apparatus, control method thereof, and storage medium | |
JP4836065B2 (en) | Edge tracking method and computer program therefor | |
JP6798609B2 (en) | Video analysis device, video analysis method and program | |
JP7334516B2 (en) | Three-dimensional shape model generation device, three-dimensional shape model generation method, and program | |
JP2004046464A (en) | Apparatus and method for estimating three-dimensional position of mobile object, program, and recording medium thereof | |
JP6489654B2 (en) | Camera calibration apparatus, method and program | |
TW202226158A (en) | Apparatus and method for processing a depth map | |
WO2020184006A1 (en) | Image processing device, image processing method, and non-transitory computer-readable medium | |
WO2020196520A1 (en) | Method, system and computer readable media for object detection coverage estimation | |
JPWO2017209213A1 (en) | Image processing apparatus, image processing method, and program |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20170202 |
|
RD03 | Notification of appointment of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7423 Effective date: 20170206 |
|
RD04 | Notification of resignation of power of attorney |
Free format text: JAPANESE INTERMEDIATE CODE: A7424 Effective date: 20170202 |
|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20181009 |
|
A977 | Report on retrieval |
Free format text: JAPANESE INTERMEDIATE CODE: A971007 Effective date: 20190813 |
|
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: 20190828 |
|
A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20190829 |
|
R150 | Certificate of patent or registration of utility model |
Ref document number: 6583923 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 |