Exact variance of finite indicator losses #
This module records the elementary but useful variance identity behind the
finite PAC-Bayes--Bernstein route. For an arbitrary Boolean-valued bad-event
predicate on a finite data domain, the associated indicator loss has exact
population variance R * (1 - R), where R is its population risk.
The result is distribution-generic within the finite setting: it assumes only a finite probability mass function. It is not restricted to a literal Bernoulli sample space or a particular classifier representation.
def
FormalSLT.PACBayes.IndicatorVariance.indicatorLoss
{ι : Type u_1}
{Z : Type u_2}
(bad : ι → Z → Bool)
:
ι → Z → ℝ
The real-valued indicator loss associated with a Boolean bad-event predicate.
Equations
Instances For
@[simp]
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorLoss_sq
{ι : Type u_1}
{Z : Type u_2}
(bad : ι → Z → Bool)
(i : ι)
(z : Z)
:
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorLoss_nonneg
{ι : Type u_1}
{Z : Type u_2}
(bad : ι → Z → Bool)
(i : ι)
(z : Z)
:
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorLoss_le_one
{ι : Type u_1}
{Z : Type u_2}
(bad : ι → Z → Bool)
(i : ι)
(z : Z)
:
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk_nonneg
{ι : Type u_1}
{Z : Type u_2}
[Fintype Z]
(p : Z → ℝ)
(hp : PACBayesKL.IsPMF p)
(bad : ι → Z → Bool)
(i : ι)
:
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk_le_one
{ι : Type u_1}
{Z : Type u_2}
[Fintype Z]
(p : Z → ℝ)
(hp : PACBayesKL.IsPMF p)
(bad : ι → Z → Bool)
(i : ι)
:
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk_mem_Icc
{ι : Type u_1}
{Z : Type u_2}
[Fintype Z]
(p : Z → ℝ)
(hp : PACBayesKL.IsPMF p)
(bad : ι → Z → Bool)
(i : ι)
:
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorDeviation_centered
{ι : Type u_1}
{Z : Type u_2}
[Fintype Z]
(p : Z → ℝ)
(hp : PACBayesKL.IsPMF p)
(bad : ι → Z → Bool)
(i : ι)
:
The population-centered indicator loss has mean zero.
theorem
FormalSLT.PACBayes.IndicatorVariance.indicatorDeviation_secondMoment_eq
{ι : Type u_1}
{Z : Type u_2}
[Fintype Z]
(p : Z → ℝ)
(hp : PACBayesKL.IsPMF p)
(bad : ι → Z → Bool)
(i : ι)
:
∑ z : Z, p z * (indicatorPopulationRisk p bad i - indicatorLoss bad i z) ^ 2 = indicatorPopulationRisk p bad i * (1 - indicatorPopulationRisk p bad i)
Exact variance identity for an arbitrary finite Boolean indicator loss.