# Vapnik–Chervonenkis 维

一类二值分类器的 **Vapnik–Chervonenkis 维**（[VC 维](https://www.edgepedia.org/zh/vc-dimension)）是该类能够以所有可能方式标注的最大点集的规模，这一性质称为粉碎。该概念由苏联数学家弗拉基米尔·N·万普尼克（Vladimir N. Vapnik）和阿列克谢·Ya·切尔沃年基斯（Alexey Ya. Chervonenkis）于20世纪60年代起在发展底层理论时提出，是统计学习理论的核心容量度量：有限的VC维保证在训练数据上测得的误差能够预测新数据上的误差，且这一保证在整个类上一致成立。<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup>

| 关键事实 | 详情 |
|---|---|
| 定义 | 该类所粉碎的集合的最大规模 m，即实现全部 2^m 种标注；若可粉碎任意大规模的集合，则VC维为无穷<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup> |
| 起源 | 1968年发表于《苏联数学报告》的一则短讯；全文于1971年以俄文发表，英译为“关于事件相对频率向其概率的一致收敛”（《概率论及其应用》16(2), 264–280）<sup>[2](https://mlanthology.org/misc/1971/vapnik1971misc-uniform/)</sup> |
| 组合核心 | Sauer引理：一旦 m 超过维数 d，增长函数被 \( \sum_{i=0}^{d} \binom{m}{i} \) 所界，增长从指数型转为多项式型<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup> |
| 样本复杂度 | 对于类维数 d 和样本量 m，期望最坏情况泛化差距的尺度为 \( \widetilde{O}(\sqrt{d/m}) \)<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup> |
| 标准例子 | 实数轴上的阈值：1；实数轴上的区间：2；\( \mathbb{R}^d \) 中的半空间：d + 1；平面上的圆盘：3<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup><sup> • </sup><sup>[3](https://lib.ysu.am/open_books/413311.pdf)</sup> |
| 神经网络 | 对于含 W 个权重、L 层的ReLU网络，VC维为 O(WL log W)，匹配的下界为 \( \Omega(WL\log(W/L)) \)，在非线性单元数 U 上紧界为 \( \Theta(WU) \)<sup>[4](https://jmlr.csail.mit.edu/beta/papers/v20/17-612.html)</sup> |
| 已知局限 | 早期基于VC的样本复杂度界给出的预测大得不切实际，且对某些神经网络，这些界严重高估真实泛化误差<sup>[5](https://pubmed.ncbi.nlm.nih.gov/7584902/)</sup><sup> • </sup><sup>[6](https://journals.aps.org/prl/abstract/10.1103/PhysRevLett.72.2113)</sup> |

## 粉碎与增长函数

固定一个将输入空间映射到 {0, 1} 的假设类 \( \mathcal{H} \)。对于含 m 个点的有限样本 X，类中每个分类器在 X 上诱导一种标注，\( |\mathcal{H}|_X| \) 计算可达到的不同标注数。若该类实现全部 \( 2^m \) 种可能标注，则称它**粉碎** X。增长函数 \( \Gamma_{\mathcal{H}}(m) \) 是该计数在所有规模为 m 的样本上的最大值，因此总介于 1 与 \( 2^m \) 之间。<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup>

于是VC维为

\[ \mathrm{VCdim}(\mathcal{H}) = \max\{ m \ge 0 : \Gamma_{\mathcal{H}}(m) = 2^m \}, \]

当该类粉碎任意大规模的集合时，取值为无穷。定义中有两个特征在实践中很重要。只需粉碎给定规模的一个集合，而非该规模的每一个集合，因此证明下界意味着展示一个有利的构型。而粉碎性向下单调：不能粉碎任何规模为 m 的集合的类，也不能粉碎任何更大的集合。<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup>

## 实例演算

**阈值与区间。** 在实数轴上，阈值函数 \( h_a(x) = \mathbb{1}_{\pm}(x \ge a) \) 能粉碎单个点，但不能粉碎任何一对点，因为没有阈值会将较小的点标为1、较大的点标为−1；VC维为1。闭区间能粉碎任意两个点（都标为内部、都标为外部，或只标其中一个为内部），但不能粉碎任何三个点，因为保留两个外侧点而去掉中间点的标注不是一个区间；VC维为2。<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup><sup> • </sup><sup>[7](https://www.cs.montana.edu/courses/spring2007/536/lectures/tom-7b.html)</sup>

**线性分类器。** \( \mathbb{R}^d \) 中的半空间VC维为 d + 1，同样的值 d + 1 也适用于 r 维空间中的线性决策面，即具有 r 个输入的感知机。<sup>[3](https://lib.ysu.am/open_books/413311.pdf)</sup><sup> • </sup><sup>[8](https://nkapila.me/masters/mitchell)</sup> 平面上的圆盘能粉碎某些三点集，例如等边三角形，但不能粉碎任何四点集，故VC维为3。<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup>

**图。** 这一概念超越了几何数据。对于图 G，若顶点集 D 的每个子集 R 都能对某个顶点 x 实现为 \( R = D \cap N(x) \)，其中 N(x) 是 x 的闭邻域，则称 D 被粉碎；G 的VC维是被粉碎集合的最大基数。当时在英国工作的数学家马丁·安东尼（Martin Anthony）、格雷厄姆·布莱特韦尔（Graham Brightwell）和科林·库珀（Colin Cooper）导出了随机图 G(n, p) 具有VC维 d 的精确阈值函数。<sup>[9](https://www.sciencedirect.com/science/article/pii/0012365X9400187N)</sup>

## Sauer引理与泛化界

定义本身对学习着墨不多；真正的价值来自Sauer引理（由索尔、谢拉赫和佩尔勒斯独立证明），它在 m 超过维数 d 后给出增长函数的界：

\[ \Gamma_{\mathcal{H}}(m) \le \sum_{i=0}^{d} \binom{m}{i} = O(m^d). \]

增长函数在VC维之前呈指数增长，之后呈多项式增长，这一相变使一致收敛成为可能。<sup>[10](https://ocw.mit.edu/courses/15-097-prediction-machine-learning-and-statistics-spring-2012/3f3332b76e8248226fb2285b91cfc6db_MIT15_097S12_lec14.pdf)</sup><sup> • </sup><sup>[11](https://www.cs.huji.ac.il/~shais/UnderstandingMachineLearning/understanding-machine-learning-theory-algorithms.pdf)</sup> 将多项式界代入无分布假设的集中不等式论证，得到期望最坏情况泛化差距的阶为 \( \widetilde{O}(\sqrt{d/m}) \)，其中 d 是VC维，m 是样本量；与拉德马赫界或覆盖数界不同，这一估计不涉及对数据分布的任何假设。<sup>[1](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)</sup>

这一界是统计学习基本定理的基础，该定理指出：一个概念类可被PAC学习当且仅当它是一致Glivenko–Cantelli类，而这又恰好当该类具有有限VC维时发生；然而，这一等价关系仅在该类满足可测性假设时成立。<sup>[12](https://arxiv.org/abs/1104.2097)</sup> 同样的有限性条件驱动样本复杂度结果：一个学习算法若观察到的样本少于大约 \( \max[(1/\varepsilon)\log(1/\delta), (\mathrm{VC}(C)-1)/(32\varepsilon)] \) 个，则无法以置信度 \( 1-\delta \) 保证类中所有目标概念的误差低于 \( \varepsilon \)。<sup>[7](https://www.cs.montana.edu/courses/spring2007/536/lectures/tom-7b.html)</sup>

该理论还延伸至离散几何。当时在[加州大学圣克鲁兹分校](https://www.edgepedia.org/zh/university-of-california-santa-cruz)的[大卫·豪斯勒](https://www.edgepedia.org/zh/david-haussler)（David Haussler）与苏黎世联邦理工学院的埃莫·韦尔茨（Emo Welzl）于1987年证明，任何有界VC维的range空间都容许一个 \( \varepsilon \)-网——一个击中每个足够大集合的小样本——其规模为 \( O((1/\varepsilon)\log(1/\varepsilon)) \)，这一结果在计算几何与学习理论中被广泛使用。<sup>[13](https://arxiv.org/abs/1012.1240)</sup><sup> • </sup><sup>[14](https://jeffe.cs.illinois.edu/pubs/pdf/survey.pdf)</sup>

## 结构风险最小化与支持向量机

万普尼克直接在这些界之上构建了他的学习纲领。[结构风险最小化](https://www.edgepedia.org/zh/structural-risk-minimization)将VC维递增的假设空间 \( \mathcal{H}_i \) 嵌套起来，并选择使经验误差与容量惩罚两项组合界最小的层级，从而在两者之间作出权衡；支持向量机由万普尼克提出，作为这一原则的近似实现。<sup>[15](https://eden.dei.uc.pt/~bribeiro/agregBMR2010/files/SeminarWEB/seminar1_v8se7.html)</sup><sup> • </sup><sup>[16](https://www.sciencedirect.com/topics/mathematics/structural-risk-minimization)</sup>

支持向量机与VC维之间的关系并非朴素的那种。当惩罚参数 C 允许取所有值时，Hilbert空间 \( \mathcal{H} \) 中支持向量机的VC维为 \( \dim(\mathcal{H}) + 1 \)；对于二次多项式核，这是 \( (d^2 + 3d + 2)/2 \)；对于高斯径向基函数核，维数为无穷，因为足够窄的RBF分类器可以分离任意多个带标注的点。<sup>[16](https://www.sciencedirect.com/topics/mathematics/structural-risk-minimization)</sup><sup> • </sup><sup>[17](https://www.cs.princeton.edu/courses/archive/fall08/cos402/readings/burgesSVM.pdf)</sup> 当时在[微软研究院](https://www.edgepedia.org/zh/microsoft-research)的克里斯托弗·J·C·伯吉斯（Christopher J. C. Burges）在其1998年的教程中指出，极高的VC维通常会不利于泛化，然而RBF和多项式SVM在实践中表现良好，当时没有理论能保证这种表现；基于间隔的分析——其中容量取决于权重向量的欧几里得长度而非特征数量——提供了部分解释。<sup>[17](https://www.cs.princeton.edu/courses/archive/fall08/cos402/readings/burgesSVM.pdf)</sup><sup> • </sup><sup>[15](https://eden.dei.uc.pt/~bribeiro/agregBMR2010/files/SeminarWEB/seminar1_v8se7.html)</sup>

## 神经网络的VC维

对于神经网络，VC维随规模增长。对于采用ReLU激活的分段线性网络，在 W 个权重和 L 层的情况下，VC维至多为 O(WL log W)，构造出的例子达到 \( \Omega(WL\log(W/L)) \)；就非线性单元数 U 而言，紧界为 \( \Theta(WU) \)。这些结果可推广到任意分段线性激活函数以及伪维数，并揭示了一种随非线性类型而变的深度依赖关系：分段常数激活无依赖，分段线性为线性依赖，一般分段多项式不超过二次依赖。<sup>[4](https://jmlr.csail.mit.edu/beta/papers/v20/17-612.html)</sup>

由于VC维至少与权重数成正比，基于VC的界随参数数量缩放，因此无法解释严重过参数化的深度网络在经验上的成功，这一点在深度学习理论综述中已被指出。<sup>[18](https://pmc.ncbi.nlm.nih.gov/articles/PMC8300482/)</sup> [维尔茨堡大学](https://www.edgepedia.org/zh/university-of-wurzburg)物理学家曼弗雷德·奥珀（Manfred Opper）于1994年证明，对于奇偶机这一双层网络，在输入维数固定时，VC维随隐藏单元数 K 无界增长，在低于随VC维增长的临界样本量时泛化不可能，然而渐近泛化误差与 K 无关，且VC界严重高估了它；相空间维数与VC维扮演着相互独立的角色。<sup>[6](https://journals.aps.org/prl/abstract/10.1103/PhysRevLett.72.2113)</sup>

## 实际适用性

VC界能否作为设计工具使用已被直接检验。剑桥大学工程系的S. B. 霍尔登和M. 尼兰詹对元音共振峰频率集的分类进行了实验，发现早期基于VC的样本复杂度预测相当不切实际，而后来考虑具体训练算法的理论给出了显著更适用的预测，尽管仍有明显缺陷。<sup>[5](https://pubmed.ncbi.nlm.nih.gov/7584902/)</sup>

尽管如此，该理论仍保持活跃。2023年的一项分析认为，双下降现象——大网络完美拟合训练数据同时泛化良好——可以用包括VC维和结构风险最小化在内的经典VC理论概念来解释，并给出了由经典VC泛化界准确建模的双下降经验曲线。<sup>[19](https://www.sciencedirect.com/science/article/pii/S0893608023005658)</sup> 对原始估计本身的精化工作仍在继续，近期结果从中偏差的角度对通常的VC收敛速率作出了更精细的估计。<sup>[20](https://arxiv.org/abs/2601.16411)</sup>

## References

1. [Chapter 6: Growth functions and VC dimension, Statistical Learning Theory course notes, University of British Columbia](https://www.cs.ubc.ca/~dsuth/532D/26w1/notes/html/chap_vc.html)
2. [Vapnik, V. N., and Chervonenkis, A. Ya. (1971). On the Uniform Convergence of Relative Frequencies of Events to Their Probabilities. ML Anthology reproduction.](https://mlanthology.org/misc/1971/vapnik1971misc-uniform/)
3. [Motwani, R., and Raghavan, P. Probability and Computing, Chapter 14 (VC dimension examples).](https://lib.ysu.am/open_books/413311.pdf)
4. [Bartlett, P., Harvey, N., Liaw, C., and Mehrabian, A. Nearly-tight VC-dimension and Pseudodimension Bounds for Piecewise Linear Neural Networks. JMLR.](https://jmlr.csail.mit.edu/beta/papers/v20/17-612.html)
5. [Holden, S. B., and Niranjan, M. (1995). On the practical applicability of VC dimension bounds. Neural Computation 7(6), 1265–1288.](https://pubmed.ncbi.nlm.nih.gov/7584902/)
6. [Opper, M. (1994). Learning and generalization in a two-layer neural network: The role of the Vapnik-Chervonenkis dimension. Physical Review Letters 72, 2113.](https://journals.aps.org/prl/abstract/10.1103/PhysRevLett.72.2113)
7. [Chapter 7 lecture notes (VC dimension and sample complexity), Montana State University](https://www.cs.montana.edu/courses/spring2007/536/lectures/tom-7b.html)
8. [Mitchell, T. Machine Learning, Chapter 7 notes (VC dimension examples)](https://nkapila.me/masters/mitchell)
9. [Anthony, M., Brightwell, G., and Cooper, C. (1995). The Vapnik-Chervonenkis dimension of a random graph. Discrete Mathematics 138, 43–56.](https://www.sciencedirect.com/science/article/pii/0012365X9400187N)
10. [MIT OpenCourseWare, 15.097 Lecture 14: Statistical learning theory](https://ocw.mit.edu/courses/15-097-prediction-machine-learning-and-statistics-spring-2012/3f3332b76e8248226fb2285b91cfc6db_MIT15_097S12_lec14.pdf)
11. [Shalev-Shwartz, S., and Ben-David, S. Understanding Machine Learning (book PDF)](https://www.cs.huji.ac.il/~shais/UnderstandingMachineLearning/understanding-machine-learning-theory-algorithms.pdf)
12. [PAC learnability versus VC dimension: a footnote to a basic result of statistical learning. arXiv.](https://arxiv.org/abs/1104.2097)
13. [Tight lower bounds for the size of epsilon-nets. arXiv.](https://arxiv.org/abs/1012.1240)
14. [Jeff Erickson, survey on epsilon-nets and range spaces](https://jeffe.cs.illinois.edu/pubs/pdf/survey.pdf)
15. [Support Vector Machines seminar notes (structural risk minimization and VC dimension)](https://eden.dei.uc.pt/~bribeiro/agregBMR2010/files/SeminarWEB/seminar1_v8se7.html)
16. [Structural Risk Minimization, ScienceDirect Topics overview](https://www.sciencedirect.com/topics/mathematics/structural-risk-minimization)
17. [Burges, C. J. C. (1998). A Tutorial on Support Vector Machines for Pattern Recognition. Data Mining and Knowledge Discovery 2, 121–167.](https://www.cs.princeton.edu/courses/archive/fall08/cos402/readings/burgesSVM.pdf)
18. [A selective overview of deep learning. PMC.](https://pmc.ncbi.nlm.nih.gov/articles/PMC8300482/)
19. [To understand double descent, we need to understand VC theory. Neural Networks (ScienceDirect).](https://www.sciencedirect.com/science/article/pii/S0893608023005658)
20. [A Refinement of Vapnik–Chervonenkis' Theorem. arXiv.](https://arxiv.org/abs/2601.16411)

---
*Initially written Sep 17, 2026 · Reviewed: Sep 30, 2026; Oct 15, 2026 · Edited: Sep 30, 2026; Oct 15, 2026 · Last review: Oct 15, 2026*

Topic: 技术与人造世界 › 计算技术与数字系统 › 人工智能与数据 › Machine learning and neural computation › Machine learning methods › Learning theory and generalization › VC dimension and model capacity

Copyright 2026 Edgepedia

License: Edgepedia Community License 1.0, https://www.edgepedia.org/edgepedia/license

Source: https://www.edgepedia.org/zh/vapnik-chervonenkis-dimension

English original: https://www.edgepedia.org/vapnik-chervonenkis-dimension
