Icon

ecg_​cnn_​ptb

ECG Heartbeat Classification Dataset (PTB)

This ECG dataset is provided by Physikalisch-Technische Bundesanstalt (PTB) and is available on Kaggle (https://www.kaggle.com/shayanfazeli/heartbeat). This dataset is pre-processed with beats recorded in a 10 second window and is classified as either normal (0.0) or abnormal (1.0). For more details, please read the paper at (https://arxiv.org/pdf/1805.00794.pdf).

In this workflow Conv1D Neural Network is trained for the classification task. The neural network implemented is a small version of what is described in the paper.

Read more about these workflows here: https://www.knime.com/blog/ecg-categorization-to-detect-arrhythmia

URL: Link to Kaggle Dataset https://www.kaggle.com/shayanfazeli/heartbeat
URL: Associated Research Paper https://arxiv.org/pdf/1805.00794.pdf

Read data for Physikalisch-Technische Bundesanstalt (PTB) ECG dataset available on Kaggle: https://www.kaggle.com/shayanfazeli/heartbeat

PTB dataset is already preprocessed with heartbeats classified as normal (0) and abnormal (1) in class variable. For more details
on prepreocessing, read the preprocessing section in this paper: https://arxiv.org/pdf/1805.00794.pdf

This data set is imbalanced with roughly 10,000 rows for abnormal class and 4000 rows for normal class.

Visualize sample Beats and Statistics from each class.

This part of workflow deals with modelling on processed data

Train/Test Split with 80% for train and 20% for test
Partitioning
ptbd_abnormal
CSV Reader
ptbd_normal
CSV Reader
Save weights of trained model
Keras Network Writer
Merge datasets
Concatenate
Many to One
Predictions on test data
Keras Network Executor
Plot Sample Beats
Check model performance
Scorer
Convert class variable toString to use for Stratified Sampling
Number to String
Shuffle Rows to input in
Shuffle
Join predictions column and test data class column
Joiner
Important! Swap the order of 1.0 and 0.0
Column Resorter
Keras model structure
Neural Network Model
One-Hot Encode
One to Many
Describe statistics for each column 72.2% data with abnormal class 28.8% data with normal class
Statistics
Add decimal to String Predictions
Add in Decimal
Final configurations for neural network
Keras Network Learner
Creates a Conda Env
Conda Environment Propagation
Oversample minority class to adjust class imbalance
SMOTE

Nodes

Extensions

Links