Tutorials › Statistical Learning (Graduate) › Oracle Regularization for Known Smoothness

Kernel Ridge Rates and Source Conditions · Tutorial 734 of 989

Oracle Regularization for Known Smoothness

Learn to optimize the source-and-spectrum risk bound and quantify the cost of choosing a regularization level away from its oracle value.

Advanced 10 min read

What You'll Learn

  • Express a kernel ridge risk bound using source smoothness and effective-dimension growth.
  • Derive the unique oracle regularization level and its corresponding risk rate.
  • Interpret how the oracle changes with sample size, smoothness, and spectral decay.
  • Calculate the risk penalty for multiplying the oracle level by a fixed factor.
  • Diagnose how a wrongly scaled regularization sequence changes the convergence rate.

Why an Oracle Regularization Level?

Kernel ridge regression balances two effects of regularization. A larger \(\lambda\) generally increases approximation bias, while a smaller \(\lambda\) allows more noisy directions to contribute to variance. When the target’s source smoothness and the spectrum’s effective-dimension growth are known, this tradeoff gives a specific regularization level that minimizes a stated risk bound. This is an oracle choice: it uses properties of the data-generating problem that would not usually be known in practice.

The object optimized here is the bound, not necessarily the exact finite-sample prediction risk. That distinction matters: constants in the bound may be conservative, and the bound may not capture every detail of the risk. Nevertheless, its minimizer identifies the right scale of regularization under the stated assumptions.

The Source-and-Spectrum Bound

Let \(T\) be the covariance operator associated with the kernel features, and let \(f_\lambda\) denote the population target approximant induced by regularization level \(\lambda>0\). Under a source condition, the target lies in a smoothness class controlled by an exponent \(r>0\) and radius \(R\). In the range where the bias result applies, the squared prediction bias is bounded by a constant times \(R^2\lambda^{2r}\). Separately, suppose the effective dimension satisfies \(\mathcal{N}(\lambda)\le Q\lambda^{-\alpha}\), for constants \(Q>0\) and \(\alpha>0\), over the regularization range of interest. The effective-dimension variance bound is then of order \(\sigma^2\mathcal{N}(\lambda)/n\).

Definition: For this tutorial, the source-and-spectrum risk bound is the function
$$ B_n(\lambda)=A\lambda^{2r}+\frac{D}{n}\lambda^{-\alpha},\qquad \lambda>0, $$
where \(A>0\) collects the bias constants and source radius, \(D>0\) collects the variance constants, and \(r,\alpha>0\). The first term is the bias contribution; the second is the variance contribution. The constants are treated as fixed while optimizing over \(\lambda\).

For example, if the bias result gives \(C_b R^2\lambda^{2r}\), and the variance result gives \(C_v\sigma^2 Q\lambda^{-\alpha}/n\), then \(A=C_bR^2\) and \(D=C_v\sigma^2Q\). In a high-probability result, the constants may also depend on the specified confidence level; the optimization below applies once those constants are fixed. If a source condition has greater smoothness than the bias bound can use, \(r\) here must be the exponent in the applicable bias bound, not an unsupported larger exponent.

We optimize over positive \(\lambda\) for which the bound is valid. If the method imposes an interval of admissible regularization levels, the unconstrained minimizer is used when it lies in the interval; otherwise the minimum over that interval occurs at the nearer endpoint in log scale.

Worked Example: Writing the Bound From Its Components

Suppose a source condition gives a squared-bias bound \(4R^2\lambda\), and an effective-dimension variance bound gives \(18\sigma^2/(n\sqrt{\lambda})\). Take \(R=1\) and \(\sigma=1\). Identify the exponents and write the risk bound.

Matching \(4\lambda\) to \(A\lambda^{2r}\) gives \(A=4\) and \(2r=1\), so \(r=1/2\). Matching \(18\lambda^{-1/2}/n\) to \(D\lambda^{-\alpha}/n\) gives \(D=18\) and \(\alpha=1/2\). Thus

$$ B_n(\lambda)=4\lambda+\frac{18}{n}\lambda^{-1/2}. $$

The bias rises linearly with \(\lambda\), while the variance falls as \(\lambda^{-1/2}\). Both constants are positive, so neither term can be discarded when choosing \(\lambda\).

Deriving the Oracle Level

The oracle level follows by minimizing \(B_n(\lambda)\). The derivative is

$$ B_n'(\lambda)=2rA\lambda^{2r-1}-\frac{\alpha D}{n}\lambda^{-\alpha-1}. $$

The first term is positive and the second negative. Setting the derivative to zero equates the marginal increase in bias to the marginal decrease in variance.

Theorem: For \(A,D,n,r,\alpha>0\), the function \(B_n(\lambda)=A\lambda^{2r}+(D/n)\lambda^{-\alpha}\) has a unique global minimizer over \(\lambda>0\), given by
$$ \lambda_{\mathrm{or}} = \left(\frac{\alpha D}{2rA\,n}\right)^{\!1/(2r+\alpha)}. $$
At this level, the minimized bound is
$$ B_n(\lambda_{\mathrm{or}}) = \left(1+\frac{2r}{\alpha}\right) A\left(\frac{\alpha D}{2rA\,n}\right)^{\!2r/(2r+\alpha)}. $$

Proof. Differentiating and multiplying the stationary-point equation by the positive quantity \(\lambda^{\alpha+1}\) shows that \(B_n'(\lambda)=0\) exactly when

$$ 2rA\lambda^{2r+\alpha}=\frac{\alpha D}{n}. $$

The left side is strictly increasing from zero to infinity as \(\lambda\) increases from zero to infinity. There is therefore exactly one positive solution, namely \(\lambda_{\mathrm{or}}\). Also, \(B_n'(\lambda)<0\) below that solution and \(B_n'(\lambda)>0\) above it, so it is the unique global minimum. At the stationary point,

$$ 2rA\lambda_{\mathrm{or}}^{2r} = \frac{\alpha D}{n}\lambda_{\mathrm{or}}^{-\alpha}, \qquad \frac{D}{n}\lambda_{\mathrm{or}}^{-\alpha} = \frac{2r}{\alpha}A\lambda_{\mathrm{or}}^{2r}. $$

Substituting this relationship into the bound gives \(B_n(\lambda_{\mathrm{or}})=(1+2r/\alpha)A\lambda_{\mathrm{or}}^{2r}\). Inserting the expression for \(\lambda_{\mathrm{or}}\) proves the displayed minimum. \(\square\)

The oracle level decreases with sample size at rate \(n^{-1/(2r+\alpha)}\). Substitution into the bound gives rate \(n^{-2r/(2r+\alpha)}\), with constants depending on \(A,D,r,\alpha\). Greater usable smoothness \(r\) permits a smaller bias at a given \(\lambda\); stronger effective-dimension growth \(\alpha\) makes the variance penalty increase more rapidly as \(\lambda\) shrinks.

Worked Example: Calculating the Oracle and Its Rate

Return to \(B_n(\lambda)=4\lambda+18\lambda^{-1/2}/n\). Here \(A=4\), \(D=18\), \(2r=1\), and \(\alpha=1/2\). The oracle formula gives

$$ \lambda_{\mathrm{or}} = \left(\frac{(1/2)18}{1\cdot 4n}\right)^{1/(1+1/2)} = \left(\frac{9}{8n}\right)^{2/3}. $$

The rate exponent is \(2r/(2r+\alpha)=1/(3/2)=2/3\). The minimized bound can also be checked term by term. At the oracle, the stationary-point relation says variance equals twice the bias, since \(\alpha/(2r)=1/2\). Therefore

$$ B_n(\lambda_{\mathrm{or}}) = 3\cdot4\left(\frac{9}{8n}\right)^{2/3} = 12\left(\frac{9}{8}\right)^{2/3}n^{-2/3}. $$

The rate is \(n^{-2/3}\), and the explicit constant above follows from the given bound; it is not a claim that the exact prediction risk has that same constant.

How Much Does a Tuning Error Cost?

A useful sensitivity calculation compares a chosen level \(\lambda=c\lambda_{\mathrm{or}}\) with the oracle, where \(c>0\) is a multiplicative error. At the oracle, the variance term is \(2r/\alpha\) times the bias term. Scaling \(\lambda\) by \(c\) multiplies the bias by \(c^{2r}\), and the variance by \(c^{-\alpha}\). Consequently the ratio of bounds is exactly

$$ \frac{B_n(c\lambda_{\mathrm{or}})}{B_n(\lambda_{\mathrm{or}})} = \frac{\alpha c^{2r}+2r c^{-\alpha}}{2r+\alpha}. $$

This ratio equals one at \(c=1\), decreases before the oracle and increases after it. A simple bound, useful when only the size of the error is known, is

$$ \frac{B_n(c\lambda_{\mathrm{or}})}{B_n(\lambda_{\mathrm{or}})} \leq \max\{c^{2r},c^{-\alpha}\}. $$

Indeed, the ratio is a weighted average of \(c^{2r}\) and \(c^{-\alpha}\), with positive weights that sum to one. The exact expression is sharper and also shows the asymmetry: under-regularization can be more costly when \(\alpha\) is large, while over-regularization can be more costly when \(2r\) is large.

Worked Example: Doubling or Halving the Oracle Level

Let \(r=1/2\) and \(\alpha=1/2\). The bound ratio for a factor \(c\) is

$$ \frac{B_n(c\lambda_{\mathrm{or}})}{B_n(\lambda_{\mathrm{or}})} = \frac{(1/2)c+(1)c^{-1/2}}{3/2} = \frac{1}{3}c+\frac{2}{3}c^{-1/2}. $$

If the chosen level is twice the oracle, \(c=2\), the ratio is

$$ \frac{2}{3}+\frac{2}{3\sqrt{2}} \approx 1.138. $$

The bound is about 13.8% larger. If the chosen level is half the oracle, \(c=1/2\), the ratio is

$$ \frac{1}{6}+\frac{2\sqrt{2}}{3} \approx 1.109. $$

Here halving the level increases the bound by about 10.9%. The calculation is specific to these exponents; a factor-of-two error does not have a universal cost independent of smoothness and spectral decay.

Sensitivity is also important when the regularization sequence has the wrong power of \(n\). If \(\lambda_n=n^{-a}\) for a fixed \(a>0\), then the two terms have orders \(n^{-2ra}\) and \(n^{-1+\alpha a}\). When both terms decay, their sum has order \(n^{-q(a)}\), where

$$ q(a)=\min\{2ra,\ 1-\alpha a\}. $$

The first exponent increases with \(a\), while the second decreases. Their minimum is largest when they are equal, at \(a=1/(2r+\alpha)\), exactly the oracle scaling. This gives a rate-level way to assess tuning error: a fixed multiplicative error in the oracle level changes constants, whereas using the wrong power of \(n\) can worsen the convergence rate.

Worked Example: A Mis-scaled Regularization Sequence

Take \(r=1/2\) and \(\alpha=1/2\), and choose \(\lambda_n=n^{-1/2}\) rather than the oracle order \(n^{-2/3}\). The bias term has order

$$ \lambda_n^{2r}=(n^{-1/2})^1=n^{-1/2}, $$

and the variance term has order

$$ n^{-1}\lambda_n^{-\alpha} = n^{-1}(n^{-1/2})^{-1/2} = n^{-1}n^{1/4} = n^{-3/4}. $$

The bias decays more slowly, so the bound has order \(n^{-1/2}\). At the oracle exponent \(a=2/3\), both terms have order \(n^{-2/3}\). The mis-scaled sequence therefore loses rate, even though both choices tend to zero.

Common Pitfall and Practical Meaning

  • Confusing a bound minimizer with an exact-risk minimizer. The derivative calculation establishes the minimum of \(B_n(\lambda)\), not of the unknown finite-sample risk. The oracle is defined relative to the bound.
  • Balancing the two terms as if they must be equal. The correct stationary condition is \(2r\) times the bias term equals \(\alpha\) times the variance term. They are equal only when \(2r=\alpha\).
  • Ignoring the exponent convention. If the bias term is \(\lambda^{2r}\), its exponent in the tuning formula is \(2r\), not \(r\). Substituting \(r\) in its place changes both the oracle scale and the risk rate.
  • Using smoothness that the bias result does not support. The optimization cannot create a stronger bias bound than the source-condition result provides. Use the applicable bias exponent and constants.

When \(A,D,r,\alpha\) are known, the formula gives a transparent benchmark for the scale and rate of regularization. When they are not known, the oracle calculation remains useful for understanding what an ideal choice would achieve, but selecting a data-dependent level is a separate problem. In particular, this calculation alone does not provide a method for adapting to unknown smoothness.

Key takeaway: For a bound with bias \(A\lambda^{2r}\) and variance \(D\lambda^{-\alpha}/n\), the oracle level is proportional to \(n^{-1/(2r+\alpha)}\), and the minimized bound is proportional to \(n^{-2r/(2r+\alpha)}\). Multiplicative errors have an explicit, exponent-dependent cost; errors in the power of \(n\) can change the rate itself.

Check Your Understanding

Work from the bound and assumptions stated in each question.

  1. For \(B_n(\lambda)=A\lambda^{2r}+D\lambda^{-\alpha}/n\), derive the stationary-point equation and explain why it has exactly one positive solution.
  2. At the oracle, what is the ratio of the variance term to the bias term? Under what condition are the two terms equal?
  3. If \(\lambda=c\lambda_{\mathrm{or}}\), write the exact ratio \(B_n(\lambda)/B_n(\lambda_{\mathrm{or}})\) and identify which part reflects over-regularization.
  4. For \(\lambda_n=n^{-a}\), which two exponents determine the rate of the bound, and what value of \(a\) balances them?
  5. Why does minimizing the source-and-spectrum bound not, by itself, prove that the resulting level minimizes the exact prediction risk?
Clinical Biostats