KR101763259B1 - Electronic apparatus for categorizing data and method thereof - Google Patents

Electronic apparatus for categorizing data and method thereof Download PDF

Info

Publication number
KR101763259B1
KR101763259B1 KR1020160038559A KR20160038559A KR101763259B1 KR 101763259 B1 KR101763259 B1 KR 101763259B1 KR 1020160038559 A KR1020160038559 A KR 1020160038559A KR 20160038559 A KR20160038559 A KR 20160038559A KR 101763259 B1 KR101763259 B1 KR 101763259B1
Authority
KR
South Korea
Prior art keywords
weight
data
similarity
row
learning
Prior art date
Application number
KR1020160038559A
Other languages
Korean (ko)
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 KR1020160038559A priority Critical patent/KR101763259B1/en
Application granted granted Critical
Publication of KR101763259B1 publication Critical patent/KR101763259B1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N3/00Computing arrangements based on biological models
    • G06N3/02Neural networks
    • G06N3/08Learning methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/10Complex mathematical operations
    • G06F17/16Matrix or vector computation, e.g. matrix-matrix or matrix-vector multiplication, matrix factorization
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06K9/42
    • G06K9/6267
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/32Normalisation of the pattern dimensions

Abstract

전자 장치가 개시된다. 본 전자 장치는 복수의 클래스로 구분되는 학습 데이터를 저장하는 저장부 및 행렬 형태의 데이터가 입력되면, 신경망 모델을 이용하여 데이터의 행 및 열과 학습 데이터의 행 및 열과의 상관 정도를 산출하고, 산출된 상관 정도에 기초하여 복수의 클래스 중 데이터에 대응되는 클래스를 결정하는 프로세서를 포함한다.An electronic device is disclosed. The electronic device includes a storage unit for storing learning data classified into a plurality of classes and a matrix type data, and calculates a degree of correlation between rows and columns of data and rows and columns of data using a neural network model, And determining a class corresponding to the data among the plurality of classes based on the degree of correlation.

Description

데이터를 구분하는 전자 장치 및 그 방법 { ELECTRONIC APPARATUS FOR CATEGORIZING DATA AND METHOD THEREOF }BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an electronic apparatus and a method thereof,

본 발명은 데이터를 구분하는 전자 장치 및 그 방법에 대한 것으로, 더욱 상세하게는 입력된 데이터의 클래스를 결정하는 전자 장치 및 그 방법에 대한 것이다.BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an electronic apparatus and method for distinguishing data, and more particularly, to an electronic apparatus and a method thereof for determining a class of input data.

패턴 인식이란 얼굴 인식 또는 제스처 인식과 같이 주어진 정보를 분석하여 몇 개의 구분되는 패턴의 클래스로 나누고, 주어진 정보의 클래스를 결정하는 하는 것을 의미한다. 이러한 패턴 인식 과정은 일반적으로 데이터 표현 단계와 분류 단계로 나눌 수 있다. 데이터 표현 단계는 입력된 데이터를 분류에 적합한 형태로 변환하며, 분류 단계는 분류기를 사용하여 추출된 특징 정보를 바탕으로 분류를 수행한다.Pattern recognition means analyzing given information such as face recognition or gesture recognition, and dividing it into several classes of classified patterns, and determining the class of given information. This pattern recognition process can be generally divided into a data representation step and a classification step. The data representation step transforms the input data into a form suitable for classification, and the classification step performs classification based on the feature information extracted using the classifier.

다만, 종래의 분류 단계는 행렬 형태의 데이터가 입력되더라도 행렬 형태를 벡터 형태로 변환하여 분류를 수행하였고, 그에 따라 각 행 및 각 열이 가지는 특성을 반영하지 못하는 문제가 있었다.However, in the conventional classification step, even if matrix-shaped data is input, the matrix form is converted into a vector form and classified, thereby failing to reflect characteristics of each row and each column.

또는, 형식적으로 수식 형태만 형렬 형태로 유지되었고, 실질적으로는 유클리드 거리를 이용하여 각 행 및 각 열이 가지는 특성을 반영하지 못한 채 분류가 수행되었다.Alternatively, only the formula form was maintained in a form of a formula, and the classification was performed substantially without reflecting the characteristics of each row and each column using the Euclidean distance.

그에 따라, 입력 데이터의 각 행 및 각 열이 가지는 특성을 반영하여 패턴 인식을 수행하는 방법이 필요하게 되었다.Accordingly, there is a need for a method of performing pattern recognition by reflecting characteristics of each row and each column of input data.

본 발명은 상술한 필요성에 따른 것으로, 본 발명의 목적은 입력된 데이터의 클래스를 결정하는 경우에 거리-기반 분류기의 인식 성능을 향상시킨 전자 장치 및 그 방법을 제공함에 있다.It is an object of the present invention to provide an electronic apparatus and a method for improving the recognition performance of a distance-based classifier when determining a class of input data.

이상과 같은 목적을 달성하기 위한 본 발명의 일 실시 예에 따르면, 전자 장치는 복수의 클래스로 구분되는 학습 데이터를 저장하는 저장부 및 행렬 형태의 데이터가 입력되면, 신경망 모델을 이용하여 상기 데이터의 행 및 열과 상기 학습 데이터의 행 및 열과의 상관 정도를 산출하고, 상기 산출된 상관 정도에 기초하여 상기 복수의 클래스 중 상기 데이터에 대응되는 클래스를 결정하는 프로세서를 포함한다.According to another aspect of the present invention, there is provided an electronic device including a storage unit for storing learning data classified into a plurality of classes, And a processor for calculating a degree of correlation between the row and the column and the row and column of the learning data and determining a class corresponding to the data among the plurality of classes based on the calculated degree of correlation.

또한, 상기 저장부는 상기 신경망 모델에 사용되는 제1 가중치 및 제2 가중치를 상기 학습 데이터와 함께 저장하며, 상기 프로세서는 상기 데이터의 각 행과 상기 학습 데이터의 각 행 사이의 제1 상관 계수와, 상기 데이터의 각 열과 상기 학습 데이터의 각 열 사이의 제2 상관 계수를 산출하고, 상기 제1 상관 계수 및 상기 제2 상관 계수에 상기 제1 가중치 및 상기 제2 가중치를 단계적으로 적용하여 상기 데이터 및 상기 학습 데이터 간의 유사도를 산출하며, 상기 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 상기 데이터의 클래스로 결정할 수 있다.The storage unit stores a first weight and a second weight used in the neural network model together with the learning data. The processor calculates a first correlation coefficient between each row of the data and each row of the learning data, Calculating a second correlation coefficient between each column of the data and each column of the learning data and applying the first weight and the second weight to the first correlation coefficient and the second correlation coefficient step by step, The degree of similarity between the learning data is calculated, and the class to which the learning data having the largest similarity among the calculated similarities is calculated can be determined as the class of the data.

그리고, 상기 프로세서는 아래의 수학식을 이용하여 상기 유사도를 산출할 수 있다.The processor may calculate the degree of similarity using the following equation.

Figure 112016030724254-pat00001
Figure 112016030724254-pat00001

여기서, ρri 및 ρcj는,Here, ρ, and ρ ri is cj,

Figure 112016030724254-pat00002
Figure 112016030724254-pat00002

Figure 112016030724254-pat00003
이며,
Figure 112016030724254-pat00003
Lt;

X는 상기 데이터, Y는 상기 학습 데이터, f(X,Y)는 상기 유사도, ωri는 i번째 행의 가중치, ωcj는 j번째 열의 가중치, l1은 행의 개수, l2는 열의 개수, vr은 행 전체에 대한 가중치, vc는 열 전체에 대한 가중치, φ는 활성화 함수, ρri는 i번째 행의 상관 계수, ρcj는 j번째 열의 상관 계수,

Figure 112016030724254-pat00004
는 X와 Y의 i번째 행의 공분산,
Figure 112016030724254-pat00005
는 X와 Y의 j번째 열의 공분산,
Figure 112016030724254-pat00006
는 X의 i번째 행의 분산,
Figure 112016030724254-pat00007
는 Y의 i번째 행의 분산,
Figure 112016030724254-pat00008
는 X의 j번째 열의 분산,
Figure 112016030724254-pat00009
는 Y의 j번째 열의 분산을 나타낸다.X is the data, Y are the training data, f (X, Y) is the degree of similarity, ω ri is i-th row weight, ω cj is the j-th column weights, l 1 is the number of the line, l 2 is the number of columns , v r is the weight for the entire row, v c is the weight for the whole column, φ is the activation function, ρ ri is the correlation coefficient of the i th row, ρ cj is the correlation coefficient of the j th column,
Figure 112016030724254-pat00004
Is the covariance of the i-th row of X and Y,
Figure 112016030724254-pat00005
Is the covariance of the jth column of X and Y,
Figure 112016030724254-pat00006
Is the variance of the ith row of X,
Figure 112016030724254-pat00007
Is the variance of the ith row of Y,
Figure 112016030724254-pat00008
Is the variance of the jth column of X,
Figure 112016030724254-pat00009
Represents the variance of the jth column of Y.

또한, 상기 프로세서는 상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 제1 가중치 및 상기 제2 가중치를 결정하고, 상기 제1 가중치 및 상기 제2 가중치를 상기 저장부에 저장할 수 있다.The processor may further comprise a plurality of data pairs in the learning data and sequentially applying an initial first weight, an initial second weight, and the plurality of data pairs to the equation to calculate the first weight and the second weight And store the first weight and the second weight in the storage unit.

그리고, 상기 프로세서는 상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 복수의 데이터 쌍 간의 유사도를 산출하고, 상기 산출된 유사도와 타겟 값을 비교하여, 비교 결과 값에 기초하여 상기 초기 제1 가중치 및 상기 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행하고, 상기 프로세서는 상기 산출된 유사도와 상기 타겟 값 간의 비교 결과 값이 기설정된 조건을 충족할 때까지 상기 가중치 학습 동작을 반복적으로 수행하며, 상기 기설정된 조건이 충족되면, 최종 업데이트된 값을 상기 제1 가중치 및 상기 제2 가중치로 결정할 수 있다.The processor constructs a plurality of data pairs in the learning data, and sequentially calculates the similarity between the plurality of data pairs by applying the initial first weight, the initial second weight, and the plurality of data pairs to the equation Wherein the processor performs a weight learning operation for comparing the calculated similarity with a target value and updating the initial first weight and the initial second weight based on the comparison result value, Repeatedly performing the weight learning operation until the comparison result value between the values meets a predetermined condition, and when the predetermined condition is satisfied, the last updated value can be determined as the first weight and the second weight .

또한, 상기 프로세서는 각 데이터 쌍의 클래스가 동일한 경우와 상이한 경우에 대해, 상기 타겟 값을 상이하게 결정할 수 있다.In addition, the processor may determine the target value differently when the classes of each data pair are the same and different.

그리고, 상기 프로세서는 상기 산출된 유사도와 상기 타겟 값에 오류 역전파 알고리즘(error-back-propagation algorithm)을 적용하여 상기 가중치 학습 동작을 수행할 수 있다.The processor may perform the weight learning operation by applying an error-back-propagation algorithm to the calculated similarity and the target value.

한편, 본 발명의 일 실시 예에 따르면, 전자 장치의 데이터 구분 방법은 복수의 클래스로 구분되는 학습 데이터를 저장하는 단계, 행렬 형태의 데이터를 입력받는 단계 및 신경망 모델을 이용하여 상기 데이터의 행 및 열과 상기 학습 데이터의 행 및 열과의 상관 정도를 산출하고, 상기 상관 정도에 기초하여 상기 복수의 클래스 중 상기 데이터에 대응되는 클래스를 결정하는 단계를 포함한다.According to an embodiment of the present invention, there is provided a method of classifying data in an electronic device, comprising: storing learning data classified into a plurality of classes; inputting matrix-type data; And a step of determining a class corresponding to the data among the plurality of classes based on the degree of correlation.

또한, 상기 클래스를 결정하는 단계는 상기 데이터의 각 행과 상기 학습 데이터의 각 행 사이의 제1 상관 계수와, 상기 데이터의 각 열과 상기 학습 데이터의 각 열 사이의 제2 상관 계수를 산출하는 단계, 상기 제1 상관 계수 및 상기 제2 상관 계수에 제1 가중치 및 제2 가중치를 단계적으로 적용하여 상기 데이터 및 상기 학습 데이터 간의 유사도를 산출하는 단계 및 상기 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 상기 데이터의 클래스로 결정하는 단계를 포함할 수 있다.The step of determining the class may include calculating a first correlation coefficient between each row of the data and each row of the learning data and a second correlation coefficient between each column of the data and each column of the learning data Calculating a degree of similarity between the data and the learning data by stepwise applying a first weight and a second weight to the first correlation coefficient and the second correlation coefficient, And classifying the class to which the data belongs as the class of the data.

그리고, 상기 유사도를 산출하는 단계는 아래의 수학식을 이용하여 상기 유사도를 산출할 수 있다.The step of calculating the degree of similarity may calculate the degree of similarity using the following equation.

Figure 112016030724254-pat00010
Figure 112016030724254-pat00010

여기서, ρri 및 ρcj는,Here, ρ, and ρ ri is cj,

Figure 112016030724254-pat00011
Figure 112016030724254-pat00011

Figure 112016030724254-pat00012
이며,
Figure 112016030724254-pat00012
Lt;

X는 상기 데이터, Y는 상기 학습 데이터, f(X,Y)는 상기 유사도, ωri는 i번째 행의 가중치, ωcj는 j번째 열의 가중치, l1은 행의 개수, l2는 열의 개수, vr은 행 전체에 대한 가중치, vc는 열 전체에 대한 가중치, φ는 활성화 함수, ρri는 i번째 행의 상관 계수, ρcj는 j번째 열의 상관 계수,

Figure 112016030724254-pat00013
는 X와 Y의 i번째 행의 공분산,
Figure 112016030724254-pat00014
는 X와 Y의 j번째 열의 공분산,
Figure 112016030724254-pat00015
는 X의 i번째 행의 분산,
Figure 112016030724254-pat00016
는 Y의 i번째 행의 분산,
Figure 112016030724254-pat00017
는 X의 j번째 열의 분산,
Figure 112016030724254-pat00018
는 Y의 j번째 열의 분산을 나타낸다.X is the data, Y are the training data, f (X, Y) is the degree of similarity, ω ri is i-th row weight, ω cj is the j-th column weights, l 1 is the number of the line, l 2 is the number of columns , v r is the weight for the entire row, v c is the weight for the whole column, φ is the activation function, ρ ri is the correlation coefficient of the i th row, ρ cj is the correlation coefficient of the j th column,
Figure 112016030724254-pat00013
Is the covariance of the i-th row of X and Y,
Figure 112016030724254-pat00014
Is the covariance of the jth column of X and Y,
Figure 112016030724254-pat00015
Is the variance of the ith row of X,
Figure 112016030724254-pat00016
Is the variance of the ith row of Y,
Figure 112016030724254-pat00017
Is the variance of the jth column of X,
Figure 112016030724254-pat00018
Represents the variance of the jth column of Y.

또한, 상기 저장하는 단계는 상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 제1 가중치 및 상기 제2 가중치를 결정하는 단계 및 상기 제1 가중치 및 상기 제2 가중치를 저장하는 단계를 포함할 수 있다.The storing step may include constructing a plurality of data pairs in the learning data, sequentially applying an initial first weight, an initial second weight, and the plurality of data pairs to the equation to calculate the first weight and the second weight, 2 < / RTI > weight, and storing the first weight and the second weight.

그리고, 상기 저장하는 단계는 상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 복수의 데이터 쌍 간의 유사도를 산출하는 단계, 상기 산출된 유사도와 타겟 값을 비교하여, 비교 결과 값에 기초하여 상기 초기 제1 가중치 및 상기 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행하는 단계, 상기 산출된 유사도와 상기 타겟 값 간의 비교 결과 값이 기설정된 조건을 충족할 때까지 상기 가중치 학습 동작을 반복적으로 수행하는 단계, 상기 기설정된 조건이 충족되면, 최종 업데이트된 값을 상기 제1 가중치 및 상기 제2 가중치로 결정하는 단계 및 상기 제1 가중치 및 상기 제2 가중치를 저장하는 단계를 포함할 수 있다.The storing step includes a step of constructing a plurality of data pairs from the learning data, sequentially applying an initial first weight, an initial second weight, and the plurality of data pairs to the equation, Performing a weight learning operation for comparing the calculated similarity with a target value and updating the initial first weight and the initial second weight based on a comparison result value; Repeatedly performing the weight learning operation until the comparison result value between the target values satisfies a predetermined condition; determining the last updated value as the first weight and the second weight when the predetermined condition is satisfied; And storing the first weight and the second weight.

또한, 상기 타겟 값은 각 데이터 쌍의 클래스가 동일한 경우와 상이한 경우에 대해, 상이하게 결정될 수 있다.In addition, the target value may be determined differently for cases where the classes of the data pairs are the same and different.

그리고, 상기 가중치 학습 동작을 수행하는 단계는 상기 산출된 유사도와 상기 타겟 값에 오류 역전파 알고리즘(error-back-propagation algorithm)을 적용하여 상기 가중치 학습 동작을 수행할 수 있다.The step of performing the weight learning operation may perform the weight learning operation by applying an error-back-propagation algorithm to the calculated similarity and the target value.

이상과 같은 본 발명의 다양한 실시 예에 따르면, 신경망 모델을 이용하여 입력된 데이터의 행 및 열의 특성을 고려함에 따라 거리-기반 분류기의 인식 성능을 향상시킬 수 있다.According to various embodiments of the present invention as described above, recognition performance of the distance-based classifier can be improved by considering characteristics of rows and columns of input data using a neural network model.

도 1은 본 발명의 일 실시 예에 따른 전자 장치의 구성을 나타내는 블럭도이다.
도 2는 본 발명의 일 실시 예에 따른 복수의 클래스로 구분된 학습 데이터를 설명하기 위한 도면이다.
도 3 및 도 4는 학습 데이터의 일 예를 나타내는 도면이다.
도 5는 본 발명의 일 실시 예에 따른 신경망 모듈을 설명하기 위한 도면이다.
도 6은 본 발명의 일 실시 예에 따른 얼굴 인식을 수행하는 방법을 설명하기 위한 도면이다.
도 7은 본 발명의 다른 실시 예에 따른 제스처 인식을 수행하는 방법을 설명하기 위한 도면이다.
도 8은 본 발명의 확장 실시 예에 따른 신경망 모듈을 설명하기 위한 도면이다.
도 9는 본 발명의 일 실시 예에 따른 전자 장치의 데이터 구분 방법을 설명하기 위한 흐름도이다.
1 is a block diagram showing the configuration of an electronic device according to an embodiment of the present invention.
2 is a view for explaining learning data classified into a plurality of classes according to an embodiment of the present invention.
3 and 4 are diagrams showing examples of learning data.
5 is a view for explaining a neural network module according to an embodiment of the present invention.
6 is a view for explaining a method of performing face recognition according to an embodiment of the present invention.
7 is a view for explaining a method of performing gesture recognition according to another embodiment of the present invention.
8 is a view for explaining a neural network module according to an embodiment of the present invention.
9 is a flowchart illustrating a data classification method of an electronic device according to an embodiment of the present invention.

이하에서, 첨부된 도면을 이용하여 본 발명에 대하여 구체적으로 설명한다.Hereinafter, the present invention will be described in detail with reference to the accompanying drawings.

도 1은 본 발명의 일 실시 예에 따른 전자 장치(100)의 구성을 나타내는 블럭도이다.1 is a block diagram showing a configuration of an electronic device 100 according to an embodiment of the present invention.

본 발명의 일 실시 예에 따른 전자 장치(100)는 기저장되어 있는 행렬 형태의 데이터와 새로 입력된 행렬 형태의 데이터를 각 행 및 각 열 단위로 비교하여, 기저장되어 있는 데이터 중 입력된 데이터와 가장 유사한 데이터를 결정할 수 있다.The electronic device 100 according to an embodiment of the present invention compares data of a matrix in which data is already stored and data of a newly inputted matrix in each row and each column, The most similar data can be determined.

예를 들어, 전자 장치(100)는 사용자 1 내지 5에 대한 얼굴 이미지를 저장하고 있고, 새로운 얼굴 이미지가 입력되면, 입력된 얼굴 이미지를 사용자 1 내지 5 중 하나로 결정할 수 있다. 즉, 전자 장치(100)는 입력된 데이터를 사용자 1 내지 5 중 하나로 분류하는 동작을 수행한다. 다만, 이하에서는 입력된 데이터와 가장 유사한 데이터를 결정하는 것으로 표현한다.For example, the electronic device 100 stores a face image for the users 1 to 5, and when a new face image is input, the input face image can be determined as one of the users 1 to 5. That is, the electronic device 100 performs an operation of classifying the input data into one of the users 1 to 5. [ However, in the following description, the data most similar to the input data is determined.

전자 장치(100)는 거리-기반 분류기를 이용하여 입력된 데이터와 가장 유사한 데이터를 결정할 수 있다. 거리-기반의 의미는 복수의 데이터 간의 차이를 의미하는 것으로, 거리 차이가 크면 복수의 데이터의 정합성이 낮다고 볼 수 있으며, 거리 차이가 작으면 복수의 데이터의 정합성이 높다고 볼 수 있다,The electronic device 100 may use the distance-based classifier to determine the most similar data to the input data. The distance-based meaning means a difference between a plurality of data. If the distance difference is large, the consistency of the plurality of data is low. If the distance difference is small, the consistency of the plurality of data is high.

전자 장치(100)는 차-기반 거리가 아닌 내적-기반 거리를 이용하는 거리-기반 분류기를 이용할 수 있다. 차-기반 거리를 이용하는 분류기는 유클리드 거리를 측정하는 것으로 볼 수 있고, 내적-기반 거리를 이용하는 분류기는 분산을 이용하여 거리를 측정하는 것으로 볼 수 있다.The electronic device 100 may use a distance-based classifier that uses an inner-based distance rather than a co-based distance. The classifier using the difference-based distance can be regarded as measuring the Euclidean distance, and the classifier using the inner-based distance can be regarded as measuring the distance using the dispersion.

이상과 같은 전자 장치(100)는 스마트폰, 출입관리 시스템, 서버 시스템 등으로 구현될 수 있으며, 객체를 인식하여 기저장된 데이터와 매칭되는지 판단할 수 있다. 또는, 전자 장치(100)는 스마트 TV, 데스크탑 PC 등으로 구현될 수 있으며, 입력된 이미지와 매칭되는 데이터를 포함하는 컨텐츠를 검색하여 제공할 수도 있다.The electronic device 100 may be implemented as a smart phone, an entry management system, a server system, or the like, and may determine whether an object is recognized and matched with previously stored data. Alternatively, the electronic device 100 may be implemented as a smart TV, a desktop PC, or the like, and may search for and provide content including data matching the input image.

전자 장치(100)는 도 1에 도시된 바와 같이, 저장부(110) 및 프로세서(120)를 포함한다.The electronic device 100 includes a storage unit 110 and a processor 120, as shown in FIG.

저장부(110)는 학습 데이터를 저장할 수 있다. 여기서, 학습 데이터는 행렬 형태의 데이터일 수 있다. 예를 들어, 학습 데이터는 복수의 흑백 이미지일 수 있다. 각 흑백 이미지는 흑백 이미지의 해상도에 대응되는 행렬 형태의 데이터일 수 있다. 또는, 학습 데이터는 동영상으로부터 생성된 행렬 형태의 데이터일 수도 있다.The storage unit 110 may store learning data. Here, the learning data may be data in a matrix form. For example, the training data may be a plurality of monochrome images. Each black-and-white image may be data in the form of a matrix corresponding to the resolution of the black-and-white image. Alternatively, the learning data may be data in the form of a matrix generated from a moving picture.

학습 데이터는 기저장된 데이터로서 새로 입력되는 데이터와의 유사도 산출을 위한 기준 데이터일 수 있다. 따라서, 학습 데이터가 기저장되어 있지 않은 경우 데이터가 입력되더라도 유사도 산출이 불가능할 수 있다.The learning data may be reference data for calculating similarity with newly input data as pre-stored data. Therefore, if the learning data is not previously stored, the similarity calculation may not be possible even if data is input.

저장부(110)는 학습 데이터를 복수의 클래스로 구분하여 저장할 수 있다. 여기서, 클래스는 유사한 학습 데이터의 그룹이라고 볼 수 있다. 예를 들어, 저장부(110)는 복수의 얼굴 이미지를 사람에 따라 구분하여 저장할 수 있다. 즉, 동일한 클래스에 속하는 이미지는 동일한 사람에 대한 얼굴 이미지일 수 있으나, 표정, 조명, 포즈 등이 다른 이미지일 수 있다.The storage unit 110 may store training data classified into a plurality of classes. Here, the class can be regarded as a group of similar learning data. For example, the storage unit 110 may store a plurality of face images according to a person. That is, an image belonging to the same class may be a face image for the same person, but facial expressions, lighting, pose, and the like may be other images.

저장부(110)는 후술할 신경망 모델에 사용되는 제1 가중치 및 제2 가중치를 저장할 수 있다. 여기서, 제1 가중치 및 제2 가중치는 신경망 모델을 이용하여 학습 데이터로부터 결정되는 정보이며, 입력된 데이터와 학습 데이터의 유사도를 산출하기 위해 이용되는 데이터이다.The storage unit 110 may store a first weight and a second weight used in a neural network model to be described later. Here, the first weight and the second weight are information determined from the learning data using the neural network model, and are data used for calculating the similarity between the input data and the learning data.

프로세서(120)는 행렬 형태의 데이터가 입력되면, 신경망 모델을 이용하여 데이터의 행 및 열과 학습 데이터의 행 및 열과의 상관 정도를 산출할 수 있다. 여기서, 행렬 형태의 데이터는 촬영부(미도시), 입력부(미도시), 통신부(미도시) 등을 통해 입력된 데이터일 수 있다. 또는, 행렬 형태의 데이터는 기저장된 데이터일 수 있고, 이 경우 사용자에 의해 기저장된 데이터가 호출된 것으로 볼 수 있다.When the matrix type data is input, the processor 120 can calculate the degree of correlation between rows and columns of data and rows and columns of data using a neural network model. Here, the data in the form of a matrix may be data input through a photographing unit (not shown), an input unit (not shown), a communication unit (not shown) Alternatively, the data in the form of a matrix may be pre-stored data, in which case the pre-stored data may be viewed as being called by the user.

한편, 신경망 모델이란 인간의 기억과 같이 신경망을 구성하여 기억 내용들을 노드 사이의 연결 강도로 저장한 모델이다. 즉, 각 노드 사이의 연결 강도에 따라 노드의 중요성이 결정될 수 있다. 상술한 제1 가중치 및 제2 가중치는 각 노드 사이의 연결 강도라고 볼 수 있다.On the other hand, a neural network model is a model in which a neural network is constructed like a human memory and the memory contents are stored as the connection strength between nodes. That is, the importance of the node can be determined according to the connection strength between the nodes. The first weight and the second weight can be regarded as connection strength between nodes.

프로세서(120)는 데이터 및 학습 데이터의 각 행 및 각 열을 신경망 모델에 입력하여 데이터 및 학습 데이터의 상관 정도를 산출할 수 있다. 예를 들어, 프로세서(120)는 데이터의 제1 행 및 학습 데이터의 제1 행의 상관 정도를 산출한 후, 순차적으로 나머지 행 및 열에 대하여도 상관 정도를 산출할 수 있다.Processor 120 may input each row and each column of data and learning data into a neural network model to calculate the degree of correlation of data and learning data. For example, the processor 120 may calculate the degree of correlation between the first row of data and the first row of the learning data, and then sequentially calculate the degree of correlation with respect to the remaining rows and columns.

프로세서(120)는 각 행 및 각 열로부터 산출된 복수의 상관 정도로부터 데이터 및 학습 데이터의 전체 상관 정도를 산출하고, 복수의 클래스 중 데이터에 대응되는 클래스를 결정할 수 있다.The processor 120 can calculate the total degree of correlation of data and learning data from a plurality of degrees of correlation calculated from each row and each column and determine a class corresponding to data among the plurality of classes.

구체적으로, 프로세서(120)는 데이터의 각 행과 학습 데이터의 각 행 사이의 제1 상관 계수와, 데이터의 각 열과 학습 데이터의 각 열 사이의 제2 상관 계수를 산출할 수 있다. 그에 따라, 행의 개수만큼 복수의 제1 상관 계수 및 열의 계수만큼 복수의 제2 상관 계수가 산출될 수 있다.Specifically, the processor 120 can calculate a first correlation coefficient between each row of data and each row of learning data, and a second correlation coefficient between each column of data and each column of learning data. Accordingly, a plurality of second correlation coefficients can be calculated by a plurality of first correlation coefficients and column coefficients by the number of rows.

프로세서(120)는 제1 상관 계수 및 제2 상관 계수에 제1 가중치 및 제2 가중치를 단계적으로 적용하여 데이터 및 학습 데이터 간의 유사도를 산출할 수 있다. 여기서, 제1 가중치는 복수의 제1 상관 계수 및 복수의 제2 상관 계수 각각에 대응되는 복수의 가중치를 포함할 수 있다. 즉, 제1 가중치는 각 행에 대한 가중치 및 각 열에 대한 가중치를 포함할 수 있다. 제2 가중치는 행 전체에 대한 가중치 및 열 전체에 대한 가중치를 포함할 수 있다.The processor 120 may calculate the degree of similarity between the data and the learning data by stepwise applying the first weight and the second weight to the first correlation coefficient and the second correlation coefficient. Here, the first weight may include a plurality of weight values corresponding to each of the plurality of first correlation coefficients and the plurality of second correlation coefficients. That is, the first weight may include a weight for each row and a weight for each column. The second weight may include a weight for the entire row and a weight for the entire column.

여기서, 프로세서(120)는 아래의 수학식을 이용하여 유사도를 산출할 수 있다.Here, the processor 120 may calculate the degree of similarity using the following equation.

Figure 112016030724254-pat00019
Figure 112016030724254-pat00019

여기서, ρri 및 ρcj는,Here, ρ, and ρ ri is cj,

Figure 112016030724254-pat00020
Figure 112016030724254-pat00020

Figure 112016030724254-pat00021
이며,
Figure 112016030724254-pat00021
Lt;

X는 데이터, Y는 학습 데이터, f(X,Y)는 유사도, ωri는 i번째 행의 가중치, ωcj는 j번째 열의 가중치, l1은 행의 개수, l2는 열의 개수, vr은 행 전체에 대한 가중치, vc는 열 전체에 대한 가중치, φ는 활성화 함수, ρri는 i번째 행의 상관 계수, ρcj는 j번째 열의 상관 계수,

Figure 112016030724254-pat00022
는 X와 Y의 i번째 행의 공분산,
Figure 112016030724254-pat00023
는 X와 Y의 j번째 열의 공분산,
Figure 112016030724254-pat00024
는 X의 i번째 행의 분산,
Figure 112016030724254-pat00025
는 Y의 i번째 행의 분산,
Figure 112016030724254-pat00026
는 X의 j번째 열의 분산,
Figure 112016030724254-pat00027
는 Y의 j번째 열의 분산을 나타낸다.Ω ri is the weight of the i th row, ω cj is the weight of the j th column, l 1 is the number of rows, l 2 is the number of columns, v r (x, y) is the training data, f is a weight for the entire row, v c is the column weight for the total, φ is activated function, ρ ri is the i-th row correlation coefficient, ρ cj is the j-th column, the correlation coefficient,
Figure 112016030724254-pat00022
Is the covariance of the i-th row of X and Y,
Figure 112016030724254-pat00023
Is the covariance of the jth column of X and Y,
Figure 112016030724254-pat00024
Is the variance of the ith row of X,
Figure 112016030724254-pat00025
Is the variance of the ith row of Y,
Figure 112016030724254-pat00026
Is the variance of the jth column of X,
Figure 112016030724254-pat00027
Represents the variance of the jth column of Y.

프로세서(120)는 유사도 산출 과정에서 활성화 함수를 이용하여 비선형 변환을 수행하며, 활성화 함수로 scaled hyperbolic tangent function이 이용될 수 있다.The processor 120 performs nonlinear transformation using an activation function in the similarity calculation process, and a scaled hyperbolic tangent function can be used as an activation function.

프로세서(120)는 유사도를 산출하는 과정을 모든 학습 데이터에 대하여 반복 수행하여, 모든 학습 데이터 각각과 입력된 데이터의 유사도를 산출할 수 있다. 즉, 프로세서(120)는 저장하고 있는 학습 데이터의 개수만큼 복수의 유사도를 산출할 수 있다.The processor 120 may repeat the process of calculating the degree of similarity for all the learning data to calculate the degree of similarity between each of the learning data and the input data. That is, the processor 120 can calculate a plurality of similarities by the number of stored learning data.

프로세서(120)는 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 데이터의 클래스로 결정할 수 있다. 즉, 프로세서(120)는 가장 큰 유사도가 산출된 학습 데이터를 입력된 데이터와 가장 유사한 데이터로 결정하고, 해당 학습 데이터가 포함되어 있는 클래스를 입력된 데이터의 클래스로 결정할 수 있다.The processor 120 can determine the class to which the learning data having the greatest similarity among the calculated similarities is calculated as the class of the data. In other words, the processor 120 can determine the most similar data as the data most similar to the input data, and determine the class including the learning data as the class of the input data.

한편, 이상에서는 저장부(110)에 저장되어 있는 제1 가중치 및 제2 가중치를 이용하여 유사도를 산출하는 것으로 설명하였는데, 제1 가중치 및 제2 가중치는 학습 데이터로부터 생성된 정보일 수 있다. 예를 들어, 프로세서(120)는 학습 데이터를 수신하면, 학습 데이터를 저장부(110)에 저장하고, 학습 데이터로부터 제1 가중치 및 제2 가중치를 결정할 수 있다.In the above description, the degree of similarity is calculated using the first weight and the second weight stored in the storage unit 110. The first weight and the second weight may be information generated from the learning data. For example, when the processor 120 receives the learning data, it may store the learning data in the storage unit 110 and determine the first weight and the second weight from the learning data.

먼저, 프로세서(120)는 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 복수의 데이터 쌍을 순차적으로 수학식 1에 적용하여 제1 가중치 및 제2 가중치를 결정할 수 있다. 여기서, 초기 제1 가중치 및 초기 제2 가중치는 임의로 결정된 초기 값일 수 있다.First, the processor 120 constructs a plurality of data pairs in learning data, and sequentially applies the initial first weight, the initial second weight, and a plurality of data pairs to Equation 1 to determine the first weight and the second weight . Here, the initial first weight and the initial second weight may be arbitrarily determined initial values.

프로세서(120)는 학습 데이터 중 구성 가능한 모든 복수의 데이터 쌍을 구성할 수 있다. 예를 들어, 프로세서(120)는 A1, A2, B, C의 학습 데이터가 입력되면, (A1, A2), (A1, B), (A1, C), (A2, B), (A2, C), (B, C)의 데이터 쌍을 구성할 수 있다. 다만, 이는 일 실시 예에 불과하고, 프로세서(120)는 일부 데이터 쌍만을 구성할 수도 있다.The processor 120 may configure all the plurality of configurable data pairs in the learning data. (A1, A2), (A1, B), (A1, C), (A2, B), (A2, C), (B, C). However, this is only an example, and the processor 120 may configure only some data pairs.

프로세서(120)는 초기 제1 가중치, 초기 제2 가중치 및 복수의 데이터 쌍을 순차적으로 수학식 1에 적용하여 복수의 데이터 쌍 간의 유사도를 산출할 수 있다. 유사도를 산출하는 방식은 수학식 1에서 설명한 바와 동일하다. 다만, 신경망 모델에 입력되는 데이터의 차이만이 있을 뿐이다.The processor 120 may calculate the similarity between a plurality of data pairs by sequentially applying an initial first weight, an initial second weight, and a plurality of data pairs to Equation (1). The method of calculating the degree of similarity is the same as that described in Equation (1). However, there is only difference in the data input to the neural network model.

프로세서(120)는 산출된 유사도와 타겟 값을 비교하여, 비교 결과 값에 기초하여 초기 제1 가중치 및 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행할 수 있다.Processor 120 may perform a weighted learning operation that compares the calculated similarity with a target value and updates the initial first weight and the initial second weight based on the comparison result.

여기서, 프로세서(120)는 각 데이터 쌍의 클래스가 동일한 경우와 상이한 경우에 대해, 타겟 값을 상이하게 결정할 수 있다. 예를 들어, 프로세서(120)는 (A1, A2)와 같이 각 데이터 쌍의 클래스가 동일한 경우 타겟 값을 1로 정하고, (A1, B), (A1, C), (A2, B), (A2, C), (B, C)와 같이 각 데이터 쌍의 클래스가 상이한 경우 타겟 값을 -1로 정할 수 있다.Here, the processor 120 can differently determine the target value for cases where the classes of the respective data pairs are the same and different. For example, the processor 120 sets the target value to 1 and sets (A1, B), (A1, C), (A2, B), A2, C), and (B, C), the target value may be set to -1 if the classes of the data pairs are different.

산출된 유사도는 임의로 결정된 초기 제1 가중치 및 초기 제2 가중치를 이용하였기 때문에 타겟 값과 차이가 발생할 수 있다. 이러한 차이를 줄이기 위해, 프로세서(120)는 산출된 유사도와 타겟 값에 오류 역전파 알고리즘(error-back-propagation algorithm)을 적용하여 초기 제1 가중치 및 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행할 수 있다.The calculated similarity may be different from the target value since the initial first weight and the initial second weight are arbitrarily determined. In order to reduce this difference, the processor 120 performs a weight learning operation to update an initial first weight and an initial second weight by applying an error-back-propagation algorithm to the calculated similarity and target value can do.

오류 역전파 알고리즘은 기계 학습에서 사용되는 학습 구조로, 일반적인 형태는 입력층 - 은닉층 - 은닉층 - ... - 출력층으로 구성되며, 각 층은 서로 교차되는 weight 값으로 연결되어 있다. 출력층에서 제시한 값에 대해, 실제 원하는 값으로 통계적으로 학습하는 과정을 통해 최적의 weight 값을 산출할 수 있다.The error backpropagation algorithm is a learning structure used in machine learning. The general form consists of an input layer - a hidden layer - a hidden layer - ... - output layer, and each layer is connected to each other by weight values intersecting each other. The optimal weight value can be calculated by statistically learning the values presented in the output layer with actual desired values.

오류 역전파 알고리즘은 동일 입력층에 대해 원하는 값이 출력되도록 개개의 weight 값을 조정하는 방법으로 사용되며, 속도는 느리지만, 안정적인 결과를 얻을 수 있으며, 기계 학습에 널리 사용되고 있다. 프로세서(120)는 오류 역전파 알고리즘을 이용하여 타겟 값이 출력되도록 초기 제1 가중치 및 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행할 수 있다.The error backpropagation algorithm is used to adjust individual weight values so that the desired value is output for the same input layer. The speed is slow, but stable results are obtained and widely used in machine learning. Processor 120 may perform a weighted learning operation to update an initial first weight and an initial second weight such that a target value is output using an error back propagation algorithm.

프로세서(120)는 업데이트된 초기 제1 가중치 및 초기 제2 가중치를 이용하여 새로운 데이터 쌍에 대해 동일한 작업을 반복할 수 있다. 초기 제1 가중치 및 초기 제2 가중치는 업데이트가 반복됨에 따라 특정 값에 수렴할 수 있다.Processor 120 may repeat the same operation for a new data pair using the updated initial weight and the initial weight. The initial first weight and the initial second weight may converge to a specific value as the update is repeated.

프로세서(120)는 산출된 유사도와 타겟 값 간의 비교 결과 값이 기설정된 조건을 충족할 때까지 가중치 학습 동작을 반복적으로 수행하며, 기설정된 조건이 충족되면, 최종 업데이트된 값을 제1 가중치 및 제2 가중치로 결정할 수 있다.The processor 120 repeatedly performs the weight learning operation until the comparison result value between the calculated similarity and the target value satisfies the preset condition, and when the predetermined condition is satisfied, the last updated value is set to the first weight and the 2 Weights can be determined.

예를 들어, 프로세서(120)는 학습 데이터 중 구성 가능한 모든 복수의 데이터 쌍에 대하여 가중치 학습 동작을 반복한 후, 제1 가중치 및 제2 가중치를 결정할 수 있다. 또는, 프로세서(120)는 순차적으로 업데이트되는 초기 제1 가중치 및 초기 제2 가중치의 변화율이 기설정된 값보다 작은 경우에 학습 동작을 정지하고, 최종 업데이트된 값을 제1 가중치 및 제2 가중치로 결정할 수도 있다. 프로세서(120)는 결정된 제1 가중치 및 제2 가중치를 저장부(110)에 저장할 수 있다. For example, the processor 120 may determine a first weight and a second weight after repeating the weight learning operation on all of a plurality of configurable data pairs in the training data. Alternatively, the processor 120 may stop the learning operation when the rate of change of the initial first weight and the initial second weight that are sequentially updated is smaller than a predetermined value, and determine the last updated value as the first weight and the second weight It is possible. The processor 120 may store the determined first weight and the determined second weight in the storage unit 110.

상술한 바와 같이 행과 열의 형태를 유지한 상태로 가중치 학습 동작을 수행하여 각 행 및 각 열에 대한 가중치를 산출하고, 산출된 가중치를 이용하여 입력된 데이터와 기저장된 데이터 각각의 유사도를 산출하면, 입력된 데이터의 인식 성능이 향상될 수 있다.If weights are calculated for each row and each column by performing a weight learning operation while maintaining the form of rows and columns as described above and the degree of similarity between input data and pre-stored data is calculated by using the calculated weight, The recognition performance of the input data can be improved.

이하에서는 전자 장치(100)의 데이터 구분 방법에 대하여 좀더 구체적으로 설명한다.Hereinafter, the data classification method of the electronic device 100 will be described in more detail.

도 2는 본 발명의 일 실시 예에 따른 복수의 클래스로 구분된 학습 데이터를 설명하기 위한 도면이다.2 is a view for explaining learning data classified into a plurality of classes according to an embodiment of the present invention.

도 2는 A, B, C의 세 개의 클래스로 구분된 학습 데이터를 도시하였다. A 클래스는 A1, A2, A3의 학습 데이터를 포함하고, B 클래스는 B1, B2, B3, B4의 학습 데이터를 포함하고, C 클래스는 C1, C2의 학습 데이터를 포함한다. 다만, 이는 일 실시 예에 불과하고, 클래스의 개수 및 각 클래스별 학습 데이터의 개수는 얼마든지 달라질 수 있다.FIG. 2 shows learning data divided into three classes A, B, and C. FIG. The A class includes learning data of A1, A2, and A3, the B class includes learning data of B1, B2, B3, and B4, and the C class includes learning data of C1 and C2. However, this is only an embodiment, and the number of classes and the number of learning data for each class can be changed as much as possible.

학습 데이터는 이미지일 수 있다. 예를 들어, 프로세서(120)는 도 3에 도시된 바와 같이 하나의 클래스에 포함된 15장의 학습 데이터를 수신할 수 있다. 15장의 학습 데이터는 동일한 남성 인물에 대한 이미지이나, 조명, 촬영 각도, 표정 등의 차이가 있을 수 있다.The learning data may be an image. For example, the processor 120 can receive 15 pieces of learning data included in one class as shown in FIG. There may be differences in images, lighting, photographing angle, facial expression, etc. of the same male person in the learning data of 15 sheets.

프로세서(120)는 또 다른 인물에 대한 이미지가 수신되면, 수신된 이미지를 새로운 클래스로 구분하여 저장할 수 있다. 예를 들어, 프로세서(120)는 여성 인물이 포함된 이미지가 4장이 수신되면, 이전의 15장의 이미지와는 다른 클래스를 구성하여 4장의 이미지를 저장할 수 있다.The processor 120 may classify received images into new classes and store them when an image of another person is received. For example, when four images including an female character are received, the processor 120 may classify the four images into a different class from the previous fifteen images.

프로세서(120)는 수신된 이미지를 그레이 스케일로 변경할 수 있다. 예를 들어, 수신된 이미지가 RGB 이미지인 경우에는 R, G, B 각각에 대한 행렬 데이터가 필요했으나, 그레이 스케일 이미지인 경우에는 하나의 행렬 데이터만이 필요하다. 그에 따라, 인식 성능을 유지하면서도 연산 속도를 향상시킬 수 있다. 다만, 이는 일 실시 예에 불과하고, RGB 이미지를 그대로 유지한 채로 R, G, B 각각에 대한 행렬 데이터를 이용하여 유사도를 판단할 수도 있다.Processor 120 may change the received image to grayscale. For example, if the received image is an RGB image, matrix data for each of R, G, and B is required. However, in case of a grayscale image, only one matrix data is required. Accordingly, the calculation speed can be improved while maintaining the recognition performance. However, this is merely an example, and the degree of similarity may be determined using the matrix data for each of R, G, and B while the RGB image is maintained.

프로세서(120)는 수신된 이미지의 크기를 조정하여 모든 학습 데이터의 행렬 크기를 동일하게 변경할 수 있다. 그에 따라, 프로세서(120)는 모든 학습 데이터 간의 각 행 및 각 열의 상관 정도를 산출할 수 있다. 이때, 프로세서(120)는 수신된 이미지를 크롭하는 것이 아니라 리사이징하여 크기를 조정할 수 있다.The processor 120 may adjust the size of the received image to change the matrix size of all learning data equally. Thereby, the processor 120 can calculate the degree of correlation between each row and each column between all the learning data. At this time, the processor 120 may resize the received image and adjust its size.

학습 데이터는 동영상일 수도 있다. 예를 들어, 도 4는 특정 제스처가 촬영된 동영상을 프레임 별로 도시한 학습 데이터를 나타낸다. 여기서, 클래스는 특정 제스처이며, 해당 클래스에 포함되는 학습 데이터는 특정 제스처를 동일하게 수행하는 다른 사용자의 동영상 또는 동일한 사용자이더라도 새롭게 특정 제스처를 수행하는 동영상일 수 있다. 즉, 프로세서(120)는 제스처 별로 입력된 동영상의 클래스를 구분하여 저장할 수 있다.The learning data may be a moving picture. For example, FIG. 4 shows learning data showing a moving image of a specific gesture frame by frame. Here, the class is a specific gesture, and the learning data included in the class may be a moving picture of another user who performs the same specific gesture, or a moving picture that performs a new specific gesture even if the same user is the same. That is, the processor 120 can classify and store the input moving picture class for each gesture.

프로세서(120)는 수신된 동영상의 각 프레임을 기설정된 차원으로 벡터화하고, 벡터화된 복수의 프레임에서 연속하는 두 개의 벡터화된 프레임의 차를 순차적으로 계산하여 프레임 순서와 동일하게 쌓아 행렬 데이터를 생성할 수 있다.The processor 120 performs vectorization of each frame of the received moving image to a predetermined dimension, sequentially calculates the difference between two vectorized frames that are continuous in a plurality of vectorized frames, and sequentially generates matrix data by stacking the frames in the same order as the frame order .

예를 들어, 프로세서(120)는 N 개의 프레임을 갖는 동영상이 수신되면, 각 프레임을 M 차원으로 벡터화하고, 차를 계산하여 N-1 × M 또는 M × N-1의 행렬 데이터를 생성할 수 있다.For example, when a moving picture having N frames is received, the processor 120 can vectorize each frame into M dimensions and calculate a difference to generate matrix data of N-1xM or MxN-1 have.

다만, 이에 한정되는 것은 아니며, 프로세서(120)는 각 프레임의 차를 계산하지 않고, N × M 또는 M × N의 행렬 데이터를 생성할 수도 있다.However, the present invention is not limited thereto, and the processor 120 may generate N × M or M × N matrix data without calculating the difference of each frame.

이상과 같이 프로세서(120)는 학습 데이터를 기설정된 형태의 행렬 데이터로 변환하여 저장할 수 있다.As described above, the processor 120 can convert the learning data into matrix data of a predetermined type and store the matrix data.

도 5는 본 발명의 일 실시 예에 따른 신경망 모듈을 설명하기 위한 도면이다.5 is a view for explaining a neural network module according to an embodiment of the present invention.

신경망 모듈은 상술한 수학식 1로 표현될 수 있다. 또한, 신경망 모듈은 가중치 학습 동작을 수행하기 위해 사용될 수 있으며, 가중치가 학습되어 저장되면 입력되는 데이터의 클래스를 결정하기 위해 사용될 수 있다.The neural network module can be expressed by Equation (1). In addition, the neural network module may be used to perform a weighted learning operation and may be used to determine the class of data to be entered when weights are learned and stored.

먼저, 신경망 모듈이 가중치 학습 동작을 수행하기 위해 사용되는 경우를 설명한다.First, a case where a neural network module is used to perform a weight learning operation will be described.

프로세서(120)는 학습 데이터 중에서 복수의 데이터 쌍을 구성하여 신경망 모듈의 입력으로 사용할 수 있다. 예를 들어, 프로세서(120)는 도 2의 A1, B1의 행렬 데이터를 신경망 모듈에 입력하여 유사도 f(A1,B1)를 산출할 수 있다. 이때, 노드 사이의 연결 강도를 나타내는 초기 제1 가중치 및 초기 제2 가중치는 임의로 설정된 값일 수 있다.The processor 120 may construct a plurality of data pairs from the learning data and use them as inputs to the neural network module. For example, the processor 120 may calculate the similarity f (A1, B1) by inputting the matrix data of A1, B1 in Fig. 2 to the neural network module. At this time, the initial first weight and the initial second weight, which indicate the connection strength between the nodes, may be arbitrarily set values.

프로세서(120)는 임의로 설정된 초기 제1 가중치 및 초기 제2 가중치를 이용하여 산출된 유사도와 타겟 값을 비교하여 초기 제1 가중치 및 초기 제2 가중치를 업데이트할 수 있다. 예를 들어, 프로세서(120)는 서로 다른 클래스의 A1, B1 행렬 데이터가 입력되면, 타겟 값을 -1로 설정하고, 산출된 유사도가 -1에 가까워지도록 학습할 수 있다. 그 과정에서 프로세서(120)는 초기 제1 가중치 및 초기 제2 가중치를 업데이트할 수 있다.The processor 120 may update the initial first weight and the initial second weight by comparing the target value with the similarity calculated using an arbitrarily set initial first weight and an initial second weight. For example, when the A1 and B1 matrix data of different classes are input, the processor 120 sets the target value to -1 and learns that the calculated similarity approaches -1. In the process, the processor 120 may update the initial first weight and the initial second weight.

프로세서(120)는 하나의 데이터 쌍에 대하여 초기 제1 가중치 및 초기 제2 가중치를 업데이트한 후, 새로운 데이터 쌍에 대하여 동일한 가중치 학습 동작을 수행할 수 있다. 예를 들어, 프로세서(120)는 도 2의 A1, A3의 행렬 데이터를 신경망 모듈에 입력하여 유사도 f(A1,A3)를 산출할 수 있다. 프로세서(120)는 동일한 클래스의 A1, A3 행렬 데이터가 입력되면, 타겟 값을 1로 설정하고, 산출된 유사도가 1에 가까워지도록 업데이트된 초기 제1 가중치 및 초기 제2 가중치를 한번 더 업데이트할 수 있다. 여기서, 프로세서(120)는 임의로 설정된 초기 제1 가중치 및 초기 제2 가중치를 이용하는 것이 아니라 업데이트된 초기 제1 가중치 및 초기 제2 가중치를 이용하여 유사도를 산출하고 업데이트하게 된다.Processor 120 may update the initial first weight and the initial second weight for one data pair and then perform the same weighted learning operation on the new data pair. For example, the processor 120 may calculate the similarity f (A1, A3) by inputting the matrix data of A1, A3 in Fig. 2 to the neural network module. The processor 120 may set the target value to 1 and update the updated initial weight and initial second weight so that the calculated similarity approaches 1 have. Here, the processor 120 calculates and updates the degree of similarity using the updated initial initial weight and the initial initial weight instead of using the initial initial weight and the initial initial weight that are arbitrarily set.

프로세서(120)는 모든 데이터 쌍에 대하여 이상과 같은 과정을 반복하여 초기 제1 가중치 및 초기 제2 가중치를 업데이트하고, 최종 업데이트된 값을 제1 가중치 및 제2 가중치로 결정할 수 있다.The processor 120 may repeat the above process for all data pairs to update the initial first weight and the initial second weight, and determine the last updated value as the first weight and the second weight.

또는, 프로세서(120)는 모든 데이터 쌍이 아닌 일부 데이터 쌍에 대하여만 이상과 같은 과정을 반복할 수도 있다. 프로세서(120)는 이상과 같은 과정을 반복하며 변화율이 기설정된 값보다 작아지면 학습 과정을 중단하고, 최종 업데이트된 값을 제1 가중치 및 제2 가중치로 결정할 수도 있다.Alternatively, the processor 120 may repeat the above process only for some data pairs, not all data pairs. The processor 120 repeats the above process, and if the rate of change becomes smaller than the predetermined value, the learning process may be stopped and the last updated value may be determined as the first weight and the second weight.

프로세서(120)는 제1 가중치 및 제2 가중치가 결정되고, 새로운 데이터가 입력되면, 입력된 데이터의 클래스를 결정할 수 있다. 예를 들어, 프로세서(120)는 새로운 데이터 X가 입력되면, X, A1을 신경망 모듈의 입력으로 사용할 수 있다. 구체적으로, 프로세서(120)는 수학식 1에 X, A1을 입력하여 유사도 f(X,A1)를 산출할 수 있다.The processor 120 can determine the class of the input data when the first weight and the second weight are determined and new data is input. For example, processor 120 may use X, A1 as input to the neural network module when new data X is input. Specifically, the processor 120 may calculate the similarity f (X, A1) by inputting X and A1 into the equation (1).

먼저, 프로세서(120)는 입력 데이터를 학습 데이터에 대응되도록 변환할 수 있다. 예를 들어, 프로세서(120)는 이미지가 수신되면 학습 데이터에 대응되도록 색상, 크기 등을 변환할 수 있다. 또는, 프로세서(120)는 동영상이 수신되면 학습 데이터에 대응되도록 행렬 데이터를 생성할 수도 있다.First, the processor 120 may convert the input data to correspond to the learning data. For example, the processor 120 may convert colors, sizes, and the like so that they correspond to learning data when an image is received. Alternatively, the processor 120 may generate matrix data to correspond to learning data when a moving picture is received.

프로세서(120)는 입력 데이터와의 유사도를 산출하는 과정을 학습 데이터 전부에 대하여 수행할 수 있다. 예를 들어, 프로세서(120)는 X, A1에 대한 유사도 f(X,A1)를 산출한 후, X, A2에 대한 유사도 f(X,A2)를 산출할 수 있다. 이때, 프로세서(120)는 상술한 가중치 학습 동작에서 결정된 제1 가중치 및 제2 가중치를 이용하여 유사도를 산출할 수 있다.The processor 120 may perform a process of calculating the degree of similarity with the input data to all of the learning data. For example, the processor 120 may calculate the similarity f (X, A1) for X, A1 and then calculate the similarity f (X, A2) for X, A2. At this time, the processor 120 may calculate the degree of similarity using the first weight and the second weight determined in the weight learning operation.

최종적으로, 프로세서(120)는 학습 데이터 개수와 동일한 개수의 유사도를 산출할 수 있다. 프로세서(120)는 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 입력 데이터의 클래스로 결정할 수 있다. 예를 들어, 프로세서(120)는 입력 데이터 X와의 유사도가 가장 큰 학습 데이터로 B1이 결정되면, X의 클래스를 B1이 속한 B 클래스로 결정할 수 있다.Finally, the processor 120 can calculate the number of similarities as the number of learning data. The processor 120 can determine the class to which the learning data having the largest similarity calculated among the calculated similarities belongs as the class of the input data. For example, when B1 is determined as the learning data having the greatest degree of similarity to the input data X, the processor 120 can determine the class of X as the class B to which B1 belongs.

프로세서(120) 이상과 같은 방법을 통해 얼굴 이미지가 입력되면 저장되어 있는 얼굴 이미지 중 가장 유사한 얼굴 이미지를 결정할 수 있다. 즉, 프로세서(120)는 이상과 같은 방법을 통해 얼굴 인식, 제스처 인식 등을 수행할 수 있다.Processor 120 If the face image is input through the above method, the most similar face image among the stored face images can be determined. That is, the processor 120 can perform face recognition, gesture recognition, and the like through the above-described method.

도 6은 본 발명의 일 실시 예에 따른 얼굴 인식을 수행하는 방법을 설명하기 위한 도면이다.6 is a view for explaining a method of performing face recognition according to an embodiment of the present invention.

얼굴 인식을 위해서는 데이터 표현 단계(Representation, 610) 및 분류 단계(Classificaion, 620)를 거치게 된다.For face recognition, a data representation step (610) and a classification step (620) are performed.

데이터 표현 단계(610)는 전처리(Pre-processing, 611) 및 특징 추출(Feature Extraction, 612)을 통해 입력된 데이터를 분류 단계(620)에서 이용될 데이터 형태로 변환한다. 분류 단계(620)는 유사도 계산(Computing Similarity) 및 클래스 결정(Nearest Neighbor)을 통해 최종적으로 입력된 데이터의 클래스를 결정한다. 분류 단계에 대하여는 상술하였으므로, 데이터 표현 단계(610)에 대하여만 설명한다.The data presenting step 610 transforms the input data through preprocessing 611 and feature extraction 612 into a data form to be used in the classifying step 620. The classification step 620 determines the class of data finally input through computing similarity and nearest neighbor. Since the classification step has been described above, only the data representation step 610 will be described.

먼저, 전처리(611) 단계에서 프로세서(120)는 얼굴 이미지가 입력되면 이미지의 색상 및 크기를 변경할 수 있다. 그리고, 특징 추출(612) 단계에서 프로세서(120)는 2차원 행렬 형태를 유지할 수 있는 방법 중 지역 기술자 기반의 HOG와 텐서 부분 공간 분석 방법인 TPCA를 이용하여 특징이 강조된 데이터를 생성할 수 있다.First, in the preprocessing step 611, the processor 120 can change the color and size of the image when the face image is input. In the characteristic extraction step 612, the processor 120 can generate characteristic emphasized data using HOG based on a local descriptor and TPCA, a tensor subspace analysis method, among methods capable of maintaining a two-dimensional matrix form.

프로세서(120)는 입력 데이터로부터 최종적으로 생성된 데이터를 이용하여 유사도 판단 및 클래스 결정을 수행할 수 있다. 그에 따라, 프로세서(120)는 얼굴 이미지를 입력받아 얼굴을 인식할 수 있다.The processor 120 may perform similarity determination and class determination using the data finally generated from the input data. Accordingly, the processor 120 can receive the face image and recognize the face.

도 7은 본 발명의 다른 실시 예에 따른 제스처 인식을 수행하는 방법을 설명하기 위한 도면이다.7 is a view for explaining a method of performing gesture recognition according to another embodiment of the present invention.

제스처 인식을 위해서는 데이터 표현 단계(Representation, 710) 및 분류 단계(Classificaion, 720)를 거치게 된다. 분류 단계(720)는 도 6과 동일하며 구체적인 설명은 생략한다.For gesture recognition, a data representation step (710) and a classification step (720) are performed. The classification step 720 is the same as that in Fig. 6, and a detailed description thereof will be omitted.

데이터 표현 단계(710)는 전처리(Pre-processing, 711), 특징 추출(Feature Extraction, 712) 및 프레임 스택킹(Stacking Frame, 713)을 통해 입력된 데이터를 분류 단계(720)에서 이용될 데이터 형태로 변환한다.The data representation step 710 may include inputting the data input through pre-processing 711, feature extraction 712, and a stacking frame 713 into the data format to be used in the classification step 720 .

먼저, 전처리(711) 단계에서 프로세서(120)는 이미지 시퀀스가 입력되면 각 프레임의 색상을 변경하고, 연속하는 두 개의 프레임 간 차를 계산할 수 있다. 그리고, 특징 추출(712) 단계에서 프로세서(120)는 PCA(Principal Component Analysis)와 LPP(Locality Preserving Projection)를 결합하여 프레임 간 차를 50차원 벡터로 변경할 수 있다. 그리고, 프레임 스택킹(713) 단계에서 프로세서(120)는 프레임 간 차를 스택킹하여 행렬 형태의 데이터를 생성할 수 있다.First, in the preprocessing step 711, when the image sequence is inputted, the processor 120 may change the color of each frame and calculate the difference between two consecutive frames. In the feature extraction step 712, the processor 120 may combine PCA (Principal Component Analysis) and LPP (Locality Preserving Projection) to change the inter-frame difference to a 50-dimensional vector. In the frame stacking step 713, the processor 120 may generate the matrix-shaped data by stacking the inter-frame difference.

프로세서(120)는 입력 데이터로부터 최종적으로 생성된 데이터를 이용하여 유사도 판단 및 클래스 결정을 수행할 수 있다. 그에 따라, 프로세서(120)는 동영상을 입력받아 제스처를 인식할 수 있다.The processor 120 may perform similarity determination and class determination using the data finally generated from the input data. Accordingly, the processor 120 can receive the moving picture and recognize the gesture.

도 8은 본 발명의 확장 실시 예에 따른 신경망 모듈을 설명하기 위한 도면이다.8 is a view for explaining a neural network module according to an embodiment of the present invention.

도 8에 따르면, 프로세서(120)는 행렬 형태의 데이터가 아닌 3차원 형태의 데이터를 신경망 모듈의 입력 데이터로 사용할 수 있다. 이 경우, 프로세서(120)는 각 행 및 각 열의 상관 정도 뿐만 아니라 깊이 방향의 데이터에 대하여도 상관 정도를 산출하여 유사도를 판단할 수 있다.According to FIG. 8, the processor 120 may use data of a three-dimensional form, rather than matrix-type data, as input data of the neural network module. In this case, the processor 120 can determine the similarity by calculating the degree of correlation not only with respect to the degree of correlation between each row and each column but also with respect to the data in the depth direction.

도 8에는 3차원 형태의 데이터에 대하여만 도시하였으나, 이에 한정되는 것은 아니며, 유사한 방법으로 고차원 형태의 데이터에 대하여도 확장 적용할 수 있다.Although FIG. 8 shows only three-dimensional data, the present invention is not limited thereto, and a similar method can be applied to extended data.

도 9는 본 발명의 일 실시 예에 따른 전자 장치의 데이터 구분 방법을 설명하기 위한 흐름도이다.9 is a flowchart illustrating a data classification method of an electronic device according to an embodiment of the present invention.

먼저, 복수의 클래스로 구분되는 학습 데이터를 저장한다(S910). 그리고, 행렬 형태의 데이터를 입력받는다(S920). 그리고, 신경망 모델을 이용하여 데이터의 행 및 열과 학습 데이터의 행 및 열과의 상관 정도를 산출하고, 상관 정도에 기초하여 복수의 클래스 중 데이터에 대응되는 클래스를 결정한다(S930).First, learning data classified into a plurality of classes is stored (S910). Then, the data of the matrix form is inputted (S920). The neural network model is used to calculate the degree of correlation between the rows and columns of data and the rows and columns of the learning data, and the class corresponding to the data among the plurality of classes is determined based on the degree of correlation (S930).

여기서, 클래스를 결정하는 단계(S930)는 데이터의 각 행과 학습 데이터의 각 행 사이의 제1 상관 계수와, 데이터의 각 열과 학습 데이터의 각 열 사이의 제2 상관 계수를 산출하는 단계, 1 상관 계수 및 제2 상관 계수에 제1 가중치 및 제2 가중치를 단계적으로 적용하여 데이터 및 학습 데이터 간의 유사도를 산출하는 단계 및 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 데이터의 클래스로 결정하는 단계를 포함할 수 있다.The class determining step S930 includes calculating a first correlation coefficient between each row of the data and each row of the learning data and a second correlation coefficient between each column of the data and each column of the learning data; Calculating a degree of similarity between the data and the learning data by stepwise applying the first weight and the second weight to the correlation coefficient and the second correlation coefficient and calculating a degree of similarity between the data and the learning data by classifying the class to which the calculated learning data belongs, As shown in FIG.

특히, 유사도를 산출하는 단계는 아래의 수학식을 이용하여 유사도를 산출할 수 있다.In particular, the step of calculating the degree of similarity may calculate the degree of similarity using the following equation.

Figure 112016030724254-pat00028
Figure 112016030724254-pat00028

여기서, ρri 및 ρcj는,Here, ρ, and ρ ri is cj,

Figure 112016030724254-pat00029
Figure 112016030724254-pat00029

Figure 112016030724254-pat00030
이며,
Figure 112016030724254-pat00030
Lt;

X는 데이터, Y는 학습 데이터, f(X,Y)는 유사도, ωri는 i번째 행의 가중치, ωcj는 j번째 열의 가중치, l1은 행의 개수, l2는 열의 개수, vr은 행 전체에 대한 가중치, vc는 열 전체에 대한 가중치, φ는 활성화 함수, ρri는 i번째 행의 상관 계수, ρcj는 j번째 열의 상관 계수,

Figure 112016030724254-pat00031
는 X와 Y의 i번째 행의 공분산,
Figure 112016030724254-pat00032
는 X와 Y의 j번째 열의 공분산,
Figure 112016030724254-pat00033
는 X의 i번째 행의 분산,
Figure 112016030724254-pat00034
는 Y의 i번째 행의 분산,
Figure 112016030724254-pat00035
는 X의 j번째 열의 분산,
Figure 112016030724254-pat00036
는 Y의 j번째 열의 분산을 나타낸다.Ω ri is the weight of the i th row, ω cj is the weight of the j th column, l 1 is the number of rows, l 2 is the number of columns, v r (x, y) is the training data, f is a weight for the entire row, v c is the column weight for the total, φ is activated function, ρ ri is the i-th row correlation coefficient, ρ cj is the j-th column, the correlation coefficient,
Figure 112016030724254-pat00031
Is the covariance of the i-th row of X and Y,
Figure 112016030724254-pat00032
Is the covariance of the jth column of X and Y,
Figure 112016030724254-pat00033
Is the variance of the ith row of X,
Figure 112016030724254-pat00034
Is the variance of the ith row of Y,
Figure 112016030724254-pat00035
Is the variance of the jth column of X,
Figure 112016030724254-pat00036
Represents the variance of the jth column of Y.

한편, 저장하는 단계(S910)는 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 복수의 데이터 쌍을 순차적으로 수학식에 적용하여 제1 가중치 및 제2 가중치를 결정하는 단계 및 제1 가중치 및 제2 가중치를 저장하는 단계를 포함할 수 있다.Meanwhile, the step of storing (S910) constitutes a plurality of data pairs in the learning data, sequentially applying the initial first weight, the initial second weight, and the plurality of data pairs to the mathematical expression to calculate the first weight and the second weight And storing the first weight and the second weight.

또한, 저장하는 단계(S910)는 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 복수의 데이터 쌍을 순차적으로 수학식에 적용하여 복수의 데이터 쌍 간의 유사도를 산출하는 단계, 산출된 유사도와 타겟 값을 비교하여, 비교 결과 값에 기초하여 초기 제1 가중치 및 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행하는 단계, 산출된 유사도와 타겟 값 간의 비교 결과 값이 기설정된 조건을 충족할 때까지 가중치 학습 동작을 반복적으로 수행하는 단계, 기설정된 조건이 충족되면, 최종 업데이트된 값을 제1 가중치 및 제2 가중치로 결정하는 단계 및 제1 가중치 및 제2 가중치를 저장하는 단계를 포함할 수 있다.In addition, the step of storing (S910) constitutes a plurality of data pairs in the learning data, and the initial first weight, the initial second weight and a plurality of data pairs are sequentially applied to the mathematical expression to calculate the similarity between the plurality of data pairs Comparing the calculated similarity with a target value, and performing a weight learning operation to update an initial first weight and an initial second weight based on a comparison result value, calculating a comparison result value between the calculated similarity and a target value Repeatedly performing a weighted learning operation until a predetermined condition is met, determining a last updated value as a first weight and a second weight, if a predetermined condition is met, and determining a first weight and a second weight, And storing it.

한편, 타겟 값은 각 데이터 쌍의 클래스가 동일한 경우와 상이한 경우에 대해, 상이하게 결정될 수 있다.On the other hand, the target value can be determined differently for cases where the classes of the respective data pairs are the same and different.

한편, 가중치 학습 동작을 수행하는 단계는 산출된 유사도와 타겟 값에 오류 역전파 알고리즘(error-back-propagation algorithm)을 적용하여 가중치 학습 동작을 수행할 수 있다.Meanwhile, in the step of performing the weight learning operation, a weight learning operation may be performed by applying an error-back-propagation algorithm to the calculated similarity and target value.

이상과 같은 본 발명의 다양한 실시 예에 따르면, 신경망 모델을 이용하여 입력된 데이터의 특성을 고려함에 따라 거리-기반 분류기의 인식 성능을 향상시킬 수 있다.According to various embodiments of the present invention as described above, the recognition performance of the distance-based classifier can be improved by considering the characteristics of the input data using the neural network model.

한편, 이상에서는 얼굴 인식 및 제스처 인식을 위주로 설명하였으나, 이에 한정되는 것은 아니다. 예를 들어, 전자 장치는 특정 데이터가 입력되면, 입력된 데이터의 형태를 변환한 후 기저장되어 있는 데이터 중 가장 유사한 데이터를 결정할 수도 있다.Although the face recognition and the gesture recognition have been described above, the present invention is not limited thereto. For example, when specific data is input, the electronic device may convert the type of the input data and determine the most similar data among the stored data.

한편, 이러한 다양한 실시 예에 따른 방법들은 프로그래밍되어 각종 저장 매체에 저장될 수 있다. 이에 따라, 저장 매체를 실행하는 다양한 유형의 전자 장치에서 상술한 다양한 실시 예에 따른 방법들이 구현될 수 있다.Meanwhile, the methods according to various embodiments may be programmed and stored in various storage media. As such, the methods according to various embodiments described above can be implemented in various types of electronic devices that execute the storage medium.

구체적으로는, 상술한 데이터 구분 방법을 순차적으로 수행하는 프로그램이 저장된 비일시적 판독 가능 매체(non-transitory computer readable medium)가 제공될 수 있다. Specifically, a non-transitory computer readable medium may be provided in which a program for sequentially performing the above-described data classification method is stored.

비일시적 판독 가능 매체란 레지스터, 캐쉬, 메모리 등과 같이 짧은 순간 동안 데이터를 저장하는 매체가 아니라 반영구적으로 데이터를 저장하며, 기기에 의해 판독(reading)이 가능한 매체를 의미한다. 구체적으로는, 상술한 다양한 어플리케이션 또는 프로그램들은 CD, DVD, 하드 디스크, 블루레이 디스크, USB, 메모리카드, ROM 등과 같은 비일시적 판독 가능 매체에 저장되어 제공될 수 있다.A non-transitory readable medium is a medium that stores data for a short period of time, such as a register, cache, memory, etc., but semi-permanently stores data and is readable by the apparatus. In particular, the various applications or programs described above may be stored on non-volatile readable media such as CD, DVD, hard disk, Blu-ray disk, USB, memory card, ROM,

또한, 이상에서는 본 발명의 바람직한 실시 예에 대하여 도시하고 설명하였지만, 본 발명은 상술한 특정의 실시 예에 한정되지 아니하며, 청구범위에서 청구하는 본 발명의 요지를 벗어남이 없이 당해 발명이 속하는 기술분야에서 통상의 지식을 가진자에 의해 다양한 변형실시가 가능한 것은 물론이고, 이러한 변형실시들은 본 발명의 기술적 사상이나 전망으로부터 개별적으로 이해되어져서는 안될 것이다.While the present invention has been particularly shown and described with reference to exemplary embodiments thereof, it is to be understood that the invention is not limited to the disclosed exemplary embodiments, but, on the contrary, It will be understood by those skilled in the art that various changes in form and detail may be made therein without departing from the spirit and scope of the present invention.

100 : 전자 장치 110 : 저장부
120 : 프로세서
100: electronic device 110: storage unit
120: Processor

Claims (14)

복수의 클래스로 구분되는 학습 데이터를 저장하는 저장부; 및
행렬 형태의 데이터가 입력되면, 신경망 모델을 이용하여 상기 데이터의 행 및 열과 상기 학습 데이터의 행 및 열과의 상관 정도를 산출하고, 상기 산출된 상관 정도에 기초하여 상기 복수의 클래스 중 상기 데이터에 대응되는 클래스를 결정하는 프로세서;를 포함하고,
상기 저장부는,
상기 신경망 모델에 사용되는 제1 가중치 및 제2 가중치를 상기 학습 데이터와 함께 저장하며,
상기 프로세서는,
상기 데이터의 각 행과 상기 학습 데이터의 각 행 사이의 제1 상관 계수와, 상기 데이터의 각 열과 상기 학습 데이터의 각 열 사이의 제2 상관 계수를 산출하고, 상기 제1 상관 계수 및 상기 제2 상관 계수에 상기 제1 가중치 및 상기 제2 가중치를 단계적으로 적용하여 상기 데이터 및 상기 학습 데이터 간의 유사도를 산출하는, 전자 장치.
A storage unit for storing learning data classified into a plurality of classes; And
Calculating a degree of correlation between a row and a column of the data and a row and a column of the learning data using a neural network model when data in a matrix form is input; A processor for determining a class to be used,
Wherein,
Storing a first weight and a second weight used in the neural network model together with the learning data,
The processor comprising:
Calculating a first correlation coefficient between each row of the data and each row of the learning data and a second correlation coefficient between each column of the data and each column of the learning data, Wherein the degree of similarity between the data and the learning data is calculated by stepwise applying the first weight and the second weight to a correlation coefficient.
제1항에 있어서,
상기 프로세서는,
상기 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 상기 데이터의 클래스로 결정하는, 전자 장치.
The method according to claim 1,
The processor comprising:
And determines the class to which the learning data having the largest similarity calculated among the calculated similarities belongs as the class of the data.
제2항에 있어서,
상기 프로세서는,
아래의 수학식을 이용하여 상기 유사도를 산출하는, 전자 장치:
Figure 112016030724254-pat00037

여기서, ρri 및 ρcj는,
Figure 112016030724254-pat00038

Figure 112016030724254-pat00039
이며,
X는 상기 데이터, Y는 상기 학습 데이터, f(X,Y)는 상기 유사도, ωri는 i번째 행의 가중치, ωcj는 j번째 열의 가중치, l1은 행의 개수, l2는 열의 개수, vr은 행 전체에 대한 가중치, vc는 열 전체에 대한 가중치, φ는 활성화 함수, ρri는 i번째 행의 상관 계수, ρcj는 j번째 열의 상관 계수,
Figure 112016030724254-pat00040
는 X와 Y의 i번째 행의 공분산,
Figure 112016030724254-pat00041
는 X와 Y의 j번째 열의 공분산,
Figure 112016030724254-pat00042
는 X의 i번째 행의 분산,
Figure 112016030724254-pat00043
는 Y의 i번째 행의 분산,
Figure 112016030724254-pat00044
는 X의 j번째 열의 분산,
Figure 112016030724254-pat00045
는 Y의 j번째 열의 분산을 나타낸다.
3. The method of claim 2,
The processor comprising:
Wherein the similarity is calculated using the following equation:
Figure 112016030724254-pat00037

Here, ρ, and ρ ri is cj,
Figure 112016030724254-pat00038

Figure 112016030724254-pat00039
Lt;
X is the data, Y are the training data, f (X, Y) is the degree of similarity, ω ri is i-th row weight, ω cj is the j-th column weights, l 1 is the number of the line, l 2 is the number of columns , v r is the weight for the entire row, v c is the weight for the whole column, φ is the activation function, ρ ri is the correlation coefficient of the i th row, ρ cj is the correlation coefficient of the j th column,
Figure 112016030724254-pat00040
Is the covariance of the i-th row of X and Y,
Figure 112016030724254-pat00041
Is the covariance of the jth column of X and Y,
Figure 112016030724254-pat00042
Is the variance of the ith row of X,
Figure 112016030724254-pat00043
Is the variance of the ith row of Y,
Figure 112016030724254-pat00044
Is the variance of the jth column of X,
Figure 112016030724254-pat00045
Represents the variance of the jth column of Y.
제3항에 있어서,
상기 프로세서는,
상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 제1 가중치 및 상기 제2 가중치를 결정하고, 상기 제1 가중치 및 상기 제2 가중치를 상기 저장부에 저장하는, 전자 장치.
The method of claim 3,
The processor comprising:
The first weight and the second weight are determined by sequentially constructing a plurality of data pairs from the learning data and sequentially applying an initial first weight, an initial second weight, and the plurality of data pairs to the equation, And stores the first weight and the second weight in the storage.
제3항에 있어서,
상기 프로세서는,
상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 복수의 데이터 쌍 간의 유사도를 산출하고, 상기 산출된 유사도와 타겟 값을 비교하여, 비교 결과 값에 기초하여 상기 초기 제1 가중치 및 상기 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행하고,
상기 프로세서는,
상기 산출된 유사도와 상기 타겟 값 간의 비교 결과 값이 기설정된 조건을 충족할 때까지 상기 가중치 학습 동작을 반복적으로 수행하며,
상기 기설정된 조건이 충족되면, 최종 업데이트된 값을 상기 제1 가중치 및 상기 제2 가중치로 결정하는, 전자 장치.
The method of claim 3,
The processor comprising:
Wherein a plurality of data pairs are constructed from the learning data, the initial first weight, the initial second weight, and the plurality of data pairs are sequentially applied to the equation to calculate the degree of similarity between the plurality of data pairs, Performing a weight learning operation for comparing the similarity with a target value and updating the initial first weight and the initial second weight based on a comparison result value,
The processor comprising:
Repeatedly performing the weight learning operation until a result of comparison between the calculated similarity and the target value satisfies a predetermined condition,
And determines the last updated value as the first weight and the second weight if the predetermined condition is met.
제5항에 있어서,
상기 프로세서는,
각 데이터 쌍의 클래스가 동일한 경우와 상이한 경우에 대해, 상기 타겟 값을 상이하게 결정하는, 전자 장치.
6. The method of claim 5,
The processor comprising:
And determines the target value differently when the classes of each data pair are the same and different.
제5항에 있어서,
상기 프로세서는,
상기 산출된 유사도와 상기 타겟 값에 오류 역전파 알고리즘(error-back-propagation algorithm)을 적용하여 상기 가중치 학습 동작을 수행하는, 전자 장치.
6. The method of claim 5,
The processor comprising:
And performs the weight learning operation by applying an error-back-propagation algorithm to the calculated similarity and the target value.
전자 장치의 데이터 구분 방법에 있어서,
복수의 클래스로 구분되는 학습 데이터를 저장하는 단계;
행렬 형태의 데이터를 입력받는 단계; 및
신경망 모델을 이용하여 상기 데이터의 행 및 열과 상기 학습 데이터의 행 및 열과의 상관 정도를 산출하고, 상기 상관 정도에 기초하여 상기 복수의 클래스 중 상기 데이터에 대응되는 클래스를 결정하는 단계;를 포함하고,
상기 클래스를 결정하는 단계는,
상기 데이터의 각 행과 상기 학습 데이터의 각 행 사이의 제1 상관 계수와, 상기 데이터의 각 열과 상기 학습 데이터의 각 열 사이의 제2 상관 계수를 산출하는 단계; 및
상기 제1 상관 계수 및 상기 제2 상관 계수에 제1 가중치 및 제2 가중치를 단계적으로 적용하여 상기 데이터 및 상기 학습 데이터 간의 유사도를 산출하는 단계;를 포함하는, 데이터 구분 방법.
A method of classifying data in an electronic device,
Storing training data classified into a plurality of classes;
Receiving data in a matrix form; And
Calculating a degree of correlation between the rows and columns of the data and rows and columns of the learning data using a neural network model and determining a class corresponding to the data among the plurality of classes based on the degree of correlation ,
The step of determining the class comprises:
Calculating a first correlation coefficient between each row of the data and each row of the learning data and a second correlation coefficient between each column of the data and each column of the learning data; And
And calculating the degree of similarity between the data and the learning data by stepwise applying the first weight and the second weight to the first correlation coefficient and the second correlation coefficient.
제8항에 있어서,
상기 클래스를 결정하는 단계는,
상기 산출된 유사도 중 가장 큰 유사도가 산출된 학습 데이터가 속한 클래스를 상기 데이터의 클래스로 결정하는 단계;를 더 포함하는, 데이터 구분 방법.
9. The method of claim 8,
The step of determining the class comprises:
And determining a class to which the calculated learning data having the largest similarity among the calculated similarities belongs as the class of the data.
제9항에 있어서,
상기 유사도를 산출하는 단계는,
아래의 수학식을 이용하여 상기 유사도를 산출하는, 데이터 구분 방법:
Figure 112016030724254-pat00046

여기서, ρri 및 ρcj는,
Figure 112016030724254-pat00047

Figure 112016030724254-pat00048
이며,
X는 상기 데이터, Y는 상기 학습 데이터, f(X,Y)는 상기 유사도, ωri는 i번째 행의 가중치, ωcj는 j번째 열의 가중치, l1은 행의 개수, l2는 열의 개수, vr은 행 전체에 대한 가중치, vc는 열 전체에 대한 가중치, φ는 활성화 함수, ρri는 i번째 행의 상관 계수, ρcj는 j번째 열의 상관 계수,
Figure 112016030724254-pat00049
는 X와 Y의 i번째 행의 공분산,
Figure 112016030724254-pat00050
는 X와 Y의 j번째 열의 공분산,
Figure 112016030724254-pat00051
는 X의 i번째 행의 분산,
Figure 112016030724254-pat00052
는 Y의 i번째 행의 분산,
Figure 112016030724254-pat00053
는 X의 j번째 열의 분산,
Figure 112016030724254-pat00054
는 Y의 j번째 열의 분산을 나타낸다.
10. The method of claim 9,
The step of calculating the degree of similarity may include:
And calculating the degree of similarity using the following equation:
Figure 112016030724254-pat00046

Here, ρ, and ρ ri is cj,
Figure 112016030724254-pat00047

Figure 112016030724254-pat00048
Lt;
X is the data, Y are the training data, f (X, Y) is the degree of similarity, ω ri is i-th row weight, ω cj is the j-th column weights, l 1 is the number of the line, l 2 is the number of columns , v r is the weight for the entire row, v c is the weight for the whole column, φ is the activation function, ρ ri is the correlation coefficient of the i th row, ρ cj is the correlation coefficient of the j th column,
Figure 112016030724254-pat00049
Is the covariance of the i-th row of X and Y,
Figure 112016030724254-pat00050
Is the covariance of the jth column of X and Y,
Figure 112016030724254-pat00051
Is the variance of the ith row of X,
Figure 112016030724254-pat00052
Is the variance of the ith row of Y,
Figure 112016030724254-pat00053
Is the variance of the jth column of X,
Figure 112016030724254-pat00054
Represents the variance of the jth column of Y.
제10항에 있어서,
상기 저장하는 단계는,
상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 제1 가중치 및 상기 제2 가중치를 결정하는 단계; 및
상기 제1 가중치 및 상기 제2 가중치를 저장하는 단계;를 포함하는, 데이터 구분 방법.
11. The method of claim 10,
Wherein the storing step comprises:
Determining a first weight and a second weight by constructing a plurality of data pairs from the learning data and sequentially applying an initial first weight, an initial second weight, and the plurality of data pairs to the equation; And
And storing the first weight and the second weight.
제10항에 있어서,
상기 저장하는 단계는,
상기 학습 데이터 중에서 복수의 데이터 쌍을 구성하고, 초기 제1 가중치, 초기 제2 가중치 및 상기 복수의 데이터 쌍을 순차적으로 상기 수학식에 적용하여 상기 복수의 데이터 쌍 간의 유사도를 산출하는 단계;
상기 산출된 유사도와 타겟 값을 비교하여, 비교 결과 값에 기초하여 상기 초기 제1 가중치 및 상기 초기 제2 가중치를 업데이트하는 가중치 학습 동작을 수행하는 단계;
상기 산출된 유사도와 상기 타겟 값 간의 비교 결과 값이 기설정된 조건을 충족할 때까지 상기 가중치 학습 동작을 반복적으로 수행하는 단계;
상기 기설정된 조건이 충족되면, 최종 업데이트된 값을 상기 제1 가중치 및 상기 제2 가중치로 결정하는 단계; 및
상기 제1 가중치 및 상기 제2 가중치를 저장하는 단계;를 포함하는, 데이터 구분 방법.
11. The method of claim 10,
Wherein the storing step comprises:
Calculating a degree of similarity between the plurality of data pairs by sequentially constructing a plurality of data pairs in the learning data, sequentially applying an initial first weight, an initial second weight, and the plurality of data pairs to the equation;
Performing a weight learning operation for comparing the calculated similarity with a target value and updating the initial first weight and the initial second weight based on the comparison result;
Repeatedly performing the weight learning operation until a result of comparison between the calculated similarity and the target value satisfies a predetermined condition;
Determining the last updated value as the first weight and the second weight when the predetermined condition is satisfied; And
And storing the first weight and the second weight.
제12항에 있어서,
상기 타겟 값은,
각 데이터 쌍의 클래스가 동일한 경우와 상이한 경우에 대해, 상이하게 결정되는, 데이터 구분 방법.
13. The method of claim 12,
The target value may be,
Wherein a different class for each data pair is determined for the same case and different case.
제12항에 있어서,
상기 가중치 학습 동작을 수행하는 단계는,
상기 산출된 유사도와 상기 타겟 값에 오류 역전파 알고리즘(error-back-propagation algorithm)을 적용하여 상기 가중치 학습 동작을 수행하는, 데이터 구분 방법.
13. The method of claim 12,
The step of performing the weight learning operation comprises:
Wherein the weight learning operation is performed by applying an error-back-propagation algorithm to the calculated similarity and the target value.
KR1020160038559A 2016-03-30 2016-03-30 Electronic apparatus for categorizing data and method thereof KR101763259B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020160038559A KR101763259B1 (en) 2016-03-30 2016-03-30 Electronic apparatus for categorizing data and method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020160038559A KR101763259B1 (en) 2016-03-30 2016-03-30 Electronic apparatus for categorizing data and method thereof

Publications (1)

Publication Number Publication Date
KR101763259B1 true KR101763259B1 (en) 2017-07-31

Family

ID=59419083

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020160038559A KR101763259B1 (en) 2016-03-30 2016-03-30 Electronic apparatus for categorizing data and method thereof

Country Status (1)

Country Link
KR (1) KR101763259B1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023058862A1 (en) * 2021-10-08 2023-04-13 삼성전자주식회사 Electronic device and control method for electronic device

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
Choi, Hyunsoek, and Hyeyoung Park. "A multimodal user authentication system using faces and gestures." BioMed research international 2015.
Choi, Hyunsoek, Jeongin Seo, and Hyeyoung Park. "Matrix correlation distance for 2D image classification." Proceedings of the 29th Annual ACM Symposium on Applied Computing. ACM, 2014.
CireŞAn, Dan, et al. "Multi-column deep neural network for traffic sign classification." Neural Networks 32, 2012.

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2023058862A1 (en) * 2021-10-08 2023-04-13 삼성전자주식회사 Electronic device and control method for electronic device

Similar Documents

Publication Publication Date Title
CN111079639B (en) Method, device, equipment and storage medium for constructing garbage image classification model
Zhang et al. Small sample image recognition using improved Convolutional Neural Network
EP3388978B1 (en) Image classification method, electronic device, and storage medium
Thai et al. Image classification using support vector machine and artificial neural network
CN105631398B (en) Method and apparatus for recognizing object and method and apparatus for training recognizer
US9633044B2 (en) Apparatus and method for recognizing image, and method for generating morphable face images from original image
JP4618098B2 (en) Image processing system
US7958070B2 (en) Parameter learning method, parameter learning apparatus, pattern classification method, and pattern classification apparatus
Haque et al. Two-handed bangla sign language recognition using principal component analysis (PCA) and KNN algorithm
Wang et al. Energy based competitive learning
CN109643384A (en) Method and apparatus for zero sample learning
KR20190126857A (en) Detect and Represent Objects in Images
Ling et al. Class-oriented discriminative dictionary learning for image classification
WO2023088174A1 (en) Target detection method and apparatus
Islam et al. A facial region segmentation based approach to recognize human emotion using fusion of HOG & LBP features and artificial neural network
CN112749737A (en) Image classification method and device, electronic equipment and storage medium
Hotta Local co-occurrence features in subspace obtained by KPCA of local blob visual words for scene classification
CN110111365B (en) Training method and device based on deep learning and target tracking method and device
CN103927522A (en) Face recognition method based on manifold self-adaptive kernel
Liu et al. A new patch selection method based on parsing and saliency detection for person re-identification
Okokpujie et al. Development of an adaptive trait-aging invariant face recognition system using convolutional neural networks
Ghorpade et al. Neural Networks for face recognition Using SOM
Islam et al. Human facial expression recognition system using artificial neural network classification of Gabor feature based facial expression information
KR101763259B1 (en) Electronic apparatus for categorizing data and method thereof
US11935302B2 (en) Object re-identification using multiple cameras

Legal Events

Date Code Title Description
E701 Decision to grant or registration of patent right
GRNT Written decision to grant