https://github.com/graph-com/sgd_unlearning
https://github.com/graph-com/sgd_unlearning
Last synced: 5 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/graph-com/sgd_unlearning
- Owner: Graph-COM
- Created: 2024-01-17T16:37:26.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-10-26T22:09:09.000Z (over 1 year ago)
- Last Synced: 2025-07-17T06:48:12.228Z (7 months ago)
- Language: Jupyter Notebook
- Size: 24.2 MB
- Stars: 4
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SGD_Unlearning
This is the official implementation of **Neurips 2024** paper
[Certified Machine Unlearning via Noisy Stochastic Gradient Descent](https://arxiv.org/abs/2403.17105)
By Eli Chien, Haoyu Wang, Ziang Chen and Pan Li.
Please also check our **NeurIPS 2024 Spotlight** paper
[Langevin Unlearning: A New Perspective of Noisy Gradient Descent for Machine Unlearning](https://arxiv.org/abs/2401.10371)
## Environment requirements
The code is runnable under the following enveironment:
````
matplotlib 3.7.2
notebook 7.0.7
numpy 1.24.4
pandas 2.0.3
scikit-learn 1.3.0
scipy 1.10.1
seaborn 0.13.0
torch 2.0.0+cu117
torchvision 0.15.1+cu117
tqdm 4.65.0
````
## To implement and re-produce the result in Figure 3.a, run
````
python main_sgd.py --lam 1e-6 --dataset [MNIST/CIFAR10] --projection 0 --compare_baseline_nonconvergent 1
````
## To implement and re-produce the result in Figure 3.b, run
````
python main_sgd.py --lam 1e-6 --dataset [MNIST/CIFAR10] --projection 0 --sequential 1
````
## To implement and re-produce the result in Figure 3.c.d, run
````
python main_sgd.py --lam 1e-6 --dataset [MNIST/CIFAR10] --projection 0 --paint_unlearning_sigma 1
````
## Note
* use --gpu to allocate to a GPU device
* /result/SGD saves the results we run and report in our paper
## Citation
If you find our work useful, please cite us:
```
@misc{chien2024certifiedmachineunlearningnoisy,
title={Certified Machine Unlearning via Noisy Stochastic Gradient Descent},
author={Eli Chien and Haoyu Wang and Ziang Chen and Pan Li},
year={2024},
eprint={2403.17105},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/2403.17105},
}
```