JPH01129358A - Arithmetic unit for table numerical value - Google Patents

Arithmetic unit for table numerical value

Info

Publication number
JPH01129358A
JPH01129358A JP62287499A JP28749987A JPH01129358A JP H01129358 A JPH01129358 A JP H01129358A JP 62287499 A JP62287499 A JP 62287499A JP 28749987 A JP28749987 A JP 28749987A JP H01129358 A JPH01129358 A JP H01129358A
Authority
JP
Japan
Prior art keywords
vector
frame
image
point
rectangular
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
JP62287499A
Other languages
Japanese (ja)
Inventor
Masami Ogawa
尾川 正見
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP62287499A priority Critical patent/JPH01129358A/en
Publication of JPH01129358A publication Critical patent/JPH01129358A/en
Priority to US08/047,354 priority patent/US5347598A/en
Pending legal-status Critical Current

Links

Landscapes

  • Processing Or Creating Images (AREA)
  • Document Processing Apparatus (AREA)

Abstract

PURPOSE:To automate an input and to prevent an input miss by recognizing the frame line of a primitive image as the gather of a rectangular frame, identifying the position relation between the rectangular frames and operating a numerical value in the rectangular frame based on this relation. CONSTITUTION:A user executes the rough sketch of the desired frame line on the paper of a notebook or a sheet paper, etc. This original is loaded on an image scanner 5 and an image input instruction is given from a keyboard 3 or a mouse 4 to a control part 1. According to a program stored in a program memory 9, a CPU circuit 8 sends an image scan instruction to the image scanner 5. The image scanner 5 reads picture information on the original from the sensor of a CCD, etc., and stores the image in an image memory 1. A table frame line is recognized from the primitive image to be digital-inputted and further, a cell number is added to frame data with using the information of the position relation. A character image in respective cells is recognized and the desired operation between cells is executed. Thus, the easy data input and operation processing of a high speed can be executed.

Description

【発明の詳細な説明】 [産業上の利用分野] 本発明は表敷値演算装置、特に原始画像の枠線内の数値
を認識し、数値間で所望の演算を行う表敷値演算装置に
関するものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a surface value calculation device, and particularly to a surface value calculation device that recognizes numerical values within a frame line of an original image and performs desired calculations between the numerical values. It is something.

[従来の技術] 従来、コンピュータ等の画像処理装置にデジタル画像を
人力する場合、所望の画像部分はペン。
[Prior Art] Conventionally, when manually inputting a digital image to an image processing device such as a computer, a desired image portion is captured using a pen.

タブレット等により指定して入力しなければならなかっ
た。このため、コンピュータによる表内の数値計算はす
べて手作業によってデータ入力が行われていた。また、
文字認識装置を使用して入力する場合も、各入力値と表
枠との対応を人手によって付けねばならなかった。
It was necessary to specify and input the information using a tablet, etc. For this reason, all numerical calculations in tables were performed by computer and data was entered manually. Also,
Even when inputting using a character recognition device, the correspondence between each input value and the table frame had to be manually established.

[発明が解決しようとする問題点コ 上記従来例では、使用者がマウス、ペンを使用して所望
の画像部分を指示するため、操作が繁雑で入力時間がか
かつていた。また、人によって入力誤差が生じ、正確な
画像を入力出来なかった。更に、入力ミスにより、作業
時間を大量に要するという欠点があった。
[Problems to be Solved by the Invention] In the conventional example described above, the user uses a mouse and a pen to indicate a desired image portion, which makes the operation complicated and takes a long input time. In addition, input errors occurred depending on the person, making it impossible to input accurate images. Furthermore, there is a drawback that a large amount of work time is required due to input errors.

本発明は、前記従来例の欠点を除去し、原始画像の表枠
を認識し、枠内の数値に所望の演算を行う表敷値演算装
置を提供する。
The present invention eliminates the drawbacks of the conventional example, and provides a surface value calculation device that recognizes the table frame of an original image and performs desired calculations on the numerical values within the frame.

[問題点を解決するための手段] この問題点を解決するための一手段として、本発明の表
敷値演算装置は、原始画像の枠線を矩形枠の集合として
認識する枠線認識手段と、前記矩形枠間の位置関係を識
別する位置関係識別手段と、前記矩形枠間の前記位置関
係に基づいて、矩形枠内の数値を演算する演算手段とを
備える。
[Means for Solving the Problem] As a means for solving this problem, the surface value calculation device of the present invention includes a frame line recognition means that recognizes the frame line of the original image as a set of rectangular frames. , a positional relationship identifying means for identifying the positional relationship between the rectangular frames, and a calculation means for calculating a numerical value within the rectangular frame based on the positional relationship between the rectangular frames.

[作用] かかる構成において、枠線認識手段に認識した矩形枠の
位置関係を位置関係識別手段で識別し、矩形枠の位置関
係に基づいて、矩形枠内の数値を演算をする。
[Operation] In this configuration, the positional relationship of the rectangular frames recognized by the frame line recognition unit is identified by the positional relationship identifying unit, and the numerical value within the rectangular frame is calculated based on the positional relationship of the rectangular frames.

−以下余白一 [実施例] 以下、添付図面を参照しつつ本発明に係る実施例の枠線
構成装置及び表敷値演算装置を詳細に説明する。
- Below is a margin 1 [Example] Hereinafter, a frame line configuring device and a cover value calculating device according to an embodiment of the present invention will be described in detail with reference to the accompanying drawings.

以下の実施例には、 (1)手書き人力された表をあられす画像から表を形成
する枠線を矩形枠の集合として認識し、枠線全体を直線
からなる表に仕上げるもの、(2)更に、矩形枠内の画
像を切り出すもの、(3)更に、矩形枠の行列を認識し
、枠内の数値を演算するものを順に説明する。
The following embodiments include: (1) A system that recognizes the frame lines forming a table from a hail image as a collection of rectangular frames and finishes the entire frame line into a table consisting of straight lines; (2) Furthermore, a method for cutting out an image within a rectangular frame, and (3) a method for recognizing a matrix of a rectangular frame and calculating numerical values within the frame will be explained in order.

第2図は実施例の枠線構成装置を含むグラフィックシス
テムの外観図で、1は制御部、2はCRT、3はキーボ
ード、4はマウスである。
FIG. 2 is an external view of a graphic system including a frame line configuring device according to an embodiment, in which 1 is a control unit, 2 is a CRT, 3 is a keyboard, and 4 is a mouse.

これらで所謂ワークステーションを構成している。また
、5は文書を操作して画像を入力するイメージスキャナ
、6はワークステーションで処理された画像を用紙にハ
ードコピーするイメージプリンタである。木枠線構成装
置においては、手書きの原始画像は原稿用紙等に書かれ
たものをイメージスキャナ5で読取るか、又はマウス4
によりCRTZ上に手書き画像を形成するようにしても
よい。要は手書き画像が何等かの形で、後述のイメージ
メモリ部10へ格納されればよい。
These constitute a so-called workstation. Further, 5 is an image scanner that inputs images by manipulating documents, and 6 is an image printer that hard copies images processed at the workstation onto paper. In the wooden frame line composing device, the handwritten original image is obtained by reading what is written on manuscript paper etc. with an image scanner 5 or by using a mouse 4.
Alternatively, a handwritten image may be formed on the CRTZ. The point is that the handwritten image may be stored in some form in the image memory section 10, which will be described later.

第1図は本実施例の枠線構成装置のハードウェア構成を
示すブロック図である。ワークステーションの制御部1
は、全体を制御するCPU回路8、枠線だ識するプログ
ラムを格納した例えばRAM等から成るプログラムメモ
リ部9と、デジタル画像を格納するイメージメモリ部1
0から構成される。
FIG. 1 is a block diagram showing the hardware configuration of the frame line configuring device of this embodiment. Workstation control unit 1
, a CPU circuit 8 that controls the entire system, a program memory section 9 consisting of a RAM, etc., which stores a program for recognizing frame lines, and an image memory section 1 that stores digital images.
Consists of 0.

第3図は枠線認識処理の流れの概念を示すフローチャー
トである。このフローチャートに従って、ステップ毎に
その細部を順に説明する。
FIG. 3 is a flowchart showing the concept of the flow of frame line recognition processing. Following this flowchart, the details of each step will be explained in order.

〈イメージ入力〉・・・ステップS31まず、使用者が
、ノートあるいはシート紙等の用紙上に、所望の枠線を
ラフスケッチする。
<Image input>...Step S31 First, the user roughly sketches a desired frame line on a paper such as a notebook or sheet paper.

第4図に手書きによる枠線が描かれたシートの一例を示
す。この原稿をイメージスキャナ5に乗せ、キーボード
3あるいはマウス4からイメージ入力命令を制御部1に
与えれる。すると、CPU回路8はプログラムメモリ部
9に格納されたプログラムに従い、イメージスキャナ5
に画像スキャン命令を送る。イメージスキャナ5は原稿
上の画像情報をCCD等のセンサから読み取り、イメー
ジメモリ部10に画像を格納する。
FIG. 4 shows an example of a sheet with handwritten frame lines. This document is placed on the image scanner 5, and an image input command is given to the control section 1 from the keyboard 3 or mouse 4. Then, the CPU circuit 8 operates the image scanner 5 according to the program stored in the program memory section 9.
Send an image scan command to. The image scanner 5 reads image information on a document from a sensor such as a CCD, and stores the image in an image memory section 10.

〈前処理〉・・・ステップS32 イメージスキャナ5より入力されたデジタル画像は、イ
メージメモリ部10上では第5図に示すマトリクス構造
を持つ。画像は、原稿の横方向(以後これをX方向とす
る)に最尤m個、原稿の縦方向(以後これをy方向とす
る)に最大n個の画像から構成されており、原稿の白、
黒に対応して各画素はそれぞれ°’o”、”t°′の値
を持つ。
<Preprocessing> Step S32 The digital image input from the image scanner 5 has a matrix structure shown in FIG. 5 on the image memory section 10. The image consists of a maximum of m images in the horizontal direction of the document (hereinafter referred to as the X direction) and a maximum of n images in the vertical direction of the document (hereinafter referred to as the y direction). ,
Corresponding to black, each pixel has a value of °'o" and "t°', respectively.

即ち、画素の座標値を、横方向にx=1.2゜・・・1
m、縦方向にy=1.2.・・・、nとした時、位置(
x、y)の画素の値p (x、y)は次の式%式% 手書きによって描かれた表枠は、P (x、y)=1で
ある画素の集合として表現されるのであるが、P (x
、y)=1である画素の列を追跡するための前処理とし
て、ノイズ除去及び細線化を行う。ノイズ除去は例えば
周知の平滑化等で可能である。又、細線化は例えば、位
数、連結度等を考慮して黒画素の縮退を行う等の周知の
技術を用いる事ができる。
In other words, the coordinate value of the pixel is x=1.2°...1 in the horizontal direction.
m, vertically y=1.2. ..., when n is the position (
The pixel value p (x, y) of pixel (x, y) is expressed by the following formula% A table frame drawn by hand is expressed as a set of pixels where P (x, y) = 1. , P (x
, y)=1, noise removal and line thinning are performed as preprocessing for tracking the pixel column where ,y)=1. Noise can be removed by, for example, well-known smoothing. Further, for thinning, for example, a well-known technique such as degenerating black pixels in consideration of order, degree of connectivity, etc. can be used.

このノイズ除去及び細線化が終了すると、手書きの表枠
は幅1の連続点の集合となる。例えば第4図の手書き入
力の枠線の内、枠線部分61の近傍の線及びその周辺の
白部分60を第6図に示す。第6図で、論理値“0”の
画素が白部で、“1”の画像が黒部である。
When this noise removal and line thinning are completed, the handwritten table frame becomes a set of continuous points with a width of 1. For example, in the frame line for handwritten input in FIG. 4, a line near the frame line portion 61 and a white portion 60 around it are shown in FIG. In FIG. 6, pixels with logical value "0" are white parts, and images with logical value "1" are black parts.

くベクトル化〉・・・ステップS33 こうして得られたデジタル画像の各画素P (1,1)
、 =−、P (x、 y)、 ・・・、 P (m。
Vectorization>...Step S33 Each pixel P (1, 1) of the digital image thus obtained
, =-, P (x, y), ..., P (m.

n)について黒画素を追跡することにより、ベクトル化
し、得られた座標を第9図に示した座標型ベクトルデー
タテーブル91に書き込む。
By tracing the black pixels with respect to n), vectorization is performed, and the obtained coordinates are written into the coordinate type vector data table 91 shown in FIG.

始点のx、X座標をそれぞれ始点X座標欄93゜始点y
座標欄94に、終点のx、X座標をそれぞれ終点X座標
欄95.終点y座標欄96に記入していく。ラスクイメ
ージを、端点、折れ点。
Enter the x and X coordinates of the starting point in the starting point x coordinate field 93° starting point y.
In the coordinate field 94, enter the x and X coordinates of the end point in the end point X coordinate field 95. Fill in the end point y-coordinate column 96. Rusk image, end points, fold points.

交差点1分岐点等の特徴点を始点および終点にもつベク
トルデータに変換する手法は、公知の技術であるので、
ここには述べない。
The method of converting a feature point such as a branch point of an intersection into vector data having a starting point and an ending point is a well-known technique, so
I won't mention it here.

ベクトルデータVは、第7図に示す様に、始点座標Px
  (Xi 、ys )および終点座標P。
As shown in FIG. 7, the vector data V is the starting point coordinate Px
(Xi, ys) and end point coordinates P.

(xa 、 3’a )から成る。添え字Sは5tar
tの頭文字、添え字eはendの頭文字である。
It consists of (xa, 3'a). Subscript S is 5tar
The first letter of t and the subscript e are the first letters of end.

座標型ベクトルテーブル91のベクトルは番号92は、
各ベクトル1つ1つに与えられる通し番号で、V、、V
2.・・・、VIllと与えられる。
The vector number 92 in the coordinate type vector table 91 is
A serial number given to each vector one by one, V, ,V
2. ..., is given as VIll.

ここではベクトルの総数となる。Here it is the total number of vectors.

座標型ベクトルテーブル91の角度θ97は、各ベクト
ルの傾きを示す角度で、ベクトルの始点と終点の座標値
より、次の式で求めることができる。即ち、 X、−X。
The angle θ97 of the coordinate type vector table 91 is an angle indicating the inclination of each vector, and can be determined from the coordinate values of the starting point and ending point of the vector using the following equation. That is, X, -X.

π (Xs ” Xi、’/e> ys) π −(Xs = X13’e < Vg)エラー    
  (x、=x□y@=ys)こうして求めた各ベクト
ルの傾きθ97を、座標型ベクトルテーブル91に書き
込んでいく。
π (Xs ” Xi, '/e> ys) π - (Xs = X13'e < Vg) error
(x,=x□y@=ys) The inclination θ97 of each vector thus obtained is written into the coordinate type vector table 91.

第9図ではθの単位をdegreeにしている。In FIG. 9, the unit of θ is degree.

第4図の原画像を人力した場合は、第8図の様にベクト
ル化される。座標値は適当に定められている。第9図の
座標型ベクトルテーブル中の数値は、第8図の例であり
、ベクトルの総数mは■1〜V13で13個である。
When the original image in FIG. 4 is manually created, it is vectorized as shown in FIG. The coordinate values are appropriately determined. The numerical values in the coordinate type vector table of FIG. 9 are the example of FIG. 8, and the total number m of vectors is 13 (1 to V13).

なお、以降の処理のために、垂直ベクトルはX座標の小
さい方の点を始点とし、垂直ベクトル以外のベクトルは
、X座標の小さい方の点を始点として座標型ベクトルテ
ーブル91に書き込んでいく。垂直ベクトルの判定は後
述する第20図に示されたアルゴリズムにより行う。
Note that for subsequent processing, vertical vectors are written in the coordinate-type vector table 91 with the point with the smaller X coordinate as the starting point, and vectors other than the vertical vectors are written in the coordinate type vector table 91 with the point with the smaller X coordinate as the starting point. The vertical vector is determined by an algorithm shown in FIG. 20, which will be described later.

く関係テーブル生成〉・・・ステップS34関係テーブ
ル生成は、ステップ333で得られた枠線画像の座標型
ベクトルデータ91を基に、ベクトルと点と座標の関係
をテーブルにした3個のデータテーブル、即ち、第10
図(a)の点型ベクトルテーブル101と、第10図(
b)の点データテーブル105と、第10図(c)のベ
クトルリストテーブル110とを生成する処理である。
Generation of relationship tables>... Step S34 generates relationship tables, based on the coordinate type vector data 91 of the frame line image obtained in step 333, three data tables are created that are tables of relationships between vectors, points, and coordinates. , that is, the 10th
The point vector table 101 in Figure (a) and Figure 10 (
This process generates the point data table 105 in b) and the vector list table 110 in FIG. 10(c).

点型ベクトルテーブル101は、座標型ベクトルテーブ
ル91と異なり、ベクトルを始点及び終点の点番号10
3,104で表す。また点データテーブル105は、各
点番号の点のX。
Point-type vector table 101 differs from coordinate-type vector table 91 in that point-type vector table 101 is different from coordinate-type vector table 91.
It is expressed as 3,104. In addition, the point data table 105 shows the point X of each point number.

y座標値107,108を示している。ベクトルリスト
テーブル110は、それぞれの点に接続している全ての
ベクトルをリスト構造で格納している。
The y coordinate values 107 and 108 are shown. The vector list table 110 stores all vectors connected to each point in a list structure.

第10図(a)〜(C)に示す第8図の例では、点デー
タはP1〜P9の9個、ベクトルリストはり、〜L21
1の26個になる。
In the example of FIG. 8 shown in FIGS. 10(a) to (C), there are nine point data P1 to P9, a vector list, to L21
There will be 26 pieces of 1.

まず、第11図に示すフローチャートに従って、座標型
ベクトルテーブル91から、点型ベクトルテーブル10
1と点データテーブル105を求めるアルゴリズムを説
明する。ステップ5110でカウンタ1=09点の総数
n=oに初期化し、ステップ5111で座標型ベクトル
テーブル91中のベクトル番号Vlのベクトルについて
、始点、終点の座標を得る。ステップ5112で始点が
点データテーブル105に登録済みか否かをチエツクす
る。ベクトル番号v1の場合は、始点(xs 、 ys
 )は未だ点データテーブル105に登録されていない
ので、ステップ5113に進んで点番号P1の点として
登録し、点の総数nを1増加させる。そしてステップ5
115で、この点番号P1を点型ベクトルテーブル10
1からの始点欄103に追加する。
First, according to the flowchart shown in FIG.
1 and the algorithm for determining the point data table 105 will be explained. In step 5110, the counter 1 is initialized to the total number n=o of 09 points, and in step 5111, the coordinates of the start point and end point of the vector with vector number Vl in the coordinate type vector table 91 are obtained. In step 5112, it is checked whether the starting point has been registered in the point data table 105. In the case of vector number v1, the starting point (xs, ys
) has not yet been registered in the point data table 105, the process advances to step 5113, where it is registered as a point with point number P1, and the total number n of points is incremented by 1. and step 5
115, this point number P1 is stored in the point type vector table 10.
1 to the starting point column 103.

次に終点(xe、ya)についてステップ8116〜5
119で同様の処理を行う。終点(Xs−ya)は番号
P2の点として登録し、点の総数nを1増加させる。ス
テップ5120でiを+1して、ステップ5121でi
>mすなわち全ベクトルについて処理したかをチエツク
し、まだの場合はステップ5111に戻って、ステップ
5111〜5121を繰り返す。こうして、各ベクトル
Vl  (i=1〜13)について以上の処理を行う。
Next, steps 8116 to 5 for the end point (xe, ya)
Similar processing is performed in step 119. The end point (Xs-ya) is registered as a point with number P2, and the total number of points n is increased by one. In step 5120, i is incremented by 1, and in step 5121, i is
>m, that is, whether all vectors have been processed. If not, return to step 5111 and repeat steps 5111 to 5121. In this way, the above processing is performed for each vector Vl (i=1 to 13).

ベクトルV3の始点のように既に点が点データテーブル
105に登録されている場合は、ステップ5114ある
いはステップ5118でこの点番号P1を読み出し、点
型ベクトルテーブル101の始点欄103あるいは終点
欄104に書き込むだけで良い。第10図(a)、(b
)の点型ベクトルテーブル101及び点データテーブル
105に書き込まれた数値は、第8図の枠線例の場合で
ある。
If a point is already registered in the point data table 105, such as the starting point of vector V3, this point number P1 is read out in step 5114 or step 5118 and written in the starting point column 103 or ending point column 104 of the point type vector table 101. Just that is fine. Figure 10(a),(b)
) are written in the point type vector table 101 and the point data table 105 for the frame line example in FIG.

次に、点型ベクトルテーブル101と点データテーブル
105より、ベクトルリストテーブル110を求めるア
ルゴリズムを第12図のフローチャートに従って説明す
る。
Next, an algorithm for obtaining the vector list table 110 from the point type vector table 101 and the point data table 105 will be explained according to the flowchart of FIG.

全ての点データPJ  (j=1〜n)について、本例
ではn=9、次の処理を行う。まず、ステップ5130
でカウンタj=1に初期化し、ステップ5131で点P
Jを始点あるいは終点にもつベクトルを点型ベクトルテ
ーブル101より求める。もし上の条件を満たすベクト
ルがあれば、ステップ5132でベクトルリスト番号L
lをベクトルリストテーブル110のベクトルリスト番
号欄111に、ベクトル番号をベクトル番号欄112に
登録する。ステップ5133では次の接続ベクトルがあ
るか否かをチエツクし、もしあればステップ5134で
ベクトルリストテーブル110のNEXT欄113に、
次のベクトルリスト番号を記入する。もし、他の接続ベ
クトルがなければステップ5135でφを記入する。
For all point data PJ (j=1 to n), n=9 in this example, and the following processing is performed. First, step 5130
The counter is initialized to j=1 in step 5131, and the point P is set in step 5131.
A vector having J as the starting point or ending point is found from the point type vector table 101. If there is a vector that satisfies the above conditions, in step 5132 the vector list number L
1 is registered in the vector list number column 111 of the vector list table 110, and the vector number is registered in the vector number column 112. In step 5133, it is checked whether there is the next connection vector, and if there is, in step 5134, it is entered in the NEXT column 113 of the vector list table 110.
Enter the next vector list number. If there is no other connection vector, φ is entered in step 5135.

ステップ5136でjを+1して、ステップ5137で
j>nすなわち全点の処理が終了したかをチエツクし、
j>nでない場合はステップ5131に戻って、ステッ
プ8131〜ステツプ5137を繰り返す。例えば、第
8図の場合には、点P1に接続するベクトルはV + 
、 Vl 。
In step 5136, j is incremented by 1, and in step 5137, it is checked whether j>n, that is, all points have been processed.
If j>n is not satisfied, the process returns to step 5131 and steps 8131 to 5137 are repeated. For example, in the case of FIG. 8, the vector connected to point P1 is V +
, Vl.

■4となる。■It becomes 4.

く枠線抽出〉・・・ステップ335 第9図の座標型ベクトルテーブル91゜第10図(a)
〜(C)の点型ベクトルテーブル101、点データテー
ブル105.ベクトルリストテーブル110より枠線デ
ータを抽出するアルゴリズムを説明する。
Frame line extraction>...Step 335 Coordinate type vector table 91° in Fig. 9 Fig. 10 (a)
~(C) Point type vector table 101, point data table 105. An algorithm for extracting frame line data from the vector list table 110 will be explained.

枠線は、単数あるいは複数の矩形枠データの集合である
ので、各矩形成分をなすベクトル集合を第13図の矩形
枠ベクトルテーブル130の形態で求める。矩形枠ベク
トルテーブル130は、それぞれの枠番号W1〜W1に
ついて、枠の上側ベクトル132.左側ベクトル133
.右側ベクトル134.下側ベクトル135からなる。
Since a frame line is a set of single or plural rectangular frame data, a vector set forming each rectangular component is determined in the form of a rectangular frame vector table 130 in FIG. 13. The rectangular frame vector table 130 includes upper frame vectors 132 . left vector 133
.. Right vector 134. It consists of a lower vector 135.

さらに、斜め線を含んだ枠の場合には、右下斜めベクト
ル136.右上斜めベクトル137が加わる。
Furthermore, in the case of a frame including a diagonal line, the lower right diagonal vector 136. An upper right diagonal vector 137 is added.

第16図(a)、(ti)のフローチャートを用いて、
矩形枠ベクトルテーブル130を求めるアルゴリズムを
説明する。
Using the flowcharts in FIGS. 16(a) and (ti),
An algorithm for obtaining the rectangular frame vector table 130 will be explained.

ステップ5160でカウンタi=1に初期化する。ステ
ップ5161で座標型ベクトルテーブル91からベクト
ルV1  (i=t〜m)が水平ベクトルであるかどう
か調べる。水平ベクトル判定のアルゴリズムを、第19
図のフローチャートに示す。ステップ5190で角度θ
盛の絶対値1θ1が所定のしきい値θ、より小さいか否
かをチエツクし、小さい場合はステップS19,1でベ
クトルV1を水平ベクトルであると判定する。なお、θ
、は5°〜10°程度に決めれば良い。
In step 5160, the counter is initialized to i=1. In step 5161, it is checked from the coordinate type vector table 91 whether the vector V1 (i=t to m) is a horizontal vector. The algorithm for horizontal vector determination is described in the 19th
This is shown in the flowchart in Figure. In step 5190, the angle θ
It is checked whether the absolute value 1θ1 of the height is smaller than a predetermined threshold value θ, and if it is smaller, the vector V1 is determined to be a horizontal vector in step S19,1. In addition, θ
, may be set to about 5° to 10°.

Vlが水平ベクトルであるならば、ステップ3161a
で上側ベクトル欄132にベクトル番号V1を記入し、
次にステップ5162でその■1の始点を始点として接
続する垂直ベクトルがあるかどうか調べる。第17図に
始点側の垂直ベクトルの検索のアルゴリズムを表わすフ
ローチャートを示す。ステップ5175で、ベクトルリ
ストテーブル110より、始点に接続しているベクトル
を求める。ステップ5176でそのベクトルが垂直ベク
トルか否か、ステップ5177で注目している点がその
垂直ベクトルの始点か否かをチエツクし、注目している
点を始点とする垂直ベクトルの場合は、ステップ517
8でこのベクトルを求める垂直ベクトルとする。ステッ
プ5179で注目している点を共有する全ベクトルを点
検したかをチエツクし、まだの場合はステップ5175
に戻って、ステップ8175〜5179を繰り返す。
If Vl is a horizontal vector, step 3161a
Enter the vector number V1 in the upper vector column 132,
Next, in step 5162, it is checked whether there is a vertical vector connecting the starting point of 1 to the starting point. FIG. 17 shows a flowchart representing the algorithm for searching the vertical vector on the starting point side. In step 5175, vectors connected to the starting point are found from the vector list table 110. In step 5176, it is checked whether the vector is a vertical vector, and in step 5177, it is checked whether the point of interest is the starting point of the vertical vector. If the point of interest is a vertical vector starting from the point of interest, step 517
8. Let this vector be the perpendicular vector to be found. Check whether all vectors that share the point of interest have been checked in step 5179, and if not, step 5175
Return to and repeat steps 8175 to 5179.

ここで、垂直ベクトル判定を第20図のフローチャート
に従って説明する。ステップ5200でベクトル■1の
角度θ1の絶対値1θ11が所定のしぎい値θ、より大
きいか否かをチエツクし、大きければ、ステップ520
1でこのベクトルVIを垂直ベクトルとする。尚、θ、
4は80°〜85°程度にすればよい。
Here, vertical vector determination will be explained according to the flowchart of FIG. 20. In step 5200, it is checked whether the absolute value 1θ11 of the angle θ1 of vector 1 is larger than a predetermined threshold value θ, and if it is, step 520
1 makes this vector VI a vertical vector. Furthermore, θ,
4 may be approximately 80° to 85°.

もし、始点側に垂直ベクトルがあれば、ステップ516
3で矩形枠ベクトルテーブルの左側ベクトル欄133に
、そのベクトル番号を記入する。
If there is a vertical vector on the starting point side, step 516
3, enter the vector number in the left vector column 133 of the rectangular frame vector table.

次に、ステップ5164で終点側について調べる。第1
8図に終点側の垂直ベクトルの検索のアルゴリズムを表
わすフローチャートを示す。
Next, in step 5164, the end point side is examined. 1st
FIG. 8 shows a flowchart representing the algorithm for searching the vertical vector on the end point side.

ステップ5180で、ベクトルリストテーブルより、終
点に接続しているベクトルを求める。
In step 5180, vectors connected to the end point are determined from the vector list table.

ステップ5181でそのベクトルが垂直ベクトルか否か
、ステップ3182で注目している点がその垂直ベクト
ルの始点か否かをチエツクし、注目している点を始点と
する垂直ベクトルの場合は、ステップ5183でこのベ
クトルを求める垂直ベクトルとする。ステップ5184
でン主目している点を共有する全ベクトルを点検したか
をチエツクし、まだの場合はステップ3180に戻って
、ステップ5180〜3184を繰り返す。
In step 5181, it is checked whether the vector is a vertical vector, and in step 3182, it is checked whether the point of interest is the starting point of the vertical vector. If the point of interest is a vertical vector starting from the point of interest, step 5183 is checked. Let this vector be the perpendicular vector to be found. Step 5184
Check whether all vectors that share the point of interest have been checked, and if not, return to step 3180 and repeat steps 5180 to 3184.

もし、終点側に垂直ベクトルがあれば、ステップ516
5で、矩形枠ベクトルテーブルの右側ベクトル欄134
に、そのベクトル番号を記入する。
If there is a vertical vector on the end point side, step 516
5, the right vector column 134 of the rectangular frame vector table
Enter the vector number in .

左側ベクトルと右側ベクトルが求められたなら、ステッ
プ5166で、左側ベクトルの終点と右側ベクトルの終
点を両端点に持つベクトルを点型ベクトルテーブル10
5より探索し、もし存在すれば、ステップ5167でそ
のベクトル番号を矩形枠ベクトルテーブル130の下側
ベクトル欄135に記入する。
Once the left vector and right vector have been determined, in step 5166, a vector whose end points are the end point of the left vector and the end point of the right vector is stored in the point vector table 10.
If the vector exists, the vector number is entered in the lower vector column 135 of the rectangular frame vector table 130 in step 5167.

次に、斜め線について探索する。ステップ8168で左
側ベクトルの始点と右側ベクトルの終点を両端点に持つ
ベクトルを点型ベクトルテーブル105より探索し、も
し存在すれば、ステップ5169でそのベクトル番号を
右下斜めベクトル欄136に記入する。同様に、ステッ
プ5170で、左側ベクトルの終点と右側ベクトルの始
点とを両端点に持つベクトルを点型ベクトルテーブルよ
り探索し、もし存在すれば、ステップ5171でそのベ
クトル番号を右上斜めベクトル欄137に記入する。
Next, let's explore diagonal lines. In step 8168, the point-type vector table 105 is searched for a vector whose end points are the start point of the left vector and the end point of the right vector, and if it exists, the vector number is entered in the lower right diagonal vector field 136 in step 5169. Similarly, in step 5170, the point type vector table is searched for a vector whose end points are the end point of the left vector and the start point of the right vector, and if it exists, the vector number is entered in the upper right diagonal vector field 137 in step 5171. Fill out.

以上のように、少なくとも上・下・左・右側のベクトル
の存在するものを、ステップ5172で矩形枠として矩
形枠番号W1131を登録する。
As described above, in step 5172, the rectangular frame number W1131 is registered as a rectangular frame for a frame in which at least the upper, lower, left, and right vectors exist.

次にステップ5173でiに+1し、ステップ5174
でi>mすなわち全ベクトルを処理したかをチエツクし
、まだの場合はステップ5161に戻ってステップ51
61〜5174を繰り返す。
Next, in step 5173, add 1 to i, and in step 5174
Check whether i>m, that is, all vectors have been processed, and if not, return to step 5161 and proceed to step 51.
Repeat steps 61-5174.

以上の処理を繰り返せば、矩形枠ベクトルテーブル13
0が得られる。尚、ステップ5161でベクトル■、が
水平ベクトルでない場合、あるいはステップ5162,
5164,5166で左・右・下側のベクトルのない場
合は、ステップ5172に進んで、次のベクトルをチエ
ツクする。
By repeating the above process, the rectangular frame vector table 13
0 is obtained. Note that if the vector ■ is not a horizontal vector in step 5161, or if the vector
If there are no left, right, or lower vectors in steps 5164 and 5166, the process advances to step 5172 and checks the next vector.

次に、矩形枠ベクトルテーブル130のままでは、枠線
を再構成しにくいので、各矩形枠を座標データとサイズ
データと種類とで表現し直す。
Next, since it is difficult to reconstruct the frame lines using the rectangular frame vector table 130 as is, each rectangular frame is reexpressed using coordinate data, size data, and type.

即ち、第14図に示すように、左上端の点のX座標14
2.X座標143.枠幅w144゜枠高h 145 、
 fffl類kind146の5つのパラメータで表さ
れた枠テーブル140を求める。枠の種類は、第15図
に示す4つのうちいずれかを表し、それぞれK。、に、
、に2゜K3の値で区別する。
That is, as shown in FIG. 14, the X coordinate 14 of the upper left point
2. X coordinate 143. Frame width w 144° Frame height h 145,
A frame table 140 expressed by five parameters of fffl class kind 146 is obtained. The type of frame represents one of the four types shown in Fig. 15, each of which is K. , to,
, are distinguished by the value of 2°K3.

値K。は斜め線のない枠150、 値に、は左斜め線のみ持つ枠151、 値に2は右上斜め線のみ持つ枠152、値に3は右下斜
め線及び右上斜め線のみ持つ枠153を表すものとする
Value K. The value represents a frame 150 without a diagonal line, the value represents a frame 151 with only a left diagonal line, the value 2 represents a frame 152 with only an upper right diagonal line, and the value 3 represents a frame 153 with only a lower right diagonal line and an upper right diagonal line. shall be taken as a thing.

座標x、y、幅W、高さhは次の式で求まる。The coordinates x, y, width W, and height h are determined by the following formula.

x = (VIIP、)x 、 y= (Vl]Pi)
yw −(VIIP s) x−(VLIP−) Xh
 == (VLEFTa)y−(VLEFT、)y但し
、(VUP、)Xは上側ベクトルの始点のX座標(VL
IPjyは上側ベクトルの始点のX座標(VtlPe)
xは上側ベクトルの終点のX座標(VLEFTa) y
は左側ベクトルの終点のX座標(VLEFT、lアは左
側ベクトルの始点のX座標である。
x = (VIIP,)x, y= (Vl]Pi)
yw −(VIIPs) x−(VLIP−) Xh
== (VLEFTa)y - (VLEFT,)y However, (VUP,)X is the X coordinate of the starting point of the upper vector (VL
IPjy is the X coordinate of the starting point of the upper vector (VtlPe)
x is the X coordinate of the end point of the upper vector (VLEFTa) y
is the X coordinate of the end point of the left vector (VLEFT), and 1a is the X coordinate of the start point of the left vector.

枠の種類kindは、右下斜めベクトル、右上斜めベク
トルの存在より、第21図に示すフローチャートのよう
に決定すれば良い。第21図のステップ5210は右下
斜ベクトルの存否を、ステップ5211,5212は右
上斜ベクトルの存否をチエツクする。その組み合わせか
ら、ステップ5213では種別をに3に、ステップ52
14では種別をに1に、ステップ5215では種別をに
2に、ステップ5216では種別をに0にする。ステッ
プ5217では全矩形枠の処理がおわったかをチエツク
し、まだの場合はステップ5210に戻ってステップ8
210〜5217を繰り返す。
The frame type kind may be determined based on the presence of the lower right diagonal vector and the upper right diagonal vector as shown in the flowchart shown in FIG. Step 5210 in FIG. 21 checks whether there is a lower right diagonal vector, and steps 5211 and 5212 check whether there is an upper right diagonal vector. From that combination, step 5213 sets the type to 3, step 52
In step 14, the type is set to 1, in step 5215, the type is set to 2, and in step 5216, the type is set to 0. In step 5217, it is checked whether all rectangular frames have been processed, and if not, the process returns to step 5210 and step 8
Repeat steps 210-5217.

く枠線の構成〉・・・ステップ33に うして得られた枠テーブル140に基づいて、プリンタ
出力やフロッピ出力等を行えば、手書きで等で人力され
た枠線を直線で再構成できる。
Frame line configuration> If output to a printer or floppy disk is performed based on the frame table 140 obtained in step 33, the frame lines manually drawn by hand or the like can be reconstructed as straight lines.

前記実施例では、水平ベクトルに着目して枠線データを
求めたが、アルゴリズム中の水平ベクトルと垂直ベクト
ルを置き換えて、垂直ベクトルに着目したアルゴリズム
でも同様に枠線データを求めることができる。
In the embodiment described above, the frame line data was obtained by focusing on the horizontal vector, but the frame line data can be similarly obtained using an algorithm that focuses on the vertical vector by replacing the horizontal vector and the vertical vector in the algorithm.

以上説明したように、 入力原画像中の枠線画素をベクトル化して得たベクトル
集合の中から、矩形をなすベクトル群を選出し、これを
枠線データとする方法で、複雑な構造を持つ枠線を認識
することが可能となった。
As explained above, by selecting a rectangular vector group from the vector set obtained by vectorizing the frame line pixels in the input original image and using this as frame line data, it is possible to create a complex structure. It is now possible to recognize frame lines.

次に、前述の枠線抽出法を応用して、枠線内の画像の切
り出しを行う例を第23図、第24図。
Next, FIGS. 23 and 24 show an example of cutting out an image within a frame line by applying the above-described frame line extraction method.

第25図を用いて説明する。This will be explained using FIG. 25.

第23図には第1図にCPU回路8とデータのやり取り
を行う補助記憶部11が更に追加されている。第24図
のフローチャートにおいて、ステップ531〜535は
第3図と同じであり、第3図のステップS35の次にス
テップS36の代わりに、ステップ536aが追加され
る。
In FIG. 23, an auxiliary storage section 11 for exchanging data with the CPU circuit 8 is further added to FIG. 1. In the flowchart of FIG. 24, steps 531 to 535 are the same as in FIG. 3, and step 536a is added next to step S35 in FIG. 3 instead of step S36.

く画像切り出し〉・・・ステップ36aステツプ536
aでは、切り出した画像を補助記憶部11に格納する。
Image extraction> Step 36a Step 536
In step a, the cut out image is stored in the auxiliary storage section 11.

枠線抽出で得られた枠テーブル140に基づいた画像の
切り出しを、第25図のフローチャートに従って説明す
る。
Image cutting based on the frame table 140 obtained by frame line extraction will be explained with reference to the flowchart of FIG. 25.

まず、ステップ5250で枠テーブル140の金枠の左
上端座標データX1,3’+及びWl。
First, in step 5250, the upper left coordinate data X1, 3'+ and Wl of the gold frame of the frame table 140 are obtained.

高さり、の値から、枠線の座標を求める。ステップ52
51でイメージメモリ部10に格納されているデジタル
画像データの内、この枠線に囲まれる矩形画像データ部
をCPU回路8に読み出す。
Find the coordinates of the frame line from the height value. Step 52
At 51, a rectangular image data section surrounded by this frame line is read out to the CPU circuit 8 from among the digital image data stored in the image memory section 10.

ここで前述したような斜め線を含む枠線に対応する画像
を読み出さないようにしても良い。
Here, the image corresponding to the frame line including the diagonal line as described above may not be read out.

入力者への確認のために、ステップ5252で切り出し
た矩形画像データ部をCRTデイスプレィ2に表示し、
ステップ5253で切り出すか否かをチエツクする。そ
して、切り出す場合はステップ5254で、この矩形画
像データ部を補助記憶部11(例えばフロッピーディス
ク。
The rectangular image data section cut out in step 5252 is displayed on the CRT display 2 for confirmation by the inputter.
In step 5253, it is checked whether to cut out or not. When cutting out, in step 5254, this rectangular image data section is stored in the auxiliary storage section 11 (for example, a floppy disk).

光メモリ等)へ転送して格納する。ステップ5255で
は全矩形枠を処理したかをチエツクし、まだの場合はス
テップ5250に戻ってステップ3250〜5255を
繰り返す。
(optical memory, etc.) and store it. In step 5255, it is checked whether all rectangular frames have been processed. If not, the process returns to step 5250 and steps 3250 to 5255 are repeated.

必要に応じで、キーボードマウス3.4から指示を与え
て、CPU回路8により画像データをCRTデイスプレ
ィ2に表示したり、プリンタ部6に出力することができ
る。
If necessary, image data can be displayed on the CRT display 2 or output to the printer section 6 by the CPU circuit 8 by giving instructions from the keyboard and mouse 3.4.

本画像の切り出しにより、入力された原始画像を加工し
て直線からなる表枠線を生成し、この表枠線を境界とす
る矩形領域を抽出することにより、人の介在なく枠線内
の画像を切り出して画像処理部に入力することができる
By cutting out the main image, the input original image is processed to generate a table frame line made of straight lines, and by extracting a rectangular area with this table frame line as a boundary, the image within the frame line can be processed without human intervention. can be cut out and input to the image processing section.

次に、前述の矩形枠内の画像の切り出しを応用した特徴
的な一実施例、枠内の数値の演算例を第26図を用いて
説明する。木表数値演算装置は第23図の構成であるが
、補助記憶部11内に後述するセルテーブル290と文
字コードテーブル300とを備える。
Next, a characteristic example in which the above-mentioned cutting out of an image within a rectangular frame is applied, and an example of calculation of numerical values within the frame will be described with reference to FIG. The tree table numerical calculation device has the configuration shown in FIG. 23, and is provided with a cell table 290 and a character code table 300, which will be described later, in the auxiliary storage section 11.

第26図は本例の枠内の数値の演算処理手順を示すフロ
ーチャートである。ここでステップS31〜S35まで
は第3図と同様である。ステップ336の代わりにステ
ップ536bが付加され、以後ステップS37〜S39
と続く。
FIG. 26 is a flowchart showing the calculation processing procedure for numerical values within the frame in this example. Here, steps S31 to S35 are the same as in FIG. 3. Step 536b is added instead of step 336, and thereafter steps S37 to S39
It continues.

くセル番号付け〉・・・ステップ536bステツプS3
1〜S35において、矩形枠による抽出処理が終ると、
次にステップ536bで枠データの1つ1つにセル番号
を付加する。
Cell numbering>...Step 536b Step S3
1 to S35, when the extraction process using the rectangular frame is finished,
Next, in step 536b, a cell number is added to each piece of frame data.

第27図に本例の入力画像を示す。第27図は横5×縦
3の表枠であり、図に示す様に各セルはセル番号C1,
I 、 C1,2、・・・CI、5 、C2,+ +・
・・、 C3,5である。ここで、C1,lは、前述し
たように斜め線を含んだ枠線である。尚、C,、、でX
は行番号、yは列番号を表す。
FIG. 27 shows the input image of this example. Figure 27 shows a table frame of 5 width x 3 height, and as shown in the figure, each cell has cell number C1,
I, C1,2,...CI,5, C2,+ +・
..., C3,5. Here, C1,l is a frame line including diagonal lines as described above. In addition, C, , X
represents the row number, and y represents the column number.

第26図のステップ536bのセル番号付処理のアルゴ
リズムを第28図のフローチャートに示す。まず、ステ
ップ8280で、各矩形枠データを、矩形枠の左上点の
X座標について昇順にソーティングして並べ変える。ソ
ーティングされた矩形枠データはy1≦y2≦・・・≦
ylllの順となっている。mは枠線の総数である。次
にステップ3281で制御変数に=1.j=1.i=1
の初期化をする。
The algorithm for the cell numbering process in step 536b of FIG. 26 is shown in the flowchart of FIG. First, in step 8280, each rectangular frame data is sorted and rearranged in ascending order with respect to the X coordinate of the upper left point of the rectangular frame. The sorted rectangular frame data is y1≦y2≦...≦
The order is yllll. m is the total number of frame lines. Next, in step 3281, the control variable is set to =1. j=1. i=1
Initialize.

ステップ5282で、各矩形枠データのyl。At step 5282, yl of each rectangular frame data.

y2.・・・、y、に対しyl、1−yIを計算して、
εと比較する。εは予め設定されたしきい値であるが、
枠の幅や高さより小さい値で、3mm〜5mmに相当す
る画素数にすれば良い。例えば1mmあたり8画素のデ
ジタル画像に対しては5X8=40とする。
y2. ..., calculate yl, 1-yI for y,
Compare with ε. ε is a preset threshold,
The number of pixels may be set to a value smaller than the width and height of the frame, which corresponds to 3 mm to 5 mm. For example, for a digital image with 8 pixels per mm, 5×8=40.

もし、y+++−3’+がしきい値よりも大きければ、
i+1番目の枠な次の行の枠であるとみなし、ステップ
3283に進んで、j番目からi番目までの枠をそれぞ
れCk、l 、Ck、2 +  +Ck、 +1−Jや
、)とする。こうして得られた同じ行の枠を、今度はス
テップ5284でX座標について昇順にソートする。あ
らためて、ソートされた順に、Ck、I 、  Ck、
2 、・・・、Ck、+1−J。1.とする。
If y+++-3'+ is greater than the threshold,
It is assumed that the i+1th frame is the frame of the next row, and the process proceeds to step 3283, where the jth to ith frames are respectively set as Ck, l, Ck, 2++Ck, +1-J, etc.). The thus obtained frames in the same row are then sorted in ascending order with respect to the X coordinate in step 5284. Again, in the sorted order, Ck, I, Ck,
2,..., Ck, +1-J. 1. shall be.

ステップ5285では、制御変数に、j、iに+1して
、ステップ3282に戻り、次の行についての処理を行
う。
In step 5285, the control variables j and i are incremented by 1, and the process returns to step 3282 to process the next row.

ステップ5282でy+++−yiがしきい値以下なら
ば、ステップ5286でiに+1して、ステップ828
7で全矩形枠の処理を終了したかをチエツクし、まだな
らばステップ3282に戻り、次の矩形枠をチエツクす
る。全矩形枠の処理が終ると、次に比較する枠はないの
で、ステップ3288.5289でステップ3283.
284と同じ処理を行いリターンする。
If y+++-yi is less than or equal to the threshold value in step 5282, i is incremented by 1 in step 5286, and step 828
At step 7, it is checked whether all rectangular frames have been processed, and if not, the process returns to step 3282 and the next rectangular frame is checked. Once all the rectangular frames have been processed, there is no frame to compare next, so step 3288.5289 is followed by step 3283.
It performs the same processing as 284 and returns.

〈演算数値入力〉・・・ステップS37セル番号付けの
結果のセルテーブル290を第29図に示す。枠番号2
91どセル番号292との対応を示すセルテーブル29
0が得られる。
<Arithmetic numerical value input>...A cell table 290 resulting from cell numbering in step S37 is shown in FIG. Frame number 2
91 cell table 29 showing correspondence with cell number 292
0 is obtained.

このテーブルからセル番号x、yに対応する枠番号iを
求めることができ、さらに、第14図の枠テーブル14
0よりセル内の文字画像領域の座標値が算出でき、原画
像から文字画像領域を切出すことができる。複数の文字
列を含む文字画像から一文字一文字を切出して認識する
手法は公知の技術なので、ここでは述べない。文字認識
後得られた数値文字データは第30図に示すセル301
と文字コード302との対応を示す文字コードテーブル
300に格納される。
From this table, the frame number i corresponding to the cell numbers x and y can be obtained, and furthermore, the frame number i corresponding to the cell numbers
The coordinate values of the character image area within the cell can be calculated from 0, and the character image area can be cut out from the original image. Since the method of extracting and recognizing each character from a character image containing a plurality of character strings is a well-known technique, it will not be described here. The numerical character data obtained after character recognition is stored in cell 301 shown in Figure 30.
and a character code 302 are stored in a character code table 300 showing the correspondence between the character code 302 and the character code 302.

ユーザは、キー、マウス等の入力装置により、セル間の
演算式を人力する。例えばキーボードからa + b 
+ c + dと人力する。
The user manually inputs calculation formulas between cells using input devices such as keys and a mouse. For example, a + b from the keyboard
+ c + d manually.

く演算処理〉・・・ステツブS38 第27図の例の場合には、文字コードテーブル300よ
り、10+20+30+40”及び”5+10+15+
20”が計算される。
Calculation processing>...Step S38 In the case of the example shown in FIG. 27, from the character code table 300, 10+20+30+40" and
20” is calculated.

〈演算結果出力〉・・・ステップS39結果ノ” 10
0 ”及び5o″がCRTデイスプレィ2上に表示、あ
るいはプリンタ部6に記録される。尚、演算結果の出力
は、入力された表の同じ行の空白部でもよいし、枠を追
加して出力してもよい。
<Computation result output>...Step S39 result no" 10
0" and 5o" are displayed on the CRT display 2 or recorded on the printer section 6. Note that the output of the calculation result may be a blank space in the same row of the input table, or may be output by adding a frame.

本実施例によれば、デジタル入力された原始画像より表
枠線を認識し、さらに枠データにその位置関係情報を用
いてセル番号を付加し、各セル内の文字画像を認識し、
所望のセル間演算を行うことにより、簡便で高速なデー
タ入力及び演算処理を可能となる。
According to this embodiment, table frame lines are recognized from a digitally input original image, cell numbers are added to the frame data using the positional relationship information, character images in each cell are recognized,
By performing desired inter-cell calculations, it becomes possible to perform simple and high-speed data input and calculation processing.

[発明の効果コ 本発明により、原始画像の表枠を認識し、枠内の数値に
所望の演算を行う表敷値演算装置を提供できる。
[Effects of the Invention] According to the present invention, it is possible to provide a front value calculation device that recognizes the front frame of an original image and performs desired calculations on the numerical values within the frame.

【図面の簡単な説明】[Brief explanation of the drawing]

第1図は実施例の枠線構成装置のブロック構成図、 第2図は実施例の枠線構成装置をグラフィック処理シス
テムとしたときの外観斜視図、第3図は実施例における
枠線構成の処理手順の概略を示すフローチャート、 第4図は枠線画像の一例を示す図、 第5図はイメージメモリ内の空間を示す図、第6図はイ
メージメモリに格納された画像データを示す図、 第7図はベクトル各部の名称を説明する図、第8図はベ
クトル化された枠線画像を示す図、第9図は座標型ベク
トルデータを格納する座標型ベクトルテーブルを示す図
、 第10図(a)は点型ベクトルを格納する点型ベクトル
テーブルを示す図、 第10図(b)は点座標を格納する点データテーブルを
示す図、 第10図(C)はある点に接続しているベクトルのリス
トを格納するベクトルリストテーブルを示す図、 第11図は座標型ベクトルテーブルから点型ベクトルテ
ーブル及び点データテーブルを作成するアルゴリズムを
示すフローチャート、第12図はベクトルリストテーブ
ルを作成するアルゴリズムを示すフローチャート、 第13図は矩形枠ベクトルテーブルを示す図、第14図
は枠テーブルを示す図、 第15図は枠の種類を示す図、 第16図(a)、(b)は矩形枠ベクトルテーブルを作
成するアルゴリズムを示すフローチャート、 第17図は始点側の垂直ベクトルを追跡するサブルーチ
ンを示すフローチャート、 第18図は終点側の垂直ベクトルを追跡するサブルーチ
ンを示すフローチャート、 第19図は水平ベクトル判定のアルゴリズムを示すフロ
ーチャート、 第20図は垂直ベクトル判定のアルゴリズムを示すフロ
ーチャート、 第21図は枠の種類を判別するアルゴリズムを示すフロ
ーチャート、 第22図は枠間隔の狭い枠線画像の一例を示す図、 第23図は実施例の枠内の画像の切り出し及び表の数値
を演算する装置の構成図、 第24図は実施例における枠内の画像の切り出しの、処
理手順の概略を示すフローチャート、第25図は枠内の
画像の切り出しのアルゴリズムを示すフローチャート 第26図は実施例における表の数値の演算の処理手順の
概略を示すフローチャート、第27図は演算数値を記入
した表の例を示す図、 第28図はセルテーブル作成のアルゴリズムを示すフロ
ーチャート、 第29図はセルテーブルを示す図、 第30図は文字コードテーブルを示す図である。 図中、1・・・制御部、2・・・CRT、3・・・キー
ボード、4・・・マウス、5・・・イメージイスキャナ
、6・・・イメージプリンタ、8・・・CPU回路、9
・・・プログラムメモリ部、10・・・イメージメモリ
部、11・・・補助記憶部である。 第1図 @3図 y 第7図 第8図 第4図 第6図 第5図 第9図 (C) 第10図 第17図 娃 第18図 第19図 第20図 第22図 第23図 第24図 第26図 第27図 第29図 第30図
FIG. 1 is a block configuration diagram of the frame line configuration device of the embodiment, FIG. 2 is an external perspective view when the frame line configuration device of the embodiment is used as a graphic processing system, and FIG. 3 is a block diagram of the frame line configuration device of the embodiment. A flowchart showing an outline of the processing procedure; FIG. 4 is a diagram showing an example of a frame line image; FIG. 5 is a diagram showing a space in the image memory; FIG. 6 is a diagram showing image data stored in the image memory; Figure 7 is a diagram explaining the names of each part of the vector, Figure 8 is a diagram showing a vectorized frame line image, Figure 9 is a diagram showing a coordinate type vector table that stores coordinate type vector data, and Figure 10. (a) is a diagram showing a point type vector table that stores point type vectors, Figure 10 (b) is a diagram showing a point data table that stores point coordinates, and Figure 10 (C) is a diagram showing a point data table that stores point coordinates. Figure 11 is a flowchart showing an algorithm for creating a point-type vector table and point data table from a coordinate-type vector table, and Figure 12 is an algorithm for creating a vector list table. FIG. 13 is a diagram showing a rectangular frame vector table, FIG. 14 is a diagram showing a frame table, FIG. 15 is a diagram showing types of frames, and FIGS. 16 (a) and (b) are rectangular frames. A flowchart showing an algorithm for creating a vector table, Fig. 17 a flowchart showing a subroutine for tracking vertical vectors on the starting point side, Fig. 18 a flowchart showing a subroutine for tracking vertical vectors on an endpoint side, and Fig. 19 a flowchart showing a subroutine for tracking vertical vectors on the endpoint side. FIG. 20 is a flowchart showing the algorithm for determining vertical vectors. FIG. 21 is a flowchart showing the algorithm for determining the type of frame. FIG. 22 is an example of a frame line image with narrow frame intervals. 23 is a block diagram of a device for cutting out images within the frame and calculating numerical values in the table in the embodiment; FIG. 24 is a flowchart showing an outline of the processing procedure for cutting out the image within the frame in the embodiment; Fig. 25 is a flowchart showing the algorithm for cutting out the image within the frame. Fig. 26 is a flowchart showing an outline of the processing procedure for calculating numerical values in a table in the embodiment. Fig. 27 shows an example of a table in which calculated numerical values are entered. 28 is a flowchart showing an algorithm for creating a cell table, FIG. 29 is a diagram showing a cell table, and FIG. 30 is a diagram showing a character code table. In the figure, 1...Control unit, 2...CRT, 3...Keyboard, 4...Mouse, 5...Image scanner, 6...Image printer, 8...CPU circuit, 9
. . . program memory section, 10 . . . image memory section, 11 . . . auxiliary storage section. Figure 1 @ Figure 3y Figure 7 Figure 8 Figure 4 Figure 6 Figure 5 Figure 9 (C) Figure 10 Figure 17 Figure 18 Figure 19 Figure 20 Figure 22 Figure 23 Figure 24 Figure 26 Figure 27 Figure 29 Figure 30

Claims (5)

【特許請求の範囲】[Claims] (1)原始画像の枠線を矩形枠の集合として認識する枠
線認識手段と、 前記矩形枠間の位置関係を識別する位置関係識別手段と
、 前記矩形枠間の前記位置関係に基づいて、矩形枠内の数
値を演算する演算手段とを備えることを特徴とする表数
値演算装置。
(1) a frame line recognition means that recognizes the frame line of the original image as a set of rectangular frames; a positional relationship identification means that identifies the positional relationship between the rectangular frames; and based on the positional relationship between the rectangular frames, 1. A tabular numerical calculation device comprising: calculation means for calculating numerical values within a rectangular frame.
(2)枠線認識手段は、原始画像を端点、接点、交差点
、分岐点等の特徴点を始点および終点とするベクトル線
分集合に変換するベクトル化手段と、前記ベクトル線分
集合に属する各ベクトル線分間の接続関係に基づいて、
矩形をなすベクトル群を抽出する矩形抽出手段と備える
ことを特徴とする特許請求の範囲第1項記載の表数値演
算装置。
(2) The frame line recognition means includes a vectorization means for converting the original image into a set of vector line segments whose starting points and end points are feature points such as end points, contact points, intersections, and branching points, and each Based on the connection relationship between vector lines,
2. The table numerical calculation device according to claim 1, further comprising rectangle extraction means for extracting a group of vectors forming a rectangle.
(3)矩形抽出手段は、ベクトル線分の中から水平ベク
トルを検索する水平ベクトル検索手段と、該水平ベクト
ルに接続する垂直ベクトルを追跡する垂直ベクトル追跡
手段を備え、矩形をなすベクトル群を抽出することを特
徴とする特許請求の範囲第2項記載の表数値演算装置。
(3) The rectangle extraction means includes a horizontal vector search means for searching for a horizontal vector from a vector line segment, and a vertical vector tracking means for tracing a vertical vector connected to the horizontal vector, and extracts a group of vectors forming a rectangle. A table numerical calculation device according to claim 2, characterized in that:
(4)矩形抽出手段は、ベクトル線分の中から垂直ベク
トルを検索する垂直ベクトル検索手段と、該垂直ベクト
ルに接続する水平ベクトルを追跡する水平ベクトル追跡
手段を備え、矩形をなすベクトル群を抽出することを特
徴とする特許請求の範囲第2項記載の表数値演算装置。
(4) The rectangle extraction means includes a vertical vector search means for searching for a vertical vector from a vector line segment, and a horizontal vector tracking means for tracing a horizontal vector connected to the vertical vector, and extracts a group of vectors forming a rectangle. A table numerical calculation device according to claim 2, characterized in that:
(5)位置関係識別手段は、矩形枠の行を識別する行識
別手段と、矩形枠の列を識別する列識別手段とを備える
ことを特徴とした特許請求の範囲第1項記載の表数値演
算装置。
(5) The table numerical value set forth in claim 1, wherein the positional relationship identification means includes row identification means for identifying rows of the rectangular frame, and column identification means for identifying columns of the rectangular frame. Computing device.
JP62287499A 1987-03-20 1987-11-16 Arithmetic unit for table numerical value Pending JPH01129358A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP62287499A JPH01129358A (en) 1987-11-16 1987-11-16 Arithmetic unit for table numerical value
US08/047,354 US5347598A (en) 1987-03-20 1993-04-19 Image processing apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP62287499A JPH01129358A (en) 1987-11-16 1987-11-16 Arithmetic unit for table numerical value

Publications (1)

Publication Number Publication Date
JPH01129358A true JPH01129358A (en) 1989-05-22

Family

ID=17718135

Family Applications (1)

Application Number Title Priority Date Filing Date
JP62287499A Pending JPH01129358A (en) 1987-03-20 1987-11-16 Arithmetic unit for table numerical value

Country Status (1)

Country Link
JP (1) JPH01129358A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05342408A (en) * 1991-04-04 1993-12-24 Fuji Xerox Co Ltd Document image filing device
US5668892A (en) * 1992-10-27 1997-09-16 Fuji Xerox Co., Ltd. Table recognition apparatus
JP2007087238A (en) * 2005-09-26 2007-04-05 Fujitsu Ltd Data conversion program, method and device
JP2009108472A (en) * 2007-10-26 2009-05-21 Kunimoto Co Ltd Top end point
US9277074B2 (en) 2013-12-04 2016-03-01 Canon Kabushiki Kaisha Image processing apparatus, method, and medium determining whether image data of a page to be processed is blank and contains a foreground object and transmitting the foreground object obtained by removing a background object
US9412033B2 (en) 2012-04-12 2016-08-09 Canon Kabushiki Kaisha Image processing apparatus capable of preventing page missing, control method therefor, and storage medium

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH05342408A (en) * 1991-04-04 1993-12-24 Fuji Xerox Co Ltd Document image filing device
US5668892A (en) * 1992-10-27 1997-09-16 Fuji Xerox Co., Ltd. Table recognition apparatus
US5708730A (en) * 1992-10-27 1998-01-13 Fuji Xerox Co., Ltd. Table recognition apparatus
JP2007087238A (en) * 2005-09-26 2007-04-05 Fujitsu Ltd Data conversion program, method and device
JP2009108472A (en) * 2007-10-26 2009-05-21 Kunimoto Co Ltd Top end point
US9412033B2 (en) 2012-04-12 2016-08-09 Canon Kabushiki Kaisha Image processing apparatus capable of preventing page missing, control method therefor, and storage medium
US9277074B2 (en) 2013-12-04 2016-03-01 Canon Kabushiki Kaisha Image processing apparatus, method, and medium determining whether image data of a page to be processed is blank and contains a foreground object and transmitting the foreground object obtained by removing a background object

Similar Documents

Publication Publication Date Title
US6016148A (en) Automated mapping of facial images to animation wireframes topologies
US5048099A (en) Polygon-based method for automatic extraction of selected text in a digitized document
JP4757001B2 (en) Image processing apparatus and image processing method
CN114529925B (en) Method for identifying table structure of whole line table
US20020106124A1 (en) Block selection of table features
JP2761467B2 (en) Image segmentation device and character recognition device
JP4395188B2 (en) Document image recognition apparatus and storage medium for document image recognition program
JPS63206873A (en) Apparatus and method for vector conversion of input scan image data
JPH06301781A (en) Method and equipment for image transformation for pattern recognition by computer
CN114782974A (en) Table identification method, system, intelligent terminal and computer readable storage medium
CN114782645A (en) Virtual digital person making method, related equipment and readable storage medium
JPH01129358A (en) Arithmetic unit for table numerical value
JP3172498B2 (en) Image recognition feature value extraction method and apparatus, storage medium for storing image analysis program
JPH0646408B2 (en) Split image processing method
JPH01129369A (en) Frame line constituting device
JP2846486B2 (en) Image input device
JP3582734B2 (en) Table vectorizer
JP2803736B2 (en) Character recognition method
JP2755299B2 (en) Image processing method
JP2954218B2 (en) Image processing method and apparatus
Ouhyoung et al. A three-dimensional building authoring tool based on line drawing understanding
JPS622382A (en) Feature extracting devie for pattern
CN117275026A (en) Method for identifying investment amount form based on convolutional neural network
JPH0785255B2 (en) Character pattern shaping device
JP3182694B2 (en) Figure editing method and apparatus