Efficient Utility-Preserving Machine Unlearning with Implicit Gradient Surgery
Shiji Zhou, Tianbai Yu, Zhi Zhang, Heng Chang, Xiao Zhou, Dong Wu, Han Zhao
TL;DR
This work tackles the fundamental utility-unlearning tradeoff in machine unlearning by formulating the Problem as Utility-Preserving Unlearning (UPUP), a constrained optimization that maximizes unlearning while bounding utility loss. It establishes that solving UPUP is equivalent to unilateral gradient surgery on the unlearning gradient, and proposes Efficient Utility-Preserving Machine Unlearning (EUPMU) with an implicit gradient-surgery mechanism to avoid extra backpropagations. Theoretical analysis proves convergence to Pareto-optimal or stationary solutions under standard smoothness and Lipschitz assumptions, and empirical results on classification and diffusion-model generation show that EUPMU achieves better forgetting-utility tradeoffs and faster runtime than baselines. The approach offers a practical, provably sound, and computationally efficient path for responsible MU across diverse models and tasks, including image generation and NSFW content removal.
Abstract
Machine unlearning (MU) aims to efficiently remove sensitive or harmful memory from a pre-trained model. The key challenge is to balance the potential tradeoff between unlearning efficacy and utility preservation, which involves forgetting undesirable information as defined while maintaining the model's original performance. One potential way to tackle this problem is to use multi-objective optimization to jointly optimize both the unlearning and utility preservation objectives. However, existing multi-objective methods only guarantee finding a Pareto-optimal solution without fine-grained control, which causes under-optimization of the unlearning objective. To this end, we first model MU as a constrained optimization problem, that is, optimizing the unlearning objective under the constraint of a bounded increase for utility loss. We then show that solving this optimization problem is equivalent to unilateral gradient surgery on the unlearning objective. To resolve the additional computational cost brought by gradient surgery, we propose an implicit gradient surgery method, which approximates the solution to the aforementioned constrained optimization problem via only one backpropagation, thereby achieving efficient utility-preserving MU. Theoretically, we provide a tight convergence analysis of the algorithm. Empirically, our extensive experiments show that the proposed algorithm achieves better tradeoff results than existing baselines. Codes are available at https://github.com/anseryuer/EUPMU-Efficient-Utility-Preserving-Machine-Unlearning.
