Skip to main content

Posts

Showing posts from September, 2020
 Sự khác nhau giữa độ chính xác (Precision) và độ nhắc lại (Recall). (Viết lại) Predicted \Fact:           Positives  |    Negatives Positives        ||               TP            |       FN  -------------   --------------------------- Negatives       ||               FP            |       TN Độ chính xác mô tả ý nghĩa như sau:  Giả sử ta có một quần thể cần tìm ra trong quần thể có bao nhiêu cá thể dương tính (Positives) và bao nhiêu cá thể âm tính (Negatives).  Một phương pháp A có độ chính xác (precision) 80% có nghĩa là nếu ta thực hiện 100 mẫu kiểm định và phát hiện ra 40 mẫu có phát hiện  có dương tính trong đó, thì với độ chính xác 80%, khả năng là 40*0.8 = 32  mẫu là dương tính ...

Applying neural network for 1D-signal ppg

 In this post, I jot down some useful thing need to notice when trying to test a model with Python and Keras for newbies like me. First, segment data with python command Second, organization data to fit the built-in model in Keras Third, experience with training model with preprocessing data with MinMaxScaler. 1. Segment Data with Python In python to import data, the easy and regular way is employing `read_csv` function from pandas package. File format often in .txt, .csv, or .xls but prefer to save and load .csv file because I can explore, verify, and manipulate on Excel software confidently. Let's start by read a csv file name "InvertPhaseLong2.csv" as below from  pandas  import  read_csv dataset = read_csv( 'drive/My Drive/InvertPhaseLong2.csv' , header= 0 ) header= 0 mean the file contains a header in the first rows, in case we do not care header then let set it as header=None The file dataset is in the format of pandas as DataFrame so in this...