PigeonColumba compressa

Structured (neuron) pruning: criteria, recovery, budget

Delete whole neurons so the net is genuinely smaller. Which importance criterion picks the right ones, and is a pruned teacher a head start over training the small shape fresh, at the same number of training steps?

Methods: Structured (neuron) pruning, Channel pruning with dependency groups, Prune, then fine-tune (cut and regrow)

Line chart of test accuracy (20-way) against hidden width (log scale), one line per configuration, with a dashed reference line for the teacher. Titled “recovered with KD, full budget (+ fresh init)”. The numbers are in the table below.
Test accuracy (20-way) against hidden width: recovered with KD, full budget (+ fresh init)
Line chart of test accuracy (20-way) against hidden width (log scale), one line per configuration, with a dashed reference line for the teacher. Titled “does the pruned start help? short vs full budget”. The numbers are in the table below.
Test accuracy (20-way) against hidden width: does the pruned start help? short vs full budget
Line chart of test accuracy (20-way) against hidden width (log scale), one line per configuration. Titled “no recovery: the cliff”. The numbers are in the table below.
Test accuracy (20-way) against hidden width: no recovery: the cliff

Note: 'short' = 750 steps, 'full' = 3000 steps; pruned and fresh nets use the same optimizer and learning rate, so the only difference is the starting weights.

Table

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

Hidden widthCriterionRecoveryTest accuracy (20-way)Target-class AP ('bird')Test NLLKL(Bayes || model)Parameters (nonzero)
128l1none0.4250.6761.9901.90537,268
128l1KD, short0.917 ± 0.0000.989 ± 0.0010.268 ± 0.0000.185 ± 0.00037,268
128l1KD, full0.915 ± 0.0000.989 ± 0.0000.315 ± 0.0000.235 ± 0.00037,268
128l1labels, full0.909 ± 0.0010.988 ± 0.0000.421 ± 0.0000.346 ± 0.00137,268
128actnone0.4050.6852.1592.08137,268
128actKD, short0.917 ± 0.0010.988 ± 0.0000.263 ± 0.0000.184 ± 0.00037,268
128actKD, full0.917 ± 0.0010.990 ± 0.0010.301 ± 0.0000.222 ± 0.00037,268
128actlabels, full0.910 ± 0.0010.986 ± 0.0000.408 ± 0.0000.334 ± 0.00137,268
128taylornone0.2990.3663.8643.78437,268
128taylorKD, short0.915 ± 0.0000.990 ± 0.0000.272 ± 0.0000.192 ± 0.00037,268
128taylorKD, full0.915 ± 0.0000.990 ± 0.0000.313 ± 0.0010.232 ± 0.00137,268
128taylorlabels, full0.906 ± 0.0000.989 ± 0.0000.421 ± 0.0030.341 ± 0.00237,268
128randomnone0.3090.6032.1822.09337,268
128randomKD, short0.916 ± 0.0000.987 ± 0.0000.262 ± 0.0010.187 ± 0.00037,268
128randomKD, full0.918 ± 0.0020.988 ± 0.0000.308 ± 0.0020.232 ± 0.00237,268
128randomlabels, full0.909 ± 0.0000.986 ± 0.0010.404 ± 0.0030.338 ± 0.00237,268
128(fresh init)KD, short0.911 ± 0.0010.989 ± 0.0010.270 ± 0.0020.196 ± 0.00337,268
128(fresh init)KD, full0.918 ± 0.0000.991 ± 0.0010.284 ± 0.0020.210 ± 0.00337,268
128(fresh init)labels, full0.909 ± 0.0030.988 ± 0.0010.382 ± 0.0030.313 ± 0.00237,268
64l1none0.1690.1352.7942.71110,452
64l1KD, short0.893 ± 0.0000.986 ± 0.0000.337 ± 0.0010.255 ± 0.00010,452
64l1KD, full0.908 ± 0.0000.987 ± 0.0010.307 ± 0.0000.225 ± 0.00010,452
64l1labels, full0.891 ± 0.0010.985 ± 0.0020.434 ± 0.0000.358 ± 0.00010,452
64actnone0.1480.4782.7862.70110,452
64actKD, short0.874 ± 0.0000.977 ± 0.0000.391 ± 0.0010.309 ± 0.00110,452
64actKD, full0.904 ± 0.0010.987 ± 0.0000.302 ± 0.0010.223 ± 0.00110,452
64actlabels, full0.888 ± 0.0020.980 ± 0.0000.409 ± 0.0000.334 ± 0.00010,452
64taylornone0.1520.1493.3143.23310,452
64taylorKD, short0.875 ± 0.0010.971 ± 0.0000.379 ± 0.0010.301 ± 0.00110,452
64taylorKD, full0.903 ± 0.0000.983 ± 0.0000.312 ± 0.0000.235 ± 0.00010,452
64taylorlabels, full0.884 ± 0.0000.981 ± 0.0010.428 ± 0.0000.353 ± 0.00010,452
64randomnone0.1130.2282.8422.75710,452
64randomKD, short0.875 ± 0.0000.975 ± 0.0010.384 ± 0.0010.302 ± 0.00110,452
64randomKD, full0.904 ± 0.0010.986 ± 0.0000.306 ± 0.0030.225 ± 0.00210,452
64randomlabels, full0.887 ± 0.0020.982 ± 0.0010.416 ± 0.0080.341 ± 0.00910,452
64(fresh init)KD, short0.869 ± 0.0020.972 ± 0.0030.399 ± 0.0080.319 ± 0.00710,452
64(fresh init)KD, full0.904 ± 0.0010.985 ± 0.0000.299 ± 0.0020.220 ± 0.00310,452
64(fresh init)labels, full0.885 ± 0.0010.979 ± 0.0010.422 ± 0.0080.344 ± 0.00810,452
32l1none0.0820.1972.9662.8813,188
32l1KD, short0.776 ± 0.0030.939 ± 0.0010.687 ± 0.0120.602 ± 0.0123,188
32l1KD, full0.860 ± 0.0020.974 ± 0.0030.431 ± 0.0080.346 ± 0.0093,188
32l1labels, full0.843 ± 0.0010.971 ± 0.0040.497 ± 0.0020.414 ± 0.0043,188
32actnone0.0780.1302.9692.8843,188
32actKD, short0.732 ± 0.0020.902 ± 0.0020.813 ± 0.0050.731 ± 0.0053,188
32actKD, full0.848 ± 0.0020.961 ± 0.0010.466 ± 0.0050.387 ± 0.0043,188
32actlabels, full0.827 ± 0.0010.953 ± 0.0020.534 ± 0.0010.454 ± 0.0023,188
32taylornone0.1100.0822.9922.9083,188
32taylorKD, short0.721 ± 0.0000.904 ± 0.0020.845 ± 0.0020.763 ± 0.0023,188
32taylorKD, full0.836 ± 0.0020.961 ± 0.0000.504 ± 0.0030.425 ± 0.0033,188
32taylorlabels, full0.820 ± 0.0000.951 ± 0.0010.566 ± 0.0010.489 ± 0.0013,188
32randomnone0.0760.0942.9872.9023,188
32randomKD, short0.731 ± 0.0050.894 ± 0.0020.800 ± 0.0090.716 ± 0.0103,188
32randomKD, full0.848 ± 0.0010.962 ± 0.0000.461 ± 0.0030.379 ± 0.0043,188
32randomlabels, full0.826 ± 0.0040.953 ± 0.0020.541 ± 0.0090.460 ± 0.0103,188
32(fresh init)KD, short0.744 ± 0.0020.901 ± 0.0060.765 ± 0.0050.685 ± 0.0073,188
32(fresh init)KD, full0.847 ± 0.0000.968 ± 0.0060.466 ± 0.0000.389 ± 0.0023,188
32(fresh init)labels, full0.825 ± 0.0000.953 ± 0.0040.550 ± 0.0000.474 ± 0.0013,188
16l1none0.0440.2442.9962.9111,092
16l1KD, short0.551 ± 0.0010.747 ± 0.0101.340 ± 0.0031.256 ± 0.0041,092
16l1KD, full0.686 ± 0.0060.873 ± 0.0110.941 ± 0.0150.859 ± 0.0141,092
16l1labels, full0.680 ± 0.0040.870 ± 0.0170.971 ± 0.0170.890 ± 0.0141,092
16actnone0.0590.0643.0082.9231,092
16actKD, short0.516 ± 0.0050.742 ± 0.0051.411 ± 0.0071.327 ± 0.0061,092
16actKD, full0.672 ± 0.0020.878 ± 0.0030.983 ± 0.0090.903 ± 0.0091,092
16actlabels, full0.666 ± 0.0000.857 ± 0.0001.013 ± 0.0060.931 ± 0.0061,092
16taylornone0.0440.0963.0332.9491,092
16taylorKD, short0.509 ± 0.0000.779 ± 0.0011.442 ± 0.0001.360 ± 0.0001,092
16taylorKD, full0.658 ± 0.0090.846 ± 0.0061.020 ± 0.0260.938 ± 0.0251,092
16taylorlabels, full0.642 ± 0.0040.825 ± 0.0011.068 ± 0.0050.983 ± 0.0051,092
16randomnone0.0550.0602.9952.9111,092
16randomKD, short0.504 ± 0.0030.796 ± 0.0111.453 ± 0.0011.371 ± 0.0011,092
16randomKD, full0.652 ± 0.0070.879 ± 0.0061.025 ± 0.0190.944 ± 0.0201,092
16randomlabels, full0.645 ± 0.0020.877 ± 0.0071.044 ± 0.0020.967 ± 0.0011,092
16(fresh init)KD, short0.548 ± 0.0030.793 ± 0.0171.340 ± 0.0151.257 ± 0.0161,092
16(fresh init)KD, full0.701 ± 0.0060.868 ± 0.0120.906 ± 0.0130.825 ± 0.0131,092
16(fresh init)labels, full0.685 ± 0.0010.861 ± 0.0050.955 ± 0.0080.873 ± 0.0071,092

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 76 smaller models hatch 6 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.

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.