Checks / structure
GroupNorm channels not divisible by numGroups
Check R29. Runs in the editor as you build, in CI through the
GitHub Action, and over the wire at
POST /api/v1/check. Milliseconds, before any GPU is billed.
block
structure
R29
| Trigger | A GroupNorm layer's channel count is not an exact multiple of numGroups. |
|---|---|
| Why | GroupNorm splits channels into equal groups; a non-divisible count raises at construction. Parallel to the GQA / attention head-dim divisibility checks. Set numGroups to a divisor of the channel count. |
| Source | Wu & He 2018, Group Normalization. |
The evidence behind it
In a 264-graph study (two seeds, torch 2.8), all 96 graphs blocked by the structural checks crashed PyTorch forward and all 80 that passed ran clean. Read the study.
Why it is not a lint you can ignore
A structural mistake does not fail at review time and it does not fail at import
time. It fails when the module is constructed on the training node, after the job was queued and
the dataset was downloaded. That is why this runs before the spend and not after it.
Run this check on your own model
Free, no account needed
Every check
41 structural checks: 6 guardrail gates and 35 architecture advisor rules. See the full catalogue.
← R28 ConvTranspose checkerboard risk ยท R30 Very large Linear layer →