Schematic Overview of HRV Classification Pipeline.
If you use this work, please cite it as:
@article{goretti2025deep,
title={Deep Learning for Risky Cardiovascular and Cerebrovascular Event Prediction in Hypertensive Patients},
author={Goretti, F. and Salman, A. and Cartocci, A. and Luschi, A. and Pecchia, L. and Milli, M. and Iadanza, E.},
journal={Applied Sciences},
volume={15},
number={3},
pages={1178},
year={2025},
publisher={MDPI},
doi={10.3390/app15031178}
}
In this study, we tackle the processing of patients’ heart rate variability (HRV) datasets for two classification tasks employing resource-efficient methods, synthetic data generation, deep learning techniques, and transfer learning.
You are free to use, modify, and distribute this project for any purpose. However, if you use this project in your work or derive from it, you must provide appropriate attribution by referencing this repository.
Refer to our, MIT License.
git clone https://github.com/alexsalman/heart_rate_variability.git
cd heart_rate_variability
conda create -n <env-name>
source activate <env-name>
pip install -r requirements.txt
python src/data/make_dataset.py data/raw/<Atrial Fibrillation Data> data/interim/
python src/data/make_dataset.py data/raw/<Cardiovascular Event Data> data/interim/
Create metadata for training sets and data generator objects, models fitting, and sample synthetic records
python src/data/generate_synthetic.py data/interim/<Atrial Fibrillation Training Data> data/processed/
python src/data/generate_synthetic.py data/interim/<Cardiovascular Event Training Data> data/processed/
python src/models/train_model.py data/processed/<Atrial Fibrillation Synthetic Training Data> models/
python src/models/test_model.py data/interim/<Atrial Fibrillation Real Test Data> reports/figures/
python src/models/train_model.py data/processed/<Cardiovascular Event Synthetic/Real Training Data> models/
python src/models/test_model.py data/interim/<Cardiovascular Event Real Test Data> reports/figures/
├── LICENSE
├── Makefile <- Makefile with commands like `make data` or `make train`
├── README.md <- The top-level README for developers using this project.
├── data
│ ├── external <- Data from third party sources.
│ ├── interim <- Intermediate data that has been transformed.
│ ├── processed <- The final, canonical data sets for modeling.
│ └── raw <- The original, immutable data dump.
│
├── docs <- A default Sphinx project; see sphinx-doc.org for details
│
├── models <- Trained and serialized models, model predictions, or model summaries
│
├── notebooks <- Jupyter notebooks. Naming convention is a number (for ordering),
│ the creator's initials, and a short `-` delimited description, e.g.
│ `1.0-jqp-initial-data-exploration`.
│
├── references <- Data dictionaries, manuals, and all other explanatory materials.
│
├── reports <- Generated analysis as HTML, PDF, LaTeX, etc.
│ └── figures <- Generated graphics and figures to be used in reporting
│
├── requirements.txt <- The requirements file for reproducing the analysis environment, e.g.
│ generated with `pip freeze > requirements.txt`
│
├── setup.py <- makes project pip installable (pip install -e .) so src can be imported
├── src <- Source code for use in this project.
│ ├── __init__.py <- Makes src a Python module
│ │
│ ├── data <- Scripts to download or generate data
│ │ └── make_dataset.py
│ │
│ ├── features <- Scripts to turn raw data into features for modeling
│ │ └── build_features.py
│ │
│ ├── models <- Scripts to train models and then use trained models to make
│ │ │ predictions
│ │ ├── predict_model.py
│ │ └── train_model.py
│ │
│ └── visualization <- Scripts to create exploratory and results oriented visualizations
│ └── visualize.py
│
└── tox.ini <- tox file with settings for running tox; see tox.readthedocs.io
Project based on the cookiecutter data science project template. #cookiecutterdatascience