medium · Monte Carlo variance reduction
Let and let . We want a Monte Carlo estimate of the tail probability where and denote the standard normal density and CDF and .
The crude estimator draws and averages the indicators . Because is small this is wasteful. Instead use importance sampling: draw from a shifted proposal with density , and reweight.
Write down the importance-sampling estimator of using proposal , and show it is unbiased for every . State its likelihood ratio (weight) explicitly.
Show that the second moment of one reweighted sample equals and deduce the equation satisfied by the variance-minimizing shift .
For , find numerically and report the factor by which the per-sample variance is reduced relative to the crude estimator. Use .
Write the target as an expectation under the proposal by inserting the likelihood ratio :
The weight is the ratio of the two Gaussian densities,
The estimator is and by the change of measure above, for every . Unbiasedness never depends on ; only the variance does.
The per-sample variance is with
The key algebraic step — the one a candidate typically fumbles — is to complete the square in the integrand rather than fight the integral numerically. With ,
The exponent is
Hence and integrating from to gives
Minimizing is easiest through :
So the optimal shift solves where is the Gaussian hazard rate. Since is convex in this sense (the hazard rate is increasing, so the derivative crosses zero once), this stationary point is the global minimum.
Use the Mills-ratio expansion for large . With , the fixed point gives, iterating,
Note the heuristic ''shift the proposal mean up to the threshold'' () is almost right; the exact optimum sits just above because the tail mass beyond concentrates slightly past it.
Now evaluate the variances.
The variance reduction factor is
Answer. 1. with ; unbiased for all . 2. , and solves . 3. For : , giving roughly a 220-fold reduction in per-sample variance (equivalently, about fewer draws for the same accuracy).
The zero-variance ideal proposal is the conditional density , i.e. the normal truncated to the tail — but it requires knowing and is awkward to sample, which is exactly why the tractable single-parameter tilt is used. Also worth knowing: antithetic variates would help almost nothing here, because the payoff is essentially never triggered by both and ; the pairing gives you two zeros nearly always. Rare-event estimation is the textbook case where importance sampling wins and antithetics do not.
hard · PAC-Bayes and information-theoretic generalization bounds
Fix a data space , a hypothesis space , and a loss . Let be i.i.d.\ from a distribution on . A (possibly randomized) learning rule is a Markov kernel producing a hypothesis ; write for the resulting joint law and for its marginals. Define Assume that for every fixed the random variable , , is -sub-Gaussian, i.e. Let denote the mutual information.
(a) Prove that Name the variational identity that drives the proof, and point out the one step that centers the relevant quantity.
(b) Suppose has an absolutely continuous law on () and the rule is deterministic, for measurable , with pushforward law atomless (non-degenerate). Show , so the bound of (a) is vacuous for every deterministic rule with a continuously distributed output. Say in one sentence which inequality from your proof of (a) is responsible.
(c) Take on and the noisy mean estimator , where and is independent of .
(i) Compute exactly.
(ii) Write the resulting bound from (a) and describe its behaviour as ; reconcile with (b).
(iii) With , find the smallest for which the bound is at most , and interpret the required noise scale.
Define , so the target is .
The identity that does the work is the Donsker–Varadhan variational formula for relative entropy: for any two probability measures and any measurable with , Apply it with , , and for . Since ,
The step a candidate misses is that the product measure both centers and factorizes it. Under , condition on ; then is still i.i.d.\ and independent of , and is a centered average of i.i.d.\ -sub-Gaussian terms. Its MGF factorizes: Averaging over preserves the bound, so . (In particular : under the product law the empirical risk is unbiased for the population risk of an independent hypothesis.) Hence Minimizing the right side over at gives . Repeating with (equivalently applying the argument to ) gives the matching lower bound, so
Let be the graph. Because deterministically, . Under the product law, since is atomless, so for every point . Thus assigns full mass to a set of product-measure zero: , and by definition of relative entropy . The bound of (a) then reads : vacuous, even though for, say, a bounded loss the true gap is .
Responsible step: the Donsker–Varadhan inequality itself. It compares against , and this comparison is infinitely loose precisely when the joint law is mutually singular with the product — i.e.\ when the hypothesis is a deterministic function of continuous data. The moral: mutual information is only an upper bound mechanism; a finite gap forces neither finite nor tightness, which is why one randomizes the algorithm (or passes to conditional-mutual-information/CMI frameworks that stay finite by construction).
(i) The estimator depends on only through the sufficient statistic , and , so is a Markov chain and . Hence Now and with is a scalar additive-Gaussian channel with input variance and noise variance :
(ii) Substituting into (a), As the argument of the log diverges and the bound — exactly the deterministic-ERM pathology of (b): plain is a continuous deterministic function of the data, so .
(iii) With require , i.e. , i.e. . The smallest admissible noise is The required injected noise has standard deviation — the same order as the sampling fluctuation of itself (whose s.d.\ is ). To certify even a generalization bound by the information method, you must blur the estimator by an amount comparable to the signal you extracted; here that roughly doubles the estimator's variance. Information-theoretic control literally charges you for the precision with which the output remembers the sample.
Two new problems every morning at 8am · every day so far