Let S⊆Rd be nonempty, compact and convex, let w∗ be any optimization oracle for S, let C be a nonempty bounded set of cost vectors, and let H be a family of functions f:X→Rd. Fix a sample (x1,c1),…,(xn,cn) with n≥1 and every ci∈C, and let
F∣X={(w∗(f(x1)),…,w∗(f(xn))):f∈H}.
If F∣X is finite, then
R^SPOn(H)≤ωS(C)n2log∣F∣X∣.
The empirical complexity depends on f only through the decision vector in F∣X, and each SPO loss lies in [0,ωS(C)]; this is the step of the proof of Theorem 2 that the paper attributes to Massart's lemma and the definition of ωS(C).
Formalization Note The finiteness hypothesis makes explicit what the printed inequality leaves implicit (for infinite F∣X its right-hand side is +∞); without it Lean's ncard would be 0. For empty H both sides are 0. The logarithm is natural.
namespace SPOBounds.Natarajan
/-- **Proof of Theorem 2, Massart step** (arXiv:1905.11488v3, Appendix B.1, p. 31, the
displayed chain, fourth line). For a fixed sample `s` whose cost vectors lie in the nonempty
bounded set `C`, if the set `𝔉_{|𝕏}` of decision vectors `(w(f(x₁)), …, w(f(xₙ)))`, `f ∈ H`,
is finite, then `R̂ⁿ_SPO(H) ≤ ω_S(C) √(2 log |𝔉_{|𝕏}| / n)`. -/
theorem empirical_rademacher_massart {d : ℕ} {X : Type*}
(S : Set (EuclideanSpace ℝ (Fin d))) (hS : S.Nonempty) (hSc : IsCompact S)
(hSv : Convex ℝ S)
(w : EuclideanSpace ℝ (Fin d) → EuclideanSpace ℝ (Fin d)) (hw : IsOracle S w)
(C : Set (EuclideanSpace ℝ (Fin d))) (hC : C.Nonempty) (hCb : Bornology.IsBounded C)
(H : Set (X → EuclideanSpace ℝ (Fin d)))
(n : ℕ) (hn : 0 < n) (s : Fin n → X × EuclideanSpace ℝ (Fin d)) (hsC : ∀ i, (s i).2 ∈ C)
(hfin : (sampleDecisions w H s).Finite) :
empRademacherSPO w H s ≤
linGapSet S C * Real.sqrt (2 * Real.log ((sampleDecisions w H s).ncard : ℝ) / n) := by sorry
end SPOBounds.Natarajan
Source
El Balghiti, Elmachtoub, Grigas, Tewari, Generalization Bounds in the Predict-then-Optimize Framework, arXiv:1905.11488v3, p. 31, Appendix B.1 (proof of Theorem 2), the displayed chain, fourth line
Read-back
What the Lean code literally says, in plain math · claude-opus-5-5
Data and hypotheses.
d∈N and X is an arbitrary type.
S⊆Rd is nonempty, compact and convex.
w:Rd→Rd is an oracle for S: for every c, w(c)∈S minimizes v↦⟨c,v⟩ over S, with ties broken arbitrarily.
C⊆Rd is nonempty and bounded.
H is an arbitrary set of functions X→Rd.
n≥1, and s=((x1,c1),…,(xn,cn)) is a fixed sample in (X×Rd)n with every ci∈C.
Here ℓSPOw(c^,c)=⟨c,w(c^)⟩−⟨c,w(c)⟩. Each supremum is real-valued: 0 if H is empty or the values are unbounded above.
ωS(C)=supc∈C(supv∈S⟨c,v⟩−infv∈S⟨c,v⟩).
∣F∣s∣ is the number of elements of the finite set F∣s.
Degenerate cases.
H=∅:F∣s=∅ and ∣F∣s∣=0. Since log0 is taken to be 0, the right-hand side is 0. The left-hand side is also 0, because every supremum over the empty set is 0.
∣F∣s∣=1:log1=0, so the bound says R^SPOn(H;s)≤0.
Confirmed by the moderator at approval.