JP2006227768A - Method and program for character recognition in portable terminal - Google Patents

Method and program for character recognition in portable terminal Download PDF

Info

Publication number
JP2006227768A
JP2006227768A JP2005038565A JP2005038565A JP2006227768A JP 2006227768 A JP2006227768 A JP 2006227768A JP 2005038565 A JP2005038565 A JP 2005038565A JP 2005038565 A JP2005038565 A JP 2005038565A JP 2006227768 A JP2006227768 A JP 2006227768A
Authority
JP
Japan
Prior art keywords
character
reading
character line
area
image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
JP2005038565A
Other languages
Japanese (ja)
Inventor
寿一 ▲高▼橋
Juichi Takahashi
Daisuke Ohashi
乃輔 大橋
Masashi Koga
昌史 古賀
Ryuji Mine
竜治 嶺
Tatsuya Kameyama
達也 亀山
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hitachi Omron Terminal Solutions Corp
Original Assignee
Hitachi Omron Terminal Solutions Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Omron Terminal Solutions Corp filed Critical Hitachi Omron Terminal Solutions Corp
Priority to JP2005038565A priority Critical patent/JP2006227768A/en
Publication of JP2006227768A publication Critical patent/JP2006227768A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Character Input (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To solve the problem to read a character string of a language like Japanese in which columnar writing and lateral writing are mixed in real time with a portable terminal with low CPU performance and limited available memory even if a user does not specify the direction of character string. <P>SOLUTION: An automatic determination means for the character line direction is set up as preprocessing of character recognition in a portable terminal. In the automatic determination means for the character line direction is provided with a reading area extraction means to detect figures, photographs, ruled lines, and blanks and extract an area of images as a reading area excluding the above. A character line direction determination means is also made to perform determination of character line direction in the area extended vertically and horizontally in a prescribed extent centering on the position specified in imaging the character string to be read in order to operate in high speed and saving memory. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、カメラを有する携帯型の端末、および、そのユーザーインターフェース、および、文字認識の技術に関する。   The present invention relates to a portable terminal having a camera, a user interface thereof, and a character recognition technology.

近年、小型の携帯電話やPDA(Personal Digital Assistance)等(以下、これらをまとめて携帯端末と呼ぶ)が広く普及している。携帯端末では、メール作成やアドレス登録、メモ書き、スケジュール登録などで、文字の入力が必要な場合が多い。文字を入力する手段としてキーを用いるのが一般的である。しかし、小型の携帯端末でのキー入力では、キーを何度も押さなければならないため、利用者の負担が大きい。   In recent years, small mobile phones, PDAs (Personal Digital Assistance) and the like (hereinafter collectively referred to as mobile terminals) have become widespread. In mobile terminals, it is often necessary to input characters for e-mail creation, address registration, memo writing, schedule registration, and the like. A key is generally used as a means for inputting characters. However, a key input on a small portable terminal requires a user to press the key many times, which places a heavy burden on the user.

キー入力に代わる手段として、文字認識を利用する方式が特開2003−78640号公報(特許文献1)で述べられている。これは入力したい文字列を付属のカメラで画像として撮り込み、読取りたい文字列を指定して、その文字列を文字認識の技術を用いて読取り、読取った文字列を入力するというものである。   Japanese Patent Laid-Open No. 2003-78640 (Patent Document 1) describes a method using character recognition as a means for replacing key input. In this method, a character string to be input is captured as an image with an attached camera, a character string to be read is designated, the character string is read using a character recognition technique, and the read character string is input.

特開2003−78640号公報 しかし、日本語では縦書きと横書きの両方が用いられる。そのため、文字認識に先立って縦書き文字列を読取るのか横書き文字列を読取るのか、文字列の方向を予め指定する必要があった。However, in Japanese, both vertical writing and horizontal writing are used. Therefore, prior to character recognition, it is necessary to designate in advance the direction of the character string, whether to read a vertically written character string or a horizontally written character string.

上記のように、利用者が文字列の方向を指定しなくても、縦書きと横書きが混在する日本語のような言語の文字列を、CPUの処理能力が低くかつ使用できるメモリが少ない携帯端末でリアルタイムに読取ることが課題である。従来から、文著が縦書きか横書きかを画像から判定する技術はあった。しかし、従来手法では、広範囲の画像を処理する必要があり、メモリ容量や処理能力が限られている携帯端末への適用は困難であった。   As described above, even if the user does not specify the direction of the character string, a character string in a language such as Japanese, in which vertical writing and horizontal writing are mixed, has a low CPU processing capacity and a small amount of memory that can be used. Reading in real time with a terminal is a problem. Conventionally, there has been a technique for determining whether a document is written vertically or horizontally from an image. However, in the conventional method, it is necessary to process a wide range of images, and it has been difficult to apply to a portable terminal with limited memory capacity and processing capability.

上記課題を解決するために、本発明では、携帯端末における文字認識の前処理として文字行方向自動判定手段を設ける。この文字行方向自動判定手段には、図や写真や罫線や空白を検知してこれらを除いた画像の領域を読取領域として抽出する読取領域抽出手段を設ける。   In order to solve the above-described problem, in the present invention, a character line direction automatic determination unit is provided as preprocessing for character recognition in a portable terminal. The automatic character line direction determining means is provided with a reading area extracting means for detecting a figure, a photograph, a ruled line or a blank and extracting an image area excluding these as a reading area.

また、前記文字行方向判定手段は、高速かつ省メモリで動作するように、読取る文字列を撮像する際に指定する位置を中心とした上下左右に所定の範囲で広げた領域で文字行方向判定を行うようにした。指定する位置は、特開2003−78640号公報(特許文献1)に示すように読取る文字列の位置にマーカーを合わせることによって指定される。   Further, the character line direction determining means determines the character line direction in a region that is widened in a predetermined range from the top, bottom, left, and right centering on the position specified when imaging the character string to be read so as to operate at high speed and save memory. To do. The position to be specified is specified by aligning the marker with the position of the character string to be read as shown in Japanese Patent Application Laid-Open No. 2003-78640 (Patent Document 1).

さらに、前記文字行方向自動判定手段は、指定する位置から所定の範囲に広げた領域と前記読取領域抽出手段で抽出した読取領域の一致している領域を用いることで、より使用メモリが少なくなり、処理速度も速くすることができる。   Further, the character line direction automatic determination means uses less area by using an area where the reading area extracted by the reading area extraction means coincides with an area expanded from a designated position to a predetermined range. The processing speed can also be increased.

前記読取領域抽出手段と前記文字行方向自動判定手段を設けることで、CPUの処理能力が低くかつ使用できるメモリが少ない携帯端末で高速かつ省メモリで縦書き横書きが混在する日本語のような言語の文字列をリアルタイムに読取ることができる。   By providing the reading area extracting unit and the automatic character line direction determining unit, a language such as Japanese that has a low CPU processing capacity and a small amount of memory that can be used at a high speed, memory saving, and vertical writing and horizontal writing. Can be read in real time.

本発明によれば、CPUパワーが小さくかつ使用できるメモリが少ない携帯端末で、縦書き横書きの両方が用いられる日本語のような言語の文字列を、読取る文字列の方向を予め設定しなくても、高速かつ省メモリで文字列の方向を自動で判定し、文字列認識することができる。   According to the present invention, a character string in a language such as Japanese that uses both vertical writing and horizontal writing on a portable terminal with low CPU power and a small amount of memory that can be used does not have to set the direction of the character string to be read in advance. However, it is possible to recognize the character string by automatically determining the direction of the character string at a high speed and saving memory.

以下、本発明の実施の形態を図面により詳細に説明する。
図1は本発明を適用した携帯端末の実施の形態を示すデータフローである。本発明のプログラム101は、携帯端末に搭載されたカメラからの画像を入力とし、画像中に写された文書中の単語を読取り、その結果を表示する。読取領域抽出モジュール102は、入力画像を入力して入力画像中の図や写真や罫線や空白の領域を検知して読取る領域のみを抽出して、抽出した領域座標を出力する。文字行方向判定モジュール103は、入力画像と読取領域を入力して文字行が縦書きか横書きかを判定し、その判定結果である縦書きか横書きかの情報を出力する。文字行抽出モジュール104は、入力画像と文字行方向と読取領域座標を入力して文字行を抽出し、その文字行領域を出力する。文字行表示モジュール105は、入力画像と文字行方向と文字行領域を入力しディスプレイに表示する。文字列読取モジュール106は、利用者から入力画像に対して文字行方向および文字行領域が正しいことを確認する入力があった場合は、文字行領域を入力して文字列を認識し、その読取った結果を出力する。ここで、文字行表示モジュール105で表示した文字行方向および文字行領域が利用者の読取りたい文字列であるとき、その文字行に対して文字列認識を行うという指示を利用者が指示する。表示モジュール107は、入力画像と文字列読取結果を入力し、それをディスプレイに表示する。
Hereinafter, embodiments of the present invention will be described in detail with reference to the drawings.
FIG. 1 is a data flow showing an embodiment of a portable terminal to which the present invention is applied. The program 101 of the present invention receives an image from a camera mounted on a portable terminal as input, reads a word in a document copied in the image, and displays the result. The reading area extraction module 102 inputs an input image, detects a figure, a photograph, a ruled line, and a blank area in the input image, extracts only the area to be read, and outputs the extracted area coordinates. The character line direction determination module 103 inputs an input image and a reading area, determines whether the character line is vertical writing or horizontal writing, and outputs information indicating whether the character line is vertical writing or horizontal writing. The character line extraction module 104 extracts the character line by inputting the input image, the character line direction, and the reading area coordinates, and outputs the character line area. The character line display module 105 inputs an input image, a character line direction, and a character line area, and displays them on the display. The character string reading module 106 recognizes a character string by inputting the character line area when the user confirms that the character line direction and the character line area are correct with respect to the input image. Output the result. Here, when the character line direction and the character line area displayed by the character line display module 105 are a character string that the user wants to read, the user instructs an instruction to perform character string recognition on the character line. The display module 107 inputs the input image and the character string reading result and displays them on the display.

図2は、ハードウェアの構成を示すブロック図である。携帯端末201は、読取対象文字列を撮像するカメラ202と本発明のプログラムの処理演算を行うCPU203とカメラ202で撮像した画像、本発明のプログラムおよび文字識別用の辞書および文字列照合用の文字列辞書を記憶するメモリ204と読取対象文字列の表示および文字行抽出結果の表示および文字列認識結果の表示を行うディスプレイ205とカメラ202の撮像の決定および文字行抽出結果の確認および文字列認識結果の確認をプログラムに伝えるボタン206で構成される。   FIG. 2 is a block diagram illustrating a hardware configuration. The portable terminal 201 includes a camera 202 that captures a character string to be read, a CPU 203 that performs processing operations of the program of the present invention, an image captured by the camera 202, a program of the present invention, a character identification dictionary, and a character for character string matching. Memory 204 for storing the column dictionary, display of the character string to be read, display of the character line extraction result, display of the character string recognition result, determination of imaging of the camera 202 and confirmation of the character line extraction result, and character string recognition It consists of a button 206 that conveys the result confirmation to the program.

図3は、図1で示した文字認識プログラムの概略処理手順を示すフローチャートである。画像入力処理301ではカメラ撮像した画像を内部メモリに取り込む。画像表示処理302では画像入力処理301で取り込んだ画像をディスプレイに表示する。読取領域抽出処理303では画像入力処理301で取り込んだ画像から図や写真や罫線や空白を検知してこれらの領域を除いた読取領域のみを抽出する。文字行方向判定処理304では読取領域抽出処理303で抽出した読取領域から文字行が縦書きなのか横書きなのか文字行方向を判定する。   FIG. 3 is a flowchart showing a schematic processing procedure of the character recognition program shown in FIG. In the image input process 301, an image captured by the camera is taken into the internal memory. In the image display process 302, the image captured in the image input process 301 is displayed on the display. In a reading area extraction process 303, a figure, a photograph, a ruled line, or a blank is detected from the image captured in the image input process 301, and only the reading area excluding these areas is extracted. In the character line direction determination process 304, the character line direction is determined from the reading area extracted by the reading area extraction process 303 whether the character line is vertical writing or horizontal writing.

文字行抽出処理305では読取領域抽出処理で抽出した読取領域と文字行方向判定処理304で判定された文字行方向に基づいて文字行を抽出する。文字行領域表示処理306では画像表示処理302で表示した画像に文字行抽出処理305で抽出した文字行領域を矩形でディスプレイに表示する。このとき、縦書きと横書きのどちらの文字行方向なのか明確にするため、縦書きの場合と横書きの場合で文字行領域の矩形の色を変えるとよい。文字行決定判断307では文字行領域表示処理306で表示した文字行領域が利用者の読取りたい文字列であるか否かの入力を受け付け、利用者の読取りたい文字列であれば文字列読取処理307を行う。そうでなければ画像入力処理301へ戻る。文字列読取り処理308では、文字行抽出処理305で抽出した文字行から文字列を読取る。文字行抽出処理305および文字列読取り処理307については、利用者が指定する位置から文字行方向判定処理で判定された文字行方向に基づいて例えば特許文献1に示す方法を用いることで実現できる。読取り結果表示処理309では文字列読取り処理308で読取った文字列をディスプレイに表示する。決定または終了判定310では画像表示処理302で表示した入力画像と読取り文字行表示処理306で表示した文字行領域と文字列読取結果表示処理309で表示した文字列を利用者が確認して読取った文字列を決定または文字認識プログラムの終了を選択した場合に終了とする。そうでない場合は次の画像入力処理301に戻る。   In the character line extraction process 305, a character line is extracted based on the reading area extracted in the reading area extraction process and the character line direction determined in the character line direction determination process 304. In the character line area display process 306, the character line area extracted by the character line extraction process 305 is displayed on the display in the form of a rectangle on the image displayed by the image display process 302. At this time, in order to clarify whether the character line direction is vertical writing or horizontal writing, the color of the rectangle of the character line area may be changed between vertical writing and horizontal writing. In the character line determination judgment 307, an input as to whether or not the character line area displayed in the character line area display process 306 is a character string that the user wants to read is accepted. 307 is performed. Otherwise, the process returns to the image input process 301. In the character string reading process 308, a character string is read from the character line extracted by the character line extraction process 305. The character line extraction process 305 and the character string reading process 307 can be realized by using, for example, the method disclosed in Patent Document 1 based on the character line direction determined by the character line direction determination process from the position specified by the user. In the reading result display process 309, the character string read in the character string reading process 308 is displayed on the display. In the determination or end determination 310, the user confirmed and read the input image displayed in the image display process 302, the character line area displayed in the read character line display process 306, and the character string displayed in the character string read result display process 309. When the character string is determined or the end of the character recognition program is selected, the process ends. Otherwise, the process returns to the next image input process 301.

図4は、読取領域抽出処理の詳細を示す図である。401は入力画像であり、402は読取領域をユーザが指定する際に画像に重ねて表示されるマーカーであり、このマーカーと座標が同一になる部分が読取領域の仮中心として決定される。403のように、入力画像401から図や写真を検出して読取領域から除外する。また、403のように、指定座標側の画像の領域404から罫線405を検出して読取領域から除外する。また、405のように、指定座標側の画像の領域406から空白407を検出して読取領域から除外する。このようにして読取領域408が決定される。なお、読取領域から除外すべき項目としては、上述の総てを利用する必要はなく、また、これ以外の条件を合わせて用いてもよい。   FIG. 4 is a diagram showing details of the reading area extraction processing. Reference numeral 401 denotes an input image, and reference numeral 402 denotes a marker that is displayed so as to be superimposed on the image when the user designates the reading area. A portion having the same coordinates as the marker is determined as a temporary center of the reading area. Like 403, a figure and a photograph are detected from the input image 401, and it excludes from a reading area. Further, as indicated by 403, ruled lines 405 are detected from the area 404 of the image on the designated coordinate side and excluded from the reading area. Also, as indicated by 405, a blank 407 is detected from the image area 406 on the designated coordinate side and excluded from the reading area. In this way, the reading area 408 is determined. Note that it is not necessary to use all the above items to be excluded from the reading area, and other conditions may be used together.

図5は読取領域抽出処理の詳細なデータフローの一例である。図・写真検出501で入力画像から図や写真の領域を検出する。図や写真などを検出は、例えば画素の連結成分の外接矩形を用いて、外接矩形の大きさがある大きさ以上の連結成分を検出すればよい。ただし、指定座標に近い連結成分は図や写真として扱わないとする。罫線検出502では入力画像から図・写真検出501で検出した領域以外の領域において長い罫線を検出する。罫線の検出は、例えば画素の連結成分の外接矩形の縦横比がある大きさ以上である連結成分を検出すればよい。検出した罫線より画像の外側の領域は読取領域外とする。空白検出503では入力画像から図・写真検出で検出された図や写真の領域以外の領域と罫線検出502で検出した罫線の領域以外から空白領域を検出する。ここで、以上の3つの検出は順番が変わってもよいとする。   FIG. 5 is an example of a detailed data flow of the reading area extraction process. A figure / photo detection 501 detects a figure / photo area from the input image. For example, a circumscribed rectangle of a connected component of pixels is used to detect a connected component having a size equal to or larger than a certain size. However, it is assumed that the connected component close to the designated coordinates is not handled as a figure or a photograph. The ruled line detection 502 detects a long ruled line in an area other than the area detected by the figure / photo detection 501 from the input image. The ruled line may be detected by detecting a connected component having a certain aspect ratio or more of the circumscribed rectangle of the connected component of the pixel. The area outside the image from the detected ruled line is outside the reading area. In the blank detection 503, a blank area is detected from an area other than the figure or photograph area detected by the figure / photo detection from the input image and the ruled line area detected by the ruled line detection 502. Here, the order of the above three detections may be changed.

図6は、文字行方向判定処理の詳細なデータフローの一例である。文字行方向判定を高速かつ省メモリで行うために、文字行方向判定用領域限定処理601では、読取位置指定座標から所定の範囲で上下左右の少なくともいずれかの方向に広げた領域を入力画像から取り出す。さらに所定の範囲で上下左右の少なくともいずれかの方向に広げた領域で読取領域の座標の方が読取位置指定座標に近い方の座標については読取領域の座標を用いる。読取位置指定座標から上下左右に広げる所定の範囲としては、入力画像の大きさに対して十分に小さい(全体を処理対象とするのと比較して十分な処理演算量の削減が見込める程度)、一定の割合(例えば4文字程度が3行程度あればよい。取り込む際に10行が画像に入るとして、4文字程度が3行程度の領域であれば、入力画像に対して縦横それぞれ4分の1の大きさ)とすることが考えられる。   FIG. 6 is an example of a detailed data flow of character line direction determination processing. In order to perform character line direction determination at high speed and in a memory-saving manner, in the character line direction determination area limiting process 601, an area widened in a predetermined range from the reading position designation coordinate in at least one of up, down, left, and right directions is input Take out. Further, the coordinates of the reading area are used for the coordinates of the reading area where the coordinates of the reading area are closer to the reading position designation coordinates in an area expanded in at least one of the upper, lower, left and right directions within a predetermined range. The predetermined range extending from the reading position designation coordinate to the top, bottom, left, and right is sufficiently small with respect to the size of the input image (to the extent that a sufficient reduction in the amount of processing computation can be expected as compared with the entire processing target). A certain ratio (for example, about 4 characters should be about 3 lines. If 10 lines are included in the image at the time of importing, if about 4 characters are about 3 lines, the input image will be 4 minutes each vertically and horizontally. 1).

ヒストグラム生成処理602では、文字行方向判定用領域限定処理601で限定された領域について縦方向、および横方向に画素のヒストグラムを生成する。ここで、ヒストグラムの生成には画素でなく連結成分の外接矩形の座標を用いてもよい。その場合は、縦方向のヒストグラムであれば連結成分の外接矩形の高さの値を加算し、横方向のヒストグラムであれば連結成分の外接矩形の幅の値を加算していく。文字行方向判定処理603は、縦および横方向のヒストグラムと指定座標から文字行が縦方向なのか横方向なのかを判定する。   In the histogram generation process 602, pixel histograms are generated in the vertical direction and the horizontal direction for the area limited by the character line direction determination area limiting process 601. Here, the coordinates of the circumscribed rectangle of the connected component instead of the pixel may be used for generating the histogram. In that case, the height value of the circumscribed rectangle of the connected component is added in the case of the histogram in the vertical direction, and the width value of the circumscribed rectangle of the connected component is added in the case of the histogram in the horizontal direction. Character line direction determination processing 603 determines whether a character line is vertical or horizontal from the vertical and horizontal histograms and designated coordinates.

方向の判定の基準は、以下の条件順位に従う。なお、以下の条件の中にあるヒストグラムの谷間とは、ヒストグラム中の値が閾値以下の箇所である。閾値は入力画像中のノイズの多さにより変動する。   The criteria for determining the direction follow the following order of conditions. Note that the valleys of the histogram under the following conditions are locations where the value in the histogram is equal to or less than the threshold value. The threshold varies depending on the amount of noise in the input image.

(1)縦方向のヒストグラムにおける画素の最大値をwMax、横方向のヒストグラムにおける画素の最大値をhMaxとすると、
wMax > hMax × a の時は縦方向文字行 、
hMax > wMax × a の時は横方向文字行 、
とする。ここで、aは任意の値として、例えば1.3とする。
(1) If the maximum pixel value in the vertical histogram is wMax and the maximum pixel value in the horizontal histogram is hMax,
When wMax> hMax × a, vertical text line,
When hMax> wMax × a, horizontal text line,
And Here, a is an arbitrary value, for example, 1.3.

(2)縦方向のヒストグラムの谷間の幅の平均をwWAve、横方向のヒストグラムの谷間の幅の平均をhWAveとすると、
wWAve > hWAve の時は縦方向文字行 、
hWave > wWAve の時は横方向文字行 、
とする。
(2) If the average width of the valleys in the vertical histogram is wWAve and the average width of the valleys in the horizontal histogram is hWAve,
When wWAve> hWAve, vertical text line
When hWave> wWAve, horizontal text line
And

(3)縦方向のヒストグラムの谷間の数をwNum、横方向のヒストグラムの谷間の数をhNumとすると、
wNum < hNum の時は縦方向文字行 、
hNum < wNum の時は横方向文字行 、
ここで、従来手法では、カメラで取り込んだ文書画像全体を文字認識の対象とするため、文書画像全体を段落や段組などのいわゆる文書レイアウトを解析してそれぞれの文字行ごとに方向を判定する必要があるが、本発明で想定する処理では、利用者が指定する文字列のみの方向さえわかればよい。そのため、文書画像全体を解析する必要はなく、読取指定位置付近のみで文字行方向判定を行えばよい。文字行方向の判定には4文字程度の文字行が3行程度あれば十分な精度で文字行方向を判定することができる。入力画像に10行程度の文字行が入るとすると、入力画像の縦横それぞれ4分の1程度の大きさであれば4文字3行程度が入ると考えられる。これにより従来手法よりも、少ないメモリ容量または演算処理能力しか持たない携帯端末においても、文字行方向判定および文字認識を精度よく行うことができる。
(3) When the number of valleys in the vertical histogram is wNum and the number of valleys in the horizontal histogram is hNum,
When wNum <hNum, vertical text line,
When hNum <wNum, horizontal text line,
Here, in the conventional method, since the entire document image captured by the camera is targeted for character recognition, the entire document image is analyzed for a so-called document layout such as a paragraph or a column and the direction is determined for each character line. Although it is necessary, in the process assumed in the present invention, it is only necessary to know the direction of the character string designated by the user. Therefore, it is not necessary to analyze the entire document image, and character line direction determination may be performed only near the reading designated position. For the determination of the character line direction, if there are about three character lines of about four characters, the character line direction can be determined with sufficient accuracy. If there are about 10 character lines in the input image, it is considered that if the size of the input image is about a quarter each, then about 3 lines of 4 characters will be included. As a result, even in a portable terminal having a smaller memory capacity or arithmetic processing capability than in the conventional method, the character line direction determination and the character recognition can be performed with high accuracy.

また、上記条件のいずれでも判定できない場合、文字行方向判定用領域限定処理601に戻り、読取位置指定座標から上下左右の少なくともいずれかに広げる領域をさらに広げて、ヒストグラム生成処理602および文字行方向判定処理603を繰り返す。繰り返す回数はCPUパワーの大きさによって変更する。読取位置指定座標から上下左右の少なくともいずれかに広げる大きさとしては、判定できなかった領域に対して例えば1.5倍程度大きくする。   If neither of the above conditions can be determined, the process returns to the character line direction determination area limiting process 601 to further widen the area extending from the reading position designation coordinate to at least one of up, down, left, and right, and the histogram generation process 602 and the character line direction. The determination process 603 is repeated. The number of repetitions varies depending on the CPU power. The size that extends from the reading position designation coordinate to at least one of up, down, left, and right is about 1.5 times larger than the area that could not be determined.

図7は、図6が示す文字行方向判定処理を示す図である。701は入力画像である。702は読取領域抽出処理で得られた読取領域である。703は利用者が読取りたい文字列を指定した読取文字列指定位置である。704は703で指定した読取文字列の位置から上下左右に一定に広げた文字行判定用限定領域である。705は読取領域702と文字行判定用限定領域704のそれぞれの領域の座標で、読取文字列指定位置703のAND領域である。この705の領域に対してヒストグラムを取る。706は705の領域に対して横方向に画素のヒストグラムを取った結果である。707は705の領域に対して縦方向に画素のヒストグラムを取った結果である。入力画像701においては、ヒストグラム706および707から、図6の603の説明における条件の例えば(2)を用いた結果によると、707の方が平均の谷間の幅が広いため、縦書きであると判定される。   FIG. 7 is a diagram showing the character line direction determination processing shown in FIG. Reference numeral 701 denotes an input image. Reference numeral 702 denotes a reading area obtained by reading area extraction processing. Reference numeral 703 denotes a read character string designation position that designates a character string that the user wants to read. Reference numeral 704 denotes a character line determination limited area that is spread from the position of the read character string designated in 703 to the upper, lower, left, and right sides. Reference numeral 705 denotes the coordinates of the reading area 702 and the character line determination limited area 704, which is an AND area of the reading character string designation position 703. A histogram is taken for the area 705. Reference numeral 706 denotes the result of taking a pixel histogram in the horizontal direction with respect to the area 705. Reference numeral 707 denotes a result of taking a histogram of pixels in the vertical direction with respect to the area 705. In the input image 701, from the histograms 706 and 707, according to the result of using, for example, (2) of the condition in the description of 603 in FIG. Determined.

図8は、縦書きの文字列読取結果の表示例1である。ディスプレイ801に画像と文字行802を表示する。文字列読取の結果表示803は文字行方向判定で縦書きと判断された場合は縦書きに表示する。   FIG. 8 is a display example 1 of a vertically written character string reading result. An image and a character line 802 are displayed on the display 801. The character string reading result display 803 is displayed vertically when it is determined that the character line direction is determined to be vertically written.

図9は、縦書きの文字列読取結果の表示例2である。ディスプレイ901に画像と文字行902を表示する。文字列読取の結果表示903は文字行方向判定で縦書きと判断された場合でも横書きに表示する。また、横書きの文字行読取結果と区別するために、縦書きの文字列読取の場合と横書きの文字列読取の場合で文字行902の色を変える。   FIG. 9 is a display example 2 of the vertically written character string reading result. An image and a character line 902 are displayed on the display 901. The character string reading result display 903 is displayed in horizontal writing even when vertical writing is determined in the character line direction determination. Further, in order to distinguish from the result of reading a horizontally written character line, the color of the character line 902 is changed between the case of reading a vertically written character string and the case of reading a horizontally written character string.

図10は、横書きの文字列読取結果の表示例である。ディスプレイ1001に画像と文字行1002と文字列読取の結果表示1003を表示する。   FIG. 10 is a display example of a horizontally written character string reading result. An image, a character line 1002, and a character string reading result display 1003 are displayed on the display 1001.

本発明のプログラムのデータの流れを示すデータフローである。It is a data flow which shows the data flow of the program of this invention. ハードウェアの構成図である。It is a block diagram of hardware. 図1のプログラムにおける概略処理手順を示すフローチャートである。It is a flowchart which shows the general | schematic process sequence in the program of FIG. 読取領域抽出処理を示す図である。It is a figure which shows the reading area extraction process. 読取領域抽出処理のデータフローの一例である。It is an example of the data flow of reading area extraction processing. 文字行方向判定処理のデータフローの一例である。It is an example of the data flow of a character line direction determination process. 図6が示す文字行方向判定処理を示す図である。It is a figure which shows the character line direction determination process which FIG. 6 shows. 縦書きの文字列読取結果の表示例1である。It is the example 1 of a display of the vertical character string read result. 縦書きの文字列読取結果の表示例2である。It is the example 2 of a display of the vertical character string read result. 横書きの文字列読取結果の表示例である。It is an example of a display of the horizontal character string reading result.

符号の説明Explanation of symbols

102:読取領域抽出モジュール、103文字行方向判定モジュール、104:文字行抽出モジュール、105:文字行表示モジュール、106:文字列読取モジュール、107:処理結果表示モジュール。   102: Reading area extraction module, 103 Character line direction determination module, 104: Character line extraction module, 105: Character line display module, 106: Character string reading module, 107: Processing result display module

Claims (4)

文書画像の電子データを入力するカメラと、該入力された文書画像および該文書画像の処理結果を表示する表示部と、処理演算部とを有する文字認識装置において実行されるプログラムであり、該処理演算部に、
文書の紙面を撮像した文書画像とユーザに指定された読取位置とを入力とし、文書画像中から読取対象領域を抽出するする読取領域抽出処理と、読取対象領域中の文字行の方向を判定する文字行方向判定処理と、文字行方向判定結果にしたがって読取対象領域中から文字行を抽出する文字行抽出処理と、抽出した文字行中の文字を読取る文字列読取処理を実行させ、
前記文字行方向判定処理において、前記ユーザに指定された読取位置の周辺で文字行方向を判定するに十分な領域を抽出して処理を行うことを特徴とする文字認識プログラム。
A program executed in a character recognition device having a camera that inputs electronic data of a document image, a display unit that displays the input document image and a processing result of the document image, and a processing operation unit, In the calculation part,
A document image obtained by capturing a paper surface of a document and a reading position designated by a user are input, and a reading area extraction process for extracting a reading target area from the document image and a direction of a character line in the reading target area are determined. A character line direction determining process, a character line extracting process for extracting a character line from the reading target area according to a character line direction determining result, and a character string reading process for reading a character in the extracted character line;
In the character line direction determination process, a character recognition program for performing processing by extracting an area sufficient for determining a character line direction around a reading position designated by the user.
前記読取対象抽出処理が、画像中の空白部に基づき画像を分割した後、読取位置を含む分割領域を選択することである請求項1の文字認識プログラム。   The character recognition program according to claim 1, wherein the reading target extraction processing is to select a divided region including a reading position after dividing the image based on a blank portion in the image. 前記読取対象抽出処理が、画像中の直線成分で画像を分割後、読取位置を含む分割領域を選択することである請求項1の文字認識プログラム。   The character recognition program according to claim 1, wherein the reading target extraction process is to select a divided region including a reading position after dividing an image by linear components in the image. 請求項1の構成に加えて、文字行抽出結果を文書画像に重ねて表示する文字行抽出結果表示処理を有し、読取指示がない場合には画像入力と読取領域抽出処理と文字行方向判定処理と文字行抽出処理と文字行抽出結果表示を繰り返し、読取指示がある場合には文字列読取処理を実行することを特徴とする文字認識プログラム。   In addition to the configuration of claim 1, the apparatus has a character line extraction result display process for displaying a character line extraction result superimposed on a document image, and when there is no reading instruction, an image input, a reading area extraction process, and a character line direction determination. A character recognition program which repeats processing, character line extraction processing, and character line extraction result display, and executes character string reading processing when there is a reading instruction.
JP2005038565A 2005-02-16 2005-02-16 Method and program for character recognition in portable terminal Pending JP2006227768A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005038565A JP2006227768A (en) 2005-02-16 2005-02-16 Method and program for character recognition in portable terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005038565A JP2006227768A (en) 2005-02-16 2005-02-16 Method and program for character recognition in portable terminal

Publications (1)

Publication Number Publication Date
JP2006227768A true JP2006227768A (en) 2006-08-31

Family

ID=36989123

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005038565A Pending JP2006227768A (en) 2005-02-16 2005-02-16 Method and program for character recognition in portable terminal

Country Status (1)

Country Link
JP (1) JP2006227768A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009070242A (en) * 2007-09-14 2009-04-02 Ricoh Co Ltd Area division method and device, and program
WO2012118332A2 (en) * 2011-03-01 2012-09-07 Seok Sang Ho Hybrid user interface using vertical notation
JP2012226748A (en) * 2011-04-15 2012-11-15 Lg Electronics Inc Network system and control method thereof
WO2013046512A1 (en) * 2011-09-26 2013-04-04 Necカシオモバイルコミュニケーションズ株式会社 Information processing terminal
WO2015122039A1 (en) * 2014-02-12 2015-08-20 シャープ株式会社 Translation device
KR20170128994A (en) * 2016-05-16 2017-11-24 주식회사 케이티 Apparatus and method for spam message filtering
JP2021111394A (en) * 2019-12-30 2021-08-02 ネクストブイピーユー (シャンハイ) カンパニー リミテッド Method and device for recognizing characters subjected to mixed composition, chip circuit and computer program product

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH034386A (en) * 1989-05-31 1991-01-10 Toshiba Corp Optical character reader
JPH03268181A (en) * 1990-03-19 1991-11-28 Fujitsu Ltd Document reader
JPH07121658A (en) * 1993-10-20 1995-05-12 Nippon Digital Kenkyusho:Kk Character string detection system
JPH09128479A (en) * 1995-11-01 1997-05-16 Ricoh Co Ltd Method and device for dividing area
JPH11338971A (en) * 1998-05-28 1999-12-10 Canon Inc Photographing device and method therefor, and storage medium
JP2003078640A (en) * 2001-09-05 2003-03-14 Hitachi Ltd Portable terminal equipment and communication system

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH034386A (en) * 1989-05-31 1991-01-10 Toshiba Corp Optical character reader
JPH03268181A (en) * 1990-03-19 1991-11-28 Fujitsu Ltd Document reader
JPH07121658A (en) * 1993-10-20 1995-05-12 Nippon Digital Kenkyusho:Kk Character string detection system
JPH09128479A (en) * 1995-11-01 1997-05-16 Ricoh Co Ltd Method and device for dividing area
JPH11338971A (en) * 1998-05-28 1999-12-10 Canon Inc Photographing device and method therefor, and storage medium
JP2003078640A (en) * 2001-09-05 2003-03-14 Hitachi Ltd Portable terminal equipment and communication system

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009070242A (en) * 2007-09-14 2009-04-02 Ricoh Co Ltd Area division method and device, and program
WO2012118332A2 (en) * 2011-03-01 2012-09-07 Seok Sang Ho Hybrid user interface using vertical notation
WO2012118332A3 (en) * 2011-03-01 2013-02-07 Seok Sang Ho Hybrid user interface using vertical notation
JP2012226748A (en) * 2011-04-15 2012-11-15 Lg Electronics Inc Network system and control method thereof
US9043033B2 (en) 2011-04-15 2015-05-26 Lg Electronics Inc. Network system and control method thereof
WO2013046512A1 (en) * 2011-09-26 2013-04-04 Necカシオモバイルコミュニケーションズ株式会社 Information processing terminal
WO2015122039A1 (en) * 2014-02-12 2015-08-20 シャープ株式会社 Translation device
JP2015153032A (en) * 2014-02-12 2015-08-24 シャープ株式会社 Translator
CN106415528A (en) * 2014-02-12 2017-02-15 夏普株式会社 Translation device
KR20170128994A (en) * 2016-05-16 2017-11-24 주식회사 케이티 Apparatus and method for spam message filtering
KR102112845B1 (en) * 2016-05-16 2020-05-19 주식회사 케이티 Apparatus and method for spam message filtering
JP2021111394A (en) * 2019-12-30 2021-08-02 ネクストブイピーユー (シャンハイ) カンパニー リミテッド Method and device for recognizing characters subjected to mixed composition, chip circuit and computer program product
JP7097099B2 (en) 2019-12-30 2022-07-07 ネクストブイピーユー (シャンハイ) カンパニー リミテッド Methods, devices, chip circuits and computer program products for recognizing mixed typesetting characters

Similar Documents

Publication Publication Date Title
CN110046529B (en) Two-dimensional code identification method, device and equipment
US7949157B2 (en) Interpreting sign language gestures
JP4761996B2 (en) Character division program, character division device, and character division method
JP2006227768A (en) Method and program for character recognition in portable terminal
US20080205769A1 (en) Apparatus, method and program product for matching with a template
JP2007233871A (en) Image processor, control method for computer, and program
KR20130066819A (en) Apparus and method for character recognition based on photograph image
JP2001266068A (en) Method and device for recognizing table, character- recognizing device, and storage medium for recording table recognizing program
JP5111055B2 (en) Image processing apparatus, image processing method, and computer program
US20060078204A1 (en) Image processing apparatus and method generating binary image from a multilevel image
CN110717060B (en) Image mask filtering method, device and storage medium
JP2016053763A (en) Image processor, image processing method and program
JP5483467B2 (en) Form reader, square mark detection method, and square mark detection program
JP4474231B2 (en) Document link information acquisition system
JP2010191767A (en) Device and method for recognizing character
JP2009025856A (en) Document discrimination program and document discrimination device
US10579896B2 (en) Mark detection system and method
JP2008269131A (en) Image processor and image processing program
JP6521481B2 (en) Image correction apparatus, image correction method, program
US20240153126A1 (en) Automatic image cropping using a reference feature
JP7478628B2 (en) Image processing device, control method, and control program
Elmore et al. A morphological image preprocessing suite for ocr on natural scene images
JP4365619B2 (en) Edge detection device, component recognition device, edge detection method, and component recognition method
JP3517077B2 (en) Pattern extraction device and method for extracting pattern area
JP2008102610A (en) Image processor

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20070613

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20070613

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20100513

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20100518

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20100610

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20101116

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20110607