This project explores the use of Federated Learning for predicting patient mortality in Intensive Care Units (ICUs) using the MIMIC-III clinical dataset.
- Perform supervised classification to predict mortality outcomes.
- Implement non-IID data distribution across multiple simulated clients (e.g., hospitals).
- Compare performance between a federated model and a centralized model.
data/: Contains raw CSV files extracted from MIMIC-III (e.g.,CHARTEVENTS.csv,LABEVENTS.csv, etc.)client_{i}_data.csv: Partitioned non-IID data for each client.final_dataset_with_mortality.csv: Final dataset including mortality labels.non_iid_distribution.png: Visualization of data distribution across clients.federated_vs_centralized_performance.png: Side-by-side performance comparison.bdm_federated_learning_mimic_iii.py: Main script containing the full pipeline.
- Python (NumPy, Pandas, Matplotlib)
- PyTorch
- Scikit-learn
- Google Colab
- MIMIC-III Dataset (via PhysioNet)
-
Data Preprocessing
- Extraction of key clinical features (e.g., GCS, vital signs, PaO₂/FiO₂, urine output, lab results)
- Cleaning and handling of missing/outlier values
-
Label Engineering
- In-hospital mortality
- 48-hour ICU mortality
- 30-day post-discharge mortality
-
Federated Learning Implementation
- Non-IID partitioning across 10 clients
- Local neural networks trained independently
- Federated Averaging (FedAvg) for global model updates
- Performance monitoring + early stopping
-
Evaluation & Visualization
- Local and global model accuracy
- Loss and accuracy curves per round
- Comparison against a centralized model
-
Federated Model:
- Aggregates local client updates using FedAvg
- Achieves competitive test accuracy across clients
-
Centralized Model:
- Trained on combined data for baseline comparison
Visualizations showcase class distributions, training dynamics, and final performance comparisons.
Watch a quick walkthrough of the project here:
👉 Project Demo (Google Drive)
- Download the MIMIC-III dataset and upload it to Google Drive
- Run the
bdm_federated_learning_mimic_iii.pyscript on Google Colab - Outputs and plots will be saved automatically
- Developed by [DJABRI Maroua ,BOUYAHIAOUI Meriem , DINARI Yasmine ,REZZOUG Aicha] as part of the Big Data Mining course project
- Dataset used: MIMIC-III Clinical Database