gMLP Gates Tokens Without Attention
gMLP splits channels and gates one half by a spatial projection of the other, adding location sense to MLPs cheaply.
Why Does This Exist?
Mixer mixes all tokens equally with no order bias. Language and vision both need order without full attention.
gMLP gates instead. It follows mlp mixer baselines, aids image classification scaling, and keeps pretrained models simple.
Think of It Like This
A dimmer wired to a neighbor room
Two rooms share power. One room dial sets brightness in the other, so activity couples without a central controller.
Split halves are rooms, spatial projection is wiring. Where it stops: fixed wiring cannot adapt per input, just as static gates lack input dependence.
How It Actually Works
Split into halves of channels. Spatial gate with shape . Output , where multiplies elementwise. Add channel MLPs around it.
Worked example
. holds weights. Gate for token is . If row peaks on token plus on , output keeps local order. Cost K versus attention per head per layer dynamic.
Watch Out For
Expecting input adaptive routing from static gates
is fixed after training, unlike attention. Symptom: poor handling of shuffled layouts. Fix: use attention or dynamic gates when order varies strongly per input.
The Quick Version
- gMLP splits channels and gates half by spatial projection.
- Gate matrix holds K static weights.
- Order emerges without attention or positions.
- Static gates cannot adapt per input like attention.
- Pair with channel MLPs for full blocks.