KR20210005413A - Apparatus and method for subpixel line localization - Google Patents

Apparatus and method for subpixel line localization Download PDF

Info

Publication number
KR20210005413A
KR20210005413A KR1020190080859A KR20190080859A KR20210005413A KR 20210005413 A KR20210005413 A KR 20210005413A KR 1020190080859 A KR1020190080859 A KR 1020190080859A KR 20190080859 A KR20190080859 A KR 20190080859A KR 20210005413 A KR20210005413 A KR 20210005413A
Authority
KR
South Korea
Prior art keywords
line
gradient
subpixel
pixels
gradients
Prior art date
Application number
KR1020190080859A
Other languages
Korean (ko)
Other versions
KR102279177B1 (en
Inventor
서수영
Original Assignee
경북대학교 산학협력단
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 경북대학교 산학협력단 filed Critical 경북대학교 산학협력단
Priority to KR1020190080859A priority Critical patent/KR102279177B1/en
Publication of KR20210005413A publication Critical patent/KR20210005413A/en
Application granted granted Critical
Publication of KR102279177B1 publication Critical patent/KR102279177B1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/70Determining position or orientation of objects or cameras
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/10Segmentation; Edge detection
    • G06T7/11Region-based segmentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/60Analysis of geometric attributes

Abstract

Disclosed are an apparatus and a method for determining subpixel line positions, capable of efficiently determining positions of line points corresponding to a line from positions of line pixels determined at a pixel level related to the line on an image, and a recording medium. The method for determining subpixel line positions according to an embodiment of the present invention is a method for determining subpixel line positions which determines positions of line points corresponding to lines from positions of line pixels determined at pixel levels related to the lines on an image comprising: a step of calculating gradients related to pixel value differences between adjacent pixels with respect to pixels including line pixels and peripheral pixels adjacent to the line pixels using a gradient calculation part; a step of calculating gradient magnitudes of the pixels and regularizing the gradients of the pixels based on the gradient magnitudes of the pixels to calculate subpixel level displacements with respect to the positions of the line pixels using a regularizing part; and a step of determining the positions of the line points at subpixel levels based on the positions of the line pixels and the subpixel level displacements using the subpixel line position determining part.

Description

서브픽셀 라인위치 결정 장치 및 방법{APPARATUS AND METHOD FOR SUBPIXEL LINE LOCALIZATION}Apparatus and method for determining sub-pixel line positioning {APPARATUS AND METHOD FOR SUBPIXEL LINE LOCALIZATION}

본 발명은 서브픽셀 라인위치 결정 장치 및 방법에 관한 것으로, 보다 상세하게는 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 상기 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 결정하는 서브픽셀 라인위치 결정 장치 및 방법에 관한 것이다.The present invention relates to an apparatus and method for determining a subpixel line position, and more particularly, to a subpixel level determining a position of a line point corresponding to the line from a position of a line pixel determined as a pixel level related to a line in an image. It relates to an apparatus and method for determining pixel line position.

영상 처리 용어 중 라인(line)은 양측의 주변 보다 밝거나 어두운 밝기를 가지고 기하학적으로 가늘고 긴 모양을 가지는 부분을 의미한다. 실내 영상화, 건물 외관 영상화, 위성 영상화, 의료 영상화, 및 도로 영상화를 포함한 다양한 영상화 기술에서 가장 중요하고 빈번하게 관찰되는 특징들 중 하나로서, 라인 특징이 영상에서 장면(scene)을 분석하고 해석하는데 사용된다. 따라서, 영상 처리 및 컴퓨터 비전 분야에서 정확한 라인 추출이 중요하다.In image processing terms, a line refers to a portion having a geometrically elongated shape with a brightness that is brighter or darker than the surroundings of both sides. As one of the most important and frequently observed features in various imaging technologies including indoor imaging, building exterior imaging, satellite imaging, medical imaging, and road imaging, line features are used to analyze and interpret scenes in images. do. Therefore, accurate line extraction is important in the field of image processing and computer vision.

최근, 자율 주행을 위한 차선 추출, 의료 영상에서 혈관 추출, 및 위성 영상에서 도로 추출을 포함한 다양한 응용분야의 발전에 따라, 영상으로부터 라인 특징의 효율적 추출에 대한 요구가 급속도로 증가하고 있다. 선형 특징들의 위치를 고품질로 결정하기 위해, 선형 특징들의 위치를 서브픽셀 수준으로 결정할 필요가 있다. Steger는 표면 밝기(surface intensity)의 테일러 급수 근사법(TA; Taylor series Approximation)과 헤시안 행렬(Hessian matrix)에서 파생된 법선 벡터(normal vector)를 기반으로 하는 서브픽셀 라인 위치 결정 방법을 제안하였다. 그러나, 이 방법은 약한 라인 신호와 높은 노이즈 수준 하에서 선형 특징들의 위치가 불안정하게 결정되는 문제가 있다. 또한, Steger가 제안한 방법은 현재의 라인 확산 방향의 부근에 있는 3개의 픽셀들 내에 있는 위치들 만을 확인하여 위치들을 연결하므로, 라인 특징들이 높은 곡률을 가지는 경우에 라인 위치들을 제대로 연결하지 못하게 되는 문제가 있다.Recently, with the development of various application fields including lane extraction for autonomous driving, blood vessel extraction from medical images, and road extraction from satellite images, demand for efficient extraction of line features from images is rapidly increasing. In order to determine the location of the linear features with high quality, it is necessary to determine the location of the linear features at the subpixel level. Steger proposed a method for determining subpixel line positioning based on a Taylor series Approximation (TA) of surface intensity and a normal vector derived from a Hessian matrix. However, this method has a problem in that the positions of linear features are determined unstable under a weak line signal and a high noise level. In addition, the method proposed by Steger checks only the positions within the three pixels in the vicinity of the current line diffusion direction and connects the positions, so when the line features have high curvature, the line positions cannot be properly connected. There is.

C. Steger, "An unbiased detector of curvilinear structures", IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 20, no. 2, pp. 113-125, 1998.C. Steger, "An unbiased detector of curvilinear structures", IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 20, no. 2, pp. 113-125, 1998.

본 발명은 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 효율적으로 결정할 수 있는 서브픽셀 라인위치 결정 장치 및 방법, 기록 매체를 제공하기 위한 것이다.The present invention provides a subpixel line positioning apparatus and method capable of efficiently determining a position of a line point corresponding to a line at a subpixel level from a position of a line pixel determined at a pixel level related to a line in an image, and a recording medium. will be.

또한, 본 발명은 직진성(straightness)과 전방위성(omni-directionality)을 갖도록 라인점들을 연결하여 라인을 생성할 수 있는 서브픽셀 라인위치 결정 장치 및 방법, 기록 매체를 제공하기 위한 것이다.In addition, the present invention is to provide a subpixel line positioning apparatus and method, and a recording medium capable of generating a line by connecting line points so as to have straightness and omni-directionality.

또한, 본 발명은 라인 특징들이 높은 곡률을 가지는 경우에도 라인점들을 정확하게 연결하여 영상에서 라인들을 고품질로 추출할 수 있는 서브픽셀 라인위치 결정 장치 및 방법, 기록 매체를 제공하기 위한 것이다.In addition, the present invention is to provide a subpixel line positioning apparatus and method, and a recording medium capable of accurately connecting line points and extracting lines from an image with high quality even when line features have a high curvature.

또한, 본 발명은 적은 연산 처리량으로, 고속으로 고품질의 라인들을 추출할 수 있는 서브픽셀 라인위치 결정 장치 및 방법, 기록 매체를 제공하기 위한 것이다.Further, the present invention is to provide a subpixel line positioning apparatus and method, and a recording medium capable of extracting high-quality lines at high speed with a small computational throughput.

본 발명이 해결하고자 하는 과제는 이상에서 언급된 과제로 제한되지 않는다. 언급되지 않은 다른 기술적 과제들은 이하의 기재로부터 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 명확하게 이해될 수 있을 것이다.The problem to be solved by the present invention is not limited to the problems mentioned above. Other technical problems that are not mentioned will be clearly understood by those of ordinary skill in the art from the following description.

본 발명의 일 측면에 따른 서브픽셀 라인위치 결정 방법은, 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 상기 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 결정하는 서브픽셀 라인위치 결정 방법으로서, 그래디언트 산출부에 의해, 상기 라인픽셀 및 상기 라인픽셀에 인접한 주변픽셀들을 포함하는 픽셀들에 대해, 인접한 픽셀들 간의 픽셀값 차이와 관련된 그래디언트들을 산출하는 단계; 정규화부에 의해, 상기 픽셀들의 그래디언트들의 크기들을 산출하고, 상기 라인픽셀의 위치에 대한 서브픽셀 레벨 변위를 산출하기 위해 상기 픽셀들의 그래디언트들의 크기들을 기반으로 상기 픽셀들의 그래디언트들을 정규화하는 단계; 및 서브픽셀 라인위치 결정부에 의해, 상기 라인픽셀의 위치 및 상기 서브픽셀 레벨 변위를 기반으로 서브픽셀 레벨로 상기 라인점의 위치를 결정하는 단계를 포함한다.A method for determining a subpixel line position according to an aspect of the present invention includes determining a position of a line point corresponding to the line at a subpixel level from a position of a line pixel determined at a pixel level related to a line in an image. A method comprising: calculating, by a gradient calculator, gradients related to a pixel value difference between adjacent pixels for pixels including the line pixel and adjacent pixels adjacent to the line pixel; Normalizing, by a normalizing unit, the gradients of the pixels based on the sizes of the gradients of the pixels to calculate the sizes of the gradients of the pixels and calculate the subpixel level displacement with respect to the position of the line pixel; And determining, by the subpixel line position determining unit, the position of the line point at the subpixel level based on the position of the line pixel and the subpixel level displacement.

상기 라인점의 위치를 결정하는 단계는, 상기 라인픽셀의 위치와 상기 서브픽셀 레벨 변위를 합산하여 상기 라인점의 위치를 서브픽셀 레벨로 결정하는 단계를 포함할 수 있다.The determining of the position of the line point may include determining the position of the line point as a sub-pixel level by summing the position of the line pixel and the sub-pixel level displacement.

상기 픽셀들의 그래디언트들을 정규화하는 단계는, 그래디언트 합산부에 의해, 상기 픽셀들의 그래디언트들을 합산하여 합산 그래디언트를 산출하는 단계; 그래디언트 크기 산출부에 의해, 상기 픽셀들의 그래디언트들의 크기들을 산출하는 단계; 그래디언트 크기 합산부에 의해, 상기 픽셀들의 그래디언트들의 크기들을 합산하여 그래디언트 합산 크기를 산출하는 단계; 및 서브픽셀 변위 산출부에 의해, 상기 그래디언트 합산 크기에 의해 상기 합산 그래디언트를 정규화하여 상기 서브픽셀 레벨 변위를 산출하는 단계를 포함할 수 있다.Normalizing the gradients of the pixels may include calculating, by a gradient summing unit, a summed gradient by summing the gradients of the pixels; Calculating sizes of gradients of the pixels by a gradient size calculator; Calculating a summed gradient size by summing the sizes of the gradients of the pixels by a gradient size summation unit; And calculating the subpixel level displacement by normalizing the summed gradient by the summed gradient size by a subpixel displacement calculator.

본 발명에 따른 서브픽셀 라인위치 결정 방법은, 윈도우 설정부에 의해, 상기 영상에서 상기 라인픽셀의 위치로부터 상기 라인점의 위치를 결정하기 위한 픽셀들을 결정하는 단계를 더 포함할 수 있다. 상기 픽셀들을 결정하는 단계는 상기 라인픽셀을 중심으로 (2K + 1) × (2K + 1) 픽셀 크기(K는 양의 정수)를 가지는 윈도우를 설정하고, 상기 윈도우 내의 픽셀들을 결정하는 단계를 포함할 수 있다.The method for determining a line position of a subpixel according to the present invention may further include determining, by a window setting unit, pixels for determining the position of the line point from the position of the line pixel in the image. The determining of the pixels includes setting a window having a (2K + 1) × (2K + 1) pixel size (K is a positive integer) around the line pixel, and determining pixels within the window. can do.

상기 합산 그래디언트를 산출하는 단계는, 행 방향 그래디언트 합산부에 의해, 상기 픽셀들의 행 방향 그래디언트들을 합산하여 행 방향 합산 그래디언트를 산출하는 단계; 및 열 방향 그래디언트 합산부에 의해, 상기 픽셀들의 열 방향 그래디언트들을 합산하여 열 방향 합산 그래디언트를 산출하는 단계를 포함할 수 있다. 상기 그래디언트들의 크기들을 산출하는 단계는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 산출할 수 있다. 상기 그래디언트 합산 크기를 산출하는 단계는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 기반으로 상기 그래디언트 합산 크기를 산출할 수 있다. 상기 서브픽셀 레벨 변위를 산출하는 단계는, 행 방향 변위 산출부에 의해, 상기 행 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 행 방향 서브픽셀 레벨 변위를 산출하는 단계; 및 열 방향 변위 산출부에 의해, 상기 열 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 열 방향 서브픽셀 레벨 변위를 산출하는 단계를 포함할 수 있다. 상기 라인점의 위치를 결정하는 단계는, 상기 라인픽셀의 행 방향 위치와 상기 행 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 행 방향 위치를 서브픽셀 레벨로 결정하는 단계; 및 상기 라인픽셀의 열 방향 위치와 상기 열 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 열 방향 위치를 서브픽셀 레벨로 결정하는 단계를 포함할 수 있다.The calculating of the summed gradient may include calculating, by a row direction gradient summation unit, a row direction summed gradient by summing the row direction gradients of the pixels; And calculating a column direction sum gradient by summing the column direction gradients of the pixels by the column direction gradient summing unit. In the calculating of the sizes of the gradients, sizes of the row direction gradients and the sizes of the column direction gradients may be calculated. In the calculating of the summed gradient size, the summed gradient size may be calculated based on the sizes of the row direction gradients and the column direction gradients. The calculating of the subpixel level displacement may include calculating a row direction subpixel level displacement by dividing the row direction sum gradient by the gradient sum size by a row direction displacement calculator; And calculating a column direction subpixel level displacement by dividing the column direction sum gradient by the gradient sum size by a column direction displacement calculator. The determining of the position of the line point may include determining a row direction position of the line point as a subpixel level by summing the row direction position of the line pixel and the row direction subpixel level displacement; And determining the column direction position of the line point as a subpixel level by summing the column direction position of the line pixel and the column direction subpixel level displacement.

상기 픽셀들의 그래디언트들을 정규화하는 단계는, 상기 라인픽셀의 상태가 릿지(ridge)인 경우, 상기 그래디언트 합산 크기에 제1 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하는 단계; 및 상기 라인픽셀의 상태가 밸리(valley)인 경우, 상기 그래디언트 합산 크기에 상기 제1 부호와 상이한 제2 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하는 단계를 포함할 수 있다.The normalizing of the gradients of the pixels may include: when the line pixel is ridge, normalizing the gradients of the pixels by applying a first sign to the sum of the gradients; And when the state of the line pixel is a valley, applying a second sign different from the first sign to the sum of the gradients to normalize the gradients of the pixels.

상기 합산 그래디언트를 산출하는 단계는 하기의 수식 1에 따라 상기 행 방향 합산 그래디언트 및 상기 열 방향 합산 그래디언트를 산출할 수 있다. 상기 그래디언트 합산 크기를 산출하는 단계는 하기의 수식 2에 따라 상기 그래디언트 합산 크기를 산출할 수 있다. 상기 서브픽셀 레벨 변위를 산출하는 단계는 하기의 수식 3 및 수식 4에 따라 상기 서브픽셀 레벨 변위를 산출할 수 있다. 상기 라인점의 위치를 결정하는 단계는 하기의 수식 5에 따라 상기 라인점의 위치를 결정할 수 있다.In the calculating of the summed gradient, the summed row direction gradient and the summed column direction gradient may be calculated according to Equation 1 below. In the calculating of the summed gradient size, the summed gradient size may be calculated according to Equation 2 below. In the calculating of the subpixel level displacement, the subpixel level displacement may be calculated according to Equations 3 and 4 below. In determining the position of the line point, the position of the line point may be determined according to Equation 5 below.

[수식 1][Equation 1]

Figure pat00001
Figure pat00001

[수식 2][Equation 2]

Figure pat00002
Figure pat00002

[수식 3][Equation 3]

Figure pat00003
Figure pat00003

[수식 4][Equation 4]

Figure pat00004
Figure pat00004

[수식 5][Equation 5]

Figure pat00005
Figure pat00005

상기 수식 1 내지 수식 5에서,

Figure pat00006
는 상기 행 방향 합산 그래디언트,
Figure pat00007
는 상기 열 방향 합산 그래디언트,
Figure pat00008
는 행 방향 그래디언트,
Figure pat00009
는 열 방향 그래디언트,
Figure pat00010
는 상기 그래디언트 합산 크기,
Figure pat00011
는 상기 라인픽셀의 상태가 릿지인지 밸리인지를 나타내는 정보,
Figure pat00012
는 상기 행 방향 서브픽셀 레벨 변위,
Figure pat00013
는 상기 열 방향 서브픽셀 레벨 변위, c는 상기 라인픽셀의 열 방향 픽셀값, r은 상기 라인픽셀의 행 방향 픽셀값,
Figure pat00014
는 상기 라인점의 행 방향 위치,
Figure pat00015
는 상기 라인점의 열 방향 위치를 나타낸다.In Equations 1 to 5,
Figure pat00006
Is the sum gradient in the row direction,
Figure pat00007
Is the summation gradient in the column direction,
Figure pat00008
Is the row direction gradient,
Figure pat00009
Is the column direction gradient,
Figure pat00010
Is the sum of the gradients,
Figure pat00011
Is information indicating whether the state of the line pixel is ridge or valley,
Figure pat00012
Is the subpixel level displacement in the row direction,
Figure pat00013
Is the column direction subpixel level displacement, c is the column direction pixel value of the line pixel, r is the row direction pixel value of the line pixel,
Figure pat00014
Is the row direction position of the line point,
Figure pat00015
Represents the position of the line point in the column direction.

본 발명에 따른 서브픽셀 라인위치 결정 방법은, 라인 연결부에 의해, 상기 영상에서 라인을 생성하기 위해 상기 라인점들을 연결하는 단계를 더 포함할 수 있다. 상기 라인점들을 연결하는 단계는, 상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점들 간의 좌표 거리들, 그리고 상기 제1 라인점과 상기 제2 라인점들 간의 각도들을 기반으로 상기 제2 라인점들 중 상기 제1 라인점과 연결할 라인점을 결정할 수 있다.The method for determining a line position of a subpixel according to the present invention may further include connecting the line points to generate a line in the image by a line connector. The connecting of the line points may include coordinate distances between a first line point included in the line and second line points in the vicinity of the first line point among the line points, and the first line point and the A line point to be connected to the first line point among the second line points may be determined based on angles between the second line points.

상기 라인점들을 연결하는 단계는, 거리 산출부에 의해, 상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점 간의 좌표 거리를 산출하는 단계; 각도 산출부에 의해, 상기 제1 라인점에서의 상기 라인의 제1 각도를 산출하고, 상기 제1 라인점과 상기 제2 라인점 간의 제2 각도를 산출하는 단계; 각도차 산출부에 의해, 상기 제1 각도와 상기 제2 각도 간의 각도차를 산출하는 단계; 연결거리 산출부에 의해, 상기 좌표 거리 및 상기 각도차를 기반으로 상기 제1 라인점과 상기 제2 라인점 간의 연결거리를 산출하는 단계; 및 라인점 결정부에 의해, 상기 제2 라인점들 중 상기 제1 라인점과 가장 연결거리가 작은 라인점을 결정하여 상기 제1 라인점과 연결하는 단계를 포함할 수 있다.The connecting of the line points may include calculating a coordinate distance between a first line point included in the line and a second line point in the vicinity of the first line point among the line points by a distance calculator; Calculating a first angle of the line at the first line point by an angle calculator, and calculating a second angle between the first line point and the second line point; Calculating an angle difference between the first angle and the second angle by an angle difference calculator; Calculating, by a connection distance calculator, a connection distance between the first line point and the second line point based on the coordinate distance and the angle difference; And determining, by a line point determining unit, a line point having a smallest connection distance to the first line point among the second line points, and connecting the line point to the first line point.

상기 좌표 거리를 산출하는 단계는 하기의 수식 6에 따라 상기 좌표 거리를 산출할 수 있다. 상기 제2 각도를 산출하는 단계는 하기의 수식 7에 따라 상기 제2 각도를 산출할 수 있다. 상기 각도차를 산출하는 단계는 하기의 수식 8에 따라 상기 각도차를 산출할 수 있다. 상기 연결거리를 산출하는 단계는 하기의 수식 9 및 수식 10에 따라 상기 연결거리를 산출할 수 있다.In the calculating of the coordinate distance, the coordinate distance may be calculated according to Equation 6 below. In the calculating of the second angle, the second angle may be calculated according to Equation 7 below. In the calculating of the angle difference, the angle difference may be calculated according to Equation 8 below. In the calculating of the connection distance, the connection distance may be calculated according to Equations 9 and 10 below.

[수식 6][Equation 6]

Figure pat00016
Figure pat00016

[수식 7][Equation 7]

Figure pat00017
Figure pat00017

[수식 8][Equation 8]

Figure pat00018
Figure pat00018

[수식 9][Equation 9]

Figure pat00019
Figure pat00019

[수식 10][Equation 10]

Figure pat00020
Figure pat00020

상기 수식 6 내지 수식 10에서,

Figure pat00021
은 상기 좌표 거리,
Figure pat00022
는 상기 제1 라인점의 행 방향 좌표,
Figure pat00023
는 상기 제1 라인점의 열 방향 좌표,
Figure pat00024
는 상기 제2 라인점의 행 방향 좌표,
Figure pat00025
는 상기 제2 라인점의 열 방향 좌표,
Figure pat00026
는 상기 각도차,
Figure pat00027
는 상기 제1 각도,
Figure pat00028
는 상기 제2 각도,
Figure pat00029
는 설정된 각도차 반영 인자,
Figure pat00030
는 상기 각도차에 따라 결정되는 각도거리,
Figure pat00031
는 상기 연결거리를 나타낸다.In Equations 6 to 10,
Figure pat00021
Is the coordinate distance,
Figure pat00022
Is the row direction coordinate of the first line point,
Figure pat00023
Is the column direction coordinate of the first line point,
Figure pat00024
Is the row direction coordinate of the second line point,
Figure pat00025
Is the column direction coordinate of the second line point,
Figure pat00026
Is the angle difference,
Figure pat00027
Is the first angle,
Figure pat00028
Is the second angle,
Figure pat00029
Is the set angle difference reflection factor,
Figure pat00030
Is the angular distance determined according to the angular difference,
Figure pat00031
Represents the connection distance.

본 발명의 다른 측면에 따르면, 상기 서브픽셀 라인위치 결정 방법을 실행하기 위한 프로그램이 기록된 컴퓨터로 판독 가능한 기록 매체가 제공된다.According to another aspect of the present invention, there is provided a computer-readable recording medium in which a program for executing the subpixel line positioning method is recorded.

본 발명의 또 다른 측면에 따른 서브픽셀 라인위치 결정 장치는, 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 상기 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 결정하기 위한 서브픽셀 라인위치 결정 장치로서, 상기 라인픽셀 및 상기 라인픽셀에 인접한 주변픽셀들을 포함하는 픽셀들에 대해, 인접한 픽셀들 간의 픽셀값 차이와 관련된 그래디언트들을 산출하는 그래디언트 산출부; 상기 픽셀들의 그래디언트들의 크기들을 산출하고, 상기 라인픽셀의 위치에 대한 서브픽셀 레벨 변위를 산출하기 위해 상기 픽셀들의 그래디언트들의 크기들을 기반으로 상기 픽셀들의 그래디언트들을 정규화하는 정규화부; 및 상기 라인픽셀의 위치 및 상기 서브픽셀 레벨 변위를 기반으로 서브픽셀 레벨로 상기 라인점의 위치를 결정하는 서브픽셀 라인위치 결정부를 포함한다.A subpixel line position determining apparatus according to another aspect of the present invention includes a subpixel line for determining a position of a line point corresponding to the line as a subpixel level from a position of a line pixel determined as a pixel level related to a line in an image. A positioning device, comprising: a gradient calculator configured to calculate gradients related to a pixel value difference between adjacent pixels for pixels including the line pixel and adjacent pixels adjacent to the line pixel; A normalization unit that normalizes the gradients of the pixels based on the sizes of the gradients of the pixels to calculate the sizes of the gradients of the pixels and to calculate the subpixel level displacement with respect to the position of the line pixel; And a subpixel line position determining unit configured to determine the position of the line point at a subpixel level based on the position of the line pixel and the subpixel level displacement.

상기 정규화부는, 상기 픽셀들의 그래디언트들을 합산하여 합산 그래디언트를 산출하는 그래디언트 합산부; 상기 픽셀들의 그래디언트들의 크기들을 산출하는 그래디언트 크기 산출부; 상기 픽셀들의 그래디언트들의 크기들을 합산하여 그래디언트 합산 크기를 산출하는 그래디언트 크기 합산부; 및 상기 그래디언트 합산 크기에 의해 상기 합산 그래디언트를 정규화하여 상기 서브픽셀 레벨 변위를 산출하는 서브픽셀 변위 산출부를 포함할 수 있다. 상기 서브픽셀 라인위치 결정부는, 상기 라인픽셀의 위치와 상기 서브픽셀 레벨 변위를 합산하여 상기 라인점의 위치를 서브픽셀 레벨로 결정할 수 있다.The normalization unit may include: a gradient summing unit for calculating a sum gradient by summing the gradients of the pixels; A gradient size calculator that calculates the sizes of the gradients of the pixels; A gradient size summing unit for calculating a summed gradient size by summing the sizes of the gradients of the pixels; And a subpixel displacement calculator configured to calculate the subpixel level displacement by normalizing the summed gradient based on the summed gradient size. The subpixel line position determining unit may determine the position of the line point as the subpixel level by summing the position of the line pixel and the subpixel level displacement.

본 발명에 따른 서브픽셀 라인위치 결정 장치는, 상기 영상에서 상기 라인픽셀의 위치로부터 상기 라인점의 위치를 결정하기 위한 픽셀들을 결정하는 윈도우 설정부를 더 포함할 수 있다. 상기 윈도우 설정부는, 상기 라인픽셀을 중심으로 (2K + 1) × (2K + 1) 픽셀 크기(K는 양의 정수)를 가지는 윈도우를 설정하고, 상기 윈도우 내의 픽셀들을 결정할 수 있다.The subpixel line position determining apparatus according to the present invention may further include a window setting unit that determines pixels for determining the position of the line point from the position of the line pixel in the image. The window setting unit may set a window having a (2K + 1) × (2K + 1) pixel size (K is a positive integer) centered on the line pixel, and determine pixels in the window.

상기 그래디언트 합산부는, 상기 픽셀들의 행 방향 그래디언트들을 합산하여 행 방향 합산 그래디언트를 산출하는 행 방향 그래디언트 합산부; 및 상기 픽셀들의 열 방향 그래디언트들을 합산하여 열 방향 합산 그래디언트를 산출하는 열 방향 그래디언트 합산부를 포함할 수 있다. 상기 그래디언트 크기 산출부는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 산출할 수 있다. 상기 그래디언트 크기 합산부는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 기반으로 상기 그래디언트 합산 크기를 산출할 수 있다. 상기 서브픽셀 변위 산출부는, 상기 행 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 행 방향 서브픽셀 레벨 변위를 산출하는 행 방향 변위 산출부; 및 상기 열 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 열 방향 서브픽셀 레벨 변위를 산출하는 열 방향 변위 산출부를 포함할 수 있다. 상기 서브픽셀 라인위치 결정부는, 상기 라인픽셀의 행 방향 위치와 상기 행 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 행 방향 위치를 서브픽셀 레벨로 결정하고; 그리고 상기 라인픽셀의 열 방향 위치와 상기 열 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 열 방향 위치를 서브픽셀 레벨로 결정할 수 있다.The gradient summing unit may include a row directional gradient summing unit for calculating a row directional sum gradient by summing the row directional gradients of the pixels; And a column direction gradient summing unit configured to calculate a column direction sum gradient by summing the column direction gradients of the pixels. The gradient size calculator may calculate sizes of the row direction gradients and the column direction gradients. The gradient summation unit may calculate the summed gradient size based on the sizes of the row direction gradients and the column direction gradients. The subpixel displacement calculator may include a row direction displacement calculator configured to calculate a row direction subpixel level displacement by dividing the row direction sum gradient by the gradient sum size; And a column direction displacement calculator configured to calculate a column direction subpixel level displacement by dividing the column direction sum gradient by the gradient sum size. The subpixel line position determining unit may determine a row direction position of the line point as a subpixel level by summing a row direction position of the line pixel and the row direction subpixel level displacement; Further, the column direction position of the line point may be determined as a subpixel level by summing the column direction position of the line pixel and the column direction subpixel level displacement.

상기 정규화부는, 상기 라인픽셀의 상태가 릿지(ridge)인 경우, 상기 그래디언트 합산 크기에 제1 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하고; 그리고 상기 라인픽셀의 상태가 밸리(valley)인 경우, 상기 그래디언트 합산 크기에 상기 제1 부호와 상이한 제2 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화할 수 있다.When the state of the line pixel is a ridge, the normalization unit normalizes the gradients of the pixels by applying a first sign to the sum of the gradients; Further, when the state of the line pixel is a valley, the gradients of the pixels may be normalized by applying a second sign different from the first sign to the sum of the gradients.

본 발명에 따른 서브픽셀 라인위치 결정 장치는, 상기 영상에서 라인을 생성하기 위해 상기 라인점들을 연결하는 라인 연결부를 더 포함할 수 있다. 상기 라인 연결부는, 상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점들 간의 좌표 거리들, 그리고 상기 제1 라인점과 상기 제2 라인점들 간의 각도들을 기반으로 상기 제2 라인점들 중 상기 제1 라인점과 연결할 라인점을 결정할 수 있다.The subpixel line positioning apparatus according to the present invention may further include a line connection unit connecting the line points to generate a line in the image. The line connection unit may include coordinate distances between a first line point included in the line and second line points in the vicinity of the first line point among the line points, and the first line point and the second line point A line point to be connected to the first line point among the second line points may be determined based on the angles between them.

상기 라인 연결부는, 상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점 간의 좌표 거리를 산출하는 거리 산출부; 상기 제1 라인점에서의 상기 라인의 제1 각도를 산출하고, 상기 제1 라인점과 상기 제2 라인점 간의 제2 각도를 산출하는 각도 산출부; 상기 제1 각도와 상기 제2 각도 간의 각도차를 산출하는 각도차 산출부; 상기 좌표 거리 및 상기 각도차를 기반으로 상기 제1 라인점과 상기 제2 라인점 간의 연결거리를 산출하는 연결거리 산출부; 및 상기 제2 라인점들 중 상기 제1 라인점과 가장 연결거리가 작은 라인점을 상기 제1 라인점과 연결하는 라인점 결정부를 포함할 수 있다.The line connection unit may include a distance calculator configured to calculate a coordinate distance between a first line point included in the line and a second line point near the first line point among the line points; An angle calculator configured to calculate a first angle of the line at the first line point and to calculate a second angle between the first line point and the second line point; An angle difference calculator configured to calculate an angle difference between the first angle and the second angle; A connection distance calculator configured to calculate a connection distance between the first line point and the second line point based on the coordinate distance and the angle difference; And a line point determining unit connecting a line point having a smallest connection distance to the first line point among the second line points with the first line point.

본 발명의 실시예에 의하면, 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 효율적으로 결정할 수 있는 서브픽셀 라인위치 결정 장치 및 방법, 기록 매체가 제공된다.According to an embodiment of the present invention, a subpixel line positioning apparatus and method for efficiently determining a position of a line point corresponding to a line from a position of a line pixel determined at a pixel level related to a line in an image at a subpixel level, and recording Media is provided.

또한, 본 발명의 실시예에 의하면, 직진성(straightness)과 전방위성(omni-directionality)을 갖도록 라인점들을 연결할 수 있고 라인 특징들이 높은 곡률을 가지는 경우에도 라인점들을 정확하게 연결할 수 있으며, 적은 연산 처리량으로, 고속으로 고품질의 라인들을 추출할 수 있다.In addition, according to an embodiment of the present invention, line points can be connected to have straightness and omni-directionality, and even when line features have high curvature, line points can be accurately connected, and low computational throughput As a result, high-quality lines can be extracted at high speed.

본 발명의 효과는 상술한 효과들로 제한되지 않는다. 언급되지 않은 효과들은 본 명세서 및 첨부된 도면으로부터 본 발명이 속하는 기술분야에서 통상의 지식을 가진 자에게 명확히 이해될 수 있을 것이다.The effect of the present invention is not limited to the above-described effects. Effects not mentioned will be clearly understood by those of ordinary skill in the art from the present specification and the accompanying drawings.

도 1은 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 흐름도이다.
도 2는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치의 구성도이다.
도 3a는 본 발명의 실시예에 따라 설정된 윈도우를 예시한 도면이다.
도 3b는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치를 구성하는 그래디언트 산출부의 구성도이다.
도 4는 도 1의 단계 S300의 흐름도이다.
도 5는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치를 구성하는 정규화부의 구성도이다.
도 6은 도 5의 단계 S360의 순서도이다.
도 7은 도 1의 단계 S500의 흐름도이다.
도 8a는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치를 구성하는 라인 연결부의 구성도이다.
도 8b는 본 발명의 실시예에 따라 라인점과 후보 라인점 간의 연결 거리를 산출하는 과정을 설명하기 위한 도면이다.
도 9는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 연결거리 특성을 보여주는 도면이다.
도 10은 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 성능을 평가하는데 사용된 다양한 라인 특징들을 포함하는 영상들을 예시한 도면이다.
도 11은 본 발명의 실시예에 따라 서브픽셀 단위로 위치 결정된 라인점들을 나타낸 도면이다.
도 12는 본 발명의 실시예와 비교예의 제곱근 평균 오차 성능을 비교하여 나타낸 도면이다.
도 13은 다양한 노이즈 크기와 라인 두께를 가지는 영상들에 대해 본 발명의 실시예와 비교예의 평균 오차 성능을 비교하여 나타낸 도면이다.
도 14는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 성능을 검증하기 위한 실험에 사용된 자연 이미지들(natural images)을 나타낸 도면이다.
도 15는 본 발명의 실시예에 따라 자연 이미지들에서 검출한 라인 픽셀들을 나타낸 것이다.
도 16은 자연 이미지들에 대한 본 발명의 실시예와 비교예의 라인점 위치 결정 결과를 나타낸 도면이다.
도 17은 노이즈가 추가된 자연 이미지들에 대한 본 발명의 실시예와 비교예의 라인점 위치 결정 결과를 나타낸 도면이다.
도 18은 본 발명의 실시예와 비교예에 따라 라인점들을 연결하여 라인을 생성한 결과를 나타낸 도면이다.
1 is a flowchart of a method of determining a line position of a subpixel according to an exemplary embodiment of the present invention.
2 is a configuration diagram of a subpixel line positioning apparatus according to an embodiment of the present invention.
3A is a diagram illustrating a window set according to an embodiment of the present invention.
3B is a configuration diagram of a gradient calculator constituting a subpixel line positioning apparatus according to an embodiment of the present invention.
4 is a flowchart of step S300 of FIG. 1.
5 is a block diagram of a normalization unit constituting a subpixel line positioning apparatus according to an embodiment of the present invention.
6 is a flowchart of step S360 of FIG. 5.
7 is a flowchart of step S500 of FIG. 1.
8A is a block diagram of a line connection part of a subpixel line positioning apparatus according to an embodiment of the present invention.
8B is a diagram for describing a process of calculating a connection distance between a line point and a candidate line point according to an embodiment of the present invention.
9 is a diagram showing connection distance characteristics of a method for determining a line position of a subpixel according to an embodiment of the present invention.
10 is a diagram illustrating images including various line features used to evaluate the performance of a method for determining a subpixel line position according to an embodiment of the present invention.
11 is a diagram illustrating line points positioned in units of subpixels according to an embodiment of the present invention.
12 is a view showing a comparison of the square root mean error performance of the Example of the present invention and Comparative Example.
13 is a diagram showing a comparison of average error performance of an embodiment of the present invention and a comparative example for images having various noise sizes and line thicknesses.
14 is a diagram showing natural images used in an experiment for verifying the performance of a method for determining a subpixel line position according to an embodiment of the present invention.
15 illustrates line pixels detected in natural images according to an embodiment of the present invention.
16 is a diagram showing a result of determining the position of a line point in an embodiment of the present invention and a comparative example for natural images.
17 is a diagram showing a result of determining the position of a line point in an embodiment of the present invention and a comparative example for natural images to which noise is added.
18 is a diagram showing a result of generating a line by connecting line points according to an embodiment and a comparative example of the present invention.

본 발명의 다른 이점 및 특징, 그리고 그것들을 달성하는 방법은 첨부되는 도면과 함께 상세하게 후술하는 실시예를 참조하면 명확해질 것이다. 그러나 본 발명은 이하에서 개시되는 실시예에 한정되지 않으며, 본 발명은 청구항의 범주에 의해 정의될 뿐이다. 만일 정의되지 않더라도, 여기서 사용되는 모든 용어들(기술 혹은 과학 용어들을 포함)은 이 발명이 속한 종래 기술에서 보편적 기술에 의해 일반적으로 수용되는 것과 동일한 의미를 갖는다. 공지된 구성에 대한 일반적인 설명은 본 발명의 요지를 흐리지 않기 위해 생략될 수 있다. 본 발명의 도면에서 동일하거나 상응하는 구성에 대하여는 가급적 동일한 도면부호가 사용된다. 본 발명의 이해를 돕기 위하여, 도면에서 일부 구성은 다소 과장되거나 축소되어 도시될 수 있다.Other advantages and features of the present invention, and a method of achieving them will become apparent with reference to embodiments to be described later in detail together with the accompanying drawings. However, the present invention is not limited to the embodiments disclosed below, and the present invention is only defined by the scope of the claims. Even if not defined, all terms (including technical or scientific terms) used herein have the same meaning as commonly accepted by universal technology in the prior art to which this invention belongs. General descriptions of known configurations may be omitted so as not to obscure the subject matter of the present invention. In the drawings of the present invention, the same reference numerals are used as much as possible for the same or corresponding configurations. In order to help the understanding of the present invention, some configurations in the drawings may be somewhat exaggerated or reduced.

본 출원에서 사용한 용어는 단지 특정한 실시예를 설명하기 위해 사용된 것으로, 본 발명을 한정하려는 의도가 아니다. 단수의 표현은 문맥상 명백하게 다르게 뜻하지 않는 한, 복수의 표현을 포함한다. 본 출원에서, "포함하다", "가지다" 또는 "구비하다" 등의 용어는 명세서상에 기재된 특징, 숫자, 단계, 동작, 구성요소, 부분품 또는 이들을 조합한 것이 존재함을 지정하려는 것이지, 하나 또는 그 이상의 다른 특징들이나 숫자, 단계, 동작, 구성요소, 부분품 또는 이들을 조합한 것들의 존재 또는 부가 가능성을 미리 배제하지 않는 것으로 이해되어야 한다.The terms used in the present application are only used to describe specific embodiments, and are not intended to limit the present invention. Singular expressions include plural expressions unless the context clearly indicates otherwise. In the present application, terms such as "comprise", "have" or "have" are intended to designate the presence of features, numbers, steps, actions, components, parts, or a combination thereof described in the specification. It is to be understood that the possibility of the presence or addition of other features, numbers, steps, actions, components, parts, or combinations thereof, or any further features, is not excluded in advance.

본 명세서 전체에서 사용되는 '~부'는 적어도 하나의 기능이나 동작을 처리하는 단위로서, 예를 들어 소프트웨어, FPGA 또는 ASIC과 같은 하드웨어 구성요소를 의미할 수 있다. 그렇지만 '~부'가 소프트웨어 또는 하드웨어에 한정되는 의미는 아니다. '~부'는 어드레싱할 수 있는 저장 매체에 있도록 구성될 수도 있고 하나 또는 그 이상의 프로세서들을 재생시키도록 구성될 수도 있다. 일 예로서 '~부'는 소프트웨어 구성요소들, 객체지향 소프트웨어 구성요소들, 클래스 구성요소들 및 태스크 구성요소들과 같은 구성요소들과, 프로세스들, 함수들, 속성들, 프로시저들, 서브루틴들, 프로그램 코드의 세그먼트들, 드라이버들, 펌웨어, 마이크로 코드, 회로, 데이터, 데이터베이스, 데이터 구조들, 테이블들, 어레이들 및 변수들을 포함할 수 있다. 구성요소와 '~부'에서 제공하는 기능은 복수의 구성요소 및 '~부'들에 의해 분리되어 수행될 수도 있고, 다른 추가적인 구성요소와 통합될 수도 있다.The'~ unit' used throughout this specification is a unit that processes at least one function or operation, and may mean, for example, a hardware component such as software, FPGA, or ASIC. However,'~ part' is not limited to software or hardware. The'~ unit' may be configured to be in an addressable storage medium, or may be configured to reproduce one or more processors. As an example,'~ unit' refers to components such as software components, object-oriented software components, class components, and task components, processes, functions, properties, procedures, and subs. Routines, segments of program code, drivers, firmware, microcode, circuits, data, databases, data structures, tables, arrays, and variables. The components and functions provided by the'~ unit' may be performed separately by a plurality of elements and the'~ units', or may be integrated with other additional elements.

본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법은 영상에서 미리 검출되어 픽셀 레벨로 결정된 라인픽셀에 근접한 픽셀들의 그래디언트 합의 정규화(RSG; Regularized Sum of Gradients)를 기반으로 서브픽셀 라인위치를 추정함으로써, 정확하고 빠르게 그리고 적은 연산 처리량으로 라인 위치를 서브픽셀 정확도로 결정할 수 있으며, 약한 라인신호 조건이나 강한 노이즈 조건에서도 강건하고 정확하게 서브픽셀 정확도로 라인 위치를 결정할 수 있다. 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법은 픽셀 레벨로 결정된 라인픽셀의 이웃에 있는 픽셀들의 그래디언트 벡터들의 합을 픽셀들의 그래디언트 크기들의 합으로 나누는 RSG 처리를 기반으로 라인에 속하는 라인점들의 위치를 서브픽셀 레벨로 정확하게 결정할 수 있다.The subpixel line position determination method according to an embodiment of the present invention estimates the subpixel line position based on the regularized sum of gradients (RSG) of pixels adjacent to the line pixel detected in advance and determined as the pixel level in an image. In addition, it is possible to determine the line position with sub-pixel accuracy accurately, quickly and with low computational throughput, and robustly and accurately determine the line position with sub-pixel accuracy even under weak line signal conditions or strong noise conditions. The method for determining a line position of a subpixel according to an embodiment of the present invention is based on a RSG process in which the sum of gradient vectors of pixels adjacent to the line pixel determined at the pixel level is divided by the sum of the gradient sizes of the pixels. Position can be accurately determined at the subpixel level.

본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법은 라인에 속하는 라인점(제1 라인점)과, 후보 라인점들(제2 라인점들) 간의 좌표 거리 및 각도차를 기반으로 제1 라인점과 제2 라인점 간의 연결 거리를 산출하고, 좌표 거리 및 각도차를 기반으로 산출된 연결 거리를 기반으로 제2 라인점들 중 제1 라인점에 연결될 제2 라인점을 결정하여 연결할 수 있다. 본 발명의 실시예에 의하면, 직진성(straightness)과 전방위성(omni-directionality)을 갖도록 라인점들을 연결하여 라인을 생성할 수 있으며, 라인 특징들이 높은 곡률을 가지는 경우에도 라인점들을 정확하게 연결함으로써, 영상에서 라인들을 고품질로 추출할 수 있다.The method for determining a subpixel line position according to an embodiment of the present invention includes a first line based on a coordinate distance and an angle difference between a line point (first line point) belonging to a line and candidate line points (second line points). A connection distance between the point and the second line point may be calculated, and a second line point to be connected to the first line point among the second line points may be determined and connected based on the connection distance calculated based on the coordinate distance and the angle difference. . According to an embodiment of the present invention, a line can be created by connecting line points to have straightness and omni-directionality, and by accurately connecting line points even when line features have high curvature, Lines can be extracted with high quality from an image.

도 1은 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 흐름도이다. 도 2는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치의 구성도이다. 도 1 및 도 2를 참조하면, 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치(10)는 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 결정하기 위한 것으로, 윈도우 설정부(100), 그래디언트 산출부(200), 정규화부(300), 서브픽셀 라인위치 결정부(400) 및 라인 연결부(500)를 포함할 수 있다.1 is a flowchart of a method of determining a line position of a subpixel according to an exemplary embodiment of the present invention. 2 is a configuration diagram of a subpixel line positioning apparatus according to an embodiment of the present invention. 1 and 2, the subpixel line position determining apparatus 10 according to an exemplary embodiment of the present invention subtracts a position of a line point corresponding to a line from a position of a line pixel determined as a pixel level related to a line in an image. To determine the pixel level, it may include a window setting unit 100, a gradient calculator 200, a normalization unit 300, a subpixel line position determining unit 400, and a line connection unit 500.

윈도우 설정부(100)는 영상에서 픽셀 레벨로 검출된 라인픽셀의 위치로부터 라인점의 위치를 결정하기 위한 픽셀들을 결정할 수 있다(S100). 윈도우 설정부(100)는 라인픽셀을 중심으로 (2K + 1) × (2K + 1) 픽셀 크기(K는 양의 정수)를 가지는 윈도우(local window)를 설정하고, 윈도우 내의 (2K + 1) × (2K + 1) 개의 픽셀들을 결정할 수 있다.The window setting unit 100 may determine pixels for determining the position of the line point from the position of the line pixel detected at the pixel level in the image (S100). The window setting unit 100 sets a local window having a pixel size of (2K + 1) × (2K + 1) pixel (K is a positive integer) centered on the line pixel, and (2K + 1) in the window. × (2K + 1) pixels can be determined.

도 3a는 본 발명의 실시예에 따라 설정된 윈도우를 예시한 도면이다. 도 1 내지 도 3a를 참조하면, 라인픽셀(LP)에 대한 서브픽셀 레벨 라인 위치를 결정하기 위하여, 윈도우 설정부(100)는 (r,c) 좌표에 해당하는 라인픽셀(LP)을 중심으로 (2K + 1) × (2K + 1) 픽셀 크기(K는 양의 정수)를 가지는 윈도우(LW)를 설정하여, 라인픽셀(LP)과 라인픽셀(LP)에 이웃한 4K(K+1) 개의 주변픽셀들(PP)을 포함하여 총 (2K + 1) × (2K + 1) 개의 픽셀들을 선택할 수 있다.3A is a diagram illustrating a window set according to an embodiment of the present invention. 1 to 3A, in order to determine the subpixel level line position for the line pixel LP, the window setting unit 100 centers on the line pixel LP corresponding to the (r,c) coordinate. (2K + 1) × (2K + 1) By setting a window (LW) with a pixel size (K is a positive integer), 4K (K+1) adjacent to the line pixel (LP) and the line pixel (LP) A total of (2K + 1) × (2K + 1) pixels including the neighboring pixels PP may be selected.

도 3a에는 K = 1 인 윈도우(LW)의 예, 즉 3×3 픽셀 크기의 윈도우(LW)가 도시되어 있으나, 윈도우 설정부(100)는 윈도우(LW)의 K 값을 2 이상으로 설정하여 라인픽셀(LP) 부근의 픽셀들을 추출할 수도 있다. 또한, 윈도우 설정부(100)는 반드시 정방형의 윈도우(LW)를 설정하지 않고, 직사각형 또는 사각 이상의 다각형 구조의 윈도우를 설정하여 라인픽셀(LP) 부근의 픽셀들을 추출할 수도 있다.3A shows an example of a window LW with K = 1, that is, a window LW having a size of 3×3 pixels, but the window setting unit 100 sets the K value of the window LW to 2 or more. Pixels near the line pixel LP may be extracted. In addition, the window setting unit 100 may not necessarily set a square window LW, but may extract pixels near the line pixel LP by setting a window having a polygonal structure of a rectangle or more than a square.

그래디언트 산출부(200)는 라인픽셀(LP) 및 라인픽셀(LP)에 인접한 주변픽셀들(PP)을 포함하는 픽셀들에 대해, 인접한 픽셀들 간의 픽셀값 차이와 관련된 그래디언트들을 산출할 수 있다(S200). 도 3b는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치를 구성하는 그래디언트 산출부의 구성도이다. 도 1 내지 도 3b를 참조하면, 그래디언트 산출부(200)는 행방향 그래디언트 산출부(220)와, 열방향 그래디언트 산출부(240)를 포함할 수 있다.The gradient calculator 200 may calculate gradients related to a pixel value difference between adjacent pixels for pixels including the line pixel LP and the surrounding pixels PP adjacent to the line pixel LP ( S200). 3B is a configuration diagram of a gradient calculator constituting a subpixel line positioning apparatus according to an embodiment of the present invention. 1 to 3B, the gradient calculator 200 may include a row direction gradient calculator 220 and a column direction gradient calculator 240.

행방향 그래디언트 산출부(220)는 행 방향으로 인접한 픽셀들 간의 픽셀값 차이를 산출하여 행 방향 그래디언트를 산출할 수 있다. 열방향 그래디언트 산출부(240)는 열 방향으로 인접한 픽셀들 간의 픽셀값 차이를 산출하여 열 방향 그래디언트를 산출할 수 있다.The row direction gradient calculator 220 may calculate a row direction gradient by calculating a pixel value difference between pixels adjacent in the row direction. The column direction gradient calculator 240 may calculate a column direction gradient by calculating a pixel value difference between pixels adjacent in the column direction.

정규화부(300)는 픽셀들의 그래디언트들의 크기들을 산출하고, 라인픽셀의 위치에 대한 서브픽셀 레벨 변위를 산출하기 위해 픽셀들의 그래디언트들의 크기들을 기반으로 픽셀들의 그래디언트들을 정규화할 수 있다(S300). 도 4는 도 1의 단계 S300의 흐름도이다. 도 5는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치를 구성하는 정규화부의 구성도이다. 도 4 및 도 5를 참조하면, 정규화부(300)는 그래디언트 합산부(320), 그래디언트 크기 산출부(340), 그래디언트 크기 합산부(360) 및 서브픽셀 변위 산출부(380)를 포함할 수 있다.The normalization unit 300 may normalize the gradients of the pixels based on the sizes of the gradients of the pixels in order to calculate the sizes of the gradients of the pixels and calculate the subpixel level displacement with respect to the position of the line pixel (S300). 4 is a flowchart of step S300 of FIG. 1. 5 is a block diagram of a normalization unit constituting a subpixel line positioning apparatus according to an embodiment of the present invention. 4 and 5, the normalization unit 300 may include a gradient summing unit 320, a gradient size calculation unit 340, a gradient size summing unit 360, and a subpixel displacement calculation unit 380. have.

그래디언트 합산부(320)는 픽셀들의 그래디언트들을 합산하여 합산 그래디언트를 산출할 수 있다(S320). 그래디언트 합산부(320)는 행 방향 그래디언트 합산부(322)와, 열 방향 그래디언트 합산부(324)를 포함할 수 있다. 행 방향 그래디언트 합산부(322)는 픽셀들의 행 방향 그래디언트들을 합산하여 행 방향 합산 그래디언트를 산출할 수 있다. 열 방향 그래디언트 합산부(324)는 픽셀들의 열 방향 그래디언트들을 합산하여 열 방향 합산 그래디언트를 산출할 수 있다. 실시예에서, 그래디언트 합산부(320)는 하기의 수식 1에 따라 행 방향 합산 그래디언트 및 열 방향 합산 그래디언트를 산출할 수 있다.The gradient summing unit 320 may calculate a sum gradient by summing the gradients of pixels (S320). The gradient summing unit 320 may include a row direction gradient summing unit 322 and a column directional gradient summing unit 324. The row direction gradient summing unit 322 may calculate the row direction sum gradient by summing the row direction gradients of the pixels. The column direction gradient summing unit 324 may calculate the column direction sum gradient by summing the column direction gradients of pixels. In an embodiment, the gradient summing unit 320 may calculate the summed row direction gradient and the summed column direction gradient according to Equation 1 below.

[수식 1][Equation 1]

Figure pat00032
Figure pat00032

수식 1에서,

Figure pat00033
는 행 방향 합산 그래디언트,
Figure pat00034
는 열 방향 합산 그래디언트,
Figure pat00035
는 행 방향 그래디언트,
Figure pat00036
는 열 방향 그래디언트를 나타낸다. (r,c)는 라인픽셀의 좌표이다. 그래디언트 합산부(320)는 (2K + 1) × (2K + 1) 개(K는 양의 정수)의 픽셀들의 크기를 가지는 로컬 윈도우(local window) 내에서 행 방향 그래디언트들의 합인 행 방향 합산 그래디언트
Figure pat00037
와, 열 방향 그래디언트들의 합인 열 방향 합산 그래디언트
Figure pat00038
를 각각 계산할 수 있다.In Equation 1,
Figure pat00033
Is the summation gradient in the row direction,
Figure pat00034
Is the summation gradient in the column direction,
Figure pat00035
Is the row direction gradient,
Figure pat00036
Represents the column direction gradient. (r,c) is the coordinates of the line pixel. The gradient summing unit 320 is a row direction summation gradient that is the sum of row direction gradients within a local window having a size of (2K + 1) × (2K + 1) pixels (K is a positive integer).
Figure pat00037
Wow, the summation gradient in the column direction, which is the sum of the gradients in the column direction
Figure pat00038
Each can be calculated.

그래디언트 크기 산출부(340)는 픽셀들의 그래디언트들의 크기들을 산출할 수 있다(S340). 그래디언트 크기 산출부(340)는 행 방향 그래디언트들의 크기들 및 열 방향 그래디언트들의 크기들을 산출할 수 있다. 그래디언트 크기 합산부(360)는 픽셀들의 그래디언트들의 크기들을 합산하여 그래디언트 합산 크기를 산출할 수 있다(S360). 그래디언트 크기 합산부(360)는 행 방향 그래디언트들의 크기들 및 열 방향 그래디언트들의 크기들을 기반으로 그래디언트 합산 크기를 산출할 수 있다. 실시예에서, 그래디언트 크기 합산부(360)는 하기의 수식 2에 따라 로컬 윈도우 내의 그래디언트 크기들의 합을 계산하여 그래디언트 합산 크기를 산출할 수 있다.The gradient size calculator 340 may calculate the sizes of gradients of pixels (S340). The gradient size calculator 340 may calculate the sizes of the row direction gradients and the column direction gradients. The gradient size summing unit 360 may calculate the summed gradient size by summing the sizes of the gradients of the pixels (S360). The gradient size summing unit 360 may calculate the summed gradient size based on the sizes of the row direction gradients and the column direction gradients. In an embodiment, the gradient size summing unit 360 may calculate the sum of the gradient sizes in the local window according to Equation 2 below to calculate the summed gradient size.

[수식 2][Equation 2]

Figure pat00039
Figure pat00039

수식 2에서,

Figure pat00040
는 행 방향 그래디언트,
Figure pat00041
는 열 방향 그래디언트,
Figure pat00042
는 그래디언트 합산 크기를 나타낸다. (r,c)는 라인픽셀의 좌표이다. 그래디언트 합산 크기
Figure pat00043
는 서브픽셀 라인 위치들의 그래디언트들의 합(합산 그래디언트)을 정규화하는데 사용된다.In Equation 2,
Figure pat00040
Is the row direction gradient,
Figure pat00041
Is the column direction gradient,
Figure pat00042
Represents the gradient sum size. (r,c) is the coordinates of the line pixel. Gradient sum size
Figure pat00043
Is used to normalize the sum of the gradients of the subpixel line positions (sum gradient).

도 6은 도 5의 단계 S360의 순서도이다. 도 2 및 도 6을 참조하면, 정규화부(300)는 라인픽셀의 상태가 릿지(ridge)인 경우, 그래디언트 합산 크기에 제1 부호를 적용하여 픽셀들의 그래디언트들을 정규화하고(S362), 라인픽셀의 상태가 밸리(valley)인 경우, 그래디언트 합산 크기에 제1 부호와 상이한 제2 부호를 적용하여 픽셀들의 그래디언트들을 정규화할 수 있다(S364).6 is a flowchart of step S360 of FIG. 5. 2 and 6, when the state of the line pixel is ridge, the normalization unit 300 normalizes the gradients of the pixels by applying a first sign to the sum of the gradients (S362), and When the state is a valley, the gradients of the pixels may be normalized by applying a second code different from the first sign to the sum of the gradients (S364).

다시 도 4 및 도 5를 참조하면, 서브픽셀 변위 산출부(380)는 그래디언트 합산 크기에 의해 합산 그래디언트를 정규화하여 서브픽셀 레벨 변위를 산출할 수 있다(S380). 서브픽셀 변위 산출부(380)는 행 방향 변위 산출부(382)와, 열 방향 변위 산출부(384)를 포함할 수 있다. 행 방향 변위 산출부(382)는 행 방향 합산 그래디언트를 그래디언트 합산 크기로 나누어 행 방향 서브픽셀 레벨 변위를 산출할 수 있다. 열 방향 변위 산출부(384)는 열 방향 합산 그래디언트를 그래디언트 합산 크기로 나누어 열 방향 서브픽셀 레벨 변위를 산출할 수 있다. 실시예에서, 서브픽셀 변위 산출부(380)는 하기의 수식 3 및 수식 4에 따라 서브픽셀 레벨 변위를 산출할 수 있다.Referring back to FIGS. 4 and 5, the subpixel displacement calculator 380 may calculate the subpixel level displacement by normalizing the sum gradient based on the summed gradient size (S380). The subpixel displacement calculation unit 380 may include a row direction displacement calculation unit 382 and a column direction displacement calculation unit 384. The row direction displacement calculator 382 may calculate the row direction subpixel level displacement by dividing the row direction sum gradient by the gradient sum size. The column direction displacement calculator 384 may calculate the column direction subpixel level displacement by dividing the column direction sum gradient by the gradient sum size. In an embodiment, the subpixel displacement calculator 380 may calculate the subpixel level displacement according to Equations 3 and 4 below.

[수식 3][Equation 3]

Figure pat00044
Figure pat00044

[수식 4][Equation 4]

Figure pat00045
Figure pat00045

수식 3 및 수식 4에서,

Figure pat00046
는 행 방향 합산 그래디언트,
Figure pat00047
는 열 방향 합산 그래디언트,
Figure pat00048
는 라인픽셀의 상태가 릿지인지 밸리인지를 나타내는 정보,
Figure pat00049
는 행 방향 서브픽셀 레벨 변위,
Figure pat00050
는 열 방향 서브픽셀 레벨 변위, c는 라인픽셀의 열 방향 좌표, r은 라인픽셀의 행 방향 좌표를 나타낸다. 라인픽셀의 상태를 결정하기 위하여, 아래와 같이 2개의 커널(kernel)이 정의되고, 2개의 커널을 기반으로 하기의 수식에 따라
Figure pat00051
가 산출될 수 있다.In Equation 3 and Equation 4,
Figure pat00046
Is the summation gradient in the row direction,
Figure pat00047
Is the summation gradient in the column direction,
Figure pat00048
Is information indicating whether the state of the line pixel is ridge or valley,
Figure pat00049
Is the row direction subpixel level displacement,
Figure pat00050
Is the subpixel level displacement in the column direction, c is the column direction coordinate of the line pixel, and r is the row direction coordinate of the line pixel. In order to determine the state of the line pixel, two kernels are defined as follows, and based on the two kernels, according to the following equation
Figure pat00051
Can be calculated.

Figure pat00052
,
Figure pat00053
Figure pat00052
,
Figure pat00053

Figure pat00054
Figure pat00054

Figure pat00055
값이 0 보다 크면 라인픽셀은 릿지로 분류되고, 그렇지 않으면 라인픽셀은 밸리로 분류될 수 있다. 서브픽셀 변위 산출부(380)는
Figure pat00056
값을 기반으로 수식 3에 따라 정규화값의 부호를 결정하여 그래디언트 합산 크기에 제1 부호(예를 들어, 양의 부호) 또는 제2 부호(예를 들어, 음의 부호)를 적용하고, 수식 4에 따라 행 방향 합산 그래디언트 및 열 방향 합산 그래디언트를 각각 정규화값의 부호가 적용된 그래디언트 합산 크기 D(r,c)로 나누어 정규화함으로써, 서브픽셀 레벨 변위를 산출할 수 있다. 서브픽셀 레벨 변위
Figure pat00057
,
Figure pat00058
Figure pat00059
,
Figure pat00060
, 및
Figure pat00061
에 따라 결정될 수 있다. 서브픽셀 레벨 변위는 라인픽셀의 중심에 대한 상대 변위값을 의미한다.
Figure pat00055
If the value is greater than 0, the line pixel may be classified as a ridge, otherwise the line pixel may be classified as a valley. The subpixel displacement calculation unit 380
Figure pat00056
Based on the value, the sign of the normalized value is determined according to Equation 3, and the first sign (for example, positive sign) or the second sign (for example, negative sign) is applied to the sum of the gradients, and Equation 4 According to, the subpixel level displacement can be calculated by dividing the summation gradient in the row direction and the summation gradient in the column direction by the summed gradient size D(r,c) to which the sign of the normalization value is applied. Subpixel level displacement
Figure pat00057
,
Figure pat00058
Is
Figure pat00059
,
Figure pat00060
, And
Figure pat00061
Can be determined according to. The subpixel level displacement means a relative displacement value with respect to the center of a line pixel.

서브픽셀 라인위치 결정부(400)는 라인픽셀의 위치 및 서브픽셀 레벨 변위를 기반으로 서브픽셀 레벨로 라인점의 위치를 결정할 수 있다(S400). 서브픽셀 라인위치 결정부(400)는 라인픽셀의 위치와 서브픽셀 레벨 변위를 합산하여 라인점의 위치를 서브픽셀 레벨로 결정할 수 있다. 서브픽셀 라인위치 결정부(400)는 라인픽셀의 행 방향 위치와 행 방향 서브픽셀 레벨 변위를 합산하여 라인점의 행 방향 위치를 서브픽셀 레벨로 결정하고, 라인픽셀의 열 방향 위치와 열 방향 서브픽셀 레벨 변위를 합산하여 라인점의 열 방향 위치를 서브픽셀 레벨로 결정할 수 있다. 실시예에서, 서브픽셀 라인위치 결정부(400)는 하기의 수식 5에 따라 라인점의 위치(서브픽셀 라인좌표)를 결정할 수 있다.The subpixel line position determiner 400 may determine the position of the line point at the subpixel level based on the position of the line pixel and the subpixel level displacement (S400). The subpixel line position determiner 400 may determine the position of the line point as the subpixel level by summing the position of the line pixel and the subpixel level displacement. The subpixel line position determining unit 400 determines the row direction position of the line point as the subpixel level by summing the row direction position of the line pixel and the row direction subpixel level displacement, and determines the column direction position of the line pixel and the column direction subpixel level. The position of the line point in the column direction may be determined as the sub-pixel level by summing the pixel-level displacement. In an embodiment, the subpixel line position determiner 400 may determine the position of the line point (subpixel line coordinate) according to Equation 5 below.

[수식 5][Equation 5]

Figure pat00062
Figure pat00062

수식 5에서, c는 라인픽셀의 열 방향 좌표, r은 라인픽셀의 행 방향 좌표,

Figure pat00063
는 행 방향 서브픽셀 레벨 변위,
Figure pat00064
는 열 방향 서브픽셀 레벨 변위,
Figure pat00065
는 라인점의 행 방향 위치,
Figure pat00066
는 라인점의 열 방향 위치를 나타낸다.In Equation 5, c is the column direction coordinate of the line pixel, r is the row direction coordinate of the line pixel,
Figure pat00063
Is the row direction subpixel level displacement,
Figure pat00064
Is the column direction subpixel level displacement,
Figure pat00065
Is the row direction position of the line point,
Figure pat00066
Indicates the position of the line point in the column direction.

라인 연결부(500)는 영상에서 라인을 생성하기 위해 라인점들을 연결할 수 있다. 라인 연결부(500)는 라인에 포함된 제1 라인점과, 라인점들 중 제1 라인점 근방의 제2 라인점들 간의 좌표 거리들, 그리고 제1 라인점과 제2 라인점들 간의 각도들을 기반으로 제2 라인점들 중 제1 라인점과 연결할 라인점을 결정할 수 있다.The line connector 500 may connect line points to create a line in an image. The line connection unit 500 determines coordinate distances between a first line point included in the line, second line points in the vicinity of the first line point among the line points, and angles between the first line point and the second line points. Based on the second line point, a line point to be connected to the first line point may be determined.

도 7은 도 1의 단계 S500의 흐름도이다. 도 8a는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 장치를 구성하는 라인 연결부의 구성도이다. 도 8b는 본 발명의 실시예에 따라 라인점과 후보 라인점 간의 연결 거리를 산출하는 과정을 설명하기 위한 도면이다. 도 7 내지 도 8b를 참조하면, 라인 연결부(500)는 거리 산출부(510), 각도 산출부(520), 각도차 산출부(530), 연결거리 산출부(540) 및 라인점 결정부(550)를 포함할 수 있다.7 is a flowchart of step S500 of FIG. 1. 8A is a block diagram of a line connection part of a subpixel line positioning apparatus according to an embodiment of the present invention. 8B is a diagram for describing a process of calculating a connection distance between a line point and a candidate line point according to an embodiment of the present invention. 7 to 8B, the line connection unit 500 includes a distance calculation unit 510, an angle calculation unit 520, an angle difference calculation unit 530, a connection distance calculation unit 540, and a line point determination unit ( 550) may be included.

거리 산출부(510)는 라인(LN)에 포함된 제1 라인점(P1)과, 라인점들 중 제1 라인점(P1) 근방의 각 제2 라인점(P2, P3) 간의 좌표 거리를 산출할 수 있다(S510). 거리 산출부(510)는 하기의 수식 6에 따라 좌표 거리를 산출할 수 있다.The distance calculating unit 510 calculates a coordinate distance between the first line point P1 included in the line LN and the second line points P2 and P3 in the vicinity of the first line point P1 among the line points. It can be calculated (S510). The distance calculator 510 may calculate the coordinate distance according to Equation 6 below.

[수식 6][Equation 6]

Figure pat00067
Figure pat00067

수식 6에서,

Figure pat00068
은 좌표 거리,
Figure pat00069
는 제1 라인점(P1)의 행 방향 좌표,
Figure pat00070
는 제1 라인점(P1)의 열 방향 좌표,
Figure pat00071
는 제2 라인점(후보 라인점)(P2, P3)의 행 방향 좌표,
Figure pat00072
는 제2 라인점(P2, P3)의 열 방향 좌표를 나타낸다.
Figure pat00073
는 제1 라인점(P1)의 좌표이고,
Figure pat00074
는 제2 라인점(P2, P3)의 좌표이다.In Equation 6,
Figure pat00068
Is the coordinate distance,
Figure pat00069
Is the row direction coordinate of the first line point P1,
Figure pat00070
Is the column direction coordinate of the first line point P1,
Figure pat00071
Is the row direction coordinate of the second line point (candidate line point) (P2, P3),
Figure pat00072
Denotes the column direction coordinates of the second line points P2 and P3.
Figure pat00073
Is the coordinates of the first line point P1,
Figure pat00074
Is the coordinates of the second line points P2 and P3.

각도 산출부(520)는 제1 라인점(P1)에서의 라인(LN)의 제1 각도를 산출하고, 제1 라인점(P1)과 제2 라인점(P2, P3) 간의 제2 각도를 산출할 수 있다(S520). 실시예에서, 각도 산출부(520)는 하기의 수식 7에 따라 제2 각도(후보 방향 각도)를 산출할 수 있다.The angle calculation unit 520 calculates a first angle of the line LN at the first line point P1, and calculates a second angle between the first line point P1 and the second line points P2 and P3. It can be calculated (S520). In an embodiment, the angle calculator 520 may calculate the second angle (candidate direction angle) according to Equation 7 below.

[수식 7][Equation 7]

Figure pat00075
Figure pat00075

수식 7에서,

Figure pat00076
는 제1 라인점(P1)의 행 방향 좌표,
Figure pat00077
는 제1 라인점(P1)의 열 방향 좌표,
Figure pat00078
는 제2 라인점(P2, P3)의 행 방향 좌표,
Figure pat00079
는 제2 라인점(P2, P3)의 열 방향 좌표,
Figure pat00080
는 제2 각도를 나타낸다. 각도차 산출부(530)는 제1 각도(현재 라인의 방향 각도)와 제2 각도(후보 방향 각도) 간의 각도차를 산출할 수 있다(S530). 각도차 산출부(530)는 하기의 수식 8에 따라 각도차를 산출할 수 있다.In Equation 7,
Figure pat00076
Is the row direction coordinate of the first line point P1,
Figure pat00077
Is the column direction coordinate of the first line point P1,
Figure pat00078
Is the row direction coordinate of the second line point (P2, P3),
Figure pat00079
Is the column direction coordinate of the second line point (P2, P3),
Figure pat00080
Represents the second angle. The angle difference calculator 530 may calculate an angle difference between a first angle (a current line direction angle) and a second angle (a candidate direction angle) (S530). The angle difference calculator 530 may calculate the angle difference according to Equation 8 below.

[수식 8][Equation 8]

Figure pat00081
Figure pat00081

수식 8에서,

Figure pat00082
는 각도차,
Figure pat00083
는 제1 각도,
Figure pat00084
는 제2 각도를 나타낸다. 연결거리 산출부(540)는 좌표 거리 및 각도차를 기반으로 제1 라인점(P1)과 제2 라인점(P2, P3) 간의 연결거리를 산출할 수 있다(S540). 연결거리 산출부(540)는 하기의 수식 9 및 수식 10에 따라 연결거리를 산출할 수 있다.In Equation 8,
Figure pat00082
Is the angle difference,
Figure pat00083
Is the first angle,
Figure pat00084
Represents the second angle. The connection distance calculation unit 540 may calculate a connection distance between the first line point P1 and the second line point P2 and P3 based on the coordinate distance and the angle difference (S540). The connection distance calculator 540 may calculate the connection distance according to Equations 9 and 10 below.

[수식 9][Equation 9]

Figure pat00085
Figure pat00085

[수식 10][Equation 10]

Figure pat00086
Figure pat00086

수식 9 및 수식 10에서,

Figure pat00087
는 각도차,
Figure pat00088
는 설정된 각도차 반영 인자,
Figure pat00089
는 각도차(
Figure pat00090
)에 따라 결정되는 각도거리,
Figure pat00091
는 연결거리를 나타낸다.
Figure pat00092
는 연결 거리에 대한 각도 거리의 영향을 조절하기 위한 인자이다.
Figure pat00093
는 예를 들어, 3.0으로 설정될 수 있다. 라인점 결정부(550)는 제2 라인점들(후보 라인점들) 중 제1 라인점(P1)과 가장 연결거리가 작은 라인점(최소 연결거리를 가지는 라인점)을 제1 라인점(P1)과 연결할 수 있다(S550). 다음으로, 선택된 제2 라인점의 방향 및 위치(좌표)는 다음 라인점을 연결을 위한 제1 라인점의 방향 및 위치로 갱신될 수 있다.In Equation 9 and Equation 10,
Figure pat00087
Is the angle difference,
Figure pat00088
Is the set angle difference reflection factor,
Figure pat00089
Is the angular difference (
Figure pat00090
Angular distance determined according to ),
Figure pat00091
Represents the connection distance.
Figure pat00092
Is a factor for controlling the influence of the angular distance on the connection distance.
Figure pat00093
May be set to 3.0, for example. The line point determination unit 550 selects a line point (a line point having a minimum connection distance) with the smallest connection distance to the first line point P1 among the second line points (candidate line points). It can be connected to P1) (S550). Next, the direction and position (coordinate) of the selected second line point may be updated to the direction and position of the first line point for connecting the next line point.

도 9는 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 연결거리 특성을 보여주는 도면이다. 도 9의 (a)는 Steger 방법에 의한 연결거리 특성을 나타낸 도면이고, 도 9의 (b)는 상기 수식 10에 따른 연결거리 특성을 나타낸 도면이다. 도 9의 (b)에 도시된 그래프에서 가로축은 좌표거리(기하거리)

Figure pat00094
, 세로축은 각도차(각도거리)
Figure pat00095
, 색상 스케일은 연결거리 d를 나타낸다. 반투명한 백색 영역은 연결거리가 3.0 이하인 영역을 나타낸다. 도 9의 (b)에 도시된 바와 같이, 본 발명의 실시예에 따른 방법은 좌표거리
Figure pat00096
가 커질수록(예를 들어, 0.8 픽셀보다 큰 경우), 좌표거리
Figure pat00097
보다 직진성(straightness)을 더 중요한 인자로 고려한다.9 is a diagram showing connection distance characteristics of a method for determining a line position of a subpixel according to an embodiment of the present invention. FIG. 9A is a diagram showing the connection distance characteristics according to the Steger method, and FIG. 9B is a diagram showing the connection distance characteristics according to Equation 10 above. In the graph shown in Fig. 9(b), the horizontal axis is the coordinate distance (geometric distance)
Figure pat00094
, The vertical axis is the angle difference (angle distance)
Figure pat00095
, The color scale represents the connection distance d. The translucent white area represents the area where the connection distance is 3.0 or less. As shown in (b) of Figure 9, the method according to the embodiment of the present invention is a coordinate distance
Figure pat00096
The larger is (for example, greater than 0.8 pixels), the coordinate distance
Figure pat00097
Consider straightness as a more important factor.

또한, Steger 방법은 현재 라인 방향으로부터 90° 이상 벗어난 라인점들을 후보 연결 위치들로 고려하지 않지만, 본 발명은 현재 라인점과의 기하 거리가 비교적 작은 라인점들(예를 들어, 0.8 픽셀 미만)인 경우에는 이러한 라인점들이 현재 라인점의 라인 방향으로부터 90° 이상 벗어나 있더라도 후보 연결 위치들로 고려할 수 있다. 따라서, 직진성(straightness)과 전방위성(omni-directionality)을 갖도록 라인점들을 연결하여 라인점들이 끊어지는 현상을 방지할 수 있다.In addition, the Steger method does not consider line points deviating from the current line direction by more than 90° as candidate connection positions, but the present invention provides line points with a relatively small geometric distance from the current line point (for example, less than 0.8 pixels). In the case of, even if these line points deviate from the line direction of the current line point by 90° or more, they may be considered as candidate connection positions. Accordingly, it is possible to prevent a phenomenon in which the line points are disconnected by connecting the line points so as to have straightness and omni-directionality.

본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법의 성능을 평가하기 위한 시뮬레이션을 수행하였다. 서브픽셀 라인위치 결정 방법의 테스트를 위해, 도 10에 도시된 바와 같이, 블러 인자(blurring factor)가 1 을 가지고, 다양한 라인 두께들, 라인 각도(line normal angle), 노이즈 세기(noise strength)를 가지는 라인 특징들을 포함하도록 영상들을 생성하였다. 도 10은 101×101 픽셀 크기를 가지는 4개의 모의 라인 이미지들의 예시도이다. 도 10의 (a) 내지 (d)에 도시된 4개의 모의 라인 이미지들의 라인 두께는 6 픽셀 크기, 노이즈 세기는 8/255, 라인 각도는 각각 0°, 23°, 47°, 82°이다. A simulation for evaluating the performance of the method for determining subpixel line positions according to an embodiment of the present invention was performed. For the test of the subpixel line positioning method, as shown in FIG. 10, the blurring factor is 1, and various line thicknesses, line normal angles, and noise strengths are determined. Branches created images to include line features. 10 is an exemplary diagram of four simulated line images having a size of 101×101 pixels. The line thickness of the four simulated line images shown in FIGS. 10A to 10D is 6 pixels, the noise intensity is 8/255, and the line angles are 0°, 23°, 47°, and 82°, respectively.

실험에 앞서, 먼저 영상 내 픽셀들의 그래디언트들을 기반으로 라인 픽셀들을 검출하였다. 일 예로, 라인 픽셀들은 인접한 픽셀들의 그래디언트 각도 차들의 합을 기반으로 선정될 수 있으나, 라인 픽셀들은 이러한 방법에 제한되지 않고 다양한 방법으로 선정될 수 있다. 라인 픽셀들은 픽셀 단위의 위치로 결정될 수 있다. 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법(이하, 'RSG'로 약칭될 수 있음)과의 비교를 위해, "An unbiased detector of curvilinear structures" (IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 20, no. 2, pp. 113-125, 1998, C. Steger)에 개시된 테일러 급수 근사법(Taylor series Approximation)(이하, 'TA'로 약칭될 수 있음)을 비교예로 하여 서브픽셀 라인위치를 결정하였다.Prior to the experiment, first, line pixels were detected based on the gradients of pixels in the image. For example, line pixels may be selected based on the sum of gradient angle differences of adjacent pixels, but line pixels are not limited to this method and may be selected in various ways. Line pixels may be determined based on a pixel-by-pixel position. For comparison with the subpixel line position determination method (hereinafter, may be abbreviated as'RSG') according to an embodiment of the present invention, "An unbiased detector of curvilinear structures" (IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 20, no. 2, pp. 113-125, 1998, C. Steger), the Taylor series Approximation (hereinafter, may be abbreviated as'TA') as a comparative example Was determined.

도 11은 본 발명의 실시예에 따라 서브픽셀 단위로 위치 결정된 라인점들을 나타낸 도면이다. 도 11의 (a) 내지 (f)는 각각 라인 두께가 1, 2, 3, 4, 6, 8 인 모의 영상들로, 노이즈 세기는 모두 30/255 이다. 도 11의 (a) 내지 (f)에서 라인 각도는 각각 0°, 15°, 30°, 45°, 60°, 75° 이다. 도 11의 (a) 내지 (f)에 도시된 영상들에서 적색 세모들은 본 발명의 실시예(RSG)에 따라 서브픽셀 단위로 위치 결정된 라인점들, 청색 네모들은 비교예(TA)에 따라 서브픽셀 단위로 위치 결정된 라인점들, 녹색 화살표들은 그레디언트 벡터들을 나타낸 것이다.11 is a diagram illustrating line points positioned in units of subpixels according to an embodiment of the present invention. 11A to 11F are simulated images with line thicknesses of 1, 2, 3, 4, 6, and 8, respectively, and noise intensity is all 30/255. In (a) to (f) of FIG. 11, the line angles are 0°, 15°, 30°, 45°, 60°, and 75°, respectively. In the images shown in FIGS. 11A to 11F, red triangles are line points positioned in sub-pixel units according to an embodiment (RSG) of the present invention, and blue squares are sub-pixels according to comparative example (TA). Line points and green arrows positioned in pixels indicate gradient vectors.

도 11에 도시된 결과로부터 본 발명의 실시예에 따른 서브픽셀 라인위치 결정 방법이 다양한 경우들에서 비교예(TA) 보다 우수한 라인점 위치 결정 성능을 갖는 것을 알 수 있다. 특히 라인 두께가 8 픽셀이고, 라인 각도가 75°인 도 11의 (f)와 같이 라인 신호가 상대적으로 약한 경우, 본 발명의 실시예에 따른 방법은 비교예보다 직진성을 가지는 것으로 정확하게 라인점들을 결정하였으며, 비교예보다 훨씬 높은 정확성을 가지는 것을 알 수 있다.It can be seen from the results shown in FIG. 11 that the subpixel line positioning method according to the embodiment of the present invention has superior line point positioning performance than the comparative example TA in various cases. In particular, when the line thickness is 8 pixels and the line signal is relatively weak as shown in Fig. 11(f) where the line angle is 75°, the method according to the embodiment of the present invention is more straightforward than the comparative example, and accurately calculates line points. Was determined, and it can be seen that it has much higher accuracy than the comparative example.

제곱근 평균 오차(RMSE; root mean squared errors)를 기반으로 본 발명의 실시예(RSG)와 비교예(TA)의 성능을 비교하여 도 12에 나타내었다. 도 12의 (a) 내지 (d)는 노이즈 크기가 10/255 인 경우이고, 도 12의 (e) 내지 (h)는 노이즈 크기가 30/255 인 경우이고, 도 12의 (i) 내지 (l)은 노이즈 크기가 60/255 인 경우이다. 도 12의 (a), (e), (i)는 라인 두께가 2 픽셀인 경우이고, 도 12의 (b), (f), (j)는 라인 두께가 4 픽셀인 경우이고, 도 12의 (c), (g), (k)는 라인 두께가 6 픽셀인 경우이고, 도 12의 (d), (h), (l)은 라인 두께가 8 픽셀인 경우이다. 본 발명의 실시예에 따른 방법(RSG)은 다양한 경우들에서 비교예(TA) 보다 낮은 RMSE를 나타냈으며, 특히 라인 두께가 크고 노이즈 크기가 커서 라인 특징이 상대적으로 약한 열악한 경우들에서 비교예(TA) 보다 라인점들의 위치들을 서브픽셀 단위로 보다 정확하게 측정하였다.Based on the root mean squared errors (RMSE), the performance of the Example (RSG) and Comparative Example (TA) of the present invention is compared and shown in FIG. 12. 12(a) to (d) show the case where the noise size is 10/255, FIGS. 12(e) to (h) show the case where the noise size is 30/255, and FIGS. 12(i) to ( l) is the case where the noise size is 60/255. 12(a), (e), and (i) show the case where the line thickness is 2 pixels, and FIGS. 12(b), (f), and (j) show the case where the line thickness is 4 pixels, and FIG. 12 (C), (g), and (k) of FIG. 12 are cases where the line thickness is 6 pixels, and (d), (h), and (l) of FIG. 12 are cases where the line thickness is 8 pixels. The method (RSG) according to the embodiment of the present invention exhibited a lower RMSE than the comparative example (TA) in various cases, and in particular, in the case of relatively weak line characteristics due to a large line thickness and a large noise size, the comparative example ( The positions of the line points were more accurately measured in units of subpixels than TA).

본 발명의 실시예에 따른 방법(RGS)와 비교예(TA)의 성능 평가를 위한 모의 실험을 하였다. 다양한 노이즈 크기와 라인 두께에 대해 RMSE들의 평균을 산출하여 도 13에 도시하였다. 도 13의 첫번째 열에 도시된 (a), (d), (g), (j)는 비교예(TA)에 대한 결과이고, 도 13의 두번째 열에 도시된 (b), (e), (h), (k)는 본 발명의 실시예(RSG)에 대한 결과이다. 도 13의 세번째 열에 도시된 (c), (f), (i), (l)은 비교예(TA)와 본 발명의 실시예(RSG)의 RMSE 평균값의 차이로서, Z축 값이 클수록 본 발명의 실시예(RSG)의 RMSE 평균값이 낮은 것, 다시 말해 본 발명의 실시예(RSG)의 성능이 비교예(TA) 보다 우수한 것을 의미한다.A simulation was conducted for evaluating the performance of the method (RGS) and the comparative example (TA) according to the embodiment of the present invention. The average of the RMSEs for various noise sizes and line thicknesses is calculated and shown in FIG. 13. (A), (d), (g), and (j) shown in the first column of FIG. 13 are results for Comparative Example (TA), and (b), (e), and (h) shown in the second column of FIG. ), (k) are the results for the embodiment of the present invention (RSG). (C), (f), (i), and (l) shown in the third column of FIG. 13 are differences between the average RMSE values of the comparative example (TA) and the example of the present invention (RSG). It means that the average RMSE value of the present embodiment (RSG) is low, that is, the performance of the present embodiment (RSG) is superior to that of the comparative example (TA).

도 13의 (a), (b), (c)는 평활 인자(smoothing factor)를 0.5 로 한 경우이고, 도 13의 (d), (e), (f)는 평활 인자를 0.75 로 한 경우이고, 도 13의 (g), (h), (i)는 평활 인자를 1.0 으로 한 경우이고, 도 13의 (j), (k), (l)은 평활 인자를 1.25 로 한 경우이다. 도 13에서 2개의 가로/세로 축들(σn, w)은 노이즈 크기와 라인 두께이다. 도 13의 도시로부터, 다양한 경우들에서 본 발명의 실시예에 따른 방법(RSG)이 비교예(TA) 보다 정확하게 라인점들의 위치를 결정할 수 있는 것을 알 수 있다. 본 발명의 실시예에 따른 방법(RSG)은 특히 노이즈 크기가 높은 경우에 비교예(TA) 보다 월등히 높은 성능을 나타내었다.(A), (b), and (c) of FIG. 13 are the cases where the smoothing factor is set to 0.5, and (d), (e), and (f) of Fig. 13 are the cases where the smoothing factor is set to 0.75. 13(g), (h), and (i) show the case where the smoothing factor is set to 1.0, and Fig. 13(j), (k), and (l) show the case where the smoothing factor is set to 1.25. In FIG. 13, two horizontal/vertical axes (σ n , w) are noise magnitude and line thickness. From the illustration of FIG. 13, it can be seen that in various cases, the method RSG according to the embodiment of the present invention can more accurately determine the position of the line points than the comparative example TA. The method (RSG) according to the embodiment of the present invention exhibited significantly higher performance than the comparative example (TA), especially when the noise level is high.

Figure pat00098
Figure pat00098

표 1은 다양한 평활 인자(σs)에 대하여, 본 발명의 실시예에 따른 방법(RSG)과 비교예(TA)의 연산 시간 성능과 RMSE 평균을 비교하여 나타낸 것이다. 평활 인자를 증가시킬수록, 연산 시간과 RMSE가 감소하는 이점이 있으나, 평활 인자를 증가시키면 영상에서의 특징들이 감소하게 되는 문제가 있다. 본 발명의 실시예에 따른 방법(RSG)은 특히 평활 인자가 낮은 경우에 비교예(TA) 보다 20% 이상 빠르고, 40% 이상 정확하게 서브픽셀 단위로 라인점들의 위치를 결정하였다. 따라서 본 발명의 실시예에 의하면, 낮은 평활 인자를 적용하여 영상에서 특징들이 손상되는 것을 방지하면서 라인들을 정확하게 검출할 수 있다.Table 1 shows the comparison of the calculation time performance and the RMSE average of the method RSG and the comparative example TA according to an embodiment of the present invention for various smoothing factors (σ s ). As the smoothing factor is increased, there is an advantage in that the operation time and RMSE are decreased. However, when the smoothing factor is increased, there is a problem that features in the image are decreased. The method (RSG) according to the embodiment of the present invention is 20% faster than that of the comparative example (TA), especially when the smoothing factor is low, and the position of the line points is accurately determined by subpixel units by 40% or more. Accordingly, according to an embodiment of the present invention, lines can be accurately detected while preventing features from being damaged in an image by applying a low smoothing factor.

도 14에 도시된 자연 이미지들(natural images)을 이용하여 본 발명의 서브픽셀 라인위치 결정 방법의 성능을 검증하기 위한 실험을 하였다. 도 14의 (a), (b)는 각각 잘 알려져 있는 "Lena" 이미지와, "Barbara" 이미지이다. 도 14의 (c), (d)는 DSLR 카메라로 각각 관목과, 건물 외관을 촬영한 "Shrub" 이미지와, "Facade" 이미지이다. 4개의 이미지들의 픽셀값 범위는 [0, 255] 이다. 자연 이미지들에 대한 서브픽셀 라인 위치 결정 실험을 하기에 앞서, 먼저 그래디언트 각도차들의 합을 기반으로 하는 라인 검출 방법으로 픽셀 단위의 라인 픽셀들을 검출하였다. 도 15는 본 발명의 실시예에 따라 검출된 라인 픽셀들을 나타낸 것이다. 흑색 세모들은 릿지에 해당하는 라인 픽셀들, 백색 세모들은 밸리에 해당하는 라인 픽셀들을 나타낸 것이다. 표 2는 검출된 라인 픽셀들의 개수를 나타낸 것이다.An experiment was conducted to verify the performance of the method for determining a subpixel line position of the present invention using natural images shown in FIG. 14. 14A and 14B are well-known images of "Lena" and "Barbara", respectively. 14C and 14D are "Shrub" images and "Facade" images of shrubs and buildings, respectively, taken with a DSLR camera. The range of pixel values for the four images is [0, 255]. Prior to the subpixel line positioning experiment for natural images, first, line pixels in pixel units were detected using a line detection method based on the sum of gradient angle differences. 15 illustrates detected line pixels according to an embodiment of the present invention. Black triangles represent line pixels corresponding to ridges, and white triangles represent line pixels corresponding to valleys. Table 2 shows the number of detected line pixels.

Figure pat00099
Figure pat00099

도 15에 도시된 바와 같이, 픽셀 정확도로 검출된 라인 특징들은 전형적으로 지그재그 형태를 갖는다. 본 발명의 실시예에 따른 방법(RSG)과 비교예의 방법(TA)으로 각각 자연 이미지들에 대해 검출된 라인 픽셀들을 기반으로 서브픽셀 라인위치를 결정하는 실험을 하였다. 이미지들은 1.0의 평활 인자로 노이즈 제거되었다. Sobel 연산자를 이용한 평활화된 이미지들의 컨볼루션에 의해 그래디언트들(1차 차분들)을 산출하였으며, Sobel 연산자를 이용한 1차 차분 이미지들의 컨볼루션에 의해 2차 차분들을 산출하였다.As shown in Fig. 15, line features detected with pixel accuracy typically have a zigzag shape. Experiments were conducted to determine sub-pixel line positions based on line pixels detected for natural images, respectively, by the method (RSG) according to the embodiment of the present invention and the method (TA) of the comparative example. Images were denoised with a smoothing factor of 1.0. Gradients (first-order differences) were calculated by convolution of smoothed images using Sobel operator, and second-order differences were calculated by convolution of first-order difference images using Sobel operator.

도 16은 본 발명의 실시예와 비교예의 라인 위치결정 결과를 나타낸 도면이다. 도 16에서 상/하방을 향하는 적색 세모들은 본 발명의 실시예(RSG)에 따라 검출된 라인점들, 상/하방을 향하는 청색 세모들은 비교예(TA)에 따라 검출된 라인점들이다. 또한, 도 16에서 상방을 향하는 청색/적색 세모들은 릿지 라인의 라인점들, 하방을 향하는 청색/적색 세모들은 밸리 라인의 라인점들이다. 본 발명의 실시예(RSG)는 라인점들이 연속적으로 이어지는 형태로 검출되었으며, 라인점들의 위치가 지그재그 형태가 아닌 직진성을 나타내는 위치들로 검출되었다.16 is a diagram showing a result of line positioning in an embodiment of the present invention and a comparative example. In FIG. 16, red triangles facing upward/downward are detected according to an embodiment (RSG) of the present invention, and blue triangles facing upward/downward are detected according to Comparative Example (TA). In addition, in FIG. 16, blue/red triangles facing upward are line points of a ridge line, and blue/red triangles facing downward are line points of a valley line. In the embodiment of the present invention (RSG), the line points were detected in a continuous line, and the positions of the line points were detected as positions indicating straightness rather than a zigzag shape.

심한 노이즈 조건 하에서 본 발명의 실시예(RSG)와 비교예(TA)의 성능 비교를 위해, 노이즈 크기가 10인 랜덤 가우시안 노이즈를 원본 이미지들에 추가한 다음, 노이즈 이미지들을 1.0의 평활 인자로 평활화하였다. 이어서, 본 발명의 실시예(RSG)와 비교예(TA)에 의해, 평활화된 이미지들에 대해 서브픽셀 라인위치를 검출하였으며, 검출된 라인점들을 도 17에 도시하였다. 도 17에서 상/하방을 향하는 적색 세모들은 본 발명의 실시예(RSG)에 따라 검출된 라인점들, 상/하방을 향하는 청색 세모들은 비교예(TA)에 따라 검출된 라인점들이다. 또한, 도 17에서 상방을 향하는 청색/적색 세모들은 릿지 라인의 라인점들, 하방을 향하는 청색/적색 세모들은 밸리 라인의 라인점들이다.To compare the performance of the present invention (RSG) and the comparative example (TA) under severe noise conditions, random Gaussian noise having a noise size of 10 is added to the original images, and then the noise images are smoothed with a smoothing factor of 1.0. I did. Subsequently, the subpixel line positions were detected for smoothed images by the embodiment (RSG) and the comparative example (TA) of the present invention, and the detected line points are shown in FIG. 17. In FIG. 17, red triangles facing upward/downward are detected according to an embodiment (RSG) of the present invention, and blue triangles facing upward/downward are detected according to Comparative Example (TA). In addition, in FIG. 17, blue/red triangles facing upward are line points of a ridge line, and blue/red triangles facing downward are line points of a valley line.

도 17에 도시된 바와 같이, 본 발명의 실시예(RSG)에 따라 서브픽셀 라인위치를 검출한 경우, 라인점들의 위치가 평활화된 이미지에서 시각적으로 검출될 수 있는 라인 특징들에 잘 부합하였다. 노이즈 레벨의 변동에 의한 영향을 평가하기 위하여, 랜덤 가우시안 노이즈를 추가하여 다양한 노이즈 레벨(5, 10, 15, 20, 30)을 갖는 노이즈 이미지들을 생성하였다. 표 3은 자연 이미지들에 대한 평균 거리를 나타낸 것이다.As shown in FIG. 17, when the subpixel line positions are detected according to the embodiment of the present invention (RSG), the positions of the line points correspond well to line features that can be visually detected in the smoothed image. In order to evaluate the effect of the fluctuation of the noise level, noise images having various noise levels (5, 10, 15, 20, 30) were generated by adding random Gaussian noise. Table 3 shows the average distances for natural images.

Figure pat00100
Figure pat00100

d1 내지 d6는 각각 아래의 수식과 같다. Each of d1 to d6 is as follows.

Figure pat00101
Figure pat00101

Figure pat00102
은 노이즈가 없는 이미지에 대해 비교예(TA)에 의해 검출한 라인점의 위치,
Figure pat00103
은 노이즈가 없는 이미지에 대해 본 발명의 실시예(RSG)에 의해 검출한 라인점의 위치,
Figure pat00104
은 노이즈가 있는 이미지에 대해 비교예(TA)에 의해 검출한 라인점의 위치,
Figure pat00105
은 노이즈가 없는 이미지에 대해 본 발명의 실시예(RSG)에 의해 검출한 라인점의 위치를 나타낸다. 표 3에서, d1 내지 d6 앞에 기재된 'R', 'V'는 각각 릿지 라인과 밸리 라인을 나타낸다. 표 3에 도시된 바와 같이, 평균 거리 d1 은 Lena, Barbara, Shrub 이미지들에서 약 0.5 픽셀, Facade 이미지에서 약 0.36 이었다. 평균 거리 d3 은 모든 노이즈 및 자연 이미지들에서 평균 거리 d2 보다 약 30% 정도 작고, 평균 거리 d5 는 모든 경우에서 평균 거리 d4 보다 작으며, 평균 거리 d6은 0.52 ~ 1.17 픽셀 범위인 것을 알 수 있다. 이는 본 발명의 실시예(RSG)에 의하면 다양한 노이즈 레벨에서 비교예(TA) 보다 정확하고 안정적으로 라인위치를 결정할 수 있으며, 다양한 신호 및 노이즈 레벨 하에서 정확한 이미지 처리가 가능한 것을 의미한다.
Figure pat00102
Is the position of the line point detected by Comparative Example (TA) for an image without noise,
Figure pat00103
Is the position of the line point detected by the embodiment of the present invention (RSG) for an image without noise,
Figure pat00104
Is the position of the line point detected by Comparative Example (TA) for the image with noise,
Figure pat00105
Represents the position of the line point detected by the embodiment of the present invention (RSG) for a noise-free image. In Table 3,'R'and'V' described in front of d1 to d6 represent a ridge line and a valley line, respectively. As shown in Table 3, the average distance d1 was about 0.5 pixels in the Lena, Barbara, and Shrub images, and about 0.36 in the Facade images. It can be seen that the average distance d3 is about 30% smaller than the average distance d2 in all noise and natural images, the average distance d5 is less than the average distance d4 in all cases, and the average distance d6 is in the range of 0.52 to 1.17 pixels. This means that according to the embodiment (RSG) of the present invention, the line position can be determined more accurately and stably than the comparative example (TA) at various noise levels, and accurate image processing is possible under various signal and noise levels.

Lena 이미지와 Barbara 이미지에 대해 라인점들을 연결하는 실험을 수행하였다. 도 18은 본 발명의 실시예와 비교예에 따라 라인점들을 연결하여 라인을 생성한 결과를 나타낸 도면이다. 도 18에서 상부의 4개의 이미지들은 비교예(TA)에 의해 라인점들을 연결하여 생성된 라인들을 나타낸 것이고, 하부의 4개의 이미지들은 본 발명의 실시예(RSG)에 의해 라인점들을 연결하여 생성된 라인들을 나타낸 것이다. 도 18에서 녹색선은 릿지 라인, 황색선은 밸리 라인을 나타낸다. 5개 보다 작은 라인점들로 이루어진 라인들은 도 18에 도시하지 않았다.An experiment was performed to connect line points for the Lena image and the Barbara image. 18 is a view showing a result of generating a line by connecting line points according to an embodiment and a comparative example of the present invention. In FIG. 18, the upper four images represent lines generated by connecting line points according to Comparative Example (TA), and the lower four images are generated by connecting line points according to the embodiment of the present invention (RSG). This is the displayed lines. In FIG. 18, a green line represents a ridge line and a yellow line represents a valley line. Lines consisting of less than 5 line points are not shown in FIG. 18.

도 18의 도시로부터, 본 발명의 실시예에 따라 라인점들을 연결하여 라인들을 연결한 경우, 비교예(TA)에 의해 생성된 라인들 보다 긴 라인들을 생성할 수 있음을 알 수 있다. 비교예(TA)의 경우, 본 발명의 실시예와 비교하여 라인들이 생략된 부분들이 다수 발견된다. 본 발명의 실시예에 의해 생성된 라인들이 비교예의 경우보다 긴 이유는 비교예 보다 높은 직진성(straightnes) 및 전방향성(omni-directionality)을 갖기 때문이다.From the illustration of FIG. 18, it can be seen that when lines are connected by connecting line points according to an embodiment of the present invention, longer lines than the lines generated by the comparative example TA can be generated. In the case of the comparative example TA, a number of portions in which lines are omitted are found compared to the embodiment of the present invention. The reason that the lines generated by the embodiment of the present invention are longer than that of the comparative example is that they have higher straightness and omni-directionality than that of the comparative example.

본 발명의 실시예에 따른 방법 중 적어도 일부는 컴퓨터에서 실행될 수 있는 프로그램으로 작성 가능하고, 컴퓨터로 읽을 수 있는 기록매체를 이용하여 상기 프로그램을 동작시키는 범용 디지털 컴퓨터에서 구현될 수 있다. 컴퓨터로 읽을 수 있는 기록매체는 SRAM(Static RAM), DRAM(Dynamic RAM), SDRAM(Synchronous DRAM) 등과 같은 휘발성 메모리, ROM(Read Only Memory), PROM(Programmable ROM), EPROM(Electrically Programmable ROM), EEPROM(Electrically Erasable and Programmable ROM), 플래시 메모리 장치, PRAM(Phase-change RAM), MRAM(Magnetic RAM), RRAM(Resistive RAM), FRAM(Ferroelectric RAM)과 같은 불휘발성 메모리, 플로피 디스크, 하드 디스크 또는 광학적 판독 매체 예를 들어 시디롬, 디브이디 등과 같은 형태의 저장매체일 수 있으나, 이에 제한되지는 않는다.At least some of the methods according to the embodiments of the present invention can be written in a program that can be executed on a computer, and can be implemented in a general-purpose digital computer that operates the program using a computer-readable recording medium. Computer-readable recording media include volatile memories such as SRAM (Static RAM), DRAM (Dynamic RAM), SDRAM (Synchronous DRAM), Read Only Memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Nonvolatile memory such as Electrically Erasable and Programmable ROM (EEPROM), flash memory device, phase-change RAM (PRAM), magnetic RAM (MRAM), resistive RAM (RRAM), ferroelectric RAM (FRAM), floppy disk, hard disk, or The optical reading medium may be, for example, a storage medium in the form of a CD-ROM or a DVD, but is not limited thereto.

이상의 실시예들은 본 발명의 이해를 돕기 위하여 제시된 것으로, 본 발명의 범위를 제한하지 않으며, 이로부터 다양한 변형 가능한 실시예들도 본 발명의 범위에 속하는 것임을 이해하여야 한다. 본 발명의 기술적 보호범위는 청구범위의 기술적 사상에 의해 정해져야 할 것이며, 본 발명의 기술적 보호범위는 청구범위의 문언적 기재 그 자체로 한정되는 것이 아니라 실질적으로는 기술적 가치가 균등한 범주의 발명까지 미치는 것임을 이해하여야 한다.It should be understood that the above embodiments have been presented to aid the understanding of the present invention, and do not limit the scope of the present invention, and various deformable embodiments are also within the scope of the present invention. The technical protection scope of the present invention should be determined by the technical idea of the claims, and the technical protection scope of the present invention is not limited to the literal description of the claims per se, but the invention of the scope of which the technical value is substantially equal. It should be understood that it extends to.

10: 서브픽셀 라인위치 결정 장치
100: 윈도우 설정부
200: 그래디언트 산출부
300: 정규화부
320: 그래디언트 합산부
340: 그래디언트 크기 산출부
360: 그래디언트 크기 합산부
380: 서브픽셀 변위 산출부
400: 서브픽셀 라인위치 결정부
500: 라인 연결부
510: 거리 산출부
520: 각도 산출부
530: 각도차 산출부
540: 연결거리 산출부
550: 라인점 결정부
10: subpixel line positioning device
100: window setting unit
200: gradient calculation unit
300: normalization unit
320: gradient summing section
340: gradient size calculation unit
360: gradient size summing section
380: subpixel displacement calculation unit
400: subpixel line position determining unit
500: line connection
510: distance calculation unit
520: angle calculation unit
530: angle difference calculation unit
540: connection distance calculation unit
550: line point determination unit

Claims (18)

영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 상기 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 결정하는 서브픽셀 라인위치 결정 방법으로서,
그래디언트 산출부에 의해, 상기 라인픽셀 및 상기 라인픽셀에 인접한 주변픽셀들을 포함하는 픽셀들에 대해, 인접한 픽셀들 간의 픽셀값 차이와 관련된 그래디언트들을 산출하는 단계;
정규화부에 의해, 상기 픽셀들의 그래디언트들의 크기들을 산출하고, 상기 라인픽셀의 위치에 대한 서브픽셀 레벨 변위를 산출하기 위해 상기 픽셀들의 그래디언트들의 크기들을 기반으로 상기 픽셀들의 그래디언트들을 정규화하는 단계; 및
서브픽셀 라인위치 결정부에 의해, 상기 라인픽셀의 위치 및 상기 서브픽셀 레벨 변위를 기반으로 서브픽셀 레벨로 상기 라인점의 위치를 결정하는 단계를 포함하는 서브픽셀 라인위치 결정 방법.
A subpixel line position determination method for determining a position of a line point corresponding to the line at a subpixel level from a position of a line pixel determined at a pixel level related to a line in an image,
Calculating gradients related to a pixel value difference between the adjacent pixels for pixels including the line pixel and adjacent pixels adjacent to the line pixel, by a gradient calculator;
Normalizing, by a normalizing unit, the gradients of the pixels based on the sizes of the gradients of the pixels to calculate the sizes of the gradients of the pixels and calculate the subpixel level displacement with respect to the position of the line pixel; And
And determining, by a subpixel line position determining unit, a position of the line point at a subpixel level based on the position of the line pixel and the subpixel level displacement.
제1항에 있어서,
상기 라인점의 위치를 결정하는 단계는,
상기 라인픽셀의 위치와 상기 서브픽셀 레벨 변위를 합산하여 상기 라인점의 위치를 서브픽셀 레벨로 결정하는 단계를 포함하는 서브픽셀 라인위치 결정 방법.
The method of claim 1,
The step of determining the position of the line point,
And determining the position of the line point as a sub-pixel level by summing the position of the line pixel and the sub-pixel level displacement.
제1항에 있어서,
상기 픽셀들의 그래디언트들을 정규화하는 단계는,
그래디언트 합산부에 의해, 상기 픽셀들의 그래디언트들을 합산하여 합산 그래디언트를 산출하는 단계;
그래디언트 크기 산출부에 의해, 상기 픽셀들의 그래디언트들의 크기들을 산출하는 단계;
그래디언트 크기 합산부에 의해, 상기 픽셀들의 그래디언트들의 크기들을 합산하여 그래디언트 합산 크기를 산출하는 단계; 및
서브픽셀 변위 산출부에 의해, 상기 그래디언트 합산 크기에 의해 상기 합산 그래디언트를 정규화하여 상기 서브픽셀 레벨 변위를 산출하는 단계를 포함하는 서브픽셀 라인위치 결정 방법.
The method of claim 1,
Normalizing the gradients of the pixels,
Calculating a sum gradient by summing the gradients of the pixels by a gradient summing unit;
Calculating sizes of gradients of the pixels by a gradient size calculator;
Calculating a summed gradient size by summing the sizes of the gradients of the pixels by a gradient size summation unit; And
And calculating the subpixel level displacement by normalizing the sum gradient based on the summed gradient size by a subpixel displacement calculator.
제3항에 있어서,
윈도우 설정부에 의해, 상기 영상에서 상기 라인픽셀의 위치로부터 상기 라인점의 위치를 결정하기 위한 픽셀들을 결정하는 단계를 더 포함하고,
상기 픽셀들을 결정하는 단계는 상기 라인픽셀을 중심으로 (2K + 1) × (2K + 1) 픽셀 크기를 가지는 윈도우를 설정하고, 상기 윈도우 내의 픽셀들을 결정하는 단계를 포함하고, 상기 K는 양의 정수인 서브픽셀 라인위치 결정 방법.
The method of claim 3,
Further comprising, by a window setting unit, determining pixels for determining the position of the line point from the position of the line pixel in the image,
The determining of the pixels includes setting a window having a (2K + 1) × (2K + 1) pixel size around the line pixel, and determining pixels within the window, wherein K is a positive A method of determining subpixel line position, which is an integer.
제4항에 있어서,
상기 합산 그래디언트를 산출하는 단계는,
행 방향 그래디언트 합산부에 의해, 상기 픽셀들의 행 방향 그래디언트들을 합산하여 행 방향 합산 그래디언트를 산출하는 단계; 및
열 방향 그래디언트 합산부에 의해, 상기 픽셀들의 열 방향 그래디언트들을 합산하여 열 방향 합산 그래디언트를 산출하는 단계를 포함하고,
상기 그래디언트들의 크기들을 산출하는 단계는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 산출하고,
상기 그래디언트 합산 크기를 산출하는 단계는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 기반으로 상기 그래디언트 합산 크기를 산출하고,
상기 서브픽셀 레벨 변위를 산출하는 단계는,
행 방향 변위 산출부에 의해, 상기 행 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 행 방향 서브픽셀 레벨 변위를 산출하는 단계; 및
열 방향 변위 산출부에 의해, 상기 열 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 열 방향 서브픽셀 레벨 변위를 산출하는 단계를 포함하고,
상기 라인점의 위치를 결정하는 단계는,
상기 라인픽셀의 행 방향 위치와 상기 행 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 행 방향 위치를 서브픽셀 레벨로 결정하는 단계; 및
상기 라인픽셀의 열 방향 위치와 상기 열 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 열 방향 위치를 서브픽셀 레벨로 결정하는 단계를 포함하는 서브픽셀 라인위치 결정 방법.
The method of claim 4,
The step of calculating the summation gradient,
Calculating a row direction sum gradient by summing the row direction gradients of the pixels by a row direction gradient summing unit; And
Comprising a column direction summation gradient by summing the column direction gradients of the pixels by a column direction gradient summing unit,
In the calculating of the sizes of the gradients, the sizes of the row direction gradients and the column direction gradients are calculated,
In the calculating of the summed gradient size, the summed gradient size is calculated based on the sizes of the row direction gradients and the column direction gradients,
The step of calculating the subpixel level displacement,
Calculating a subpixel level displacement in a row direction by dividing the summed gradient in the row direction by the summed gradient size by a row direction displacement calculator; And
Comprising a column direction subpixel level displacement by dividing the column direction sum gradient by the gradient sum size by a column direction displacement calculation unit,
The step of determining the position of the line point,
Determining a row direction position of the line point as a subpixel level by summing the row direction position of the line pixel and the row direction subpixel level displacement; And
And determining the position in the column direction of the line point as a sub-pixel level by summing the position in the column direction of the line pixel and the level displacement in the column direction.
제5항에 있어서,
상기 픽셀들의 그래디언트들을 정규화하는 단계는,
상기 라인픽셀의 상태가 릿지(ridge)인 경우, 상기 그래디언트 합산 크기에 제1 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하는 단계; 및
상기 라인픽셀의 상태가 밸리(valley)인 경우, 상기 그래디언트 합산 크기에 상기 제1 부호와 상이한 제2 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하는 단계를 포함하는 서브픽셀 라인위치 결정 방법.
The method of claim 5,
Normalizing the gradients of the pixels,
When the state of the line pixel is a ridge, normalizing the gradients of the pixels by applying a first sign to the sum of the gradients; And
And normalizing the gradients of the pixels by applying a second sign different from the first sign to the sum of the gradients when the state of the line pixel is a valley.
제6항에 있어서,
상기 합산 그래디언트를 산출하는 단계는 하기의 수식 1에 따라 상기 행 방향 합산 그래디언트 및 상기 열 방향 합산 그래디언트를 산출하고,
상기 그래디언트 합산 크기를 산출하는 단계는 하기의 수식 2에 따라 상기 그래디언트 합산 크기를 산출하고,
상기 서브픽셀 레벨 변위를 산출하는 단계는 하기의 수식 3 및 수식 4에 따라 상기 서브픽셀 레벨 변위를 산출하고,
상기 라인점의 위치를 결정하는 단계는 하기의 수식 5에 따라 상기 라인점의 위치를 결정하고,
[수식 1]
Figure pat00106

[수식 2]
Figure pat00107

[수식 3]
Figure pat00108

[수식 4]
Figure pat00109

[수식 5]
Figure pat00110

상기 수식 1 내지 수식 5에서,
Figure pat00111
는 상기 행 방향 합산 그래디언트,
Figure pat00112
는 상기 열 방향 합산 그래디언트,
Figure pat00113
는 행 방향 그래디언트,
Figure pat00114
는 열 방향 그래디언트,
Figure pat00115
는 상기 그래디언트 합산 크기,
Figure pat00116
는 상기 라인픽셀의 상태가 릿지인지 밸리인지를 나타내는 정보,
Figure pat00117
는 상기 행 방향 서브픽셀 레벨 변위,
Figure pat00118
는 상기 열 방향 서브픽셀 레벨 변위, c는 상기 라인픽셀의 열 방향 좌표, r은 상기 라인픽셀의 행 방향 좌표,
Figure pat00119
는 상기 라인점의 행 방향 위치,
Figure pat00120
는 상기 라인점의 열 방향 위치를 나타내는 서브픽셀 라인위치 결정 방법.
The method of claim 6,
In the calculating of the summation gradient, the row direction summation gradient and the column direction summation gradient are calculated according to Equation 1 below,
In the calculating of the summed gradient size, the summed gradient size was calculated according to Equation 2 below,
In the calculating of the subpixel level displacement, the subpixel level displacement is calculated according to Equations 3 and 4 below,
The step of determining the position of the line point is to determine the position of the line point according to Equation 5 below,
[Equation 1]
Figure pat00106

[Equation 2]
Figure pat00107

[Equation 3]
Figure pat00108

[Equation 4]
Figure pat00109

[Equation 5]
Figure pat00110

In Equations 1 to 5,
Figure pat00111
Is the sum gradient in the row direction,
Figure pat00112
Is the summation gradient in the column direction,
Figure pat00113
Is the row direction gradient,
Figure pat00114
Is the column direction gradient,
Figure pat00115
Is the sum of the gradients,
Figure pat00116
Is information indicating whether the state of the line pixel is ridge or valley,
Figure pat00117
Is the subpixel level displacement in the row direction,
Figure pat00118
Is the column direction subpixel level displacement, c is the column direction coordinate of the line pixel, r is the row direction coordinate of the line pixel,
Figure pat00119
Is the row direction position of the line point,
Figure pat00120
Is a method of determining a subpixel line position indicating a position of the line point in the column direction.
제1항에 있어서,
라인 연결부에 의해, 상기 영상에서 라인을 생성하기 위해 상기 라인점들을 연결하는 단계를 더 포함하고,
상기 라인점들을 연결하는 단계는,
상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점들 간의 좌표 거리들, 그리고 상기 제1 라인점과 상기 제2 라인점들 간의 각도들을 기반으로 상기 제2 라인점들 중 상기 제1 라인점과 연결할 라인점을 결정하는 서브픽셀 라인위치 결정 방법.
The method of claim 1,
The step of connecting the line points to generate a line in the image by a line connector, further comprising,
The step of connecting the line points,
Based on the coordinate distances between the first line point included in the line and the second line points in the vicinity of the first line point among the line points, and the angles between the first line point and the second line point And determining a line point to be connected to the first line point among the second line points.
제8항에 있어서,
상기 라인점들을 연결하는 단계는,
거리 산출부에 의해, 상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점 간의 좌표 거리를 산출하는 단계;
각도 산출부에 의해, 상기 제1 라인점에서의 상기 라인의 제1 각도를 산출하고, 상기 제1 라인점과 상기 제2 라인점 간의 제2 각도를 산출하는 단계;
각도차 산출부에 의해, 상기 제1 각도와 상기 제2 각도 간의 각도차를 산출하는 단계;
연결거리 산출부에 의해, 상기 좌표 거리 및 상기 각도차를 기반으로 상기 제1 라인점과 상기 제2 라인점 간의 연결거리를 산출하는 단계; 및
라인점 결정부에 의해, 상기 제2 라인점들 중 상기 제1 라인점과 가장 연결거리가 작은 라인점을 결정하여 상기 제1 라인점과 연결하는 단계를 포함하는 서브픽셀 라인위치 결정 방법.
The method of claim 8,
The step of connecting the line points,
Calculating a coordinate distance between a first line point included in the line and a second line point near the first line point among the line points, by a distance calculator;
Calculating a first angle of the line at the first line point by an angle calculator, and calculating a second angle between the first line point and the second line point;
Calculating an angle difference between the first angle and the second angle by an angle difference calculator;
Calculating, by a connection distance calculator, a connection distance between the first line point and the second line point based on the coordinate distance and the angle difference; And
And determining, by a line point determining unit, a line point having a smallest connection distance to the first line point among the second line points and connecting the line point to the first line point.
제9항에 있어서,
상기 좌표 거리를 산출하는 단계는 하기의 수식 6에 따라 상기 좌표 거리를 산출하고,
상기 제2 각도를 산출하는 단계는 하기의 수식 7에 따라 상기 제2 각도를 산출하고,
상기 각도차를 산출하는 단계는 하기의 수식 8에 따라 상기 각도차를 산출하고,
상기 연결거리를 산출하는 단계는 하기의 수식 9 및 수식 10에 따라 상기 연결거리를 산출하고,
[수식 6]
Figure pat00121

[수식 7]
Figure pat00122

[수식 8]
Figure pat00123

[수식 9]
Figure pat00124

[수식 10]
Figure pat00125

상기 수식 6 내지 수식 10에서,
Figure pat00126
은 상기 좌표 거리,
Figure pat00127
는 상기 제1 라인점의 행 방향 좌표,
Figure pat00128
는 상기 제1 라인점의 열 방향 좌표,
Figure pat00129
는 상기 제2 라인점의 행 방향 좌표,
Figure pat00130
는 상기 제2 라인점의 열 방향 좌표,
Figure pat00131
는 상기 각도차,
Figure pat00132
는 상기 제1 각도,
Figure pat00133
는 상기 제2 각도,
Figure pat00134
는 설정된 각도차 반영 인자,
Figure pat00135
는 상기 각도차에 따라 결정되는 각도거리,
Figure pat00136
는 상기 연결거리를 나타내는 서브픽셀 라인위치 결정 방법.
The method of claim 9,
In the calculating of the coordinate distance, the coordinate distance is calculated according to Equation 6 below,
In the calculating of the second angle, the second angle is calculated according to Equation 7 below,
In the calculating of the angle difference, the angle difference is calculated according to Equation 8 below,
In the calculating of the connection distance, the connection distance is calculated according to Equations 9 and 10 below,
[Equation 6]
Figure pat00121

[Equation 7]
Figure pat00122

[Equation 8]
Figure pat00123

[Equation 9]
Figure pat00124

[Equation 10]
Figure pat00125

In Equations 6 to 10,
Figure pat00126
Is the coordinate distance,
Figure pat00127
Is the row direction coordinate of the first line point,
Figure pat00128
Is the column direction coordinate of the first line point,
Figure pat00129
Is the row direction coordinate of the second line point,
Figure pat00130
Is the column direction coordinate of the second line point,
Figure pat00131
Is the angle difference,
Figure pat00132
Is the first angle,
Figure pat00133
Is the second angle,
Figure pat00134
Is the set angle difference reflection factor,
Figure pat00135
Is the angular distance determined according to the angular difference,
Figure pat00136
Is a method of determining a subpixel line position indicating the connection distance.
제1항 내지 제10항 중 어느 한 항에 기재된 서브픽셀 라인위치 결정 방법을 실행하기 위한 프로그램이 기록된 컴퓨터로 판독 가능한 기록 매체.A computer-readable recording medium on which a program for executing the subpixel line positioning method according to any one of claims 1 to 10 is recorded. 영상에서 라인에 관련된 픽셀 레벨로 결정된 라인픽셀의 위치로부터 상기 라인에 대응되는 라인점의 위치를 서브픽셀 레벨로 결정하기 위한 서브픽셀 라인위치 결정 장치로서,
상기 라인픽셀 및 상기 라인픽셀에 인접한 주변픽셀들을 포함하는 픽셀들에 대해, 인접한 픽셀들 간의 픽셀값 차이와 관련된 그래디언트들을 산출하는 그래디언트 산출부;
상기 픽셀들의 그래디언트들의 크기들을 산출하고, 상기 라인픽셀의 위치에 대한 서브픽셀 레벨 변위를 산출하기 위해 상기 픽셀들의 그래디언트들의 크기들을 기반으로 상기 픽셀들의 그래디언트들을 정규화하는 정규화부; 및
상기 라인픽셀의 위치 및 상기 서브픽셀 레벨 변위를 기반으로 서브픽셀 레벨로 상기 라인점의 위치를 결정하는 서브픽셀 라인위치 결정부를 포함하는 서브픽셀 라인위치 결정 장치.
A subpixel line position determining device for determining a position of a line point corresponding to the line at a subpixel level from a position of a line pixel determined at a pixel level related to a line in an image,
A gradient calculator configured to calculate gradients related to a pixel value difference between adjacent pixels for pixels including the line pixel and adjacent pixels adjacent to the line pixel;
A normalization unit that normalizes the gradients of the pixels based on the sizes of the gradients of the pixels to calculate the sizes of the gradients of the pixels and to calculate the subpixel level displacement with respect to the position of the line pixel; And
And a subpixel line position determining unit configured to determine a position of the line point at a subpixel level based on the position of the line pixel and the subpixel level displacement.
제12항에 있어서,
상기 정규화부는,
상기 픽셀들의 그래디언트들을 합산하여 합산 그래디언트를 산출하는 그래디언트 합산부;
상기 픽셀들의 그래디언트들의 크기들을 산출하는 그래디언트 크기 산출부;
상기 픽셀들의 그래디언트들의 크기들을 합산하여 그래디언트 합산 크기를 산출하는 그래디언트 크기 합산부; 및
상기 그래디언트 합산 크기에 의해 상기 합산 그래디언트를 정규화하여 상기 서브픽셀 레벨 변위를 산출하는 서브픽셀 변위 산출부를 포함하고,
상기 서브픽셀 라인위치 결정부는,
상기 라인픽셀의 위치와 상기 서브픽셀 레벨 변위를 합산하여 상기 라인점의 위치를 서브픽셀 레벨로 결정하는 서브픽셀 라인위치 결정 장치.
The method of claim 12,
The normalization unit,
A gradient summing unit for calculating a sum gradient by summing the gradients of the pixels;
A gradient size calculator that calculates the sizes of the gradients of the pixels;
A gradient size summing unit for calculating a summed gradient size by summing the sizes of the gradients of the pixels; And
And a subpixel displacement calculator configured to calculate the subpixel level displacement by normalizing the summed gradient based on the summed gradient size,
The subpixel line position determining unit,
A subpixel line position determining apparatus configured to determine the position of the line point as a subpixel level by summing the position of the line pixel and the subpixel level displacement.
제13항에 있어서,
상기 영상에서 상기 라인픽셀의 위치로부터 상기 라인점의 위치를 결정하기 위한 픽셀들을 결정하는 윈도우 설정부를 더 포함하고,
상기 윈도우 설정부는, 상기 라인픽셀을 중심으로 (2K + 1) × (2K + 1) 픽셀 크기를 가지는 윈도우를 설정하고, 상기 윈도우 내의 픽셀들을 결정하고, 상기 K는 양의 정수인 서브픽셀 라인위치 결정 장치.
The method of claim 13,
Further comprising a window setting unit for determining pixels for determining the position of the line point from the position of the line pixel in the image,
The window setting unit sets a window having a (2K + 1) × (2K + 1) pixel size around the line pixel, determines pixels in the window, and determines the subpixel line position where K is a positive integer. Device.
제14항에 있어서,
상기 그래디언트 합산부는,
상기 픽셀들의 행 방향 그래디언트들을 합산하여 행 방향 합산 그래디언트를 산출하는 행 방향 그래디언트 합산부; 및
상기 픽셀들의 열 방향 그래디언트들을 합산하여 열 방향 합산 그래디언트를 산출하는 열 방향 그래디언트 합산부를 포함하고,
상기 그래디언트 크기 산출부는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 산출하고,
상기 그래디언트 크기 합산부는 상기 행 방향 그래디언트들의 크기들 및 상기 열 방향 그래디언트들의 크기들을 기반으로 상기 그래디언트 합산 크기를 산출하고,
상기 서브픽셀 변위 산출부는,
상기 행 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 행 방향 서브픽셀 레벨 변위를 산출하는 행 방향 변위 산출부; 및
상기 열 방향 합산 그래디언트를 상기 그래디언트 합산 크기로 나누어 열 방향 서브픽셀 레벨 변위를 산출하는 열 방향 변위 산출부를 포함하고,
상기 서브픽셀 라인위치 결정부는,
상기 라인픽셀의 행 방향 위치와 상기 행 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 행 방향 위치를 서브픽셀 레벨로 결정하고; 그리고
상기 라인픽셀의 열 방향 위치와 상기 열 방향 서브픽셀 레벨 변위를 합산하여 상기 라인점의 열 방향 위치를 서브픽셀 레벨로 결정하는 서브픽셀 라인위치 결정 장치.
The method of claim 14,
The gradient summing unit,
A row direction gradient summing unit for calculating a row direction sum gradient by summing the row direction gradients of the pixels; And
A column direction gradient summing unit configured to calculate a column direction sum gradient by summing the column direction gradients of the pixels,
The gradient size calculator calculates sizes of the row direction gradients and the column direction gradients,
The gradient size summation unit calculates the summed gradient size based on the sizes of the row direction gradients and the column direction gradients,
The subpixel displacement calculating unit,
A row direction displacement calculator configured to calculate a row direction subpixel level displacement by dividing the row direction sum gradient by the gradient sum size; And
A column direction displacement calculator configured to calculate a column direction subpixel level displacement by dividing the column direction sum gradient by the gradient sum size,
The subpixel line position determining unit,
Determining a row direction position of the line point as a subpixel level by summing the row direction position of the line pixel and the row direction subpixel level displacement; And
A subpixel line position determining device configured to determine a position in the column direction of the line point as a subpixel level by summing the position in the column direction of the line pixel and the level displacement in the column direction.
제15항에 있어서,
상기 정규화부는,
상기 라인픽셀의 상태가 릿지(ridge)인 경우, 상기 그래디언트 합산 크기에 제1 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하고; 그리고
상기 라인픽셀의 상태가 밸리(valley)인 경우, 상기 그래디언트 합산 크기에 상기 제1 부호와 상이한 제2 부호를 적용하여 상기 픽셀들의 그래디언트들을 정규화하는 서브픽셀 라인위치 결정 장치.
The method of claim 15,
The normalization unit,
When the state of the line pixel is ridge, normalizing the gradients of the pixels by applying a first sign to the sum of the gradients; And
When the state of the line pixel is a valley, the subpixel line positioning apparatus normalizes the gradients of the pixels by applying a second sign different from the first sign to the sum of the gradients.
제12항에 있어서,
상기 영상에서 라인을 생성하기 위해 상기 라인점들을 연결하는 라인 연결부를 더 포함하고,
상기 라인 연결부는,
상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점들 간의 좌표 거리들, 그리고 상기 제1 라인점과 상기 제2 라인점들 간의 각도들을 기반으로 상기 제2 라인점들 중 상기 제1 라인점과 연결할 라인점을 결정하는 서브픽셀 라인위치 결정 장치.
The method of claim 12,
Further comprising a line connector connecting the line points to generate a line in the image,
The line connection part,
Based on the coordinate distances between the first line point included in the line and the second line points in the vicinity of the first line point among the line points, and the angles between the first line point and the second line point A subpixel line position determining device configured to determine a line point to be connected to the first line point among the second line points.
제17항에 있어서,
상기 라인 연결부는,
상기 라인에 포함된 제1 라인점과, 상기 라인점들 중 상기 제1 라인점 근방의 제2 라인점 간의 좌표 거리를 산출하는 거리 산출부;
상기 제1 라인점에서의 상기 라인의 제1 각도를 산출하고, 상기 제1 라인점과 상기 제2 라인점 간의 제2 각도를 산출하는 각도 산출부;
상기 제1 각도와 상기 제2 각도 간의 각도차를 산출하는 각도차 산출부;
상기 좌표 거리 및 상기 각도차를 기반으로 상기 제1 라인점과 상기 제2 라인점 간의 연결거리를 산출하는 연결거리 산출부; 및
상기 제2 라인점들 중 상기 제1 라인점과 가장 연결거리가 작은 라인점을 상기 제1 라인점과 연결하는 라인점 결정부를 포함하는 서브픽셀 라인위치 결정 장치.
The method of claim 17,
The line connection part,
A distance calculator configured to calculate a coordinate distance between a first line point included in the line and a second line point in the vicinity of the first line point among the line points;
An angle calculator configured to calculate a first angle of the line at the first line point and to calculate a second angle between the first line point and the second line point;
An angle difference calculator configured to calculate an angle difference between the first angle and the second angle;
A connection distance calculator configured to calculate a connection distance between the first line point and the second line point based on the coordinate distance and the angle difference; And
And a line point determining unit connecting a line point having a smallest connection distance to the first line point among the second line points with the first line point.
KR1020190080859A 2019-07-04 2019-07-04 Apparatus and method for subpixel line localization KR102279177B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020190080859A KR102279177B1 (en) 2019-07-04 2019-07-04 Apparatus and method for subpixel line localization

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020190080859A KR102279177B1 (en) 2019-07-04 2019-07-04 Apparatus and method for subpixel line localization

Publications (2)

Publication Number Publication Date
KR20210005413A true KR20210005413A (en) 2021-01-14
KR102279177B1 KR102279177B1 (en) 2021-07-20

Family

ID=74142086

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020190080859A KR102279177B1 (en) 2019-07-04 2019-07-04 Apparatus and method for subpixel line localization

Country Status (1)

Country Link
KR (1) KR102279177B1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117237441A (en) * 2023-11-10 2023-12-15 湖南科天健光电技术有限公司 Sub-pixel positioning method, sub-pixel positioning system, electronic equipment and medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011133954A (en) * 2009-12-22 2011-07-07 3D Media Co Ltd Edge extraction method and edge extraction device
JP2013200648A (en) * 2012-03-23 2013-10-03 Toyota Auto Body Co Ltd Edge extraction method of gray image, edge extraction device and edge extraction program of gray image
KR20150108303A (en) * 2014-02-22 2015-09-25 시아오미 아이엔씨. Method and device for detecting straight line

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011133954A (en) * 2009-12-22 2011-07-07 3D Media Co Ltd Edge extraction method and edge extraction device
JP2013200648A (en) * 2012-03-23 2013-10-03 Toyota Auto Body Co Ltd Edge extraction method of gray image, edge extraction device and edge extraction program of gray image
KR20150108303A (en) * 2014-02-22 2015-09-25 시아오미 아이엔씨. Method and device for detecting straight line

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
C. Steger, "An unbiased detector of curvilinear structures", IEEE Transactions on Pattern Analysis and Machine Intelligence, vol. 20, no. 2, pp. 113-125, 1998.

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117237441A (en) * 2023-11-10 2023-12-15 湖南科天健光电技术有限公司 Sub-pixel positioning method, sub-pixel positioning system, electronic equipment and medium
CN117237441B (en) * 2023-11-10 2024-01-30 湖南科天健光电技术有限公司 Sub-pixel positioning method, sub-pixel positioning system, electronic equipment and medium

Also Published As

Publication number Publication date
KR102279177B1 (en) 2021-07-20

Similar Documents

Publication Publication Date Title
CN112348815B (en) Image processing method, image processing apparatus, and non-transitory storage medium
Ye et al. A local phase based invariant feature for remote sensing image matching
CN102169587B (en) Device and method for image processing
WO2016062159A1 (en) Image matching method and platform for testing of mobile phone applications
US8401333B2 (en) Image processing method and apparatus for multi-resolution feature based image registration
US9953437B1 (en) Method and device for constructing a table including information on a pooling type and testing method and testing device using the same
CN110738642A (en) Mask R-CNN-based reinforced concrete crack identification and measurement method and storage medium
Oliveira et al. A probabilistic approach for color correction in image mosaicking applications
CN106778659B (en) License plate recognition method and device
CN111640157A (en) Checkerboard corner detection method based on neural network and application thereof
CN113326763B (en) Remote sensing target detection method based on boundary frame consistency
US20140081605A1 (en) Dtm estimation method, dtm estimation program, dtm estimation device, and method for creating 3-dimensional building model, and region extraction method, region extraction program, and region extraction device
US11176425B2 (en) Joint detection and description systems and methods
CN104899888A (en) Legemdre moment-based image subpixel edge detection method
CN112560619A (en) Multi-focus image fusion-based multi-distance bird accurate identification method
CN113158789A (en) Target detection method, system, device and medium for remote sensing image
KR102279177B1 (en) Apparatus and method for subpixel line localization
CN109496326B (en) Image processing method, device and system
CN104268550A (en) Feature extraction method and device
CN112489207B (en) Space-constrained dense matching point cloud plane element extraction method
CN113673515A (en) Computer vision target detection algorithm
KR102214482B1 (en) Apparatus and method for line linking
CN113744142A (en) Image restoration method, electronic device and storage medium
CN112233186A (en) Equipment air tightness detection camera self-calibration method based on image perception
CN111553927A (en) Checkerboard corner detection method, checkerboard corner detection system, computer device and storage medium

Legal Events

Date Code Title Description
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right
GRNT Written decision to grant