Binary classification for arrythmia detection with ECG datasets.

Overview

HEART DISEASE AI DATATHON 2021

[Eng] / [Kor]


#English

This is an AI diagnosis modeling contest that uses the heart disease echocardiography and electrocardiogram datasets for artificial intelligence learning promoted as part of the "2021 AI Learning Data Construction Project" to discriminate echocardiography/electrocardiogram diseases.

Task II. Arrythmia on ECG datasets

0. Model

Resnet-based architecture.
Best AUC-ROC Score: 0.9986926250732517

1. Installation

1.1. Environment

Python >= 3.6

1.2. Requirements:

  • tensorflow >= 2.5
  • xmltodict
  • scikit-learn
  • matplotlib
  • numpy
pip install -r requirements.txt

2. Usage

2.1. Training

  1. Basic usage
python train.py -d electrocardiogram/data/train -s model.h5
  1. Training with 8 leads inputs, elevation adjustment, data augmentation and gqussian noises
python train.py -d electrocardiogram/data/train -s model.h5 -l 8 -v -a -n

To see more options:

python train.py -h
  • options:
    • -d, --data : File path of training data
    • -s, --save : File name for saving trained model (extension should be '.h5')
    • -b, --batch : Batch size (default=500)
    • -e, --epoch : Number of epochs (default=50)
    • -l, --lead : Number of leads to be trained (2/8/12) (default=2)
    • -v, --elevation : Option for adjusting elevation
    • -a, --augmentation : Option for data augmentation (stretching & amplifying)
    • -n, --noise : Option for adding noise on data

2.2. Evaluation

  1. Basic usage
python eval.py -d electrocardiogram/data/validation -m model.h5
  1. Evaluation with the best model
python eval.py -d electrocardiogram/data/validation -m best.h5
  1. Evaluation with 12 leads inputs and elevation adjustment
python eval.py -d electrocardiogram/data/validation -m model.h5 -l 12 -v

To see more options:

python eval.py -h
  • options:
    • -d, --data : File path of validation data
    • -m, --model : File name of saved model
    • -l, --lead : Number of leads being trained (default=2) (2/8/12)
    • -v, --elevation : Option for adjusting elevation

#Korean

심초음파/심전도 ai 모델 데이터톤 2021

이 경진대회는 "2021 인공지능 학습용 데이터 구축사업"의 일환으로 추진된 인공지능 학습용 심장질환 심초음파 및 심전도 데이터셋을 이용하여 심초음파/심전도 질환을 판별하는 AI 진단 모델링 경진대회입니다.

Task II. Arrythmia on ECG datasets

심전도 데이터셋을 활용한 부정맥 진단 AI 모델 공모(심전도 데이터셋을 활용한 부정맥 진단 AI 모델 개발)

0. 모델

Resnet 구조 기반의 Binary classification model.
Best AUC-ROC Score: 0.9986926250732517

1. 설치

1.1. 환경

Python >= 3.6

1.2. 필요한 패키지:

  • tensorflow >= 2.5
  • xmltodict
  • scikit-learn
  • matplotlib
  • numpy
pip install -r requirements.txt

2. 사용법

2.1. Training

  1. 기본 사용법 예시 (제출용)
python train.py -d electrocardiogram/data/train -s model.h5
  1. 8개 리드, 상하조정, 데이터 어그멘테이션, 노이즈 적용
python train.py -d electrocardiogram/data/train -s model.h5 -l 8 -v -a -n

To see more options:

python train.py -h
  • options:
    • -d, --data : 트레이닝 데이터 경로
    • -s, --save : 학습된 모델명 (확장자 .h5로 써줄 것)
    • -b, --batch : 배치 사이즈 (default=500)
    • -e, --epoch : 에포크 수 (default=50)
    • -l, --lead : 트레이닝에 쓸 리드 수 (2/8/12) (default=2)
    • -v, --elevation : 상하 조정 옵션
    • -a, --augmentation : 데이터 어그멘테이션 옵션 (stretching & amplifying)
    • -n, --noise : 가우시안 노이즈 적용 옵션

2.2. Evaluation

  1. 기본 사용법 예시
python eval.py -d electrocardiogram/data/validation -m model.h5
  1. 체출된 Best model 평가 (제출용)
python eval.py -d electrocardiogram/data/validation -m best.h5
  1. 12개 리드, 상하조정 적용
python eval.py -d electrocardiogram/data/validation -m model.h5 -l 12 -v

To see more options:

python eval.py -h
  • options:
    • -d, --data : 벨리데이션 데이터 경로
    • -m, --model : 불러올 모델 파일명
    • -l, --lead : 트레이닝된 리드 수 (2/8/12) (default=2)
    • -v, --elevation : 상하 조정 옵션
You might also like...
MOT-Tracking-by-Detection-Pipeline - For Tracking-by-Detection format MOT (Multi Object Tracking), is it a framework that separates Detection and Tracking processes? Object detection on multiple datasets with an automatically learned unified label space.
Object detection on multiple datasets with an automatically learned unified label space.

Simple multi-dataset detection An object detector trained on multiple large-scale datasets with a unified label space; Winning solution of E

Models, datasets and tools for Facial keypoints detection

Template for Data Science Project This repo aims to give a robust starting point to any Data Science related project. It contains readymade tools setu

A general and strong 3D object detection codebase that supports more methods, datasets and tools (debugging, recording and analysis).

ALLINONE-Det ALLINONE-Det is a general and strong 3D object detection codebase built on OpenPCDet, which supports more methods, datasets and tools (de

This project is the official implementation of our accepted ICLR 2021 paper BiPointNet: Binary Neural Network for Point Clouds.
This project is the official implementation of our accepted ICLR 2021 paper BiPointNet: Binary Neural Network for Point Clouds.

BiPointNet: Binary Neural Network for Point Clouds Created by Haotong Qin, Zhongang Cai, Mingyuan Zhang, Yifu Ding, Haiyu Zhao, Shuai Yi, Xianglong Li

[CVPRW 21]
[CVPRW 21] "BNN - BN = ? Training Binary Neural Networks without Batch Normalization", Tianlong Chen, Zhenyu Zhang, Xu Ouyang, Zechun Liu, Zhiqiang Shen, Zhangyang Wang

BNN - BN = ? Training Binary Neural Networks without Batch Normalization Codes for this paper BNN - BN = ? Training Binary Neural Networks without Bat

Pytorch reimplement of the paper "A Novel Cascade Binary Tagging Framework for Relational Triple Extraction" ACL2020. The original code is written in keras.

CasRel-pytorch-reimplement Pytorch reimplement of the paper "A Novel Cascade Binary Tagging Framework for Relational Triple Extraction" ACL2020. The o

Binary Passage Retriever (BPR) - an efficient passage retriever for open-domain question answering

BPR Binary Passage Retriever (BPR) is an efficient neural retrieval model for open-domain question answering. BPR integrates a learning-to-hash techni

Extract MNIST handwritten digits dataset binary file into bmp images

MNIST-dataset-extractor Extract MNIST handwritten digits dataset binary file into bmp images More info at http://yann.lecun.com/exdb/mnist/ Dependenci

Owner
HY_Kim
CSer in SUNY Korea.
HY_Kim
SE-MSCNN: A Lightweight Multi-scaled Fusion Network for Sleep Apnea Detection Using Single-Lead ECG Signals

SE-MSCNN: A Lightweight Multi-scaled Fusion Network for Sleep Apnea Detection Using Single-Lead ECG Signals Abstract Sleep apnea (SA) is a common slee

null 9 Dec 21, 2022
A real world application of a Recurrent Neural Network on a binary classification of time series data

What is this This is a real world application of a Recurrent Neural Network on a binary classification of time series data. This project includes data

Josep Maria Salvia Hornos 2 Jan 30, 2022
Implement face detection, and age and gender classification, and emotion classification.

YOLO Keras Face Detection Implement Face detection, and Age and Gender Classification, and Emotion Classification. (image from wider face dataset) Ove

Chloe 10 Nov 14, 2022
An easy way to build PyTorch datasets. Modularly build datasets and automatically cache processed results

EasyDatas An easy way to build PyTorch datasets. Modularly build datasets and automatically cache processed results Installation pip install git+https

Ximing Yang 4 Dec 14, 2021
Deep Learning Datasets Maker is a QGIS plugin to make datasets creation easier for raster and vector data.

Deep Learning Dataset Maker Deep Learning Datasets Maker is a QGIS plugin to make datasets creation easier for raster and vector data. How to use Down

deepbands 25 Dec 15, 2022
Cl datasets - PyTorch image dataloaders and utility functions to load datasets for supervised continual learning

Continual learning datasets Introduction This repository contains PyTorch image

berjaoui 5 Aug 28, 2022
Official implementation of "Towards Good Practices for Efficiently Annotating Large-Scale Image Classification Datasets" (CVPR2021)

Towards Good Practices for Efficiently Annotating Large-Scale Image Classification Datasets This is the official implementation of "Towards Good Pract

Sanja Fidler's Lab 52 Nov 22, 2022
Simple-Image-Classification - Simple Image Classification Code (PyTorch)

Simple-Image-Classification Simple Image Classification Code (PyTorch) Yechan Kim This repository contains: Python3 / Pytorch code for multi-class ima

Yechan Kim 8 Oct 29, 2022
Image Classification - A research on image classification and auto insurance claim prediction, a systematic experiments on modeling techniques and approaches

A research on image classification and auto insurance claim prediction, a systematic experiments on modeling techniques and approaches

null 0 Jan 23, 2022
Hl classification bc - A Network-Based High-Level Data Classification Algorithm Using Betweenness Centrality

A Network-Based High-Level Data Classification Algorithm Using Betweenness Centr

Esteban Vilca 3 Dec 1, 2022