MobileNetV2 — every parameter gradient node IS the loss's derivative in that parameter #
mnv2_net_tiedB says each of the 210 parameter gradient nodes (158 emitted at the default
convBias := false) denotes its layer's parameter Jacobian contracted with the cotangent the
emitted backward chain threads to it, from a loss cotangent g; the *_eq_vjp lemmas say the
chain's segments are certified VJP backwards. mnv2_net_lossGrad composes them: for any loss L
of the logits whose gradient at the net's output is g, every node is ∂L/∂θ of the WHOLE net with
that one parameter varied. mnv2_net_lossGrad_smoothedCE discharges hL for the label-smoothed
loss the artifacts ship.
How. ResNet50ParamGrad's shape:
- Per stage (at variable widths): the loss read at each internal activation of the stem, the
t = 1block, the stride-1 body, the stride-2 body and the head (mnv2StemG*,mnv2NoExpG*,mnv2BodyG*,mnv2SBodyG*,mnv2HeadG*), its gradient the chain's own cotangent through relu6 (relu6HasVJPAt, whose backward ISrelu6MaskB), batch BN, and the conv, depthwise and XLA-SAMEstrided depthwise input-VJPs. The stride-1 body bundle covers both the skip blocks and the two widenings: a skip block's body sees the lossu ↦ Gn (u + v), whose gradient at the body output is stilldyOut(mnv2_resid_lossTiedB). - Per net: the loss read after each block (
mnv2Suf*), pulled back through the seventeen certified block VJPs and the head's, and eachΦidentified with the whole net at updated weights by a standalonemnv2_factor_*theorem.
Hypotheses. MNV2PosB (every BN ε > 0), MNV2SmoothAtB (all 35 relu6 sites off both kinks
at the real activations); for the smoothed loss every example's target summing to one and
0 < nCls.
dStridedXlaInB — the emitted XLA-SAME strided depthwise input-cotangent — is the batched
strided depthwise VJP's backward, at any saved input.
The loss at the stem conv's output.
Equations
- Proofs.MobileNetV2TieB.mnv2StemGC N h w Gn εs γs βs z = Proofs.MobileNetV2TieB.mnv2StemGN N h w Gn (Proofs.StableHLO.bnBatchLA N oc h w εs γs βs z)
Instances For
Stem, every parameter node a loss derivative — the four nodes mnv2StemTiedB ties, Φ the
loss as a function of the stem's (W, b, γ, β).
Equations
- One or more equations did not get rendered due to their size.
Instances For
The loss at the project conv's output (Gn is the loss at the block output, bnₚ's).
Equations
- Proofs.MobileNetV2TieB.mnv2NoExpGPc N h w Gn p z = Gn (Proofs.StableHLO.bnBatchLA N oc h w p.pε p.pγ p.pβ z)
Instances For
The loss at the depthwise BN's output.
Equations
- Proofs.MobileNetV2TieB.mnv2NoExpGDn N h w Gn p u = Proofs.MobileNetV2TieB.mnv2NoExpGPc N h w Gn p (Proofs.StableHLO.batchMap N (Proofs.flatConv p.pW p.pb) (Proofs.relu6 (N * (ic * h * w)) u))
Instances For
The loss at the depthwise conv's output.
Equations
- Proofs.MobileNetV2TieB.mnv2NoExpGDc N h w Gn p z = Proofs.MobileNetV2TieB.mnv2NoExpGDn N h w Gn p (Proofs.StableHLO.bnBatchLA N ic h w p.dε p.dγ p.dβ z)
Instances For
t = 1 block, every parameter node a loss derivative — the eight nodes mnv2NoExpTiedB
ties. The project BN's γ/β read dyOut itself: nothing follows the linear bottleneck.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2BodyGPc N h w Gb p z = Gb (Proofs.StableHLO.bnBatchLA N oc h w p.pε p.pγ p.pβ z)
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2BodyGDn N h w Gb p u = Proofs.MobileNetV2TieB.mnv2BodyGPc N h w Gb p (Proofs.StableHLO.batchMap N (Proofs.flatConv p.pW p.pb) (Proofs.relu6 (N * (mid * h * w)) u))
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2BodyGDc N h w Gb p z = Proofs.MobileNetV2TieB.mnv2BodyGDn N h w Gb p (Proofs.StableHLO.bnBatchLA N mid h w p.dε p.dγ p.dβ z)
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2BodyGEc N h w Gb p z = Proofs.MobileNetV2TieB.mnv2BodyGEn N h w Gb p (Proofs.StableHLO.bnBatchLA N mid h w p.eε p.eγ p.eβ z)
Instances For
Stride-1 body, every parameter node a loss derivative — the twelve nodes
mnv2Stride1TiedB ties, Φ the loss at the body output as a function of the weight record.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The stride-1 body bundle, from the loss Gb at the body output. A widening block (b11,
b17) is this at Gb := Gn.
A skip block's twelve nodes. The identity skip is a constant once a body parameter varies,
so the loss at the body output has gradient dyOut there and the body bundle applies.
Equations
- Proofs.MobileNetV2TieB.mnv2SBodyGPc N h w Gn p z = Gn (Proofs.StableHLO.bnBatchLA N oc h w p.pε p.pγ p.pβ z)
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2SBodyGDn N h w Gn p u = Proofs.MobileNetV2TieB.mnv2SBodyGPc N h w Gn p (Proofs.StableHLO.batchMap N (Proofs.flatConv p.pW p.pb) (Proofs.relu6 (N * (mid * h * w)) u))
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2SBodyGDc N h w Gn p z = Proofs.MobileNetV2TieB.mnv2SBodyGDn N h w Gn p (Proofs.StableHLO.bnBatchLA N mid h w p.dε p.dγ p.dβ z)
Instances For
Equations
- Proofs.MobileNetV2TieB.mnv2SBodyGEc N h w Gn p z = Proofs.MobileNetV2TieB.mnv2SBodyGEn N h w Gn p (Proofs.StableHLO.bnBatchLA N mid (2 * h) (2 * w) p.eε p.eγ p.eβ z)
Instances For
Stride-2 block, every parameter node a loss derivative — the twelve nodes
mnv2Stride2TiedB ties; the depthwise nodes are the XLA-SAME strided ones.
Equations
- One or more equations did not get rendered due to their size.
Instances For
The loss at the GAP output (the classifier's input).
Equations
- Proofs.MobileNetV2TieB.mnv2HeadGA N L Wd bd a = L (Proofs.StableHLO.batchMap N (Proofs.dense Wd bd) a)
Instances For
The loss at the head relu6's output.
Equations
- Proofs.MobileNetV2TieB.mnv2HeadGHr N h w L Wd bd u = Proofs.MobileNetV2TieB.mnv2HeadGA N L Wd bd (Proofs.StableHLO.batchMap N (Proofs.globalAvgPoolFlat oc h w) u)
Instances For
The loss at the head BN's output.
Equations
- Proofs.MobileNetV2TieB.mnv2HeadGHn N h w L Wd bd u = Proofs.MobileNetV2TieB.mnv2HeadGHr N h w L Wd bd (Proofs.relu6 (N * (oc * h * w)) u)
Instances For
The loss at the head conv's output.
Equations
- Proofs.MobileNetV2TieB.mnv2HeadGHc N h w L εh γh βh Wd bd z = Proofs.MobileNetV2TieB.mnv2HeadGHn N h w L Wd bd (Proofs.StableHLO.bnBatchLA N oc h w εh γh βh z)
Instances For
Head, every parameter node a loss derivative — the six nodes mnv2HeadTiedB ties, Φ
the loss as a function of (hW, hb, hγ, hβ, Wd, bd).
Equations
- One or more equations did not get rendered due to their size.
Instances For
Pull the loss gradient back through the t = 1 block (mnv2NoExpCotIn_eq_vjp).
…through a widening block (mnv2ExpOnlyCotIn_eq_vjp).
…through a skip block (mnv2ResidCotIn_eq_vjp).
…and through a stride-2 block (mnv2StridedCotIn_eq_vjp).
The net after block b16: block b17, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB16 N w y = Proofs.MobileNetV2TieB.mnv2SufB17 N w (Proofs.mnv2ExpOnlyB N 7 7 w.b17 y)
Instances For
The net after block b15: block b16, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB15 N w y = Proofs.MobileNetV2TieB.mnv2SufB16 N w (Proofs.mnv2ResidB N 7 7 w.b16 y)
Instances For
The net after block b14: block b15, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB14 N w y = Proofs.MobileNetV2TieB.mnv2SufB15 N w (Proofs.mnv2ResidB N 7 7 w.b15 y)
Instances For
The net after block b13: block b14, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB13 N w y = Proofs.MobileNetV2TieB.mnv2SufB14 N w (Proofs.mnv2StridedB N 7 7 w.b14 y)
Instances For
The net after block b12: block b13, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB12 N w y = Proofs.MobileNetV2TieB.mnv2SufB13 N w (Proofs.mnv2ResidB N 14 14 w.b13 y)
Instances For
The net after block b11: block b12, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB11 N w y = Proofs.MobileNetV2TieB.mnv2SufB12 N w (Proofs.mnv2ResidB N 14 14 w.b12 y)
Instances For
The net after block b10: block b11, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB10 N w y = Proofs.MobileNetV2TieB.mnv2SufB11 N w (Proofs.mnv2ExpOnlyB N 14 14 w.b11 y)
Instances For
The net after block b9: block b10, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB9 N w y = Proofs.MobileNetV2TieB.mnv2SufB10 N w (Proofs.mnv2ResidB N 14 14 w.b10 y)
Instances For
The net after block b8: block b9, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB8 N w y = Proofs.MobileNetV2TieB.mnv2SufB9 N w (Proofs.mnv2ResidB N 14 14 w.b9 y)
Instances For
The net after block b7: block b8, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB7 N w y = Proofs.MobileNetV2TieB.mnv2SufB8 N w (Proofs.mnv2ResidB N 14 14 w.b8 y)
Instances For
The net after block b6: block b7, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB6 N w y = Proofs.MobileNetV2TieB.mnv2SufB7 N w (Proofs.mnv2StridedB N 14 14 w.b7 y)
Instances For
The net after block b5: block b6, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB5 N w y = Proofs.MobileNetV2TieB.mnv2SufB6 N w (Proofs.mnv2ResidB N 28 28 w.b6 y)
Instances For
The net after block b4: block b5, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB4 N w y = Proofs.MobileNetV2TieB.mnv2SufB5 N w (Proofs.mnv2ResidB N 28 28 w.b5 y)
Instances For
The net after block b3: block b4, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB3 N w y = Proofs.MobileNetV2TieB.mnv2SufB4 N w (Proofs.mnv2StridedB N 28 28 w.b4 y)
Instances For
The net after block b2: block b3, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB2 N w y = Proofs.MobileNetV2TieB.mnv2SufB3 N w (Proofs.mnv2ResidB N 56 56 w.b3 y)
Instances For
The net after block b1: block b2, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufB1 N w y = Proofs.MobileNetV2TieB.mnv2SufB2 N w (Proofs.mnv2StridedB N 56 56 w.b2 y)
Instances For
The net after the stem: block b1, then the rest.
Equations
- Proofs.MobileNetV2TieB.mnv2SufStem N w y = Proofs.MobileNetV2TieB.mnv2SufB1 N w (Proofs.mnv2NoExpB N 112 112 w.b1 y)
Instances For
The net with the stem's parameters varied is the suffix after the stem at the varied stem.
The net with block b1's weights varied is the suffix after b1 at the varied block.
The net with block b2's weights varied is the suffix after b2 at the varied block.
The net with block b3's weights varied is the suffix after b3 at the varied block.
The net with block b4's weights varied is the suffix after b4 at the varied block.
The net with block b5's weights varied is the suffix after b5 at the varied block.
The net with block b6's weights varied is the suffix after b6 at the varied block.
The net with block b7's weights varied is the suffix after b7 at the varied block.
The net with block b8's weights varied is the suffix after b8 at the varied block.
The net with block b9's weights varied is the suffix after b9 at the varied block.
The net with block b10's weights varied is the suffix after b10 at the varied block.
The net with block b11's weights varied is the suffix after b11 at the varied block.
The net with block b12's weights varied is the suffix after b12 at the varied block.
The net with block b13's weights varied is the suffix after b13 at the varied block.
The net with block b14's weights varied is the suffix after b14 at the varied block.
The net with block b15's weights varied is the suffix after b15 at the varied block.
The net with block b16's weights varied is the suffix after b16 at the varied block.
The net with block b17's weights varied is the suffix after b17 at the varied block.
The net with the head varied is the head at the varied parameters.
Every MobileNetV2 parameter gradient node is the derivative of L in that parameter, for a
loss L of the logits and g the cotangent the chain starts from: the 210 slots
mnv2_net_tiedB ties, each at the cotangent the emitted chain threads to it, stated against L
of mobilenetv2ForwardBFull with that one parameter varied.
Equations
- One or more equations did not get rendered due to their size.
Instances For
Every MobileNetV2 parameter gradient node is the derivative of the loss in that
parameter. For any loss L of the logits with gradient g at the net's output, each of the
210 slots mnv2_net_tiedB ties — at the same cotangent — is ∂L/∂θ of the WHOLE net,
mobilenetv2ForwardBFull with that one parameter varied (a stem field, a block's weight record
w.bk := p with one slot changed, or a head field).
Hypotheses: every BN ε positive (MNV2PosB) and all 35 relu6 sites off both kinks at the real
activations (MNV2SmoothAtB). The loss enters only through hL;
mnv2_net_lossGrad_smoothedCE discharges it for the loss the artifacts ship.
The loss the artifacts ship: every node is the derivative of the batched label-smoothed
cross-entropy smoothedBatchLoss, g the six-op cotangent the render emits.