本篇論文提出「應用K-近鄰演算法(KNN, K-Nearest Neighbors)於訊號辨識的研究」。K-近鄰演算法在本篇論文中是以辨識心電圖(ECG)訊號中的「正常心跳類別」(NORM)、「心室過早收縮類別」(VPC)、及「心房過早收縮類別」(APC)等三種類別為範例說明。訊號辨識的應用,在本文是分成如下的三大過程說明,分別是:(1)訓練過程:本過程包含如下的四大部分,分別是:(a)心電圖(ECG)訊號的介紹;(b)特徵點的定義;(c)特徵值的取得;及(d)「訓練樣本集」的獲得;(2)距離的計算:計算未知類別之待辨識心電圖訊號與「訓練樣本集」中之每一個訓練樣本的歐氏距離;及(3)最終類別的判定:本過程包含如下的三大部分,分別是:(i)排序:將歐氏距離的計算結果,依距離值的大小,以由小而大的順序排序;(ii)取K 個訓練樣本及其對應的類別:依如上的排列順序,取排序在前面的K 個訓練樣本及其相對應的所屬類別;及(iii)判定未知類別之待辨識心電圖訊號的類別:尋找出現次數最多的類別,該類別即是未知類別之待辨識心電圖訊號所屬的最終類別。本文最後以K = 1及K =3的實驗方式,去尋找最靠近待辨識心電圖訊號的K個樣本點。經多次的測試,確認本文所提的K-近鄰演算法是一個簡單有效的辨識方法。 關鍵詞:K-近鄰演算法(K-Nearest Neighbors(KNN))、正常心跳類別(Normal heartbeats (NORM))、心室過早收縮類別(Ventricular premature contractions (VPC))、心房過早收縮類別(Atrial premature contractions (APC))。
This study applies the K-Nearest Neighbors (KNN, K-Nearest Neighbors) algorithm to signal identification. In this paper, the K-nearest neighbor algorithm is used to identify the Normal heartbeats (NORM), Ventricular premature contractions (VPC), and Atrial premature contractions (APC) in the electrocardiogram (ECG) signal. The application of signal recognition is divided into the following three major process in this article: (1) Training process: This process includes the following four parts, namely: (a) Electrocardiogram (ECG) signal introduction; (b) Definition of feature points; (c) Obtaining feature values; and (d) Obtaining "training sample set"; (2) Calculation of Euclideandistance: Calculating the unknown type of ECG signal to be identified and each of the "training sample set" of the training sample; and (3) The determination of the final category: This process includes the following three parts, namely: (i) Sorting: The calculation result of the Euclidean distance is determined by the distance value and be sorted in order from small to large; (ii) Take K training samples and their corresponding categories in the front; and (iii) Determine the category of the unknownECG signal: Find the category with the most occurrences. This category is the final category of the ECG signal to be identified in the unknown category. At the end of this article, K = 1 and K = 3 are used to find the K sample points closest to the ECG signal to be identified. After many tests, it is confirmed that the K-nearest neighbor algorithm proposed in this article is a simple and effective identification method. Keywords: K-Nearest Neighbors (KNN), Normal heartbeats (NORM), Ventricular Premature Contractions (VPC), Atrial Premature Contractions (APC).