Simulating statistical queries from examples #
A statistical query learner can be run on random labelled examples: answer each query φ by the
empirical mean of φ on a fresh block of m examples (StatisticalQuery.simulate). By
Hoeffding's inequality an empirical mean is within the tolerance τ of the expectation except
with probability 2 exp (-m τ² / 2), and by a union bound over the at most q queries of the run,
all answers are within tolerance except with probability 2 q exp (-m τ² / 2). The run is then a
run of the learner against an oracle answering within tolerance, so the hypothesis has error at
most ε whenever the learner learns with tolerance τ and error ε
(StatisticalQuery.Learns.toOuterMeasure_lt_disagreement_simulate_le). Whenever
2 q exp (-m τ² / 2) ≤ δ, this is a PAC learner from q m examples for the family of the
distributions of a D-random point labelled by a concept of the class
(StatisticalQuery.Learns.isPACLearnerFor): learnability from statistical queries implies PAC
learnability [Kearns1998, Theorem 1]. The simulation needs a positive tolerance. For τ > 0 and
0 < δ < 1 the condition holds once m ≥ 2 log (2 q / δ) / τ². At τ = 0 it reads 2 q ≤ δ,
which holds only for a learner making no queries.
The learner may choose its queries adaptively; the union bound runs along the tree of its calls
(StatisticalQuery.toOuterMeasure_simulate_notMem_le): each query of the run is answered from a
block of examples independent of the blocks used before, whatever the earlier answers were. This
is the block form of the simulation in Reyzin, Section 2.1, with m examples per
query. The union bound is proved by induction on the query budget, splitting off the first block
with PMF.pi_fin_succ. The library's presampling theorem
(Cslib.OracleComp.IsQueryBounded.run_interpret_presample) transports exact laws from online runs,
and there is no online form of this bound to transport. Kearns's proof of Theorem 1 instead answers
every query from a single sample, with sample bounds for a finite query space and for a query space
of finite VC dimension; the single-sample form and both of its bounds are not formalized here.
Main definitions #
Cslib.MachineLearning.StatisticalQuery.empirical: the empirical mean of a query on a block of labelled examples.Cslib.MachineLearning.StatisticalQuery.simulate: running a learner on blocks of examples.Cslib.MachineLearning.StatisticalQuery.labelled: the distribution of a labelled example.Cslib.MachineLearning.StatisticalQuery.realizable: the distributions of aD-random point labelled by a concept of a class.Cslib.MachineLearning.StatisticalQuery.simulateLearner: the PAC learner fromq mexamples.
Main results #
Cslib.MachineLearning.StatisticalQuery.toOuterMeasure_simulate_notMem_le: the union bound along an adaptive run.Cslib.MachineLearning.StatisticalQuery.toOuterMeasure_empirical_notMem_valid_le: an empirical mean ofmexamples is within tolerance except with probability2 exp (-m τ² / 2).Cslib.MachineLearning.StatisticalQuery.Learns.toOuterMeasure_lt_disagreement_simulate_le: the simulated learner fails with probability at most2 q exp (-m τ² / 2).Cslib.MachineLearning.StatisticalQuery.Learns.isPACLearnerFor: learning from statistical queries gives PAC learning fromq mexamples.
References #
Run the statistical query program A on blocks of labelled examples: its i-th call φ is
answered by the empirical mean of φ on the i-th block. Once the blocks run out, the remaining
calls are answered by 0.
The union bound along an adaptive run. Let the program A make at most n calls, and let
its results be in good whenever each call φ is answered by an element of possible φ. If the
empirical mean of each query on a sample of P is outside possible φ with probability at most
β, then running A on n independent samples of P gives a result outside good with
probability at most n β.
Estimating a statistical query. The empirical mean of the query φ on m independent
examples of the target c under D is outside the tolerance τ ≥ 0 of its expectation with
probability at most 2 exp (-m τ² / 2), by Hoeffding's inequality.
Statistical queries from examples [Kearns1998, Theorem 1] [Reyzin, Section 2.1]
[Rey20]. If A learns C under D from statistical queries of tolerance τ ≥ 0 with error
ε, using at most q queries, then running A on q independent blocks of m examples of a
target c ∈ C, each query answered by the empirical mean on its own block, gives a hypothesis of
error above ε with probability at most 2 q exp (-m τ² / 2).
PAC learning #
The distributions of a D-random point labelled by a concept of C: the family over which
learning under D is PAC learning.
The PAC learner from q m examples that runs A on q blocks of m examples, the block j
consisting of the examples finProdFinEquiv (j, k).
Under a D-random point labelled by c, the error of h is its disagreement with c.
Learning from statistical queries gives PAC learning [Kearns1998, Theorem 1]
Reyzin, Section 2.1. If A learns C under D from statistical queries of
tolerance τ ≥ 0 with error ε, using at most q queries, and 2 q exp (-m τ² / 2) ≤ δ, then
running A on q blocks of m examples is a PAC learner with error ε and confidence 1 - δ
from q m examples, for the distributions of a D-random point labelled by a concept of C.