LeanMachineLearning exposition

Bandits.avg_mean_reward_tendsto_of_sublinear_regret🔗

This page has the declaration's own card below, then its dependency graph, then a card for each dependency (type dependencies first, then the rest of the transitive closure). For a theorem, the graph and the dependency cards only follow its statement's dependencies (its proof is replaced by sorry, so what it proves doesn't depend on how); for everything else, both the type and the body/value are followed, since their content is part of what later declarations build on.

Minimal Lean file

avg_mean_reward_tendsto_of_sublinear_regret🔗

LemmaBandits.avg_mean_reward_tendsto_of_sublinear_regret

If the regret is sublinear, the average mean reward tends to the highest mean of the arms.

🔗theorem
Bandits.avg_mean_reward_tendsto_of_sublinear_regret.{u_1, u_2} {𝓐 : Type u_1} {Ω : Type u_2} {m𝓐 : MeasurableSpace 𝓐} {ν : ProbabilityTheory.Kernel 𝓐 } {A : Ω 𝓐} {ω : Ω} (hr : (fun x => regret ν A x ω) =o[Filter.atTop] fun t => t) : Filter.Tendsto (fun t => (∑ s Finset.range t, (x : ), id x ν (A s ω)) / t) Filter.atTop (nhds (⨆ a, (x : ), id x ν a))
Bandits.avg_mean_reward_tendsto_of_sublinear_regret.{u_1, u_2} {𝓐 : Type u_1} {Ω : Type u_2} {m𝓐 : MeasurableSpace 𝓐} {ν : ProbabilityTheory.Kernel 𝓐 } {A : Ω 𝓐} {ω : Ω} (hr : (fun x => regret ν A x ω) =o[Filter.atTop] fun t => t) : Filter.Tendsto (fun t => (∑ s Finset.range t, (x : ), id x ν (A s ω)) / t) Filter.atTop (nhds (⨆ a, (x : ), id x ν a))

Code

lemma avg_mean_reward_tendsto_of_sublinear_regret
    (hr : (regret ν A · ω) =o[atTop] fun t ↦ (t : ℝ)) :
    Tendsto (fun t ↦ (∑ s ∈ range t, (ν (A s ω))[id]) / (t : ℝ))
      atTop (nhds (⨆ a, (ν a)[id]))
Type uses (1)

Actions: Source · Open Issue

Proof
by
  have ht : Tendsto (fun t ↦ (⨆ a, (ν a)[id]) - regret ν A t ω / t)
      atTop (nhds (⨆ a, (ν a)[id])) := by
    simpa using tendsto_const_nhds.sub hr.tendsto_div_nhds_zero
  apply ht.congr'
  filter_upwards [eventually_ne_atTop 0] with t ht
  rw [regret]
  field_simp
  ring

Dependency graph

Type dependencies (1)

regret🔗

DefinitionBandits.regret

Regret of a sequence of pulls k : ℕ → 𝓐 at time t for the reward kernel ν ; Kernel 𝓐 ℝ.

🔗def
Bandits.regret.{u_1, u_2} {𝓐 : Type u_1} {Ω : Type u_2} {m𝓐 : MeasurableSpace 𝓐} (ν : ProbabilityTheory.Kernel 𝓐 ) (A : Ω 𝓐) (t : ) (ω : Ω) :
Bandits.regret.{u_1, u_2} {𝓐 : Type u_1} {Ω : Type u_2} {m𝓐 : MeasurableSpace 𝓐} (ν : ProbabilityTheory.Kernel 𝓐 ) (A : Ω 𝓐) (t : ) (ω : Ω) :

Code

noncomputable
def regret (ν : Kernel 𝓐 ℝ) (A : ℕ → Ω → 𝓐) (t : ℕ) (ω : Ω) : ℝ :=
  t * (⨆ a, (ν a)[id]) - ∑ s ∈ range t, (ν (A s ω))[id]
Used by (11)

Actions: Source · Open Issue