Uniform convergence of empirical errors #
A labeled sample is ε-representative for a class C under a distribution D on α × β if the
empirical error of every hypothesis of C on the sample is within ε of its true error
[ShalevShwartzBenDavid2014, Definition 4.1]. For a single hypothesis, Hoeffding's inequality bounds
the probability that m i.i.d. examples misestimate its error by ε by 2 exp (-2 m ε²)
[Hoe63]. A union bound gives uniform convergence for a finite class
[ShalevShwartzBenDavid2014, Section 4.2]. On an ε / 2-representative sample every empirical risk
minimizer is within ε of the best error in the class [ShalevShwartzBenDavid2014, Lemma 4.2]. This
is the agnostic route to PAC learning: no concept of the class needs to fit the distribution.
The domain and label spaces are arbitrary measurable spaces. Each hypothesis needs a measurable
misclassification set; measurableSet_misclassified supplies this for measurable hypotheses with
Bool labels. Hoeffding's inequality is the library's finite-PMF form for [0, 1] scores
(Cslib.Probability.PMF.pi_sum_abs_sub_mean_ge_card_mul), applied to the Bernoulli indicator of a
measurable event; the empirical error of a hypothesis is the relative frequency of its
misclassification set. Uniform convergence for infinite classes of finite VC dimension is in
VCUniformConvergence.lean.
Main definitions #
IsRepresentative D C ε S: the sampleSisε-representative forCunderD.
Main results #
measure_pi_le_abs_card_filter_div_sub_measure: Hoeffding's inequality for the relative frequency of one measurable event.measure_pi_le_abs_empiricalMiscount_div_sub_error: Hoeffding's inequality for the empirical error of one hypothesis.measure_pi_not_isRepresentative_le: uniform convergence for a finite class.IsRepresentative.error_le_optimalError_add: ERM on anε / 2-representative sample isε-optimal.
References #
A labeled sample S is ε-representative for the class C under D if the empirical error
empiricalMiscount h S / m of every h ∈ C is within ε of its true error
[ShalevShwartzBenDavid2014, Definition 4.1].
Hoeffding's inequality for a relative frequency [Hoe63]: under m i.i.d. samples
from μ, the fraction of sample points where a measurable g : Z → Bool is true differs from
μ {g = true} by at least ε with probability at most 2 exp (-2 m ε²).
Hoeffding's inequality for the empirical error of one hypothesis [Hoe63]: under m
i.i.d. examples from D, the empirical error of h differs from error D h by at least ε with
probability at most 2 exp (-2 m ε²). The domain is an arbitrary measurable space; only the
misclassification set of h must be measurable.
Uniform convergence for a finite class [ShalevShwartzBenDavid2014, Section 4.2]: m i.i.d.
examples fail to be ε-representative for a finite class H with probability at most
|H| · 2 exp (-2 m ε²).
Uniform convergence for a finite class, sample-size form: m i.i.d. examples fail to be
ε-representative for a finite class H with probability at most δ once
log (2 |H| / δ) ≤ 2 m ε².
ERM on a representative sample [ShalevShwartzBenDavid2014, Lemma 4.2]: on an
ε / 2-representative sample for C, every empirical risk minimizer for C outputs a hypothesis
whose error is at most optimalError D C + ε. The class need not be finite.
An ε-representative sample is ε'-representative for every ε' ≥ ε.