[Paper Review] Decoupled Kullback-Leibler Divergence Loss
The paper shows KL loss is equivalent to a decoupled form (DKL) comprising a weighted MSE and a cross-entropy with soft labels, and proposes IKL by breaking asymmetry and adding global information to achieve state-of-the-art results in adversarial training and knowledge distillation.
In this paper, we delve deeper into the Kullback-Leibler (KL) Divergence loss and mathematically prove that it is equivalent to the Decoupled Kullback-Leibler (DKL) Divergence loss that consists of 1) a weighted Mean Square Error (wMSE) loss and 2) a Cross-Entropy loss incorporating soft labels. Thanks to the decomposed formulation of DKL loss, we have identified two areas for improvement. Firstly, we address the limitation of KL/DKL in scenarios like knowledge distillation by breaking its asymmetric optimization property. This modification ensures that the $\mathbf{w}$MSE component is always effective during training, providing extra constructive cues. Secondly, we introduce class-wise global information into KL/DKL to mitigate bias from individual samples. With these two enhancements, we derive the Improved Kullback-Leibler (IKL) Divergence loss and evaluate its effectiveness by conducting experiments on CIFAR-10/100 and ImageNet datasets, focusing on adversarial training, and knowledge distillation tasks. The proposed approach achieves new state-of-the-art adversarial robustness on the public leaderboard -- RobustBench and competitive performance on knowledge distillation, demonstrating the substantial practical merits. Our code is available at https://github.com/jiequancui/DKL.
Motivation & Objective
- Explain the gradient optimization mechanism of KL divergence and show its equivalence to a Decoupled Kullback-Leibler (DKL) loss.
- Identify limitations of DKL in asymmetry and lack of global context, especially in knowledge distillation.
- Propose improvements by breaking asymmetry and incorporating global information to form the Improved Kullback-Leibler (IKL) loss.
- Demonstrate IKL's effectiveness via adversarial training and knowledge distillation experiments on CIFAR-10/100 and ImageNet.
Proposed method
- Reformulate KL divergence as a Decoupled Kullback-Leibler (DKL) loss consisting of a weighted MSE term and a cross-entropy term with soft labels.
- Show that DKL can have asymmetric gradient flows between inputs, which can reduce the wMSE component during training.
- Introduce IKL by (i) breaking the asymmetry to ensure both loss terms contribute to optimization and (ii) incorporating global (class-wise) information as regularization.
- Define class-wise weights using the average predictions for each ground-truth class to inject global information into the weighted MSE.
- Empirically evaluate IKL on adversarial training and knowledge distillation tasks across CIFAR-10/100 and ImageNet.
Experimental results
Research questions
- RQ1How does KL divergence behave under gradient-based optimization, and can it be decomposed into complementary components (wMSE and cross-entropy) without loss of generality?
- RQ2What are the limitations of the DKL formulation in training scenarios like knowledge distillation due to gradient asymmetry?
- RQ3Can breaking asymmetry and adding global information improve performance in adversarial training and knowledge distillation?
- RQ4Does the proposed IKL loss yield state-of-the-art results on CIFAR-10/100 and ImageNet for the targeted tasks?
Key findings
- KL loss is mathematically equivalent to a decoupled form (DKL) consisting of a weighted MSE loss and a cross-entropy loss with soft labels.
- DKL optimization is asymmetric with respect to inputs, which can cause the wMSE component to be neglected in scenarios like knowledge distillation.
- IKL breaks the asymmetry and incorporates global information, yielding improved intra-class consistency.
- Experiments show IKL achieves new state-of-the-art results for adversarial training and knowledge distillation on CIFAR-10/100 and ImageNet.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.