JP2014109810A - Information processing apparatus and information processing program - Google Patents

Information processing apparatus and information processing program Download PDF

Info

Publication number
JP2014109810A
JP2014109810A JP2012262621A JP2012262621A JP2014109810A JP 2014109810 A JP2014109810 A JP 2014109810A JP 2012262621 A JP2012262621 A JP 2012262621A JP 2012262621 A JP2012262621 A JP 2012262621A JP 2014109810 A JP2014109810 A JP 2014109810A
Authority
JP
Japan
Prior art keywords
character
character string
node
nodes
candidate
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
JP2012262621A
Other languages
Japanese (ja)
Inventor
Shunichi Kimura
俊一 木村
Eiichi Tanaka
瑛一 田中
Kosuke Maruyama
耕輔 丸山
Takuya Sakurai
拓也 桜井
Masanori Sekino
雅則 関野
Motoyuki Takaai
基行 鷹合
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.)
Fujifilm Business Innovation Corp
Original Assignee
Fuji Xerox Co Ltd
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 Fuji Xerox Co Ltd filed Critical Fuji Xerox Co Ltd
Priority to JP2012262621A priority Critical patent/JP2014109810A/en
Publication of JP2014109810A publication Critical patent/JP2014109810A/en
Pending legal-status Critical Current

Links

Images

Landscapes

  • Character Discrimination (AREA)

Abstract

PROBLEM TO BE SOLVED: To provide an information processing apparatus which outputs a character recognition result faster than a conventional apparatus when selecting the character recognition result out of a plurality of candidates for the character recognition result and outputting the character recognition result.SOLUTION: First generation means of an information processing apparatus generates a set of character strings of one or more characters from the head or tail of a predetermined first character pattern, and second generation means generates a second character string pattern from the set. Network construction means regards respective characters of a plurality of character recognition results as nodes and connecting nodes of adjacent character images by links to construct a network, limiting means limits nodes connected from one of the head direction and tail direction in the network to nodes matching the second character string pattern and then to nodes matching the first character string pattern, and output means outputs a character candidate string in a path constructed by the limited nodes as a character recognition result.

Description

本発明は、情報処理装置及び情報処理プログラムに関する。   The present invention relates to an information processing apparatus and an information processing program.

特許文献1には、都道府県又は市町村の名称を予め記憶した記憶テーブルと、所望の住所の読みを1字毎に入力するためのキー入力手段と、このキー入力手段によって入力された名称を表示するための表示手段と、前記キー入力手段によって入力された字を、順次、前記記憶テーブルに記憶された複数の名称の読みの先頭から数文字と比較し、一致する名称が1つになったときに、残余の文字のキー入力を待たずに、記憶テーブルに記憶されている当該名称を前記表示手段に表示する制御手段とを備えた住所入力装置が開示されている。   Patent Document 1 displays a storage table in which names of prefectures or municipalities are stored in advance, a key input unit for inputting a desired address reading for each character, and a name input by the key input unit. The characters input by the display means and the key input means are sequentially compared with several characters from the beginning of the readings of a plurality of names stored in the storage table, and one matching name is obtained. Sometimes, an address input device is disclosed that includes control means for displaying the name stored in a storage table on the display means without waiting for key input of the remaining characters.

特許文献2には、書式制御情報(FC)の字種の指定に正規表現を使用することにより詳細な指定を可能にして、認識率を向上させることを目的とし、用紙に記録された文字等を読取るために参照される書式制御情報を記憶するためのものであって、書式制御情報中の文字種を指定する情報が正規表現で表されているFC部と、FC部に記憶された書式制御情報中の正規表現を解析する正規表現解析部と、正規表現解析部による解析結果に基づいて認識辞書中の使用する辞書を選択する字種制御部と、字種制御部によって選択された辞書を用いて用紙に記録された文字等のパターンと照合し読取り結果を求める照合部を備えていることが開示されている。   Japanese Patent Laid-Open No. 2004-260688 discloses the use of regular expressions for specifying the character type of the format control information (FC) to enable detailed specification and improve the recognition rate. For storing format control information to be read for reading FC information in which information specifying a character type in the format control information is represented by a regular expression, and format control stored in the FC unit A regular expression analysis unit that analyzes regular expressions in information, a character type control unit that selects a dictionary to be used in a recognition dictionary based on an analysis result by the regular expression analysis unit, and a dictionary selected by the character type control unit. It is disclosed that a collation unit that collates with a pattern of characters and the like recorded on a sheet by using it and obtains a reading result is disclosed.

特許文献3には、文字認識結果の修正に必要な修正規則の機能拡張や保守が容易で、修正誤りを起こすことがない文字認識結果の修正方式を提供することを課題とし、入力文字列に対する文字認識結果である候補文字列を第1位から第n位まで配列して候補文字マトリクスを形成し、このマトリクスを正規表現マッチング部に渡し、マッチング部は、種々の文字列記述形式に適合した種々の修正規則を蓄積した修正規則ファイルをプログラム外に有しており、入力されたマトリクスに適合可能な修正規則をファイルから選択し、そして、選択した修正規則に最も適合する候補文字列をマトリクス内の文字を選んで作成し、続いて、選択された修正規則に従って、文字列置き換え部が、候補文字列内の文字列をより正しい文字列に置換し、次に、文字置き換え部が、文字列置換された候補文字列内の個々の文字をより正しい文字に置換することが開示されている。   In Patent Document 3, it is an object to provide a method for correcting a character recognition result that is easy to expand and maintain the correction rules necessary for correcting the character recognition result and does not cause a correction error. Candidate character strings that are character recognition results are arranged from the first to the nth to form a candidate character matrix, and this matrix is passed to the regular expression matching unit. The matching unit is adapted to various character string description formats. A correction rule file storing various correction rules is stored outside the program, a correction rule that can be applied to the input matrix is selected from the file, and a candidate character string that best matches the selected correction rule is matrixed. Then, the character string replacement unit replaces the character string in the candidate character string with the correct character string according to the selected correction rule, and then Character replacement unit, the replacement of individual characters in a string replacement candidate character strings to a more correct character is disclosed.

特許文献4には、不定ピッチで記入された単語文字列を、大幅な文字認識処理時間の増加を招くことなく正しく読み取る単語読み取り方式を提供することを目的とし、入力単語文字列パターンから個々のパターンを囲む矩形を抽出するパターン切出手段と、これらの矩形を組み合わせて、総矩形数が、読み取り対象単語の文字数の範囲内となる文字パターン矩形の並びを1つ以上生成する文字パターン矩形生成手段と、文字パターン矩形の並びを予め用意された標準文字パターンと比較して候補文字列を出力する文字認識手段と、候補文字列を予め用意された単語辞書と比較して候補単語を出力する単語検索手段とを備えていることが開示されている。   Patent Document 4 aims to provide a word reading method that correctly reads a word character string written at an indefinite pitch without causing a significant increase in character recognition processing time. Character pattern rectangle generation that generates a sequence of one or more character pattern rectangles in which the total number of rectangles is within the range of the number of characters of the word to be read by combining these rectangles with a pattern cutout unit that extracts rectangles surrounding the pattern A character recognition means for outputting a candidate character string by comparing the arrangement of character pattern rectangles with a standard character pattern prepared in advance, and outputting a candidate word by comparing the candidate character string with a word dictionary prepared in advance. And a word search means.

特開平03−257582号公報Japanese Patent Laid-Open No. 03-257582 特開平06−036069号公報Japanese Patent Application Laid-Open No. 06-036069 特開平09−138836号公報JP 09-138836 A 特開平01−281586号公報JP-A-01-281586

本発明は、複数の文字認識結果の候補から文字認識結果を選択して出力する場合にあって、本構成を有していない場合に比較して、高速に文字認識結果を出力するようにした情報処理装置及び情報処理プログラムを提供することを目的としている。   In the present invention, when a character recognition result is selected and output from a plurality of character recognition result candidates, the character recognition result is output at a higher speed than when the configuration is not provided. An object is to provide an information processing apparatus and an information processing program.

かかる目的を達成するための本発明の要旨とするところは、次の各項の発明に存する。
請求項1の発明は、予め定められた第1の文字列パターンの先頭又は最後尾から1文字以上の文字列の集合を生成する第1の生成手段と、前記第1の生成手段によって生成された集合から第2の文字列パターンを生成する第2の生成手段と、複数の文字認識結果の各々の文字をノードとし、隣接する文字画像のノード間をリンクで結ぶネットワークを構築するネットワーク構築手段と、前記ネットワーク構築手段によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、前記第2の生成手段によって生成された第2の文字列パターンに合致するノードに限定し、次に、前記第1の文字列パターンに合致するノードに限定する限定手段と、前記限定手段によって限定されたノードによって構成されたパス内の文字候補列を文字認識結果として出力する出力手段を具備することを特徴とする情報処理装置である。
The gist of the present invention for achieving the object lies in the inventions of the following items.
The invention according to claim 1 is generated by a first generation unit that generates a set of one or more character strings from the beginning or end of a predetermined first character string pattern, and the first generation unit. Second generation means for generating a second character string pattern from the set, and network construction means for constructing a network in which each character of a plurality of character recognition results is a node, and nodes of adjacent character images are linked by a link And the second character string pattern generated by the second generation means for a node connected from either the first direction or the last direction in the network constructed by the network construction means. A limiting means for limiting to nodes that match the first character string pattern, and a node limited by the limiting means. An information processing apparatus characterized by comprising output means for outputting the character candidate string in the path that is as a character recognition result.

請求項2の発明は、前記限定手段は、前記ネットワーク構築手段によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、文字認識候補とならない文字種を示す第3の文字列パターンに合致しないノードに限定し、前記第2の生成手段によって生成された第2の文字列パターンに合致するノードに限定し、次に、前記第1の文字列パターンに合致するノードに限定することを特徴とする請求項1に記載の情報処理装置である。   According to a second aspect of the present invention, the limiting means indicates a character type that is not a character recognition candidate for a node connected from either the head direction or the tail direction in the network constructed by the network construction means. Limited to nodes that do not match the third character string pattern, limited to nodes that match the second character string pattern generated by the second generation means, and then matches the first character string pattern The information processing apparatus according to claim 1, wherein the information processing apparatus is limited to nodes that perform processing.

請求項3の発明は、コンピュータを、予め定められた第1の文字列パターンの先頭又は最後尾から1文字以上の文字列の集合を生成する第1の生成手段と、前記第1の生成手段によって生成された集合から第2の文字列パターンを生成する第2の生成手段と、複数の文字認識結果の各々の文字をノードとし、隣接する文字画像のノード間をリンクで結ぶネットワークを構築するネットワーク構築手段と、前記ネットワーク構築手段によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、前記第2の生成手段によって生成された第2の文字列パターンに合致するノードに限定し、次に、前記第1の文字列パターンに合致するノードに限定する限定手段と、前記限定手段によって限定されたノードによって構成されたパス内の文字候補列を文字認識結果として出力する出力手段として機能させるための情報処理プログラムである。   According to a third aspect of the present invention, there is provided a first generating means for generating a set of one or more character strings from the head or the tail of a predetermined first character string pattern, and the first generating means. And a second generation means for generating a second character string pattern from the set generated by the above, and a network that connects each character of the plurality of character recognition results as a node and connects nodes of adjacent character images by a link A second character string generated by the second generation unit with respect to a network connecting unit and a node connected from either the first direction or the last direction in the network built by the network building unit Limited to nodes that match the pattern, then limited to nodes that match the first character string pattern, and limited by the limiting means An information processing program for functioning as an output means for outputting the character candidate columns in the configuration path by over de as a character recognition result.

請求項1の情報処理装置によれば、複数の文字認識結果の候補から文字認識結果を選択して出力する場合にあって、本構成を有していない場合に比較して、高速に文字認識結果を出力することができる。   According to the information processing apparatus of claim 1, when a character recognition result is selected and output from a plurality of character recognition result candidates, character recognition is performed at a higher speed than when the present configuration is not provided. The result can be output.

請求項2の情報処理装置によれば、第2の文字列パターンに合致するノードに限定する処理を、本構成を有していない場合に比較して、少なくすることができる。   According to the information processing apparatus of the second aspect, it is possible to reduce the processing to limit to the nodes matching the second character string pattern as compared with the case where this configuration is not provided.

請求項3の情報処理プログラムによれば、複数の文字認識結果の候補から文字認識結果を選択して出力する場合にあって、本構成を有していない場合に比較して、高速に文字認識結果を出力することができる。   According to the information processing program of claim 3, when a character recognition result is selected and output from a plurality of character recognition result candidates, character recognition is performed at a higher speed than when the present configuration is not provided. The result can be output.

本実施の形態の構成例についての概念的なモジュール構成図である。It is a conceptual module block diagram about the structural example of this Embodiment. 本実施の形態による処理例を示すフローチャートである。It is a flowchart which shows the process example by this Embodiment. 本実施の形態の構成例についての概念的なモジュール構成図である。It is a conceptual module block diagram about the structural example of this Embodiment. 対象とする帳票の例を示す説明図である。It is explanatory drawing which shows the example of the form made into object. 正規表現表記規則の例を示す説明図である。It is explanatory drawing which shows the example of a regular expression description rule. 文字位置と文字候補の関係例を示す説明図である。It is explanatory drawing which shows the example of a relationship between a character position and a character candidate. 文字位置と文字候補の関係例を示す説明図である。It is explanatory drawing which shows the example of a relationship between a character position and a character candidate. 本実施の形態による処理例を示すフローチャートである。It is a flowchart which shows the process example by this Embodiment. 記号例を示す説明図である。It is explanatory drawing which shows the example of a symbol. 記号例を示す説明図である。It is explanatory drawing which shows the example of a symbol. 記号例を示す説明図である。It is explanatory drawing which shows the example of a symbol. 記号例を示す説明図である。It is explanatory drawing which shows the example of a symbol. 記号例を示す説明図である。It is explanatory drawing which shows the example of a symbol. 文字切り出し位置が複数ある場合の処理例を示す説明図である。It is explanatory drawing which shows the process example in case there exist multiple character cutout positions. 記号例を示す説明図である。It is explanatory drawing which shows the example of a symbol. 文字切り出し位置が複数ある場合の処理例を示す説明図である。It is explanatory drawing which shows the process example in case there exist multiple character cutout positions. 文字列を構成するネットワークの例を示す説明図である。It is explanatory drawing which shows the example of the network which comprises a character string. 文字列を構成するネットワーク内のノードが接続されている例を示す説明図である。It is explanatory drawing which shows the example in which the node in the network which comprises a character string is connected. パス限定処理モジュール内のモジュール構成例を示す説明図である。It is explanatory drawing which shows the module structural example in a path | pass limitation processing module. パス限定処理モジュールによる処理例を示すフローチャートである。It is a flowchart which shows the process example by a path | pass limitation processing module. 文字位置と文字候補の関係例を示す説明図である。It is explanatory drawing which shows the example of a relationship between a character position and a character candidate. 限定文字列パターン検査処理モジュールが受け付けるデータと出力するデータの例を示す説明図である。It is explanatory drawing which shows the example of the data which a limited character string pattern test | inspection processing module receives and the data to output. 文字列の羅列の例を示す説明図である。It is explanatory drawing which shows the example of the enumeration of a character string. 文字列集合を2分木構造とした例を示す説明図である。It is explanatory drawing which shows the example which made the character string set the binary tree structure. 本実施の形態(変形例)の構成例についての概念的なモジュール構成図である。It is a conceptual module block diagram about the structural example of this Embodiment (modification). 本実施の形態(変形例)による処理例を示すフローチャートである。It is a flowchart which shows the process example by this Embodiment (modification). 文字列を構成するネットワーク内のノードが接続されている例を示す説明図である。It is explanatory drawing which shows the example in which the node in the network which comprises a character string is connected. 本実施の形態を実現するコンピュータのハードウェア構成例を示すブロック図である。It is a block diagram which shows the hardware structural example of the computer which implement | achieves this Embodiment. 文字列画像の例を示す説明図である。It is explanatory drawing which shows the example of a character string image. 文字境界候補の例を示す説明図である。It is explanatory drawing which shows the example of a character boundary candidate. 外接矩形の例を示す説明図である。It is explanatory drawing which shows the example of a circumscribed rectangle. 文字切り出し結果の例を示す説明図である。It is explanatory drawing which shows the example of a character cutout result. 文字切り出し位置を示すネットワーク表現の例を示す説明図である。It is explanatory drawing which shows the example of the network expression which shows a character cutout position. ネットワーク表現内のパターンの例を示す説明図である。It is explanatory drawing which shows the example of the pattern in a network expression. ネットワークの例を示す説明図である。It is explanatory drawing which shows the example of a network. 複数の文字候補がある場合のネットワーク例を示す説明図である。It is explanatory drawing which shows the example of a network when there exist a some character candidate.

本実施の形態は、複数の文字列を対象として、その中から予め定められた正規表現で記載された文字列の型に合致する文字列を出力するものである。例えば、文字列が含まれている画像に対する文字認識結果を対象としてもよく、その画像に対する文字認識の結果から予め定められた正規表現で記載された文字列の型に合致する文字列を出力する。より具体的には、文字認識を行うときに、複数の文字切り出し結果があり、さらに1つの文字画像に対しても複数の文字認識結果があり得るが、それらの文字の組み合わせである複数の文字列から、認識結果として正しい文字列を抽出しようとするものである。
まず、本実施の形態を説明する前に、その前提又は本実施の形態を利用する情報処理装置について説明する。なお、この説明は、本実施の形態の理解を容易にすることを目的とするものである。
In this embodiment, a plurality of character strings are targeted, and a character string that matches a character string type described in a regular expression is output from the plurality of character strings. For example, a character recognition result for an image including a character string may be targeted, and a character string that matches a character string type described in a predetermined regular expression is output from the result of character recognition for the image. . More specifically, when character recognition is performed, there are a plurality of character cutout results, and there may also be a plurality of character recognition results for one character image, but a plurality of characters that are combinations of these characters. A correct character string is to be extracted from the sequence as a recognition result.
First, before describing the present embodiment, the premise or an information processing apparatus using the present embodiment will be described. This description is intended to facilitate understanding of the present embodiment.

例えば、図29の例に示すような文字列画像を対象とする。まず、この文字列画像を文字セグメントに分割する。文字セグメントとは、文字そのもの、あるいは文字の一部となる可能性がある文字部分である。ここでは、図29の例に示すような横書きの文字列画像を例にとる。横書きの画像では、垂直な線(あるいは垂直に近い線)で分割を行うことにより、文字セグメントに分割する。例えば図30に示した縦線(切れ目候補3010、切れ目候補3020)で、文字列画像を分割して、3つの文字セグメント「イ」、「ヒ」、及び、「学」を得ることができる。図30の例に示した縦線を切れ目候補と呼ぶこととする。切れ目候補3010が「イ」と「ヒ」を分け、切れ目候補3020が「ヒ」と「学」を分けている。   For example, a character string image as shown in the example of FIG. 29 is targeted. First, this character string image is divided into character segments. A character segment is a character itself or a character portion that can be a part of a character. Here, a horizontally written character string image as shown in the example of FIG. 29 is taken as an example. In a horizontally written image, the image is divided into character segments by dividing the image with vertical lines (or lines close to vertical). For example, the character string image can be divided by the vertical lines (cut candidate 3010, cut candidate 3020) shown in FIG. 30 to obtain three character segments “I”, “HI”, and “Study”. The vertical line shown in the example of FIG. 30 is called a break candidate. A break candidate 3010 separates “I” and “HI”, and a break candidate 3020 separates “HI” and “Study”.

次に、図31の例に示すように、各文字セグメントに対し、その外接矩形(外接矩形3110、外接矩形3120、外接矩形3130)を抽出する。
以下、特許文献2に記載されている技術内容を例にして説明する。なお、以下の説明で用いる用語は、特許文献2で用いる用語とは異なっている場合がある。ただし、内容は特許文献2と同じである。
前述の文字セグメントを統合して、文字画像を決定する。複数の文字セグメントを統合して1つの文字画像を形成する場合もあれば、1つの文字セグメントが1つの文字となる場合もある。文字画像を決定するとは、文字の切り出し位置を決定することと同値であるから、以下では文字切り出し位置の決定という場合もある。
文字セグメントの統合のパターンは複数存在する。複数存在するパターンの中で、最も文字画像として評価の高いものを選択することによって、最終的な文字切り出し位置を決定する。
図31の例に対しては、すべての文字切り出しパターンは、図32に示す例のようになる。つまり、図32(a)の例では、パターン1として3つの文字画像(外接矩形3110、外接矩形3120、外接矩形3130)、図32(b)の例では、パターン2として2つの文字画像(外接矩形3110と3120、外接矩形3130)、図32(c)の例では、パターン3として1つの文字画像(外接矩形3110と3120と3130)、図32(d)の例では、パターン4として2つの文字画像(外接矩形3110、外接矩形3120と3130)を示している。
Next, as shown in the example of FIG. 31, the circumscribed rectangles (circumscribed rectangle 3110, circumscribed rectangle 3120, circumscribed rectangle 3130) are extracted for each character segment.
Hereinafter, the technical content described in Patent Document 2 will be described as an example. Note that the terms used in the following description may be different from the terms used in Patent Document 2. However, the contents are the same as in Patent Document 2.
A character image is determined by integrating the character segments described above. A plurality of character segments may be integrated to form one character image, or one character segment may become one character. Determining a character image is equivalent to determining a character cutout position, and hence may be referred to as determining a character cutout position below.
There are multiple patterns of character segment integration. A final character cutout position is determined by selecting a character image having the highest evaluation from among a plurality of existing patterns.
For the example of FIG. 31, all character cutout patterns are as shown in the example of FIG. That is, in the example of FIG. 32A, three character images (circumscribed rectangle 3110, circumscribed rectangle 3120, circumscribed rectangle 3130) are used as pattern 1, and in the example of FIG. In the example of rectangles 3110 and 3120, circumscribed rectangle 3130) and FIG. 32C, one character image (circumscribed rectangles 3110, 3120 and 3130) is used as pattern 3, and in the example of FIG. Character images (circumscribed rectangle 3110 and circumscribed rectangles 3120 and 3130) are shown.

文字切り出し位置を示すネットワーク表現(グラフ表現ともいわれる)として、図32の例に示した複数の切り出しパターンを表すことができる。図33の例において、ネットワークは、始点ノード3300、終点ノード3390、中間ノード3310(ノード1)、中間ノード3320(ノード2)の4つのノードと、ノード間を接続するアークで構成されている(ノード間の接続線をアークと呼ぶこととする)。始点は、文字列画像の左端、終点は文字列画像の右端にあたる。中間ノード3310(ノード1)、中間ノード3320(ノード2)は、それぞれ、文字の切れ目候補位置(すなわち、図30の例に示した切れ目候補3010、切れ目候補3020)を示す。中間ノード3310(ノード1)は、切れ目候補3010に対応している。また、中間ノード3320(ノード2)は、切れ目候補3020に対応している。   A plurality of cutout patterns shown in the example of FIG. 32 can be represented as network expressions (also referred to as graph expressions) indicating character cutout positions. In the example of FIG. 33, the network is composed of four nodes, a start node 3300, an end node 3390, an intermediate node 3310 (node 1), and an intermediate node 3320 (node 2), and arcs connecting the nodes ( Connection lines between nodes are called arcs). The start point corresponds to the left end of the character string image, and the end point corresponds to the right end of the character string image. Intermediate node 3310 (node 1) and intermediate node 3320 (node 2) respectively indicate character break candidate positions (that is, break candidate 3010 and break candidate 3020 shown in the example of FIG. 30). The intermediate node 3310 (node 1) corresponds to the break candidate 3010. Further, the intermediate node 3320 (node 2) corresponds to the break candidate 3020.

始点から、各ノードを通って、終点に至る経路を以下、「パス」と呼ぶ。パスは、1又は複数のアークから構成される。通常、複数のパスが存在する。図32の例に示した文字切り出しパターンは、これらの複数のパスに対応している。例えば、図32(b)の例に示したパターン2は、図34の太線で示したパス(文字切り出しパターン3304、文字切り出しパターン3322)と対応している。
ここで、どれか1つのアークには、1つの文字画像の候補が対応している。例えば、始点ノード3300と中間ノード3320(ノード2)を結ぶアークには、「化」という文字画像(文字切り出しパターン3304)が対応している。1つのアークに対応する文字に対して、その文字の評価値を決定することができる。これを「アーク評価値」と呼ぶこととする。
アーク評価値は、文字の形状情報や、文字認識における認識確度などから算出する。アーク評価値の算出方法はさまざまある。例えば、(1)特開平9−185681号公報、(2)特開平8−161432号公報、(3)特開平10−154207号公報、(4)特開昭61−175878号公報、(5)特開平3−37782号公報、(6)特開平11−203406号公報等に記載の従来技術に示されている手法等がある。
A route from the start point through each node to the end point is hereinafter referred to as a “path”. The path is composed of one or a plurality of arcs. Usually there are multiple paths. The character cutout pattern shown in the example of FIG. 32 corresponds to these multiple paths. For example, the pattern 2 shown in the example of FIG. 32B corresponds to the paths (character cutout pattern 3304 and character cutout pattern 3322) shown by thick lines in FIG.
Here, one character image candidate corresponds to any one arc. For example, a character image (character cutout pattern 3304) “K” corresponds to an arc connecting the start point node 3300 and the intermediate node 3320 (node 2). For a character corresponding to one arc, an evaluation value of the character can be determined. This is called an “arc evaluation value”.
The arc evaluation value is calculated from character shape information, recognition accuracy in character recognition, and the like. There are various methods for calculating the arc evaluation value. For example, (1) JP-A-9-185681, (2) JP-A-8-161432, (3) JP-A-10-154207, (4) JP-A-61-175878, (5) There are methods shown in the prior art described in JP-A-3-37782, (6) JP-A-11-203406, and the like.

1つのパスは、複数のアークから構成されている。複数のアーク評価値を用いて、そのアークから構成されるパスの評価値を計算することができる。これを「パス評価値」と呼ぶこととする。
文字切り出し位置を決定するため、複数のパスの中で、最もパス評価値の高いパスを選択する。パスが選択できれば、文字切り出し位置が確定して、文字を切り出すことができる。そして、切り出した文字(文字画像)を文字認識した結果も確定することになる。
例えば、図34の例で、太線のパスが選択されたとする。この場合、文字切り出し位置は、始点3300と、中間ノード3320(ノード2)と、終点3390の3点となる。そして、確定した文字認識結果は、「化」(文字切り出しパターン3304)、「学」(文字切り出しパターン3322)となる。
One path is composed of a plurality of arcs. Using a plurality of arc evaluation values, an evaluation value of a path constituted by the arcs can be calculated. This is called a “path evaluation value”.
In order to determine the character cutout position, the path with the highest path evaluation value is selected from the plurality of paths. If the path can be selected, the character cutout position is fixed and the character can be cut out. Then, the result of character recognition of the cut out character (character image) is also confirmed.
For example, in the example of FIG. 34, it is assumed that a thick line path is selected. In this case, the character cutout positions are three points: a start point 3300, an intermediate node 3320 (node 2), and an end point 3390. Then, the confirmed character recognition results are “B” (character cutout pattern 3304) and “Study” (character cutout pattern 3322).

ここで、パス評価値の算出方法について説明する。基本的には、パス評価値は、アーク評価値の重み付け和が用いられる。i番目のアークのアーク評価値をVとし、i番目のアーク評価値に対する重みをwとし、アークの数をN、パス評価値をPとすると、Pは次の(1)式で与えられる。

Figure 2014109810
パスの数が複数存在すると前述したが、実際の文字列には、多くの文字セグメントが存在しているため、存在するパスの数は膨大となる。
そこで、特開平3−225579号公報に記載の技術では、図33の例に示されたようなネットワーク内の複数のパスから最も評価値の高いパスを探索する方法として、ダイナミックプログラミング手法を用いることが述べられている。
ここでは、ダイナミックプログラミング手法の中で、このようなネットワークの最良パスを探索するのに適したビタビ法の説明を行う。 Here, a method for calculating the path evaluation value will be described. Basically, a weighted sum of arc evaluation values is used as the path evaluation value. When the arc evaluation value of the i-th arc is V i , the weight for the i-th arc evaluation value is w i , the number of arcs is N, and the path evaluation value is P, P is given by the following equation (1). It is done.
Figure 2014109810
As described above, there are a plurality of paths. However, since there are many character segments in an actual character string, the number of existing paths becomes enormous.
Therefore, in the technique described in Japanese Patent Laid-Open No. 3-225579, a dynamic programming technique is used as a method for searching for a path having the highest evaluation value from a plurality of paths in the network as shown in the example of FIG. Is stated.
Here, a Viterbi method suitable for searching for the best path of such a network in a dynamic programming method will be described.

図35に示す例において、始点ノード3500から終点ノード3590までのネットワークを説明する。なお、ノード間のリンク(アークともいわれる)は、図35に示したものに限らず、さまざまな場合がある。図35のように対称の結線でなくてもかまわない。
このネットワークにおいて、途中に複数のノード(中間ノード3511、中間ノード3512、中間ノード3513等)を介して始点ノードから終点ノードに達するとする。途中のノードを中間ノードと呼ぶこととする。
各ノードとノードの間にはリンクが張られている。このリンクにはそのリンク固有の評価値(リンク値)が割り当てられている。始点ノード3500から終点ノード3590に向かうパスは複数存在する。パスは、複数のリンクから成り立つことになる。パスが含む複数のリンクのリンク値の和が、パスの評価値となる。
例えば、リンク値は、ノード間の距離であるとする。この場合、パス評価値が最小のパスは、始点ノードから終点ノードに向かうパスの中で、最小距離のパスということになる。あるいは、パス評価値が最大のパスを求める問題とすることも可能である。
In the example shown in FIG. 35, a network from the start node 3500 to the end node 3590 will be described. The links between nodes (also referred to as arcs) are not limited to those shown in FIG. The connection may not be symmetrical as shown in FIG.
In this network, it is assumed that the end point node is reached from the start point node via a plurality of nodes (intermediate node 3511, intermediate node 3512, intermediate node 3513, etc.) in the middle. An intermediate node is called an intermediate node.
A link is established between each node. An evaluation value (link value) unique to the link is assigned to this link. There are a plurality of paths from the start node 3500 to the end node 3590. A path consists of multiple links. The sum of the link values of a plurality of links included in the path becomes the evaluation value of the path.
For example, the link value is a distance between nodes. In this case, the path with the minimum path evaluation value is the path with the minimum distance among the paths from the start node to the end node. Alternatively, it may be a problem of obtaining a path having the maximum path evaluation value.

ここで、ビタビ法は、あるノードにある方向から入力されるリンクを1に限定することによって、最適ではないパスを削減する。これにより、演算処理量と所要メモリ量を削減する手法である。
例えば、今、ノードx(中間ノード3521)に左から入力されるリンクがすでに、1に限定されているとする。同様に、ノードy(中間ノード3522)、ノードz(中間ノード3523)に関しても1に限定されているとする。このとき、ノードX(中間ノード3531)に左から入力されるリンクを限定する。ノードX(中間ノード3531)には、ノードx(中間ノード3421)、ノードy(中間ノード3422)、ノードz(中間ノード3423)の3つのノードからリンクが張られている。このとき、ノードX(中間ノード3531)を通るパスとして、最適な可能性があるのは、ノードx(中間ノード3521)、ノードy(中間ノード3522)、ノードz(中間ノード3523)からノードX(中間ノード3531)に向かうリンクのいずれかである。この3つのうちで最適なものだけを残し、残りの2つを削除する。このようにして、ノードX(中間ノード3531)に左から入力されるパス(リンク)を1に限定する。ノードY(中間ノード3532)、ノードZ(中間ノード3533)に関しても同様に左から入力されるパスを1に限定する。
このような手順を左のノードA(中間ノード3511)、ノードB(中間ノード3512)、ノードC(中間ノード3513)から順に右の方向に行う。最終的にノードP(中間ノード3581)、ノードQ(中間ノード3582)、ノードR(中間ノード3583)に入る3つのパスに限定する。この3つのパスの中で最適なものを選択すればよい。
このようなビタビ法を用いた最適パス選定方法を、図33に例示のネットワークにも同様に適用し得る。文字切り出し位置をノードとする。また、アーク評価値を前述のリンク値とすればよい。
Here, the Viterbi method reduces non-optimal paths by limiting the number of links input from a certain direction to a certain node. This is a technique for reducing the amount of calculation processing and the required memory amount.
For example, assume that the number of links input from the left to the node x (intermediate node 3521) is already limited to 1. Similarly, the node y (intermediate node 3522) and the node z (intermediate node 3523) are also limited to 1. At this time, the link input from the left to the node X (intermediate node 3531) is limited. Node X (intermediate node 3531) is linked to three nodes: node x (intermediate node 3421), node y (intermediate node 3422), and node z (intermediate node 3423). At this time, there is an optimal possibility that the path passing through the node X (intermediate node 3531) is from the node x (intermediate node 3521), the node y (intermediate node 3522), and the node z (intermediate node 3523) to the node X. One of the links going to (intermediate node 3531). Of these three, only the optimum one is left and the remaining two are deleted. In this way, the path (link) input from the left to the node X (intermediate node 3531) is limited to 1. Similarly, for the node Y (intermediate node 3532) and the node Z (intermediate node 3533), the paths input from the left are limited to 1.
Such a procedure is performed in order from the left node A (intermediate node 3511), node B (intermediate node 3512), and node C (intermediate node 3513) in the right direction. Finally, the number of paths is limited to three that enter the node P (intermediate node 3581), the node Q (intermediate node 3582), and the node R (intermediate node 3583). What is necessary is just to select the optimal one among these three paths.
Such an optimal path selection method using the Viterbi method can be similarly applied to the network illustrated in FIG. Let the character cutout position be a node. Moreover, what is necessary is just to let an arc evaluation value be the above-mentioned link value.

従来技術が扱っていた図33に例示するようなネットワークは、1つのアークに対し、1つの文字候補が存在しているものである。しかし、実際には1つのアークに対して、複数の文字候補が存在している。つまり、文字認識結果が複数ある場合である。例えば、図36のように、複数の文字候補を割り当てることになる。図36は、複数の文字候補がある場合のネットワーク例を示す説明図である。図36の例では、「化学」(文字画像3602)という画像を1文字として認識したときの認識結果が、文字候補3602Aの「梢」、文字候補3602Bの「際」、文字候補3602Cの「傾」の3種類ある。「化」(文字画像3604)という画像を1文字として認識したときの認識結果が、文字候補3604Aの「化」、文字候補3604Bの「比」、文字候補3604Cの「任」の3種類ある。同様に、他の文字画像に対しても文字認識結果としての文字候補が複数ある。なお、図36の例では、各文字画像に対して3種類の文字候補があるが、異なる数の文字候補を割り当ててもよい。例えば、認識確度が予め定められた値以上である文字を文字候補とした場合は、各文字画像に対して文字候補の数が異なる場合がある。
従来技術では、このような場合に、ビタビ法(又は、一般的にはダイナミックプログラミング手法)を適用して、文字認識結果を得ることはされていない。
In the network illustrated in FIG. 33 handled by the conventional technology, one character candidate exists for one arc. However, there are actually a plurality of character candidates for one arc. That is, there are a plurality of character recognition results. For example, as shown in FIG. 36, a plurality of character candidates are assigned. FIG. 36 is an explanatory diagram illustrating a network example when there are a plurality of character candidates. In the example of FIG. 36, when the image “chemical” (character image 3602) is recognized as one character, the recognition result is “top” of the character candidate 3602A, “when” of the character candidate 3602B, and “inclination” of the character candidate 3602C. There are three types. There are three types of recognition results when the image “K” (character image 3604) is recognized as one character: “K” for the character candidate 3604A, “Ratio” for the character candidate 3604B, and “K” for the character candidate 3604C. Similarly, there are a plurality of character candidates as character recognition results for other character images. In the example of FIG. 36, there are three types of character candidates for each character image, but a different number of character candidates may be assigned. For example, when a character having a recognition accuracy equal to or higher than a predetermined value is used as a character candidate, the number of character candidates may be different for each character image.
In the prior art, in such a case, the Viterbi method (or generally the dynamic programming method) is not applied to obtain a character recognition result.

以下、図面に基づき本発明を実現するにあたっての好適な一実施の形態の例を説明する。
図1、図3は、本実施の形態の構成例についての概念的なモジュール構成図を示している。
なお、モジュールとは、一般的に論理的に分離可能なソフトウェア(コンピュータ・プログラム)、ハードウェア等の部品を指す。したがって、本実施の形態におけるモジュールはコンピュータ・プログラムにおけるモジュールのことだけでなく、ハードウェア構成におけるモジュールも指す。それゆえ、本実施の形態は、それらのモジュールとして機能させるためのコンピュータ・プログラム(コンピュータにそれぞれの手順を実行させるためのプログラム、コンピュータをそれぞれの手段として機能させるためのプログラム、コンピュータにそれぞれの機能を実現させるためのプログラム)、システム及び方法の説明をも兼ねている。ただし、説明の都合上、「記憶する」、「記憶させる」、これらと同等の文言を用いるが、これらの文言は、実施の形態がコンピュータ・プログラムの場合は、記憶装置に記憶させる、又は記憶装置に記憶させるように制御するの意である。また、モジュールは機能に一対一に対応していてもよいが、実装においては、1モジュールを1プログラムで構成してもよいし、複数モジュールを1プログラムで構成してもよく、逆に1モジュールを複数プログラムで構成してもよい。また、複数モジュールは1コンピュータによって実行されてもよいし、分散又は並列環境におけるコンピュータによって1モジュールが複数コンピュータで実行されてもよい。なお、1つのモジュールに他のモジュールが含まれていてもよい。また、以下、「接続」とは物理的な接続の他、論理的な接続(データの授受、指示、データ間の参照関係等)の場合にも用いる。「予め定められた」とは、対象としている処理の前に定まっていることをいい、本実施の形態による処理が始まる前はもちろんのこと、本実施の形態による処理が始まった後であっても、対象としている処理の前であれば、そのときの状況・状態に応じて、又はそれまでの状況・状態に応じて定まることの意を含めて用いる。
また、システム又は装置とは、複数のコンピュータ、ハードウェア、装置等が通信回線(一対一対応、一対多対応、多対一対応、多対多対応の通信接続を含む)で接続されて構成されるほか、1つのコンピュータ、ハードウェア、装置等によって実現される場合も含まれる。「装置」と「システム」とは、互いに同義の用語として用いる。もちろんのことながら、「システム」には、人為的な取り決めである社会的な「仕組み」(社会システム)にすぎないものは含まない。
また、各モジュールによる処理毎に又はモジュール内で複数の処理を行う場合はその処理毎に、対象となる情報を記憶装置から読み込み、その処理を行った後に、処理結果を記憶装置に書き出すものである。したがって、処理前の記憶装置からの読み込み、処理後の記憶装置への書き出しについては、説明を省略する場合がある。なお、ここでの記憶装置としては、ハードディスク、RAM(Random Access Memory)、外部記憶媒体、通信回線を介した記憶装置、CPU(Central Processing Unit)内のレジスタ等を含んでいてもよい。
Hereinafter, an example of a preferred embodiment for realizing the present invention will be described with reference to the drawings.
1 and 3 show conceptual module configuration diagrams of configuration examples of the present embodiment.
The module generally refers to components such as software (computer program) and hardware that can be logically separated. Therefore, the module in the present embodiment indicates not only a module in a computer program but also a module in a hardware configuration. Therefore, the present embodiment is a computer program for causing these modules to function (a program for causing a computer to execute each procedure, a program for causing a computer to function as each means, and a function for each computer. This also serves as an explanation of the program and system and method for realizing the above. However, for the sake of explanation, the words “store”, “store”, and equivalents thereof are used. However, when the embodiment is a computer program, these words are stored in a storage device or stored in memory. It is the control to be stored in the device. Modules may correspond to functions one-to-one, but in mounting, one module may be configured by one program, or a plurality of modules may be configured by one program, and conversely, one module May be composed of a plurality of programs. The plurality of modules may be executed by one computer, or one module may be executed by a plurality of computers in a distributed or parallel environment. Note that one module may include other modules. Hereinafter, “connection” is used not only for physical connection but also for logical connection (data exchange, instruction, reference relationship between data, etc.). “Predetermined” means that the process is determined before the target process, and not only before the process according to this embodiment starts but also after the process according to this embodiment starts. In addition, if it is before the target processing, it is used in accordance with the situation / state at that time or with the intention to be decided according to the situation / state up to that point.
In addition, a system or device is configured by connecting a plurality of computers, hardware, devices, and the like through communication lines (including one-to-one correspondence, one-to-many correspondence, many-to-one correspondence, and many-to-many communication connection). In addition, the case where it is realized by one computer, hardware, device, or the like is also included. “Apparatus” and “system” are used as synonymous terms. Of course, the “system” does not include a social “mechanism” (social system) that is an artificial arrangement.
In addition, when performing a plurality of processes in each module or in each module, the target information is read from the storage device for each process, and the processing result is written to the storage device after performing the processing. is there. Therefore, description of reading from the storage device before processing and writing to the storage device after processing may be omitted. Here, the storage device may include a hard disk, a RAM (Random Access Memory), an external storage medium, a storage device via a communication line, a register in a CPU (Central Processing Unit), and the like.

本実施の形態である情報処理装置は、画像から文字を認識するものであって、図3の例に示すように、画像受付モジュール310、文字列抽出モジュール320、切出位置抽出モジュール330、文字候補抽出モジュール340、パス限定処理モジュール350、出力モジュール360を有している。   The information processing apparatus according to the present embodiment recognizes characters from an image. As shown in the example of FIG. 3, an image reception module 310, a character string extraction module 320, a cutout position extraction module 330, a character A candidate extraction module 340, a path limitation processing module 350, and an output module 360 are included.

画像受付モジュール310は、文字列抽出モジュール320と接続されている。画像受付モジュール310は、画像を受け付けて、その画像を文字列抽出モジュール320へ渡す。画像を受け付けるとは、例えば、スキャナ、カメラ等で画像を読み込むこと、ファックス等で通信回線を介して外部機器から画像を受信すること、ハードディスク(コンピュータに内蔵されているものの他に、通信回線を介して接続されているもの等を含む)等に記憶されている画像を読み出すこと等が含まれる。画像は、2値画像、多値画像(カラー画像を含む)であってもよい。受け付ける画像は、1枚であってもよいし、複数枚であってもよい。また、画像の内容として、文字列が含まれているのであれば、ビジネスに用いられる文書、広告宣伝用のパンフレット等であってもよい。   The image reception module 310 is connected to the character string extraction module 320. The image reception module 310 receives an image and passes the image to the character string extraction module 320. Accepting an image means, for example, reading an image with a scanner, a camera, etc., receiving an image from an external device via a communication line by fax, etc., a hard disk (in addition to what is built in a computer, a communication line For example, reading out an image stored in a device etc.). The image may be a binary image or a multi-value image (including a color image). One image may be received or a plurality of images may be received. Moreover, as long as the content of the image contains a character string, it may be a document used for business, a pamphlet for advertisement, or the like.

文字列抽出モジュール320は、画像受付モジュール310、切出位置抽出モジュール330と接続されている。文字列抽出モジュール320は、画像受付モジュール310が受け付けた画像から文字列を抽出する。
切出位置抽出モジュール330が対象とする画像は横書きあるいは縦書きの、1列のみの文字列画像を対象としている。なお、ここで、列とは、横書きの場合は横に並ぶ列であり、縦書きの場合は縦に並ぶ列である。
したがって、文字列抽出モジュール320は、画像受付モジュール310が受け付けた画像が1列のみの文字列画像であれば、そのまま用いればよい。画像受付モジュール310が受け付けた画像が、複数の文字列が存在するものがあり、このような複数文字列を単一の文字列になるように分離する手法としては、従来よりさまざまものが提案されているため、それらを用いればよい。単一の文字列となるように分離する例としてもさまざまな方式があるため、そのうちのいずれかを用いればよい。例えば、(1)特開平4−311283号公報、(2)特開平3−233789号公報、(3)特開平5−73718号公報、(4)特開2000−90194号公報、等を用いればよい。これ以外の方法であってもよい。
The character string extraction module 320 is connected to the image reception module 310 and the cutout position extraction module 330. The character string extraction module 320 extracts a character string from the image received by the image reception module 310.
The image targeted by the cut-out position extraction module 330 is a character string image of only one column written horizontally or vertically. Here, the column is a column arranged horizontally in the case of horizontal writing, and a column aligned vertically in the case of vertical writing.
Therefore, if the image received by the image receiving module 310 is a character string image with only one column, the character string extraction module 320 may be used as it is. Some images received by the image receiving module 310 include a plurality of character strings, and various methods have been proposed for separating such a plurality of character strings into a single character string. Therefore, they can be used. Since there are various methods as examples of separation so as to form a single character string, any one of them may be used. For example, if (1) JP-A-4-311283, (2) JP-A-3-233789, (3) JP-A-5-73718, (4) JP-A-2000-90194, etc. are used. Good. Other methods may be used.

切出位置抽出モジュール330は、文字列抽出モジュール320、文字候補抽出モジュール340と接続されている。切出位置抽出モジュール330は、文字列抽出モジュール320が抽出した文字列画像から文字画像を切り出す位置を抽出する。つまり、文字列画像を複数の文字セグメントに分割する。この文字切り出し位置の抽出方法としてもさまざまな方式があるため、そのうちのどれかを用いればよい。例えば、(1)特開平5−114047号公報、(2)特開平4−100189号公報、(3)特開平4−92992号公報、(4)特開平4−68481号公報、(5)特開平9−54814号公報、(6)特開平9−185681号公報の0021段落に記載の文字の境界候補抽出方式、(7)特開平5−128308号公報の0005段落に記載の文字切り出し位置決定方法等を用いればよい。これ以外の方法であってもよい。なお、ここでの文字画像とは、いわば文字候補画像であり、必ずしもその文字画像が1つの文字を表す画像でなくてもよい。   The cutout position extraction module 330 is connected to the character string extraction module 320 and the character candidate extraction module 340. The cutout position extraction module 330 extracts a position at which a character image is cut out from the character string image extracted by the character string extraction module 320. That is, the character string image is divided into a plurality of character segments. Since there are various methods for extracting the character cut-out position, any one of them may be used. For example, (1) Japanese Patent Application Laid-Open No. 5-114047, (2) Japanese Patent Application Laid-Open No. 4-100189, (3) Japanese Patent Application Laid-Open No. 4-92992, (4) Japanese Patent Application Laid-Open No. 4-68481, (5) Special Kaihei 9-54814, (6) Character boundary candidate extraction method described in paragraph 0021 of JP-A-9-185681, (7) Character cut-out position determination described in paragraph 0005 of JP-A-5-128308 A method or the like may be used. Other methods may be used. The character image here is a so-called character candidate image, and the character image is not necessarily an image representing one character.

また、切出位置抽出モジュール330は、複数の切り出し位置を抽出してもよい。複数の切り出し位置を抽出することによって、1つの文字列画像に対して、文字切出位置群が複数ある。文字切出位置群とは、1つの文字列画像に対して、1つ以上の文字切り出し位置があることをいう。例えば、2つの文字切り出し位置があれば、3つの文字画像に分けられることになる。また、文字切出位置群が複数あるとは、1つの文字列画像に対して、文字切出位置で分けられた文字画像列が複数あることをいう。例えば、2つの文字切り出し位置で3つの文字画像からなる文字画像列と、3つの文字切り出し位置で4つの文字画像からなる文字画像列となる。具体例で説明すると、「化学」という文字列に対して、「イ」「ヒ」「学」からなる文字画像列と「化」「学」からなる文字画像列を生成することである。   Further, the cutout position extraction module 330 may extract a plurality of cutout positions. By extracting a plurality of cutout positions, there are a plurality of character cutout position groups for one character string image. The character cutout position group means that there are one or more character cutout positions for one character string image. For example, if there are two character cutout positions, they are divided into three character images. Also, “a plurality of character cut-out position groups” means that there are a plurality of character image strings divided by character cut-out positions for one character string image. For example, a character image string composed of three character images at two character cutout positions and a character image string composed of four character images at three character cutout positions. To explain with a specific example, a character image string consisting of “I”, “HI”, and “Study” and a character image string consisting of “K” and “Study” are generated for the character string “Chemical”.

文字候補抽出モジュール340は、切出位置抽出モジュール330、パス限定処理モジュール350と接続されている。文字候補抽出モジュール340は、切出位置抽出モジュール330によって抽出された位置によって分けられた文字画像に対して文字認識を行った結果である複数の文字候補を抽出する。この抽出処理を行うために、文字認識処理を行ってもよい。そのために、文字候補抽出モジュール340内に文字認識モジュールを含んでいてもよい。文字認識処理による認識結果は、前述のように、1つの文字画像に対して複数の文字候補が対応する。つまり、その文字画像を文字認識して、第1位の認識確度を有している文字候補、第2位の認識確度を有している文字候補等のように、複数の文字候補を文字認識結果とする。そして、文字認識結果として、文字候補の他に、その文字候補の認識確度を有していてもよい。また、抽出するのに、1つの文字画像に対して予め定められた数の文字候補を抽出してもよいし、予め定められた値以上の認識確度を有している文字候補を抽出してもよい。なお、認識確度は、文字認識処理において、その認識結果としての信頼性を表す値であってもよいし、文字画像の外接矩形のサイズ、縦横比等によって定められる文字らしさを表す値であってもよい。   The character candidate extraction module 340 is connected to the cutout position extraction module 330 and the path limitation processing module 350. The character candidate extraction module 340 extracts a plurality of character candidates that are the result of character recognition performed on the character images divided by the positions extracted by the cutout position extraction module 330. In order to perform this extraction process, a character recognition process may be performed. Therefore, a character recognition module may be included in the character candidate extraction module 340. As described above, the recognition result obtained by the character recognition process corresponds to a plurality of character candidates for one character image. In other words, the character image is recognized, and a plurality of character candidates such as a character candidate having the first recognition accuracy and a character candidate having the second recognition accuracy are recognized. As a result. And as a character recognition result, you may have the recognition accuracy of the character candidate other than a character candidate. In addition, for extraction, a predetermined number of character candidates may be extracted from one character image, or character candidates having a recognition accuracy equal to or higher than a predetermined value are extracted. Also good. The recognition accuracy may be a value representing the reliability as a recognition result in the character recognition process, or a value representing the character likeness determined by the size of the circumscribed rectangle of the character image, the aspect ratio, etc. Also good.

パス限定処理モジュール350は、文字候補抽出モジュール340、出力モジュール360と接続されている。パス限定処理モジュール350は、文字候補抽出モジュール340によって抽出された複数の文字候補の各々をノードとし、隣接する文字画像のノード間にリンクを構築することによってネットワークを生成する。隣接する文字画像のノード間とは、隣接する文字画像があり、その文字画像に対応するノード間ということである。
また、切出位置抽出モジュール330が複数の切り出し位置を抽出した場合は、パス限定処理モジュール350は、切出位置抽出モジュール330によって抽出された複数の切り出し位置によって分けられた文字画像に対して文字認識を行った結果である複数の文字候補の各々をノードとし、隣接する文字画像のノード間にリンクを構築することによってネットワークを生成するようにしてもよい。
そして、パス限定処理モジュール350は、生成されたネットワーク内のノードに先頭方向又は最後尾方向のいずれか一方向から接続するリンクに対して、予め定められた文字列パターンに合致するリンクに限定する。
また、パス限定処理モジュール350は、限定されたリンクによって接続されたノードの文字候補間の関係による文字列らしさを表す値に基づいて、リンク値を生成してもよい。さらに、リンクを構成しているノードに対する文字らしさを表す値に基づいて、リンク値を生成するようにしてもよい。
そして、パス限定処理モジュール350は、生成されたリンク値に基づいて、ネットワーク内のパスを選択するようにしてもよい。
The path limitation processing module 350 is connected to the character candidate extraction module 340 and the output module 360. The path restriction processing module 350 uses each of the plurality of character candidates extracted by the character candidate extraction module 340 as a node, and generates a network by constructing a link between nodes of adjacent character images. Between nodes of adjacent character images means that there is an adjacent character image and the node corresponds to the character image.
When the cutout position extraction module 330 has extracted a plurality of cutout positions, the path limitation processing module 350 performs character processing on character images divided by the cutout positions extracted by the cutout position extraction module 330. Each of a plurality of character candidates as a result of recognition may be a node, and a network may be generated by building a link between nodes of adjacent character images.
Then, the path limitation processing module 350 limits the links connecting to the generated nodes in the network from either the first direction or the last direction to links that match a predetermined character string pattern. .
Further, the path limitation processing module 350 may generate a link value based on a value representing the character string likelihood based on the relationship between the character candidates of the nodes connected by the limited link. Furthermore, the link value may be generated based on a value representing character likeness with respect to the nodes constituting the link.
Then, the path limitation processing module 350 may select a path in the network based on the generated link value.

また、パス限定処理モジュール350は、最初のリンクから文字列パターンに合致していない場合、その合致していないリンクの次のリンクからその文字列パターンに合致するリンクに限定するようにしてもよい。
また、パス限定処理モジュール350は、文字列パターンに合致するリンクがない場合は、その文字列パターン内の一部分の文字列パターンに合致するリンクに限定するようにしてもよい。
Further, when the character string pattern does not match from the first link, the path limitation processing module 350 may limit the link following the non-matching link to a link that matches the character string pattern. .
In addition, when there is no link that matches the character string pattern, the path limitation processing module 350 may limit the link to a part of the character string pattern that matches the character string pattern.

出力モジュール360は、パス限定処理モジュール350と接続されている。出力モジュール360は、パス限定処理モジュール350によって限定されたリンクによってつながれたパス内の文字候補列を文字認識結果として出力する。また、出力モジュール360は、パス限定処理モジュール350によって選択されたパス内の文字候補列を文字認識結果として出力するようにしてもよい。文字認識結果を出力するとは、例えば、プリンタ等の印刷装置で印刷すること、ディスプレイ等の表示装置に表示すること、メモリーカード等の記憶媒体に記憶すること、他の情報処理装置へ渡すこと等が含まれる。   The output module 360 is connected to the path limitation processing module 350. The output module 360 outputs a character candidate string in the path connected by the link limited by the path limitation processing module 350 as a character recognition result. The output module 360 may output a character candidate string in the path selected by the path restriction processing module 350 as a character recognition result. Outputting the character recognition result includes, for example, printing on a printing device such as a printer, displaying on a display device such as a display, storing in a storage medium such as a memory card, passing to another information processing device, etc. Is included.

図3の例に示した実施の形態は、以下のように把握することもできる。
(1)画像から文字画像を切り出す位置を抽出する切出位置抽出手段と、前記切出位置抽出手段によって抽出された位置によって分けられた文字画像に対して文字認識を行った結果である複数の文字候補を抽出する文字候補抽出手段と、前記文字候補抽出手段によって抽出された複数の文字候補の各々をノードとし、隣接する文字画像のノード間にリンクを構築することによってネットワークを生成するネットワーク生成手段と、前記ネットワーク生成手段によって生成されたネットワーク内のノードに先頭方向又は最後尾方向のいずれか一方向から接続するリンクに対して、予め定められた文字列パターンに合致するリンクに限定する限定手段と、前記限定手段によって限定されたリンクによってつながれたパス内の文字候補列を文字認識結果として出力する出力手段を具備することを特徴とする情報処理装置である。
この情報処理装置によれば、画像から文字を認識する場合にあって、本構成を有していない場合に比較して、精度が高い文字認識結果を出力することができる。
The embodiment shown in the example of FIG. 3 can also be grasped as follows.
(1) A plurality of cut position extraction means for extracting a position to cut out a character image from an image, and a plurality of character recognition results obtained by performing character recognition on the character image divided by the position extracted by the cut out position extraction means. Character candidate extraction means for extracting character candidates, and network generation for generating a network by constructing a link between nodes of adjacent character images with each of the plurality of character candidates extracted by the character candidate extraction means as nodes. And a link that connects to a node in the network generated by the network generation unit from either the first direction or the last direction, and is limited to a link that matches a predetermined character string pattern A character candidate string in a path connected by means and a link limited by the limiting means An information processing apparatus characterized by comprising output means for outputting a result.
According to this information processing apparatus, when a character is recognized from an image, a character recognition result with higher accuracy can be output as compared with a case where the present configuration is not provided.

(2)前記限定手段によって限定されたリンクによって接続されたノードの文字候補間の関係による文字列らしさを表す値に基づいて、リンク値を生成するリンク値生成手段と、前記リンク値生成手段によって生成されたリンク値に基づいて、前記ネットワーク生成手段によって生成されたネットワーク内のパスを選択するパス選択手段を具備し、前記出力手段は、前記パス選択手段によって選択されたパス内の文字候補列を文字認識結果として出力することを特徴とする(1)に記載の情報処理装置である。
この情報処理装置によれば、各文字画像の1つだけの文字認識結果によって認識文字列を決定してしまうことを防止することができる。
(2) a link value generating means for generating a link value based on a value representing a character string likelihood based on a relationship between character candidates of nodes connected by a link limited by the limiting means; and the link value generating means Path selection means for selecting a path in the network generated by the network generation means based on the generated link value, and the output means includes character candidate strings in the path selected by the path selection means Is output as a character recognition result, The information processing apparatus according to (1).
According to this information processing apparatus, it is possible to prevent a recognized character string from being determined based on only one character recognition result of each character image.

(3)前記リンク値生成手段は、前記リンクを構成しているノードに対する文字らしさを表す値に基づいて、前記リンク値を生成することを特徴とする(2)に記載の情報処理装置である。
この情報処理装置によれば、文字列らしさを表す値と文字らしさを表す値を用いてリンク値を生成することができる。
(3) The information processing apparatus according to (2), wherein the link value generation unit generates the link value based on a value representing character likeness with respect to the nodes constituting the link. .
According to this information processing apparatus, it is possible to generate a link value using a value representing character stringiness and a value representing characteriness.

(4)前記切出位置抽出手段は、複数の切り出し位置を抽出し、前記ネットワーク生成手段は、前記切出位置抽出手段によって抽出された複数の切り出し位置によって分けられた文字画像に対して文字認識を行った結果である複数の文字候補の各々をノードとし、隣接する文字画像のノード間にリンクを構築することによってネットワークを生成することを特徴とする(2)又は(3)に記載の情報処理装置である。
この情報処理装置によれば、複数の切り出し位置に対しても文字認識結果を出力することができる。
(4) The cutout position extraction unit extracts a plurality of cutout positions, and the network generation unit recognizes characters for character images divided by the plurality of cutout positions extracted by the cutout position extraction unit. The information according to (2) or (3), wherein each of a plurality of character candidates as a result of performing the step is used as a node, and a network is generated by constructing a link between adjacent character image nodes. It is a processing device.
According to this information processing apparatus, it is possible to output character recognition results for a plurality of cutout positions.

(5)前記限定手段は、最初のリンクから前記文字列パターンに合致していない場合、該合致していないリンクの次のリンクから該文字列パターンに合致するリンクに限定することを特徴とする(1)から(4)のいずれか一項に記載の情報処理装置である。
この情報処理装置によれば、最初に誤った文字認識結果がある場合であっても、文字列パターンに合致する文字認識結果を出力することができる。
(5) In the case where the character string pattern does not match from the first link, the limiting means limits the link following the non-matching link to a link that matches the character string pattern. The information processing apparatus according to any one of (1) to (4).
According to this information processing apparatus, even if there is an erroneous character recognition result at first, a character recognition result that matches the character string pattern can be output.

(6)前記限定手段は、前記文字列パターンに合致するリンクがない場合は、該文字列パターン内の一部分の文字列パターンに合致するリンクに限定することを特徴とする(1)から(5)のいずれか一項に記載の情報処理装置である。
この情報処理装置によれば、文字列パターン内の一部分の文字列パターンに合致する文字認識結果を出力することができる。
(6) In the case where there is no link that matches the character string pattern, the limiting means limits the link to a link that matches a part of the character string pattern in the character string pattern. The information processing apparatus according to any one of the above.
According to this information processing apparatus, it is possible to output a character recognition result that matches a partial character string pattern in the character string pattern.

(7)コンピュータを、画像から文字画像を切り出す位置を抽出する切出位置抽出手段と、前記切出位置抽出手段によって抽出された位置によって分けられた文字画像に対して文字認識を行った結果である複数の文字候補を抽出する文字候補抽出手段と、前記文字候補抽出手段によって抽出された複数の文字候補の各々をノードとし、隣接する文字画像のノード間にリンクを構築することによってネットワークを生成するネットワーク生成手段と、前記ネットワーク生成手段によって生成されたネットワーク内のノードに先頭方向又は最後尾方向のいずれか一方向から接続するリンクに対して、予め定められた文字列パターンに合致するリンクに限定する限定手段と、前記限定手段によって限定されたリンクによってつながれたパス内の文字候補列を文字認識結果として出力する出力手段として機能させるための情報処理プログラムである。
この情報処理プログラムによれば、画像から文字を認識する場合にあって、本構成を有していない場合に比較して、精度が高い文字認識結果を出力することができる。
(7) As a result of the computer performing character recognition on the character image divided by the position extracted by the cut-out position extracting unit and the position extracted by the cut-out position extracting unit, the position where the character image is cut out from the image A character candidate extracting means for extracting a plurality of character candidates and a network by constructing a link between adjacent character image nodes with each of the plurality of character candidates extracted by the character candidate extracting means as a node And a link that matches a predetermined character string pattern with respect to a link that connects to a node in the network generated by the network generation unit from either the first direction or the last direction. Limiting means for limiting and characters in the path connected by the link limited by the limiting means An information processing program for functioning as an output means for outputting the auxiliary column as a character recognition result.
According to this information processing program, it is possible to output a character recognition result with higher accuracy when recognizing characters from an image than when not having this configuration.

図4は、対象とする帳票400の例を示す説明図である。この帳票400には、名前枠410、住所枠(市前)420と住所枠(市後)430が設定されている。この帳票400への記載者は、名前枠410には名前を記入する。また、住所枠(市前)420と住所枠(市後)430には住所を記載する。その結果、名前枠410内には、名前のみが記入されていると仮定することができる。又は、住所枠(市前)420、住所枠(市後)430内には住所のみが記入されていると仮定することができる。
このように、枠に記載されるはずの文字、又は単語が限定される場合には、自由に記載可能な場合よりも認識率を上げることができる。例えば、住所などの場合で、図4の例のように、住所枠(市前)420内に市の名前を書くように指定されている場合を考える。市の名前は限定されているので、それに限定すれば、より精度が上がる。ここで、例えば、住所枠(市前)420内に記載される可能性のある市名が、下記3つに限定されているとする。
(1)横浜
(2)川崎
(3)横須賀
ここで、住所枠(市前)420内に記載される文字列は、この3パターンに限定されているということができる。
FIG. 4 is an explanatory diagram showing an example of a target form 400. In the form 400, a name frame 410, an address frame (in front of the city) 420, and an address frame (after the city) 430 are set. A reporter on the form 400 enters a name in the name frame 410. Addresses are written in the address frame (in front of the city) 420 and the address frame (after the city) 430. As a result, it can be assumed that only the name is entered in the name box 410. Alternatively, it can be assumed that only the address is written in the address frame (in front of the city) 420 and the address frame (after the city) 430.
In this way, when the characters or words that are supposed to be described in the frame are limited, the recognition rate can be increased as compared with the case where the description can be freely made. For example, in the case of an address or the like, consider a case where the name of a city is designated to be written in the address frame (in front of the city) 420 as in the example of FIG. The name of the city is limited, so if you limit it, the accuracy will be higher. Here, for example, it is assumed that the city names that may be described in the address frame (in front of the city) 420 are limited to the following three.
(1) Yokohama (2) Kawasaki (3) Yokosuka Here, it can be said that the character string described in the address frame (city front) 420 is limited to these three patterns.

このような、文字列パターンの限定を指定する手法(限定文字列パターン108を指定する手法)の例として、正規表現がある。正規表現には種々の表記法があるが、一例として、正規表現の表記方法を図5に例示する。図5は、正規表現表記規則500の例を示す説明図である。正規表現表記規則500は、規則欄510内の表記を、意味欄520で説明している。
例えば、前記のように、「横浜」、あるいは、「川崎」、あるいは、「横須賀」のみを対象とする場合、正規表現としては、
「横浜|川崎|横須賀」
と記述すればよい。
There is a regular expression as an example of a method for designating the limitation of the character string pattern (a method for designating the limited character string pattern 108). There are various notation methods for regular expressions. As an example, a notation method for regular expressions is illustrated in FIG. FIG. 5 is an explanatory diagram showing an example of a regular expression notation rule 500. In the regular expression notation rule 500, the notation in the rule column 510 is explained in the meaning column 520.
For example, as described above, when targeting only “Yokohama”, “Kawasaki”, or “Yokosuka”, as a regular expression,
"Yokohama | Kawasaki | Yokosuka"
May be described.

特許文献2に記載の技術では、文字位置毎に、字種を限定させて、精度を上げる例が述べられている。
前述の市名の例では、
・1文字目には、「横」、「川」のみ
・2文字目には、「浜」、「崎」、「須」のみ
・3文字目には、「賀」のみ
しかあり得ない。この条件を利用する。例えば、1文字目には、「横」と、「川」しかあり得ないので、それのみを出力するように設定する。このようにすることによって、認識率の精度を上げることが可能となる。例えば、「横」は、「黄」と字が似ており、正解は「横」であるのに、「黄」と誤認識する可能性があるが、出力文字を、「横」と「川」に限定することで、「黄」の出力を禁ずることとなっている。
In the technique described in Patent Document 2, an example is described in which the character type is limited for each character position to increase accuracy.
In the city example above,
・ The first character is “horizontal” and “river” only ・ The second character is only “Hama”, “Saki”, and “su” ・ The third character is only “ga”. Use this condition. For example, since there can only be “horizontal” and “river” for the first character, it is set to output only that. By doing so, it is possible to increase the accuracy of the recognition rate. For example, “horizontal” is similar in character to “yellow” and the correct answer is “horizontal”, but there is a possibility that it may be mistaken for “yellow”, but the output characters are “horizontal” and “river” By limiting to “”, output of “yellow” is prohibited.

さらに、特許文献3に示すように、複数の文字候補を1文字目から見ていく方法もある。
1つの文字を認識する場合、複数の認識候補を得ることができる。複数の文字候補には、第1候補から、第n候補までの、順位が付けられている。第1候補が最も確度の高い候補であり、数値が大きくなるに従って、認識の確度は低下する。特許文献3に記載の技術では、1文字目の第1候補から順に、正規表現にマッチするものを探索していく。ここで、決定するのは1文字目であるとする。1文字目の、第1候補が正規表現にマッチすれば、その候補を選択する。第1候補が正規表現にマッチしない場合、第2候補をチェックする。以降、正規表現にマッチするまで、第2、第3と、順に候補を探索する。正規表現にマッチする候補がない場合は、終了する。正規表現にマッチする候補がある場合その候補を選択する。候補を選択した後では、2文字目の選択を行う。ここではすでに1文字目の選択が行われているため、1文字目と合わせて、2文字の文字列が正規表現にマッチするような文字を選択する必要がある。ここで、1文字目と同様に、2文字目の第1候補から順に探索する。正規表現にマッチした段階で、その候補を選択する。
この方法であれば、複数の文字候補があっても、最終的に正規表現にマッチする文字列を選択することができる。
Furthermore, as shown in Patent Document 3, there is a method of viewing a plurality of character candidates from the first character.
When recognizing one character, a plurality of recognition candidates can be obtained. The plurality of character candidates are ranked from the first candidate to the nth candidate. The first candidate is the candidate with the highest accuracy, and the accuracy of recognition decreases as the numerical value increases. In the technique described in Patent Document 3, a search is made for items that match the regular expression in order from the first candidate of the first character. Here, it is assumed that the first character is determined. If the first candidate of the first character matches the regular expression, the candidate is selected. If the first candidate does not match the regular expression, the second candidate is checked. Thereafter, the candidates are searched in order of the second and third until the regular expression is matched. If no candidate matches the regular expression, the process ends. If there is a candidate that matches the regular expression, select that candidate. After selecting a candidate, the second character is selected. Here, since the first character has already been selected, it is necessary to select a character whose two character strings match the regular expression together with the first character. Here, similarly to the first character, the search is performed in order from the first candidate of the second character. When a regular expression is matched, the candidate is selected.
With this method, even if there are a plurality of character candidates, a character string that finally matches the regular expression can be selected.

例えば、各文字と、その認識文字候補が、図6の例のようになっているとする。つまり、3つの各文字について、3つの文字認識候補がある例である。また、この場合の、正解は、「横須賀」であるとする。また、出力文字パターンとしての正規表現は、
「横浜|川崎|横須賀」
であるとする。
この例では、1文字目は第2候補、2文字目は第2候補、3文字目は第1候補を選択することで、正解出力を得ることができる。
特許文献2に記載の技術では、予め文字位置に応じて、出力される文字候補を決める。特許文献2に記載の技術での出力候補は、図7の例に示すハッチング部を除いた出力の中で、最も順位の高いもの(第1候補の方が第2候補よりも順位が高いとする)を出力することになる。結局、特許文献2に記載の技術では、「横浜賀」が出力されることとなる。
For example, assume that each character and its recognized character candidate are as shown in the example of FIG. That is, there are three character recognition candidates for each of the three characters. In this case, the correct answer is “Yokosuka”. Also, the regular expression as the output character pattern is
"Yokohama | Kawasaki | Yokosuka"
Suppose that
In this example, the correct output can be obtained by selecting the second candidate for the first character, the second candidate for the second character, and the first candidate for the third character.
In the technique described in Patent Document 2, character candidates to be output are determined in advance according to the character position. The output candidate in the technique described in Patent Document 2 has the highest ranking among the outputs excluding the hatched portion shown in the example of FIG. 7 (if the first candidate has a higher rank than the second candidate) Will be output. Eventually, with the technique described in Patent Document 2, “Yokohamaga” is output.

特許文献3に記載の技術では、1文字目では、正規表現に合致するのは「横」であるため、「横」が選択される。2文字目では、最も順位の高く、かつ正規表現に合致するのは、「浜」であるため、「浜」が出力される。3文字目では、正規表現に合致する文字はない。「横浜賀」という単語は、出力文字パターン「横浜|川崎|横須賀」の中にはないためである。そのため、特許文献3に記載の技術では、出力なしということになるか、あるいは、「横浜賀」の中で、最長一致の「横浜」が出力されることになる。   In the technique described in Patent Document 3, since “horizontal” matches the regular expression at the first character, “horizontal” is selected. In the second character, “Hama” is output because “Hama” has the highest ranking and matches the regular expression. In the third character, no character matches the regular expression. This is because the word “Yokohamaga” is not in the output character pattern “Yokohama | Kawasaki | Yokosuka”. Therefore, in the technique described in Patent Document 3, there is no output or “Yokohama” having the longest match in “Yokohamaga” is output.

特許文献2、特許文献3に記載の技術では、文字列の1文字目、かつ、第1候補から、順に正規表現(あるいは、正規表現のような文字列パターン指示方法。以下、正規表現として示す)に合致する文字を選択している。
本実施の形態では、文字認識候補のあり得る文字列のうちから、正規表現に合致するパターンを探索するものである。そして、そのためにビタビ法を用いるようにしてもよい。
In the techniques described in Patent Document 2 and Patent Document 3, a regular expression (or a character string pattern instruction method such as a regular expression in order from the first character of the character string and the first candidate. ) Is selected.
In the present embodiment, a pattern that matches a regular expression is searched for from character strings that can be character recognition candidates. For this purpose, the Viterbi method may be used.

図8は、本実施の形態による処理例を示すフローチャートである。
ステップS802では、画像受付モジュール310が、対象となる画像を受け付ける。
ステップS804では、文字列抽出モジュール320が、画像から文字列画像を抽出する。
ステップS806では、切出位置抽出モジュール330が、文字列画像を対象として切り出し位置を抽出する。
ステップS808では、文字候補抽出モジュール340が、切り出された文字画像を文字認識する。
ステップS810では、文字候補抽出モジュール340が、複数の文字認識結果を文字画像の文字候補として抽出する。
ステップS812では、パス限定処理モジュール350が、ネットワークを生成し、その中のパスを限定する。
ステップS814では、出力モジュール360が、文字認識結果を出力する。
FIG. 8 is a flowchart showing an example of processing according to this embodiment.
In step S802, the image reception module 310 receives a target image.
In step S804, the character string extraction module 320 extracts a character string image from the image.
In step S806, the cutout position extraction module 330 extracts the cutout position for the character string image.
In step S808, the character candidate extraction module 340 recognizes characters in the cut character image.
In step S810, the character candidate extraction module 340 extracts a plurality of character recognition results as character candidates for the character image.
In step S812, the path limitation processing module 350 generates a network and limits the paths therein.
In step S814, the output module 360 outputs a character recognition result.

次に、図9から図28を用いて、パス限定処理モジュール350による処理を説明する。
本実施の形態は、さらに、パス評価値の高いパスを出力することによって、文字切り出し位置の確定、又は文字認識を行うものである。また、パスの探索にダイナミックプログラミングの手法を用いてもよい。
本実施の形態のネットワークにおいては、始点ノード、終点ノード、複数の中間ノードがある。また、各ノード間のリンクには、リンク値を与える。始点ノードから1あるいは複数の中間ノードを介して、終点ノードに至るパスは、介するノードに依存したリンクを通ることになる。始点ノードから終点ノードに至るパスのパス評価値は、そのパスが通ったリンクのリンク値の重み付け和として表すことができる。
本実施の形態のパス限定処理モジュール350は、1つの文字画像に対して、複数の文字認識結果が存在しているときに、前述のノード、リンク、パスの構成(ネットワーク構造)を生成するものである。ネットワーク構造が与えられれば、パス限定処理モジュール350によってビタビ法などの手法を用いて、最適パスを探索することが可能となる。
Next, processing performed by the path limitation processing module 350 will be described with reference to FIGS.
In the present embodiment, the character cutout position is confirmed or the character is recognized by outputting a path having a high path evaluation value. A dynamic programming method may be used for path search.
In the network of the present embodiment, there are a start node, an end node, and a plurality of intermediate nodes. A link value is given to the link between each node. A path from the start node to one end node through one or a plurality of intermediate nodes passes through a link depending on the intervening node. The path evaluation value of the path from the start point node to the end point node can be expressed as a weighted sum of the link values of the links through which the path passes.
The path limitation processing module 350 according to the present embodiment generates the above-described node, link, and path configuration (network structure) when a plurality of character recognition results exist for one character image. It is. Given a network structure, the path limitation processing module 350 can search for an optimal path using a method such as the Viterbi method.

<A1.文字切り出し位置が固定の場合>
まず、切出位置抽出モジュール330の抽出する文字切り出し位置が固定(一種類)の場合について説明する。
図9は、記号例を示す説明図である。記号の種類として、長方形910、横棒である接続線920、922、924、927、928、円弧930、丸である文字候補942、944、946がある。
図9の例において、長方形910A、910B、910C、910D(図10に例示する長方形910)は、それぞれ文字セグメントを表す。
また、横棒である接続線920、922、924、926、928は、文字切り出し位置を示す(図11に例示する接続線920、接続線922)。文字セグメントは文字切り出し位置を介して、隣接する文字セグメントにつながっている。
さらに、丸で表されている文字候補942A、944A等は、1つの文字セグメントを1文字として認識したときの、複数の文字候補を示す。円弧930A、930B、930C、930Dは、下の1つの文字セグメントだけを対象に文字認識を行っていることを示している。
<A1. When the character cutout position is fixed>
First, the case where the character cutout position extracted by the cutout position extraction module 330 is fixed (one type) will be described.
FIG. 9 is an explanatory diagram showing a symbol example. As types of symbols, there are a rectangle 910, connecting lines 920, 922, 924, 927, 928 as horizontal bars, an arc 930, and character candidates 942, 944, 946 as circles.
In the example of FIG. 9, rectangles 910A, 910B, 910C, and 910D (rectangle 910 illustrated in FIG. 10) each represent a character segment.
Connection lines 920, 922, 924, 926, and 928 which are horizontal bars indicate character cutout positions (connection lines 920 and 922 illustrated in FIG. 11). A character segment is connected to an adjacent character segment via a character cutout position.
Furthermore, character candidates 942A, 944A, and the like represented by circles indicate a plurality of character candidates when one character segment is recognized as one character. Arcs 930A, 930B, 930C, and 930D indicate that character recognition is performed only on the lower one character segment.

図12の例では、文字候補942、944、946は、その下の長方形910が示す1文字の文字セグメントを認識したときの複数の文字候補であることを示している。また、円弧930は、その下の長方形9101つだけを対象に文字認識を行うことを示している。
本実施の形態では、文字セグメントの複数の文字候補をノードとして捉える。さらに、隣接する文字セグメントの文字候補と、リンクを接続する。図13の例にリンクを太線で記入して示す。
ここでリンク値生成処理が生成するリンク値としては、リンク左右のノードの相互作用を示すものを使ってもよい。具体的には、リンクの左の文字候補とリンクの右の文字候補が連続して日本語の文章中に出現する確率(バイグラム)を用いる。
このようにノードとリンクを構成することによって、すべてのネットワーク構造が規定できる。ネットワーク構造が規定できれば、ビタビ法等により、最適パスを選択できる。
In the example of FIG. 12, the character candidates 942, 944, and 946 indicate a plurality of character candidates when the character segment of one character indicated by the rectangle 910 below the character candidates is recognized. An arc 930 indicates that character recognition is performed on only the rectangle 9101 below the arc 930.
In the present embodiment, a plurality of character candidates in a character segment are regarded as nodes. Further, a link is connected to a character candidate of an adjacent character segment. In the example of FIG. 13, links are indicated by bold lines.
Here, as the link value generated by the link value generation process, a link value indicating the interaction between the left and right nodes of the link may be used. Specifically, the probability (bigram) that the left character candidate of the link and the right character candidate of the link appear in Japanese sentences in succession is used.
By configuring nodes and links in this way, all network structures can be defined. If the network structure can be defined, the optimum path can be selected by the Viterbi method or the like.

<A2.ノード内情報も用いる場合>
前述では、リンク値として、ノード間の相互作用を示すもの(文章中に出現する確率)だけを用いたが、さらにノード単独の評価値を用いるようにしてもよい。ここでは、ビタビ法を用いて最適パスを探索するものとする。左から順にノードの左から入るリンクをノード毎に1つだけに限定していく処理を行う。
今、図13の例で文字候補942B、944B、946Bのリンクを限定する段階であるとする。
ここで、文字候補942B、944B、946Bと、左側にある文字候補942A、944A、946A間のリンク値を生成する。リンク値としては、各ノード間の相互作用を表すバイグラムなどの値と、各ノード内部の値の両方を用いる。ノード内部の値とは、例えば、文字候補942Bの文字の認識確度などがある。
<A2. When using in-node information>
In the above description, only the link value indicating the interaction between nodes (probability of appearing in the text) is used, but an evaluation value of the node alone may be used. Here, it is assumed that the optimum path is searched using the Viterbi method. In order from the left, only one link for each node is entered from the left of the node.
Assume that it is a stage where the links of the character candidates 942B, 944B, and 946B are limited in the example of FIG.
Here, link values between the character candidates 942B, 944B, and 946B and the character candidates 942A, 944A, and 946A on the left side are generated. As a link value, both a value such as a bigram representing an interaction between nodes and a value inside each node are used. The value inside the node includes, for example, the recognition accuracy of the character candidate 942B.

ここで、リンクは、文字候補942B、944B、946Bと文字候補942A、944A、946A間にあるため、リンク値としては、文字候補942B、944B、946Bと文字候補942A、944A、946A間の評価値を算出するのが簡単である。しかし、ノード内部の値は、文字候補942B、944B、946Bと文字候補942A、944A、946A間にあるのではなく、この場合、文字候補942B、944B、946Bに存在する。
つまり、ノード間情報はリンクの内部に存在していて、ノード内情報はリンクの端点に存在する。このような発生位置、又は概念が異なる値を一度に扱う。
Here, since the link is between the character candidates 942B, 944B, 946B and the character candidates 942A, 944A, 946A, the link values are the evaluation values between the character candidates 942B, 944B, 946B and the character candidates 942A, 944A, 946A. Is easy to calculate. However, the value inside the node is not between the character candidates 942B, 944B, 946B and the character candidates 942A, 944A, 946A, but in this case, exists in the character candidates 942B, 944B, 946B.
That is, the inter-node information exists inside the link, and the intra-node information exists at the end point of the link. Such occurrence positions or values with different concepts are handled at a time.

従来では、図33に示す始点ノード3300、中間ノード3310(ノード1)、中間ノード3320(ノード2)、終点ノード3390など(つまり、文字切り出し位置)をノードとして、ノード間のアーク評価値を算出している。本実施の形態のように、複数の文字コードをノードとして、ノード間のリンク値を算出するわけではない。そのため、従来技術をそのまま用いることはできない。
本実施の形態では、リンクの評価値として、リンクの内部に存在する値(例えば、バイグラムの値)と、リンクの一方の端点のみに存在する値(例えば、文字候補942Bの文字認識確度)を用いる。他方の端点に存在する値(例えば、文字候補942Aの文字認識確度)は用いない。このようにすることで、リンクの内部の値と、リンクの端点の値をともに用いる評価が可能となる。
最終的には、文字列の評価値(パス評価値)として、(1)式で、すべてのリンクの評価値を加算することになる。そのため、リンクの評価値の中に、リンクの内部の評価値と、リンクの一方の端点の評価値が含まれていれば、パス評価値の中にすべてのリンク内部の評価値とリンク端点の評価値が1つずつ含まれることになる。
Conventionally, arc evaluation values between nodes are calculated using the start node 3300, the intermediate node 3310 (node 1), the intermediate node 3320 (node 2), the end node 3390, etc. (that is, the character extraction position) shown in FIG. 33 as nodes. doing. As in the present embodiment, a link value between nodes is not calculated using a plurality of character codes as nodes. Therefore, the prior art cannot be used as it is.
In the present embodiment, as the link evaluation value, a value (for example, bigram value) existing inside the link and a value (for example, character recognition accuracy of the character candidate 942B) existing only at one end point of the link are used. Use. The value existing at the other end point (for example, the character recognition accuracy of the character candidate 942A) is not used. By doing in this way, evaluation using both the value inside the link and the value of the end point of the link becomes possible.
Eventually, the evaluation values of all the links are added by the expression (1) as the evaluation value (path evaluation value) of the character string. Therefore, if the link evaluation value includes the evaluation value inside the link and the evaluation value at one end of the link, the evaluation values inside all the links and the link end points are included in the path evaluation value. One evaluation value is included.

リンク値生成処理では、前述のリンク内部の値と、リンク端点の値のように、複数の値(バイグラムや認識確度)などを特徴量として、リンク値を算出すればよい。このように複数の値から、1つのリンク値を算出する方法としては、(1)特開平9−185681号公報、(2)特開昭61−175878号公報、(3)特開平3−37782号公報、(4)特開平11−203406号公報等に記載の技術を用いればよい。これ以外の方法であってもよい。
なお、複数の値を特徴量ベクトルとして把握し、リンク値は、特徴量ベクトルを対象として、リンク評価値(スカラー値)を出力する関数で実現できる。
In the link value generation process, a link value may be calculated using a plurality of values (bigram and recognition accuracy) as feature quantities, such as the above-described link internal value and link end point value. As described above, methods for calculating one link value from a plurality of values include (1) Japanese Patent Laid-Open No. 9-185681, (2) Japanese Patent Laid-Open No. 61-175878, and (3) Japanese Patent Laid-Open No. 3-37782. No. 4, (4) Japanese Patent Laid-Open No. 11-203406, etc. may be used. Other methods may be used.
Note that a plurality of values can be grasped as a feature vector, and the link value can be realized by a function that outputs a link evaluation value (scalar value) for the feature vector.

<A3.リンク情報として2以上のノードを用いる場合>
前述では、リンク左右のノードの相互情報としてバイグラムを用いていた。この場合、リンク情報として2つのノード間の関係情報を用いていることになる。
ビタビ法を用いる場合、例えば、ノードである文字候補942A、944A、946Aの左側のリンク数はすでに1個に限定されていることになる。この場合には、2以上のノードの情報を用いてリンク情報を構築することが可能となる。
例えば、2つの連続する文字の生起確率であるバイグラムではなく、3つの連続する文字の生起確率であるトライグラムを用いることも可能となる。
今、リンク値生成処理では、ノードである文字候補942B、944B、946Bの左側のリンク値を生成しようとする。
例えば、文字候補942A−文字候補942B間のリンク値を算出する。バイグラムであれば、文字候補942Aと文字候補942Bが連続する生起確率を求めればよい。ここで、トライグラムを求める場合を説明する。文字候補942Aの左側のリンクは1つに限定されているため、実は、文字候補942Aの左の文字も確定していることになる。この文字を保持するノードをGとする。トライグラムとしては、ノードG−ノード(文字候補942A)−ノード(文字候補942B)の3つの文字に関する生起確率を求めればよい。
以上のように求めたトライグラムをノード(文字候補942A)−ノード(文字候補942B)間のリンク値として生成すればよい。同様に、Ngramであっても、求めることが可能となる。
<A3. When using two or more nodes as link information>
In the above, a bigram is used as mutual information between the left and right nodes of the link. In this case, the relationship information between the two nodes is used as the link information.
When the Viterbi method is used, for example, the number of links on the left side of the character candidates 942A, 944A, and 946A that are nodes is already limited to one. In this case, link information can be constructed using information of two or more nodes.
For example, it is possible to use a trigram which is the occurrence probability of three consecutive characters instead of the bigram which is the occurrence probability of two consecutive characters.
Now, in the link value generation process, an attempt is made to generate link values on the left side of the character candidates 942B, 944B, and 946B that are nodes.
For example, the link value between the character candidate 942A and the character candidate 942B is calculated. If it is a bigram, what is necessary is just to obtain | require the occurrence probability that the character candidate 942A and the character candidate 942B continue. Here, a case where a trigram is obtained will be described. Since the left link of the character candidate 942A is limited to one, the character on the left of the character candidate 942A is actually confirmed. Let G be the node that holds this character. As the trigram, the occurrence probabilities relating to the three characters of node G-node (character candidate 942A) -node (character candidate 942B) may be obtained.
The trigram obtained as described above may be generated as a link value between the node (character candidate 942A) and the node (character candidate 942B). Similarly, even Ngram can be obtained.

<A4.文字切り出し位置が確定していない場合>
文字切り出し位置が確定していない場合(つまり、切出位置抽出モジュール330が複数の文字切り出し位置を抽出した場合であり、具体的には、「化」のように、「イ」と「ヒ」、あるいは、「化」のどちらになるか分からない場合)、文字候補の選択と、文字切り出し位置の選択を行うようにしてもよい。文字切り出し位置が確定していない場合、文字候補の選択は、文字切り出し位置の選択となる。
図14は、文字切り出し位置が複数ある場合の処理例を示す説明図である。ここでは、円弧の記号の意味が追加されている。円弧が下にある複数の文字セグメント(長方形)を指し示す場合、その円弧はその複数の文字セグメントを統合した画像を1文字とみなして認識することを示す。円弧1410Aは、長方形910Aと長方形910Bを統合した画像を1文字とみなして文字認識結果として文字候補1422A、1424A、1426Aを有している。また、円弧1410Cは、長方形910A、910B、910C、910Dを統合した画像を1文字とみなして文字認識結果として文字候補1422C、1424C、1426Cを有している。
図15の例に示すように、円弧930Aと円弧930Bの下に2つの文字セグメント(長方形910A、長方形910B)「イ」と「ヒ」がある場合に、その2つを含む円弧1410の上の文字候補(文字候補1422、1424、1426)は、「イ」と「ヒ」を統合した1つの文字セグメント「化」を認識したときの複数の文字候補に相当する。
<A4. When the character cutout position is not fixed>
When the character cutout position is not fixed (that is, when the cutout position extraction module 330 has extracted a plurality of character cutout positions, specifically, “I” and “H”, such as “B”. Alternatively, when it is not known which of the two is “change”, the selection of the character candidate and the selection of the character cutout position may be performed. When the character cutout position is not fixed, the character candidate selection is the character cutout position selection.
FIG. 14 is an explanatory diagram illustrating a processing example when there are a plurality of character cutout positions. Here, the meaning of the symbol of the arc is added. When the arc indicates a plurality of character segments (rectangles) below, the arc indicates that an image obtained by integrating the plurality of character segments is recognized as one character. The arc 1410A has character candidates 1422A, 1424A, and 1426A as character recognition results by regarding the image obtained by integrating the rectangle 910A and the rectangle 910B as one character. In addition, the arc 1410C has character candidates 1422C, 1424C, and 1426C as character recognition results by regarding an image obtained by integrating the rectangles 910A, 910B, 910C, and 910D as one character.
As shown in the example of FIG. 15, when there are two character segments (rectangle 910A, rectangle 910B) “I” and “HI” below the arcs 930A and 930B, the arc 1410 including the two character segments Character candidates (character candidates 1422, 1424, and 1426) correspond to a plurality of character candidates when one character segment “formation” in which “I” and “HI” are integrated is recognized.

文字切り出し位置が確定していない場合のリンクの接続は、図16の例に示すようになる。図16は、文字切り出し位置が複数ある場合の処理例を示す説明図である。
ここでは、文字切り出し位置に注目する。今、図16の矢印で示す文字切り出し位置に関連するノードのリンクを対象とする。この文字切り出し位置でリンクされるノードには、
(1)左側ノード:矢印の文字切り出し位置に円弧の右側が存在するノード(斜線でハッチングしたノード、文字候補1642A、文字候補1644A、文字候補1662A、文字候補1664A、文字候補1672A、文字候補1674A等)と、
(2)右側ノード:矢印の文字切り出し位置に円弧の左側が存在するノード(内部が白のノード、文字候補1642B、文字候補1644B、文字候補1662B、文字候補1664B、文字候補1672B、文字候補1674B等)
の2種類がある。このとき、左側ノードと、右側ノード間にリンクを形成することによって、グラフ構造を構築することができる。
例えば、すべての左側ノードが、すべての右側ノードに直接接続できるようにリンクを形成すればよい。さらに、すべての文字切り出し位置において、前述のように、左側ノードと右側ノードのリンクを形成し、さらに、左側が文字列の端点の場合には始点ノードに接続し、また、右側が文字列の端点の場合には終端ノードに接続すれば、すべてのグラフ構造を構築することができる。
The link connection when the character cutout position is not fixed is as shown in the example of FIG. FIG. 16 is an explanatory diagram illustrating a processing example when there are a plurality of character cutout positions.
Here, attention is focused on the character cutout position. Now, the node link related to the character cutout position indicated by the arrow in FIG. 16 is targeted. The nodes linked at this character cut-out position include
(1) Left node: a node on the right side of the arc at the character cutout position of the arrow (a hatched node, character candidate 1642A, character candidate 1644A, character candidate 1662A, character candidate 1664A, character candidate 1672A, character candidate 1673A, etc. )When,
(2) Right node: a node in which the left side of the arc is present at the character cut-out position of the arrow (inner white node, character candidate 1642B, character candidate 1644B, character candidate 1662B, character candidate 1664B, character candidate 1672B, character candidate 1673B, etc. )
There are two types. At this time, a graph structure can be constructed by forming a link between the left node and the right node.
For example, a link may be formed so that all left nodes can be directly connected to all right nodes. Furthermore, as described above, a link between the left node and the right node is formed at all character cutout positions, and if the left side is the end point of the character string, it is connected to the start point node, and the right side is the character string In the case of an end point, all graph structures can be constructed by connecting to the end node.

この場合においても、リンク値は、リンク左右のノードの相互作用を示すものを使ってもよいし、ノード内部の評価値を用いてもよい。
特に、この場合には、文字切り出し位置が確定していないため、ノード内部の評価値として、文字の形状情報を用いることができる。文字形状情報の例として、文字の縦横比や、文字左右の空白量、等を用いることができる。
Also in this case, the link value may be one indicating the interaction between the left and right nodes of the link, or an evaluation value inside the node may be used.
In particular, in this case, since the character cutout position is not fixed, the character shape information can be used as the evaluation value inside the node. As an example of the character shape information, the aspect ratio of the character, the amount of white space on the left and right of the character, and the like can be used.

このようにすることによって、文字列の左端から、文字列の右端に至るすべてのパスを書き出すことができる。各パスは、認識出力文字列に該当する。つまり、文字列を構成するネットワークにおいて、左端ノードから、右端ノードへ至るパスを決定することによって、文字列を決定できることになる。   In this way, all paths from the left end of the character string to the right end of the character string can be written out. Each path corresponds to a recognized output character string. That is, in the network constituting the character string, the character string can be determined by determining the path from the left end node to the right end node.

以上をまとめると、文字列を構成するネットワークは、例えば、図17のようになる。図17の例において、○は、ノードを示す。○と○を接続する実線は、ノード間の接続を示すアークあるいはリンクである。ノードAは、文字列の左端を示し、ノードBは、文字列の右端を示す。このネットワークにおいて、左端ノードAから、右端ノードBへ至るパスを決定することによって、文字列を決定できることになる。   Summarizing the above, the network constituting the character string is, for example, as shown in FIG. In the example of FIG. 17, ◯ indicates a node. A solid line connecting ○ and ○ is an arc or a link indicating a connection between nodes. Node A indicates the left end of the character string, and node B indicates the right end of the character string. In this network, a character string can be determined by determining a path from the left end node A to the right end node B.

これらのパスの中で、正規表現にマッチするものだけを出力するようにすればよい。しかしながら、パスの数は膨大であるので、すべてのパスに対して正規表現にマッチしているかどうかをチェックすることは現実的ではない。
そこで、ビタビ法を用いて高速化する。
前述したように、あるノードに左から接続されるリンクの本数を1本に限定するようにしていく。もちろんのことながら、あるノードに右から接続されるリンクの本数を1本に限定するようにしてもよいが、以下の例では、左から接続されるリンクについて説明する。
ここで、あるノードに左から接続されるリンクを決定すれば、そのノードに至る出力文字列が確定できる。この出力文字列が正規表現に部分一致しているかどうかをチェックすればよい。
Of these paths, only those that match the regular expression need be output. However, since the number of paths is enormous, it is not practical to check whether all paths match the regular expression.
Therefore, the speed is increased by using the Viterbi method.
As described above, the number of links connected to a certain node from the left is limited to one. Of course, the number of links connected to a certain node from the right may be limited to one, but in the following example, a link connected from the left will be described.
Here, if a link connected to a certain node from the left is determined, an output character string reaching that node can be determined. What is necessary is just to check whether this output character string partially matches the regular expression.

まず、あるノードに左から接続されるリンクが、N本あるとする。N本のリンクのうち、正規表現に部分一致しているものだけを抽出し、部分一致していないものを捨てる。
図18の例を用いて説明する。図18は、文字列を構成するネットワーク内のノードが接続されている例を示す説明図である。
例えば、ノードD(文字候補「会」)に左から3本のリンクが接続されているとする。そして、そのリンクはそれぞれノードA(文字列候補「ヒ学」)、ノードB(文字列候補「化学」)、ノードC(文字列候補「ト学」)から接続されているとする。ここで、正規表現が、「化学会議」とされているとする。
ノードA、B、Cには、さらに左からノードが接続されているが、その部分は説明では省略している。ノードA、B、Cに関しては、すでに、左側のノードが1本に限定されているため、それらのノードに至るパスが確定している。そのため、それらのノードに至る文字列も確定している。ノードAの文字列候補は「ヒ学」、ノードBの文字列候補は「化学」、ノードCの文字列候補は「ト学」となっている。
ここで、ノードDに左から接続されるリンクを確定させる。ノードAからのパスであれば、文字列は「ヒ学会」であり、ノードBからのパスであれば、文字列は「化学会」であり、ノードCからのパスであれば、文字列は「ト学会」となる。この中で、正規表現である文字列パターンに部分一致するものを選択する。
First, it is assumed that there are N links connected to a certain node from the left. Of the N links, only those that partially match the regular expression are extracted, and those that do not partially match are discarded.
This will be described with reference to the example of FIG. FIG. 18 is an explanatory diagram showing an example in which nodes in a network constituting a character string are connected.
For example, it is assumed that three links from the left are connected to the node D (character candidate “meeting”). The links are connected from node A (character string candidate “Higaku”), node B (character string candidate “Chemistry”), and node C (character string candidate “Gaku”). Here, it is assumed that the regular expression is “chemical meeting”.
Nodes A, B, and C are further connected from the left, but that portion is omitted in the description. Regarding nodes A, B, and C, the number of nodes on the left side is already limited to one, and the paths to those nodes are already determined. Therefore, the character strings that reach those nodes are also determined. The character string candidate of node A is “Higaku”, the character string candidate of node B is “chemistry”, and the character string candidate of node C is “gaku”.
Here, the link connected to the node D from the left is determined. If it is a path from node A, the character string is “Higaku society”, if it is a path from node B, the character string is “Chemical Society”, and if it is a path from node C, the character string is It becomes "Togaku Gakkai". Among them, the one that partially matches the character string pattern that is a regular expression is selected.

ここで、文字列が文字列パターンに部分一致するとは、文字列が、正規表現「化学会議」の先頭から連続する部分に一致すればよいというものである。例えば、「化学会」は、正規表現「化学会議」の最初から3文字目までは一致するので、部分一致しているとする。その他の、「ヒ学会」、「ト学会」は部分一致しない。
したがって、部分一致とは、文字列がXであるとき、Xの後ろに任意の文字が続くとみなして、後ろに任意の文字が続く文字列が先頭から正規表現に一致しているかどうかを判断するとしてもよい。
Here, the partial matching of the character string with the character string pattern means that the character string only needs to match a portion continuous from the beginning of the regular expression “Chemical Conference”. For example, “Chemical Society” matches the first to third characters of the regular expression “Chemical Conference”, so it is assumed that they partially match. Others such as “Higaku Gakkai” and “Gaku Gakkai” do not match.
Therefore, partial match means that when a character string is X, it is assumed that an arbitrary character follows X, and whether or not the character string followed by an arbitrary character matches the regular expression from the beginning. You may do that.

ここで、部分一致しているものが複数ある場合には、正規表現を用いた方式とは別のやり方で最も評価値の高いものを選択すればよい。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。
さらに、部分一致しているものがない場合には、すべての候補の中から、正規表現とは異なる方法で最も評価値の高いものを選択すればよい。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。
以上のようにして、各ノードにおいて、左側のリンクを1つに絞る。最終的に、左端から右端に向かう複数のパスが残るので、その中から出力すべきパスを得ればよい。
Here, when there are a plurality of partial matches, the one with the highest evaluation value may be selected by a method different from the method using the regular expression. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used.
Furthermore, if there is no partial match, the candidate with the highest evaluation value may be selected from all candidates using a method different from the regular expression. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used.
As described above, the link on the left side is narrowed down to one at each node. Finally, since a plurality of paths from the left end to the right end remain, it is sufficient to obtain a path to be output from among them.

<パス限定処理モジュール350の例1>
図19は、パス限定処理モジュール350内のモジュール構成例を示す説明図である。パス限定処理モジュール350は、ネットワーク構築処理モジュール130、ノード数限定処理モジュール1920、制御モジュール1930、出力決定処理モジュール160を有している。
図20は、パス限定処理モジュール350による処理例を示すフローチャートである。
ステップS2002では、ネットワーク構築処理モジュール130が、ネットワークを構築する。
ステップS2004では、ノード数限定処理モジュール1920が、制御モジュール1930による制御によって、ネットワーク内のノードを限定する。
ステップS2006では、出力決定処理モジュール160が、出力すべきパスを決定する。
<Example 1 of the path limitation processing module 350>
FIG. 19 is an explanatory diagram showing a module configuration example in the path limitation processing module 350. The path limitation processing module 350 includes a network construction processing module 130, a node number limitation processing module 1920, a control module 1930, and an output determination processing module 160.
FIG. 20 is a flowchart illustrating an example of processing performed by the path limitation processing module 350.
In step S2002, the network construction processing module 130 constructs a network.
In step S2004, the node number limitation processing module 1920 limits the nodes in the network under the control of the control module 1930.
In step S2006, the output determination processing module 160 determines a path to be output.

ネットワーク構築処理モジュール130は、ノード数限定処理モジュール1920と接続されている。ネットワーク構築処理モジュール130は、文字候補抽出モジュール340によって抽出された複数の文字候補の各々をノードとし、隣接する文字画像のノード間にリンクを構築することによってネットワークを生成する。つまり、前述したように、文字列の一方の端(例えば、左端)から他方の端(例えば、右端)に至るネットワークを構築する。
ノード数限定処理モジュール1920は、ネットワーク構築処理モジュール130、制御モジュール1930、出力決定処理モジュール160と接続されている。ノード数限定処理モジュール1920は、ネットワーク構築処理モジュール130によって生成されたネットワーク内のノードに先頭方向又は最後尾方向のいずれか一方向から接続するリンクに対して、予め定められた文字列パターンに合致するリンクに限定する。つまり、前述したように、各ノードにおいて、例えば左から接続されるノード数を限定する処理を行う。例えば、限定するノード数として1つである。
The network construction processing module 130 is connected to the node limit processing module 1920. The network construction processing module 130 uses each of the plurality of character candidates extracted by the character candidate extraction module 340 as a node, and creates a network by constructing a link between adjacent character image nodes. That is, as described above, a network is constructed from one end (for example, the left end) of the character string to the other end (for example, the right end).
The node limit processing module 1920 is connected to the network construction processing module 130, the control module 1930, and the output determination processing module 160. The node limit processing module 1920 matches a predetermined character string pattern with respect to a link connected to a node in the network generated by the network construction processing module 130 from either the first direction or the last direction. Limited to links. That is, as described above, for each node, for example, processing for limiting the number of nodes connected from the left is performed. For example, the number of nodes to be limited is one.

制御モジュール1930は、ノード数限定処理モジュール1920と接続されている。制御モジュール1930は、ノード数を限定するノード位置を左から順になるように制御するものである。
本実施の形態では、制御モジュール1930において、右端の終点ノードにおけるノード数を1本に限定する処理は行わない。すなわち、右端の終点ノードに入るリンク数(アーク数)が、M本であれば、最終的にM本のパスが残ることになる。M本のパスは、M個の文字列に相当している。
The control module 1930 is connected to the node number limitation processing module 1920. The control module 1930 controls the node positions that limit the number of nodes in order from the left.
In the present embodiment, the control module 1930 does not perform processing for limiting the number of nodes in the rightmost end node to one. That is, if the number of links (number of arcs) entering the rightmost end node is M, M paths will eventually remain. The M paths correspond to M character strings.

出力決定処理モジュール160は、ノード数限定処理モジュール1920と接続されている。出力決定処理モジュール160は、ノード数限定処理モジュール1920によって限定されたリンクによってつながれたパス内の文字候補列を文字認識結果として出力する。つまり、前述のM個の文字列の中から、出力すべき文字列を選択する。例えば、図17の例では、右端の終点ノードBに3つのリンクが接続されている場合、3本の文字列候補が残ることになる。この3つの候補から出力すべき文字列を選択する。
このようにするのは、途中の部分一致では、文字列の後ろ側に一致していない文字数を評価することができないためである。文字列全体として、文字列の前側と後ろ側の不一致数を合わせて不一致数の最も少ないものを選択するため、M個の文字列に関して、評価を行う。
また、制御モジュール1930において、右端の終点ノードにおける入力ノード数を1本になるまで選択してもよい。出力決定処理モジュール160では、その1本化した文字列の中から、正規表現にマッチする最も長い部分がある文字列を選択する。
The output determination processing module 160 is connected to the node number limitation processing module 1920. The output determination processing module 160 outputs the character candidate string in the path connected by the link limited by the node number limitation processing module 1920 as a character recognition result. That is, the character string to be output is selected from the M character strings described above. For example, in the example of FIG. 17, when three links are connected to the rightmost end node B, three character string candidates remain. A character string to be output is selected from these three candidates.
This is because the number of characters that do not match the back side of the character string cannot be evaluated by partial matching in the middle. In order to select the character string having the smallest number of mismatches by combining the number of mismatches between the front side and the back side of the character string, the M character strings are evaluated.
Further, in the control module 1930, the number of input nodes at the rightmost end node may be selected until one. The output determination processing module 160 selects a character string having the longest portion matching the regular expression from the single character string.

「出力すべき文字列」を選択する評価尺度は、さまざまあって、下記のいずれか等を選択すればよい。
(1)評価尺度1
正規表現に最長一致するものを選ぶ。
最長一致するものが複数ある場合には、最もパス評価値の高い文字列を選ぶ。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。
変形例として、最長一致するものの文字数が所定の文字数未満である場合は、リジェクトとする。
(1.1)変形例(その1)
文字列の左端や右端が正規表現に一致しない場合、その一致しない左端や右端を除いた部分を抜き出して、その部分のみを正規表現に一致したとして、出力する。例えば、正規表現が「化学会議」で、文字列が「AB化学会議C」の場合、「AB」と「C」を取り除いた「化学会議」を出力する。このとき、取り除いた左端「AB」と右端「C」の文字数は計3文字となる。この取り除いた文字数が最も少ない文字列を選択する。
(1.2)変形例(その2)
前述の例で、「化学会議」となっている画像中の文字列の長さ(例えば、画像の画素数や、スキャン前の紙におけるセンチ数など)が最も長いものを選択してもよい。つまり、除去するノイズの量が画像中で最も小さいものを選択する。
There are various evaluation scales for selecting “character string to be output”, and any one of the following may be selected.
(1) Evaluation scale 1
Choose the longest match for a regular expression.
If there are multiple longest matches, the character string with the highest path evaluation value is selected. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used.
As a modified example, when the number of characters of the longest match is less than a predetermined number of characters, it is rejected.
(1.1) Modification (Part 1)
If the left end or right end of the character string does not match the regular expression, the portion excluding the left end or right end that does not match is extracted, and only that portion is output as the regular expression. For example, if the regular expression is “Chemical Conference” and the character string is “AB Chemical Conference C”, “Chemical Conference” is output by removing “AB” and “C”. At this time, the number of characters at the left end “AB” and the right end “C” removed is a total of three characters. The character string with the smallest number of removed characters is selected.
(1.2) Modification (Part 2)
In the above-described example, the character string in the image that is “chemical meeting” (for example, the number of pixels of the image or the number of centimeters on the paper before scanning) may be selected. That is, the smallest noise in the image is selected.

(2)評価尺度2
正規表現に合致する文字列の長さは規定せず、正規表現に合致するものの中で、最もパス評価値の高い文字列を選ぶ。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。
出力文字列の中に、正規表現にマッチする部分があればよい。例えば、正規表現が「化学会議」であるとして、文字列が、「前化学会議A」であるとき、1文字目と6文字目を省いて、「化学会議」という部分だけを出力することになる。
また、正規表現に完全に一致するときのみ採用するとしてもよい。
(2) Evaluation scale 2
The length of the character string that matches the regular expression is not specified, and the character string having the highest path evaluation value is selected from those that match the regular expression. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used.
There should be a part that matches the regular expression in the output string. For example, if the regular expression is “Chemical Conference” and the character string is “Previous Chemical Conference A”, the first and sixth characters are omitted, and only the part “Chemical Conference” is output. Become.
Further, it may be adopted only when it completely matches the regular expression.

(3)評価尺度3
左端から右端までの全文字列が正規表現に一致すれば、その文字列を出力する。複数のパスが合致する場合は、最もパス評価値の高い文字列を選ぶ。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。ただし、左端から右端までの全文字列の中で、正規表現に一致するものがない場合は、出力がない(リジェクト)とする。
(3) Evaluation scale 3
If all character strings from the left end to the right end match the regular expression, that character string is output. If multiple paths match, select the character string with the highest path evaluation value. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used. However, if none of the character strings from the left end to the right end match the regular expression, there is no output (reject).

<パス限定処理モジュール350の例2>
前述のパス限定処理モジュール350の例1では、文字列の左端から、部分一致するノードを選択することになる。
ところが、部分一致では、文字列の先頭から、正規表現に一致する必要がある。
文字列の先頭部分には、ノイズが発生する場合が多い。ノイズが発生した場合には、文字列の最初から部分一致する文字列が存在しない場合がある。例えば、文字列の最初に縦棒のノイズが存在している場合、多くの出力文字列の1文字目に、「1」という文字が入ってしまう場合がある。
このような場合、ネットワーク構築処理で構築されたすべてのパスが部分一致しないことになってしまい、正規表現のマッチングが不可能となる。部分一致とは、文字列の先頭から一致することであるためである。
そこで、文字列の最初にノイズが混入した場合の不安定性を排除することを行う。
<Example 2 of the path limitation processing module 350>
In Example 1 of the path limitation processing module 350 described above, a partially matching node is selected from the left end of the character string.
However, in partial matching, it is necessary to match the regular expression from the beginning of the character string.
Noise often occurs at the beginning of the character string. When noise occurs, there may be no character string that partially matches from the beginning of the character string. For example, when there is vertical bar noise at the beginning of a character string, the character “1” may be included in the first character of many output character strings.
In such a case, all the paths constructed by the network construction process will not partially match, and regular expression matching becomes impossible. This is because partial matching means matching from the beginning of the character string.
Therefore, instability when noise is mixed at the beginning of the character string is eliminated.

そのために、ノード数を限定する処理として、各リンクに対して、下記の処理を行う。
(1)I=1とする。
(2)文字列のI文字目から部分一致しているかどうかをチェックする。
(3)部分一致していれば終了。
(4)Iが文字列の最後であれば終了。
(5)部分一致していなければ、I=I+1として(2)に戻る。
そして、変数Iの値を用いて、各リンクに対して、何文字目から部分一致したかを計測する。その計測したIを用いて、ノード数限定処理モジュール1920における処理では、下記の方法によって入力ノード数を限定する。
・部分一致しているパスの中で、Iの値が最も小さい入力ノードを選ぶ。
・部分一致しているパスの中で、最も小さいIの値が複数ある場合(Iの値が同じ場合)、パス評価値が最も大きなノードを選ぶ。
・部分一致しているパスがない場合、パス評価値が最も大きなノードを選ぶ。
このようにすることで、文字列の最初にノイズが混入した場合の不安定性を排除する。
Therefore, as a process for limiting the number of nodes, the following process is performed for each link.
(1) I = 1.
(2) It is checked whether or not a partial match is made from the I character in the character string.
(3) End if partial match.
(4) If I is the end of the character string, the process ends.
(5) If there is no partial match, set I = I + 1 and return to (2).
Then, by using the value of the variable I, it is measured how many characters have been partially matched for each link. Using the measured I, the number of input nodes is limited by the following method in the processing in the node limit processing module 1920.
-Select the input node with the smallest value of I among the partially matched paths.
When there are a plurality of smallest I values (particularly the same I value) among the partially matched paths, the node with the largest path evaluation value is selected.
If there is no partially matching path, select the node with the largest path evaluation value.
By doing so, instability when noise is mixed at the beginning of the character string is eliminated.

<パス限定処理モジュール350の例3>
また、パス限定処理モジュール350は、正規表現に完全に一致する文字列がない場合、部分一致文字列を出力するようにしてもよい。
前述のパス限定処理モジュール350の例1、2では、与えられた文字列パターン(正規表現)に一致するパス(文字列)を出力していた。ただし、一部でもよいから、一致するものを出力したいという場合もあり得る。例えば、前述の市名の例で、図21の例のような認識結果が得られたとする。また、正解は「横浜」であるとする。
<Example 3 of the path limitation processing module 350>
Further, the path limitation processing module 350 may output a partially matched character string when there is no character string that completely matches the regular expression.
In Examples 1 and 2 of the path limitation processing module 350 described above, a path (character string) that matches a given character string pattern (regular expression) is output. However, since it may be a part, it may be desired to output a match. For example, it is assumed that the recognition result as in the example of FIG. The correct answer is “Yokohama”.

この場合、「横浜」となるパスは存在しないので、正規表現にマッチする文字列を出力することはできない。
文字認識後に、人間が認識結果を修正する場合がある。出力されない場合(リジェクトされる場合)、人間は「横浜」と2文字を入力する必要がある。ところが、「横」という文字は文字認識結果として存在している。「横」だけでも出力できれば、人間は、「浜」の1字だけを入力すればよいことになる。
パス限定処理モジュール350は以下の処理を行う。
(1)部分一致を検証するときに、部分一致する文字列の文字長が最長になる場合を記録しておく。文字列そのものか、パスの位置を記録しておけばよい。
(2)出力決定処理モジュール160における処理において、正規表現にマッチする文字列があれば、それを出力する。
(3)出力決定処理モジュール160における処理において、正規表現にマッチする文字列がない場合、部分一致文字長が最長となる文字列を出力する。
そして、文字認識結果を確認、修正する操作者には、部分一致でも出力するか否かの判断を表示装置に提示し、部分一致でも出力するが選択された場合は、(3)の処理を行うようにしてもよい。
In this case, since there is no path of “Yokohama”, a character string that matches the regular expression cannot be output.
After character recognition, a human may correct the recognition result. If it is not output (if it is rejected), the human must input “Yokohama” and two characters. However, the character “horizontal” exists as a character recognition result. If only “horizontal” can be output, a human needs to input only one character of “beach”.
The path limitation processing module 350 performs the following processing.
(1) When verifying a partial match, record the case where the character length of the partially matched character string is the longest. You can record the string itself or the location of the path.
(2) In the processing in the output determination processing module 160, if there is a character string that matches the regular expression, it is output.
(3) When there is no character string that matches the regular expression in the processing in the output determination processing module 160, the character string having the longest partial match character length is output.
Then, the operator who confirms and corrects the character recognition result is presented with a determination as to whether or not partial matching is output, and if the partial matching output is selected, the processing of (3) is performed. You may make it perform.

以上、述べたように、図22に示されるような、限定文字列パターン検査処理が行われる。つまり、前述のパス限定処理モジュール350に該当する限定文字列パターン検査処理モジュール2200は、限定文字列パターン108と対象文字列118を受け付けて、検査結果162を出力する。
限定文字列パターン108は、文字列パターンを限定するための情報であり、典型的には、前述した正規表現が該当する。
限定文字列パターン検査処理モジュール2200では、限定文字列パターン108と対象文字列118を受け付ける。対象文字列118が限定文字列パターン108に合致すれば、検査結果162として、「合致」を出力する。対象文字列118が限定文字列パターン108に合致しなければ、検査結果162として、「非合致」を出力する。
検査としては、以下の2種類がある。いずれかの検査を行う。
(検査1)文字列が完全に合致する場合のみを「合致」として、それ以外を「非合致」とする完全検査。
(検査2)文字列と限定文字列パターン(正規表現)が、従来技術で述べた部分一致する場合も、「合致」とし、それ以外を「非合致」とする部分一致検査。
As described above, the limited character string pattern inspection process as shown in FIG. 22 is performed. That is, the limited character string pattern inspection processing module 2200 corresponding to the above-described path limitation processing module 350 receives the limited character string pattern 108 and the target character string 118 and outputs the inspection result 162.
The limited character string pattern 108 is information for limiting the character string pattern, and typically corresponds to the regular expression described above.
The limited character string pattern inspection processing module 2200 receives the limited character string pattern 108 and the target character string 118. If the target character string 118 matches the limited character string pattern 108, “match” is output as the inspection result 162. If the target character string 118 does not match the limited character string pattern 108, “non-match” is output as the inspection result 162.
There are the following two types of inspections. Do one of the tests.
(Inspection 1) Complete inspection in which “match” is set only when the character string completely matches, and “non-match” is set otherwise.
(Inspection 2) Partial match inspection in which a character string and a limited character string pattern (regular expression) are also “matched” when the partial match described in the prior art is “matched” and the rest is “nonmatched”.

例えば、限定文字列パターン108として正規表現を採用し、その内容を、
横浜|川崎|横須賀
とする。
完全検査の場合、「対象文字列118が、「横浜」であるときは、検査結果として、「合致」を出力する」、又は、「対象文字列118が「黄浜」のときや、対象文字列118が「横」のとき、検査結果162として、「非合致」を出力する」、等の動作を行う。
部分一致検査の場合、「対象文字列118が、「横浜」や、対象文字列118が「横」のときは、検査結果162として、「合致」を出力する」、又は、「対象文字列118が「黄浜」のとき、検査結果162として、「非合致」を出力する」、等の動作を行う。
「対象文字列118が「横」であるときは、検査結果162として、「合致」を出力する」、又は、「対象文字列118が「黄浜」のときは、検査結果162として、「非合致」を出力する」、等の動作を行う。
前述の処理を実現するためには、このような、限定文字列パターン検査処理を行う。
ここで、限定文字列パターン108が長大である場合がある。例えば、都道府県名を限定文字列パターン108として受け付ける場合、50個程度の県名を、論理和を示す記号「|」をはさんで記入する必要がある。市名であれば、1000個程度オーダー数の市名を、論理和を示す記号「|」をはさんで記入する必要がある。
このような長大な正規表現を処理することが必要である。特に図36の例に示すような複数のパスの中から最適なパスを選ぶような処理を行う場合、限定文字列パターン検査処理の処理回数が多くなり、そのため、全体の処理量や処理時間も増大することとなる。
For example, a regular expression is adopted as the limited character string pattern 108, and the content is
Yokohama | Kawasaki | Yokosuka.
In the case of a complete inspection, “when the target character string 118 is“ Yokohama ”,“ match ”is output as the inspection result” or “when the target character string 118 is“ Kohama ”or the target character When the column 118 is “horizontal”, an operation such as “output“ non-match ”” as the inspection result 162 is performed.
In the case of partial match inspection, “when the target character string 118 is“ Yokohama ”or the target character string 118 is“ horizontal ”,“ match ”is output as the inspection result 162”, or “target character string 118 Is “Kamahama”, the operation result such as “output“ non-match ”” as the inspection result 162 is performed.
“When the target character string 118 is“ horizontal ”,“ match ”is output as the test result 162”, or “when the target character string 118 is“ Kohama ”, the test result 162 is“ non- Operations such as “output match” are performed.
In order to realize the above-described processing, such limited character string pattern inspection processing is performed.
Here, the limited character string pattern 108 may be long. For example, when a prefecture name is received as the limited character string pattern 108, it is necessary to enter about 50 prefecture names with a symbol “|” indicating a logical sum. If it is a city name, it is necessary to enter the city name of the order number of about 1000 with the symbol “|” indicating the logical sum.
It is necessary to process such a long regular expression. In particular, when performing the process of selecting the optimum path from a plurality of paths as shown in the example of FIG. 36, the number of times of the limited character string pattern inspection process increases, so that the overall processing amount and processing time are also increased. Will increase.

ここで、限定文字列パターン108を正規表現として、対象文字列118が正規表現に合致しているかどうかを検査する場合について説明する。正規表現は汎用的なパターンの記述方法であるため、パターンの記述の仕方によっては、合致/非合致の検査の処理が低速になる。
そこで、本実施の形態では、限定文字列パターン108の記述を分解する。
限定文字列パターン108が、文字列の単純な羅列で与えられた場合を対象とする。例えば、図23の例に示すように、限定したい文字列(文字列(横浜)2310、文字列(川崎)2320、文字列(横須賀)2330)が単純に並んでいる場合(つまり、論理和として文字列が接続されている場合)について説明する。
以下、このような文字列の羅列を文字列集合と呼ぶ。
文字列集合は、前述したような、何かの記号で分離可能なテキストコードであってもよいし、文字列の配列であってもよいし、その他の、集合を表現可能なデータ形式であればよい。
データ集合Aがあって、入力データxが、集合A内のデータと一致するかどうかを判定するようなアルゴリズムが種々存在している。このようなアルゴリズムを用いて、前述したような文字列集合との合致を判定することができる。
例えば、2分木検索、赤黒木検索、トライ木検索、ハッシュ法等などの方法を用いることができる。
Here, a case will be described in which the limited character string pattern 108 is used as a regular expression to check whether the target character string 118 matches the regular expression. Since the regular expression is a general-purpose pattern description method, the matching / non-matching inspection process becomes slow depending on the pattern description method.
Therefore, in the present embodiment, the description of the limited character string pattern 108 is decomposed.
The case where the limited character string pattern 108 is given as a simple enumeration of character strings is targeted. For example, as shown in the example of FIG. 23, a character string (character string (Yokohama) 2310, character string (Kawasaki) 2320, character string (Yokosuka) 2330) to be limited is simply arranged (that is, as a logical sum) (When a character string is connected).
Hereinafter, such a list of character strings is referred to as a character string set.
The character string set may be a text code that can be separated by any symbol as described above, an array of character strings, or any other data format that can express the set. That's fine.
There are various algorithms for determining whether the data set A exists and the input data x matches the data in the set A. Using such an algorithm, a match with the character string set as described above can be determined.
For example, methods such as binary tree search, red / black tree search, trie tree search, and hash method can be used.

一例をあげる。文字列は、辞書順に順番を付けることが可能である(つまり、ソートできる)。文字列集合をソートして、2分木構造とする。
図24の例は、文字列集合を2分木構造として例を示す図である。図24において、○は、ノードを示す。各ノードは最大2つの子ノードを持つ。例えば図24において、ノード8は、ノード4とノード12を子に持つ。
2分木探索では、例えば、左の子<親≦右の子となるように、木構造を作る。
このようにすると、対象とする文字列との大小関係を一番上の親ノードから参照していくことによって、N個の集合の場合に、logNの回数で集合内にデータが存在するか否かを検査することが可能となる(図24の場合)。
以上のように、順番を付けることのできる文字列に関して、単純に探索をする場合(N回の判定が必要)よりも、高速に検査することが可能となる。
Here is an example. The strings can be ordered in dictionary order (ie, can be sorted). The character string set is sorted into a binary tree structure.
The example of FIG. 24 is a diagram illustrating an example in which a character string set is a binary tree structure. In FIG. 24, ◯ indicates a node. Each node has a maximum of two child nodes. For example, in FIG. 24, node 8 has node 4 and node 12 as children.
In the binary tree search, for example, a tree structure is created such that left child <parent <right child.
In this way, by referring to the magnitude relationship with the target character string from the top parent node, in the case of N sets, data exists in the set with log 2 N times. It is possible to inspect whether or not (in the case of FIG. 24).
As described above, the character strings that can be ordered can be inspected at a higher speed than a simple search (needs N determinations).

正規表現では、汎用性を必要とするため、このような高速アルゴリズムの導入を行う。
例えば、
横浜|川崎|横須賀
の正規表現の場合、前述の文字列集合に対するアルゴリズムをそのまま適用し得る。しかし、例えば、
横浜|(別の正規表現)|須賀
のように、論理和記号の間に、別の正規表現による複雑な式が入っている場合もあり得る。その場合には、その複雑な式を、文字列集合として、辞書順に並べることはできない。少なくとも、正規表現の入れ子構造になるため、その分、低速となる。そのため、論理和記号の間にある文字列をすべて、文字列集合として、前述の文字列探索の高速アルゴリズムを適用することはできない。
そこで、本実施の形態では、限定文字列パターン108中の、文字列集合部分を抽出することを行う。つまり、文字列集合部分だけを抜き出して、その部分は、例えば、2分木探索を行う。
また、高速探索アルゴリズムを部分一致検査に用いることもできる。
そのためには、
対象文字列+任意文字列
が、文字列集合内に存在しているか否かを判定すればよい。
文字列が辞書順に並んでいることを前提とすれば、
対象文字列+任意文字列
は、
対象文字列
の次以降に並ぶことになる。
そのため、文字列集合中の文字列で、辞書順が対象文字列以上の値の文字列を発見し、その文字列の最初から対象文字列の文字数分だけ完全一致を判定すればよい。
Since regular expressions require versatility, such a high-speed algorithm is introduced.
For example,
In the case of the regular expression of Yokohama | Kawasaki | Yokosuka, the algorithm for the character string set described above can be applied as it is. But for example,
Yokohama | (another regular expression) | As in Suga, there may be a case where a complex expression using another regular expression is inserted between OR symbols. In that case, the complicated expressions cannot be arranged in a dictionary order as a character string set. At least, it becomes a regular expression nested structure, so it is slower. For this reason, it is impossible to apply the above-described high-speed algorithm for searching a character string as a character string set for all character strings between logical sum symbols.
Therefore, in the present embodiment, a character string set portion in the limited character string pattern 108 is extracted. That is, only the character string set portion is extracted, and the binary tree search is performed on the portion, for example.
Also, a fast search algorithm can be used for partial match inspection.
for that purpose,
It may be determined whether the target character string + arbitrary character string exists in the character string set.
Assuming that the strings are arranged in dictionary order,
The target character string + optional character string is
It will line up after the target character string.
Therefore, it is only necessary to find a character string having a value greater than or equal to the target character string in the character string set in the character string set and determine the complete match for the number of characters of the target character string from the beginning of the character string.

図1は、本実施の形態の構成例についての概念的なモジュール構成図であり、具体的には図3に例示したパス限定処理モジュール350内のモジュール構成例を示す説明図である。パス限定処理モジュール350は、文字認識結果である複数の文字列を対象として、その中から予め定められた文字列パターンに合致する文字列を出力するものであって、先頭N文字集合生成モジュール110、先頭N文字限定文字列パターン生成モジュール120、ネットワーク構築処理モジュール130、ノード数限定処理モジュール140、制御モジュール150、出力決定処理モジュール160を有している。つまり、図1に示す本実施の形態は、図19の例に示す構成に、先頭N文字集合生成モジュール110、先頭N文字限定文字列パターン生成モジュール120を追加し、それに合わせてノード数限定処理モジュール1920、制御モジュール1930を変更して、それぞれノード数限定処理モジュール140、制御モジュール150にしたものである。したがって、ノード数限定処理モジュール140、制御モジュール150は、それぞれノード数限定処理モジュール1920、制御モジュール1930の処理内容を含む。なお、同種の部位には同一符号を付し重複した説明を省略する。   FIG. 1 is a conceptual module configuration diagram of a configuration example of the present embodiment. Specifically, FIG. 1 is an explanatory diagram illustrating a module configuration example in the path limitation processing module 350 illustrated in FIG. The path limitation processing module 350 outputs a character string that matches a predetermined character string pattern from a plurality of character strings that are character recognition results, and includes a leading N character set generation module 110. The first N character limited character string pattern generation module 120, the network construction processing module 130, the node number limitation processing module 140, the control module 150, and the output determination processing module 160. That is, the present embodiment shown in FIG. 1 adds the top N character set generation module 110 and the top N character limited character string pattern generation module 120 to the configuration shown in the example of FIG. The module 1920 and the control module 1930 are changed to a node number limitation processing module 140 and a control module 150, respectively. Therefore, the node number limitation processing module 140 and the control module 150 include the processing contents of the node number limitation processing module 1920 and the control module 1930, respectively. In addition, the same code | symbol is attached | subjected to the same kind of site | part, and the overlapping description is abbreviate | omitted.

先頭N文字集合生成モジュール110は、先頭N文字限定文字列パターン生成モジュール120と接続されている。先頭N文字集合生成モジュール110は、予め定められた第1の文字列パターン(限定文字列パターン)の先頭又は最後尾から1文字以上の文字列の集合を生成する。限定文字列パターンは、例えば、正規表現である。以下、「先頭から」の場合を例示して説明する。「最後尾から」については、「先頭」の部分を「最後尾」と読み替えればよい。「先頭から1文字以上の文字列の集合」とは、例えば、正規表現がなされている限定文字列パターン内の文字列(文字認識結果となり得る文字列)の和集合(論理和)から、各文字列の先頭からN文字(Nは1以上)の文字列を抽出することである。以下、1文字の文字列(文字列には1文字を含む)の集合を例示して説明する。具体的には、限定文字列パターンとして、
横浜|川崎|横須賀
である場合、先頭から1文字の文字列の集合とは、(「横」、「川」)となる。なお「|」は、論理和を示す記号である。ここでは、「横浜」と「横須賀」の先頭文字が同じ「横」であるため、「横」と「川」の2つの要素となる。
The first N character set generation module 110 is connected to the first N character limited character string pattern generation module 120. The first N character set generation module 110 generates a set of one or more character strings from the beginning or the end of a predetermined first character string pattern (limited character string pattern). The limited character string pattern is, for example, a regular expression. Hereinafter, the case of “from the top” will be described as an example. As for “from the tail”, the “head” portion may be read as “the tail”. “A set of character strings of one or more characters from the beginning” means, for example, a sum set (logical sum) of character strings (character strings that can be character recognition results) in a limited character string pattern in which regular expressions are made. A character string of N characters (N is 1 or more) is extracted from the beginning of the character string. Hereinafter, a set of character strings of one character (a character string includes one character) will be described as an example. Specifically, as a limited character string pattern,
In the case of Yokohama | Kawasaki | Yokosuka, the character string set from the top is ("horizontal", "river"). “|” Is a symbol indicating a logical sum. Here, since the first characters of “Yokohama” and “Yokosuka” are the same “horizontal”, there are two elements “horizontal” and “river”.

先頭N文字限定文字列パターン生成モジュール120は、先頭N文字集合生成モジュール110、制御モジュール150と接続されている。先頭N文字限定文字列パターン生成モジュール120は、先頭N文字集合生成モジュール110によって生成された集合から第2の文字列パターンを生成する。第2の文字列パターンは、限定文字列パターンと同様に、例えば、正規表現である。前述の例では、集合(「横」、「川」)から、正規表現である
横|川
を生成する。つまり、先頭文字からN文字の文字列群を、論理和を示す記号を用いて並べたものである。
The first N character limited character string pattern generation module 120 is connected to the first N character set generation module 110 and the control module 150. The first N character limited character string pattern generation module 120 generates a second character string pattern from the set generated by the first N character set generation module 110. Similar to the limited character string pattern, the second character string pattern is, for example, a regular expression. In the above example, the regular expression horizontal | river is generated from the set ("horizontal", "river"). That is, a character string group of N characters from the first character is arranged using a symbol indicating a logical sum.

ネットワーク構築処理モジュール130は、ノード数限定処理モジュール140と接続されている。ネットワーク構築処理モジュール130は、複数の文字認識結果の各々の文字をノードとし、隣接する文字画像のノード間をリンクで結ぶネットワークを構築する。前述したように、文字列の一方の端(例えば、左端)から他方の端(例えば、右端)に至るネットワークを構築する。   The network construction processing module 130 is connected to the node number limitation processing module 140. The network construction processing module 130 constructs a network that uses each character of the plurality of character recognition results as a node and connects nodes of adjacent character images with links. As described above, a network from one end (for example, the left end) of the character string to the other end (for example, the right end) is constructed.

ノード数限定処理モジュール140は、ネットワーク構築処理モジュール130、制御モジュール150、出力決定処理モジュール160と接続されている。ノード数限定処理モジュール140は、制御モジュール150による制御によって、ネットワーク構築処理モジュール130によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、先頭N文字限定文字列パターン生成モジュール120によって生成された第2の文字列パターンに合致するノードに限定し、次に、第1の文字列パターン(限定文字列パターン)に合致するノードに限定する。つまり、各パスを構成するノード(文字)を左又は右から順に並べた文字列のうち、限定文字列パターンに合致するものを抽出することによって、パスを限定する。前述の例では、限定文字列パターンに該当するか否かを判定する前に、先頭文字によって構成されている第2の文字列パターンに該当するか否かを判定する。第2の文字列パターンに該当しなければ、限定文字列パターンとの照合は不要である。   The node limit processing module 140 is connected to the network construction processing module 130, the control module 150, and the output determination processing module 160. The node limit processing module 140 is limited to the first N characters for nodes connected from either the first direction or the last direction in the network constructed by the network construction processing module 130 under the control of the control module 150. The nodes are limited to nodes that match the second character string pattern generated by the character string pattern generation module 120, and then limited to nodes that match the first character string pattern (limited character string pattern). That is, the path is limited by extracting a character string that matches the limited character string pattern from the character strings in which the nodes (characters) constituting each path are arranged in order from the left or the right. In the above-described example, before determining whether or not it corresponds to the limited character string pattern, it is determined whether or not it corresponds to the second character string pattern constituted by the first character. If it does not correspond to a 2nd character string pattern, collation with a limited character string pattern is unnecessary.

制御モジュール150は、先頭N文字限定文字列パターン生成モジュール120、ノード数限定処理モジュール140に接続されている。制御モジュール150は、限定文字列パターンと先頭N文字限定文字列パターン生成モジュール120からの第2の文字列パターンを受け取り、前述した限定処理をノード数限定処理モジュール140に行わせるように制御する。
出力決定処理モジュール160は、ノード数限定処理モジュール140と接続されている。出力決定処理モジュール160は、ノード数限定処理モジュール140によって限定されたノードによって構成されたパス内の文字候補列を文字認識結果として出力する。
The control module 150 is connected to the first N character limited character string pattern generation module 120 and the node number limitation processing module 140. The control module 150 receives the limited character string pattern and the second character string pattern from the first N character limited character string pattern generation module 120 and controls the node number limitation processing module 140 to perform the above-described limitation processing.
The output determination processing module 160 is connected to the node limit processing module 140. The output determination processing module 160 outputs a character candidate string in the path formed by the nodes limited by the node number limitation processing module 140 as a character recognition result.

図2は、本実施の形態による処理例を示すフローチャートである。
ステップS202では、先頭N文字集合生成モジュール110が、限定文字列パターンAを受け付ける。
ステップS204では、先頭N文字集合生成モジュール110が、限定文字列パターンA内の各文字列の先頭からN文字分の文字列を抽出する。
ステップS206では、先頭N文字限定文字列パターン生成モジュール120が、抽出したN文字分の文字列から限定文字列パターンB(第2の文字列パターン)を生成する。
ステップS208では、ネットワーク構築処理モジュール130が、ネットワークを構築する。
ステップS210では、ノード数限定処理モジュール140が、ネットワーク内の文字列が限定文字列パターンBに非合致であるか否かを判断し、非合致である場合はステップS218へ進み、それ以外の場合はステップS212へ進む。
ステップS212では、ノード数限定処理モジュール140が、ネットワーク内の文字列が限定文字列パターンAに非合致であるか否かを判断し、非合致である場合はステップS218へ進み、それ以外の場合はステップS214へ進む。
ステップS214では、ノード数限定処理モジュール140が、ネットワーク内のノードを限定する。
ステップS216では、出力決定処理モジュール160が、出力すべきパスを決定する。
ステップS218では、出力決定処理モジュール160が、非合致である旨を示す情報を出力する。
FIG. 2 is a flowchart showing an example of processing according to this embodiment.
In step S202, the first N character set generation module 110 accepts the limited character string pattern A.
In step S204, the top N character set generation module 110 extracts a character string of N characters from the top of each character string in the limited character string pattern A.
In step S206, the first N character limited character string pattern generation module 120 generates a limited character string pattern B (second character string pattern) from the extracted character strings of N characters.
In step S208, the network construction processing module 130 constructs a network.
In step S210, the node number limitation processing module 140 determines whether or not the character string in the network does not match the limited character string pattern B. If the character string does not match, the process proceeds to step S218. Advances to step S212.
In step S212, the node limit processing module 140 determines whether or not the character string in the network does not match the limited character string pattern A. If it does not match, the process proceeds to step S218. Advances to step S214.
In step S214, the node number limitation processing module 140 limits the nodes in the network.
In step S216, the output determination processing module 160 determines a path to be output.
In step S218, the output determination processing module 160 outputs information indicating that it does not match.

図25は、本実施の形態(変形例)の構成例についての概念的なモジュール構成図である。図1に例示したモジュール構成のノード数限定処理モジュール140、制御モジュール150をそれぞれノード数限定処理モジュール2540、制御モジュール2550にしたものである。   FIG. 25 is a conceptual module configuration diagram of a configuration example of the present embodiment (modification). The node number limitation processing module 140 and the control module 150 having the module configuration illustrated in FIG. 1 are replaced with a node number limitation processing module 2540 and a control module 2550, respectively.

ノード数限定処理モジュール2540は、ネットワーク構築処理モジュール130、制御モジュール2550、出力決定処理モジュール160と接続されている。ノード数限定処理モジュール2540は、制御モジュール2550による制御によって、ネットワーク構築処理モジュール130によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、文字認識候補とならない文字種を示す第3の文字列パターン(非合致文字種パターン)に合致しないノードに限定し、先頭N文字限定文字列パターン生成モジュール120によって生成された第2の文字列パターンに合致するノードに限定し、次に、第1の文字列パターン(限定文字列パターン)に合致するノードに限定する。つまり、各パスを構成するノード(文字)を左又は右から順に並べた文字列のうち、限定文字列パターンに合致するものを抽出することによって、パスを限定する。まず、非合致文字種パターンに合致するか否かを判断し、合致した場合は、以下の、第2の文字列パターン、限定文字列パターンとの照合は不要である。非合致文字種パターンとは、文字認識結果としてあり得ない文字種の正規表現で示されたパターンである。例えば、図4に例示した住所枠(市前)420内には、先頭文字として英数字、記号はあり得ない。そこで、住所枠(市前)420内の文字認識結果を対象とする場合は、非合致文字種パターンとして、英数字、記号の文字コードの範囲を示すパターンを制御モジュール2550が受け取る。具体的には、この場合は、「文字コード(例えば、unicode)が255以下」である。ノード数限定処理モジュール2540は、制御モジュール2550が受け取った非合致文字種パターンを用いて、照合処理を行う。次に、非合致文字種パターンに合致しなかったものを対象として、図1に例示のノード数限定処理モジュール140による処理を行う。   The node limit processing module 2540 is connected to the network construction processing module 130, the control module 2550, and the output determination processing module 160. The node limitation processing module 2540 controls character recognition candidates for nodes connected from either the first direction or the last direction in the network constructed by the network construction processing module 130 under the control of the control module 2550. Limited to nodes that do not match the third character string pattern (non-matching character type pattern) indicating the character type that does not become, and limited to nodes that match the second character string pattern generated by the first N character limited character string pattern generation module 120 Then, it is limited to nodes that match the first character string pattern (limited character string pattern). That is, the path is limited by extracting a character string that matches the limited character string pattern from the character strings in which the nodes (characters) constituting each path are arranged in order from the left or the right. First, it is determined whether or not it matches the non-matching character type pattern. If they match, it is not necessary to collate with the following second character string pattern and limited character string pattern. The non-matching character type pattern is a pattern represented by a regular expression of a character type that cannot be a character recognition result. For example, in the address frame (city front) 420 illustrated in FIG. 4, there cannot be alphanumeric characters and symbols as the first character. Therefore, when the character recognition result in the address frame (city square) 420 is targeted, the control module 2550 receives a pattern indicating the character code range of alphanumeric characters and symbols as the non-matching character type pattern. Specifically, in this case, “a character code (for example, Unicode) is 255 or less”. The node limit processing module 2540 performs a matching process using the non-matching character type pattern received by the control module 2550. Next, the processing by the node number limitation processing module 140 illustrated in FIG. 1 is performed on a target that does not match the non-matching character type pattern.

制御モジュール2550は、先頭N文字限定文字列パターン生成モジュール120、ノード数限定処理モジュール2540に接続されている。制御モジュール2550は、限定文字列パターンと先頭N文字限定文字列パターン生成モジュール120からの第2の文字列パターンと非合致文字種パターンを受け取り、前述した限定処理をノード数限定処理モジュール2540に行わせるように制御する。   The control module 2550 is connected to the first N character limited character string pattern generation module 120 and the node number limitation processing module 2540. The control module 2550 receives the limited character string pattern, the second character string pattern and the non-matching character type pattern from the first N character limited character string pattern generation module 120, and causes the node number limitation processing module 2540 to perform the above-described limitation processing. To control.

図26は、本実施の形態(変形例)による処理例を示すフローチャートである。
ステップS2602では、先頭N文字集合生成モジュール110が、限定文字列パターンAを受け付ける。
ステップS2604では、先頭N文字集合生成モジュール110が、限定文字列パターンA内の各文字列の先頭からN文字分の文字列を抽出する。
ステップS2606では、先頭N文字限定文字列パターン生成モジュール120が、抽出したN文字分の文字列から限定文字列パターンB(第2の文字列パターン)を生成する。
ステップS2608では、ネットワーク構築処理モジュール130が、ネットワークを構築する。
ステップS2610では、ノード数限定処理モジュール2540が、ネットワーク内の文字列が非合致文字種パターンに合致するか否かを判断し、合致する場合はステップS2620へ進み、それ以外の場合はステップS2612へ進む。
ステップS2612では、ノード数限定処理モジュール2540が、ネットワーク内の文字列が限定文字列パターンBに非合致であるか否かを判断し、非合致である場合はステップS2620へ進み、それ以外の場合はステップS2614へ進む。
ステップS2614では、ノード数限定処理モジュール2540が、ネットワーク内の文字列が限定文字列パターンAに非合致であるか否かを判断し、非合致である場合はステップS2620へ進み、それ以外の場合はステップS2616へ進む。
ステップS2616では、ノード数限定処理モジュール2540が、ネットワーク内のノードを限定する。
ステップS2618では、出力決定処理モジュール160が、出力すべきパスを決定する。
ステップS2620では、出力決定処理モジュール160が、非合致を出力する。
FIG. 26 is a flowchart illustrating an example of processing according to the present embodiment (modification).
In step S2602, the first N character set generation module 110 accepts the limited character string pattern A.
In step S2604, the top N character set generation module 110 extracts a character string of N characters from the top of each character string in the limited character string pattern A.
In step S2606, the first N character limited character string pattern generation module 120 generates a limited character string pattern B (second character string pattern) from the extracted character string of N characters.
In step S2608, the network construction processing module 130 constructs a network.
In step S2610, the node number limitation processing module 2540 determines whether or not the character string in the network matches the non-matching character type pattern. If the character string matches, the process proceeds to step S2620; otherwise, the process proceeds to step S2612. .
In step S2612, the node limit processing module 2540 determines whether or not the character string in the network does not match the limited character string pattern B. If the character string does not match, the process proceeds to step S2620; Advances to step S2614.
In step S2614, the node number limitation processing module 2540 determines whether or not the character string in the network does not match the limited character string pattern A. If the character string does not match, the process proceeds to step S2620; Advances to step S2616.
In step S2616, the node number limitation processing module 2540 limits the nodes in the network.
In step S2618, the output determination processing module 160 determines a path to be output.
In step S2620, the output determination processing module 160 outputs a non-match.

さらにビタビアルゴリズムを用いた場合に適用してもよい。
図27の例に示すように、ノードA、ノードB、ノードCから、ノードDへのパスがあるとする。
ここでは、限定文字列パターンが「化学会議」であるとする。この文字列パターンになるように、パスを限定していく場合について説明する。図27は、その途中段階の例を示している。
前述したように、ビタビアルゴリズムでは、各ノードから左に接続されるノードを1つに限定していくことによって、最適パス選定処理を行う。
ノードA→ノードDのパスでは、すでにノードAから左に向かうパスが1つに限定されている。そのため、ノードA→ノードDとなるパスを選択した場合には、先頭からノードDに至るパスが決定されるので、入力文字列を決定することができる。この場合、入力文字列が「ヒ学会」となり、これが「化学会議」に部分一致するかどうかを判定する。
ノードB→ノードDのパスでは、前述と同様に、対象文字列が「化学会」となり、これが「化学会議」に部分一致するかどうかを判定する。
ノードC→ノードDのパスでは、前述と同様に、対象文字列が「ト学会」となり、これが「化学会議」に部分一致するかどうかを判定する。
ところが、ノードAの左に向かうパスを決定した段階で、ノードAに至る文字列が「ヒ学」であって、「化学会議」とは合致していないことが明らかである。そのため、「ヒ学会」を「化学会議」と比較する処理は不要である。
Furthermore, the present invention may be applied when the Viterbi algorithm is used.
Assume that there are paths from node A, node B, and node C to node D as shown in the example of FIG.
Here, it is assumed that the limited character string pattern is “chemical meeting”. The case where the path is limited so as to be this character string pattern will be described. FIG. 27 shows an example of the intermediate stage.
As described above, in the Viterbi algorithm, the optimum path selection process is performed by limiting the number of nodes connected to the left from each node.
In the path from node A to node D, the number of paths from node A to the left is already limited to one. Therefore, when the path from node A to node D is selected, the path from the head to node D is determined, so the input character string can be determined. In this case, it is determined whether or not the input character string is “Higaku Gakkai” and this partially matches “Chemical Conference”.
In the path from node B to node D, as described above, the target character string is “Chemical Society”, and it is determined whether or not it partially matches “Chemical Conference”.
In the path from the node C to the node D, as described above, the target character string is “Japanese society”, and it is determined whether or not the character string partially matches the “chemical meeting”.
However, at the stage where the path to the left of the node A is determined, it is clear that the character string leading to the node A is “Higaku” and does not match the “chemical meeting”. For this reason, the process of comparing “Hyo Gakkai” with “Chemical Conference” is unnecessary.

したがって、本実施の形態では、下記処理を行うようにしてもよい。
1.ビタビアルゴリズムの各ノードに、限定文字列パターンに合致しているか/合致していないかを示す1ビットの情報(合致情報)を記憶させる。
(ア)合致しているとき:合致情報をONとする。
(イ)合致していないとき:合致情報をOFFとする。
2.対象ノードから、左側のノードに至るパスを評価する。この評価処理は、図3に例示のパス限定処理モジュール350(図1に例示の情報処理装置等)が行う。このとき、
(ア)左側のノードの合致情報がOFFであれば、限定文字列パターン検査処理を行わない。
(ア−1)さらに、すべての左側のノードの合致情報がOFFであれば、対象ノードの合致情報をOFFとする。
(イ)左側のノードの合致情報がONの場合のみ、限定文字列パターン検査処理を行う。
(イ−1)限定文字列パターン検査処理の結果が合致している場合、対象ノードの合致情報をONとする。
(イ−2)限定文字列パターン検査処理の結果が合致していない場合、対象ノードの合致情報をOFFとする。
(ウ)対象ノードの合致情報がONとなるパスが1つだけのとき、そのパスを選定する。対象ノードの合致情報がONとなるパスが2つ以上のときは、前述したように、正規表現とは異なる方法で最も評価値の高いものを選択すればよい。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。
(エ)対象ノードの合致情報がOFFとなる場合も、前述したように、正規表現とは異なる方法で最も評価値の高いものを選択すればよい。ここでの評価値とは、例えば、特開2012−118650号公報に示した方法を用いればよい。
Therefore, in the present embodiment, the following processing may be performed.
1. Each node of the Viterbi algorithm stores 1-bit information (match information) indicating whether the limited character string pattern is matched or not matched.
(A) When they match: The match information is turned ON.
(A) When they do not match: The match information is turned OFF.
2. Evaluate the path from the target node to the left node. This evaluation process is performed by the path limitation processing module 350 illustrated in FIG. 3 (such as the information processing apparatus illustrated in FIG. 1). At this time,
(A) If the match information of the left node is OFF, the limited character string pattern inspection process is not performed.
(A-1) Further, if the match information of all the left nodes is OFF, the match information of the target node is turned OFF.
(A) The limited character string pattern inspection process is performed only when the match information of the left node is ON.
(A-1) When the result of the limited character string pattern inspection process matches, the match information of the target node is turned ON.
(A-2) If the result of the limited character string pattern inspection process does not match, the match information of the target node is turned OFF.
(C) When the matching information of the target node is only one path, select that path. When there are two or more paths for which the match information of the target node is ON, as described above, the one having the highest evaluation value may be selected by a method different from the regular expression. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used.
(D) Even when the match information of the target node is OFF, as described above, the one with the highest evaluation value may be selected by a method different from the regular expression. As the evaluation value here, for example, a method disclosed in JP 2012-118650 A may be used.

図28を参照して、本実施の形態の情報処理装置のハードウェア構成例について説明する。図28に示す構成は、例えばパーソナルコンピュータ(PC)などによって構成されるものであり、スキャナ等のデータ読み取り部2817と、プリンタなどのデータ出力部2818を備えたハードウェア構成例を示している。   With reference to FIG. 28, a hardware configuration example of the information processing apparatus according to the present embodiment will be described. The configuration shown in FIG. 28 is configured by a personal computer (PC), for example, and shows a hardware configuration example including a data reading unit 2817 such as a scanner and a data output unit 2818 such as a printer.

CPU(Central Processing Unit)2801は、前述の実施の形態において説明した各種のモジュール、すなわち、先頭N文字集合生成モジュール110、先頭N文字限定文字列パターン生成モジュール120、ネットワーク構築処理モジュール130、ノード数限定処理モジュール140、制御モジュール150、出力決定処理モジュール160、文字列抽出モジュール320、切出位置抽出モジュール330、文字候補抽出モジュール340、パス限定処理モジュール350、ノード数限定処理モジュール1920、制御モジュール1930、ノード数限定処理モジュール2540、制御モジュール2550等の各モジュールの実行シーケンスを記述したコンピュータ・プログラムに従った処理を実行する制御部である。   A CPU (Central Processing Unit) 2801 includes various modules described in the above-described embodiments, that is, a top N character set generation module 110, a top N character limited character string pattern generation module 120, a network construction processing module 130, and the number of nodes. Limit processing module 140, control module 150, output determination processing module 160, character string extraction module 320, cutout position extraction module 330, character candidate extraction module 340, path limitation processing module 350, node number limitation processing module 1920, control module 1930 , A control unit that executes processing according to a computer program describing an execution sequence of each module such as the node number limitation processing module 2540 and the control module 2550 It is.

ROM(Read Only Memory)2802は、CPU2801が使用するプログラムや演算パラメータ等を格納する。RAM(Random Access Memory)2803は、CPU2801の実行において使用するプログラムや、その実行において適宜変化するパラメータ等を格納する。これらはCPUバスなどから構成されるホストバス2804により相互に接続されている。   A ROM (Read Only Memory) 2802 stores programs used by the CPU 2801, operation parameters, and the like. A RAM (Random Access Memory) 2803 stores programs used in the execution of the CPU 2801, parameters that change as appropriate during the execution, and the like. These are connected to each other by a host bus 2804 including a CPU bus.

ホストバス2804は、ブリッジ2805を介して、PCI(Peripheral Component Interconnect/Interface)バスなどの外部バス2806に接続されている。   The host bus 2804 is connected to an external bus 2806 such as a peripheral component interconnect / interface (PCI) bus through a bridge 2805.

キーボード2808、マウス等のポインティングデバイス2809は、操作者により操作される入力デバイスである。ディスプレイ2810は、液晶表示装置又はCRT(Cathode Ray Tube)などがあり、各種情報をテキストやイメージ情報として表示する。   A keyboard 2808 and a pointing device 2809 such as a mouse are input devices operated by an operator. The display 2810 includes a liquid crystal display device or a CRT (Cathode Ray Tube), and displays various types of information as text or image information.

HDD(Hard Disk Drive)2811は、ハードディスクを内蔵し、ハードディスクを駆動し、CPU2801によって実行するプログラムや情報を記録又は再生させる。ハードディスクには、受け付けた画像、文字認識結果、文字列パターン、ネットワーク構造、対象文字列、限定文字列パターンなどが格納される。さらに、その他の各種のデータ処理プログラム等、各種コンピュータ・プログラムが格納される。   An HDD (Hard Disk Drive) 2811 has a built-in hard disk, drives the hard disk, and records or reproduces a program executed by the CPU 2801 and information. The hard disk stores received images, character recognition results, character string patterns, network structures, target character strings, limited character string patterns, and the like. Further, various computer programs such as various other data processing programs are stored.

ドライブ2812は、装着されている磁気ディスク、光ディスク、光磁気ディスク、又は半導体メモリ等のリムーバブル記録媒体2813に記録されているデータ又はプログラムを読み出して、そのデータ又はプログラムを、インタフェース2807、外部バス2806、ブリッジ2805、及びホストバス2804を介して接続されているRAM2803に供給する。リムーバブル記録媒体2813も、ハードディスクと同様のデータ記録領域として利用可能である。   The drive 2812 reads out data or a program recorded on a removable recording medium 2813 such as a magnetic disk, an optical disk, a magneto-optical disk, or a semiconductor memory, and reads the data or program into an interface 2807 and an external bus 2806. , The bridge 2805, and the RAM 2803 connected via the host bus 2804. The removable recording medium 2813 can also be used as a data recording area similar to the hard disk.

接続ポート2814は、外部接続機器2815を接続するポートであり、USB、IEEE1394等の接続部を持つ。接続ポート2814は、インタフェース2807、及び外部バス2806、ブリッジ2805、ホストバス2804等を介してCPU2801等に接続されている。通信部2816は、通信回線に接続され、外部とのデータ通信処理を実行する。データ読み取り部2817は、例えばスキャナであり、ドキュメントの読み取り処理を実行する。データ出力部2818は、例えばプリンタであり、ドキュメントデータの出力処理を実行する。   The connection port 2814 is a port for connecting the external connection device 2815 and has a connection unit such as USB and IEEE1394. The connection port 2814 is connected to the CPU 2801 and the like via the interface 2807, the external bus 2806, the bridge 2805, the host bus 2804, and the like. A communication unit 2816 is connected to a communication line and executes data communication processing with the outside. The data reading unit 2817 is a scanner, for example, and executes document reading processing. The data output unit 2818 is a printer, for example, and executes document data output processing.

なお、図28に示す情報処理装置のハードウェア構成は、1つの構成例を示すものであり、本実施の形態は、図28に示す構成に限らず、本実施の形態において説明したモジュールを実行可能な構成であればよい。例えば、一部のモジュールを専用のハードウェア(例えば特定用途向け集積回路(Application Specific Integrated Circuit:ASIC)等)で構成してもよく、一部のモジュールは外部のシステム内にあり通信回線で接続しているような形態でもよく、さらに図28に示すシステムが複数互いに通信回線によって接続されていて互いに協調動作するようにしてもよい。また、複写機、ファックス、スキャナ、プリンタ、複合機(スキャナ、プリンタ、複写機、ファックス等のいずれか2つ以上の機能を有している画像処理装置)などに組み込まれていてもよい。   Note that the hardware configuration of the information processing apparatus shown in FIG. 28 shows one configuration example, and the present embodiment is not limited to the configuration shown in FIG. 28, and the modules described in this embodiment are executed. Any configuration is possible. For example, some modules may be configured with dedicated hardware (for example, Application Specific Integrated Circuit (ASIC), etc.), and some modules are in an external system and connected via a communication line Alternatively, a plurality of systems shown in FIG. 28 may be connected to each other via a communication line so as to cooperate with each other. Further, it may be incorporated in a copying machine, a fax machine, a scanner, a printer, a multifunction machine (an image processing apparatus having any two or more functions of a scanner, a printer, a copying machine, a fax machine, etc.).

前述の実施の形態においては、対象として日本語の文字を示したが、中国語、英語等の文字を対象としてもよい。
前述の実施の形態においては、横書きの文字列を前提として、左が始点で右が終点であるような記述の仕方を行ってきた。しかし、前述の説明は、縦書きや、右から左に記述する文字列でも同様に成り立つ。例えば、縦書きの場合は、「左」を「上」、「右」を「下」とする変換を行えばよい。右から左に記述する文字列の場合は、「左」を「右」、「右」を「左」とする変換を行えばよい。
なお、数式を用いて説明したが、数式には、その数式と同等のものが含まれる。同等のものとは、その数式そのものの他に、最終的な結果に影響を及ぼさない程度の数式の変形、又は数式をアルゴリズミックな解法で解くこと等が含まれる。
In the above-described embodiment, Japanese characters are shown as an object, but characters such as Chinese and English may be an object.
In the above-described embodiment, description has been made such that the left is the start point and the right is the end point, assuming a horizontally written character string. However, the above description also holds true for vertical writing and character strings written from right to left. For example, in the case of vertical writing, conversion may be performed in which “left” is “upper” and “right” is “lower”. In the case of a character string written from right to left, conversion may be performed with “left” as “right” and “right” as “left”.
In addition, although demonstrated using a numerical formula, the thing equivalent to the numerical formula is contained in a numerical formula. The equivalent includes not only the mathematical formula itself, but also transformation of the mathematical formula to the extent that the final result is not affected, or solving the mathematical formula by an algorithmic solution.

なお、説明したプログラムについては、記録媒体に格納して提供してもよく、また、そのプログラムを通信手段によって提供してもよい。その場合、例えば、前記説明したプログラムについて、「プログラムを記録したコンピュータ読み取り可能な記録媒体」の発明として捉えてもよい。
「プログラムを記録したコンピュータ読み取り可能な記録媒体」とは、プログラムのインストール、実行、プログラムの流通などのために用いられる、プログラムが記録されたコンピュータで読み取り可能な記録媒体をいう。
なお、記録媒体としては、例えば、デジタル・バーサタイル・ディスク(DVD)であって、DVDフォーラムで策定された規格である「DVD−R、DVD−RW、DVD−RAM等」、DVD+RWで策定された規格である「DVD+R、DVD+RW等」、コンパクトディスク(CD)であって、読出し専用メモリ(CD−ROM)、CDレコーダブル(CD−R)、CDリライタブル(CD−RW)等、ブルーレイ・ディスク(Blu−ray Disc(登録商標))、光磁気ディスク(MO)、フレキシブルディスク(FD)、磁気テープ、ハードディスク、読出し専用メモリ(ROM)、電気的消去及び書換可能な読出し専用メモリ(EEPROM(登録商標))、フラッシュ・メモリ、ランダム・アクセス・メモリ(RAM)、SD(Secure Digital)メモリーカード等が含まれる。
そして、前記のプログラム又はその一部は、前記記録媒体に記録して保存や流通等させてもよい。また、通信によって、例えば、ローカル・エリア・ネットワーク(LAN)、メトロポリタン・エリア・ネットワーク(MAN)、ワイド・エリア・ネットワーク(WAN)、インターネット、イントラネット、エクストラネット等に用いられる有線ネットワーク、あるいは無線通信ネットワーク、さらにこれらの組み合わせ等の伝送媒体を用いて伝送させてもよく、また、搬送波に乗せて搬送させてもよい。
さらに、前記のプログラムは、他のプログラムの一部分であってもよく、あるいは別個のプログラムと共に記録媒体に記録されていてもよい。また、複数の記録媒体に分割して
記録されていてもよい。また、圧縮や暗号化など、復元可能であればどのような態様で記録されていてもよい。
The program described above may be provided by being stored in a recording medium, or the program may be provided by communication means. In that case, for example, the above-described program may be regarded as an invention of a “computer-readable recording medium recording the program”.
The “computer-readable recording medium on which a program is recorded” refers to a computer-readable recording medium on which a program is recorded, which is used for program installation, execution, program distribution, and the like.
The recording medium is, for example, a digital versatile disc (DVD), which is a standard established by the DVD Forum, such as “DVD-R, DVD-RW, DVD-RAM,” and DVD + RW. Standard “DVD + R, DVD + RW, etc.”, compact disc (CD), read-only memory (CD-ROM), CD recordable (CD-R), CD rewritable (CD-RW), Blu-ray disc ( Blu-ray Disc (registered trademark), magneto-optical disk (MO), flexible disk (FD), magnetic tape, hard disk, read-only memory (ROM), electrically erasable and rewritable read-only memory (EEPROM (registered trademark)) )), Flash memory, Random access memory (RAM) SD (Secure Digital) memory card and the like.
The program or a part of the program may be recorded on the recording medium for storage or distribution. Also, by communication, for example, a local area network (LAN), a metropolitan area network (MAN), a wide area network (WAN), a wired network used for the Internet, an intranet, an extranet, etc., or wireless communication It may be transmitted using a transmission medium such as a network or a combination of these, or may be carried on a carrier wave.
Furthermore, the program may be a part of another program, or may be recorded on a recording medium together with a separate program. Moreover, it may be divided and recorded on a plurality of recording media. Further, it may be recorded in any manner as long as it can be restored, such as compression or encryption.

110…先頭N文字集合生成モジュール
120…先頭N文字限定文字列パターン生成モジュール
130…ネットワーク構築処理モジュール
140…ノード数限定処理モジュール
150…制御モジュール
160…出力決定処理モジュール
310…画像受付モジュール
320…文字列抽出モジュール
330…切出位置抽出モジュール
340…文字候補抽出モジュール
350…パス限定処理モジュール
360…出力モジュール
1920…ノード数限定処理モジュール
1930…制御モジュール
2540…ノード数限定処理モジュール
2550…制御モジュール
2200…限定文字列パターン検査処理モジュール
2500…限定文字列パターン検査処理モジュール
2508…正規表現
2518…文字列集合
2600…限定文字列パターン検査処理モジュール
2608…論理関係
DESCRIPTION OF SYMBOLS 110 ... First N character set generation module 120 ... First N character limited character string pattern generation module 130 ... Network construction processing module 140 ... Node number limitation processing module 150 ... Control module 160 ... Output decision processing module 310 ... Image reception module 320 ... Character Column extraction module 330 ... Extraction position extraction module 340 ... Character candidate extraction module 350 ... Path limitation processing module 360 ... Output module 1920 ... Node number limitation processing module 1930 ... Control module 2540 ... Node number limitation processing module 2550 ... Control module 2200 ... Limited character string pattern inspection processing module 2500 ... Limited character string pattern inspection processing module 2508 ... Regular expression 2518 ... Character string set 2600 ... Limited character string pattern Inspection processing module 2608 ... logical relationship

Claims (3)

予め定められた第1の文字列パターンの先頭又は最後尾から1文字以上の文字列の集合を生成する第1の生成手段と、
前記第1の生成手段によって生成された集合から第2の文字列パターンを生成する第2の生成手段と、
複数の文字認識結果の各々の文字をノードとし、隣接する文字画像のノード間をリンクで結ぶネットワークを構築するネットワーク構築手段と、
前記ネットワーク構築手段によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、前記第2の生成手段によって生成された第2の文字列パターンに合致するノードに限定し、次に、前記第1の文字列パターンに合致するノードに限定する限定手段と、
前記限定手段によって限定されたノードによって構成されたパス内の文字候補列を文字認識結果として出力する出力手段
を具備することを特徴とする情報処理装置。
First generation means for generating a set of one or more character strings from the beginning or end of a predetermined first character string pattern;
Second generation means for generating a second character string pattern from the set generated by the first generation means;
Network construction means for constructing a network that connects each character of a plurality of character recognition results as a node and links nodes of adjacent character images,
A node that matches the second character string pattern generated by the second generation means with respect to a node connected from either the first direction or the last direction in the network constructed by the network construction means Limiting means for limiting to nodes that match the first character string pattern;
An information processing apparatus comprising: output means for outputting a character candidate string in a path formed by nodes limited by the limiting means as a character recognition result.
前記限定手段は、前記ネットワーク構築手段によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、文字認識候補とならない文字種を示す第3の文字列パターンに合致しないノードに限定し、前記第2の生成手段によって生成された第2の文字列パターンに合致するノードに限定し、次に、前記第1の文字列パターンに合致するノードに限定する
ことを特徴とする請求項1に記載の情報処理装置。
The limiting means generates a third character string pattern indicating a character type that is not a character recognition candidate for a node connected from either the first direction or the last direction in the network constructed by the network construction means. Limiting to nodes that do not match, limiting to nodes that match the second character string pattern generated by the second generation means, and then limiting to nodes that match the first character string pattern. The information processing apparatus according to claim 1.
コンピュータを、
予め定められた第1の文字列パターンの先頭又は最後尾から1文字以上の文字列の集合を生成する第1の生成手段と、
前記第1の生成手段によって生成された集合から第2の文字列パターンを生成する第2の生成手段と、
複数の文字認識結果の各々の文字をノードとし、隣接する文字画像のノード間をリンクで結ぶネットワークを構築するネットワーク構築手段と、
前記ネットワーク構築手段によって構築されたネットワーク内の先頭方向又は最後尾方向のいずれか一方向から接続するノードに対して、前記第2の生成手段によって生成された第2の文字列パターンに合致するノードに限定し、次に、前記第1の文字列パターンに合致するノードに限定する限定手段と、
前記限定手段によって限定されたノードによって構成されたパス内の文字候補列を文字認識結果として出力する出力手段
として機能させるための情報処理プログラム。
Computer
First generation means for generating a set of one or more character strings from the beginning or end of a predetermined first character string pattern;
Second generation means for generating a second character string pattern from the set generated by the first generation means;
Network construction means for constructing a network that connects each character of a plurality of character recognition results as a node and links nodes of adjacent character images,
A node that matches the second character string pattern generated by the second generation means with respect to a node connected from either the first direction or the last direction in the network constructed by the network construction means Limiting means for limiting to nodes that match the first character string pattern;
The information processing program for functioning as an output means which outputs the character candidate string in the path comprised by the node limited by the said limitation means as a character recognition result.
JP2012262621A 2012-11-30 2012-11-30 Information processing apparatus and information processing program Pending JP2014109810A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2012262621A JP2014109810A (en) 2012-11-30 2012-11-30 Information processing apparatus and information processing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012262621A JP2014109810A (en) 2012-11-30 2012-11-30 Information processing apparatus and information processing program

Publications (1)

Publication Number Publication Date
JP2014109810A true JP2014109810A (en) 2014-06-12

Family

ID=51030433

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012262621A Pending JP2014109810A (en) 2012-11-30 2012-11-30 Information processing apparatus and information processing program

Country Status (1)

Country Link
JP (1) JP2014109810A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111753047A (en) * 2020-05-19 2020-10-09 北京捷通华声科技股份有限公司 Text processing method and device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111753047A (en) * 2020-05-19 2020-10-09 北京捷通华声科技股份有限公司 Text processing method and device
CN111753047B (en) * 2020-05-19 2024-06-07 北京捷通华声科技股份有限公司 Text processing method and device

Similar Documents

Publication Publication Date Title
US11922318B2 (en) System and method of character recognition using fully convolutional neural networks with attention
JP5144940B2 (en) Improved robustness in table of contents extraction
US6950555B2 (en) Holistic-analytical recognition of handwritten text
US10133965B2 (en) Method for text recognition and computer program product
JP6003705B2 (en) Information processing apparatus and information processing program
JP5663866B2 (en) Information processing apparatus and information processing program
KR20060046128A (en) Low resolution ocr for camera acquired documents
JP2012118650A (en) Image processing apparatus and image processing program
JP7268198B2 (en) Image analysis device, image analysis method, and program
JP5942361B2 (en) Image processing apparatus and image processing program
CN112528894A (en) Method and device for distinguishing difference items
US10438097B2 (en) Recognition device, recognition method, and computer program product
JP2019212115A (en) Inspection device, inspection method, program, and learning device
WO2022038821A1 (en) Table structure recognition device and method
JP2009093305A (en) Business form recognition system
JP2014109810A (en) Information processing apparatus and information processing program
JP5942661B2 (en) Information processing apparatus and information processing program
US9009026B2 (en) Information processing apparatus, non-transitory computer readable medium storing information processing program, and information processing method
US11615636B2 (en) Apparatus and method for document recognition
US11972208B2 (en) Information processing device and information processing method
JP5888222B2 (en) Information processing apparatus and information processing program
JP2019074807A (en) Information processing device and program
US10657404B2 (en) Character recognition device, character recognition method, and character recognition program
JP6007720B2 (en) Information processing apparatus and information processing program
JP6260350B2 (en) Image processing apparatus and image processing program