Documentation

LeanMlir.Proofs.Nets.Small.Cifar8BbnParamGrad

The batch-statistics cifar8-BN net — every gradient node IS the loss's derivative #

Cifar8BbnStepTieB.cifar8Bbn_train_step_tiedB ties the 38 gradient nodes of the cifar8wb_bbn_* steps, each at the cotangent the rendered chain threads to it; Cifar8BbnWholeBackB says that chain is the certified whole-net backward. This file is the rung above both: at those cotangents, the loss of the WHOLE net with one parameter varied is differentiable in it and the node is its gradient (HasGradAt), for any loss L of the logits with gradient g there (cifar8Bbn_net_lossGrad). The batched peer of Cifar8BnParamGrad.cifar8Bn_net_lossGrad (the per-image net) and of ResNet34ParamGrad.r34_net_lossGrad.

The pools #

A 2×2 max pool has no derivative at a window whose maximum is attained twice, and after a ReLU every dead window is such a tie. So, as the per-image rung and ResNet-34's stem do, the pools are frozen at a selection σ (one cell per window per example): the pool is then the gather at σ, and PoolSelB.maxPoolB_relu_eventuallyEq_sel says the pooled ReLU IS that gather along any parameter, near a point where every window is dead or tied only between twins — cells equal at every value of the weights upstream of that pool (C8PoolTwin1 … C8PoolTwin4). The gradient is then of the gather model, which is smooth, and the chain's pool cotangent is the scatter along σ (selScatter). At σ = argmax that scatter is the render's maxPoolBackB (PoolSelB.batchMapAux_maxPoolBackFlat_eq_selScatter), which is how cifar8Bbn_net_lossGrad's chain is the node tie's.

How it is built #

Scope #

One device; the conv weight nodes on the renderers' bf16 switch (convWAt_hasGradAt), the others carry no flag. The smoothed-CE instantiation at the artifacts' own cotangent is cifar8Bbn_net_lossGrad_CE.

noncomputable def Proofs.c8Z1 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))

Stage 1's pre-activation: BN₁ of conv₁.

Equations
Instances For
    noncomputable def Proofs.c8Z2 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
    Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))

    Stage 2's pre-activation, pool 1's input before its ReLU.

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For
      noncomputable def Proofs.c8Z3 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
      Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))

      Stage 3's pre-activation.

      Equations
      Instances For
        noncomputable def Proofs.c8Z4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
        Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))

        Stage 4's pre-activation, pool 2's input before its ReLU.

        Equations
        Instances For
          noncomputable def Proofs.c8Z5 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
          Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))

          Stage 5's pre-activation.

          Equations
          Instances For
            noncomputable def Proofs.c8Z6 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
            Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))

            Stage 6's pre-activation, pool 3's input before its ReLU.

            Equations
            Instances For
              noncomputable def Proofs.c8Z7 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
              Vec (N * (c4 * (2 * h) * (2 * w)))

              Stage 7's pre-activation.

              Equations
              Instances For
                noncomputable def Proofs.c8Z8 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                Vec (N * (c4 * (2 * h) * (2 * w)))

                Stage 8's pre-activation, pool 4's input before its ReLU.

                Equations
                Instances For
                  @[reducible, inline]
                  abbrev Proofs.bIdx (N : ℕ) {c H W : ℕ} (r : Fin N) (ci : Fin c) (q : Fin H × Fin W) :
                  Fin (N * (c * H * W))

                  Example r's cell (ci, p) in the batched [N, c, H, W] index.

                  Equations
                  Instances For
                    def Proofs.C8PoolTwin1 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (_p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (r : Fin N) (q q' : Fin (2 * (2 * (2 * (2 * h)))) × Fin (2 * (2 * (2 * (2 * w))))) :

                    Twins of pool 1 (example r): equal in every channel at every record of weights. Pool 1's pre-activation reads only stages 1 and 2, so this is "equal at every weight upstream"; p fixes the widths.

                    Equations
                    • One or more equations did not get rendered due to their size.
                    Instances For
                      def Proofs.C8PoolTwin2 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (_p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (r : Fin N) (q q' : Fin (2 * (2 * (2 * h))) × Fin (2 * (2 * (2 * w)))) :

                      Twins of pool 2 (example r).

                      Equations
                      • One or more equations did not get rendered due to their size.
                      Instances For
                        def Proofs.C8PoolTwin3 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (_p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (r : Fin N) (q q' : Fin (2 * (2 * h)) × Fin (2 * (2 * w))) :

                        Twins of pool 3 (example r).

                        Equations
                        • One or more equations did not get rendered due to their size.
                        Instances For
                          def Proofs.C8PoolTwin4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (_p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (r : Fin N) (q q' : Fin (2 * h) × Fin (2 * w)) :

                          Twins of pool 4 (example r).

                          Equations
                          • One or more equations did not get rendered due to their size.
                          Instances For
                            structure Proofs.Cifar8BbnLossSmoothAt {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) :

                            What the loss gradient needs at x: every pre-ReLU activation off zero (the eight stages and the two head layers); every pool's windows, in every example, dead or tied only between that pool's twins; each selection naming a maximum of every window of its pool's input.

                            Instances For
                              noncomputable def Proofs.c8Gp4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (L : Vec (N * nC) → Vec 1) (u : Vec (N * (c4 * h * w))) :
                              Vec 1

                              The head: dense₉, relu, denseₐ, relu, dense_b, then L.

                              Equations
                              • One or more equations did not get rendered due to their size.
                              Instances For
                                noncomputable def Proofs.c8S8 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c4 * (2 * h) * (2 * w)))) :
                                Vec 1

                                Real: from stage 8's pre-activation.

                                Equations
                                Instances For
                                  noncomputable def Proofs.c8S7 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c4 * (2 * h) * (2 * w)))) :
                                  Vec 1

                                  Real: from stage 7's pre-activation.

                                  Equations
                                  • One or more equations did not get rendered due to their size.
                                  Instances For
                                    noncomputable def Proofs.c8S6 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) :
                                    Vec 1

                                    Real: from stage 6's pre-activation.

                                    Equations
                                    • One or more equations did not get rendered due to their size.
                                    Instances For
                                      noncomputable def Proofs.c8S5 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) :
                                      Vec 1

                                      Real: from stage 5's pre-activation.

                                      Equations
                                      • One or more equations did not get rendered due to their size.
                                      Instances For
                                        noncomputable def Proofs.c8S4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) :
                                        Vec 1

                                        Real: from stage 4's pre-activation.

                                        Equations
                                        • One or more equations did not get rendered due to their size.
                                        Instances For
                                          noncomputable def Proofs.c8S3 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) :
                                          Vec 1

                                          Real: from stage 3's pre-activation.

                                          Equations
                                          • One or more equations did not get rendered due to their size.
                                          Instances For
                                            noncomputable def Proofs.c8S2 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                                            Vec 1

                                            Real: from stage 2's pre-activation.

                                            Equations
                                            • One or more equations did not get rendered due to their size.
                                            Instances For
                                              noncomputable def Proofs.c8S1 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (y : Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                                              Vec 1

                                              Real: from stage 1's pre-activation.

                                              Equations
                                              • One or more equations did not get rendered due to their size.
                                              Instances For
                                                noncomputable def Proofs.c8G8 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (L : Vec (N * nC) → Vec 1) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c4 * (2 * h) * (2 * w)))) :
                                                Vec 1

                                                Gather model: from stage 8's pre-activation, pool 4 frozen at σ₄.

                                                Equations
                                                Instances For
                                                  noncomputable def Proofs.c8G7 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c4 * (2 * h) * (2 * w)))) :
                                                  Vec 1

                                                  Gather model: from stage 7's pre-activation.

                                                  Equations
                                                  • One or more equations did not get rendered due to their size.
                                                  Instances For
                                                    noncomputable def Proofs.c8G6 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) :
                                                    Vec 1

                                                    Gather model: from stage 6's pre-activation, pool 3 frozen at σ₃.

                                                    Equations
                                                    • One or more equations did not get rendered due to their size.
                                                    Instances For
                                                      noncomputable def Proofs.c8G5 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) :
                                                      Vec 1

                                                      Gather model: from stage 5's pre-activation.

                                                      Equations
                                                      • One or more equations did not get rendered due to their size.
                                                      Instances For
                                                        noncomputable def Proofs.c8G4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) :
                                                        Vec 1

                                                        Gather model: from stage 4's pre-activation, pool 2 frozen at σ₂.

                                                        Equations
                                                        • One or more equations did not get rendered due to their size.
                                                        Instances For
                                                          noncomputable def Proofs.c8G3 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) :
                                                          Vec 1

                                                          Gather model: from stage 3's pre-activation.

                                                          Equations
                                                          • One or more equations did not get rendered due to their size.
                                                          Instances For
                                                            noncomputable def Proofs.c8G2 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                                                            Vec 1

                                                            Gather model: from stage 2's pre-activation, pool 1 frozen at σ₁.

                                                            Equations
                                                            • One or more equations did not get rendered due to their size.
                                                            Instances For
                                                              noncomputable def Proofs.c8G1 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (y : Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                                                              Vec 1

                                                              Gather model: from stage 1's pre-activation.

                                                              Equations
                                                              • One or more equations did not get rendered due to their size.
                                                              Instances For
                                                                noncomputable def Proofs.c8Up8of7 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c4 * (2 * h) * (2 * w)))) :
                                                                Vec (N * (c4 * (2 * h) * (2 * w)))

                                                                Stage 7's pre-activation to stage 8's: ReLU, conv₈, BN₈.

                                                                Equations
                                                                Instances For
                                                                  noncomputable def Proofs.c8Up7of6 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) :
                                                                  Vec (N * (c4 * (2 * h) * (2 * w)))

                                                                  Stage 6's to stage 7's: ReLU, pool 3, conv₇, BN₇.

                                                                  Equations
                                                                  • One or more equations did not get rendered due to their size.
                                                                  Instances For
                                                                    noncomputable def Proofs.c8Up6of5 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) :
                                                                    Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))

                                                                    Stage 5's to stage 6's.

                                                                    Equations
                                                                    • One or more equations did not get rendered due to their size.
                                                                    Instances For
                                                                      noncomputable def Proofs.c8Up5of4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) :
                                                                      Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))

                                                                      Stage 4's to stage 5's: ReLU, pool 2, conv₅, BN₅.

                                                                      Equations
                                                                      • One or more equations did not get rendered due to their size.
                                                                      Instances For
                                                                        noncomputable def Proofs.c8Up4of3 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) :
                                                                        Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))

                                                                        Stage 3's to stage 4's.

                                                                        Equations
                                                                        • One or more equations did not get rendered due to their size.
                                                                        Instances For
                                                                          noncomputable def Proofs.c8Up3of2 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                                                                          Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))

                                                                          Stage 2's to stage 3's: ReLU, pool 1, conv₃, BN₃.

                                                                          Equations
                                                                          • One or more equations did not get rendered due to their size.
                                                                          Instances For
                                                                            noncomputable def Proofs.c8Up2of1 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (y : Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) :
                                                                            Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))

                                                                            Stage 1's to stage 2's.

                                                                            Equations
                                                                            • One or more equations did not get rendered due to their size.
                                                                            Instances For
                                                                              theorem Proofs.c8Up8of7_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              theorem Proofs.c8Up7of6_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              theorem Proofs.c8Up6of5_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              theorem Proofs.c8Up5of4_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              theorem Proofs.c8Up4of3_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              theorem Proofs.c8Up3of2_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              theorem Proofs.c8Up2of1_continuous {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) :
                                                                              @[reducible, inline]
                                                                              abbrev Proofs.TwinAlong (N : ℕ) {P c H W : ℕ} (T : Fin N → Fin H × Fin W → Fin H × Fin W → Prop) (Z : Vec P → Vec (N * (c * H * W))) :

                                                                              Twins of pool j, along a pre-activation path: equal at every θ.

                                                                              Equations
                                                                              Instances For
                                                                                theorem Proofs.c8_germ_stage8 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c4 * (2 * h) * (2 * w)))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z8 N p ε x) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) Z) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S8 N p L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G8 N p L σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage7 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c4 * (2 * h) * (2 * w)))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z7 N p ε x) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (Z θ)) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S7 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G7 N p ε L σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage6 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z6 N p ε x) (hT3 : TwinAlong N (C8PoolTwin3 N p ε x) Z) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (c8Up7of6 N p ε (Z θ))) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S6 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G6 N p ε L σ₃ σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage5 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c3 * (2 * (2 * h)) * (2 * (2 * w))))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z5 N p ε x) (hT3 : TwinAlong N (C8PoolTwin3 N p ε x) fun (θ : Vec P) => c8Up6of5 N p ε (Z θ)) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (c8Up7of6 N p ε (c8Up6of5 N p ε (Z θ)))) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S5 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G5 N p ε L σ₃ σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage4 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z4 N p ε x) (hT2 : TwinAlong N (C8PoolTwin2 N p ε x) Z) (hT3 : TwinAlong N (C8PoolTwin3 N p ε x) fun (θ : Vec P) => c8Up6of5 N p ε (c8Up5of4 N p ε (Z θ))) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (c8Up7of6 N p ε (c8Up6of5 N p ε (c8Up5of4 N p ε (Z θ))))) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S4 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G4 N p ε L σ₂ σ₃ σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage3 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c2 * (2 * (2 * (2 * h))) * (2 * (2 * (2 * w)))))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z3 N p ε x) (hT2 : TwinAlong N (C8PoolTwin2 N p ε x) fun (θ : Vec P) => c8Up4of3 N p ε (Z θ)) (hT3 : TwinAlong N (C8PoolTwin3 N p ε x) fun (θ : Vec P) => c8Up6of5 N p ε (c8Up5of4 N p ε (c8Up4of3 N p ε (Z θ)))) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (c8Up7of6 N p ε (c8Up6of5 N p ε (c8Up5of4 N p ε (c8Up4of3 N p ε (Z θ)))))) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S3 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G3 N p ε L σ₂ σ₃ σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage2 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z2 N p ε x) (hT1 : TwinAlong N (C8PoolTwin1 N p ε x) Z) (hT2 : TwinAlong N (C8PoolTwin2 N p ε x) fun (θ : Vec P) => c8Up4of3 N p ε (c8Up3of2 N p ε (Z θ))) (hT3 : TwinAlong N (C8PoolTwin3 N p ε x) fun (θ : Vec P) => c8Up6of5 N p ε (c8Up5of4 N p ε (c8Up4of3 N p ε (c8Up3of2 N p ε (Z θ))))) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (c8Up7of6 N p ε (c8Up6of5 N p ε (c8Up5of4 N p ε (c8Up4of3 N p ε (c8Up3of2 N p ε (Z θ))))))) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S2 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G2 N p ε L σ₁ σ₂ σ₃ σ₄ (Z θ)
                                                                                theorem Proofs.c8_germ_stage1 {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) {P : ℕ} (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (L : Vec (N * nC) → Vec 1) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hε : 0 < ε) (Z : Vec P → Vec (N * (c1 * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (θ₀ : Vec P) (hZc : ContinuousAt Z θ₀) (hZ0 : Z θ₀ = c8Z1 N p ε x) (hT1 : TwinAlong N (C8PoolTwin1 N p ε x) fun (θ : Vec P) => c8Up2of1 N p ε (Z θ)) (hT2 : TwinAlong N (C8PoolTwin2 N p ε x) fun (θ : Vec P) => c8Up4of3 N p ε (c8Up3of2 N p ε (c8Up2of1 N p ε (Z θ)))) (hT3 : TwinAlong N (C8PoolTwin3 N p ε x) fun (θ : Vec P) => c8Up6of5 N p ε (c8Up5of4 N p ε (c8Up4of3 N p ε (c8Up3of2 N p ε (c8Up2of1 N p ε (Z θ)))))) (hT4 : TwinAlong N (C8PoolTwin4 N p ε x) fun (θ : Vec P) => c8Up8of7 N p ε (c8Up7of6 N p ε (c8Up6of5 N p ε (c8Up5of4 N p ε (c8Up4of3 N p ε (c8Up3of2 N p ε (c8Up2of1 N p ε (Z θ)))))))) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :
                                                                                (fun (θ : Vec P) => c8S1 N p ε L (Z θ)) =ᶠ[nhds θ₀] fun (θ : Vec P) => c8G1 N p ε L σ₁ σ₂ σ₃ σ₄ (Z θ)
                                                                                theorem Proofs.c8_contW (N : ℕ) (ε : ℝ) {a oc H W kH' kW' : ℕ} (hε : 0 < ε) (Wc : Kernel4 oc a kH' kW') (bc γ β : Vec oc) (y : Vec (N * (a * H * W))) :
                                                                                ContinuousAt (fun (θ : Vec (oc * a * kH' * kW')) => StableHLO.bnBatchLA N oc H W ε γ β (StableHLO.batchMap N (flatConv (Kernel4.unflatten θ) bc) y)) Wc.flatten
                                                                                theorem Proofs.c8_contb (N : ℕ) (ε : ℝ) {a oc H W kH' kW' : ℕ} (hε : 0 < ε) (Wc : Kernel4 oc a kH' kW') (bc γ β : Vec oc) (y : Vec (N * (a * H * W))) :
                                                                                ContinuousAt (fun (θ : Vec oc) => StableHLO.bnBatchLA N oc H W ε γ β (StableHLO.batchMap N (flatConv Wc θ) y)) bc
                                                                                theorem Proofs.c8_contγ (N : ℕ) (ε : ℝ) {oc H W : ℕ} (hε : 0 < ε) (γ β : Vec oc) (v : Vec (N * (oc * H * W))) :
                                                                                ContinuousAt (fun (θ : Vec oc) => StableHLO.bnBatchLA N oc H W ε θ β v) γ
                                                                                theorem Proofs.c8_contβ (N : ℕ) (ε : ℝ) {oc H W : ℕ} (hε : 0 < ε) (γ β : Vec oc) (v : Vec (N * (oc * H * W))) :
                                                                                ContinuousAt (fun (θ : Vec oc) => StableHLO.bnBatchLA N oc H W ε γ θ v) β
                                                                                def Proofs.Cifar8BbnNetLossTiedB {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (xN cotN vN epsStr : String) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (bf16 : Bool) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (L : Vec (N * nC) → Vec 1) (g : Vec (N * nC)) :

                                                                                Every batch-statistics cifar8-BN gradient node is the gradient of L in that parameter: the 38 nodes Cifar8BbnStepTieB ties, each at the cotangent the chain threads to its layer with every pool routed at its selection, stated against L of cifar8BbnForwardB with that one parameter varied. The conv weight nodes are on the renderers' bf16 switch.

                                                                                Equations
                                                                                • One or more equations did not get rendered due to their size.
                                                                                Instances For
                                                                                  theorem Proofs.cifar8Bbn_net_lossGrad {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (xN cotN vN epsStr : String) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) (bf16 : Bool) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) {L : Vec (N * nC) → Vec 1} {g : Vec (N * nC)} (hL : HasGradAt L (cifar8BbnForwardB N p ε x) g) :
                                                                                  Cifar8BbnNetLossTiedB N xN cotN vN epsStr p ε bf16 x σ₁ σ₂ σ₃ σ₄ L g

                                                                                  Every batch-statistics cifar8-BN gradient node is the gradient of L in that parameter, whenever g is L's gradient at the logits. Hypotheses: 0 < ε; every ReLU off its kink, every pool window dead or tied only between that pool's twins, each selection naming a maximum of every window (Cifar8BbnLossSmoothAt); hL.

                                                                                  The step tie's one-row casts are BackLinks' (rowB, unrowB), by definition.

                                                                                  The emitted cifar8-bbn loss cotangent is the smoothed chain at zero smoothing: the render's scaleB invB (subB (unrow softmaxRow) t) is smoothedLossCotGraph at α = 0 and divisor invB⁻¹, read back through unrowB.

                                                                                  theorem Proofs.cifar8BbnLoss_hasGradAt (N K : ℕ) (hK : 0 < K) (sStr vN cotN : String) (invB : ℝ) (z t : Vec (N * K)) (ht : ∀ (n : Fin N), ∑ k : Fin K, targetRow N K (BackLinks.rowB N K t) n k = 1) :

                                                                                  The artifact's loss has the emitted cotangent as its gradient, at any target whose rows each sum to one and any positive class count.

                                                                                  theorem Proofs.cifar8Bbn_net_lossGrad_CE {ic c1 c2 c3 c4 h w d1 nC kH kW : ℕ} (N : ℕ) (xN cotN vN epsStr sStr : String) (hK : 0 < nC) (p : C8BbnW ic c1 c2 c3 c4 h w d1 nC kH kW) (ε : ℝ) (hε : 0 < ε) (bf16 : Bool) (invB : ℝ) (x : Vec (N * (ic * (2 * (2 * (2 * (2 * h)))) * (2 * (2 * (2 * (2 * w))))))) (t : Vec (N * nC)) (ht : ∀ (n : Fin N), ∑ k : Fin nC, targetRow N nC (BackLinks.rowB N nC t) n k = 1) (σ₁ : Fin N → Fin c1 → Fin (2 * (2 * (2 * h))) → Fin (2 * (2 * (2 * w))) → Fin 2 × Fin 2) (σ₂ : Fin N → Fin c2 → Fin (2 * (2 * h)) → Fin (2 * (2 * w)) → Fin 2 × Fin 2) (σ₃ : Fin N → Fin c3 → Fin (2 * h) → Fin (2 * w) → Fin 2 × Fin 2) (σ₄ : Fin N → Fin c4 → Fin h → Fin w → Fin 2 × Fin 2) (hx : Cifar8BbnLossSmoothAt N p ε x σ₁ σ₂ σ₃ σ₄) :

                                                                                  At the artifact's loss: every node is the gradient of the batch-mean softmax cross-entropy at the soft target t (the graph input %onehot), with g the cotangent the render composes from softmaxRow, subB and scaleB — the chain cifar8Bbn_train_step_tiedB reads, at castB1 = rowB and unB1 = unrowB.