JPH067389B2 - Image processing device - Google Patents
Image processing deviceInfo
- Publication number
- JPH067389B2 JPH067389B2 JP59197945A JP19794584A JPH067389B2 JP H067389 B2 JPH067389 B2 JP H067389B2 JP 59197945 A JP59197945 A JP 59197945A JP 19794584 A JP19794584 A JP 19794584A JP H067389 B2 JPH067389 B2 JP H067389B2
- Authority
- JP
- Japan
- Prior art keywords
- contour
- pixel
- tracking
- input pattern
- tracing
- 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.)
- Expired - Lifetime
Links
Landscapes
- Character Discrimination (AREA)
- Closed-Circuit Television Systems (AREA)
- Image Analysis (AREA)
Description
【発明の詳細な説明】 <発明の技術分野> 本発明は、文字、図形等の画像入力を白黒2値化して入
力パターンを求め、この入力パターンにつき辞書等の照
合処理を実行して、未知文字等を認識する技術に関連
し、殊に本発明は、前記照合処理に先立ち、入力パター
ンの輪郭線を高速度で追跡するための画像処理装置に関
する。DETAILED DESCRIPTION OF THE INVENTION Technical Field of the Invention According to the present invention, an input pattern is obtained by binarizing an image input of characters, figures, etc. into black and white, and a matching process such as a dictionary is executed for this input pattern to obtain an unknown pattern. The present invention relates to a technique for recognizing characters and the like, and more particularly, the present invention relates to an image processing apparatus for tracking the contour line of an input pattern at high speed prior to the matching process.
<発明の背景> 従来のこの種装置は、第10図に示す如く、文字、図形
等をCCD(Charged-Coupled Device)より成るカメラ21
にて画像化し、この画像入力を2値化回路22で白黒2
値化して入力パターンを求め、この入力パターンを画像
メモリ23へ格納した後、画像メモリ23中の入力パタ
ーンにつき、輪郭追跡回路24を動作させて、輪郭線の
追跡処理を実行している。この輪郭追跡処理は、画像メ
モリ23上に第11図に示すマスク25を設定してこれ
を所定方向(図中、矢印で示す)へ走査し、各画素につ
きその画素データSおよびその周囲4方向近傍の画素デ
ータS0〜S3をチェックし、そのデータ構成に基づき追跡
開始点を求めた後、入力パターンの輪郭黒画素を所定方
向へ順次追跡してゆく。<Background of the Invention> As shown in FIG. 10, a conventional device of this type has a camera 21 which is a CCD (Charged-Coupled Device) for characters and figures.
The image is converted into a black and white image by the binarization circuit 22.
After binarizing the input pattern and storing the input pattern in the image memory 23, the contour tracking circuit 24 is operated for the input pattern in the image memory 23 to execute the contour line tracking process. In this contour tracking processing, the mask 25 shown in FIG. 11 is set on the image memory 23, and the mask 25 is scanned in a predetermined direction (indicated by an arrow in the drawing), and the pixel data S and four directions around the pixel data S for each pixel. After checking the pixel data S 0 to S 3 in the vicinity and obtaining the tracking start point based on the data structure, the contour black pixels of the input pattern are sequentially tracked in a predetermined direction.
この場合、第1番目の輪郭線につき追跡処理が終了する
と、更に前記の走査を再開して、つぎの追跡開始点を検
出し、同様の輪郭線追跡処理を実行する。そして全ての
輪郭線につき追跡処理が終了して、追跡開始点を発見で
きなかったとき、輪郭線追跡の全処理を完了させる(第
12図のフローチャート参照)。In this case, when the tracking processing for the first contour line is completed, the above scanning is restarted, the next tracking start point is detected, and the same contour line tracking processing is executed. When the tracking processing is completed for all the contour lines and the tracking start point cannot be found, all the processing of contour line tracking is completed (see the flowchart of FIG. 12).
従って上記従来方式によれば、画像メモリ中に多数の輪
郭線が含まれるような場合、各輪郭線にかかる追跡開始
点を検出するのに、各走査位置毎にマスク内を5画素ア
クセスし且つこれを画像メモリの端から端まで実施する
必要がある。これがため輪郭追跡処理における追跡開始
点の検出処理時間が著しく大きくなり、これが輪郭線追
跡の処理効率、ひいてはパターン認識の処理効率を低下
させる要因となっている。Therefore, according to the above-mentioned conventional method, when a large number of contour lines are included in the image memory, five pixels are accessed in the mask for each scanning position in order to detect the tracking start point of each contour line. This needs to be done across the image memory. For this reason, the processing time for detecting the tracking start point in the contour tracking processing becomes remarkably long, which is a factor that reduces the processing efficiency of the contour tracking, and thus the pattern recognition processing efficiency.
<発明の目的> 本発明は、入力パターンの輪郭線追跡に際し、追跡開始
点の検出を高速化した画像処理装置を提供し、もって輪
郭追跡処理時間の短縮、更にはパターン認識処理効率の
向上をはかることを目的とする。<Objects of the Invention> The present invention provides an image processing apparatus that speeds up the detection of a tracking start point when tracing the contour line of an input pattern, thereby shortening the contour tracing processing time and further improving the pattern recognition processing efficiency. The purpose is to measure.
<発明の構成および効果> 上記目的を達成するため、本発明では、入力パターン記
憶用の画像メモリに、入力パターンを構成する2値画像
データと、輪郭追跡処理時に設定される追跡処理データ
として入力パターンの輪郭構成画素に設定される輪郭フ
ラグおよび次の輪郭構成画素への追跡方向に応じて設定
されるペアフラグとを、各画素に対応して格納するよう
構成し、輪郭追跡開始点の検出処理に際しては、画像メ
モリを所定方向に走査し各画素を順次アクセスすること
により、各画素の2値画像データおよび追跡処理データ
を取り込み、これらデータ内容に基づいてアクセス対象
画素が輪郭追跡処理済の入力パターンの内外いずれに位
置するかを認識すると共に、その認識結果に基づきその
画素を輪郭追跡処理の開始点とするか否かを決定するよ
うにした。<Structure and Effect of the Invention> In order to achieve the above object, according to the present invention, binary image data forming an input pattern and tracking processing data set during contour tracking processing are input to an image memory for storing an input pattern. The contour flag set in the contour constituent pixels of the pattern and the pair flag set according to the tracking direction to the next contour constituent pixel are configured to be stored corresponding to each pixel, and the contour tracking start point detection processing is performed. In this case, the image memory is scanned in a predetermined direction and each pixel is sequentially accessed to take in binary image data and tracking processing data of each pixel, and the access target pixel is input for which contour tracking processing has been completed based on the data contents. Whether the pixel is located inside or outside the pattern is recognized, and based on the recognition result, it is determined whether or not the pixel is used as the starting point of the contour tracking process. I decided to set it.
本発明によれば、画像メモリを走査して輪郭追跡開始点
を検出する場合に、画像メモリの全画素を夫々1回宛ア
クセスすればよく、輪郭追跡処理における追跡開始点の
検出を簡単且つ迅速に実施し得、輪郭線追跡の処理時間
を大幅に短縮でき、パターン認識処理の効率を向上し得
る等、発明目的を達成した顕著な効果を奏する。According to the present invention, when the contour tracking start point is detected by scanning the image memory, all the pixels of the image memory need only be accessed once, and the tracking start point in the contour tracking process can be detected easily and quickly. In addition, the processing time for contour line tracking can be greatly shortened, and the efficiency of pattern recognition processing can be improved.
<実施例の説明> 第1図は本発明にかかる画素処理装置の構成例を示す。<Description of Embodiments> FIG. 1 shows a configuration example of a pixel processing device according to the present invention.
図示例の装置は、画像入力を白黒2値化して形成された
入力パターンを縦横複数の画素範囲に格納する画像メモ
リ1と、画像メモリ1を所定方向に走査して各画素を順
次アクセスしてゆく走査回路2と、画像メモリ1の各画
素のデータを順次取り込んで現アクセス対象画素のパタ
ーン状態を認識するための状態認識部3と、状態認識部
3の認識結果に基づきその画素を輪郭追跡開始点として
検出するか否かを判定するコントロールROM(Read Only
Memory)4とから構成されている。 前記画像メモリ1の各画素には、第2図に示すb0〜b7の
8ビットデータが格納されるようになっており、本実施
例の場合、0番目のビットb0には2値画像データ(黒画
素が「1」,白画素が「0」)、6番目のビットb6には
ペアフラグ(「1」または「0」)、7番目のビットb7
には輪郭フラグ(輪郭点が「1」,それ以外が「0」)
が、夫々セットされる。このペアフラグおよび輪郭フラ
グは、輪郭線追跡処理が実行された画素についてのみセ
ットされるもので、第3図に示す入力パターン5の場
合、図中、○印の画素に輪郭フラグ「1」が、また斜線
の画素にペアフラグ「1」が夫々セットされている。The apparatus of the illustrated example stores an image memory 1 that stores an input pattern formed by binarizing an image input in a plurality of vertical and horizontal pixel ranges, and scans the image memory 1 in a predetermined direction to sequentially access each pixel. A scanning circuit 2, a state recognition unit 3 for sequentially capturing data of each pixel of the image memory 1 and recognizing a pattern state of a currently accessed pixel, and a contour tracking of the pixel based on a recognition result of the state recognition unit 3. Control ROM (Read Only) that determines whether to detect as a start point
Memory) 4 and. In each pixel of the image memory 1, 8-bit data b 0 to b 7 shown in FIG. 2 is stored. In the case of the present embodiment, the 0th bit b 0 is binary. Image data (black pixel is “1”, white pixel is “0”), 6th bit b 6 is pair flag (“1” or “0”), 7th bit b 7
Is a contour flag (contour points are "1", other points are "0")
But each is set. The pair flag and the contour flag are set only for the pixels for which the contour line tracking processing has been executed. In the case of the input pattern 5 shown in FIG. 3, the contour flag “1” is assigned to the pixel marked with a circle in the figure. Further, the pair flag "1" is set to each of the shaded pixels.
第4図乃至第6図は、ペアフラグの設定方法を示してい
る。今、第4図に示す入力パターン6につき、図中矢印
で示す如く輪郭線の追跡を実行する場合、ある画素T0か
らつぎの画素T1へ輪郭線を追跡すると、その都度、追跡
方向を第5図に示す8方向コードで規定すると共に、第
6図に示す手順を実行して、対応画素にペアフラグを立
てる。第6図において、ステップ1(図中、「ST1」の
如く示す)およびステップ2は方向コードdirを判定す
るものであり、方向コードdirが1,2,3のいずれか
であるとき、ステップ1が“YES”となり、追跡元に
かかる画素T0のペアフラグを反転させる(ステップ
3)。また方向コードdirが5,6,7のいずれかであ
るとき、ステップ2が“YES”となり、追跡先にかか
る画素T1のペアフラグを反転させる(ステップ4)。更
に方向コードdirが0、4のいずれかであるとき、ステ
ップ1およびステップ2のいずれもが“NO”となり、
両画素T0,T1のペアフラグはそのままとする。尚各画素
におけるペアフラグはその初期状態では「0」である。4 to 6 show a pair flag setting method. Now, for the input pattern 6 shown in FIG. 4, when the contour line is traced as indicated by the arrow in the figure, when the contour line is traced from one pixel T 0 to the next pixel T 1 , the tracing direction is changed each time. It is specified by the 8-direction code shown in FIG. 5, and the procedure shown in FIG. 6 is executed to set a pair flag in the corresponding pixel. In FIG. 6, step 1 (indicated as "ST1" in the figure) and step 2 are for determining the direction code dir. When the direction code dir is 1, 2, or 3, step 1 Becomes "YES", and the pair flag of the pixel T 0 related to the tracking source is inverted (step 3). When the direction code dir is 5, 6, or 7, step 2 becomes "YES", and the pair flag of the pixel T 1 of the tracking destination is inverted (step 4). Further, when the direction code dir is either 0 or 4, both step 1 and step 2 become “NO”,
The pair flag of both pixels T 0 and T 1 remains unchanged. The pair flag in each pixel is "0" in the initial state.
かくて画像メモリ1は、各画素毎に2値画像データ、ペ
アフラグ、輪郭フラグを含むデータIMEMが格納されてお
り、この画像メモリ1を走査回路にて走査し各画素を順
次アクセスすることにより、各画素のデータIMEMを順次
状態認識部3に取り込む。この場合、前記走査回路で
は、最初ラッチ回路7に初期設定アドレスadrをラッチ
し、アドレス加算部8にて1加算して、画像メモリ1を
アクセスするアドレスNadrを得、以下同様の加算処理を
繰り返して、このアドレスNadrを更新してゆく。Thus, the image memory 1 stores binary image data for each pixel, data IMEM including a pair flag and a contour flag. By scanning the image memory 1 with a scanning circuit and sequentially accessing each pixel, The data IMEM of each pixel is sequentially taken into the state recognition unit 3. In this case, in the scanning circuit, the initial setting address adr is first latched in the latch circuit 7 and 1 is added in the address adding unit 8 to obtain the address Nadr for accessing the image memory 1, and the same adding process is repeated thereafter. Then, this address Nadr will be updated.
状態認識部3は、現アクセス対象画素がパターン中でど
のような状態にあるのかを前記データIMEMに基づき認識
するもので、例えば第7図に示す如く、ペアフラグを入
力してQ端子より符号Aで示す出力を出すフリップフロ
ップ9と、A出力および輪郭フラグを入力して符号Bで
示す出力を出すオア回路10とで構成されている。今第
3図に示す入力パターン5を同図の矢印方向に走査した
場合を想定すると、ペアフラグ、輪郭フラグ、A出力、
B出力の各レベルは図に示す如くになり、B出力がパタ
ーンの状態に対応することがわかる。従ってB出力が論
理「1」ならば、入力パターンの内側に、また論理
「0」ならば、入力パターンの外側に、夫々アクセス対
象画素が位置していると判断できる。The state recognition unit 3 recognizes the state of the current access target pixel in the pattern based on the data IMEM. For example, as shown in FIG. 7, a pair flag is input and a code A is input from the Q terminal. It is composed of a flip-flop 9 which outputs an output indicated by and an OR circuit 10 which inputs the A output and the contour flag and outputs an output indicated by a symbol B. Assuming that the input pattern 5 shown in FIG. 3 is scanned in the direction of the arrow in FIG. 3, a pair flag, a contour flag, an A output,
The levels of the B output are as shown in the figure, and it can be seen that the B output corresponds to the state of the pattern. Therefore, if the B output is a logical "1", it can be determined that the access target pixel is located inside the input pattern, and if it is a logical "0", the access target pixel is located outside the input pattern.
この状態認識部3の認識結果に基づきつぎのコントロー
ルROM4は、アクセス対象画素を輪郭追跡開始点として検
出するか否かを判断するもので、もし追跡開始点としな
いとき、LC出力をラッチ回路7へ送ってアドレスNadr
をラッチし、一方追跡開始点とするときは、END出力
を出し、追跡開始点アドレスSadrを得る。Based on the recognition result of the state recognition section 3, the next control ROM 4 judges whether or not the pixel to be accessed is detected as the contour tracking start point. If the tracking start point is not set, the LC output is the latch circuit 7 Send to address Nadr
When the tracking start point is set, the END output is output and the tracking start point address Sadr is obtained.
第8図は、上記コントロールROM4における追跡開始点
の判断テーブルを示し、同図中、P1〜P5は第9図に示す
画像メモリ1上の各点のP1〜P5に対応している。この第
9図に示す画像メモリ1には、輪郭線追跡処理済の第1
の入力パターン11(図中、○印は輪郭フラグ「1」の
画素を示す)と、未処理の第2の入力パターン12とが
格納されており、点P1〜P3は第1の入力パターン11の
内側に、点P4は第2の入力パターン12の内側に、点
P5は両入力パターン11,12の外側に夫々位置して
いる。かくしてコントロールROM4は、B出力、輪郭フ
ラグ、2値画像データの内容に基づき上記判断を行なう
もので、第8図に示す例では、B出力の論理が「0」、
輪郭フラグが「0」、2値画像データが論理「1」であ
る点P4が輪郭追跡開始点として検出される。FIG. 8 shows a determination table of the tracking start point in the control ROM 4, in which P1 to P5 correspond to P1 to P5 of each point on the image memory 1 shown in FIG. In the image memory 1 shown in FIG. 9, the first contour-tracked first
Input pattern 11 (in the figure, a circle indicates a pixel of contour flag “1”) and an unprocessed second input pattern 12 are stored, and points P1 to P3 are the first input pattern 11 , The point P4 is located inside the second input pattern 12, and the point P5 is located outside both input patterns 11 and 12. Thus, the control ROM 4 makes the above determination based on the contents of the B output, the contour flag and the binary image data. In the example shown in FIG. 8, the B output logic is "0",
A point P4 where the contour flag is "0" and the binary image data is logical "1" is detected as the contour tracking start point.
第1図は本発明にかかる2値画像処理装置の構成例を示
す回路ブロック図、第2図は画像メモリの各画素へ格納
されるデータのフォーマットを示す図、第3図は入力パ
ターンと各フラグおよび出力との対応関係を示す図、第
4図は入力パターンの輪郭線追跡処理を説明するための
図、第5図は8方向コードを説明するための図、第6図
はペアフラグ設定処理動作を示すフローチャート、第7
図は状態認識部の具体回路を示す回路図、第8図は追跡
開始点の検出テーブルを示す図、第9図は第8図に対応
する画像メモリ上の各点を示す図、第10図は従来例の
装置構成を示すブロック図、第11図は従来例の輪郭追
跡開始点の検出処理を説明するための図、第12図は輪
郭追跡処理を示すフローチャートである。 1……画像メモリ、2……走査回路 3……状態認識部 4……コントロールROMFIG. 1 is a circuit block diagram showing a configuration example of a binary image processing device according to the present invention, FIG. 2 is a diagram showing a format of data stored in each pixel of an image memory, and FIG. 3 is an input pattern and each FIG. 4 is a diagram showing a correspondence relationship between a flag and an output, FIG. 4 is a diagram for explaining a contour line tracking process of an input pattern, FIG. 5 is a diagram for explaining an 8-direction code, and FIG. 6 is a pair flag setting process. Flow chart showing operation, No. 7
FIG. 8 is a circuit diagram showing a specific circuit of the state recognition unit, FIG. 8 is a diagram showing a tracking start point detection table, FIG. 9 is a diagram showing each point on the image memory corresponding to FIG. 8, and FIG. FIG. 11 is a block diagram showing an apparatus configuration of a conventional example, FIG. 11 is a diagram for explaining a contour tracking start point detecting process of the conventional example, and FIG. 12 is a flowchart showing the contour tracking process. 1 ... Image memory, 2 ... Scan circuit 3 ... Status recognition unit 4 ... Control ROM
───────────────────────────────────────────────────── フロントページの続き (72)発明者 宮宗 宏昭 京都府京都市右京区花園中御門町3番地 株式会社立石ライフサイエンス研究所内 (56)参考文献 特開 昭60−263276(JP,A) ─────────────────────────────────────────────────── ─── Continuation of the front page (72) Inventor Hiroaki Miyamune, Tateishi Life Science Institute, No. 3 Nakamimon-cho, Hanazono, Ukyo-ku, Kyoto City, Kyoto Prefecture (56) References JP-A-60-263276 (JP, A)
Claims (1)
追跡する輪郭追跡手段を備えた画像処理装置において、 前記入力パターンを構成する2値画像データと、前記輪
郭追跡手段による輪郭追跡処理時に設定される追跡処理
データとして入力パターンの輪郭構成画素に設定される
輪郭フラグおよび次の輪郭構成画素への追跡方向に応じ
て設定されるペアフラグとを、各画素毎に記憶すること
が可能な画像メモリと、 前記画像メモリを所定方向へ走査して各画素を順次アク
セスする走査手段と、 前記走査手段によりアクセスされた各画素の2値画像デ
ータおよび前記追跡処理データを取り込んでアクセス対
象画素が輪郭追跡処理済の入力パターンの内外いずれに
位置するかを認識する認識手段と、 前記認識手段による認識結果に基づきアクセス対象画素
を輪郭追跡処理の開始点として検出するかどうかを決定
する輪郭追跡開始点検出手段とを備えて成る画像処理装
置。1. An image processing apparatus comprising contour tracing means for tracing contour lines of a black and white binarized input pattern, wherein binary image data constituting the input pattern and contour tracing processing by the contour tracing means. It is possible to store, for each pixel, the contour flag set in the contour constituent pixels of the input pattern and the pair flag set according to the tracing direction to the next contour constituent pixel as the tracking processing data which is set at any time. An image memory, a scanning unit that scans the image memory in a predetermined direction to sequentially access each pixel, a binary image data of each pixel accessed by the scanning unit and the tracking processing data are fetched, and an access target pixel is Recognizing means for recognizing the position inside or outside the input pattern for which the contour tracking processing has been performed, and the access means based on the recognition result by the recognizing means An image processing apparatus comprising: a contour tracking start point detecting means for deciding whether or not to detect a target pixel as a start point of contour tracking processing.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP59197945A JPH067389B2 (en) | 1984-09-20 | 1984-09-20 | Image processing device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP59197945A JPH067389B2 (en) | 1984-09-20 | 1984-09-20 | Image processing device |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPS6175485A JPS6175485A (en) | 1986-04-17 |
| JPH067389B2 true JPH067389B2 (en) | 1994-01-26 |
Family
ID=16382909
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP59197945A Expired - Lifetime JPH067389B2 (en) | 1984-09-20 | 1984-09-20 | Image processing device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH067389B2 (en) |
Family Cites Families (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPS60263276A (en) * | 1984-06-12 | 1985-12-26 | Nec Corp | Shape tracking system |
-
1984
- 1984-09-20 JP JP59197945A patent/JPH067389B2/en not_active Expired - Lifetime
Also Published As
| Publication number | Publication date |
|---|---|
| JPS6175485A (en) | 1986-04-17 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US5616905A (en) | Two-dimensional code recognition method | |
| JP3170299B2 (en) | Image reading processing device | |
| EP0173098A2 (en) | Pattern outline tracking method and apparatus | |
| JPH02277185A (en) | Extracting method for rectangle coordinates | |
| JPH0130180B2 (en) | ||
| JPH067389B2 (en) | Image processing device | |
| JPH04255080A (en) | image input device | |
| JP2933927B2 (en) | Pattern recognition method and information processing apparatus | |
| JP2882056B2 (en) | How to identify specific patterns | |
| JP2506071B2 (en) | Contour tracking device | |
| JP2646642B2 (en) | Image inside / outside area judgment system | |
| JPS589471B2 (en) | link link | |
| JPH06187450A (en) | Pattern recognition method and recognition device | |
| JPS6249482A (en) | Image preprocessing device | |
| JPH0762873B2 (en) | Contour tracking device | |
| JPH05197808A (en) | Method and device for generation of image contour line vector | |
| JPH01201788A (en) | Character reading method | |
| JPH0224782A (en) | Change detecting system of result image in logical filter processing of binary image | |
| JPH0685186B2 (en) | Photo area identification device | |
| JPH0115109B2 (en) | ||
| JPH057751B2 (en) | ||
| JPH02231690A (en) | Linear picture recognizing method | |
| JPH04195274A (en) | Document terminal detecting method for optical character reader | |
| JPH0814825A (en) | Correction device for linear line detection | |
| JPS6279580A (en) | Image processing device |