This repository is developed to perform experiments and benchmarks for understanding the impact of differential privacy (DP) on machine learning algorithms. It leverages IBM's Diffprivlib, providing state-of-the-art methods for integrating differential privacy into machine learning workflows. Additionally, we designed custom benchmarking pipelines to evaluate the performance of these methods across multiple metrics.
The repository is organized as follows:
DIFFERENTIAL_PRIVACY
├── modules
│ ├── dp_benchmark.py # Main benchmarking module
│ ├── utils.py # Utility functions for the benchmarks
├── notebooks
│ ├── dp_benchmark.ipynb # Notebook to run benchmarks and visualize results
│ ├── dp_exploration_and_modeling.ipynb # Exploratory analysis and DP modeling
└── plots
└── .gitignore # Git ignore file
└── LICENSE # License information
└── README.md # Documentation (you are here!)
└── requirements.txt # Dependencies for the project
Differential Privacy (DP) is a mathematical framework that ensures privacy protection for individuals within a dataset. In this repository:
- We evaluate the effects of differential privacy on machine learning algorithms, focusing on balancing privacy guarantees with model performance.
- We utilize IBM's Diffprivlib library to incorporate DP mechanisms into algorithms like logistic regression and decision trees.
- We create custom benchmarks to evaluate metrics such as accuracy, precision, recall, F1 score.
- Understand the trade-offs between privacy (epsilon) and model performance.
- Benchmark differential privacy algorithms across various datasets and metrics.
- Visualize and interpret results to better understand the impacts of differential privacy mechanisms.
Benchmarks are designed to compare non-private machine learning models with differentially private ones under varying privacy budgets (epsilon). Results are stored and visualized in the plots/ directory.
Make sure you have Python 3.9 installed. You can create a Conda environment for this project:
conda create --name dp_env python=3.9
conda activate dp_env