JPS59114687A - Binary coding method of picture data - Google Patents

Binary coding method of picture data

Info

Publication number
JPS59114687A
JPS59114687A JP22431882A JP22431882A JPS59114687A JP S59114687 A JPS59114687 A JP S59114687A JP 22431882 A JP22431882 A JP 22431882A JP 22431882 A JP22431882 A JP 22431882A JP S59114687 A JPS59114687 A JP S59114687A
Authority
JP
Japan
Prior art keywords
point
image
threshold value
picture
threshold values
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.)
Granted
Application number
JP22431882A
Other languages
Japanese (ja)
Other versions
JPS6353584B2 (en
Inventor
Haruhiko Yokoyama
晴彦 横山
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP22431882A priority Critical patent/JPS59114687A/en
Publication of JPS59114687A publication Critical patent/JPS59114687A/en
Publication of JPS6353584B2 publication Critical patent/JPS6353584B2/ja
Granted legal-status Critical Current

Links

Landscapes

  • Image Processing (AREA)

Abstract

PURPOSE:To binary code a desired object and to discriminate the binary coded object from its periphery by setting a partial picture at a proper size. CONSTITUTION:The average of the picture data within a partial picture PKl is set at mKl and used as the threshold value at the center position qKl=(xK, yl) of PKl. The threshold values at the points other than {qKl; 1<=K<=m, 1<=l<= n} are decided as follows. That is, an optional point (i, j) on a picture included in P' is enclosed by four points forming an apex of a rectangle among {qKl} 1<=K<=m and 1<=l<=n. The threshold values ti and j at the point (i, j) are defined by an interpolation equation. A point (i', j') of P' closest to the point (i, j) is selected for the point (i, j) belonging to P'', and the threshold values ti' and j' of the point (i', j') obtained by an interpolation equation are defined as the threshold value tij of the (i, j). These threshold values thus obtained vary consecutively on a picture. The picture data value at the point (i, j) is defined as dij to obtain the binary picture data bij.

Description

【発明の詳細な説明】 産業上の利用分野 本発明は、画像の濃淡データ(以後画像データと略す)
を部分画像に分割し、各部分画像の画像データの平均値
から、補間式により各点におけるしきい値を決定して2
値化を行なう画像データの2値化方法に関するものであ
る。
[Detailed Description of the Invention] Industrial Application Field The present invention relates to image gradation data (hereinafter abbreviated as image data).
is divided into partial images, and the threshold value at each point is determined by an interpolation formula from the average value of the image data of each partial image.
The present invention relates to a method for binarizing image data.

従来例の構成とその問題点 従来例における、画像の2値化方法を以下に述べる。画
像データを、配列1di、+1≦i<A、1≦j≦8で
表わす。A、BはそれぞれX座標方向、y座標方向の画
像サイズである。しきい値の初期値t。
The structure of the conventional example and its problems The image binarization method in the conventional example will be described below. Image data is represented by an array 1di, +1≦i<A, 1≦j≦8. A and B are image sizes in the X and Y coordinate directions, respectively. Initial threshold value t.

と、0(k(1なる係数kを与えて、次の漸化式(1)
と(2)により、各点におけるしきい値+t、、+13
i<A、’+5;j≦Bを算出する。
and 0(k(1), giving the coefficient k, the following recurrence formula (1)
and (2), the threshold value at each point +t, , +13
i<A, '+5; Calculate j≦B.

画像データ(d・)としきい値(t、lより、(3)式
1] により、2値画像データib、、+1イiイA、1<j
鴇を求める。
Image data (d・) and threshold value (from t, l, (3) Equation 1), binary image data ib,,+1iiA,1<j
Seek the hawk.

ちなみに、水平方向の画像サイズB140とし、しきい
値の初期値t。を10、係数kを0.2とおいて、各点
のしきい値を求めた例を第1図に示した。
Incidentally, the horizontal image size is B140, and the initial value of the threshold value is t. FIG. 1 shows an example in which the threshold value for each point was determined by setting the coefficient k to 10 and the coefficient k to 0.2.

第1図の1は、水平な1ライン上の画像データ、第1図
の2は、上記方法で求めた同じライン上のしきい値から
得られた2値画像データをあられす。
1 in FIG. 1 is image data on one horizontal line, and 2 in FIG. 1 is binary image data obtained from the threshold value on the same line obtained by the above method.

この方法の欠点は、水平方向の画像データの変化はしき
い値に影響するのに、垂直方向の画像データの変化はし
きい値に影響しないので、垂直方向の明るさの変化をう
まく2値化できない場合があることである。
The disadvantage of this method is that changes in horizontal image data affect the threshold value, but changes in vertical image data do not affect the threshold value. There may be cases where it is not possible to do so.

発明の目的 本発明は、以上の欠点に鑑み、垂直方向の明るさの変化
を水平方向と同じようにう壕くとらえて2値化する画像
データの2値化方法を提供するものである。
OBJECTS OF THE INVENTION In view of the above-mentioned drawbacks, the present invention provides a method for binarizing image data, which captures and binarizes changes in brightness in the vertical direction in the same way as in the horizontal direction.

発明の構成 本発明は画像をn個の水平ラインとm個の垂直ラインに
よってm X n個の同じ大きさの部分画像に分割し、
部分画像の濃淡データの平均をその部分画像の中心点に
おける2値化しきい値とし、前記mxn個の部分画像の
m X n個の中心点におけるしきい値を定め、つぎに
それらの点のうち長方形の頂点をなす位置にある隣接し
た4点01 * fI L(tl、r2L(N2.JI
L(+2.J2)  (tl<12++1<+2)にお
ける前記方法によって定まった2値化しきい値t11J
1・1山2・112j1・t12j2がら・この長方形
内部の任意の点(i、i)におけるしきい値ti+]を
補間式 %式% ) (1) により算出して、画像上の各点における2値化しきい値
を得、しかる後に画像上の各点で濃淡データ値と、上記
2値化しきい値を比較することにょって、2値画像デー
タを作成することによシ、求めたい対象を2値化して、
対象を周囲と区別することを容易にする。
Structure of the Invention The present invention divides an image into m×n partial images of the same size by n horizontal lines and m vertical lines,
The average of the grayscale data of a partial image is set as the binarization threshold at the center point of the partial image, the threshold value at the m x n center points of the m x n partial images is determined, and then among those points, Adjacent four points located at the vertices of the rectangle 01 * fI L(tl, r2L(N2.JI
Binarization threshold t11J determined by the above method at L(+2.J2) (tl<12++1<+2)
1, 1 mountain 2, 112j1, t12j2, threshold value ti+ at any point (i, i) inside this rectangle is calculated using the interpolation formula % formula % ) (1) By obtaining a binarization threshold value and then comparing the gradation data value at each point on the image with the above binarization threshold value, you can create binary image data. Binarize and
Make it easier to distinguish the object from its surroundings.

実施例の説明 以下本発明の実施例の画像の2値化方法を図面によシ説
明する。第3図は、AxBOサイズの画像である。これ
をm x n個の同じ大きさの部分画像Pklに分割す
る。(1≦に≦m、1≦l≦n)第4図は、各部分画像
Pklの中心位置qkl=(xk、yl) tv分布図
である。Pkl内の画像データの平均f rnk、gと
し、これをP kitの中心位置qk1= (xk、 
yl)におけるしきい値tXk、 7iとする。Iqk
l;1≦k<m、1≦l≦n)以外の点におけるしきい
値は以下のように決める。
DESCRIPTION OF EMBODIMENTS An image binarization method according to an embodiment of the present invention will be explained below with reference to the drawings. FIG. 3 is an image of AxBO size. This is divided into m x n partial images Pkl of the same size. (1≦≦m, 1≦l≦n) FIG. 4 is a distribution diagram of the center position qkl=(xk, yl) tv of each partial image Pkl. Let the average f rnk,g of the image data in Pkl be the center position of P kit qk1= (xk,
Let the threshold value tXk at yl) be 7i. Iqk
The threshold values at points other than l; 1≦k<m, 1≦l≦n are determined as follows.

第5図は、全体画像を、ql 11qm1 +qmn+
q1nの4点を順次結んでできる長方形yの領域と、そ
の外側の領域p //を図示したもの。P′に含捷れる
画像−Fの任意点(i、Dは、’ qM ’ 1 <k
<m、 1<71<Bのうち長方形の頂点をなすある4
点に囲まれる。即ち、X k’−1< X k+ s、
 、 71≦j≦”7+1が成立するようなに、7が存
在するN1j)を囲む4点は(xl(+3’k) r 
(xlc+Vk−1−1L(”k+1 tVk)l (
”k+117に+1 )である )。 (i+j)Kお
けるしきい値”yl を次の補間式(2)によって定め
る。
Figure 5 shows the entire image as ql 11qm1 +qmn+
A diagram showing the rectangular y area formed by sequentially connecting the four points of q1n and the area p // outside of the rectangular area. An arbitrary point of the image-F that is included in P' (i, D are 'qM' 1 < k
<m, 1<71<B, a certain 4 that forms the vertex of the rectangle
surrounded by points. That is, X k'-1 < X k+ s,
, 71≦j≦”7+1, the four points surrounding N1j) where 7 exists are (xl(+3'k) r
(xlc+Vk-1-1L("k+1 tVk)l (
The threshold value yl at (i+j)K is determined by the following interpolation formula (2).

tij””!”k+1 1)(y7+1  )戸txk
yf(”k+1−リ(j−y7) ・txk74(、+
(11()(y、、−2)・txh+yp<’ xh)
(j−5r7)・tX1+t 、7.g+t +/”k
+1−Xk)(y、+1−yl)     =−山−−
旧=−(5)((5)式は(1)式でxk=111xk
+1=12 、yl=i113’l+1=”2とおいた
ものと同一である。) P“に属する点(i、i)について(i、j)に最も近
いP′の点(z/、j/)をえらび、補間式(2)で得
られた(i′+]’)のしきい値1.. −/を(iI
+)のしき”  +] い値t とする。以上で得られたしきい値は、画1] 像上で連続的に変化する。点(i、i)における画像デ
ータ値をd・・とじ、(6)式により、2値画像デー1 りす、を求める。
tij””! ”k+1 1)(y7+1) doortxk
yf("k+1-ri(j-y7) ・txk74(,+
(11()(y,,-2)・txh+yp<'xh)
(j-5r7)・tX1+t, 7. g+t+/”k
+1-Xk) (y, +1-yl) =-Mountain--
Old = - (5) (Equation (5) is equation (1), xk = 111xk
+1=12, yl=i113'l+1="2.) For the point (i, i) belonging to P", the point of P' closest to (i, j) (z/, j/ ), and the threshold value 1. of (i'+]') obtained by interpolation formula (2). .. -/(iI
+) Threshold "+]" is set to a value t.The threshold value obtained above changes continuously on the image 1].The image data value at point (i, i) is divided by d... , (6), the binary image data 1 is determined.

発明の効果 以上、本発明によると、明暗の差の小さな画像や、照明
ムラのある画像に対しても、部分画像すイズを適当に設
定することによシ、求めたい対象を2値化して周囲と区
別することが容易になった。
In addition to the effects of the invention, according to the present invention, it is possible to binarize the target object by appropriately setting the partial image size even for images with small differences in brightness and uneven illumination. It became easier to distinguish it from its surroundings.

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

第1図は画像データと従来例の方法によって求めたしき
い値のグラフ、第2図は第1図のデータから得られた2
値画像データのグラフ、第3図は画像を部分画像への分
解方法の説明図、第4図は各部分画像の中心位置の分布
図、第5図は本発明の一実施例の2値化方法の説明図で
ある。 代理人の氏名 弁理士 中 尾 敏 男 ほか1名第1
Figure 1 is a graph of image data and threshold values obtained using the conventional method, and Figure 2 is a graph of threshold values obtained from the data in Figure 1.
Graph of value image data, Figure 3 is an explanatory diagram of a method of decomposing an image into partial images, Figure 4 is a distribution diagram of the center position of each partial image, and Figure 5 is a binarization diagram of an embodiment of the present invention. It is an explanatory diagram of a method. Name of agent: Patent attorney Toshio Nakao and 1 other person No. 1
figure

Claims (1)

【特許請求の範囲】 画像をn個の水平ラインとm個の垂直ラインによってm
 X n個の同じ大きさの部分画像に分割し、部分画像
の濃淡データの平均を、その部分画像の中心点における
2値化しきい値とし、前記m x n個の部分画像のm
 x n個の中心点におけるしきい値を定め、つぎにそ
れらの点のうち長方形の頂点をなす位置にある隣接した
4点(’1+]IL(11+]2)D2+ 11 L 
(12+ 12)(’1<12t 31<12)におけ
る前記方法によって定まった2値化しきい値ti1 j
l Iti1j2’  t2j11ti2j2から、こ
の長方形内部の任意の点(i、 i)におけるしきい値
ti、3 k補間式%式% (1) により算出して、画像上の各点における2値化しきい値
を得、しかる後に画像上の各点で濃淡データ値と、上記
2値化しきい値を比較することによって、2値画像デー
タを作成する画像データの2値化方法。
[Claims] An image is divided into m by n horizontal lines and m vertical lines.
Divide into X n partial images of the same size, set the average of the grayscale data of the partial images as the binarization threshold at the center point of the partial image, and set m of the m x n partial images.
x Define the threshold values at n center points, and then calculate the four adjacent points located at the vertices of the rectangle among those points ('1+] IL (11+] 2) D2+ 11 L
Binarization threshold value ti1 j determined by the above method in (12+12) ('1<12t 31<12)
From l Iti1j2' t2j11ti2j2, threshold value ti at any point (i, i) inside this rectangle, 3 k interpolation formula % Formula % (1) Calculate the binarization threshold value at each point on the image. A method for binarizing image data, in which binary image data is created by obtaining the gradation data value at each point on the image and then comparing the binarization threshold with the binarization threshold.
JP22431882A 1982-12-20 1982-12-20 Binary coding method of picture data Granted JPS59114687A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP22431882A JPS59114687A (en) 1982-12-20 1982-12-20 Binary coding method of picture data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP22431882A JPS59114687A (en) 1982-12-20 1982-12-20 Binary coding method of picture data

Publications (2)

Publication Number Publication Date
JPS59114687A true JPS59114687A (en) 1984-07-02
JPS6353584B2 JPS6353584B2 (en) 1988-10-24

Family

ID=16811866

Family Applications (1)

Application Number Title Priority Date Filing Date
JP22431882A Granted JPS59114687A (en) 1982-12-20 1982-12-20 Binary coding method of picture data

Country Status (1)

Country Link
JP (1) JPS59114687A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61194580A (en) * 1985-02-25 1986-08-28 Nippon Telegr & Teleph Corp <Ntt> Binary coding method for light and shade image
JP2009070387A (en) * 2007-09-12 2009-04-02 Core Logic Inc Video processing device, method, and recording medium thereof

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS61194580A (en) * 1985-02-25 1986-08-28 Nippon Telegr & Teleph Corp <Ntt> Binary coding method for light and shade image
JP2009070387A (en) * 2007-09-12 2009-04-02 Core Logic Inc Video processing device, method, and recording medium thereof

Also Published As

Publication number Publication date
JPS6353584B2 (en) 1988-10-24

Similar Documents

Publication Publication Date Title
JP3740065B2 (en) Object extraction device and method based on region feature value matching of region-divided video
US6556711B2 (en) Image processing apparatus and method
EP1274228A2 (en) Method for representing a digital color image using a set of palette colors based on detected important colors
JP3634266B2 (en) Color video processing method and apparatus
US7848567B2 (en) Determining regions of interest in synthetic images
JP2000181992A (en) Color document image recognition device
JP2002165105A (en) Image processing device, its method, and recording medium
JPS59114687A (en) Binary coding method of picture data
JP2003162719A (en) Detection of pattern in digital image
CN111091188B (en) Forward computing method and device for neural network and computer readable storage medium
US5778105A (en) Method of and apparatus for removing artifacts from a reproduction
CN1153470C (en) Static iamge generation method and device
JPH08137908A (en) Method and device for retrieving picture
Ablameyko et al. Vectorization and representation of large-size 2-D line-drawing images
Wang et al. Color image segmentation and understanding through connected components
JP3115725B2 (en) Extraction method of character string image from character string with background
JP3295561B2 (en) Image processing device
Barnsley Ergodic theory, fractal tops and colour stealing
JP2872241B2 (en) Image coding method
JPH10255036A (en) Dynamic binarizing method for gray level image
Meek et al. Several methods for representing discrete data by line segments
JPH0774966A (en) Picture processor
JP3998348B2 (en) Codebook creation method and apparatus for use in vector quantization, and recording medium
Zheng et al. An Overlapping NAM Segmentation Approach for Grayscale Images and Its Applications to Moment Calculation
JPH06105168A (en) Processing system for image data