Selective Forgetting of Deep Networks at a Finer Level than Samples

Tomohiro Hayase, Suguru Yasutomi, Takashi KatoharXiv 2020

Abstract

Selective forgetting or removing information from deep neural networks (DNNs) is essential for continual learning and is challenging in controlling the DNNs. Such forgetting is crucial also in a practical sense since the deployed DNNs may be trained on the data with outliers, poisoned by attackers, or with leaked/sensitive information. In this paper, we formulate selective forgetting for classification tasks at a finer level than the samples' level. We specify the finer level based on four datasets distinguished by two conditions: whether they contain information to be forgotten and whether they are available for the forgetting procedure. Additionally, we reveal the need for such formulation with the datasets by showing concrete and practical situations. Moreover, we introduce the forgetting procedure as an optimization problem on three criteria; the forgetting, the correction, and the remembering term. Experimental results show that the proposed methods can make the model forget to use specific information for classification. Notably, in specific cases, our methods improved the model's accuracy on the datasets, which contains information to be forgotten but is unavailable in the forgetting procedure. Such data are unexpectedly found and misclassified in actual situations.

Introduction

Deep neural networks (DNNs) often encounter data that must subsequently be forgotten to comply with privacy regulations (e.g., GDPR), remove noisy outliers, or mitigate the effects of malicious data poisoning. Traditional "selective forgetting" or machine unlearning typically focuses on removing entire training samples. However, retraining from scratch is computationally prohibitive, and original datasets may no longer be fully accessible.

This paper proposes a framework for fine-grained, feature-level forgetting. Instead of discarding entire samples, the goal is to scrub specific unwanted features—such as a backdoor trigger or a background shortcut—while retaining the model's core classification capabilities. This approach is particularly relevant for scenarios where only a small subset of data is available for the unlearning process.

Problem Formulation and Methodology

The authors categorize the data environment into four distinct subsets to facilitate targeted forgetting:

  1. $\mathcal{D}_r$: The original dataset to be remembered, assumed inaccessible during forgetting.
  2. $\mathcal{D}_f$: A small subset containing the features to be forgotten.
  3. $\mathcal{D}_{f, \text{clean}}$: A version of $\mathcal{D}_f$ where the target features have been removed.
  4. $\mathcal{D}_{r, \text{extra}}$: A validation set of normal data with the target feature artificially added, used to evaluate the robustness of the forgetting process.
Conceptual framework of selective forgetting across different patterns and datasets.

The proposed forgetting procedure optimizes a composite loss function consisting of three terms:

  • Forgetting Term ($L_f$): Employs Random Label Distillation (RLD) to force the model toward a uniform distribution of class probabilities when presented with $\mathcal{D}_f$. The authors found that RLD outperforms Random Network Distillation (RND) in terms of stability and effectiveness.
  • Correction Term ($L_c$): Uses standard cross-entropy loss on $\mathcal{D}_{f, \text{clean}}$ to reinforce correct classification logic.
  • Remembering Term ($R$): Utilizes Elastic Weight Consolidation (EWC) to preserve knowledge from the inaccessible $\mathcal{D}_r$ by penalizing changes to weights critical for the original task. While EWC acts as an anchor for general knowledge, the authors note that traces of forgotten features may persist in the Fisher Information Matrix.

Experimental Evaluation

The framework was evaluated on Fashion-MNIST and CIFAR10. To simulate feature-level forgetting, "backdoors" (e.g., bright streaks or tiles) were injected into specific classes.

Softmax output distributions comparing different forgetting methods.

Key results indicate that the combination of CE + Fisher + RLD effectively decouples malicious features from decision-making. In sample-level forgetting tasks (Pattern A), the RLD method successfully reduced model accuracy on the forgotten class to near zero (0.012 on Fashion-MNIST and 0.000 on CIFAR10) while maintaining high performance on the remaining data (~82% and ~48% respectively).

As shown in Figure 4, the RLD-based method successfully flattens the softmax output for the target class (e.g., class 6: Shirt), indicating effective unlearning compared to the highly peaked distribution of the original model ("Scratch"). Furthermore, the model demonstrated significantly improved accuracy on $\mathcal{D}_{r, \text{extra}}$, proving that the forgetting generalizes to unseen data containing the unwanted feature rather than just memorizing specific training corrections. This quantitative jump confirms that an active "forgetting" term is strictly necessary for true unlearning.

Conclusion

This work demonstrates that selective forgetting at a sub-sample level is both feasible and effective. By leveraging RLD and EWC, models can be scrubbed of unwanted features without full retraining. Future work includes automating the discovery of features to be forgotten, potentially using domain translation techniques like CycleGAN to isolate poisoned data distributions more efficiently.

Summary updated

BibTeX
@misc{hayase2020selective,
  author = {Tomohiro Hayase and Suguru Yasutomi and Takashi Katoh},
  title = {{Selective Forgetting of Deep Networks at a Finer Level than Samples}},
  year = {2020},
  eprint = {2012.11849},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2012.11849},
}
Figure