JP5027201B2 - Telop character area detection method, telop character area detection device, and telop character area detection program - Google Patents
Telop character area detection method, telop character area detection device, and telop character area detection program Download PDFInfo
- Publication number
- JP5027201B2 JP5027201B2 JP2009238845A JP2009238845A JP5027201B2 JP 5027201 B2 JP5027201 B2 JP 5027201B2 JP 2009238845 A JP2009238845 A JP 2009238845A JP 2009238845 A JP2009238845 A JP 2009238845A JP 5027201 B2 JP5027201 B2 JP 5027201B2
- Authority
- JP
- Japan
- Prior art keywords
- telop character
- edge
- color
- character area
- area
- 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 Circuits (AREA)
- Image Analysis (AREA)
Description
本発明は,映像(動画像)または静止画像にテロップ文字があるかどうかを判定し,テロップ文字がある場合には,その領域を自動的に抽出する技術に関するものである。 The present invention relates to a technique for determining whether or not there is a telop character in a video (moving image) or a still image, and if there is a telop character, automatically extracting the area.
動画像のフレームや,静止画像からテロップ文字の領域を抽出する従来技術として,例えば,次のような技術が提案されている。 For example, the following techniques have been proposed as conventional techniques for extracting a telop character region from a moving image frame or a still image.
特許文献1には,映像からテロップ文字が表示されているフレームを検出する技術が開示されており,この技術では,映像のフレームにおいて所定数以上のエッジペアが含まれるブロックが連続した場合に,そのフレームをテロップ文字が表示されているフレームとして検出する。
また,特許文献2には,映像から,動きながら表示される字幕文字を検出する技術が開示されており,この技術では,字幕文字部分に支配的に現れる特徴点として,エッジペア特徴点を検出する。 Patent Document 2 discloses a technique for detecting subtitle characters that are displayed while moving from a video. In this technique, edge pair feature points are detected as feature points that predominantly appear in the subtitle character portion. .
しかし,上記の従来の技術でテロップ検出を行うと,文字領域と判定される矩形領域が正解から少しだけズレてしまうという問題がある。 However, when telop detection is performed by the above-described conventional technique, there is a problem that a rectangular area determined as a character area is slightly shifted from a correct answer.
映像からテロップの出ているフレームを検出するだけなら小さなズレは問題にならないが,文字領域の位置によって番組のヘッドラインテロップなどを判定するような場合には,僅かなズレが検出率を著しく下げてしまうことがある。 Small misalignment is not a problem if only frames with telop are detected from the video, but slight misalignment significantly lowers the detection rate when judging the headline telop of the program based on the position of the character area. May end up.
本発明は,上記の問題点の解決を図り,画像上の文字領域を精度良く検出する技術を提供することを目的とする。 An object of the present invention is to solve the above problems and provide a technique for accurately detecting a character region on an image.
本発明では,上記の課題を解決するために,文字の色に着目して,文字領域の検出を行う。テロップに使われている文字については,グラデーションのような色使いが行われることは稀であり,文字色として同時に使われる色はせいぜい2〜3色程度である。そこで,テロップの文字に使われている色に着目し,その文字色を推定することで,テロップ文字領域を正確に検出する技術を提案する。 In the present invention, in order to solve the above-described problem, the character area is detected by paying attention to the color of the character. For characters used in telops, colors such as gradation are rarely used, and there are at most about two to three colors used simultaneously as character colors. Therefore, we focus on the color used for the telop character and propose a technique for accurately detecting the telop character region by estimating the character color.
本発明の概要は,以下のとおりである。文字はストロークで構成されるので,画像上の文字部分ではエッジ(色の変化点)が発生する。このエッジの密度が所定の閾値以上の領域を対象に,エッジを構成する色の変化点のペアをエッジペアとして取り出し,エッジペアの色が似ているものを集めてグループ化するクラスタリングを行う。通常,文字の色数は多くても2〜3色であるので,同じクラスタリングの色範囲内に入るエッジペアの色のの頻度が高い色がテロップ文字に利用されているとみなして文字色の推定を行い,それをもとにテロップ文字領域を検出する。 The outline of the present invention is as follows. Since characters are composed of strokes, edges (color change points) occur in the character portion of the image. Clustering is performed in which a pair of color change points constituting an edge is taken out as an edge pair for areas where the edge density is equal to or greater than a predetermined threshold, and the edge pairs having similar colors are collected and grouped. Since the number of character colors is usually 2 to 3 at most, the color of the edge pairs that fall within the same clustering color range is considered to be used for telop characters, and the character color is estimated. The telop character area is detected based on the above.
具体的には,本発明は,テロップ文字領域の検出対象となる動画像のフレームまたは静止画像を入力して記憶装置に記憶し,その画像からエッジを抽出し,エッジを構成する色の変化点の対をエッジペアとして検出する。また,その画像からエッジまたはエッジペアが高密度に存在している高密度エッジ領域を抽出し,高密度エッジ領域にあるエッジペアを結ぶ線上の色を抽出して所定のクラスタリング手法により分類する。同一の分類に属する色の数または割合が所定の閾値以上の色を,テロップ文字の色として推定する。推定されたテロップ文字の色から前記画像におけるテロップ文字領域を検出し,その領域を表示または出力する。 Specifically, the present invention inputs a moving image frame or still image to be detected in the telop character area, stores it in a storage device, extracts an edge from the image, and changes the color change points constituting the edge. Are detected as edge pairs. Further, a high-density edge region in which edges or edge pairs are present in high density is extracted from the image, and a color on a line connecting the edge pairs in the high-density edge region is extracted and classified by a predetermined clustering method. A color in which the number or ratio of colors belonging to the same classification is equal to or greater than a predetermined threshold is estimated as a telop character color. A telop character area in the image is detected from the estimated telop character color, and the area is displayed or output.
上記発明において,推定されたテロップ文字の色からテロップ文字領域を検出する際には,推定されたテロップ文字の色を持つ各エッジペアの周囲における所定の範囲内の領域において推定された文字色と同一の分類に属する色を持つ画素をテロップ文字領域候補として記憶し,そのテロップ文字領域候補が占める面積またはその面積の前記所定の範囲内の領域における割合が所定の閾値以上のテロップ文字領域候補を,テロップ文字領域として検出する方法を用いれば,さらに精度のよい検出が可能である。 In the above invention, when detecting the telop character area from the estimated telop character color, the same character color as that estimated in the region within a predetermined range around each edge pair having the estimated telop character color A pixel having a color belonging to the classification is stored as a telop character region candidate, and a telop character region candidate whose area occupied by the telop character region candidate or a ratio of the area within the predetermined range is equal to or greater than a predetermined threshold value, If a method of detecting a telop character area is used, more accurate detection is possible.
本発明によれば,テロップの文字に用いられた色を推定した上でテロップ文字領域を判別するため,テロップ文字領域を厳密に判定できる。また,色のクラスタ分類を行うため,テロップに複数の色が用いられていても,それらのすべてを検出することができる。 According to the present invention, since the telop character area is determined after estimating the color used for the telop character, the telop character area can be determined accurately. Moreover, since the color cluster classification is performed, even if a plurality of colors are used in the telop, all of them can be detected.
以下,本発明の実施の形態について,図を用いて説明する。 Hereinafter, embodiments of the present invention will be described with reference to the drawings.
図1は,本実施の形態によるテロップ文字領域検出装置の構成例を示す図である。テロップ文字領域検出装置10は,例えばCPUとメモリとを有するコンピュータによって構成され,動画像のフレームや静止画像から,テロップ文字領域を抽出する装置であり,コンピュータのハードウェアとソフトウェアプログラム等によって実現される画像入力部11,画像記憶部12,エッジ検出部13,高密度エッジ領域抽出部14,色分類部15,テロップ文字色推定部16,テロップ文字領域検出部17,テロップ文字領域表示部18を備える。
FIG. 1 is a diagram illustrating a configuration example of a telop character area detection apparatus according to the present embodiment. The telop character
画像入力部11は,テロップ文字領域の検出対象である映像(動画像)や静止画像等の画像を入力する。入力された画像は,画像記憶部12に記憶される。
The
エッジ検出部13は,画像記憶部12に記憶された画像から色の変化点であるエッジを検出する。エッジ検出部13におけるエッジペア検出部131は,検出されたエッジの中から,想定される文字の線幅の範囲内で対になっているエッジの組であるエッジペアを検出する。エッジは,画像を構成する画素のうち画素値が局所的に不連続に変化する画素として検出されるが,それらの検出されたエッジの中で,二つのエッジ間の距離がある範囲内にあり,そのエッジ間の輝度変化や彩度変化などの色の変化が小さい場合に,そのエッジの対をエッジペアと呼ぶ。エッジペアは,画像上のテロップ部分に高頻度で現れる。エッジペアの詳細については,特許文献1や特許文献2にも記載されている。
The
高密度エッジ領域抽出部14は,テロップ文字領域の検出対象である画像から,エッジまたはエッジペアが集中する領域である高密度エッジ領域を抽出する。色分類部15は,抽出された高密度エッジ領域内に存在するエッジペア間の色を抽出し,その色を分類(クラスタリング)する。テロップ文字色推定部16は,高密度エッジ領域から抽出された色の分類に基づいて,テロップ文字に用いられている色を推定する。テロップ文字領域検出部17は,推定されたテロップ文字の色からテロップ文字領域を検出する。テロップ文字領域表示部18は,検出されたテロップ文字領域を表示または出力する。テロップ文字領域の出力では,テロップ文字領域に含まれる場合には“1”,含まれない場合には“0”というように2値データとして出力してもよい。
The high-density edge
図2は,本実施の形態によるテロップ文字領域検出処理フローチャートである。画像入力部11から動画像や静止画像などの画像ファイルが入力され,画像記憶部12に記憶される(ステップS10)。なお,以下では,入力画像が静止画像である場合の例を説明するが,動画像についても各フレームについて同様な処理によりテロップ文字領域を検出することができる。
FIG. 2 is a flowchart of telop character area detection processing according to this embodiment. Image files such as moving images and still images are input from the
エッジ検出部13が,画像記憶部12に記憶された画像からエッジと推定される点を検出し,エッジペア検出部131が,エッジの中でエッジ間の色の変化が小さいエッジの対をエッジペアとして検出する(ステップS11)。
The
次に,画像上の各点におけるエッジ密度を算出する(ステップS12)。ここでは,高密度エッジ領域検出部14が,例えば各点を中心とした,ある大きさの長方形内にあるエッジとみなされた点の数をカウントし,長方形の面積(画素数)で割った値をエッジ密度として算出する。
Next, the edge density at each point on the image is calculated (step S12). Here, the high-density edge
次に,算出されたエッジ密度が,所定の閾値以上の点があるかどうかを確かめる(ステップS13)。エッジ密度が所定の閾値以上の点がなければ,テロップ文字はないと判定する(ステップS20)。 Next, it is confirmed whether or not there is a point where the calculated edge density is equal to or greater than a predetermined threshold (step S13). If there is no point whose edge density is equal to or higher than a predetermined threshold, it is determined that there is no telop character (step S20).
エッジ密度が所定の閾値以上の点があれば,閾値以上のエッジ密度である座標の点を高密度エッジ領域とし,高密度エッジ領域内のエッジペア間の色情報を抽出する(ステップS14)。色情報は,RGBの表色系で取り出してもよいし,CIE−Labなどの表色系に変換して取り出してもよい。 If there is a point whose edge density is equal to or higher than a predetermined threshold value, a coordinate point having an edge density equal to or higher than the threshold value is set as a high-density edge region, and color information between edge pairs in the high-density edge region is extracted (step S14). The color information may be extracted in the RGB color system, or may be extracted after being converted into a color system such as CIE-Lab.
次に,色分類部15は,取り出した色を,所定のクラスタリング手法を用いてクラスタリング分類する(ステップS15)。テロップ文字色推定部16は,同一の分類に属する色の数またはその全色数に対する割合が所定の閾値以上の色を,テロップ文字色として推定する(ステップS16)。
Next, the
続いて,テロップ文字領域検出部17は,推定されたテロップ文字色を持つ各エッジペアの周囲における所定の範囲内の領域(例えば長方形領域)において前記推定された色と同一の分類に属する色を持つ画素をテロップ文字領域候補として記憶し,テロップ文字領域候補が占める面積を計測する(ステップS17)。すなわち,所定の範囲内の領域における推定されたテロップ文字色と同じクラスタ内の色を持つ画素数をカウントする。そして,計測した面積またはその面積の前記所定の範囲内の領域における割合が所定の閾値以上かどうかを判定し(ステップS18),所定の閾値以上であれば,そのテロップ文字領域候補を,テロップ文字領域として検出し,テロップ文字領域表示部18によってテロップ文字領域を表示する(ステップS19)。所定の閾値以上となるテロップ文字領域候補がなければ,テロップ文字はないと判定する(ステップS20)。
Subsequently, the telop character
以上の各部の処理内容を,さらに詳しく説明する。 The processing contents of the above units will be described in more detail.
<エッジの検出>
図3は,本実施の形態によるエッジ検出の例を説明する図である。図3(A)は,垂直方向の色変化のチェックにより,画像から縦エッジを検出する例を示し,図3(B)は,水平方向の色変化のチェックにより,画像から横エッジを検出する例を示す。ここでは,画像上で垂直方向に色が変化する点を縦エッジと呼び,画像上で水平方向に色が変化する点を横エッジと呼ぶものとする。
<Edge detection>
FIG. 3 is a diagram for explaining an example of edge detection according to this embodiment. FIG. 3A shows an example in which a vertical edge is detected from an image by checking a color change in the vertical direction, and FIG. 3B detects a horizontal edge from the image by checking a color change in the horizontal direction. An example is shown. Here, the point where the color changes in the vertical direction on the image is called a vertical edge, and the point where the color changes on the image in the horizontal direction is called a horizontal edge.
ここでは,テロップ文字領域の検出対象である画像上の(i,j)座標の画素の色情報を,ベクトル↑c(i,j)で表すものとする。iは画像の水平方向の座標であり,jは画像の垂直方向の座標である。↑c(i,j)は3次元のベクトルであり,RGBの表色系でもよいし,CIE−Labなどの表色系でもよい。 Here, it is assumed that the color information of the pixel at the (i, j) coordinate on the image that is the detection target of the telop character area is represented by the vector ↑ c (i, j). i is the coordinate in the horizontal direction of the image, and j is the coordinate in the vertical direction of the image. ↑ c (i, j) is a three-dimensional vector and may be an RGB color system or a color system such as CIE-Lab.
画像上の座標(i,j)の画素が,縦エッジであるか否かを判定する例を説明する。図3(A)に示すように座標(i,j)の周囲画素の垂直方向の色情報の関係から,式(1) に示す縦エッジ検出関数を用いて,縦エッジ判定の評価値V(i,j)を求める。 An example will be described in which it is determined whether or not the pixel at the coordinates (i, j) on the image is a vertical edge. As shown in FIG. 3A, from the relationship of the color information in the vertical direction of the surrounding pixels at coordinates (i, j), the vertical edge determination evaluation value V ( i, j).
V(i,j)=Vx (i,j)2 +Vy (i,j)2 +Vz (i,j)2 …(1)
式(1) に示す縦エッジ検出関数において,Vx (i,j),Vy (i,j),Vz (i,j)は,それぞれ以下の関数から求められる。
V (i, j) = V x (i, j) 2 + V y (i, j) 2 + V z (i, j) 2 ... (1)
In the vertical edge detection function shown in Expression (1), V x (i, j), V y (i, j), and V z (i, j) are obtained from the following functions, respectively.
Vx (i,j)=cx (i−1,j−1)−cx (i−1,j+1)
+2(cx (i,j−1)−cx (i,j+1))
+cx (i+1,j−1)−cx (i+1,j+1),
Vy (i,j)=cy (i−1,j−1)−cy (i−1,j+1)
+2(cy (i,j−1)−cy (i,j+1))
+cy (i+1,j−1)−cy (i+1,j+1),
Vz (i,j)=cz (i−1,j−1)−cz (i−1,j+1)
+2(cz (i,j−1)−cz (i,j+1))
+cz (i+1,j−1)−cz (i+1,j+1)
なお,x,y,zは,色情報のベクトル↑cの要素を示す。例えば,RGBの表色系においては,cx ,cy ,cz は,それぞれR,G,Bの画素値を示す。
V x (i, j) = c x (i−1, j−1) −c x (i−1, j + 1)
+2 (c x (i, j−1) −c x (i, j + 1))
+ C x (i + 1, j−1) −c x (i + 1, j + 1),
V y (i, j) = c y (i-1, j-1) -c y (i-1, j + 1)
+2 (c y (i, j -1) -c y (i, j + 1))
+ C y (i + 1, j-1) -c y (i + 1, j + 1),
V z (i, j) = c z (i−1, j−1) −c z (i−1, j + 1)
+2 (c z (i, j−1) −c z (i, j + 1))
+ C z (i + 1, j−1) −c z (i + 1, j + 1)
Note that x, y, and z indicate elements of the color information vector ↑ c. For example, in the RGB color system, c x , c y , and c z represent R, G, and B pixel values, respectively.
式(1) から得られる評価値V(i,j)が,所定の閾値threshold _edge以上の点を縦エッジとみなす。 Points whose evaluation value V (i, j) obtained from the equation (1) is equal to or greater than a predetermined threshold threshold_edge are regarded as vertical edges.
横エッジも縦エッジと同様に検出できる。画像上の座標(i,j)の画素が,横エッジであるか否かを判定する例を説明する。図3(B)に示すように座標(i,j)の周囲画素の水平方向の色情報の関係から,式(2) に示す横エッジ検出関数を用いて,横エッジ判定の評価値H(i,j)を求める。 The horizontal edge can be detected in the same manner as the vertical edge. An example will be described in which it is determined whether or not the pixel at the coordinates (i, j) on the image is a horizontal edge. As shown in FIG. 3B, from the relationship of the color information in the horizontal direction of the surrounding pixels at the coordinates (i, j), the horizontal edge determination evaluation value H ( i, j).
H(i,j)=Hx (i,j)2 +Hy (i,j)2 +Hz (i,j)2 …(2)
式(2) に示す横エッジ検出関数において,Hx (i,j),Hy (i,j),Hz (i,j)は,それぞれ以下の関数から求められる。
H (i, j) = H x (i, j) 2 + H y (i, j) 2 + H z (i, j) 2 (2)
In the horizontal edge detection function shown in Expression (2), H x (i, j), H y (i, j), and H z (i, j) are obtained from the following functions, respectively.
Hx (i,j)=cx (i−1,j−1)−cx (i+1,j−1)
+2(cx (i−1,j)−cx (i+1,j))
+cx (i−1,j+1)−cx (i+1,j+1),
Hy (i,j)=cy (i−1,j−1)−cy (i+1,j−1)
+2(cy (i−1,j)−cy (i+1,j))
+cy (i−1,j+1)−cy (i+1,j+1),
Hz (i,j)=cz (i−1,j−1)−cz (i+1,j−1)
+2(cz (i−1,j)−cz (i+1,j))
+cz (i−1,j+1)−cz (i+1,j+1)
式(2) から得られる評価値H(i,j)が,所定の閾値threshold _edge以上の点を横エッジとみなす。
H x (i, j) = c x (i−1, j−1) −c x (i + 1, j−1)
+2 (c x (i−1, j) −c x (i + 1, j))
+ C x (i−1, j + 1) −c x (i + 1, j + 1),
H y (i, j) = c y (i-1, j-1) -c y (i + 1, j-1)
+2 (c y (i-1 , j) -c y (i + 1, j))
+ C y (i-1, j + 1) -c y (i + 1, j + 1),
H z (i, j) = c z (i−1, j−1) −c z (i + 1, j−1)
+2 (c z (i−1, j) −c z (i + 1, j))
+ C z (i−1, j + 1) −c z (i + 1, j + 1)
Points whose evaluation value H (i, j) obtained from Equation (2) is equal to or greater than a predetermined threshold threshold_edge are regarded as horizontal edges.
<エッジペアの検出>
図4は,本実施の形態によるエッジペア検出の例を説明する図である。図4には,テロップ文字領域の検出対象である画像の一部が示されている。図4の例において,ハッチング部分が,画像上のテロップ文字の一部を示す。図4において,細線の丸はエッジ検出により検出された縦エッジの点を示し,太線の丸はエッジ検出により検出された横エッジの点を示す。
<Edge pair detection>
FIG. 4 is a diagram for explaining an example of edge pair detection according to the present embodiment. FIG. 4 shows a part of an image which is a detection target of the telop character area. In the example of FIG. 4, the hatched portion indicates a part of the telop character on the image. In FIG. 4, thin line circles indicate vertical edge points detected by edge detection, and thick line circles indicate horizontal edge points detected by edge detection.
このエッジペアの検出は,次のように行う。テロップ文字の線幅が,あらかじめ設定された所定の閾値threshold _height以下であると想定する。この閾値threshold _height以下のhに対し,縦エッジ判定の評価値V(i,j),V(i,j+h)が共に閾値threshold _edge以上であるような縦エッジの点(i,j),(i,j+h)があるものとする。 This edge pair is detected as follows. It is assumed that the line width of the telop character is equal to or less than a predetermined threshold value threshold_height set in advance. With respect to h below this threshold threshold_height, vertical edge points (i, j), (V, i, j), V (i, j + h) are both equal to or higher than threshold threshold_edge, i, j + h).
このとき,次の式(3) により得られる値が所定の閾値threshold _var を下回るときの,縦エッジの点(i,j)と(i,j+h)とを,縦エッジペアとする。 At this time, the point (i, j) and (i, j + h) of the vertical edge when the value obtained by the following equation (3) falls below a predetermined threshold threshold_var is defined as a vertical edge pair.
式(3) において,Var()は分散を表わす。 In equation (3), Var () represents the variance.
横エッジペアも縦エッジペアと同様に検出できる。図4に示すように,所定の閾値threshold _height以下のhに対し,横エッジ判定の評価値H(i’,j’),H(i’+h,j’)が共に閾値threshold _edge以上であるような横エッジの点(i’,j’),(i’+h,j’)があるものとする。 The horizontal edge pair can be detected in the same manner as the vertical edge pair. As shown in FIG. 4, the evaluation values H (i ′, j ′) and H (i ′ + h, j ′) of the horizontal edge determination are both equal to or greater than the threshold threshold_edge with respect to h equal to or less than the predetermined threshold threshold_height. It is assumed that there are such horizontal edge points (i ′, j ′), (i ′ + h, j ′).
このとき,次の式(4) により得られる値が所定の閾値threshold _var を下回るときの,横エッジの点(i’,j’)と(i’+h,j’)とを,横エッジペアとする。 At this time, the point (i ′, j ′) and (i ′ + h, j ′) of the horizontal edge when the value obtained by the following equation (4) is below the predetermined threshold threshold_var is To do.
このように,2つのエッジ間の色,すなわち2つのエッジを結ぶ線上の色のばらつきが少ないエッジの対が,エッジペアと判定される。 In this way, a pair of edges with little variation in the color between two edges, that is, the color on the line connecting the two edges, is determined as an edge pair.
<高密度エッジ領域の抽出>
図5は,本実施の形態による高密度エッジ領域抽出の例を説明する図である。ここでは,画像上の座標(i,j)の点が高密度エッジ領域の点であるかを判定する例を説明する。
<Extraction of high-density edge region>
FIG. 5 is a diagram for explaining an example of high-density edge region extraction according to the present embodiment. Here, an example will be described in which it is determined whether a point of coordinates (i, j) on the image is a point of a high-density edge region.
図5に示すように,点(i,j)を中心とした縦幅height_dense-box ×横幅width _dense-box の矩形領域を,点(i,j)のエッジ密度の算出領域とする。なお,縦幅height_dense-box および横幅width _dense-box は,あらかじめ設定された定数値である。図5に示すエッジ密度の算出領域から検出されるエッジの数を,そのエッジ密度の算出領域である矩形領域の面積で割った値を,点(i,j)のエッジ密度とする。得られた点(i,j)のエッジ密度の値が所定の閾値threshold _edge-denseを上回っている場合に,点(i,j)を高密度エッジ領域とする。 As shown in FIG. 5, a rectangular area having a height of height_dense-box × width of width_dense-box with the point (i, j) as the center is set as an edge density calculation area of the point (i, j). The vertical width height_dense-box and the horizontal width width_dense-box are preset constant values. The value obtained by dividing the number of edges detected from the edge density calculation area shown in FIG. 5 by the area of the rectangular area that is the edge density calculation area is the edge density of the point (i, j). When the edge density value of the obtained point (i, j) exceeds a predetermined threshold threshold_edge-dense, the point (i, j) is set as a high-density edge region.
なお,エッジ密度の算出領域から検出されるすべてのエッジの数からエッジ密度を求めるのではなく,エッジ密度の算出領域から検出されるエッジペアの数からエッジ密度を求めるようにしてもよい。 Instead of obtaining the edge density from the number of all edges detected from the edge density calculation region, the edge density may be obtained from the number of edge pairs detected from the edge density calculation region.
<色の抽出・クラスタリング>
検出されたすべてのエッジペアに対して,ペアとなる2つのエッジが共に高密度エッジ領域内にある場合に,エッジペアを結ぶ線分上の色の抽出を行う。抽出された色のクラスタリングを行い,文字に使われている色を推定する。
<Color extraction / clustering>
For all the detected edge pairs, when the two edges forming the pair are both in the high-density edge region, the color on the line segment connecting the edge pairs is extracted. The extracted colors are clustered to estimate the colors used in the characters.
エッジペア間の色の抽出では,例えば,エッジペア間の全画素の色の平均値や中間値など,エッジペア間で1つの色を抽出するようにしてもよいし,エッジペア間の全画素の色を1つ1つすべて抽出するようにしてもよい。また,エッジペア間の全画素から数画素の色をサンプリングするようにしてもよい。 In the extraction of colors between edge pairs, for example, one color may be extracted between edge pairs, such as the average value or intermediate value of the colors of all pixels between edge pairs, or the color of all pixels between edge pairs may be 1 You may make it extract all one by one. Further, the color of several pixels may be sampled from all the pixels between the edge pairs.
抽出された色のクラスタリングでは,例えば,色情報がRGBの表色系で得られる場合に,RGBの色情報のままでk−means法(参考文献1参照)などを用いてクラスタリングしてもよい。
〔参考文献1〕:神嶌敏弘(産業技術総合研究所),データマイニング分野のクラスタリング手法(1),人工知能学会誌18巻1号。
In the clustering of the extracted colors, for example, when the color information is obtained in the RGB color system, clustering may be performed using the k-means method (see Reference 1) while maintaining the RGB color information. .
[Reference 1]: Toshihiro Kamisu (National Institute of Advanced Industrial Science and Technology), clustering technique (1) in the field of data mining, Journal of Artificial Intelligence Society Vol.
また,RGBで得られる色情報をLab空間に変換するなどしてもよい(参考文献2参照)。
〔参考文献2〕:大田登,色彩工学,東京電機大学出版局。
In addition, color information obtained by RGB may be converted into Lab space (see Reference 2).
[Reference 2]: Noboru Ota, Color Engineering, Tokyo Denki University Press.
図6は,本実施の形態によるLab空間における色のクラスタリングの例を示す図である。高密度エッジ領域から抽出された色をLab空間に変換し,図6に示すように円柱座標とした上で,クラスタリングを行ってもよい。図6において,点線枠は分類された色のクラスタを示し,点線枠内の丸はそのクラスタに分類された,高密度エッジ領域からエッジペアの色を示す。なお,異なるエッジペアの色が同色であっても,それを1色として分類するのではなく,それぞれを区別して分類する。 FIG. 6 is a diagram illustrating an example of color clustering in the Lab space according to the present embodiment. Clustering may be performed after the color extracted from the high-density edge region is converted into Lab space to form cylindrical coordinates as shown in FIG. In FIG. 6, a dotted line frame indicates a cluster of classified colors, and a circle in the dotted line frame indicates a color of an edge pair from the high-density edge region classified into the cluster. Even if the colors of different edge pairs are the same color, they are not classified as one color, but are classified separately.
エッジペアは,画像上のテロップの領域に特徴的に高頻度で出現するため,エッジペア間から抽出された色をクラスタリングすると,図6に示すような色空間において,テロップの文字に用いられている色が同じ領域に集中する形で現れる。2色の色がテロップの文字に用いられている場合には,図6に示すような色空間において,エッジペア間から抽出された色が集中する領域が2つ出現する。 Since edge pairs appear characteristically in the telop area on the image, if the colors extracted from the edge pairs are clustered, the colors used for the telop characters in the color space shown in FIG. Appear in the same area. When two colors are used for a telop character, two regions in which colors extracted from between edge pairs are concentrated appear in a color space as shown in FIG.
<文字色の推定>
テロップに用いられている文字色の推定では,同一クラスタに分類された色の数をカウントし,カウントされた色の数が所定の閾値threshold _color _count を超えるクラスタを,文字に用いられている色のクラスタであると判定する。なお,色のカウントでは,エッジペアからの色の抽出において同じ色が複数抽出された場合でも,それぞれ別々にカウントする。前述した色のクラスタリング時において,1つのエッジペアから1つの代表色だけを抽出する場合には,カウント対象となる色とエッジペアとは1対1の関係になる。なお,文字に用いられている色のクラスタとして判定されるクラスタが,複数であってもよい。
<Estimation of character color>
In the estimation of the character color used for the telop, the number of colors classified into the same cluster is counted, and the cluster whose number exceeds the predetermined threshold threshold_color_count is used as the color used for the character. It is determined that this is a cluster. Note that the color count is performed separately even when a plurality of the same colors are extracted in the color extraction from the edge pair. When only one representative color is extracted from one edge pair at the time of the color clustering described above, the color to be counted and the edge pair have a one-to-one relationship. Note that there may be a plurality of clusters determined as the color clusters used for the characters.
また,色の数が閾値threshold _color _count を超えるかどうかを判定するのではなく,全クラスタの色の数に対する同一クラスタに分類された色の数の割合が,所定の閾値以上であるかどうかによって,テロップ文字色かどうかを判定するような実施も可能である。 Rather than determining whether the number of colors exceeds the threshold threshold_color_count, the ratio of the number of colors classified into the same cluster to the number of colors of all clusters is determined according to whether the number is equal to or greater than a predetermined threshold. , It is possible to determine whether the color is a telop character color.
<テロップ文字領域の検出>
テロップの文字領域の検出では,高密度エッジ領域にあり,かつその点での色が文字色と認められた色領域にあるときに,その点を文字領域とする。さらに,テロップ文字領域の検出の精度を上げるために,次のような方法を用いることができる。
<Detection of telop character area>
In the detection of the character area of the telop, when the character area is in the high-density edge area and the color at that point is in the color area recognized as the character color, that point is set as the character area. Further, the following method can be used to increase the accuracy of detecting the telop character area.
図7は,本実施の形態によるテロップ文字領域の認定方法を説明する図である。まず,元の画像上で文字色の検索範囲を決定する。ここでは,クラスタリングによってテロップ文字色と推定された色を持つエッジペアの周囲の,あらかじめ定められた大きさの範囲を検索範囲として決定する。例えば,高密度エッジ領域にある各エッジペアを中心にして,縦・横があらかじめ定められたサイズの長方形の範囲を検索範囲として決定する。図7の例では,エッジペアE1に対しては,それを中心とする長方形の検索範囲A1が,また,エッジペアE2に対しては,それを中心とする長方形の検索範囲A2が,テロップ文字領域候補の検索範囲となっている。 FIG. 7 is a diagram for explaining a telop character area recognition method according to this embodiment. First, the character color search range is determined on the original image. Here, a range of a predetermined size around an edge pair having a color estimated as a telop character color by clustering is determined as a search range. For example, a rectangular range having a predetermined vertical and horizontal size around each edge pair in the high-density edge region is determined as a search range. In the example of FIG. 7, a rectangular search range A1 centered on the edge pair E1 and a rectangular search range A2 centered on the edge pair E2 are the telop character area candidates. The search range is.
この各検索範囲の中で,テロップ文字色と推定された色が属するクラスタの色の範囲に入る画素があれば,その画素をテロップ文字領域候補として記憶する。検索範囲内の色を検索し終わった後,そのテロップ文字領域候補の画素数をカウントすることにより,テロップ文字領域候補の面積を計測し,それが所定の閾値以上の面積であれば,テロップ文字領域候補を,テロップ文字領域と認定する。面積が所定の閾値より小さければ,そのテロップ文字領域候補は,テロップ文字領域とは認定しない。この面積の閾値の指定は,所定の定数値でもよいし,また,例えば検索範囲の15%などというように割合を示す値であってもよい。 If there is a pixel that falls within the color range of the cluster to which the color estimated as the telop character color belongs in each search range, that pixel is stored as a telop character region candidate. After searching for the color within the search range, the area of the telop character area candidate is measured by counting the number of pixels of the telop character area candidate. The area candidate is recognized as a telop character area. If the area is smaller than a predetermined threshold, the telop character area candidate is not recognized as a telop character area. The designation of the area threshold may be a predetermined constant value, or may be a value indicating a ratio such as 15% of the search range.
<テロップ文字領域の出力/表示>
以上のテロップ文字領域の検出によって,画像上のテロップ文字領域とそれ以外の領域とを区別することができるので,例えばテロップ文字領域は“1”,それ以外は“0”というような2値化情報を出力する。または,画像上のテロップ文字領域とそれ以外の領域とを区別して表示する。なお,テロップ文字領域を囲む最小の矩形領域を出力または表示するようにしてもよい。
<Output / display of telop character area>
By detecting the telop character area as described above, the telop character area on the image can be distinguished from other areas. For example, the telop character area is binarized to “1” and the other areas are “0”. Output information. Alternatively, the telop character area on the image is displayed separately from the other areas. A minimum rectangular area surrounding the telop character area may be output or displayed.
以上説明した画像上のテロップ文字領域検出の処理は,コンピュータとソフトウェアプログラムとによって実現することができ,そのプログラムをコンピュータ読み取り可能な記録媒体に記録することも,ネットワークを通して提供することも可能である。 The above-described processing for detecting a telop character area on an image can be realized by a computer and a software program, and the program can be recorded on a computer-readable recording medium or provided through a network. .
10 テロップ文字領域検出装置
11 画像入力部
12 画像記憶部
13 エッジ検出部
131 エッジペア検出部
14 高密度エッジ領域抽出部
15 色分類部
16 テロップ文字色推定部
17 テロップ文字領域検出部
18 テロップ文字領域表示部
DESCRIPTION OF
Claims (5)
テロップ文字領域の検出対象となる画像を入力し,記憶装置に記憶する過程と,
前記画像からエッジを抽出し,エッジを構成する色の変化点の対をエッジペアとして検出する過程と,
前記画像から前記エッジまたは前記エッジペアの密度が所定の閾値以上である高密度エッジ領域を抽出する過程と,
前記高密度エッジ領域にある前記エッジペアを結ぶ線上の色を抽出して分類する過程と,
同一の分類に属する色の数またはその全色数に対する割合が所定の閾値以上の色を,テロップ文字の色として推定する過程と,
前記推定されたテロップ文字の色から前記画像におけるテロップ文字領域を検出する過程とを有する
ことを特徴とするテロップ文字領域検出方法。 In a telop character area detection method for detecting a telop character area from an image,
Inputting an image to be detected in the telop character area and storing it in a storage device;
Extracting an edge from the image and detecting a pair of color change points constituting the edge as an edge pair;
Extracting a high-density edge region in which the density of the edge or the edge pair is equal to or higher than a predetermined threshold from the image;
Extracting and classifying a color on a line connecting the edge pairs in the high-density edge region; and
A process of estimating the number of colors belonging to the same classification or the ratio of the number of colors to the total number of colors as a telop character color that exceeds a predetermined threshold;
And a step of detecting a telop character region in the image from the estimated color of the telop character.
前記テロップ文字領域を検出する過程では,
前記推定されたテロップ文字の色を持つ各エッジペアの周囲における所定の範囲内の領域において前記推定された色と同一の分類に属する色を持つ画素をテロップ文字領域候補として記憶し,前記テロップ文字領域候補が占める面積またはその面積の前記所定の範囲内の領域における割合が所定の閾値以上のテロップ文字領域候補を,テロップ文字領域として検出する
ことを特徴とするテロップ文字領域検出方法。 The telop character area detection method according to claim 1,
In the process of detecting the telop character area,
A pixel having a color belonging to the same classification as the estimated color in an area within a predetermined range around each edge pair having the estimated telop character color is stored as a telop character area candidate, and the telop character area A telop character region detection method, wherein a telop character region candidate whose area occupied by a candidate or a ratio of the area in the region within the predetermined range is equal to or greater than a predetermined threshold is detected as a telop character region.
テロップ文字領域の検出対象となる画像を入力し,記憶装置に記憶する手段と,
前記画像からエッジを抽出し,エッジを構成する色の変化点の対をエッジペアとして検出する手段と,
前記画像から前記エッジまたは前記エッジペアの密度が所定の閾値以上である高密度エッジ領域を抽出する手段と,
前記高密度エッジ領域にある前記エッジペアを結ぶ線上の色を抽出して分類する手段と,
同一の分類に属する色の数またはその全色数に対する割合が所定の閾値以上の色を,テロップ文字の色として推定する手段と,
前記推定されたテロップ文字の色から前記画像におけるテロップ文字領域を検出する手段とを備える
ことを特徴とするテロップ文字領域検出装置。 In a telop character area detection device for detecting a telop character area from an image,
Means for inputting an image to be detected in the telop character area and storing it in a storage device;
Means for extracting an edge from the image and detecting a pair of color change points constituting the edge as an edge pair;
Means for extracting from the image a high-density edge region in which the density of the edge or the edge pair is equal to or higher than a predetermined threshold;
Means for extracting and classifying a color on a line connecting the edge pairs in the high-density edge region;
Means for estimating the number of colors belonging to the same classification or a color whose ratio to the total number of colors is equal to or greater than a predetermined threshold as a telop character color;
And a means for detecting a telop character area in the image from the estimated color of the telop character.
前記テロップ文字領域を検出する手段は,
前記推定されたテロップ文字の色を持つ各エッジペアの周囲における所定の範囲内の領域において前記推定された色と同一の分類に属する色を持つ画素をテロップ文字領域候補として記憶し,前記テロップ文字領域候補が占める面積またはその面積の前記所定の範囲内の領域における割合が所定の閾値以上のテロップ文字領域候補を,テロップ文字領域として検出する
ことを特徴とするテロップ文字領域検出装置。 In the telop character area detection device according to claim 3,
The means for detecting the telop character area is:
A pixel having a color belonging to the same classification as the estimated color in an area within a predetermined range around each edge pair having the estimated telop character color is stored as a telop character area candidate, and the telop character area A telop character area detection device, wherein a telop character area candidate whose area occupied by a candidate or a ratio of the area in the area within the predetermined range is equal to or greater than a predetermined threshold is detected as a telop character area.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2009238845A JP5027201B2 (en) | 2009-10-16 | 2009-10-16 | Telop character area detection method, telop character area detection device, and telop character area detection program |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2009238845A JP5027201B2 (en) | 2009-10-16 | 2009-10-16 | Telop character area detection method, telop character area detection device, and telop character area detection program |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JP2011087144A JP2011087144A (en) | 2011-04-28 |
| JP5027201B2 true JP5027201B2 (en) | 2012-09-19 |
Family
ID=44079767
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP2009238845A Active JP5027201B2 (en) | 2009-10-16 | 2009-10-16 | Telop character area detection method, telop character area detection device, and telop character area detection program |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JP5027201B2 (en) |
Families Citing this family (6)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JP5801237B2 (en) | 2012-03-29 | 2015-10-28 | パナソニック株式会社 | Part estimation apparatus, part estimation method, and part estimation program |
| JP5679229B2 (en) * | 2012-08-24 | 2015-03-04 | 楽天株式会社 | Image processing apparatus, image processing method, and program |
| JP5695257B1 (en) * | 2014-07-25 | 2015-04-01 | 楽天株式会社 | Image processing apparatus, image processing method, and image processing program |
| JP6922690B2 (en) * | 2017-11-22 | 2021-08-18 | 富士通株式会社 | Character area extraction program, character area extraction device and character area extraction method |
| CN111783807B (en) * | 2019-04-28 | 2025-02-25 | 北京京东尚科信息技术有限公司 | Image extraction method, device and computer-readable storage medium |
| CN119723551A (en) * | 2024-12-10 | 2025-03-28 | 浙江大学 | A subtitle extraction method and device based on feature mining for barrier-free film production |
-
2009
- 2009-10-16 JP JP2009238845A patent/JP5027201B2/en active Active
Also Published As
| Publication number | Publication date |
|---|---|
| JP2011087144A (en) | 2011-04-28 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US10896349B2 (en) | Text detection method and apparatus, and storage medium | |
| US9430704B2 (en) | Image processing system with layout analysis and method of operation thereof | |
| Pun et al. | Multi-scale noise estimation for image splicing forgery detection | |
| US9311533B2 (en) | Device and method for detecting the presence of a logo in a picture | |
| CN104978567B (en) | Vehicle checking method based on scene classification | |
| CN106683073B (en) | A license plate detection method, camera and server | |
| US10748023B2 (en) | Region-of-interest detection apparatus, region-of-interest detection method, and recording medium | |
| JP5338643B2 (en) | Image feature extraction device, image processing device, and program | |
| CN104573675B (en) | The methods of exhibiting and device of operation image | |
| US8290277B2 (en) | Method and apparatus for setting a lip region for lip reading | |
| CN104298982A (en) | Text recognition method and device | |
| JP5027201B2 (en) | Telop character area detection method, telop character area detection device, and telop character area detection program | |
| US20250209844A1 (en) | Ancient book recognition method and apparatus, storage medium, and device | |
| CN113840135A (en) | Color cast detection method, device, equipment and storage medium | |
| CN111738252A (en) | Method and device for detecting text lines in image and computer system | |
| CN110136174A (en) | A method and device for tracking a target object | |
| CN111028263B (en) | Moving object segmentation method and system based on optical flow color clustering | |
| JP2020017136A (en) | Object detection and recognition apparatus, method, and program | |
| CN107368830B (en) | Text detection method and device and text recognition system | |
| CN110135382B (en) | Human body detection method and device | |
| JP4967045B2 (en) | Background discriminating apparatus, method and program | |
| CN110807792B (en) | Method and electronic device for comparing and tracking objects | |
| JP2016081472A (en) | Image processing apparatus, image processing method, and program | |
| JP5283267B2 (en) | Content identification method and apparatus | |
| CN105930813B (en) | A method of detection composes a piece of writing this under any natural scene |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 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: 20120619 |
|
| A01 | Written decision to grant a patent or to grant a registration (utility model) |
Free format text: JAPANESE INTERMEDIATE CODE: A01 |
|
| A61 | First payment of annual fees (during grant procedure) |
Free format text: JAPANESE INTERMEDIATE CODE: A61 Effective date: 20120621 |
|
| FPAY | Renewal fee payment (event date is renewal date of database) |
Free format text: PAYMENT UNTIL: 20150629 Year of fee payment: 3 |
|
| R150 | Certificate of patent or registration of utility model |
Ref document number: 5027201 Country of ref document: JP Free format text: JAPANESE INTERMEDIATE CODE: R150 Free format text: JAPANESE INTERMEDIATE CODE: R150 |
|
| S531 | Written request for registration of change of domicile |
Free format text: JAPANESE INTERMEDIATE CODE: R313531 |
|
| R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |
|
| S533 | Written request for registration of change of name |
Free format text: JAPANESE INTERMEDIATE CODE: R313533 |
|
| R350 | Written notification of registration of transfer |
Free format text: JAPANESE INTERMEDIATE CODE: R350 |