PigeonColumba compressa

Magnitude pruning: the cliff and the regrow

How sparse can the teacher get? Compare one-shot cuts with and without recovery, recovery by labels vs. by distilling from the unpruned self, gradual pruning, and a dense small model with the same weight count.

Methods: Magnitude pruning

Line chart of test accuracy (20-way) against fraction of weights removed, one line per method, with a dashed reference line for the teacher. Titled “Magnitude pruning: the cliff and the regrow”. The numbers are in the table below.
Test accuracy (20-way) against fraction of weights removed
Line chart of test accuracy (20-way) against MACs / example (nonzero) (log scale), one line per method, with a dashed reference line for the teacher. Titled “Magnitude pruning: the cliff and the regrow”. The numbers are in the table below.
Test accuracy (20-way) against MACs / example (nonzero)

Table

Mean over the seeds; ± is the standard deviation where more than one seed ran. The experiment took 391 s.

Fraction of weights removedMethodDense widthTest accuracy (20-way)Target-class AP ('bird')Test NLLKL(Bayes || model)Parameters (nonzero)
0.500one-shot, no recovery0.896 ± 0.0000.981 ± 0.0000.411 ± 0.0000.331 ± 0.00070,420
0.500one-shot + label fine-tune0.915 ± 0.0000.989 ± 0.0000.396 ± 0.0040.323 ± 0.00470,420
0.500one-shot + KD from unpruned self0.919 ± 0.0000.989 ± 0.0000.312 ± 0.0010.235 ± 0.00070,420
0.500gradual (5 steps) + KD0.917 ± 0.0010.989 ± 0.0010.304 ± 0.0010.224 ± 0.00070,420
0.500dense small net, same #weights, KD2480.920 ± 0.0020.990 ± 0.0000.269 ± 0.0020.193 ± 0.00169,956
0.750one-shot, no recovery0.750 ± 0.0000.934 ± 0.0000.771 ± 0.0000.688 ± 0.00035,604
0.750one-shot + label fine-tune0.914 ± 0.0000.988 ± 0.0000.359 ± 0.0010.285 ± 0.00235,604
0.750one-shot + KD from unpruned self0.920 ± 0.0010.989 ± 0.0000.299 ± 0.0010.222 ± 0.00135,604
0.750gradual (5 steps) + KD0.918 ± 0.0010.990 ± 0.0000.274 ± 0.0010.198 ± 0.00235,604
0.750dense small net, same #weights, KD1710.919 ± 0.0000.990 ± 0.0010.265 ± 0.0030.187 ± 0.00235,075
0.900one-shot, no recovery0.286 ± 0.0000.636 ± 0.0002.323 ± 0.0002.237 ± 0.00014,714
0.900one-shot + label fine-tune0.902 ± 0.0000.986 ± 0.0000.326 ± 0.0010.250 ± 0.00014,714
0.900one-shot + KD from unpruned self0.912 ± 0.0010.987 ± 0.0000.274 ± 0.0010.198 ± 0.00014,714
0.900gradual (5 steps) + KD0.904 ± 0.0010.987 ± 0.0000.292 ± 0.0020.211 ± 0.00214,714
0.900dense small net, same #weights, KD1030.911 ± 0.0010.987 ± 0.0010.277 ± 0.0020.199 ± 0.00214,131
0.950one-shot, no recovery0.121 ± 0.0000.194 ± 0.0002.877 ± 0.0002.792 ± 0.0007,751
0.950one-shot + label fine-tune0.874 ± 0.0010.972 ± 0.0000.384 ± 0.0040.302 ± 0.0037,751
0.950one-shot + KD from unpruned self0.889 ± 0.0010.980 ± 0.0000.343 ± 0.0010.263 ± 0.0017,751
0.950gradual (5 steps) + KD0.858 ± 0.0040.967 ± 0.0000.446 ± 0.0080.367 ± 0.0087,751
0.950dense small net, same #weights, KD690.898 ± 0.0010.984 ± 0.0020.305 ± 0.0040.229 ± 0.0037,127
0.980one-shot, no recovery0.060 ± 0.0000.066 ± 0.0002.991 ± 0.0002.906 ± 0.0003,573
0.980one-shot + label fine-tune0.621 ± 0.0050.825 ± 0.0021.166 ± 0.0151.080 ± 0.0153,573
0.980one-shot + KD from unpruned self0.629 ± 0.0000.832 ± 0.0031.144 ± 0.0091.057 ± 0.0083,573
0.980gradual (5 steps) + KD0.618 ± 0.0080.843 ± 0.0051.209 ± 0.0211.125 ± 0.0203,573
0.980dense small net, same #weights, KD390.853 ± 0.0000.966 ± 0.0040.447 ± 0.0040.368 ± 0.0052,867
0.990one-shot, no recovery0.054 ± 0.0000.038 ± 0.0002.999 ± 0.0002.914 ± 0.0002,181
0.990one-shot + label fine-tune0.080 ± 0.0000.038 ± 0.0002.945 ± 0.0002.859 ± 0.0002,181
0.990one-shot + KD from unpruned self0.088 ± 0.0000.039 ± 0.0002.943 ± 0.0002.857 ± 0.0002,181
0.990gradual (5 steps) + KD0.401 ± 0.0090.642 ± 0.0641.834 ± 0.0281.751 ± 0.0282,181
0.990dense small net, same #weights, KD250.779 ± 0.0040.925 ± 0.0070.663 ± 0.0080.583 ± 0.0061,495

Reference points

Teacher (the large model)
The full-size network trained on the labeled data; the smaller models here are measured against it. Test accuracy (20-way) 0.914, target-class AP ('bird') 0.989, test NLL 0.384, KL(Bayes || model) 0.309, parameters (nonzero) 140,052.
Bayes-optimal (the best any model can do on this problem)
Predictions from the exact class probabilities, which the lab can compute because it generated the data. Test accuracy (20-way) 0.973, target-class AP ('bird') 0.999, test NLL 0.079.

Birds in this experiment

The table's 6 smaller models hatch 5 kinds of bird. Each kind is drawn once, for one model: the smallest if the bird is healthy or bones, the one that keeps the most if it's starving.

Measured against this experiment's teacher: 140,052 parameters, 4481.7 kbit, accuracy 0.914. Storage is 32 bits a parameter, the lab's rule for a dense fp32 net, which every model drawn here is. Species follows how many times smaller a model is. A bird stays healthy while its model keeps at least 95% of the reference's score, and turns to bones at 60% or less.

24 other models have no bird: a magnitude-pruned net also stores where its remaining weights sit, and this table doesn't record that storage.

These are the lab's recorded results, so they aren't added to anyone's life list. Birds you hatch yourself, in the Coop or from a Field Guide run, are saved to your life list.