Documentation

FormalSLT.PACBayes.IndicatorVariance

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 : ιZBool) :
ιZ

The real-valued indicator loss associated with a Boolean bad-event predicate.

Equations
Instances For
    def FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk {ι : Type u_1} {Z : Type u_2} [Fintype Z] (p : Z) (bad : ιZBool) (i : ι) :

    Population risk of a Boolean indicator loss under a finite mass function.

    Equations
    Instances For
      @[simp]
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorLoss_sq {ι : Type u_1} {Z : Type u_2} (bad : ιZBool) (i : ι) (z : Z) :
      indicatorLoss bad i z ^ 2 = indicatorLoss bad i z
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorLoss_nonneg {ι : Type u_1} {Z : Type u_2} (bad : ιZBool) (i : ι) (z : Z) :
      0 indicatorLoss bad i z
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorLoss_le_one {ι : Type u_1} {Z : Type u_2} (bad : ιZBool) (i : ι) (z : Z) :
      indicatorLoss bad i z 1
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk_nonneg {ι : Type u_1} {Z : Type u_2} [Fintype Z] (p : Z) (hp : PACBayesKL.IsPMF p) (bad : ιZBool) (i : ι) :
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk_le_one {ι : Type u_1} {Z : Type u_2} [Fintype Z] (p : Z) (hp : PACBayesKL.IsPMF p) (bad : ιZBool) (i : ι) :
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorPopulationRisk_mem_Icc {ι : Type u_1} {Z : Type u_2} [Fintype Z] (p : Z) (hp : PACBayesKL.IsPMF p) (bad : ιZBool) (i : ι) :
      theorem FormalSLT.PACBayes.IndicatorVariance.indicatorDeviation_centered {ι : Type u_1} {Z : Type u_2} [Fintype Z] (p : Z) (hp : PACBayesKL.IsPMF p) (bad : ιZBool) (i : ι) :
      z : Z, p z * (indicatorPopulationRisk p bad i - indicatorLoss bad i z) = 0

      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 : ιZBool) (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.