Skip to content

Secure feature engineering for ML based on pysyft 0.2.x, just for personal learning

Notifications You must be signed in to change notification settings

shadowyee/secure-feature-engineering

Repository files navigation

1. Environment

Python=3.7 Pysyft=0.2.x torch=1.4.0 ...

2. Installation

  • Install Pysyft 0.2.x-fix-training package:
wget https://github.com/OpenMined/PySyft/archive/refs/heads/ryffel/0.2.x-fix-training.zip
unzip 0.2.x-fix-training.zip
conda create -n <env_name> python=3.7
conda activate <env_name>
  • Install dependency:
cd 0.2.x-fix-training
pip install -e .

If you encountered some errors when installing dependency, try to comment out dict object extras_require in setup.py. Maybe pip install protobuf~=3.19.0 is also required. And when you fail to install pylibsrtp, try apt install libsrtp2-dev.

  • Pysyft 0.2.x bug fix: Because 0.2.x version is not supported anymore, you may encounter some bug when using it. If you want to run this project correctly, try to modify 0.2.x-fix-training/syft/frameworks/torch/tensors/interpreters/gradients.py line 40:
<<< old code 
if not isinstance(self.other.child, int):
>>> new code
if torch.is_tensor(self.other) and not isinstance(self.other.child, int):

3. Backend Deployment

  • update the Flask (from 1.1.1 to 2.2.5) warning: syft 0.2.9 is not supported by flask 2.2.5
pip uninstall flask
pip install flask

About

Secure feature engineering for ML based on pysyft 0.2.x, just for personal learning

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published