arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2302.02334cs.LGcs.AIstat.ML
收藏

重新审视判别式与生成式分类器:理论与启示

Revisiting Discriminative vs. Generative Classifiers: Theory and Implications

Gaoling School of AI, Renmin University of China(中国人民大学高瓴人工智能学院);School of Software, Shandong University(山东大学软件学院);Tsinghua University(清华大学);Beijing Academy of Artificial Intelligence(北京智源人工智能研究院)

Chenyu Zheng, Guoqiang Wu, Fan Bao, Yue Cao, Chongxuan Li, Jun Zhu

AI总结:

本文从理论上证明多分类朴素贝叶斯仅需 $O(\log n)$ 样本即可逼近渐近误差,优于逻辑回归的 $O(n)$,并通过仿真和预训练视觉模型实验验证了其在迁移学习和少样本场景中的快速收敛优势。

摘要:

在海量有标签或无标签数据上预训练的大规模深度模型能够很好地迁移到下游任务。线性评估冻结预训练模型中的参数,并单独训练一个线性分类器,这种方式高效且对迁移具有吸引力。然而,除了默认的逻辑回归之外,很少有工作研究线性评估中的分类器选择问题。受朴素贝叶斯统计效率的启发,本文重新审视了判别式与生成式分类器这一经典主题。在理论上,本文在分析中考虑替代损失而非零一损失,并将经典结果从二分类情形推广到多分类情形。我们证明,在温和假设下,多分类朴素贝叶斯需要 $O(\log n)$ 个样本即可逼近其渐近误差,而相应的多分类逻辑回归则需要 $O(n)$ 个样本,其中 $n$ 为特征维度。为建立这一结论,我们提出了一个多分类 $\mathcal{H}$-一致性界框架,并给出了逻辑损失的显式界,这些结果本身也具有独立的研究价值。在高斯混合模型上的仿真结果验证了我们的理论发现。在多种预训练深度视觉模型上的实验表明,随着数据量的增加,朴素贝叶斯始终收敛得更快。此外,朴素贝叶斯在少样本场景中展现出潜力,并且我们在预训练监督模型中观察到了“两种机制”现象。我们的代码可在 https://github.com/ML-GSAI/Revisiting-Dis-vs-Gen-Classifiers 获取。

英文摘要:

A large-scale deep model pre-trained on massive labeled or unlabeled data transfers well to downstream tasks. Linear evaluation freezes parameters in the pre-trained model and trains a linear classifier separately, which is efficient and attractive for transfer. However, little work has investigated the classifier in linear evaluation except for the default logistic regression. Inspired by the statistical efficiency of naive Bayes, the paper revisits the classical topic on discriminative vs. generative classifiers. Theoretically, the paper considers the surrogate loss instead of the zero-one loss in analyses and generalizes the classical results from binary cases to multiclass ones. We show that, under mild assumptions, multiclass naive Bayes requires $O(\log n)$ samples to approach its asymptotic error while the corresponding multiclass logistic regression requires $O(n)$ samples, where $n$ is the feature dimension. To establish it, we present a multiclass $\mathcal{H}$-consistency bound framework and an explicit bound for logistic loss, which are of independent interests. Simulation results on a mixture of Gaussian validate our theoretical findings. Experiments on various pre-trained deep vision models show that naive Bayes consistently converges faster as the number of data increases. Besides, naive Bayes shows promise in few-shot cases and we observe the "two regimes" phenomenon in pre-trained supervised models. Our code is available at https://github.com/ML-GSAI/Revisiting-Dis-vs-Gen-Classifiers.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑