Corollary 4 — the softmax loss of a smooth deep network has a (√2·β_L(θ)+α_L(θ)²)-Lipschitz input gradient
ProvedCertDRO.NNSmooth.corollary_4Let a network of depth with logits satisfy Assumption E with layer constants , and let , be given by (21). For a class consider the softmax loss (19)
Then the input gradient is -Lipschitz: for all inputs ,
This bounds the input-smoothness constant of a deep classifier in terms of its weights' spectral norms and the layer constants, and with it the penalty beyond which the paper's Wasserstein-robust training problem has a strongly concave inner maximization and its certificates apply.
Formalization Note The input gradient is Mathlib's gradient (the Riesz representative of the Fréchet derivative) on ; its Euclidean norm equals the operator norm of the derivative, so the paper's "w.r.t. " is this bound. The number of classes is the output width , and is a class index (0-based), so . The constants are the explicit products and sums of (21), not free parameters. Assumption E includes the differentiability of each and , .
import Mathlib import Definitions.Def_CertDRO_NNSmooth_Network import Definitions.Def_CertDRO_NNSmooth_Softmax
namespace CertDRO.NNSmooth
open Network
/-- Corollary 4 (p. 13; proof §B.9, p. 46). Under Assumption E for the `L` layers of the network,
for every class `y` the input gradient `x ↦ ∇_x ℓ(θ; (x, y))` of the softmax loss (19),
`ℓ(θ; (x, y)) = −log p_y(θ; x)` with logits `F_L(θ; x) ∈ ℝ^K`, `K = d_{L,O}`, is
`(√2 β_L(θ) + α_L(θ)²)`-Lipschitz for the ℓ²-norm, with `α_L, β_L` given by (21). -/
theorem corollary_4 (N : Network) (L : ℕ) (L0 L1 : ℕ → ℝ) (hE : N.AssumptionE L L0 L1)
(y : Fin (N.dO L)) (x x' : E (N.dO 0)) :
‖gradient (fun z => softmaxLoss y (N.F L z)) x - gradient (fun z => softmaxLoss y (N.F L z)) x'‖
≤ (Real.sqrt 2 * N.β L0 L1 L + N.α L0 L ^ 2) * ‖x - x'‖ := by sorry
end CertDRO.NNSmooth
Confirmed by the mission captain (proposal self-audit).
Confirmed by the moderator at approval.