JPH087031A - Character frame detecting device - Google Patents

Character frame detecting device

Info

Publication number
JPH087031A
JPH087031A JP6139893A JP13989394A JPH087031A JP H087031 A JPH087031 A JP H087031A JP 6139893 A JP6139893 A JP 6139893A JP 13989394 A JP13989394 A JP 13989394A JP H087031 A JPH087031 A JP H087031A
Authority
JP
Japan
Prior art keywords
character
frame
histogram
character frame
threshold value
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
JP6139893A
Other languages
Japanese (ja)
Inventor
Osamu Ikeda
修 池田
Hiroyuki Inaba
弘幸 稲葉
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.)
NEC Corp
Original Assignee
NEC Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NEC Corp filed Critical NEC Corp
Priority to JP6139893A priority Critical patent/JPH087031A/en
Publication of JPH087031A publication Critical patent/JPH087031A/en
Pending legal-status Critical Current

Links

Landscapes

  • Character Input (AREA)
  • Character Discrimination (AREA)

Abstract

PURPOSE:To improve the detection precision of a character frame even if the printing quality of the character frame is low and the size of the character frame is not standardized by resetting a threshold in accordance with the peak value of a historgram. CONSTITUTION:When the number of peaks exceeding the threshold in the historgram generated in a histogram generation part 3 does not become (the number of frames X2), a threshold setting part 8 lowers the setting value of the threshold if the peak value of the histogram is low, and raises the setting value of the threshold if the peak value is high. Thus, the number of the peaks exceeding the threshold becomes (the number of frames X2). It is desirable that a peak judgement part judges whether the width of the peak of the histogram is within a prescribed range or not, and judges whether the intervals of the peaks are within the prescribed range or not. Thus, the peak coordinate position can be judged to be the character frame or not.

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は、郵便物に記載された郵
便番号枠を検出し、検出された郵便番号枠の位置に応じ
て、郵便物を取り揃える郵便物取り揃え区分機等に用い
られる文字枠検出装置に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention detects a postal code frame described in a postal matter and, according to the detected position of the postal code frame, characters used in a postal matter sorting / sorting machine or the like for sorting postal matter. The present invention relates to a frame detection device.

【0002】[0002]

【従来の技術】従来、郵便物取り揃え区分機に用いられ
る文字枠検出装置としては、図9に示すものが知られて
いる。
2. Description of the Related Art Conventionally, as a character frame detecting device used in a mail sorting machine, a device shown in FIG. 9 is known.

【0003】図9は、従来の文字枠検出装置の構成を示
すブロック図である。
FIG. 9 is a block diagram showing the structure of a conventional character box detecting device.

【0004】図10は、文字枠のY軸方向(縦軸方向)
のヒストグラムを表わした図であり、図11は文字枠の
X軸方向(横軸方向)のヒストグラムを表わした図であ
る。
FIG. 10 shows the Y-axis direction (vertical axis direction) of a character frame.
11 is a diagram showing a histogram of FIG. 11, and FIG. 11 is a diagram showing a histogram of the character frame in the X-axis direction (horizontal axis direction).

【0005】図9において、紙葉類Lは文字枠として郵
便番号枠が記載されている本装置の処理対象となる物で
ある。
In FIG. 9, a paper sheet L is an object to be processed by the present apparatus in which a postal code frame is described as a character frame.

【0006】走査部21は紙葉類L上を光学的に走査
し、光電変換されて得られる画像データを出力する回路
である。イメージメモリ22は、走査部21より読み込
んだ画像データを格納しているメモリである。ヒストグ
ラム生成部23は、イメージメモリ22に格納された画
像データから、Y軸方向及びX軸方向の射影蓄積データ
を算出し、Y軸方向及びX軸方向それぞれのヒストグラ
ムを求めている。
The scanning unit 21 is a circuit that optically scans the paper sheet L and outputs image data obtained by photoelectric conversion. The image memory 22 is a memory that stores image data read by the scanning unit 21. The histogram generation unit 23 calculates the projection accumulation data in the Y-axis direction and the X-axis direction from the image data stored in the image memory 22, and obtains the histogram in each of the Y-axis direction and the X-axis direction.

【0007】文字枠検出部30は、枠Y座標位置検出部
24と、枠X座標位置検出部25及び文字切出し部26
と枠検知判定部27により構成されている。
The character frame detecting section 30 includes a frame Y coordinate position detecting section 24, a frame X coordinate position detecting section 25, and a character cutting section 26.
And the frame detection determination unit 27.

【0008】枠Y座標位置検出部24は、ヒストグラム
生成部23より出力されたY軸方向のヒストグラムを用
いて文字枠のY座標位置を検出している。また、枠X座
標位置検出部25は、枠Y座標位置検出部24から求め
られた文字枠のY座標位置範囲でヒストグラム生成部2
3から得られたX軸方向のヒストグラムを用いて文字枠
のX座標位置を検出している。文字切り出し部26は、
枠Y座標位置検出部24と枠X座標位置検出部25から
得られた文字枠の座標位置を、切り出し位置データとし
て使用し、イメージメモリ22に格納されている画像デ
ータから1文字毎の画像データを切り出している。枠検
知判定部27は、枠Y座標位置検出部24と枠X座標位
置検出部25から得られた文字枠の座標位置と文字切出
し部26から得られた文字切出し情報を用いて、文字枠
の存在の有無及び文字枠内の文字の存在の有無を判定し
ている。
The frame Y-coordinate position detection unit 24 detects the Y-coordinate position of the character frame using the histogram in the Y-axis direction output from the histogram generation unit 23. Further, the frame X coordinate position detection unit 25 uses the histogram generation unit 2 within the Y coordinate position range of the character frame obtained from the frame Y coordinate position detection unit 24.
The X-coordinate position of the character frame is detected using the histogram in the X-axis direction obtained from No. 3. The character cutout unit 26 is
The coordinate position of the character frame obtained from the frame Y-coordinate position detection unit 24 and the frame X-coordinate position detection unit 25 is used as cut-out position data, and image data for each character is extracted from the image data stored in the image memory 22. Is cut out. The frame detection determination unit 27 uses the coordinate position of the character frame obtained from the frame Y coordinate position detection unit 24 and the frame X coordinate position detection unit 25 and the character cutout information obtained from the character cutout unit 26 to extract the character frame. The presence / absence of characters and the presence / absence of characters in the character frame are determined.

【0009】上記のように構成された文字枠検出装置に
おいて、枠Y座標位置検出部24は、図10に示すよう
に、Y軸方向のヒストグラムから文字枠の横幅に対応し
た高さを有するヒストグラムのピーク値A3及びA4を
求め、A3に対応した文字枠のY軸方向のスタート座標
位置Y3、及びA4に対応したエンド座標位置Y4を求
めている。
In the character-frame detecting apparatus configured as described above, the frame Y-coordinate position detecting unit 24, as shown in FIG. 10, has a histogram having a height corresponding to the width of the character frame from the histogram in the Y-axis direction. The peak values A3 and A4 are calculated, and the start coordinate position Y3 in the Y-axis direction of the character frame corresponding to A3 and the end coordinate position Y4 corresponding to A4 are calculated.

【0010】次に、ヒストグラム生成部23は、Y座標
位置がY3からY4の範囲でX軸方向のヒストグラムを
生成する。この時、X軸方向のヒストグラムには図11
に示すような文字枠の縦幅に対応した高さのピークが得
られる。
Next, the histogram generator 23 generates a histogram in the X-axis direction in the Y coordinate position range of Y3 to Y4. At this time, the histogram in the X-axis direction is shown in FIG.
A height peak corresponding to the vertical width of the character frame is obtained as shown in.

【0011】枠X座標位置検出部25は文字枠によるピ
ークを選択するため、予め定められたしきい値Tをヒス
トグラム上に設定し、しきい値Tを越えるピークの数を
求めている。
The frame X-coordinate position detection unit 25 sets a predetermined threshold value T on the histogram in order to select a peak based on the character frame, and obtains the number of peaks exceeding the threshold value T.

【0012】そして、枠検知判定部27は、その数が
(枠の数×2)である時、文字枠が検出されたものと判
定していた。
Then, when the number is (number of frames × 2), the frame detection determination unit 27 determines that a character frame has been detected.

【0013】[0013]

【発明が解決しようとしている課題】しかしながら上記
のような従来の文字枠検出装置では、枠がかすれて印刷
されているといった文字枠の印字品質が低かったり、枠
のサイズが標準より大きい、あるいは小さいといった文
字枠のサイズが標準化されていない場合に、しきい値T
を越えるピークの数が(枠の数×2)とならないため、
文字枠が検出できず、文字枠検出精度が低下するという
問題点があった。
However, in the conventional character frame detecting device as described above, the print quality of the character frame is poor such that the frame is printed faintly, or the size of the frame is larger or smaller than the standard. If the size of the character box such as is not standardized, the threshold value T
Since the number of peaks that exceed is not (number of frames x 2),
There is a problem in that the character frame cannot be detected and the character frame detection accuracy decreases.

【0014】そこで本発明は、文字枠の記載が低印字品
質であったり、枠サイズが非標準であっても文字枠の検
出精度を低下させることのない文字枠検出装置を提供す
ることを目的としている。
SUMMARY OF THE INVENTION Therefore, an object of the present invention is to provide a character box detecting device which does not deteriorate the detection accuracy of the character box even if the description of the character box has a low print quality or the box size is nonstandard. I am trying.

【0015】[0015]

【課題を解決するための手段】上記目的を達成するため
本発明の文字枠検出装置は、文字枠が記載された紙葉類
の画像データから前記文字枠の縦方向および横方向の射
影蓄積データからなる2つのヒストグラムを生成するヒ
ストグラム生成部と、前記ヒストグラム生成部によって
生成された2つのヒストグラムからピークの位置を求め
るとともに、前記2つのヒストグラムのうち一方のヒス
トグラムについて、予め定められたしきい値を越えるピ
ークの数を計数することで、前記文字枠の位置および有
無を検出する文字枠検出部とを有する文字枠検出装置に
おいて、前記文字枠検出部には、前記しきい値を越える
ピークの数に応じて、前記しきい値を調整するしきい値
設定部を有することを特徴とする。
In order to achieve the above-mentioned object, a character box detecting device of the present invention is a projection accumulated data in the vertical and horizontal directions of the character frame from image data of a paper sheet in which the character frame is described. And a peak position is determined from the two histograms generated by the histogram generation unit, and a predetermined threshold value is set for one of the two histograms. In a character frame detection device having a character frame detection unit for detecting the position and presence / absence of the character frame by counting the number of peaks exceeding, the character frame detection unit is configured to detect peaks exceeding the threshold value. It is characterized by having a threshold value setting unit for adjusting the threshold value according to the number.

【0016】また、文字枠のX軸方向に生成されたヒス
トグラムのピークの幅が規定範囲内にあるか否かを判定
し、かつピーク間の間隔が規定範囲内にあるか否かを判
定するピーク判定部を備えていてもよい。
Further, it is determined whether the width of the peak of the histogram generated in the X-axis direction of the character frame is within the specified range, and whether the interval between the peaks is within the specified range. A peak determination unit may be provided.

【0017】さらに、前記文字枠は直線上に複数個配列
され、前記しきい値が前記文字枠の配列方向のヒストグ
ラムに対して定められていてもよく、この場合、前記紙
葉類は郵便物であり、前記文字枠として、郵便番号枠が
記載されていてもよい。
Further, a plurality of the character frames may be arranged in a straight line, and the threshold value may be determined with respect to a histogram in the arrangement direction of the character frames. In this case, the paper sheets are postal items. A postal code frame may be described as the character frame.

【0018】[0018]

【作用】上記のように構成された文字枠検出装置では、
ヒストグラム生成部で生成されたヒストグラムについ
て、しきい値を越えるピークの数が(枠の数×2)とな
らない場合、しきい値設定部は、ヒストグラムのピーク
値が低くければ、しきい値の設定値を下げ、ピーク値が
高ければ、しきい値の設定値を上げる。これにより、し
きい値を越えるピークの数を(枠の数×2)とする。
In the character frame detection device configured as described above,
In the histogram generated by the histogram generation unit, if the number of peaks exceeding the threshold does not reach (the number of frames × 2), the threshold setting unit determines the threshold value of the threshold if the peak value of the histogram is low. If the peak value is high, lower the setting value and increase the threshold setting value. As a result, the number of peaks exceeding the threshold value is set to (number of frames × 2).

【0019】また、ピーク判定部によって、ヒストグラ
ムのピークの幅が規定範囲内にあるか否かを判定し、か
つピーク間の間隔が規定範囲内にあるか否かを判定する
ことで、そのピーク座標位置は文字枠であるか、それと
も文字枠ではないかの判定が可能である。
The peak determining section determines whether or not the width of the peak of the histogram is within the specified range, and whether or not the interval between the peaks is within the specified range. It is possible to determine whether the coordinate position is in the character frame or not.

【0020】紙葉類に文字枠が直線上に複数個配列され
ている場合、しきい値を文字枠の配列方向のヒストグラ
ムに対して定めることで、文字枠ごとのピークを一度に
求められるので一度にすべての文字枠の検出処理が行え
る。
When a plurality of character frames are arranged on a straight line on a paper sheet, the peak for each character frame can be obtained at once by setting the threshold value for the histogram in the arrangement direction of the character frames. It is possible to detect all character frames at once.

【0021】特に、紙葉類が郵便物である場合には、郵
便番号枠の位置の検出が可能になる
In particular, when the paper sheet is a postal matter, the position of the postal code frame can be detected.

【0022】[0022]

【実施例】次に、本発明の実施例について図面を参照し
て説明する。
Embodiments of the present invention will now be described with reference to the drawings.

【0023】(第1実施例)図1は本発明の文字枠検出
装置の第1実施例の構成を示すブロック図である。
(First Embodiment) FIG. 1 is a block diagram showing the configuration of the first embodiment of the character box detection device of the present invention.

【0024】図1において、紙葉類Lは、5つの文字枠
が直線上に配列された郵便番号枠が記載された郵便物で
あり、本装置の処理対象となる物である。
In FIG. 1, the paper sheet L is a postal matter in which a postal code frame in which five character frames are arranged in a straight line is described, and is a processing target of the present apparatus.

【0025】走査部1は、紙葉類L上を光学的に走査
し、光電変換されて得られる画像データを出力する回路
であり、イメージメモリ2は、走査部1より読み込んだ
画像データを格納するメモリである。
The scanning unit 1 is a circuit that optically scans the paper sheet L and outputs image data obtained by photoelectric conversion. The image memory 2 stores the image data read by the scanning unit 1. Memory.

【0026】ヒストグラム生成部3は、イメージメモリ
2に格納された画像データからY軸方向(文字枠の縦方
向)及びX軸方向(文字枠の横方向)の射影蓄積データ
を算出し、Y軸方向及びX軸方向のヒストグラムを生成
する。
The histogram generator 3 calculates projection accumulation data in the Y-axis direction (vertical direction of the character frame) and X-axis direction (horizontal direction of the character frame) from the image data stored in the image memory 2, and the Y-axis is calculated. Generate a histogram in the direction and the X-axis direction.

【0027】文字枠検出部10は、枠Y座標位置検出部
4と枠X座標位置検出部5及び、文字切出し部6と枠検
知判定部7さらに、しきい値設定部8によって構成され
ている。 枠Y座標位置検出部4は、ヒストグラム生成
部3より出力されたY方向のヒストグラムを用いて文字
枠のY座標の位置を検出し、枠X座標位置検出部5は、
枠Y座標位置検出部4から求められた枠のY座標とヒス
トグラム生成部3から得られたX軸方向のヒストグラム
を用いて文字枠のX座標位置を検出する。
The character frame detection unit 10 is composed of a frame Y coordinate position detection unit 4, a frame X coordinate position detection unit 5, a character cutout unit 6, a frame detection determination unit 7, and a threshold value setting unit 8. . The frame Y coordinate position detection unit 4 detects the Y coordinate position of the character frame using the histogram in the Y direction output from the histogram generation unit 3, and the frame X coordinate position detection unit 5
The X coordinate position of the character frame is detected using the Y coordinate of the frame obtained from the frame Y coordinate position detection unit 4 and the histogram in the X axis direction obtained from the histogram generation unit 3.

【0028】文字切り出し部6は、枠Y座標位置検出部
4と枠X座標位置検出部5から求められた枠の座標位置
を、切り出し位置データとして使用して、イメージメモ
リ2に格納されている画像データから一文字毎に画像デ
ータを切り出す。
The character slicing unit 6 uses the coordinate position of the frame obtained from the frame Y coordinate position detecting unit 4 and the frame X coordinate position detecting unit 5 as the slicing position data and is stored in the image memory 2. Image data is cut out for each character from the image data.

【0029】枠検知判定部7は、枠Y座標位置検出部4
と枠X座標位置検出部5から得られた枠位置情報と文字
切り出し部6から得られた文字切り出し情報とを用い
て、文字枠の存在の有無及び文字枠内の文字の存在の有
無を判定している。
The frame detection determination unit 7 includes a frame Y coordinate position detection unit 4
Using the frame position information obtained from the frame X-coordinate position detection unit 5 and the character cutout information obtained from the character cutout unit 6, it is determined whether or not there is a character frame and whether or not there is a character in the character frame. are doing.

【0030】しきい値設定部8は、ヒストグラム生成部
3によって得られるヒストグラム上に、文字枠の有無を
判定するために設定されるしきい値Tを、しきい値Tを
越えるピークの数に応じて調整する処理を行っている。
The threshold value setting unit 8 sets the threshold value T, which is set for determining the presence or absence of a character frame on the histogram obtained by the histogram generation unit 3, to the number of peaks exceeding the threshold value T. The process of adjusting accordingly.

【0031】次に、本実施例の動作について、図2〜図
7を参照して説明する。
Next, the operation of this embodiment will be described with reference to FIGS.

【0032】図2は、図1に示した文字枠検出装置によ
る文字枠検出の手順を示したフローチャートであり、図
3は、文字枠のY軸方向のヒストグラムを表わした図、
図4は、文字枠が標準サイズの時のX軸方向のヒストグ
ラムを表わした図、図5は、文字枠がかすれている時の
X軸方向のヒストグラムを表わした図、図6は、文字枠
が標準よりも小さいサイズの時の、X軸方向のヒストグ
ラムを表わした図、図7は、文字枠が標準より大きいサ
イズの時の、X軸方向のヒストグラムを表わした図であ
る。
FIG. 2 is a flow chart showing the procedure of character frame detection by the character frame detection device shown in FIG. 1, and FIG. 3 is a diagram showing a histogram of the character frame in the Y-axis direction,
4 is a diagram showing a histogram in the X-axis direction when the character frame has a standard size, FIG. 5 is a diagram showing a histogram in the X-axis direction when the character frame is faint, and FIG. 6 is a character frame. Is a diagram showing a histogram in the X-axis direction when is smaller than the standard, and FIG. 7 is a diagram showing a histogram in the X-axis direction when the character frame is larger than the standard.

【0033】まず、走査部1は、文字枠記載の検知対象
である紙葉類L上を光学的に走査し、光電変換処理によ
り得られた画像データをイメージメモリ2に格納する。
ここで、通常、郵便番号枠等ではドロップアウトカラー
である赤色で枠が記載されているが、走査部1の光源は
赤色をドロップアウトカラーとしない例えば黄緑系の蛍
光ランプ等を使用し、赤色の郵便番号枠であっても黒色
の郵便番号枠と同等の画像データとしてイメージメモリ
2に格納する。
First, the scanning unit 1 optically scans the paper sheet L which is the detection target of the character frame description, and stores the image data obtained by the photoelectric conversion process in the image memory 2.
Here, normally, in a postal code frame or the like, a frame is described in red which is a dropout color, but the light source of the scanning unit 1 uses, for example, a yellow-green fluorescent lamp that does not use red as a dropout color, Even a red postal code frame is stored in the image memory 2 as image data equivalent to the black postal code frame.

【0034】次に、ヒストグラム生成部3は、イメージ
メモリ2の画像データを用いて図3に示すように文字枠
が記載されている可能性のある領域におけるY軸方向の
ヒストグラムを生成する(ステップS1)。
Next, the histogram generator 3 uses the image data of the image memory 2 to generate a histogram in the Y-axis direction in the region where the character frame may be described as shown in FIG. 3 (step S1).

【0035】続いて枠Y座標位置検出部4は、Y軸方向
のヒストグラムから文字枠の横幅に対応する高さである
ヒストグラムのピーク値A1及びA2を求め、文字枠の
Y軸方向のスタート座標位置Y1及びエンド座標位置Y
2を求める(ステップS2)。 次に、ヒストグラム生
成部3は、Y座標のY1からY2の画像領域範囲につい
て、図4に示すように、X軸方向のヒストグラムを生成
する(ステップS3)。
Subsequently, the frame Y-coordinate position detection unit 4 finds the peak values A1 and A2 of the histogram, which is the height corresponding to the width of the character frame, from the histogram in the Y-axis direction, and calculates the start coordinates of the character frame in the Y-axis direction. Position Y1 and end coordinate position Y
2 is calculated (step S2). Next, the histogram generation unit 3 generates a histogram in the X-axis direction for the image area range Y1 to Y2 of the Y coordinate, as shown in FIG. 4 (step S3).

【0036】そして、枠X座標位置検出部5は、X軸方
向のヒストグラムの高さがしきい値Tを越えるピークの
数を求め、そのX座標位置を登録する(ステップS
4)。
Then, the frame X-coordinate position detection unit 5 obtains the number of peaks in which the height of the histogram in the X-axis direction exceeds the threshold value T, and registers the X-coordinate position (step S).
4).

【0037】この時、登録されたX座標位置X[i]
(iは任意の数字)が文字枠の縦軸候補となる。また、
しきい値Tの値は、文字枠の標準的なサイズを想定して
得られる値が、しきい値設定部8によって設定されてい
る。
At this time, the registered X coordinate position X [i]
(I is an arbitrary number) is a vertical axis candidate of the character frame. Also,
The value of the threshold value T is set by the threshold value setting unit 8 as a value obtained assuming a standard size of the character frame.

【0038】次に、ステップS5において、枠検知判定
部7は、登録されたX座標位置X[i]なる縦軸候補数
をチェックする。
Next, in step S5, the frame detection determination unit 7 checks the number of vertical axis candidates for the registered X coordinate position X [i].

【0039】このとき、この縦軸候補数が10であれ
ば、全ての文字枠が検出されたと判定し、文字枠検出処
理を終了する(ステップS11)。
At this time, if the number of vertical axis candidates is 10, it is determined that all the character frames have been detected, and the character frame detection processing ends (step S11).

【0040】一方、ステップS5において縦軸候補数が
10でないとき、ステップS6で縦軸候補数をチェック
する。図5に示すように枠がかすれている場合、あるい
は図6に示すように枠が標準より小さい場合など、しき
い値Tによって得られる縦軸候補数が10未満のとき、
しきい値設定部8は、しきい値として新たなしきい値N
を設定する。新たなしきい値Nは次式を満足する値であ
る(ステップS7)。
On the other hand, if the number of vertical axis candidates is not 10 in step S5, the number of vertical axis candidates is checked in step S6. When the number of vertical axis candidates obtained by the threshold value T is less than 10, such as when the frame is faint as shown in FIG. 5 or when the frame is smaller than the standard as shown in FIG.
The threshold setting unit 8 uses the new threshold N as a threshold.
Set. The new threshold value N is a value that satisfies the following expression (step S7).

【0041】[0041]

【数1】N=T×α (0<α<1) 新たなしきい値Nが設定されたら、枠X座標位置検出部
5は、X軸方向のヒストグラムの高さがしきい値Nを越
えるピークの数を求め、そのX座標位置X[i]を縦軸
候補として新たに登録する(ステップS9)。
[Formula 1] N = T × α (0 <α <1) When a new threshold value N is set, the frame X-coordinate position detection unit 5 determines that the height of the histogram in the X-axis direction exceeds the threshold value N. The number is calculated, and the X coordinate position X [i] is newly registered as a vertical axis candidate (step S9).

【0042】そして、新たに登録されたX座標位置X
[i]なる縦軸候補数をチェックし(ステップS1
0)、縦軸候補数が10であれば、枠検知判定部7は全
ての文字枠が検出されたと判定して(ステップS1
1)、文字枠検出処理を終了する。
Then, the newly registered X coordinate position X
Check the number of vertical axis candidates [i] (step S1
0) and if the number of vertical axis candidates is 10, the frame detection determination unit 7 determines that all character frames have been detected (step S1).
1) The character frame detection process is ended.

【0043】一方、縦軸候補数が10でないときは、文
字枠が未検出と判定し(ステップS12)、文字枠検出
処理を終了する。
On the other hand, when the number of vertical axis candidates is not 10, it is determined that the character frame has not been detected (step S12), and the character frame detection process is terminated.

【0044】また、図7に示すように文字枠が標準より
大きい場合など、ステップS6で縦軸候補数をチェック
した結果、しきい値Tによって得られる縦軸候補数が1
0より多くなるときには、しきい値設定部8は、しきい
値として、次式を満足する新たなしきい値N’を設定す
る。新たなしきい値N’は次式を満足する値である(ス
テップS8)。
Further, as shown in FIG. 7, when the character frame is larger than the standard, the number of vertical axis candidates is checked in step S6, and as a result, the number of vertical axis candidates obtained by the threshold value T is 1
When it is greater than 0, the threshold value setting unit 8 sets a new threshold value N ′ satisfying the following expression as a threshold value. The new threshold value N'is a value that satisfies the following expression (step S8).

【0045】[0045]

【数2】N’=T×β (β>1) 新たなしきい値N’が設定されたら、枠X座標位置検出
部5は、X軸方向のヒストグラムの高さがしきい値N’
を越えるピークの数を求め、そのX座標位置X[i]を
縦軸候補として新たに登録する(ステップS9)。
[Formula 2] N ′ = T × β (β> 1) When a new threshold value N ′ is set, the frame X coordinate position detection unit 5 determines that the height of the histogram in the X axis direction is the threshold value N ′.
The number of peaks exceeding is calculated, and the X coordinate position X [i] is newly registered as a vertical axis candidate (step S9).

【0046】そして、新たに登録されたX座標位置X
[i]なる縦軸候補数をチェックし(ステップS1
0)、縦軸候補数が10であれば、枠検知判定部7は全
ての文字枠が検出されたと判定し(ステップS11)、
文字枠検出処理を終了する。
Then, the newly registered X coordinate position X
Check the number of vertical axis candidates [i] (step S1
0), if the number of vertical axis candidates is 10, the frame detection determination unit 7 determines that all character frames have been detected (step S11),
The character frame detection process ends.

【0047】一方、縦軸候補数が10でないときは、文
字枠が未検出と判定し(ステップS12)、文字枠検出
処理を終了する。
On the other hand, when the number of vertical axis candidates is not 10, it is determined that the character frame has not been detected (step S12), and the character frame detection process is terminated.

【0048】上記のように、文字枠検出装置に、ヒスト
グラムのピーク値に応じてしきい値を設定するしきい値
設定部8を設けることにより、文字枠がかすれて印刷さ
れていたり、標準サイズより小さい場合に、X軸方向の
ヒストグラムから文字枠の縦軸候補を求める時は、しき
い値をN=T×α(0<α<1)に再設定することによ
り、文字枠の座標位置を検出することができる。
As described above, by providing the threshold setting unit 8 for setting the threshold according to the peak value of the histogram in the character frame detecting device, the character frame is printed faintly or is printed in the standard size. If the vertical axis candidate of the character frame is obtained from the histogram in the X-axis direction when the value is smaller, the threshold value is reset to N = T × α (0 <α <1) to determine the coordinate position of the character frame. Can be detected.

【0049】また、文字枠が標準サイズより大きく印刷
されていた場合に、X軸方向のヒストグラムから文字枠
の縦軸候補を求める時は、しきい値をN’=T×β(β
>1)に再設定することにより、文字枠の座標位置を検
出することができる。
Further, when the character frame is printed larger than the standard size and the vertical axis candidate of the character frame is obtained from the histogram in the X-axis direction, the threshold value is N ′ = T × β (β
By resetting to> 1), the coordinate position of the character frame can be detected.

【0050】(実施例2)図8は、本発明の第2実施例
の構成を示す図であり、文字枠検出部20に、X軸方向
に生成されたヒストグラムのピークの幅が規定範囲内で
あるか否かを判定し、かつピーク間の間隔が規定範囲内
にあるか否かを判定するピーク判定部19を付加した点
が、第1実施例と異なる。その他の構成は第1実施例と
同様であるので、その説明は省略する。
(Embodiment 2) FIG. 8 is a diagram showing the configuration of the second embodiment of the present invention, in which the width of the peak of the histogram generated in the X-axis direction in the character box detection unit 20 is within the specified range. It is different from the first embodiment in that a peak determining unit 19 is added to determine whether or not the peak interval is within a specified range. The other structure is similar to that of the first embodiment, and the description thereof is omitted.

【0051】本実施例においては、ヒストグラム上のし
きい値Tを越えるピークの幅をしきい値Tと横切る点で
測定し、その幅が規定範囲内であるかを判定し、かつピ
ーク間の間隔が規定範囲内にあるか否かを判定すること
により、文字等によるピークが文字枠のピークより高い
ことがあっても、そのピークを無視することが可能にな
る。従って、文字枠でない部分を文字枠として検出して
しまうことを防止することができる。
In the present embodiment, the width of the peak on the histogram that exceeds the threshold T is measured at a point that intersects the threshold T, it is determined whether the width is within the specified range, and By determining whether or not the interval is within the specified range, even if the peak due to characters or the like is higher than the peak of the character frame, the peak can be ignored. Therefore, it is possible to prevent a portion other than the character frame from being detected as the character frame.

【0052】なお、ここでのピークの幅及びピーク間の
間隔の規定範囲とは、標準的な文字枠を想定して得られ
るヒストグラムから設定される。
The peak width and the specified range of the interval between peaks here are set from a histogram obtained by assuming a standard character frame.

【0053】ところで、本実施例では、郵便番号が5桁
の場合について説明しているが、桁数が異なっていても
本構成を適用することができる。
By the way, in the present embodiment, the case where the postal code has five digits has been described, but the present configuration can be applied even if the number of digits is different.

【0054】さらに、本実施例では、文字枠が横方向に
並んだ場合について郵便番号枠を例にして説明している
が、Y軸方向のヒストグラム上にしきい値を設定し、そ
れを越えるピークの数を求めることで、文字枠が縦に並
んだ場合についても本構成を適用することができる。
Further, in the present embodiment, the case where the character frames are arranged in the horizontal direction has been described by taking the postal code frame as an example. However, a threshold value is set on the histogram in the Y-axis direction and peaks exceeding it are set. The present configuration can be applied to the case where the character frames are arranged vertically by determining the number of.

【0055】[0055]

【発明の効果】本発明は、以上説明したように構成され
ているので、以下に記載されている効果を奏する。
Since the present invention is constructed as described above, it has the following effects.

【0056】請求項1に記載のものにおいては、ヒスト
グラムのピーク値に応じてしきい値を再設定する事で、
文字枠の印字品質が低かったり、文字枠のサイズが標準
化されていない場合であっても、文字枠の検出精度を向
上させることができる。
According to the first aspect of the present invention, by resetting the threshold value according to the peak value of the histogram,
Even if the print quality of the character frame is low or the size of the character frame is not standardized, the detection accuracy of the character frame can be improved.

【0057】請求項2に記載のものにおいては、しきい
値Tを越えるヒストグラムのピークの幅が規定範囲内で
あるか否かを判定し、かつピーク間の間隔が規定範囲内
にあるか否かを判定することにより、文字枠以外の部分
を文字枠として検出してしまうことを防止することがで
きる。
According to the second aspect of the present invention, it is determined whether the width of the peak of the histogram exceeding the threshold value T is within the specified range, and whether the interval between the peaks is within the specified range. By determining whether or not it is possible to prevent a portion other than the character frame from being detected as a character frame.

【0058】請求項3に記載のものにおいては、文字枠
が複数個ある場合、一度にすべての文字枠について、位
置および有無を検出することができる。
In the third aspect, when there are a plurality of character frames, the position and presence / absence of all the character frames can be detected at one time.

【0059】請求項4に記載のものにおいては、文字枠
の検出を郵便物の郵便番号枠の検出に適用することで、
郵便番号枠の検出精度が向上し、その結果、郵便物の取
り揃え業務の信頼性を向上させることができる。
According to the fourth aspect of the invention, the detection of the character frame is applied to the detection of the postal code frame of the mail,
The detection accuracy of the postal code frame is improved, and as a result, the reliability of the mail sorting operation can be improved.

【図面の簡単な説明】[Brief description of drawings]

【図1】本発明の第1実施例の構成を示すブロック図で
ある。
FIG. 1 is a block diagram showing a configuration of a first exemplary embodiment of the present invention.

【図2】文字枠検出装置による文字枠検出の手順を示し
たフローチャートである。
FIG. 2 is a flowchart showing a procedure for detecting a character frame by the character frame detection device.

【図3】文字枠のY軸方向のヒストグラムを表わした図
である。
FIG. 3 is a diagram showing a histogram of a character frame in the Y-axis direction.

【図4】文字枠が標準サイズの時のX軸方向のヒストグ
ラムを表わした図である。
FIG. 4 is a diagram showing a histogram in the X-axis direction when a character frame has a standard size.

【図5】文字枠がかすれている時のX軸方向のヒストグ
ラムを表わした図である。
FIG. 5 is a diagram showing a histogram in the X-axis direction when a character frame is blurred.

【図6】文字枠が標準より小さいサイズの時のX軸方向
のヒストグラムを表わした図である。
FIG. 6 is a diagram showing a histogram in the X-axis direction when the character frame is smaller than the standard size.

【図7】文字枠が標準より大きいサイズの時のX軸方向
のヒストグラムを表わした図である。
FIG. 7 is a diagram showing a histogram in the X-axis direction when the character frame has a size larger than the standard.

【図8】本発明の第2実施例の構成を示すブロック図で
ある。
FIG. 8 is a block diagram showing a configuration of a second exemplary embodiment of the present invention.

【図9】従来の文字枠検出装置の構成を示すブロック図
である。
FIG. 9 is a block diagram showing a configuration of a conventional character frame detection device.

【図10】文字枠のY軸方向のヒストグラムを表わした
図である。
FIG. 10 is a diagram showing a histogram of a character frame in the Y-axis direction.

【図11】文字枠のX軸方向のヒストグラムを表わした
図である。
FIG. 11 is a diagram showing a histogram of a character frame in the X-axis direction.

【符号の説明】[Explanation of symbols]

L 紙葉類 1、21 走査部 2、22 イメージメモリ 3、23 ヒストグラム生成部 4、24 枠Y座標位置検出部 5、25 枠X座標位置検出部 6、26 文字切り出し部 7、27 枠検知判定部 8 しきい値判定部 10、20、30 文字枠検出部 19 ピーク判定部 L paper sheets 1, 21 scanning unit 2, 22 image memory 3, 23 histogram generation unit 4, 24 frame Y coordinate position detection unit 5, 25 frame X coordinate position detection unit 6, 26 character cutting unit 7, 27 frame detection determination Part 8 Threshold judgment part 10, 20, 30 Character box detection part 19 Peak judgment part

Claims (4)

【特許請求の範囲】[Claims] 【請求項1】 文字枠が記載された紙葉類の画像データ
から前記文字枠の縦方向および横方向の射影蓄積データ
からなる2つのヒストグラムを生成するヒストグラム生
成部と、前記ヒストグラム生成部によって生成された2
つのヒストグラムからピークの位置を求めるとともに、
前記2つのヒストグラムのうち一方のヒストグラムつい
て、予め定められたしきい値を越えるピークの数を計数
することで、前記文字枠の位置および有無を検出する文
字枠検出部とを有する文字枠検出装置において、 前記文字枠検出部には、前記しきい値を越えるピークの
数に応じて、前記しきい値を調整するしきい値設定部が
備えられたことを特徴とする文字枠検出装置。
1. A histogram generation unit that generates two histograms composed of projection accumulation data in the vertical and horizontal directions of the character frame from image data of a paper sheet in which the character frame is described, and a histogram generation unit. Was done 2
While obtaining the position of the peak from the two histograms,
A character box detecting device having a character box detecting unit for detecting the position and presence / absence of the character box by counting the number of peaks exceeding a predetermined threshold value for one of the two histograms. 2. The character box detecting device according to claim 1, wherein the character box detecting section includes a threshold value setting section that adjusts the threshold value according to the number of peaks exceeding the threshold value.
【請求項2】 請求項1に記載の文字枠検出装置におい
て、 前記文字枠検出部には、前記ヒストグラムのピークの幅
が規定範囲内にあるか否かを判定し、かつピーク間の間
隔が規定範囲内にあるか否かを判定するピーク判定部が
備えられたことを特徴とする文字枠検出装置。
2. The character frame detection device according to claim 1, wherein the character frame detection unit determines whether or not the width of the peak of the histogram is within a specified range, and the interval between the peaks is A character box detecting device comprising a peak determining unit for determining whether or not the character frame is within a prescribed range.
【請求項3】 請求項1または2のいずれかに記載の文
字枠検出装置において、 前記文字枠は直線上に複数個配列され、前記しきい値が
前記文字枠の配列方向のヒストグラムに対して定められ
ている文字枠検出装置。
3. The character frame detection device according to claim 1, wherein a plurality of the character frames are arranged on a straight line, and the threshold value is with respect to a histogram in an arrangement direction of the character frames. A defined character box detection device.
【請求項4】 請求項3に記載の文字枠検出装置におい
て、 前記紙葉類は郵便物であり、前記文字枠として郵便番号
枠が記載されている文字枠検出装置。
4. The character frame detection device according to claim 3, wherein the paper sheet is a postal matter, and a zip code frame is described as the character frame.
JP6139893A 1994-06-22 1994-06-22 Character frame detecting device Pending JPH087031A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP6139893A JPH087031A (en) 1994-06-22 1994-06-22 Character frame detecting device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP6139893A JPH087031A (en) 1994-06-22 1994-06-22 Character frame detecting device

Publications (1)

Publication Number Publication Date
JPH087031A true JPH087031A (en) 1996-01-12

Family

ID=15256068

Family Applications (1)

Application Number Title Priority Date Filing Date
JP6139893A Pending JPH087031A (en) 1994-06-22 1994-06-22 Character frame detecting device

Country Status (1)

Country Link
JP (1) JPH087031A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6983071B2 (en) 2001-05-16 2006-01-03 Nec Corporation Character segmentation device, character segmentation method used thereby, and program therefor
JP2008276458A (en) * 2007-04-27 2008-11-13 Nidec Sankyo Corp Character string recognition method and character string recognition device
JP2009169712A (en) * 2008-01-17 2009-07-30 Nidec Sankyo Corp Method and apparatus for magnetic character recognition
JP2009289195A (en) * 2008-05-30 2009-12-10 Nidec Sankyo Corp Method and apparatus for magnetic character recognition

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61267184A (en) * 1985-05-22 1986-11-26 Fujitsu Ltd Row position detecting system of character string
JPS62221790A (en) * 1986-03-24 1987-09-29 Toshiba Corp Character reader
JPH0271387A (en) * 1988-09-07 1990-03-09 Nec Corp Optical character reader

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61267184A (en) * 1985-05-22 1986-11-26 Fujitsu Ltd Row position detecting system of character string
JPS62221790A (en) * 1986-03-24 1987-09-29 Toshiba Corp Character reader
JPH0271387A (en) * 1988-09-07 1990-03-09 Nec Corp Optical character reader

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6983071B2 (en) 2001-05-16 2006-01-03 Nec Corporation Character segmentation device, character segmentation method used thereby, and program therefor
JP2008276458A (en) * 2007-04-27 2008-11-13 Nidec Sankyo Corp Character string recognition method and character string recognition device
JP2009169712A (en) * 2008-01-17 2009-07-30 Nidec Sankyo Corp Method and apparatus for magnetic character recognition
JP2009289195A (en) * 2008-05-30 2009-12-10 Nidec Sankyo Corp Method and apparatus for magnetic character recognition

Similar Documents

Publication Publication Date Title
US4998626A (en) Mail processing machine
JP3124296B2 (en) How to detect the position and direction of the fiducial mark
JPH087031A (en) Character frame detecting device
US5267325A (en) Locating characters for character recognition
KR100435125B1 (en) Apparatus for detecting a stamp, method for detecting a stamp, apparatus for processing a letter and method for processing a letter
EP0076332A1 (en) Optical character reader with pre-scanner
JP2001109887A (en) Area extracting method, method and device for extracting address area, and image processor
JPS59180783A (en) Optical character reader
CN108492446A (en) A kind of bank note edge finding method and system
JP2924440B2 (en) Address description area detection device
JPH09179982A (en) Specific pattern detecting method
JP2690483B2 (en) Character line extraction method
JP3036166B2 (en) Word type determination device
JP2000222577A (en) Method and device for ruled line processing, and recording medium
JPH08249419A (en) Table area judging device
JPS62169287A (en) Recorded character type discriminating system
JPS61267184A (en) Row position detecting system of character string
JP3155869B2 (en) Paper sheet processing apparatus and paper sheet processing method
JPS6252687A (en) Character detecting and segmenting system for character reader
JPH08202814A (en) Mail address reader and its method
JP3476936B2 (en) Character line direction determination device
JPH04139593A (en) Postal code number recognition device
JPS63136181A (en) Character reader
JPH0632074B2 (en) Normalization method
JPH01255985A (en) Character reading device

Legal Events

Date Code Title Description
LAPS Cancellation because of no payment of annual fees