Skip to content

This repository demonstrates the implementation of a deep learning model trained with Differential Privacy (DP) and deployed using a Flask API. The project utilizes TensorFlow Privacy (TFP) to ensure data privacy while maintaining model utility.

License

Notifications You must be signed in to change notification settings

BVChandrahaas/DifferentialPrivacy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 

Repository files navigation

Differential Privacy for Deep Learning with Flask Deployment

Overview

This repository demonstrates the implementation of a deep learning model trained with Differential Privacy (DP) and deployed using a Flask API. The project utilizes TensorFlow Privacy (TFP) to ensure data privacy while maintaining model utility.This repository demonstrates the implementation of a deep learning model trained with Differential Privacy (DP) and deployed using a Flask API. The project utilizes TensorFlow Privacy (TFP) to ensure data privacy while maintaining model utility.

Features

  • Implementation of differentially private stochastic gradient descent (DPSGD) for model training
  • Deployment of the trained model via a Flask API for inference
  • Resources and links to further readings, tutorials, and relevant code libraries

Repository Structure

DifferentialPrivacy
├── Dp.py
└── app.py
└── requirements.txt
└── README.md

How to Use

Setup

  1. Clone the repository and navigate to its directory:
git clone https://github.com/BVChandrahaas/DifferentialPrivacy.git
cd DifferentialPrivacy
  1. Install the required dependencies:
pip install -r requirements.txt
  1. Train the Model Run the dp_training.py script to train the model with differential privacy:
python Dp.py

The trained model will be saved in the saved_model/ directory. Run the Flask App Start the Flask API server:

python app.py

By default, the app runs at http://127.0.0.1:5000.

Resources

  • Papers
    • Deep Learning with Differential Privacy by Abadi et al.
    • Federated Learning with Differential Privacy by McMahan et al.
  • Code Libraries
    • TensorFlow Privacy
    • PyTorch-DP
  • Tutorials
    • Differential Privacy Tutorial by Stanford Natural Language Processing Group
    • Federated Learning with Differential Privacy by TensorFlow Team

Contributing

We welcome contributions! Feel free to:

  • Fork this repository
  • Submit pull requests
  • Report issues

Your contributions will help improve Vanilla Split Learning.

License

This project is licensed under the MIT License.

See LICENSE for details.

About

This repository demonstrates the implementation of a deep learning model trained with Differential Privacy (DP) and deployed using a Flask API. The project utilizes TensorFlow Privacy (TFP) to ensure data privacy while maintaining model utility.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages